REST APIEnvironment
Create a write-only Project Environment variable
Authorization
ApiKey x-api-key<token>
Workspace-owned API key with per-resource permissions.
In: header
Path Parameters
id*string
Format
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
name*string
Length
1 <= length <= 128value*string
Length
length <= 5120kind?string
Default
"secret"Value in
- "secret"
- "plain"
preview*boolean
production*boolean
Response Body
application/json
application/json
curl -X POST "https://example.com/v1/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/environment" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "value": "string", "preview": true, "production": true }'{ "variables": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "kind": "secret", "preview": true, "production": true, "purpose": "string", "required": true, "version": -9007199254740991, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" } ], "preview": { "revision": 0, "appliedRevision": 0, "stale": true }, "production": { "revision": 0, "publishedRevision": 0, "pending": true }}