Select your cookie preferences

We use cookies and similar tools to enhance your experience, provide our services, deliver relevant advertising, and make improvements. Approved third parties also use these tools to help us deliver advertising and provide certain site features.

describe_document_permission

describe_document_permission(**kwargs)

Describes the permissions for a Amazon Web Services Systems Manager document (SSM document). If you created the document, you are the owner. If a document is shared, it can either be shared privately (by specifying a user's Amazon Web Services account ID) or publicly (All ).

See also: AWS API Documentation

Request Syntax

response = client.describe_document_permission(
    Name='string',
    PermissionType='Share',
    MaxResults=123,
    NextToken='string'
)
Parameters
  • Name (string) --

    [REQUIRED]

    The name of the document for which you are the owner.

  • PermissionType (string) --

    [REQUIRED]

    The permission type for the document. The permission type can be Share .

  • MaxResults (integer) -- The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.
  • NextToken (string) -- The token for the next set of items to return. (You received this token from a previous call.)
Return type

dict

Returns

Response Syntax

{
    'AccountIds': [
        'string',
    ],
    'AccountSharingInfoList': [
        {
            'AccountId': 'string',
            'SharedDocumentVersion': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • AccountIds (list) --

      The account IDs that have permission to use this document. The ID can be either an Amazon Web Services account or All .

      • (string) --
    • AccountSharingInfoList (list) --

      A list of Amazon Web Services accounts where the current document is shared and the version shared with each account.

      • (dict) --

        Information includes the Amazon Web Services account ID where the current document is shared and the version shared with that account.

        • AccountId (string) --

          The Amazon Web Services account ID where the current document is shared.

        • SharedDocumentVersion (string) --

          The version of the current document shared with the account.

    • NextToken (string) --

      The token for the next set of items to return. Use this token to get the next set of results.

Exceptions

  • SSM.Client.exceptions.InternalServerError
  • SSM.Client.exceptions.InvalidDocument
  • SSM.Client.exceptions.InvalidNextToken
  • SSM.Client.exceptions.InvalidPermissionType
  • SSM.Client.exceptions.InvalidDocumentOperation