Create a variable for a workspace
Create a workspace level variable.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}.
Request Body
Section titled “ Request Body ”The variable to create.
object
The UUID identifying the variable.
The unique name of the variable.
The value of the variable. If the variable is secured, this will be empty.
If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.
Example generated
{ "type": "example", "uuid": "example", "key": "example", "value": "example", "secured": true}Responses
Section titled “ Responses ”The created variable.
object
The UUID identifying the variable.
The unique name of the variable.
The value of the variable. If the variable is secured, this will be empty.
If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.
Example generated
{ "type": "example", "uuid": "example", "key": "example", "value": "example", "secured": true}Headers
Section titled “ Headers ”The URL of the newly created pipeline variable.
The workspace does not exist.
Base type for most resource objects. It defines the common type element that identifies an object’s type. It also identifies the element as Swagger’s discriminator.
object
object
Optional structured data that is endpoint-specific.
object
Example generated
{ "type": "example", "error": { "message": "example", "detail": "example", "data": {} }}A variable with the provided key already exists.
Base type for most resource objects. It defines the common type element that identifies an object’s type. It also identifies the element as Swagger’s discriminator.
object
object
Optional structured data that is endpoint-specific.
object
Example generated
{ "type": "example", "error": { "message": "example", "detail": "example", "data": {} }}