Environment Vars API
The environment vars API manages Errthquake environment variables and secrets. Variables and secrets can be created, queried, updated, and deleted thought the API. They can be referenced in test configuration files for use in load tests.
Permissions
Managing environment variables requires the Manage Environment Variables permission.
Managing secrets requires the Manage Secrets permission.
APIs
Vars List API
https://api.errthquake.com/vars/<workspace-uid>
GET returns
{
"env-vars": map{ <string: variable name">, <string: variable value> },
"secrets": map{ <string: variable name">, "********" }
}
Secret values are always referenced by ******** rather than displayed in plaintext.
PUT submits
{
"env-vars": map{ <string: variable name">, <string: variable value> },
"secrets": map{ <string: variable name">, "********" }
}
PUT returns
"workspace variables updated"
The PUT operation is additive -- variables and secrets can be added and replaced but it does not replace the entire set of variables and secrets.
The environment vars API does not implement a POST operation that replaces all variables and secrets.
DELETE submits
{
"env-vars": map{ <string: variable name">, null },
"secrets": map{ <string: variable name">, null }
}
DELETE returns
"workspace variables deleted"