# Update a team's members

You can replace the set of teammates who belong to a team. Send the full list of
teammates the team should end up with — any teammate currently on the team and
missing from the list is removed. This makes the endpoint safe to call on a
schedule to keep Intercom in step with an external rota or workforce management
system, since sending an unchanged list makes no changes at all.
A token that acts on behalf of a teammate carries that teammate's permissions:
they must be able to manage teams, and any team or teammate their access is
restricted from remains out of reach here.

Endpoint: PUT /teams/{id}
Version: Preview
Security: bearerAuth

## Path parameters:

  - `id` (string, required)
    The unique identifier of a given team.

## Header parameters:

  - `Intercom-Version` (string)

## Request fields (application/json):

  - `admin_ids` (array, required)
    The ids of every teammate who should be a member of the team. Must contain at least one id, and no more than 1000.
    Example: [493881,493882]

  - `admin_priority_level` (object)
    Admin priority levels for the team

  - `admin_priority_level.primary_admin_ids` (array)
    The primary admin ids for the team
    Example: [493881]

  - `admin_priority_level.secondary_admin_ids` (array)
    The secondary admin ids for the team
    Example: [814865]

## Response 200 fields (application/json):

  - `type` (string)
    Value is always "team"
    Example: team

  - `id` (string)
    The id of the team
    Example: 814865

  - `name` (string)
    The name of the team
    Example: Example Team

  - `admin_ids` (array)
    The list of admin IDs that are a part of the team.
    Example: [493881]

  - `admin_priority_level` (object)
    Admin priority levels for the team

  - `admin_priority_level.primary_admin_ids` (array)
    The primary admin ids for the team
    Example: [493881]

  - `admin_priority_level.secondary_admin_ids` (array)
    The secondary admin ids for the team
    Example: [814865]

## Response 400 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 401 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 403 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 404 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

## Response 409 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

