Menu
AWS CodeDeploy
API Reference (API Version 2014-10-06)

GetDeploymentGroup

Gets information about a deployment group.

Request Syntax

Copy
{ "applicationName": "string", "deploymentGroupName": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

applicationName

The name of an AWS CodeDeploy application associated with the applicable IAM user or AWS account.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 100.

Required: Yes

deploymentGroupName

The name of an existing deployment group for the specified application.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 100.

Required: Yes

Response Syntax

Copy
{ "deploymentGroupInfo": { "alarmConfiguration": { "alarms": [ { "name": "string" } ], "enabled": boolean, "ignorePollAlarmFailure": boolean }, "applicationName": "string", "autoRollbackConfiguration": { "enabled": boolean, "events": [ "string" ] }, "autoScalingGroups": [ { "hook": "string", "name": "string" } ], "blueGreenDeploymentConfiguration": { "deploymentReadyOption": { "actionOnTimeout": "string", "waitTimeInMinutes": number }, "greenFleetProvisioningOption": { "action": "string" }, "terminateBlueInstancesOnDeploymentSuccess": { "action": "string", "terminationWaitTimeInMinutes": number } }, "deploymentConfigName": "string", "deploymentGroupId": "string", "deploymentGroupName": "string", "deploymentStyle": { "deploymentOption": "string", "deploymentType": "string" }, "ec2TagFilters": [ { "Key": "string", "Type": "string", "Value": "string" } ], "ec2TagSet": { "ec2TagSetList": [ [ { "Key": "string", "Type": "string", "Value": "string" } ] ] }, "lastAttemptedDeployment": { "createTime": number, "deploymentId": "string", "endTime": number, "status": "string" }, "lastSuccessfulDeployment": { "createTime": number, "deploymentId": "string", "endTime": number, "status": "string" }, "loadBalancerInfo": { "elbInfoList": [ { "name": "string" } ], "targetGroupInfoList": [ { "name": "string" } ] }, "onPremisesInstanceTagFilters": [ { "Key": "string", "Type": "string", "Value": "string" } ], "onPremisesTagSet": { "onPremisesTagSetList": [ [ { "Key": "string", "Type": "string", "Value": "string" } ] ] }, "serviceRoleArn": "string", "targetRevision": { "gitHubLocation": { "commitId": "string", "repository": "string" }, "revisionType": "string", "s3Location": { "bucket": "string", "bundleType": "string", "eTag": "string", "key": "string", "version": "string" } }, "triggerConfigurations": [ { "triggerEvents": [ "string" ], "triggerName": "string", "triggerTargetArn": "string" } ] } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

deploymentGroupInfo

Information about the deployment group.

Type: DeploymentGroupInfo object

Errors

For information about the errors that are common to all actions, see Common Errors.

ApplicationDoesNotExistException

The application does not exist with the applicable IAM user or AWS account.

HTTP Status Code: 400

ApplicationNameRequiredException

The minimum number of required application names was not specified.

HTTP Status Code: 400

DeploymentGroupDoesNotExistException

The named deployment group does not exist with the applicable IAM user or AWS account.

HTTP Status Code: 400

DeploymentGroupNameRequiredException

The deployment group name was not specified.

HTTP Status Code: 400

InvalidApplicationNameException

The application name was specified in an invalid format.

HTTP Status Code: 400

InvalidDeploymentGroupNameException

The deployment group name was specified in an invalid format.

HTTP Status Code: 400

Example

Sample Request

Copy
POST / HTTP/1.1 Host: codedeploy.us-east-1.amazonaws.com Accept-Encoding: identity Content-Length: 99 X-Amz-Target: CodeDeploy_20141006.GetDeploymentGroup X-Amz-Date: 20160707T020047Z User-Agent: aws-cli/1.10.6 Python/2.7.9 Windows/7 botocore/1.3.28 Content-Type: application/x-amz-json-1.1 Authorization: AWS4-HMAC-SHA256 Credential=AKIAIOSFODNN7EXAMPLE/20160707/us-east-1/codedeploy/aws4_request, SignedHeaders=content-type;host;user-agent;x-amz-date;x-amz-target, Signature=39c3b3042cd2aEXAMPLE { "applicationName": "TestApp-us-east-1", "deploymentGroupName": "dep-group-def-456" }

Sample Response

Copy
HTTP/1.1 200 OK x-amzn-RequestId: 31b0d6a4-88e1-11e5-bb59-fb8eade0dfc3 Content-Type: application/x-amz-json-1.1 Content-Length: 646 { "deploymentGroupInfo": { "applicationName": "TestApp-us-east-1", "autoScalingGroups": [], "deploymentConfigName": "CodeDeployDefault.OneAtATime", "deploymentGroupId": "c565c0f7-8927-45d5-ab11-c16c4b0540b6", "deploymentGroupName": "dep-group-def-456", "ec2TagFilters": [ { "Key": "Name", "Type": "KEY_AND_VALUE", "Value": "grp-c-inst-1" } ], "onPremisesInstanceTagFilters": [], "serviceRoleArn": "arn:aws:iam::444455556666:role/AnyCompany-service-role", "targetRevision": { "revisionType": "S3", "s3Location": { "bucket": "project-1234", "bundleType": "zip", "eTag": "3fdd7b9193231a096d5af1d649e26a4a", "key": "North-App.zip" }, "triggerConfigurations": [ { "triggerEvents": [ "DeploymentFailure" ], "triggerName": "Trigger-group-us-east-1-deploy-fail", "triggerTargetArn": "arn:aws:sns:us-east-1:80398EXAMPLE:us-east-deploy-fail" } ] } } }

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: