Customer

Manage customer master data including credit terms, currency, and contact information.

Path Parameter::CODE (string) — customer code

Endpoints

GET
/customer

List all customers

GET
/customer/:CODE

Get single customer by code

POST
/customer

Create new customer

PUT
/customer/:CODE

Update customer

DELETE
/customer/:CODE

Delete customer

Fields

FieldTypeRequiredNotes
codestring
Yes
Unique customer code identifier.
companynamestring
Yes
Business name. Field is 'companyname', not 'company'.
controlaccountstringNoDebtor control account code. Auto-defaults to 300-000.
Default: "300-000"
companycategorystringNoCustomer category. Get from GET /companycategory.
Default: "----"
areastringNoSales area/region. Get from GET /area.
Default: "----"
agentstringNoSales agent assigned. Get from GET /agent.
Default: "----"
credittermstringNoPayment terms. Get from GET /terms.
Default: "30 Days"
currencycodestringNoCurrency for transactions. Get from GET /currency.
Default: "----"
pricetagstringNoPrice level. Get from GET /pricetag.
Default: null
taxstringNoDefault tax code. Get from GET /tax.
Default: null
creditlimitstringNoCredit limit amount. Stored as string.
Default: "30000"
creationdatestringNoCreation date. Format: YYYY-MM-DD.
Default: today

Examples

POST — Create Customer (Minimal)

POST /customer
{
  "code": "CUS-01",
  "companyname": "Test Customer Sdn Bhd"
}

POST — Create Customer (Full)

POST /customer
{
  "code": "CUS-01",
  "companyname": "Test Customer Sdn Bhd",
  "creditterm": "30 Days",
  "currencycode": "----",
  "creditlimit": "50000",
  "area": "KL",
  "agent": "AGT-01"
}

PUT — Update Customer

PUT /customer/CUS-01
{
  "creditlimit": "75000",
  "creditterm": "60 Days"
}

Response (200 OK)

{
  "code": "CUS-01",
  "companyname": "Test Customer Sdn Bhd",
  "controlaccount": "300-000",
  "creditterm": "60 Days",
  "creditlimit": "75000",
  "currencycode": "----",
  "area": "----",
  "agent": "----"
}