Liftbay
API referenceEnvironments

Create a variable

POST
/v1/orgs/{org}/projects/{project}/environments/{env}/variables

Authorization

cookielb_session<token>

Dashboard session cookie, set by the sign-in endpoints.

Path Parameters

org*string

Organization slug

project*string

Project slug

env*string

Environment slug

Request Body

application/json
  1. body
key*string
Match^[A-Z_][A-Z0-9_]*$
Length1 <= length <= 128
value*string
Lengthlength <= 32768
visibility*Visibility
Value in"plain""sensitive""secret"

Response Body

Created

application/json
  1. response
id*string
key*string
visibility*Visibility
Value in"plain""sensitive""secret"
value*string|null
updatedAt*string
updatedBy*string
curl -X POST "https://example.com/v1/orgs/string/projects/string/environments/string/variables" \  -H "Content-Type: application/json" \  -d '{    "key": "string",    "value": "string",    "visibility": "plain"  }'
{  "id": "string",  "key": "string",  "visibility": "plain",  "value": "string",  "updatedAt": "string",  "updatedBy": "string"}