K8 HQ

Pending changes — K8 HQ Sign-in API

Pending changes operations for K8 HQ Sign-in API. Requests, permissions and responses.

Version 1OpenAPI description (JSON)

Browse operation groups

Before making requests, read the authentication and request requirements.

Changes to people that wait for an owner: list them, approve, decline or cancel.

Base URL

Base URLFor
https://api.k8hq.com/authThe K8 HQ web app, and programs acting with a person's session

Endpoints

Pending changes

Approve a change

POST/v1/changes/approve

An owner approves a pending change, which is applied now (or fails, and is marked so, if the organization changed meanwhile). Approving a removal that would leave boards without a full member gives the approving owner full access to them: the 401 confirmation_required answer lists boards and ownerMemberId (the approver) as removing a member does, and the confirmation is always needed then. Zero-access boards are listed but not handed over. A changed list needs a fresh confirmation (409 confirmation_mismatch); the change stays pending.

Needs a passkey confirmation of this change (x-k8hq-confirm: change.approve). Until confirmations are enforced, a passkey sign-in in the last five minutes also works.

For a person's own session (x-k8hq-token) only: assistants' delegated tokens and API tokens are refused. The session needs a recent passkey: if its last passkey confirmation is more than 5 minutes old, the answer is 401 step_up_required.

Parameters

NameTypeDescription
x-amz-content-sha256 (header) requiredstringThe body's SHA-256, lowercase hex. CloudFront signs requests to this service and refuses a POST without it (403, not a problem detail). For {}: 44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a.

Request body (JSON)

FieldTypeDescription
id requiredstring
orgId requiredstringThe organization (org_...). Pattern: ^org_.
{"id":"chg_01J...","orgId":"org_01J..."}

Response body (JSON)

FieldTypeDescription
ok requiredtrue

Responses

StatusBodyMeaning
200OkApplied.
400application/problem+jsonThe request is malformed or a field is invalid (invalid).
401application/problem+jsonNo session or it expired (unauthenticated), or confirm this change with your passkey (confirmation_required; until confirmations are enforced, step_up_required with action, which a passkey use in the last 5 minutes also satisfies): the answer carries the action to confirm and a short summary.
403application/problem+jsonTheir role or permissions don't allow it (forbidden); or a delegated token or foreign origin; or the confirmation isn't this session's (confirmation_invalid), or an API token or assistant asked (needs_person).
404application/problem+jsonThey aren't a member of the organization (not_found).
409application/problem+jsonIt isn't pending any more, or can't be applied now, or who can do what in the organization changed while this ran: reload and try again (conflict).
500application/problem+jsonA temporary problem (unavailable); retry.

Decline or cancel a change

POST/v1/changes/decline

Owners decline a pending change; whoever asked for it may cancel it.

For a person's own session (x-k8hq-token) only: assistants' delegated tokens and API tokens are refused.

Parameters

NameTypeDescription
x-amz-content-sha256 (header) requiredstringThe body's SHA-256, lowercase hex. CloudFront signs requests to this service and refuses a POST without it (403, not a problem detail). For {}: 44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a.

Request body (JSON)

FieldTypeDescription
id requiredstring
orgId requiredstringThe organization (org_...). Pattern: ^org_.
{"id":"chg_01J...","orgId":"org_01J..."}

Response body (JSON)

FieldTypeDescription
ok requiredtrue

Responses

StatusBodyMeaning
200OkDeclined.
400application/problem+jsonThe request is malformed or a field is invalid (invalid).
401application/problem+jsonNo session, or it expired or was revoked (unauthenticated): refresh, or sign in again.
403application/problem+jsonTheir role or permissions don't allow it (forbidden); or a delegated token or foreign origin.
404application/problem+jsonThey aren't a member of the organization (not_found).
409application/problem+jsonIt isn't pending any more, or who can do what in the organization changed while this ran: reload and try again (conflict).
500application/problem+jsonA temporary problem (unavailable); retry.

List pending changes

GET/v1/organizations/{orgId}/changes

Changes to people waiting for an owner: all of them for owners, the caller's own requests for others.

For a person's own session (x-k8hq-token), or K8 Admin's delegated token in the organization it was made for.

Parameters

NameTypeDescription
orgId (path) requiredstringOrganization ID.

Response body (JSON)

FieldTypeDescription
changes requiredChange[]

Responses

StatusBodyMeaning
200JSONThe changes.
400application/problem+jsonThe request is malformed or a field is invalid (invalid).
401application/problem+jsonNo session, or it expired or was revoked (unauthenticated): refresh, or sign in again.
403application/problem+jsonTheir role or permissions don't allow it (forbidden); or a delegated token or foreign origin.
404application/problem+jsonThey aren't a member of the organization (not_found).
405application/problem+jsonMethod not allowed. The Allow header lists supported methods.
500application/problem+jsonA temporary problem (unavailable); retry.
503application/problem+jsonWhether K8 is available couldn't be checked (unavailable); retry.