Kinde · Arazzo Workflow

Kinde Create Role with Permission

Version 1.0.0

Create a permission, create a role, and attach the permission to the role.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub AuthenticationAuthorizationCustomer IdentityIdentity ManagementOpenID ConnectSingle Sign-OnMulti-Factor AuthenticationRole-Based Access ControlFeature FlagsBillingB2BSoftware-as-a-ServiceDeveloper PlatformArazzoWorkflows

Provider

kinde

Workflows

create-role-with-permission
Create a permission and a role, then bind the permission to the role.
Creates a permission, resolves its id by listing permissions and matching on key, creates a role, and updates the role's permissions to include the resolved permission.
4 steps inputs: permissionDescription, permissionKey, permissionName, roleDescription, roleKey, roleName outputs: permissions, roleId
1
createPermission
Create the permission. The create endpoint returns a success envelope only, so the permission id is resolved in the next step.
2
resolvePermissionId
List permissions and locate the one whose key matches the permission just created so its id can be attached to the role.
3
createRole
Create the role that the permission will be attached to. Returns the new role's id.
4
attachPermission
Attach the resolved permission to the new role by submitting the permission id in the role permissions update.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Kinde Create Role with Permission
  summary: Create a permission, create a role, and attach the permission to the role.
  description: >-
    Builds out a tenant's access model from scratch. The workflow creates a new
    permission, lists permissions to resolve the newly created permission's id
    (the create endpoint returns only a success envelope), creates a new role,
    and finally attaches the resolved permission to the new role. Branching
    guards the case where the permission cannot be resolved. Every step inlines
    its request so the flow can be read and executed without opening the
    underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: permissionsApi
  url: ../openapi/kinde-permissions-api-openapi.yml
  type: openapi
- name: rolesApi
  url: ../openapi/kinde-roles-api-openapi.yml
  type: openapi
workflows:
- workflowId: create-role-with-permission
  summary: Create a permission and a role, then bind the permission to the role.
  description: >-
    Creates a permission, resolves its id by listing permissions and matching on
    key, creates a role, and updates the role's permissions to include the
    resolved permission.
  inputs:
    type: object
    required:
    - permissionName
    - permissionKey
    - roleName
    - roleKey
    properties:
      permissionName:
        type: string
        description: The display name of the permission to create.
      permissionKey:
        type: string
        description: The code-facing key for the permission (e.g. "create:invoices").
      permissionDescription:
        type: string
        description: Optional description of the permission.
      roleName:
        type: string
        description: The display name of the role to create.
      roleKey:
        type: string
        description: The code-facing key for the role (e.g. "billing_admin").
      roleDescription:
        type: string
        description: Optional description of the role.
  steps:
  - stepId: createPermission
    description: >-
      Create the permission. The create endpoint returns a success envelope
      only, so the permission id is resolved in the next step.
    operationId: CreatePermission
    requestBody:
      contentType: application/json
      payload:
        name: $inputs.permissionName
        key: $inputs.permissionKey
        description: $inputs.permissionDescription
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      createCode: $response.body#/code
  - stepId: resolvePermissionId
    description: >-
      List permissions and locate the one whose key matches the permission just
      created so its id can be attached to the role.
    operationId: GetPermissions
    parameters:
    - name: sort
      in: query
      value: name_asc
    - name: page_size
      in: query
      value: 100
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      permissions: $response.body#/permissions
    onSuccess:
    - name: permissionFound
      type: goto
      stepId: createRole
      criteria:
      - context: $response.body
        condition: $.permissions[?(@.key == '$inputs.permissionKey')].id
        type: jsonpath
  - stepId: createRole
    description: >-
      Create the role that the permission will be attached to. Returns the new
      role's id.
    operationId: CreateRole
    requestBody:
      contentType: application/json
      payload:
        name: $inputs.roleName
        key: $inputs.roleKey
        description: $inputs.roleDescription
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      roleId: $response.body#/role/id
  - stepId: attachPermission
    description: >-
      Attach the resolved permission to the new role by submitting the
      permission id in the role permissions update.
    operationId: UpdateRolePermissions
    parameters:
    - name: role_id
      in: path
      value: $steps.createRole.outputs.roleId
    requestBody:
      contentType: application/json
      payload:
        permissions:
        - id: $steps.resolvePermissionId.outputs.permissions[?(@.key == '$inputs.permissionKey')].id
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      updateCode: $response.body#/code
  outputs:
    roleId: $steps.createRole.outputs.roleId
    permissions: $steps.resolvePermissionId.outputs.permissions

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • 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.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/kinde-create-role-with-permission-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

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.