This endpoint allows you to assign one or more agents to a specific customer via public APIs. The assignment can include an expiration date and optional notes.
Endpoint
POST https://api.pingup.ai/ext/v2/{businessname}}/clients/:_id/assign-agents
Autenticazione
The endpoint requires authentication using a JWT Bearer token. The token must be included in the header. Authorization.
Authorization: Bearer YOUR_JWT_TOKEN
Params URL
Param
Type
Required
Description
_id
String
Yes
Customer ID to assign agents to
Body
{"agents":[{"agent":"string","dt_until":"ISO 8601 date string"}],"ds_notes":"string"}
Body Pamras
Param
Type
Required
Description
agents
Array
Yes
Array of agent objects to assign (minimum 1)
agents[].agent
String
Yes
ID of the agent to assign
agents[].dt_until
String
N
Assignment expiration date in ISO 8601 format. If not specified, the default date (2143-06-23) is used.
ds_notes
String
No
Textual notes relating to the assignment
Success
Code:200 OK
Errors
400 Bad Request
Example:
Error messages
"Missing or invalid agents array" -The agents array is missing, not an array, or empty.
"Invalid agent data: missing agent ID" - An array element does not contain the agent ID
"Agent {id} not found or not authorized" - The specified agent does not exist or does not belong to the user.
404 Not Found
The client does not exist or does not belong to the authenticated user.
Esempio:
401 Unauthorized
Missing or invalid authentication token.
Examples
Request:
Response:
Use cases
1. Automatic Assignment from External CRM
When a new lead comes in from the CRM, it can be automatically assigned to a specific agent.
2. Scheduled Agent Rotation
Through an external system, it is possible to schedule agent rotation on specific customers with precise expiration dates.
3. Team Assignment
For enterprise customers, you can deploy an entire team of agents with a single API call.
4. Workflow Integration
Connect with workflow management systems to automatically assign agents based on business rules.