Custom roles

Get custom role

GET
/api/v2/roles/{customRoleKey}

Get a single custom role by key or ID

Authorization

ApiKey read, write
Authorization<token>

In: header

Scope: read, write

Path Parameters

customRoleKey*string

The custom role key or ID

Formatstring

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v2/roles/string"
{  "_id": "1234a56b7c89d012345e678f",  "_links": {    "property1": {      "href": "string",      "type": "string"    },    "property2": {      "href": "string",      "type": "string"    }  },  "_access": {    "denied": [      {        "action": "string",        "reason": {          "resources": [            "proj/*:env/*;qa_*:/flag/*"          ],          "notResources": [            "string"          ],          "actions": [            "*"          ],          "notActions": [            "string"          ],          "effect": "allow",          "role_name": "string"        }      }    ],    "allowed": [      {        "action": "string",        "reason": {          "resources": [            "proj/*:env/*;qa_*:/flag/*"          ],          "notResources": [            "string"          ],          "actions": [            "*"          ],          "notActions": [            "string"          ],          "effect": "allow",          "role_name": "string"        }      }    ]  },  "description": "This custom role is just an example",  "key": "example-custom-role",  "name": "Example custom role",  "policy": [    {      "resources": [        "proj/*:env/*;qa_*:/flag/*"      ],      "notResources": [        "string"      ],      "actions": [        "*"      ],      "notActions": [        "string"      ],      "effect": "allow"    }  ],  "basePermissions": "reader",  "resourceCategory": "string",  "assignedTo": {    "membersCount": 0,    "teamsCount": 0  },  "_presetBundleVersion": 0,  "_presetStatements": [    {      "resources": [        "proj/*:env/*;qa_*:/flag/*"      ],      "notResources": [        "string"      ],      "actions": [        "*"      ],      "notActions": [        "string"      ],      "effect": "allow"    }  ]}