Skip to content

MigrationHubClient#

Index > MigrationHub > MigrationHubClient

Auto-generated documentation for MigrationHub type annotations stubs module mypy-boto3-mgh.

MigrationHubClient#

Type annotations and code completion for boto3.client("mgh"). boto3 documentation

# MigrationHubClient usage example

from boto3.session import Session
from mypy_boto3_mgh.client import MigrationHubClient

def get_mgh_client() -> MigrationHubClient:
    return Session().client("mgh")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("mgh").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("mgh")

try:
    do_something(client)
except (
    client.exceptions.AccessDeniedException,
    client.exceptions.ClientError,
    client.exceptions.DryRunOperation,
    client.exceptions.HomeRegionNotSetException,
    client.exceptions.InternalServerError,
    client.exceptions.InvalidInputException,
    client.exceptions.PolicyErrorException,
    client.exceptions.ResourceNotFoundException,
    client.exceptions.ServiceUnavailableException,
    client.exceptions.ThrottlingException,
    client.exceptions.UnauthorizedOperation,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_mgh.client import Exceptions

def handle_error(exc: Exceptions.AccessDeniedException) -> None:
    ...

Methods#

associate_created_artifact#

Associates a created artifact of an AWS cloud resource, the target receiving the migration, with the migration task performed by a migration tool.

Type annotations and code completion for boto3.client("mgh").associate_created_artifact method. boto3 documentation

# associate_created_artifact method definition

def associate_created_artifact(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    CreatedArtifact: CreatedArtifactTypeDef,  # (1)
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
  1. See CreatedArtifactTypeDef
# associate_created_artifact method usage example with argument unpacking

kwargs: AssociateCreatedArtifactRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "CreatedArtifact": ...,
}

parent.associate_created_artifact(**kwargs)
  1. See AssociateCreatedArtifactRequestRequestTypeDef

associate_discovered_resource#

Associates a discovered resource ID from Application Discovery Service with a migration task.

Type annotations and code completion for boto3.client("mgh").associate_discovered_resource method. boto3 documentation

# associate_discovered_resource method definition

def associate_discovered_resource(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    DiscoveredResource: DiscoveredResourceTypeDef,  # (1)
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
  1. See DiscoveredResourceTypeDef
# associate_discovered_resource method usage example with argument unpacking

kwargs: AssociateDiscoveredResourceRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "DiscoveredResource": ...,
}

parent.associate_discovered_resource(**kwargs)
  1. See AssociateDiscoveredResourceRequestRequestTypeDef

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for boto3.client("mgh").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

close#

Closes underlying endpoint connections.

Type annotations and code completion for boto3.client("mgh").close method. boto3 documentation

# close method definition

def close(
    self,
) -> None:
    ...

create_progress_update_stream#

Creates a progress update stream which is an AWS resource used for access control as well as a namespace for migration task names that is implicitly linked to your AWS account.

Type annotations and code completion for boto3.client("mgh").create_progress_update_stream method. boto3 documentation

# create_progress_update_stream method definition

def create_progress_update_stream(
    self,
    *,
    ProgressUpdateStreamName: str,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
# create_progress_update_stream method usage example with argument unpacking

kwargs: CreateProgressUpdateStreamRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStreamName": ...,
}

parent.create_progress_update_stream(**kwargs)
  1. See CreateProgressUpdateStreamRequestRequestTypeDef

delete_progress_update_stream#

Deletes a progress update stream, including all of its tasks, which was previously created as an AWS resource used for access control.

Type annotations and code completion for boto3.client("mgh").delete_progress_update_stream method. boto3 documentation

# delete_progress_update_stream method definition

def delete_progress_update_stream(
    self,
    *,
    ProgressUpdateStreamName: str,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
# delete_progress_update_stream method usage example with argument unpacking

kwargs: DeleteProgressUpdateStreamRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStreamName": ...,
}

parent.delete_progress_update_stream(**kwargs)
  1. See DeleteProgressUpdateStreamRequestRequestTypeDef

describe_application_state#

Gets the migration status of an application.

Type annotations and code completion for boto3.client("mgh").describe_application_state method. boto3 documentation

# describe_application_state method definition

def describe_application_state(
    self,
    *,
    ApplicationId: str,
) -> DescribeApplicationStateResultTypeDef:  # (1)
    ...
  1. See DescribeApplicationStateResultTypeDef
# describe_application_state method usage example with argument unpacking

kwargs: DescribeApplicationStateRequestRequestTypeDef = {  # (1)
    "ApplicationId": ...,
}

parent.describe_application_state(**kwargs)
  1. See DescribeApplicationStateRequestRequestTypeDef

describe_migration_task#

Retrieves a list of all attributes associated with a specific migration task.

Type annotations and code completion for boto3.client("mgh").describe_migration_task method. boto3 documentation

# describe_migration_task method definition

def describe_migration_task(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
) -> DescribeMigrationTaskResultTypeDef:  # (1)
    ...
  1. See DescribeMigrationTaskResultTypeDef
# describe_migration_task method usage example with argument unpacking

kwargs: DescribeMigrationTaskRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
}

