Set a member's site access
const url = 'https://api.overwatch.weareheavy.dev/v1/members/example/access';const options = { method: 'PATCH', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"siteIds":["0a1b2c3d-4e5f-6071-8293-a4b5c6d7e8f9"],"canCrawl":false}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://api.overwatch.weareheavy.dev/v1/members/example/access \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "siteIds": [ "0a1b2c3d-4e5f-6071-8293-a4b5c6d7e8f9" ], "canCrawl": false }'Set a restricted member’s per-site access allowlist and/or their crawl
grant. siteIds: [] revokes all site access (members are default-deny).
Role changes and removal have their own endpoints. Session-only,
owner/admin.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The member’s id (from GET /v1/members).
Request Bodyrequired
Section titled “ Request Bodyrequired ”object
The sites the member may see. [] revokes all access.
Whether the member may trigger manual crawls.
Example
{ "siteIds": [ "0a1b2c3d-4e5f-6071-8293-a4b5c6d7e8f9" ], "canCrawl": false}Responses
Section titled “ Responses ”The grants were updated.
object
Example
{ "ok": true}siteIds is not an array or names a site the organization doesn’t own.
object
A human-readable error message.
Examplegenerated
{ "error": "example"}Missing or invalid credentials.
object
A human-readable error message.
Example
{ "error": "invalid api key"}A dashboard session is required (API-key callers are rejected), or the session’s role does not allow this action.
object
A human-readable error message.
Example
{ "error": "a dashboard session is required"}No member with that id exists in your organization.
object
A human-readable error message.
Example
{ "error": "member not found"}