List grants
GET
/v1/workspaces/{workspaceId}/grants
const url = 'https://shareout.site/v1/workspaces/example/grants?resource_type=folder';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://shareout.site/v1/workspaces/example/grants?resource_type=folder' \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” workspaceId
required
string
Workspace ID or slug.
Query Parameters
Section titled “Query Parameters ” subject_id
string
resource_type
string
resource_id
string
Responses
Section titled “ Responses ”Grants
Media type application/json
object
grants
Array<object>
object
id
string
subject_type
string
subject_id
string
resource_type
string
resource_id
string
capability
string
Example
{ "grants": [ { "subject_type": "sharee", "resource_type": "folder", "capability": "view" } ]}