| Field | Required | Description |
|---|---|---|
| api-token | Yes | Authentication token provided by VasyERP |
| branch_id | Yes | Branch ID where the order will be created |
| contactId | Yes | Customer ID |
| salesOrderItems | Yes | List of products to be added |
| productId | Yes | Product ID |
| productVariantId | Yes | Product Variant ID |
| quantity | Yes | Quantity to order |
| price | Yes | Selling price per unit |
| shippingContactAddressId | Yes | Customer shipping address ID |
| billingContactAddressId | Yes | Customer billing address ID |
| paymentMethod | Yes | Payment method |
| couponCode | No | Coupon code |
| remark | No | Order remarks |
| deliveryDate | No | Expected delivery date |
| salesAdditionalCharge | No | Additional charges to apply |
curl --location '/api/v1/sales/order/create?branch_id=24448' \
--header 'api-token: {{.in-api-token}}' \
--header 'Content-Type: application/json' \
--data '{
"salesOrderItems": [
{
"productVariantId": 20847916,
"price": 33000.00,
"quantity": 1,
"productId": 18313750,
"subTotal": 33000.00,
"mrp": 35999.0
}
],
"contactId": 5313756,
"shippingContactAddressId": 5278168,
"billingContactAddressId": 5278168,
"paymentMethod": "cod",
"companyId": 24448,
"couponCode": "C-987",
"remark": "Order placed via Open API",
"deliveryDate": "2026-07-25",
"salesAdditionalCharge": [
{
"additionalChargeId": 77567,
"additionalChargeAmount": 100.0,
"additionalChargeValue": 100.0,
"taxId": 65605,
"taxRate": 18.0,
"taxAmount": 0.0
}
]
}'{
"status": true,
"message": "Sales created successfully",
"code": "200",
"response": {
"salesId": 30801778
}
}