Get API deployments

get

/apiplatform/management/v1/apis/{apiId}/deployments

Returns a collection of deployments of the {apiId} API.

The response also contains HATEOAS links to related operations.

Users requesting this resource must be assigned the Plan Manager, API Manager, or Gateway Manager role and must be issued the Manage API or View All Details grants for the specified API. All deployments are returned, regardless of the permissions issued for each gateway.

Request

Supported Media Types
Path Parameters
Query Parameters
  • Collection Format: csv
    Pass optional fields, separated by commas, in this parameter to return them in the response. See the operation's description for a list of expand values.
  • Collection Format: csv
    Pass optional fields, separated by commas, in this parameter to return them in the response. See the operation's description for a list of field values.
  • Number of items to retrieve. 1 is the minumum; 128 is the maximum.
    Default Value: 128
  • Offset the list returned results by this amount. Default is zero.
    Default Value: 0
  • Collection Format: csv
    Pass sorting criteria, comma separated.
  • Pass filtering criteria, using the SCIM filter expression syntax
  • Include the total result count in the response.
    Default Value: false
Back to Top

Response

Supported Media Types

200 Response

The collection of deployments
Body ()
Root Schema : GetDeploymentsResponse
Match All
Show Source
Nested Schema : CollectionResponseFeature
Type: object
Show Source
Nested Schema : CollectionResponsePagingFeature
Type: object
Show Source
Nested Schema : LinksResponseFeature
Type: object
Show Source
Nested Schema : GetDeploymentsResponse-allOf[3]
Type: object
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : GetDeploymentsItem
Match All
Show Source
Nested Schema : Deployment
Match All
Show Source
Nested Schema : ResourceLinksProperties
Type: object
Show Source
Nested Schema : DeploymentId
Type: object
Show Source
Nested Schema : Deployment-allOf[1]
Type: object
Show Source
Nested Schema : Deployment-allOf[2]
Type: object
Show Source
Nested Schema : DeploymentDef
Type: object
Show Source
Nested Schema : DeploymentMetadata
Type: object
Show Source
Nested Schema : Deployment-allOf[5]
Type: object
Show Source
Nested Schema : Api
Type: object
Nested Schema : Gateway
Match All
Show Source
Nested Schema : GatewayId
Type: object
Show Source
Nested Schema : GatewayIdentity
Type: object
Show Source
Nested Schema : GatewayDef
Type: object
Show Source
Nested Schema : GatewayMetadata
Type: object
Show Source
Nested Schema : configuration
Type: object
Show Source
Nested Schema : firewall
Type: object
Show Source
Nested Schema : proxyUrls
Type: array
Show Source
Nested Schema : urls
Type: array
Show Source
Nested Schema : endpoints
Type: array
The deployment's endpoints.
Show Source
Nested Schema : nodes
Type: array
Show Source
Nested Schema : NodeDeployment
Type: object
Show Source
Nested Schema : endpoints
Type: array
The node deployment's endpoints.
Show Source

403 Response

Forbidden.
Body ()
Root Schema : Error
Type: object
Show Source
Nested Schema : errorDetails
Type: array
additional errors
Show Source

500 Response

Unexpected error.
Body ()
Root Schema : Error
Type: object
Show Source
Nested Schema : errorDetails
Type: array
additional errors
Show Source
Back to Top

Examples

The following example shows how to retrieve all available deployments for an API by submitting a GET request on the REST resource using cURL. For more information about cURL, see Use cURL

curl -i -X GET 
-H "Authorization: Bearer access_token"
https://example.com/apiplatform/management/v1/apis/{apiId}/deployments

{apiId} is the unique ID for an API. To retrieve available API IDs, see Get APIs.

You can pass the following optional field values in the fields query parameter, separated by commas, to include them in the response:

  • For each API:

    • api.description: The API's description.

    • api.iterationId: The API's iteration.

    • api.createdAt: The date and time the API was created.

    • api.createdBy: The user who created the API.

    • api.updatedAt: The date and time the API was last updated.

    • api.updatedBy: The user who last updated the API.

  • For each gateway:

    • gateway.description: The gateway's description.

    • gateway.urls: The gateway???s load balancer URLs.

    • nodes: Information about a node the API is deployed to.

    • nodes.description: A node???s description.

    • nodes.urls: The node???s load balancer URLs.

    • nodes.state: The gateway node's state. Values are REQUESTINGACTIVE, and REJECTED.

    • nodes.stateComments: Comments regarding the gateway node's state.

  • For each deployment:

    • action: The deployment action. Values are DEPLOY (to create a new deployment), UNDEPLOY (to undeploy a deployment), ACTIVATE (to activate a deployment), and INACTIVATE (to inactivate a deployment).

    • deploymentState: The deployment's state. Values are REQUESTINGAPPROVED, and REJECTED.

    • deploymentComments: Comments regarding the deployment's state.

    • runtimeState: The deployment's runtime state. Values are ACTIVE and INACTIVE.

    • description: The deployment's description.

    • endpoints: The deployment's endpoints.

The following example shows you how to include these fields in the response:

curl -i -X GET
-H "Authorization: Bearer access_token"
https://example.com/apiplatform/management/v1/apis/{apiId}/deployments?fields=api.description,deploymentState

Example of Response Headers

The following shows an example of the response headers.

HTTP/1.1 200 OK
Server: Oracle-Traffic-Director/12.2.1.0.0
Date:  Fri, 17 Mar 2017 06:59:13 GMT
Content-Length:  1667
Content-Type:  application/json
X-oracle-dms-ecid:  f102c33f-1c5b-4409-806d-03bf5706c492-0002adb4
X-oracle-dms-rid: 0:1
Via: 1.1 otd_opc
Proxy-agent: Oracle-Traffic-Director/12.2.1.0.0

Example of Response Body

The following example shows the contents of the response body in JSON format, including ID of each deployment. The response also contains HATEOAS links to related operations.

{
    "count": 1,
    "links": [
        {
            "templated": "true",
            "method": "GET",
            "rel": "self",
            "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
        },
        {
            "templated": "true",
            "method": "GET",
            "rel": "canonical",
            "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
        },
        {
            "templated": "true",
            "method": "POST",
            "rel": "deploy",
            "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
        },
        {
            "templated": "true",
            "method": "GET",
            "rel": "gateways",
            "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments/gateways"
        }
    ],
    "items": [
        {
            "links": [
                {
                    "templated": "true",
                    "method": "GET",
                    "rel": "canonical",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments/103"
                },
                {
                    "templated": "true",
                    "method": "GET",
                    "rel": "implementation",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments/103/api"
                },
                {
                    "templated": "true",
                    "method": "POST",
                    "rel": "deploy",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
                },
                {
                    "templated": "true",
                    "method": "POST",
                    "rel": "redeploy",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
                },
                {
                    "templated": "true",
                    "method": "POST",
                    "rel": "activate",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
                },
                {
                    "templated": "true",
                    "method": "POST",
                    "rel": "inactivate",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
                },
                {
                    "templated": "true",
                    "method": "POST",
                    "rel": "undeploy",
                    "href": "https://example.com:443/apiplatform/management/v1/apis/103/deployments"
                }
            ],
            "id": "103"
        }
    ]
}
Back to Top