- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
GetDeploymentInstanceCommand
- This operation is deprecated, use GetDeploymentTarget instead.
Gets information about an instance as part of a deployment.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { CodeDeployClient, GetDeploymentInstanceCommand } from "@aws-sdk/client-codedeploy"; // ES Modules import
// const { CodeDeployClient, GetDeploymentInstanceCommand } = require("@aws-sdk/client-codedeploy"); // CommonJS import
const client = new CodeDeployClient(config);
const input = { // GetDeploymentInstanceInput
deploymentId: "STRING_VALUE", // required
instanceId: "STRING_VALUE", // required
};
const command = new GetDeploymentInstanceCommand(input);
const response = await client.send(command);
// { // GetDeploymentInstanceOutput
// instanceSummary: { // InstanceSummary
// deploymentId: "STRING_VALUE",
// instanceId: "STRING_VALUE",
// status: "Pending" || "InProgress" || "Succeeded" || "Failed" || "Skipped" || "Unknown" || "Ready",
// lastUpdatedAt: new Date("TIMESTAMP"),
// lifecycleEvents: [ // LifecycleEventList
// { // LifecycleEvent
// lifecycleEventName: "STRING_VALUE",
// diagnostics: { // Diagnostics
// errorCode: "Success" || "ScriptMissing" || "ScriptNotExecutable" || "ScriptTimedOut" || "ScriptFailed" || "UnknownError",
// scriptName: "STRING_VALUE",
// message: "STRING_VALUE",
// logTail: "STRING_VALUE",
// },
// startTime: new Date("TIMESTAMP"),
// endTime: new Date("TIMESTAMP"),
// status: "Pending" || "InProgress" || "Succeeded" || "Failed" || "Skipped" || "Unknown",
// },
// ],
// instanceType: "Blue" || "Green",
// },
// };
GetDeploymentInstanceCommand Input
See GetDeploymentInstanceCommandInput for more details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
deploymentId Required | string | undefined | The unique ID of a deployment. |
instanceId Required | string | undefined | The unique ID of an instance in the deployment group. |
GetDeploymentInstanceCommand Output
See GetDeploymentInstanceCommandOutput for details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
instanceSummary | InstanceSummary | undefined | Information about the instance. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
DeploymentDoesNotExistException | client | The deployment with the user or Amazon Web Services account does not exist. |
DeploymentIdRequiredException | client | At least one deployment ID must be specified. |
InstanceDoesNotExistException | client | The specified instance does not exist in the deployment group. |
InstanceIdRequiredException | client | The instance ID was not specified. |
InvalidComputePlatformException | client | The computePlatform is invalid. The computePlatform should be |
InvalidDeploymentIdException | client | At least one of the deployment IDs was specified in an invalid format. |
InvalidInstanceNameException | client | The on-premises instance name was specified in an invalid format. |
CodeDeployServiceException | Base exception class for all service exceptions from CodeDeploy service. |