Skip to main content
POST
/
team
/
upsert
Create or update a team
curl --request POST \
  --url 'https://api.flashcat.cloud/team/upsert?app_key=' \
  --header 'Content-Type: application/json' \
  --data '
{
  "team_name": "Backend SRE",
  "description": "Backend reliability engineering team",
  "person_ids": [
    80011,
    80012
  ]
}
'
{
  "request_id": "01HK8XQE3Z7JM2NTFQ5YJ8P9R4",
  "data": {
    "team_id": 1001,
    "team_name": "Backend SRE"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.flashcat.cloud/llms.txt

Use this file to discover all available pages before exploring further.

Restrictions

AspectValue
Rate limits1,000 requests/minute; 50 requests/second per account
PermissionsTeams Manage (organization)

Usage

  • Omit team_id (or set to 0) to create a new team; pass an existing ID to update.
  • team_name must be 1–39 characters and unique within the account.
  • Pass person_ids to set team membership; this replaces the entire member list.
  • Pass emails or phones to invite members who don’t yet have accounts.
  • ref_id is an external identifier for integration with third-party HR systems.
  • Every call is recorded in the account audit log. Don’t put secrets in request fields.

Authorizations

app_key
string
query
required

App key issued from the Flashduty console under Account → APP Keys. Required on every public API call. Keep it secret — it grants the same access as the owning account.

Body

application/json

Parameters for creating or updating a team.

team_name
string
required

Team display name. 1–39 characters.

Required string length: 1 - 39
team_id
integer<uint64>

Team ID. Omit or set to 0 to create a new team.

description
string

Free-form description.

Maximum string length: 500
person_ids
integer<uint64>[]

Member IDs to set as team members. Replaces the existing member list.

emails
string<email>[]

Email addresses to invite as members.

phones
string[]

Phone numbers to invite as members.

countryCode
string

Default country code applied to any phones entries that are not in E.164 format.

ref_id
string

External reference ID for HR system integration.

reset_if_name_exist
boolean

If true and a team with the same name already exists, reset its membership to the provided person_ids.

Response

Success

Success response envelope. On every 2xx response, request_id identifies the call (also mirrored in the Flashcat-Request-Id header) and data holds the endpoint-specific payload. Failure responses use a different shape — see ErrorResponse.

request_id
string
required

Unique ID for this request. Mirrored in the Flashcat-Request-Id response header. Include it when reporting issues.

Example:

"01HK8XQE3Z7JM2NTFQ5YJ8P9R4"

data
object
required

Team create/update result.