Skip to content

Task-Worker Pairing Configs

Task-Worker Pairing Configs are used to configure the behavior of tasks in the CRM. A TWPC is used to define the rules for how tasks are assigned to agents (i.e., workers).

In order to configure a TWPC you need to understand the contents of task and worker objects. See the List Unterminated Task endpoint and the List Workers endpoint for more details.

List task-worker pairing configs

Request

List the task-worker pairing configs for a company.

Security
oauth2(Required scopes: twpc:list) or bearerAuth or apiKeyHeader
Path
companyIdstringrequired

The unique company identifier.

Query
sortByArray of strings

Which fields to sort by

Default:["-priority"]
Items Enum:"id""+id""-id""priority""-priority""+priority""createdAt""+createdAt""-createdAt"
limitinteger, [ 1 .. 100 ]

The maximum count of results to retrieve.

Default:25
startingAfterstring

Return results starting after the provided object identifier.

endingBeforestring

Return results ending before the provided object identifier.

GET
/companies/{companyId}/task-worker-pairing-configs
curl -i -X GET \
  'https://sandboxapi.peach.finance/api/companies/{companyId}/task-worker-pairing-configs?sortBy=-priority&limit=25&startingAfter=string&endingBefore=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Success

Bodyapplication/json
countintegerread-only

Total number of items in this result.

statusinteger

HTTP status code.

dataArray of objects(TaskWorkerPairingConfig)
Response
{ "count": 0, "status": 0, "data": [ { … } ] }