Home
Version 3
Apps API

Apps API

Restage an App

POST /v2/apps/:guid/restage

Request

Route

POST /v2/apps/63e33a8c-7bc0-498e-b132-ca9dba4dbdab/restage

Parameters

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

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQzMyIsImVtYWlsIjoiZW1haWwtMjk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NjM2MTg3Mjl9.LNfXSogjm6GhHbvUVypfcWB4XXY-HtnY41JaChhNUiM
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v2/apps/63e33a8c-7bc0-498e-b132-ca9dba4dbdab/restage" -d '' -X POST \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQzMyIsImVtYWlsIjoiZW1haWwtMjk1QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5hZG1pbiJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NjM2MTg3Mjl9.LNfXSogjm6GhHbvUVypfcWB4XXY-HtnY41JaChhNUiM" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "metadata": {
    "guid": "63e33a8c-7bc0-498e-b132-ca9dba4dbdab",
    "url": "/v2/apps/63e33a8c-7bc0-498e-b132-ca9dba4dbdab",
    "created_at": "2016-05-12T00:45:29Z",
    "updated_at": "2016-05-12T00:45:29Z"
  },
  "entity": {
    "name": "name-2455",
    "production": false,
    "space_guid": "5a742925-1e92-442e-82fb-d5beef0ddbb4",
    "stack_guid": "a35da474-b964-491d-8d59-7413fb45ad2f",
    "buildpack": null,
    "detected_buildpack": null,
    "environment_json": null,
    "memory": 1024,
    "instances": 1,
    "disk_quota": 1024,
    "state": "STARTED",
    "version": "0dfdb3f3-933b-4362-b4fa-cd562c063c5e",
    "command": null,
    "console": false,
    "debug": null,
    "staging_task_id": null,
    "package_state": "PENDING",
    "health_check_type": "port",
    "health_check_timeout": null,
    "staging_failed_reason": null,
    "staging_failed_description": null,
    "diego": false,
    "docker_image": null,
    "package_updated_at": "2016-05-12T00:45:29Z",
    "detected_start_command": "",
    "enable_ssh": true,
    "docker_credentials_json": {
      "redacted_message": "[PRIVATE DATA HIDDEN]"
    },
    "ports": null
  }
}

Headers

Content-Type: application/json;charset=utf-8
Location: /v2/apps/63e33a8c-7bc0-498e-b132-ca9dba4dbdab
X-VCAP-Request-ID: e20d8760-2f26-4615-bd6d-12557b2a2d1b
Content-Length: 1158
X-Content-Type-Options: nosniff