SDK for PHP 3.x

Client: Aws\MigrationHubConfig\MigrationHubConfigClient
Service ID: migrationhub-config
Version: 2019-06-30

This page describes the parameters and results for the operations of the AWS Migration Hub Config (2019-06-30), and shows how to use the Aws\MigrationHubConfig\MigrationHubConfigClient object to call the described operations. This documentation is specific to the 2019-06-30 API version of the service.

Operation Summary

Each of the following operations can be created from a client using $client->getCommand('CommandName'), where "CommandName" is the name of one of the following operations. Note: a command is a value that encapsulates an operation and the parameters used to create an HTTP request.

You can also create and send a command immediately using the magic methods available on a client object: $client->commandName(/* parameters */). You can send the command asynchronously (returning a promise) by appending the word "Async" to the operation name: $client->commandNameAsync(/* parameters */).

CreateHomeRegionControl ( array $params = [] )
This API sets up the home region for the calling account only.
DeleteHomeRegionControl ( array $params = [] )
This operation deletes the home region configuration for the calling account.
DescribeHomeRegionControls ( array $params = [] )
This API permits filtering on the ControlId and HomeRegion fields.
GetHomeRegion ( array $params = [] )
Returns the calling account’s home region, if configured.

Paginators

Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:

DescribeHomeRegionControls

Operations

CreateHomeRegionControl

$result = $client->createHomeRegionControl([/* ... */]);
$promise = $client->createHomeRegionControlAsync([/* ... */]);

This API sets up the home region for the calling account only.

Parameter Syntax

