Skip to main content
POST
Extend a gate's window

Authorizations

Authorization
string
header
required

Your secret server API key (bs_dev_… or bs_production_…) with Gates API access: the gates:write scope, granted in the Console under Settings → Developer Tools → API Keys. Without it every Gates API call answers gates_scope_required. The organization and environment always come from the key. Site keys are refused.

Body

application/json
key
string
required

The key of the gate to extend.

Pattern: ^[a-z0-9][a-z0-9_-]{0,63}$
Example:

"presale-nyc-1120"

closesAt
string<date-time>
required

The new closing time (ISO 8601). Must be later than the gate's current closing time.

Example:

"2026-11-21T04:00:00Z"

Response

Extended. NOTE: handler errors also arrive here (HTTP 200) as data.error — codes: invalid_key (401), gates_scope_required (403), org_not_found (404), gate_not_found (404 — no draft or active gate holds this key), extend_only (400 — closesAt is not later than now set), invalid_closes_at (400), gate_closed (409 — the window has already passed), gate_has_no_end (409), conflict (409 — the gate changed at the same moment; read and retry).

data
object
required