FieldEx Developer
developer notes

Patch a Sales Order

The PartialUpdate API allows you to update a subset of the fields in the sales order records. This is useful in cases where you need to update a sales order without having to update all of the fields.

Method API Endpoint
PATCH {{endpoint}}/api/ext/sales-orders

Headers

Key Value
Content-Type application/json
Authorization Bearer {{token}}

Example Request

{
    "salesOrder": {
        "customer": {
            "id": "3",
            "email": null,
            "customerExternalId": null
        },
        "orderCurrency": "MYR",
        "salesOrderChannel": {
            "code": "FF",
            "name": null
        },
        "salesOrderType": {
            "code": "ORDER_TYPE_1"
        },
        "orderOwner": {
            "login": "tharindu@lavalabs.net"
        },
        "billingContact": {
            "externalId": "contact1"
        },
        "shippingContact": {
            "externalId": "contact1"
        },
        "country": {
            "name": "Malasiya"
        },
        "status": "DRAFT",
        "salesOrderExternalId": "salesOrderExt",
        "orderName": "salesorder1",
        "orderStartDate": "2023-10-06",
        "orderEndDate": "2023-10-31",
        "orderAmount": "0"
    },
    "productVMSList": []
}

Example Response

// 400 Response Code

{
    "message": "Sales Order not found with ext : salesOrderExt"
}