Stage a new role into a change request
POST
/api/v1/projects/{projectId}/roles
const url = 'https://app.avera.io/api/v1/projects/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/roles?sandboxId=example';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"name":"example","description":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url 'https://app.avera.io/api/v1/projects/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/roles?sandboxId=example' \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "description": "example" }'The change is staged into the change request named by sandboxId and applies only at promotion. Project-admin gated.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”projectId
required
string format: uuid
Query Parameters
Section titled “Query Parameters”sandboxId
required
string
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
required
string
description
string | null
Example generated
{ "name": "example", "description": "example"}Responses
Section titled “Responses”OK
Media type*/*
object
id
required
string
name
required
string
description
string | null
builtIn
required
boolean
createdAt
required
string format: date-time
modifiedAt
required
string format: date-time