> For the complete documentation index, see [llms.txt](https://docs.epic-ai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.epic-ai.com/api-dokumentation/inbox-teams.md).

# Inbox Teams

## Lists all teams for a chatbot

> \
> \
> \*\*Required Permission:\*\* \`chatbots.teams.list\`\
> \
> \*\*Resource:\*\* \`chatbots/:chatbotId\`

```json
{"openapi":"3.0.0","info":{"title":"ChatCaptain API","version":"1.0"},"tags":[{"name":"Inbox teams","description":""}],"servers":[{"url":"https://api.chatcaptain.com","description":"Production"}],"security":[{},{}],"paths":{"/v1/inbox/{chatbotId}/teams":{"get":{"operationId":"InboxTeamsController_listTeams[1]_v1","parameters":[{"name":"chatbotId","required":true,"in":"path","description":"The ID of the chatbot.","schema":{"type":"string"}}],"responses":{"200":{"description":"List of all teams.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTeamsResponseDto"}}}},"403":{"description":"Insufficient permissions."}},"summary":"Lists all teams for a chatbot","tags":["Inbox teams"],"description":"\n\n**Required Permission:** `chatbots.teams.list`\n\n**Resource:** `chatbots/:chatbotId`"}}},"components":{"schemas":{"ListTeamsResponseDto":{"type":"object","properties":{"teams":{"description":"The list of teams.","type":"array","items":{"$ref":"#/components/schemas/TeamDto"}},"error":{"type":"string","description":"Optional error message."}},"required":["teams"]},"TeamDto":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the team."},"name":{"type":"string","description":"The name of the team."},"created":{"type":"string","description":"Timestamp when the team was created."},"updated":{"type":"string","description":"Timestamp when the team was last updated."},"icon":{"type":"string","description":"The icon identifier for the team."},"userIds":{"description":"The list of user IDs that are members of the team.","type":"array","items":{"type":"string"}}},"required":["id","name","created","updated","icon","userIds"]}}}}
```

## Creates a new team

> \
> \
> \*\*Required Permission:\*\* \`chatbots.teams.create\`\
> \
> \*\*Resource:\*\* \`chatbots/:chatbotId\`

```json
{"openapi":"3.0.0","info":{"title":"ChatCaptain API","version":"1.0"},"tags":[{"name":"Inbox teams","description":""}],"servers":[{"url":"https://api.chatcaptain.com","description":"Production"}],"security":[{},{}],"paths":{"/v1/inbox/{chatbotId}/teams":{"post":{"operationId":"InboxTeamsController_createTeam[1]_v1","parameters":[{"name":"chatbotId","required":true,"in":"path","description":"The ID of the chatbot.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTeamRequestDto"}}}},"responses":{"201":{"description":"Team created successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponseDto"}}}},"400":{"description":"Invalid input data."},"403":{"description":"Insufficient permissions."}},"summary":"Creates a new team","tags":["Inbox teams"],"description":"\n\n**Required Permission:** `chatbots.teams.create`\n\n**Resource:** `chatbots/:chatbotId`"}}},"components":{"schemas":{"CreateTeamRequestDto":{"type":"object","properties":{"name":{"type":"string","description":"The name of the new team."}},"required":["name"]},"TeamResponseDto":{"type":"object","properties":{"team":{"description":"The team.","nullable":true,"allOf":[{"$ref":"#/components/schemas/TeamDto"}]},"error":{"type":"string","description":"Optional error message."}},"required":["team"]},"TeamDto":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the team."},"name":{"type":"string","description":"The name of the team."},"created":{"type":"string","description":"Timestamp when the team was created."},"updated":{"type":"string","description":"Timestamp when the team was last updated."},"icon":{"type":"string","description":"The icon identifier for the team."},"userIds":{"description":"The list of user IDs that are members of the team.","type":"array","items":{"type":"string"}}},"required":["id","name","created","updated","icon","userIds"]}}}}
```

## Retrieves a specific team

> \
> \
> \*\*Required Permission:\*\* \`chatbots.teams.get\`\
> \
> \*\*Resource:\*\* \`chatbots/:chatbotId\`

```json
{"openapi":"3.0.0","info":{"title":"ChatCaptain API","version":"1.0"},"tags":[{"name":"Inbox teams","description":""}],"servers":[{"url":"https://api.chatcaptain.com","description":"Production"}],"security":[{},{}],"paths":{"/v1/inbox/{chatbotId}/teams/{teamId}":{"get":{"operationId":"InboxTeamsController_getTeam[1]_v1","parameters":[{"name":"chatbotId","required":true,"in":"path","description":"The ID of the chatbot.","schema":{"type":"string"}},{"name":"teamId","required":true,"in":"path","description":"The ID of the team to retrieve.","schema":{"type":"string"}}],"responses":{"200":{"description":"Details of the team.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponseDto"}}}},"403":{"description":"Insufficient permissions."}},"summary":"Retrieves a specific team","tags":["Inbox teams"],"description":"\n\n**Required Permission:** `chatbots.teams.get`\n\n**Resource:** `chatbots/:chatbotId`"}}},"components":{"schemas":{"TeamResponseDto":{"type":"object","properties":{"team":{"description":"The team.","nullable":true,"allOf":[{"$ref":"#/components/schemas/TeamDto"}]},"error":{"type":"string","description":"Optional error message."}},"required":["team"]},"TeamDto":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the team."},"name":{"type":"string","description":"The name of the team."},"created":{"type":"string","description":"Timestamp when the team was created."},"updated":{"type":"string","description":"Timestamp when the team was last updated."},"icon":{"type":"string","description":"The icon identifier for the team."},"userIds":{"description":"The list of user IDs that are members of the team.","type":"array","items":{"type":"string"}}},"required":["id","name","created","updated","icon","userIds"]}}}}
```

## Deletes a team

> \
> \
> \*\*Required Permission:\*\* \`chatbots.teams.delete\`\
> \
> \*\*Resource:\*\* \`chatbots/:chatbotId\`

```json
{"openapi":"3.0.0","info":{"title":"ChatCaptain API","version":"1.0"},"tags":[{"name":"Inbox teams","description":""}],"servers":[{"url":"https://api.chatcaptain.com","description":"Production"}],"security":[{},{}],"paths":{"/v1/inbox/{chatbotId}/teams/{teamId}":{"delete":{"operationId":"InboxTeamsController_deleteTeam[1]_v1","parameters":[{"name":"chatbotId","required":true,"in":"path","description":"The ID of the chatbot.","schema":{"type":"string"}},{"name":"teamId","required":true,"in":"path","description":"The ID of the team to delete.","schema":{"type":"string"}}],"responses":{"200":{"description":"Team deleted successfully."},"403":{"description":"Insufficient permissions."}},"summary":"Deletes a team","tags":["Inbox teams"],"description":"\n\n**Required Permission:** `chatbots.teams.delete`\n\n**Resource:** `chatbots/:chatbotId`"}}}}
```

## Updates an existing team

> \
> \
> \*\*Required Permission:\*\* \`chatbots.teams.edit\`\
> \
> \*\*Resource:\*\* \`chatbots/:chatbotId\`

```json
{"openapi":"3.0.0","info":{"title":"ChatCaptain API","version":"1.0"},"tags":[{"name":"Inbox teams","description":""}],"servers":[{"url":"https://api.chatcaptain.com","description":"Production"}],"security":[{},{}],"paths":{"/v1/inbox/{chatbotId}/teams/{teamId}":{"patch":{"operationId":"InboxTeamsController_updateTeam[1]_v1","parameters":[{"name":"chatbotId","required":true,"in":"path","description":"The ID of the chatbot.","schema":{"type":"string"}},{"name":"teamId","required":true,"in":"path","description":"The ID of the team to update.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateTeamRequestDto"}}}},"responses":{"200":{"description":"Team updated successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponseDto"}}}},"400":{"description":"Invalid input data."},"403":{"description":"Insufficient permissions."}},"summary":"Updates an existing team","tags":["Inbox teams"],"description":"\n\n**Required Permission:** `chatbots.teams.edit`\n\n**Resource:** `chatbots/:chatbotId`"}}},"components":{"schemas":{"UpdateTeamRequestDto":{"type":"object","properties":{"updated":{"description":"The object containing the fields to be updated.","allOf":[{"$ref":"#/components/schemas/UpdateTeamDto"}]}},"required":["updated"]},"UpdateTeamDto":{"type":"object","properties":{"userIds":{"description":"A list of user IDs that should be members of the team.","type":"array","items":{"type":"string"}},"name":{"type":"string","description":"The new name of the team."}},"required":["userIds"]},"TeamResponseDto":{"type":"object","properties":{"team":{"description":"The team.","nullable":true,"allOf":[{"$ref":"#/components/schemas/TeamDto"}]},"error":{"type":"string","description":"Optional error message."}},"required":["team"]},"TeamDto":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier of the team."},"name":{"type":"string","description":"The name of the team."},"created":{"type":"string","description":"Timestamp when the team was created."},"updated":{"type":"string","description":"Timestamp when the team was last updated."},"icon":{"type":"string","description":"The icon identifier for the team."},"userIds":{"description":"The list of user IDs that are members of the team.","type":"array","items":{"type":"string"}}},"required":["id","name","created","updated","icon","userIds"]}}}}
```
