FieldEx Developer
developer notes

Get All Sales Orders By Customer

The SalesOrderGetAllByCustomer API allows you to retrieve all existing Sales Order.

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

Headers

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

Filter Fields

Parameter Type Example Length Required Description
page Number 1 Yes Page number for pagination
perPage Number 10 Yes Number of items per page
startFrom Number 1 Yes Start index for pagination
columnName String id Yes Name of the column for sorting
sortOrder String desc Yes Sort order(asc/desc)
search String test Yes Specifies the search query
customerId Number 1 No Customer ID for filtering

API Query Example

Method API Call
GET api/ext/sales-orders?customerid=1&startFrom=0&page=&perPage=25&columnName=&sortOrder=desc&search=a

Example Response

// 200 Response Code
{
    "total": "59372",
    "count": "2",
    "data": [
        {
            "id": "60727",
            "orderName": "testingggggg",
            "salesOrderExternalId": "null",
            "orderStartDate": "2023-08-14",
            "salesOrderNumber": "SO-060727",
            "status": "DRAFT",
            "customer": {
                "id": "null",
                "name": "1 Load Test [DO NOT DELETE]",
                "email": "null",
                "billingCity": "null",
                "billingCountry": "null",
                "billingPostcode": "null",
                "billingState": "null",
                "billingStreet": "null",
                "shippingCity": "null",
                "shippingCountry": "null",
                "shippingPostcode": "null",
                "shippingState": "null",
                "shippingStreet": "null",
                "contactPersonName": "null",
                "customerReferenceNo": "null"
            },
            "billingAddress": "null",
            "totalPrice": "null"
        },
        {
            "id": "60723",
            "orderName": "Testing the records",
            "salesOrderExternalId": "123455",
            "orderStartDate": "2023-08-04",
            "salesOrderNumber": "SO-060723",
            "status": "jsrsdendcd",
            "customer": {
                "id": "null",
                "name": "1 Load Test [DO NOT DELETE]",
                "email": "null",
                "billingCity": "null",
                "billingCountry": "null",
                "billingPostcode": "null",
                "billingState": "null",
                "billingStreet": "null",
                "shippingCity": "null",
                "shippingCountry": "null",
                "shippingPostcode": "null",
                "shippingState": "null",
                "shippingStreet": "null",
                "contactPersonName": "null",
                "customerReferenceNo": "null"
            },
            "billingAddress": "null",
            "totalPrice": "2500.0"
        }
    ],
    "recordsTotal": "59372",
    "recordsFiltered": "59372",
    "status": "HAS_DATA"
}