Skip to content

Create a service

POST
/services
curl --request POST \
--url https://apisandbox.puurk.com/services \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "id": "example", "oid": "example", "name": "example", "cogs": 1, "unit_price": 1, "active": true, "adjustable_price": true, "commission_fixed": 1, "commission_rate": 1, "commission_basis": "profit", "commission_total": 1, "down_payment": 1, "description": "example", "notes": "example", "photo_path": "example", "providers": [ "example" ], "savings": 1, "service_ids": [ "example" ], "services": [ { "service_id": "example", "service_name": "example", "original_quantity": 1, "quantity": 1, "remaining_quantity": 1, "amount": 1, "merge_contract_id": "example" } ], "is_package": true, "type": "service", "brand": "example", "category": "example", "supplier": "example", "charge_tax": true, "sku": "example", "barcode": "example", "min_qty": 1, "stock": 1, "term_cap": 1 }'

Create a new service

Request body

Media typeapplication/json
object
id

Unique identifier for the service

string
oid

Organization ID

string
name

Service name

string
cogs

Cost of goods sold

number format: double
unit_price

Unit price

number format: double
active

Whether the service is active

boolean
adjustable_price

Whether the price is adjustable

boolean
commission_fixed

Fixed commission amount

number format: double
commission_rate

Commission rate

number format: double
commission_basis

Basis for commission calculation

string
Allowed values: profit retail
commission_total

Total commission

number format: double
down_payment

Down payment amount

number format: double
description

Service description

string
notes

Additional notes

string
photo_path

Path to service photo

string
providers

List of provider IDs

Array<string>
savings

Savings amount

number format: double
service_ids

List of service IDs

Array<string>
services

List of package services

Array<object>
object
service_id

Service ID

string
service_name

Service name

string
original_quantity

Original quantity

number format: double
quantity

Current quantity

number format: double
remaining_quantity

Remaining quantity

number format: double
amount

Amount

number format: double
merge_contract_id

Merge contract ID

string
is_package

Whether this is a package service

boolean
type

Type of service

string
Allowed values: service package product
brand

Service brand

string
category

Service category

string
supplier

Service supplier

string
charge_tax

Whether to charge tax

boolean
sku

Stock keeping unit

string
barcode

Barcode

string
min_qty

Minimum quantity

number format: double
stock

Stock quantity

number format: double
term_cap

Term cap

number format: double

Service created

Media typeapplication/json
object
id

Unique identifier for the service

string
oid

Organization ID

string
name

Service name

string
cogs

Cost of goods sold

number format: double
unit_price

Unit price

number format: double
active

Whether the service is active

boolean
adjustable_price

Whether the price is adjustable

boolean
commission_fixed

Fixed commission amount

number format: double
commission_rate

Commission rate

number format: double
commission_basis

Basis for commission calculation

string
Allowed values: profit retail
commission_total

Total commission

number format: double
down_payment

Down payment amount

number format: double
description

Service description

string
notes

Additional notes

string
photo_path

Path to service photo

string
providers

List of provider IDs

Array<string>
savings

Savings amount

number format: double
service_ids

List of service IDs

Array<string>
services

List of package services

Array<object>
object
service_id

Service ID

string
service_name

Service name

string
original_quantity

Original quantity

number format: double
quantity

Current quantity

number format: double
remaining_quantity

Remaining quantity

number format: double
amount

Amount

number format: double
merge_contract_id

Merge contract ID

string
is_package

Whether this is a package service

boolean
type

Type of service

string
Allowed values: service package product
brand

Service brand

string
category

Service category

string
supplier

Service supplier

string
charge_tax

Whether to charge tax

boolean
sku

Stock keeping unit

string
barcode

Barcode

string
min_qty

Minimum quantity

number format: double
stock

Stock quantity

number format: double
term_cap

Term cap

number format: double
Example
{
"commission_basis": "profit",
"type": "service"
}

Invalid input

Unauthorized