$result = $client->createHomeRegionControl([
    'DryRun' => true || false,
    'HomeRegion' => '<string>', // REQUIRED
    'Target' => [ // REQUIRED
        'Id' => '<string>',
        'Type' => 'ACCOUNT', // REQUIRED
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Optional Boolean flag to indicate whether any effect should take place. It tests whether the caller has permission to make the call.

HomeRegion
Required: Yes
Type: string

The name of the home region of the calling account.

Target
Required: Yes
Type: Target structure

The account for which this command sets up a home region control. The Target is always of type ACCOUNT.

Result Syntax

[
    'HomeRegionControl' => [
        'ControlId' => '<string>',
        'HomeRegion' => '<string>',
        'RequestedTime' => <DateTime>,
        'Target' => [
            'Id' => '<string>',
            'Type' => 'ACCOUNT',
        ],
    ],
]

Result Details

Members
HomeRegionControl
Type: HomeRegionControl structure

This object is the HomeRegionControl object that's returned by a successful call to CreateHomeRegionControl.

Errors

InternalServerError:

Exception raised when an internal, configuration, or dependency error is encountered.

ServiceUnavailableException:

Exception raised when a request fails due to temporary unavailability of the service.

AccessDeniedException:

You do not have sufficient access to perform this action.

ThrottlingException:

The request was denied due to request throttling.

DryRunOperation:

Exception raised to indicate that authorization of an action was successful, when the DryRun flag is set to true.

InvalidInputException:

Exception raised when the provided input violates a policy constraint or is entered in the wrong format or data type.

DeleteHomeRegionControl

$result = $client->deleteHomeRegionControl([/* ... */]);
$promise = $client->deleteHomeRegionControlAsync([/* ... */]);

This operation deletes the home region configuration for the calling account. The operation does not delete discovery or migration tracking data in the home region.

Parameter Syntax

$result = $client->deleteHomeRegionControl([
    'ControlId' => '<string>', // REQUIRED
]);

Parameter Details

Members
ControlId
Required: Yes
Type: string

A unique identifier that's generated for each home region control. It's always a string that begins with "hrc-" followed by 12 lowercase letters and numbers.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

InternalServerError:

Exception raised when an internal, configuration, or dependency error is encountered.

ServiceUnavailableException:

Exception raised when a request fails due to temporary unavailability of the service.

AccessDeniedException:

You do not have sufficient access to perform this action.

ThrottlingException:

The request was denied due to request throttling.

InvalidInputException:

Exception raised when the provided input violates a policy constraint or is entered in the wrong format or data type.

DescribeHomeRegionControls

$result = $client->describeHomeRegionControls([/* ... */]);
$promise = $client->describeHomeRegionControlsAsync([/* ... */]);

This API permits filtering on the ControlId and HomeRegion fields.

Parameter Syntax

$result = $client->describeHomeRegionControls([
    'ControlId' => '<string>',
    'HomeRegion' => '<string>',
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'Target' => [
        'Id' => '<string>',
        'Type' => 'ACCOUNT', // REQUIRED
    ],
]);

Parameter Details

Members
ControlId
Type: string

The ControlID is a unique identifier string of your HomeRegionControl object.

HomeRegion
Type: string

The name of the home region you'd like to view.

MaxResults
Type: int

The maximum number of filtering results to display per page.

NextToken
Type: string

If a NextToken was returned by a previous call, more results are available. To retrieve the next page of results, make the call again using the returned token in NextToken.

Target
Type: Target structure

The target parameter specifies the identifier to which the home region is applied, which is always of type ACCOUNT. It applies the home region to the current ACCOUNT.

Result Syntax

[
    'HomeRegionControls' => [
        [
            'ControlId' => '<string>',
            'HomeRegion' => '<string>',
            'RequestedTime' => <DateTime>,
            'Target' => [
                'Id' => '<string>',
                'Type' => 'ACCOUNT',
            ],
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
HomeRegionControls
Type: Array of HomeRegionControl structures

An array that contains your HomeRegionControl objects.

NextToken
Type: string

If a NextToken was returned by a previous call, more results are available. To retrieve the next page of results, make the call again using the returned token in NextToken.

Errors

InternalServerError:

Exception raised when an internal, configuration, or dependency error is encountered.

ServiceUnavailableException:

Exception raised when a request fails due to temporary unavailability of the service.

AccessDeniedException:

You do not have sufficient access to perform this action.

ThrottlingException:

The request was denied due to request throttling.

InvalidInputException:

Exception raised when the provided input violates a policy constraint or is entered in the wrong format or data type.

GetHomeRegion

$result = $client->getHomeRegion([/* ... */]);
$promise = $client->getHomeRegionAsync([/* ... */]);

Returns the calling account’s home region, if configured. This API is used by other AWS services to determine the regional endpoint for calling AWS Application Discovery Service and Migration Hub. You must call GetHomeRegion at least once before you call any other AWS Application Discovery Service and AWS Migration Hub APIs, to obtain the account's Migration Hub home region.

Parameter Syntax

$result = $client->getHomeRegion([
]);

Parameter Details

Members

Result Syntax

[
    'HomeRegion' => '<string>',
]

Result Details

Members
HomeRegion
Type: string

The name of the home region of the calling account.

Errors

InternalServerError:

Exception raised when an internal, configuration, or dependency error is encountered.

ServiceUnavailableException:

Exception raised when a request fails due to temporary unavailability of the service.

AccessDeniedException:

You do not have sufficient access to perform this action.

ThrottlingException:

The request was denied due to request throttling.

InvalidInputException:

Exception raised when the provided input violates a policy constraint or is entered in the wrong format or data type.

Shapes

AccessDeniedException

Description

You do not have sufficient access to perform this action.

Members
Message
Type: string

DryRunOperation

Description

Exception raised to indicate that authorization of an action was successful, when the DryRun flag is set to true.

Members
Message
Type: string

HomeRegionControl

Description

A home region control is an object that specifies the home region for an account, with some additional information. It contains a target (always of type ACCOUNT), an ID, and a time at which the home region was set.

Members
ControlId
Type: string

A unique identifier that's generated for each home region control. It's always a string that begins with "hrc-" followed by 12 lowercase letters and numbers.

HomeRegion
Type: string

The AWS Region that's been set as home region. For example, "us-west-2" or "eu-central-1" are valid home regions.

RequestedTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

A timestamp representing the time when the customer called CreateHomeregionControl and set the home region for the account.

Target
Type: Target structure

The target parameter specifies the identifier to which the home region is applied, which is always an ACCOUNT. It applies the home region to the current ACCOUNT.

InternalServerError

Description

Exception raised when an internal, configuration, or dependency error is encountered.

Members
Message
Type: string

InvalidInputException

Description

Exception raised when the provided input violates a policy constraint or is entered in the wrong format or data type.

Members
Message
Type: string

ServiceUnavailableException

Description

Exception raised when a request fails due to temporary unavailability of the service.

Members
Message
Type: string

Target

Description

The target parameter specifies the identifier to which the home region is applied, which is always an ACCOUNT. It applies the home region to the current ACCOUNT.

Members
Id
Type: string

The TargetID is a 12-character identifier of the ACCOUNT for which the control was created. (This must be the current account.)

Type
Required: Yes
Type: string

The target type is always an ACCOUNT.

ThrottlingException

Description

The request was denied due to request throttling.

Members
Message
Required: Yes
Type: string
RetryAfterSeconds
Type: int

The number of seconds the caller should wait before retrying.