Skip to content

SitesClient

View as Markdown
get(projectId, siteId): Promise<Site>;
Signature
Parameter Type
projectId string
siteId string

Promise<Site>

GET /v1/projects/:projectId/sites/:siteId


list(projectId, filter?): Promise<SiteCollectionPage>;
Signature
Parameter Type
projectId string
filter? { cursor?: string; includeUnregistered?: boolean; limit?: number; }
filter.cursor? string
filter.includeUnregistered? boolean
filter.limit? number

Promise<SiteCollectionPage>

GET /v1/projects/:projectId/sites


newEnrollmentCode(
projectId,
siteId,
options?
): Promise<SiteEnrollmentCode>;
Signature

A new one-time code: the site's next key replaces every key it has, and its live sessions end.

Parameter Type
projectId string
siteId string
options? Idempotent

Promise<SiteEnrollmentCode>

POST /v1/projects/:projectId/sites/:siteId/enrollment-codes


pause(
projectId,
siteId,
options?
): Promise<Site>;
Signature

Stops the site's sign-ins, and ends its live sessions.

Parameter Type
projectId string
siteId string
options? Idempotent

Promise<Site>

POST /v1/projects/:projectId/sites/:siteId/pause


register(
projectId,
body,
options?
): Promise<RegisterSiteResult>;
Signature

The site, and its one-time enrollment code: give the code to the site, which posts it with its public key.

Parameter Type
projectId string
body RegisterSiteBody
options? Idempotent

Promise<RegisterSiteResult>

POST /v1/projects/:projectId/sites


restorePerson(
projectId,
siteId,
userId,
options?
): Promise<SitePersonRestoreResult>;
Signature

Let one of the site's people removed in Kindgi back in, while the site still knows them: the same person, with their history. Their grants come back the next time the site signs them in. Someone the site said left stays gone: if they come back, it signs them in as a new person.

Parameter Type
projectId string
siteId string
userId string
options? Idempotent

Promise<SitePersonRestoreResult>

POST /v1/projects/:projectId/sites/:siteId/people/:userId/restore


resume(
projectId,
siteId,
options?
): Promise<Site>;
Signature
Parameter Type
projectId string
siteId string
options? Idempotent

Promise<Site>

POST /v1/projects/:projectId/sites/:siteId/resume


revokeKey(
projectId,
siteId,
kid,
options?
): Promise<Site>;
Signature
Parameter Type
projectId string
siteId string
kid string
options? Idempotent

Promise<Site>

POST /v1/projects/:projectId/sites/:siteId/keys/:kid/revoke


unregister(
projectId,
siteId,
options?
): Promise<Site>;
Signature
Parameter Type
projectId string
siteId string
options? Idempotent

Promise<Site>

POST /v1/projects/:projectId/sites/:siteId/unregister


update(
projectId,
siteId,
body,
options?
): Promise<Site>;
Signature
Parameter Type
projectId string
siteId string
body UpdateSiteBody
options? Idempotent

Promise<Site>

PATCH /v1/projects/:projectId/sites/:siteId