# Promote a custom-activity property

`POST /v1/activity-properties`

- Authentication: required (Bearer token)
- Required scope: `api.activities.manage`

Promotes a custom-activity property into the evaluable registry — registering
`(activity_name, property_name)` → type so a Segment's SendQL predicate can
reference it as `activity.<activity>.<property>`. `enum_values` is required when
`type` is `enum` and rejected otherwise. An invalid name or type, or exceeding
the per-activity promoted-property cap, returns `422 validation_failed`.

## Request body

Content type: `application/json`

```json
{
  "activity_name": "string",
  "property_name": "string",
  "type": "string",
  "enum_values": [
    "string"
  ],
  "description": "string"
}
```

## Example request

```bash
curl -X POST 'https://api.sendops.dev/v1/activity-properties' \
  -H "Authorization: Bearer $SENDOPS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"activity_name":"string","property_name":"string","type":"string","enum_values":["string"],"description":"string"}'
```

## Responses

### 201 — The promoted activity-property definition

Content type: `application/json`

```json
{
  "id": "00000000-0000-0000-0000-000000000000",
  "activity_name": "string",
  "property_name": "string",
  "type": "string",
  "enum_values": [
    "string"
  ],
  "description": "string",
  "origin": "managed",
  "source_path": "string",
  "last_synced_at": "2026-05-17T20:00:00Z",
  "created_at": "2026-05-17T20:00:00Z",
  "updated_at": "2026-05-17T20:00:00Z"
}
```

### 401 — Missing, malformed, or unknown API key

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```

### 403 — Key lacks the required scope or plan limit violated

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```

### 409 — The mutation is rejected by a state rule rather than a bad request — e.g.
editing a git-backed (read-only) definition. The `code` is `conflict`.

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```

### 422 — Query parameter or path value failed validation

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```

### 429 — Per-org rate limit exceeded

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```

### 500 — Unexpected server-side failure. The `code` is `internal_error`. The
`request_id` field can be quoted to SendOps support to investigate.

Content type: `application/problem+json`

```json
{
  "type": "https://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "invalid_key",
  "request_id": "string",
  "retry_after": 0,
  "retention_days": 0,
  "scope": "string",
  "resource": "string",
  "errors": [
    {
      "field": "string",
      "reason": "string"
    }
  ]
}
```
