create_connection

AppRunner.Client.create_connection(**kwargs)

Create an App Runner connection resource. App Runner requires a connection resource when you create App Runner services that access private repositories from certain third-party providers. You can share a connection across multiple services.

A connection resource is needed to access GitHub repositories. GitHub requires a user interface approval process through the App Runner console before you can use the connection.

See also: AWS API Documentation

Request Syntax

response = client.create_connection(
    ConnectionName='string',
    ProviderType='GITHUB',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
Parameters
  • ConnectionName (string) --

    [REQUIRED]

    A name for the new connection. It must be unique across all App Runner connections for the Amazon Web Services account in the Amazon Web Services Region.

  • ProviderType (string) --

    [REQUIRED]

    The source repository provider.

  • Tags (list) --

    A list of metadata items that you can associate with your connection resource. A tag is a key-value pair.

    • (dict) --

      Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

      • Key (string) --

        The key of the tag.

      • Value (string) --

        The value of the tag.

Return type

dict

Returns

Response Syntax

{
    'Connection': {
        'ConnectionName': 'string',
        'ConnectionArn': 'string',
        'ProviderType': 'GITHUB',
        'Status': 'PENDING_HANDSHAKE'|'AVAILABLE'|'ERROR'|'DELETED',
        'CreatedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    • Connection (dict) --

      A description of the App Runner connection that's created by this request.

      • ConnectionName (string) --

        The customer-provided connection name.

      • ConnectionArn (string) --

        The Amazon Resource Name (ARN) of this connection.

      • ProviderType (string) --

        The source repository provider.

      • Status (string) --

        The current state of the App Runner connection. When the state is AVAILABLE , you can use the connection to create an App Runner service.

      • CreatedAt (datetime) --

        The App Runner connection creation time, expressed as a Unix time stamp.

Exceptions

  • AppRunner.Client.exceptions.InvalidRequestException
  • AppRunner.Client.exceptions.InternalServiceErrorException
  • AppRunner.Client.exceptions.ServiceQuotaExceededException