List the tenant's policy documents (all scopes, all versions)
const url = 'https://quikstik-core.fly.dev/policies';const options = { method: 'GET', headers: { 'x-tenant-id': '2489E9AD-2EE2-8E00-8EC9-32D5F69181C0', Authorization: 'Bearer <token>' }};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://quikstik-core.fly.dev/policies \ --header 'Authorization: Bearer <token>' \ --header 'x-tenant-id: 2489E9AD-2EE2-8E00-8EC9-32D5F69181C0'Every document version the tenant has set — live (live: true) and retired — newest version
first within each scope. Auth: a staff session, or an operator key scoped bookings.read.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Tenant identifier (UUID).
Authn/authz semantics are intentionally TBD for this contract slice; this header exists to keep the contract explicitly multi-tenant from day 0.
Responses
Section titled “Responses”The documents
object
object
A scope’s partial policy: every rule optional, absent = inherit. operator_cancel is not settable (the server refuses a document that names it). governs is for channel scope only.
object
Tiers are most-notice-first; the most generous qualifying tier applies, else below.
object
object
One rule’s verdict. For a cancel, refund_all/no_refund/refund are the refund fraction; for a reschedule refund_all means a free change and no_refund means not allowed. ota_governed is produced by resolution for a booking whose channel governs it and is never stored in a document. refund carries bps; fee carries fee.
object
none as the inner fee of a fee outcome means “use the policy’s own fee”. flat carries minor + currency; percent carries bps; keep_deposit carries nothing.
object
object
object
One rule’s verdict. For a cancel, refund_all/no_refund/refund are the refund fraction; for a reschedule refund_all means a free change and no_refund means not allowed. ota_governed is produced by resolution for a booking whose channel governs it and is never stored in a document. refund carries bps; fee carries fee.
object
none as the inner fee of a fee outcome means “use the policy’s own fee”. flat carries minor + currency; percent carries bps; keep_deposit carries nothing.
object
One rule’s verdict. For a cancel, refund_all/no_refund/refund are the refund fraction; for a reschedule refund_all means a free change and no_refund means not allowed. ota_governed is produced by resolution for a booking whose channel governs it and is never stored in a document. refund carries bps; fee carries fee.
object
none as the inner fee of a fee outcome means “use the policy’s own fee”. flat carries minor + currency; percent carries bps; keep_deposit carries nothing.
object
none as the inner fee of a fee outcome means “use the policy’s own fee”. flat carries minor + currency; percent carries bps; keep_deposit carries nothing.
object
object
object
One rule’s verdict. For a cancel, refund_all/no_refund/refund are the refund fraction; for a reschedule refund_all means a free change and no_refund means not allowed. ota_governed is produced by resolution for a booking whose channel governs it and is never stored in a document. refund carries bps; fee carries fee.
object
none as the inner fee of a fee outcome means “use the policy’s own fee”. flat carries minor + currency; percent carries bps; keep_deposit carries nothing.
object
object
Rendering hints only; the full page renders from the rules.
object
Example
{ "policies": [ { "scope_kind": "tenant", "rules": { "cancel": { "below": { "kind": "refund_all", "fee": { "kind": "none", "currency": "USD" } } }, "reschedule": { "tiers": [ { "outcome": { "kind": "refund_all", "fee": { "kind": "none", "currency": "USD" } } } ], "below": { "kind": "refund_all", "fee": { "kind": "none", "currency": "USD" } } }, "fee": { "kind": "none", "currency": "USD" }, "refund_as": { "kind": "money" }, "weather": { "kind": "none", "outcome": "full_refund_or_rebook" }, "no_show": { "kind": "refund_all", "fee": { "kind": "none", "currency": "USD" } }, "overrides": { "waiver_reasons": [ "hardship" ] } } } ]}No durable backend is wired for this operation (fail-closed)
object
Stable, machine-readable reason code (e.g. “sold_out”, “processor_not_configured”, “rail_refused”).
Example
{ "reason": "sold_out"}