Polytomic subpackage_permissions.subpackage_permissions/roles API
The subpackage_permissions.subpackage_permissions/roles API from Polytomic — 2 operation(s) for subpackage_permissions.subpackage_permissions/roles.
The subpackage_permissions.subpackage_permissions/roles API from Polytomic — 2 operation(s) for subpackage_permissions.subpackage_permissions/roles.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/polytomic-subpackage-permissions-subpackage-permissions-roles-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Reference subpackage_bulkSync Subpackage Permissions.subpackage Permissions/roles API
version: 1.0.0
servers:
- url: https://app.polytomic.com
tags:
- name: subpackage_permissions.subpackage_permissions/roles
paths:
/api/permissions/roles:
get:
operationId: list
summary: List Roles
description: 'Lists all permissions roles available in the caller''s organization, including built-in system roles.
System roles such as Admin and Member are always present in every organization
and cannot be modified or deleted. Custom roles appear alongside them and can
be created, updated, or removed as needed.
To inspect or modify a specific role, use
[`GET /api/permissions/roles/{id}`](../../../api-reference/permissions/roles/get).'
tags:
- subpackage_permissions.subpackage_permissions/roles
parameters:
- name: Authorization
in: header
description: Bearer user API key
required: true
schema:
type: string
- name: X-Polytomic-Version
in: header
required: false
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/RoleListResponseEnvelope'
'500':
description: Internal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
post:
operationId: create
summary: Create Role
description: 'Creates a new permissions role.
Provide a `name` for the new role. The role is immediately available for use
in permission policies.
To attach the role to resources, create or update a policy using
[`POST /api/permissions/policies`](../../../api-reference/permissions/policies/create).'
tags:
- subpackage_permissions.subpackage_permissions/roles
parameters:
- name: Authorization
in: header
description: Bearer user API key
required: true
schema:
type: string
- name: X-Polytomic-Version
in: header
required: false
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/RoleResponseEnvelope'
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'404':
description: Not Found
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'500':
description: Internal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRoleRequest'
/api/permissions/roles/{id}:
get:
operationId: get
summary: Get Role
description: 'Returns a single permissions role by ID.
Returns the role''s name, action set, and whether it is a built-in system role.'
tags:
- subpackage_permissions.subpackage_permissions/roles
parameters:
- name: id
in: path
required: true
schema:
type: string
format: uuid
- name: Authorization
in: header
description: Bearer user API key
required: true
schema:
type: string
- name: X-Polytomic-Version
in: header
required: false
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/RoleResponseEnvelope'
'404':
description: Not Found
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
put:
operationId: update
summary: Update Role
description: 'Updates an existing permissions role''s name and action set.
The update is a **full replacement** of the role definition.
> 🚧 Built-in system roles (such as Admin and Member) cannot be updated.
> Attempting to modify a system role returns an error.'
tags:
- subpackage_permissions.subpackage_permissions/roles
parameters:
- name: id
in: path
required: true
schema:
type: string
format: uuid
- name: Authorization
in: header
description: Bearer user API key
required: true
schema:
type: string
- name: X-Polytomic-Version
in: header
required: false
schema:
type: string
responses:
'200':
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/RoleResponseEnvelope'
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'404':
description: Not Found
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'500':
description: Internal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateRoleRequest'
delete:
operationId: delete
summary: Delete Role
description: 'Deletes a permissions role.
> 🚧 Built-in system roles (such as Admin and Member) cannot be deleted.
> Attempting to delete a system role returns an error.
Deleting a role does not automatically remove it from any policies that
reference it. Update those policies separately using
[`PUT /api/permissions/policies/{id}`](../../../../api-reference/permissions/policies/update) to avoid
leaving stale role references.'
tags:
- subpackage_permissions.subpackage_permissions/roles
parameters:
- name: id
in: path
required: true
schema:
type: string
format: uuid
- name: Authorization
in: header
description: Bearer user API key
required: true
schema:
type: string
- name: X-Polytomic-Version
in: header
required: false
schema:
type: string
responses:
'200':
description: Successful response
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'404':
description: Not Found
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
'500':
description: Internal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/ApiError'
components:
schemas:
UpdateRoleRequest:
type: object
properties:
name:
type: string
organization_id:
type:
- string
- 'null'
format: uuid
required:
- name
title: UpdateRoleRequest
RoleResponseEnvelope:
type: object
properties:
data:
$ref: '#/components/schemas/RoleResponse'
title: RoleResponseEnvelope
RoleResponse:
type: object
properties:
id:
type: string
format: uuid
name:
type: string
organization_id:
type: string
format: uuid
system:
type: boolean
title: RoleResponse
RoleListResponseEnvelope:
type: object
properties:
data:
type:
- array
- 'null'
items:
$ref: '#/components/schemas/RoleResponse'
title: RoleListResponseEnvelope
ApiError:
type: object
properties:
key:
type: string
message:
type: string
metadata:
type: object
additionalProperties:
description: Any type
status:
type: integer
title: ApiError
CreateRoleRequest:
type: object
properties:
name:
type: string
organization_id:
type:
- string
- 'null'
format: uuid
required:
- name
title: CreateRoleRequest
securitySchemes:
bearerUserAPIKey:
type: http
scheme: bearer
description: Bearer user API key
orgScopedAPIKey:
type: http
scheme: basic
description: Basic organization-scoped API key
bearerPartnerKey:
type: http
scheme: bearer
description: Bearer partner API key