Teams Service

The teams service allows users to create a team, which encapsulates a group of users. Once a team has been created, the owner of that team can add other users, using their ID's. Once a team has been created, and users have been added to a team, a team member can create an API Key for a specific team.

For now, only the owner of a team can create an API Key.

Example Payload - Create Team

POST /api/v1/teams

{
  "name": "my-team",
  "users": [
    "user-id-1",
    "user-id-2"
  ]
}

Example Payload - Add user to team

PUT /api/v1/teams/<team-id>

{
    "users": [
        "user-id-3"
    ]
}

Example Payload - Create API Key for a team

Note: if a team_id is included within the request body when creating an API key, the token service will check the teams service to ensure that the incoming owner_id, is the owner of that team.

POST /api/v1/tokens/teams/<team-id>

{
    "name": "new-api-key"
}

Last updated