Skip to main content
POST
Create mapping schema

Restrictions

Usage

  • Schema names must be unique within an account.
  • source_labels (1–3 labels) are used as lookup keys; result_labels (1–10 labels) are the labels written on match.
  • Label names must match ^[a-zA-Z_][a-zA-Z0-9_]*$ and be unique within each list.
  • source_labels and result_labels must not overlap.
  • An account can have at most 20 mapping schemas.
  • 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
schema_name
string
required

Unique schema name (max 39 chars).

Maximum string length: 39
source_labels
string[]
required

Lookup key label names (1–3). Each must match ^[a-zA-Z_][a-zA-Z0-9_]*$; entries must be unique and must not overlap with result_labels.

Maximum array length: 3
Pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
result_labels
string[]
required

Output label names written on a match (1–10). Each must match ^[a-zA-Z_][a-zA-Z0-9_]*$; entries must be unique and must not overlap with source_labels.

Maximum array length: 10
Pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
description
string

Optional description (max 500 chars).

Maximum string length: 500
team_id
integer<int64>

Owning team ID. 0 means no team.

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

Endpoint-specific payload. See each operation's 200 response schema.