External API
Find a team by name
Find the team in Proto that matches a free-text name, such as one a customer typed.
Finds the team that matches a name – for example, when a form asks which department to contact and a customer types billing support. Proto compares the name with each team’s name and Alternative names, the same way an AI agent’s Auto team match action does. Nothing changes in Proto. Not sure how to send a request? See Make your first request.
Request
Send a POST request to:
https://v3-api.proto.cx/api/platform/v1/teams/YOUR_TEAMSPACE_ID/get-team-by-name?top_k=5&score_threshold=0.7
| Parameter | Required | What it is |
|---|---|---|
top_k | No | The most teams to return. Defaults to 5. |
score_threshold | No | The lowest score to return, from 0 to 1. Defaults to 0.7. |
In the body, send the name to match. In the address, replace anything starting with YOUR_ with your own:
{
"name": "billing support"
}
| Field | Required | What it is |
|---|---|---|
name | Yes | The name to match |
Response
Proto replies 200 OK with a list of the teams that match, best first:
[
{
"id": "01J0TEAMABCDEF1234567890AB",
"name": "Billing",
"matched_name": "billing support",
"score": 0.8712,
"tags": [{ "id": "01J0TAGABCDEF1234567890ABC", "name": "billing" }],
"tag_groups": [{ "id": "01J0TGABCDEF1234567890ABCD", "name": "Finance" }]
}
]
| Field | What it is |
|---|---|
id | The team’s ID – use it to assign a ticket to the team. |
matched_name | The name or alternative name that matched |
score | How close the match is, from 0 to 1. An exact match, ignoring capital letters, scores 1 and is the only result. |
tags | The tags Proto adds automatically when the team is assigned |
tag_groups | The tag groups Proto adds automatically when the team is assigned |
If nothing is close enough, the list is empty. To make matches more likely, add the names customers use to each team’s Alternative names, in Settings, under Workspace, then Teams.
Errors
There are no errors specific to this request – if no team is close enough, the list is empty.
For errors any request can return, see If something goes wrong.