Skip to content

Register (or rotate) the tenant's OTA channel — Bokun keys + activity map

POST
/tenants/channels
curl --request POST \
--url https://quikstik-core.fly.dev/tenants/channels \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "channel": "bokun", "access_key": "example", "secret_key": "example", "activities": { "1005527": "R1", "1005528": "T1" }, "poll_window_days": 1, "publishable_key": "example" }'

Operator-scoped, authoritative registration of the tenant’s availability-syndication channel (per-tenant channel registry, PR B). The access/secret key pair is sealed into the per-tenant credential vault (never stored in clear, never echoed, never on the event); the registry row carries the Bokun activity id -> core product id map and the poll window. Re-registering rotates the credential and replaces the activity map whole. Only channel: bokun is admitted today.

Media typeapplication/json
object
channel
required
string
Allowed values: bokun
access_key
required
string
>= 1 characters
secret_key
required
string
>= 1 characters
activities
required

Bokun activity id (as a JSON key) -> core catalog product id.

object
>= 1 properties
key
additional properties
string
>= 1 characters

Example

{
"1005527": "R1",
"1005528": "T1"
}
poll_window_days

Days ahead the poller walks; omitted = the poller’s default.

integer
nullable >= 1
publishable_key

The tenant’s storefront publishable key (x-api-key on /availability/snapshot-requests), used by the allocator’s consumer-surface check. Public by design (it ships in the storefront widget), so it lives in the channel config, not the vault. Omitted = the allocator falls back to its env key, else skips the check. Present-but-blank is refused.

string
nullable >= 1 characters

Channel registered; keys sealed. Never echoes key material.

Media typeapplication/json
object
tenant_id
required
string format: uuid
channel
required
string
Allowed values: bokun
status
required
string
Allowed values: active disabled
credential_version

The vault rotation counter the keys were sealed under; null on disable.

integer
nullable

Example

{
"channel": "bokun",
"status": "active"
}

Malformed registration (unknown channel, blank key, empty activities, blank product id, zero poll window, blank publishable key).

Backend unavailable.