Return environment properties#
Description#
Return properties for an environment in a workspace with the provided IDs, or a 404 if no such workspace is found.
GET /v1/metadata/workspace/{workspace_id}/environment/{environment_id}
Parameters#
Parameter |
In |
Type |
Required |
Description |
|---|---|---|---|---|
workspace_id |
path |
string |
true |
The ID of the Workspace. |
environment_id |
path |
string |
true |
The ID of the Environment. |
Code Samples#
curl -X GET https://h.app.wdesk.com/s/wdata/oc/api/v1/metadata/workspace/{workspace_id}/environment/{environment_id} \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}'
http GET https://h.app.wdesk.com/s/wdata/oc/api/v1/metadata/workspace/{workspace_id}/environment/{environment_id} \
Accept:application/json \
Authorization:"Bearer {access-token}"
wget --method=GET "https://h.app.wdesk.com/s/wdata/oc/api/v1/metadata/workspace/{workspace_id}/environment/{environment_id}" \
--output-document - \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}'
import requests
headers = {
'Accept': 'application/json',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://h.app.wdesk.com/s/wdata/oc/api/v1/metadata/workspace/{workspace_id}/environment/{environment_id}', headers = headers)
print(r.json())
Returns#
200 - OK#
Returns an EnvironmentResponse containing an Environment object that matches the provided workspace_id and environment_id.
Example Responses#
{
"data": {
"id": "1",
"name": "string",
"description": "string",
"position": 0,
"color": "#3CB702",
"chains_count": 0,
"variables": [
{
"key": "environment",
"label": "Environment",
"defaultValue": "",
"value": "Testing",
"encrypted": true
}
],
"settings": {
"color": "#3CB702"
},
"created_at": "2018-03-14 20:10:39.520585",
"updated_at": "2018-03-14 20:10:39.520585"
}
}