Amazon Redshift

2023/10/26 - Amazon Redshift - 4 new api methods

Changes  Add Redshift APIs GetResourcePolicy, DeleteResourcePolicy, PutResourcePolicy and DescribeInboundIntegrations for the new Amazon Redshift Zero-ETL integration feature, which can be used to control data ingress into Redshift namespace, and view inbound integrations.

DescribeInboundIntegrations (new) Link ¶

Returns a list of inbound integrations.

See also: AWS API Documentation

Request Syntax

client.describe_inbound_integrations(
    IntegrationArn='string',
    TargetArn='string',
    MaxRecords=123,
    Marker='string'
)
type IntegrationArn

string

param IntegrationArn

The Amazon Resource Name (ARN) of the inbound integration.

type TargetArn

string

param TargetArn

The Amazon Resource Name (ARN) of the target of an inbound integration.

type MaxRecords

integer

param MaxRecords

The maximum number of response records to return in each call. If the number of remaining response records exceeds the specified MaxRecords value, a value is returned in a marker field of the response. You can retrieve the next set of records by retrying the command with the returned marker value.

Default: 100

Constraints: minimum 20, maximum 100.

type Marker

string

param Marker

An optional parameter that specifies the starting point to return a set of response records. When the results of a DescribeInboundIntegrations request exceed the value specified in MaxRecords , Amazon Web Services returns a value in the Marker field of the response. You can retrieve the next set of response records by providing the returned marker value in the Marker parameter and retrying the request.

rtype

dict

returns

Response Syntax

{
    'Marker': 'string',
    'InboundIntegrations': [
        {
            'IntegrationArn': 'string',
            'SourceArn': 'string',
            'TargetArn': 'string',
            'Status': 'creating'|'active'|'modifying'|'failed'|'deleting'|'syncing'|'needs_attention',
            'Errors': [
                {
                    'ErrorCode': 'string',
                    'ErrorMessage': 'string'
                },
            ],
            'CreateTime': datetime(2015, 1, 1)
        },
    ]
}

Response Structure

  • (dict) --

    • Marker (string) --

      A value that indicates the starting point for the next set of response records in a subsequent request. If a value is returned in a response, you can retrieve the next set of records by providing this returned marker value in the Marker parameter and retrying the command. If the Marker field is empty, all response records have been retrieved for the request.

    • InboundIntegrations (list) --

      A list of InboundIntegration instances.

      • (dict) --

        The content of an inbound integration.

        • IntegrationArn (string) --

          The Amazon Resource Name (ARN) of an inbound integration.

        • SourceArn (string) --

          The Amazon Resource Name (ARN) of the source of an inbound integration.

        • TargetArn (string) --

          The Amazon Resource Name (ARN) of the target of an inbound integration.

        • Status (string) --

          The status of an inbound integration.

        • Errors (list) --

          The outstanding errors of an inbound integration. Each item is an "IntegrationError". This is null if there is no error.

          • (dict) --

            The error of an inbound integration.

            • ErrorCode (string) --

              The error code of an inbound integration error.

            • ErrorMessage (string) --

              The error message of an inbound integration error.

        • CreateTime (datetime) --

          The creation time of an inbound integration.

GetResourcePolicy (new) Link ¶

Get the resource policy for a specified resource.

See also: AWS API Documentation

Request Syntax

client.get_resource_policy(
    ResourceArn='string'
)
type ResourceArn

string

param ResourceArn

[REQUIRED]

The Amazon Resource Name (ARN) of the resource of which its resource policy is fetched.

rtype

dict

returns

Response Syntax

{
    'ResourcePolicy': {
        'ResourceArn': 'string',
        'Policy': 'string'
    }
}

Response Structure

  • (dict) --

    • ResourcePolicy (dict) --

      The content of the resource policy.

      • ResourceArn (string) --

        The resources that a policy is attached to.

      • Policy (string) --

        The content of a resource policy.

PutResourcePolicy (new) Link ¶

Updates the resource policy for a specified resource.

See also: AWS API Documentation

Request Syntax

client.put_resource_policy(
    ResourceArn='string',
    Policy='string'
)
type ResourceArn

string

param ResourceArn

[REQUIRED]

The Amazon Resource Name (ARN) of the resource of which its resource policy is updated.

type Policy

string

param Policy

[REQUIRED]

The content of the resource policy being updated.

rtype

dict

returns

Response Syntax

{
    'ResourcePolicy': {
        'ResourceArn': 'string',
        'Policy': 'string'
    }
}

Response Structure

  • (dict) --

    • ResourcePolicy (dict) --

      The content of the updated resource policy.

      • ResourceArn (string) --

        The resources that a policy is attached to.

      • Policy (string) --

        The content of a resource policy.

DeleteResourcePolicy (new) Link ¶

Deletes the resource policy for a specified resource.

See also: AWS API Documentation

Request Syntax

client.delete_resource_policy(
    ResourceArn='string'
)
type ResourceArn

string

param ResourceArn

[REQUIRED]

The Amazon Resource Name (ARN) of the resource of which its resource policy is deleted.

returns

None