Home
Version 3
Apps API

Apps API

Get the env for an App

GET /v2/apps/:guid/env

Get the environment variables for an App using the app guid. Restricted to SpaceDeveloper role.

Request

Route

GET /v2/apps/bbb2df0a-ed7f-43a3-bd6b-fbfa3169a760/env

Parameters

Name Description Valid Values Example Values
guid The guid of the App

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE2MyIsImVtYWlsIjoiZW1haWwtOTZAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ0MjYwMTUzMn0.jfZisq3op4TjPG8bI14Y5sSzY_l21rDF1n-KMnERQ8w
Host: example.org
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/apps/bbb2df0a-ed7f-43a3-bd6b-fbfa3169a760/env" -X GET \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTE2MyIsImVtYWlsIjoiZW1haWwtOTZAc29tZWRvbWFpbi5jb20iLCJzY29wZSI6WyJjbG91ZF9jb250cm9sbGVyLmFkbWluIl0sImF1ZCI6WyJjbG91ZF9jb250cm9sbGVyIl0sImV4cCI6MTQ0MjYwMTUzMn0.jfZisq3op4TjPG8bI14Y5sSzY_l21rDF1n-KMnERQ8w" \
	-H "Host: example.org" \
	-H "Cookie: "

Response

Status

200 OK

Body

{
  "staging_env_json": {
    "STAGING_ENV": "staging_value"
  },
  "running_env_json": {
    "RUNNING_ENV": "running_value"
  },
  "environment_json": {
    "env_var": "env_val"
  },
  "system_env_json": {
    "VCAP_SERVICES": {

    }
  },
  "application_env_json": {
    "VCAP_APPLICATION": {
      "limits": {
        "mem": 1024,
        "disk": 1024,
        "fds": 16384
      },
      "application_id": "bbb2df0a-ed7f-43a3-bd6b-fbfa3169a760",
      "application_version": "ad609b2f-36e9-4fb5-80b9-400abb61173b",
      "application_name": "name-495",
      "application_uris": [

      ],
      "version": "ad609b2f-36e9-4fb5-80b9-400abb61173b",
      "name": "name-495",
      "space_name": "name-496",
      "space_id": "a91e66a8-6675-4255-ab20-3790a489c024",
      "uris": [

      ],
      "users": null
    }
  }
}

Headers

Content-Type: application/json;charset=utf-8
X-VCAP-Request-ID: b3c356db-b29f-4e62-8dbe-117cd0f670d0
Content-Length: 826
X-Content-Type-Options: nosniff