CentralCSP
APIWebsite Access

Grant a member access

Gives a workspace member a role on this website, replacing any role granted to them directly. If a group also grants them a role, the higher role applies.

Requires the admin role on the website.

PUT
/v1/workspaces/{workspaceId}/websites/{websiteId}/access/members/{memberId}

Authorization

headerAuthorizationBearer <JWT>

An OpenID Connect access token from signing in to CentralCSP, acting as the signed-in user.

Path Parameters

workspaceId*string

The workspace's id.

websiteId*string

The website's id.

memberId*string

The membership the grant is for.

Request Body

application/json
  1. body

The role to grant.

role*WebsiteRole

What someone may do with a website. viewer reads reports and settings. analyst also decides on scripts under review. manager also changes the website's configuration. admin also manages access and deletes the website.

Value in"viewer""analyst""manager""admin"

Response Body

The member's role on the website is set.

Example Request
curl -X PUT 'https://api.centralcsp.com/v1/workspaces/01936b7a-6f2e-7c31-9a4d-2f8e1c5b7d90/websites/01936b7a-6f2e-7c31-9a4d-2f8e1c5b7d90/access/members/01936b7a-6f2e-7c31-9a4d-2f8e1c5b7d90' \  -H 'Content-Type: application/json' \  -d '{  "role": "viewer"}'
Example Response
Empty