Home
Version 3
Packages (Experimental) API

Packages (Experimental) API

Copy a Package

POST /v3/apps/:guid/packages

Request

Route

POST /v3/apps/guid-f5564bf6-67b4-4700-bec7-65bb02b6cd9a/packages?source_package_guid=guid-86e81a89-1e8b-4aab-87ec-97ccb38269cd

Parameters

Name Description Valid Values Example Values
source_package_guid The package to copy from
source_package_guid: guid-86e81a89-1e8b-4aab-87ec-97ccb38269cd

Headers

Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQ1OSIsImVtYWlsIjoiZW1haWwtMzI2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDgwMzg5NzZ9.GMDrHLLGND0_1pzVMpOyXDeHp8zkTd0iFenSrfCz1O0
Host: example.org
Content-Type: application/x-www-form-urlencoded
Cookie: 

cURL

curl "https://api.[your-domain.com]/v3/apps/guid-f5564bf6-67b4-4700-bec7-65bb02b6cd9a/packages?source_package_guid=guid-86e81a89-1e8b-4aab-87ec-97ccb38269cd" -d '' -X POST \
	-H "Authorization: bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoidWFhLWlkLTQ1OSIsImVtYWlsIjoiZW1haWwtMzI2QHNvbWVkb21haW4uY29tIiwic2NvcGUiOlsiY2xvdWRfY29udHJvbGxlci5yZWFkIiwiY2xvdWRfY29udHJvbGxlci53cml0ZSJdLCJhdWQiOlsiY2xvdWRfY29udHJvbGxlciJdLCJleHAiOjE0NDgwMzg5NzZ9.GMDrHLLGND0_1pzVMpOyXDeHp8zkTd0iFenSrfCz1O0" \
	-H "Host: example.org" \
	-H "Content-Type: application/x-www-form-urlencoded" \
	-H "Cookie: "

Response

Status

201 Created

Body

{
  "guid": "e3f614ea-dd1d-4549-bfdf-88c0293bac64",
  "type": "docker",
  "data": {
    "hash": {
      "type": "sha1",
      "value": null
    },
    "error": null,
    "image": "http://awesome-sauce.com",
    "credentials": {

    },
    "store_image": false
  },
  "state": "READY",
  "created_at": "2015-11-13T17:02:56Z",
  "updated_at": null,
  "links": {
    "self": {
      "href": "/v3/packages/e3f614ea-dd1d-4549-bfdf-88c0293bac64"
    },
    "app": {
      "href": "/v3/apps/guid-f5564bf6-67b4-4700-bec7-65bb02b6cd9a"
    }
  }
}

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
Content-Type: application/json; charset=utf-8
X-Runtime: 0.024568
Content-Length: 539