DataZone / Client / revoke_subscription

revoke_subscription#

DataZone.Client.revoke_subscription(**kwargs)#

Revokes a specified subscription in Amazon DataZone.

See also: AWS API Documentation

Request Syntax

response = client.revoke_subscription(
    domainIdentifier='string',
    identifier='string',
    retainPermissions=True|False
)
Parameters:
  • domainIdentifier (string) –

    [REQUIRED]

    The identifier of the Amazon DataZone domain where you want to revoke a subscription.

  • identifier (string) –

    [REQUIRED]

    The identifier of the revoked subscription.

  • retainPermissions (boolean) – Specifies whether permissions are retained when the subscription is revoked.

Return type:

dict

Returns:

Response Syntax

{
    'createdAt': datetime(2015, 1, 1),
    'createdBy': 'string',
    'domainId': 'string',
    'id': 'string',
    'retainPermissions': True|False,
    'status': 'APPROVED'|'REVOKED'|'CANCELLED',
    'subscribedListing': {
        'description': 'string',
        'id': 'string',
        'item': {
            'assetListing': {
                'entityId': 'string',
                'entityRevision': 'string',
                'entityType': 'string',
                'forms': 'string',
                'glossaryTerms': [
                    {
                        'name': 'string',
                        'shortDescription': 'string'
                    },
                ]
            }
        },
        'name': 'string',
        'ownerProjectId': 'string',
        'ownerProjectName': 'string',
        'revision': 'string'
    },
    'subscribedPrincipal': {
        'project': {
            'id': 'string',
            'name': 'string'
        }
    },
    'subscriptionRequestId': 'string',
    'updatedAt': datetime(2015, 1, 1),
    'updatedBy': 'string'
}

Response Structure

  • (dict) –

    • createdAt (datetime) –

      The timestamp of when the subscription was revoked.

    • createdBy (string) –

      The identifier of the user who revoked the subscription.

    • domainId (string) –

      The identifier of the Amazon DataZone domain where you want to revoke a subscription.

    • id (string) –

      The identifier of the revoked subscription.

    • retainPermissions (boolean) –

      Specifies whether permissions are retained when the subscription is revoked.

    • status (string) –

      The status of the revoked subscription.

    • subscribedListing (dict) –

      The subscribed listing of the revoked subscription.

      • description (string) –

        The description of the published asset for which the subscription grant is created.

      • id (string) –

        The identifier of the published asset for which the subscription grant is created.

      • item (dict) –

        The published asset for which the subscription grant is created.

        Note

        This is a Tagged Union structure. Only one of the following top level keys will be set: assetListing. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

        'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
        
        • assetListing (dict) –

          The asset for which the subscription grant is created.

          • entityId (string) –

            The identifier of the published asset for which the subscription grant is created.

          • entityRevision (string) –

            The revision of the published asset for which the subscription grant is created.

          • entityType (string) –

            The type of the published asset for which the subscription grant is created.

          • forms (string) –

            The forms attached to the published asset for which the subscription grant is created.

          • glossaryTerms (list) –

            The glossary terms attached to the published asset for which the subscription grant is created.

            • (dict) –

              Details of a glossary term attached to the inventory asset.

              • name (string) –

                The name of a glossary term attached to the inventory asset.

              • shortDescription (string) –

                The shoft description of a glossary term attached to the inventory asset.

      • name (string) –

        The name of the published asset for which the subscription grant is created.

      • ownerProjectId (string) –

        The identifier of the project of the published asset for which the subscription grant is created.

      • ownerProjectName (string) –

        The name of the project that owns the published asset for which the subscription grant is created.

      • revision (string) –

        The revision of the published asset for which the subscription grant is created.

    • subscribedPrincipal (dict) –

      The subscribed principal of the revoked subscription.

      Note

      This is a Tagged Union structure. Only one of the following top level keys will be set: project. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

      'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
      
      • project (dict) –

        The project that has the subscription grant.

        • id (string) –

          The identifier of the project that has the subscription grant.

        • name (string) –

          The name of the project that has the subscription grant.

    • subscriptionRequestId (string) –

      The identifier of the subscription request for the revoked subscription.

    • updatedAt (datetime) –

      The timestamp of when the subscription was revoked.

    • updatedBy (string) –

      The Amazon DataZone user who revoked the subscription.

Exceptions

  • DataZone.Client.exceptions.InternalServerException

  • DataZone.Client.exceptions.ResourceNotFoundException

  • DataZone.Client.exceptions.AccessDeniedException

  • DataZone.Client.exceptions.ThrottlingException

  • DataZone.Client.exceptions.ConflictException

  • DataZone.Client.exceptions.ValidationException

  • DataZone.Client.exceptions.UnauthorizedException