parent.describe_migration_task(**kwargs)
  1. See DescribeMigrationTaskRequestRequestTypeDef

disassociate_created_artifact#

Disassociates a created artifact of an AWS resource with a migration task performed by a migration tool that was previously associated.

Type annotations and code completion for boto3.client("mgh").disassociate_created_artifact method. boto3 documentation

# disassociate_created_artifact method definition

def disassociate_created_artifact(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    CreatedArtifactName: str,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
# disassociate_created_artifact method usage example with argument unpacking

kwargs: DisassociateCreatedArtifactRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "CreatedArtifactName": ...,
}

parent.disassociate_created_artifact(**kwargs)
  1. See DisassociateCreatedArtifactRequestRequestTypeDef

disassociate_discovered_resource#

Disassociate an Application Discovery Service discovered resource from a migration task.

Type annotations and code completion for boto3.client("mgh").disassociate_discovered_resource method. boto3 documentation

# disassociate_discovered_resource method definition

def disassociate_discovered_resource(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    ConfigurationId: str,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
# disassociate_discovered_resource method usage example with argument unpacking

kwargs: DisassociateDiscoveredResourceRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "ConfigurationId": ...,
}

parent.disassociate_discovered_resource(**kwargs)
  1. See DisassociateDiscoveredResourceRequestRequestTypeDef

generate_presigned_url#

Generate a presigned url given a client, its method, and arguments.

Type annotations and code completion for boto3.client("mgh").generate_presigned_url method. boto3 documentation

# generate_presigned_url method definition

def generate_presigned_url(
    self,
    ClientMethod: str,
    Params: Mapping[str, Any] = ...,
    ExpiresIn: int = 3600,
    HttpMethod: str = ...,
) -> str:
    ...

import_migration_task#

Registers a new migration task which represents a server, database, etc., being migrated to AWS by a migration tool.

Type annotations and code completion for boto3.client("mgh").import_migration_task method. boto3 documentation

# import_migration_task method definition

def import_migration_task(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
# import_migration_task method usage example with argument unpacking

kwargs: ImportMigrationTaskRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
}

parent.import_migration_task(**kwargs)
  1. See ImportMigrationTaskRequestRequestTypeDef

list_application_states#

Lists all the migration statuses for your applications.

Type annotations and code completion for boto3.client("mgh").list_application_states method. boto3 documentation

# list_application_states method definition

def list_application_states(
    self,
    *,
    ApplicationIds: Sequence[str] = ...,
    NextToken: str = ...,
    MaxResults: int = ...,
) -> ListApplicationStatesResultTypeDef:  # (1)
    ...
  1. See ListApplicationStatesResultTypeDef
# list_application_states method usage example with argument unpacking

kwargs: ListApplicationStatesRequestRequestTypeDef = {  # (1)
    "ApplicationIds": ...,
}

parent.list_application_states(**kwargs)
  1. See ListApplicationStatesRequestRequestTypeDef

list_created_artifacts#

Lists the created artifacts attached to a given migration task in an update stream.

Type annotations and code completion for boto3.client("mgh").list_created_artifacts method. boto3 documentation

# list_created_artifacts method definition

def list_created_artifacts(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    NextToken: str = ...,
    MaxResults: int = ...,
) -> ListCreatedArtifactsResultTypeDef:  # (1)
    ...
  1. See ListCreatedArtifactsResultTypeDef
# list_created_artifacts method usage example with argument unpacking

kwargs: ListCreatedArtifactsRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
}

parent.list_created_artifacts(**kwargs)
  1. See ListCreatedArtifactsRequestRequestTypeDef

list_discovered_resources#

Lists discovered resources associated with the given MigrationTask.

Type annotations and code completion for boto3.client("mgh").list_discovered_resources method. boto3 documentation

# list_discovered_resources method definition

