Chelabase
ManagementMembers

Narrow a member's grant on one database

PUT
/v1/projects/{id}/grants/{member_id}/overrides

An override only narrows: its role is at most the grant's, its roles some of the grant's (any roles for an admin grant, which holds every role: the member keeps only those there, with the owner while still admin). Narrowing below admin takes the database owner away there, and the roles left must pass the same checks as a grant below admin. Every branch of the project then reconciles its member roles.

Authorization

bearer
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Project id

Formatuuid
member_id*string

Member id

Formatuuid

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

database_id*DatabaseId

A database of this project.

Formatuuid
pg_roles?array<string>|

Some of the grant's roles.

platform_role?|null

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X PUT "https://example.com/v1/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/grants/497f6eca-6276-4993-bfeb-53cbbbba6f08/overrides" \  -H "Content-Type: application/json" \  -d '{    "database_id": "91088904-0b92-46ad-9240-e1afa0da22df"  }'
{  "database_id": "91088904-0b92-46ad-9240-e1afa0da22df",  "pg_roles": [    "string"  ],  "platform_role": "viewer"}