1. Sales
VasyOpenAPI
  • Branch
    • Branch List
      GET
  • Department
    • department
      GET
  • Category
    • category
      GET
    • subCategory
      GET
  • Brand
    • Brand
      GET
    • SubBrand
      GET
  • Contact
    • Transporter Contact List
      GET
    • Get Customer List W Branch Id
      GET
    • Get Contact By Id
      GET
    • Get Contact By Mobile No
      GET
    • contactSave
      POST
    • Supplier(Party)
      GET
  • GST
    • Verify GST
      POST
  • Master
    • Get Country List
    • Get State List
    • Get City List
    • Get Tax List
    • Get Additional Charge List
  • Product
    • Get Product List
    • Get Product By ID
    • products with inventory
    • product details with Inventory By Product ID
    • Product Variant List ID & Name
    • Variant Details By Variant ID
  • Recipe
    • Get All Recipe
  • User
    • Created By
  • Report
    • Get Sales Item Register Data
    • Purchase Item Register Report
    • Stock Summary Report
    • Stock Transfer Item Register Report
    • Consumption Production Report
  • Sales
    • Update Shipping Detail
      POST
    • Update Payment Status
      POST
    • Update Order Status
      POST
    • Get All Sales Data
      POST
    • Get Sales Data By Id
      GET
    • Order Create
      POST
    • Order Status
      GET
    • Shipping Details
      GET
    • Update Due Date
      POST
    • Update Order Status
      POST
  1. Sales

Update Order Status

POST
/api/v1/sales/{salesId}/update-order-status

Update Order Status#

Purpose#

Update the order status of an existing sales voucher in the specified branch.

Why would you use this?#

Use this API when the status of a sales order changes during its lifecycle, such as when it is confirmed, processed, shipped, delivered, or cancelled. This allows external applications to keep the order status synchronized with VasyERP.

Information Required#

Headers#

FieldRequiredDescription
api-tokenYesAuthentication token provided by VasyERP
Content-TypeYesMust be application/json

Path Parameters#

FieldRequiredDescription
salesIdYesUnique ID of the sales voucher whose order status needs to be updated

Query Parameters#

FieldRequiredDescription
branch_idYesBranch ID in which the sales voucher exists

Request Body#

FieldRequiredDescriptionValidation
orderStatusYesNew status of the sales orderAccepted values: Pending, Confirmed, Processing, Shipped, Delivered, Cancelled (as applicable)
reasonNoReason code for updating the order status (primarily used for cancellation or status-specific actions)Must be a valid numeric value when provided

Example Use Case#

An e-commerce platform, logistics application, or third-party ERP updates the status of a customer order after it progresses through the fulfillment process. When the order is delivered or its status changes, the application calls this API to keep the order status synchronized with VasyERP.

Important Notes#

The specified sales voucher must exist in the provided branch.
A valid api-token is required to authenticate the request.
orderStatus is a mandatory field.
to make order status Deliverd paymentStatus must be paid
reason is optional and should contain a valid reason code when applicable.
Only valid order status values are accepted.
This API updates only the order status information of the sales voucher. All other voucher information remains unchanged.
Invalid input values or missing required fields will result in a validation error response.

Request

Path Params

Query Params

Header Params

Body Params text/plainRequired
Examples

Responses

🟢200Success
application/json
Bodyapplication/json

🟠400
Request Request Example
Shell
JavaScript
Java
Swift
curl --location '/api/v1/sales/3649298/update-order-status?branch_id=5999' \
--header 'api-token: af9ad6a5-593e-4bxq-a5c3-664129ebfger' \
--header 'Content-Type: application/json' \
--data '{  
    "orderStatus" : "In progress", 
    "reason": 1  
}'
Response Response Example
200 - Example 1
{
    "status": true,
    "message": "Order status updated successfully",
    "code": "200",
    "response": null
}
Previous
Update Payment Status
Next
Get All Sales Data
Built with