DescribeAgent - AWS DataSync

DescribeAgent

Returns information about an AWS DataSync agent, such as its name, service endpoint type, and status.

Request Syntax

{ "AgentArn": "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.

AgentArn

Specifies the Amazon Resource Name (ARN) of the DataSync agent that you want information about.

Type: String

Length Constraints: Maximum length of 128.

Pattern: ^arn:(aws|aws-cn|aws-us-gov|aws-iso|aws-iso-b):datasync:[a-z\-0-9]+:[0-9]{12}:agent/agent-[0-9a-z]{17}$

Required: Yes

Response Syntax

{ "AgentArn": "string", "CreationTime": number, "EndpointType": "string", "LastConnectionTime": number, "Name": "string", "Platform": { "Version": "string" }, "PrivateLinkConfig": { "PrivateLinkEndpoint": "string", "SecurityGroupArns": [ "string" ], "SubnetArns": [ "string" ], "VpcEndpointId": "string" }, "Status": "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.

AgentArn

The ARN of the agent.

Type: String

Length Constraints: Maximum length of 128.

Pattern: ^arn:(aws|aws-cn|aws-us-gov|aws-iso|aws-iso-b):datasync:[a-z\-0-9]+:[0-9]{12}:agent/agent-[0-9a-z]{17}$

CreationTime

The time that the agent was activated.

Type: Timestamp

EndpointType

The type of service endpoint that your agent is connected to.

Type: String

Valid Values: PUBLIC | PRIVATE_LINK | FIPS

LastConnectionTime

The last time that the agent was communicating with the DataSync service.

Type: Timestamp

Name

The name of the agent.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 256.

Pattern: ^[a-zA-Z0-9\s+=._:@/-]+$

Platform

The platform-related details about the agent, such as the version number.

Type: Platform object

PrivateLinkConfig

The network configuration that the agent uses when connecting to a VPC service endpoint.

Type: PrivateLinkConfig object

Status

The status of the agent.

  • If the status is ONLINE, the agent is configured properly and ready to use.

  • If the status is OFFLINE, the agent has been out of contact with DataSync for five minutes or longer. This can happen for a few reasons. For more information, see What do I do if my agent is offline?

Type: String

Valid Values: ONLINE | OFFLINE

Errors

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

InternalException

This exception is thrown when an error occurs in the AWS DataSync service.

HTTP Status Code: 500

InvalidRequestException

This exception is thrown when the client submits a malformed request.

HTTP Status Code: 400

Examples

Sample Request

The following example returns information about an agent specified in a request.

{ "AgentArn": "arn:aws:datasync:us-east-2:111122223333:agent/agent-1234567890abcdef0" }

Sample Response

The following example response describes an agent that uses a public service endpoint.

{ "AgentArn": "arn:aws:datasync:us-east-2:111122223333:agent/agent-1234567890abcdef0", "Name": "Data center migration agent", "Status": "ONLINE", "LastConnectionTime": "2022-10-17T17:21:35.540000+00:00", "CreationTime": "2022-10-05T20:52:29.499000+00:00", "EndpointType": "PUBLIC", "Platform": { "Version": "2" } }

See Also

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