def list_discovered_resources(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    NextToken: str = ...,
    MaxResults: int = ...,
) -> ListDiscoveredResourcesResultTypeDef:  # (1)
    ...
  1. See ListDiscoveredResourcesResultTypeDef
# list_discovered_resources method usage example with argument unpacking

kwargs: ListDiscoveredResourcesRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
}

parent.list_discovered_resources(**kwargs)
  1. See ListDiscoveredResourcesRequestRequestTypeDef

list_migration_tasks#

Lists all, or filtered by resource name, migration tasks associated with the user account making this call.

Type annotations and code completion for boto3.client("mgh").list_migration_tasks method. boto3 documentation

# list_migration_tasks method definition

def list_migration_tasks(
    self,
    *,
    NextToken: str = ...,
    MaxResults: int = ...,
    ResourceName: str = ...,
) -> ListMigrationTasksResultTypeDef:  # (1)
    ...
  1. See ListMigrationTasksResultTypeDef
# list_migration_tasks method usage example with argument unpacking

kwargs: ListMigrationTasksRequestRequestTypeDef = {  # (1)
    "NextToken": ...,
}

parent.list_migration_tasks(**kwargs)
  1. See ListMigrationTasksRequestRequestTypeDef

list_progress_update_streams#

Lists progress update streams associated with the user account making this call.

Type annotations and code completion for boto3.client("mgh").list_progress_update_streams method. boto3 documentation

# list_progress_update_streams method definition

def list_progress_update_streams(
    self,
    *,
    NextToken: str = ...,
    MaxResults: int = ...,
) -> ListProgressUpdateStreamsResultTypeDef:  # (1)
    ...
  1. See ListProgressUpdateStreamsResultTypeDef
# list_progress_update_streams method usage example with argument unpacking

kwargs: ListProgressUpdateStreamsRequestRequestTypeDef = {  # (1)
    "NextToken": ...,
}

parent.list_progress_update_streams(**kwargs)
  1. See ListProgressUpdateStreamsRequestRequestTypeDef

notify_application_state#

Sets the migration state of an application.

Type annotations and code completion for boto3.client("mgh").notify_application_state method. boto3 documentation

# notify_application_state method definition

def notify_application_state(
    self,
    *,
    ApplicationId: str,
    Status: ApplicationStatusType,  # (1)
    UpdateDateTime: TimestampTypeDef = ...,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
  1. See ApplicationStatusType
# notify_application_state method usage example with argument unpacking

kwargs: NotifyApplicationStateRequestRequestTypeDef = {  # (1)
    "ApplicationId": ...,
    "Status": ...,
}

parent.notify_application_state(**kwargs)
  1. See NotifyApplicationStateRequestRequestTypeDef

notify_migration_task_state#

Notifies Migration Hub of the current status, progress, or other detail regarding a migration task.

Type annotations and code completion for boto3.client("mgh").notify_migration_task_state method. boto3 documentation

# notify_migration_task_state method definition

def notify_migration_task_state(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    Task: TaskTypeDef,  # (1)
    UpdateDateTime: TimestampTypeDef,
    NextUpdateSeconds: int,
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
  1. See TaskTypeDef
# notify_migration_task_state method usage example with argument unpacking

kwargs: NotifyMigrationTaskStateRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "Task": ...,
    "UpdateDateTime": ...,
    "NextUpdateSeconds": ...,
}

parent.notify_migration_task_state(**kwargs)
  1. See NotifyMigrationTaskStateRequestRequestTypeDef

put_resource_attributes#

Provides identifying details of the resource being migrated so that it can be associated in the Application Discovery Service repository.

Type annotations and code completion for boto3.client("mgh").put_resource_attributes method. boto3 documentation

# put_resource_attributes method definition

def put_resource_attributes(
    self,
    *,
    ProgressUpdateStream: str,
    MigrationTaskName: str,
    ResourceAttributeList: Sequence[ResourceAttributeTypeDef],  # (1)
    DryRun: bool = ...,
) -> Dict[str, Any]:
    ...
  1. See ResourceAttributeTypeDef
# put_resource_attributes method usage example with argument unpacking

kwargs: PutResourceAttributesRequestRequestTypeDef = {  # (1)
    "ProgressUpdateStream": ...,
    "MigrationTaskName": ...,
    "ResourceAttributeList": ...,
}

parent.put_resource_attributes(**kwargs)
  1. See PutResourceAttributesRequestRequestTypeDef

get_paginator#

Type annotations and code completion for boto3.client("mgh").get_paginator method with overloads.