Skip to main content

Get Sales Agent Listing

Request

GET:/{accountBookId}/salesagent/listing

Request Parameters

ParameterDescriptionType
pagePage index of returned records. Each page contains at most 100 records. Using a page index beyond the number of available pages will result in empty result.numberrequired
activeOnlyActive only flag. When field value is "true", only active sales agents will be included in the query.boolean

Example Request URL:

Example: Get listing of active sales agents.

Parameters:
accountBookId = 1
page = 1
activeOnly = true

URL:
GET: https://accounting-api.autocountcloud.com/1/salesAgent/listing?activeOnly=true&page=1

Response

Success Response

Status Code: 200

Response Body

FieldDescriptionType
dataResponse data.array[Sales Agent Listing View Model]
totalCountNumber of records retrieved.number
Example Success Response Body
 {
"data": [
{
"salesAgent": "Abu",
"description": "Melaka sales agent",
"desc2": "",
"isActive": true,
"signature": null
},
{
"salesAgent": "Ali",
"description": "Kuala Lumpur sales agent",
"desc2": "",
"isActive": true,
"signature": null
},
{
"salesAgent": "Bob",
"description": "Penang sales agent",
"desc2": "",
"isActive": true,
"signature": null
},
{
"salesAgent": "Liam",
"description": "Georgia sales agent",
"desc2": "",
"isActive": true,
"signature": null
},
{
"salesAgent": "Ramli",
"description": "Kedah sales agent",
"desc2": "",
"isActive": true,
"signature": null
}
],
"totalCount": 5
}

Error Response

Response Body

object: Error Response Model

Example Error Response Body
{
"statusCode": 401,
"message": "401 Unauthorized."
}