Assurance / Client / list_connection_items
list_connection_items¶
- Assurance.Client.list_connection_items(**kwargs)¶
Lists the items that a connection can access, one level at a time, to help you find a document without knowing its URL. The list contains only items that the connection is authorized to access. If more results are available, the response includes
nextToken. To get the next page, call this operation again with that token.To list the top level, omit
parentId. To list the contents of an item, such as a repository, site, library, or folder, specify itsid. You can’t list the contents of aFILE.See also: AWS API Documentation
Request Syntax
response = client.list_connection_items( environmentArn='string', connectionId='string', providerConfig={ 's3': { 'sourceUri': 'string' }, 'github': { 'account': 'string' }, 'sharepoint': { 'tenantId': 'string' } }, parentId='string', maxResults=123, nextToken='string' )
- Parameters:
environmentArn (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of this governance environment.
connectionId (string) –
The ID of the GitHub or SharePoint connection to browse, as returned by
ListEnvironmentConnections. An Amazon S3 connection has no ID. To browse one, useproviderConfig.Specify either
connectionIdorproviderConfig, but not both.providerConfig (dict) –
The connection to browse, identified by what it connects to.
Note
This is a Tagged Union structure. Only one of the following top level keys can be set:
s3,github,sharepoint.s3 (dict) –
An Amazon S3 connection, identified by its source URI.
sourceUri (string) – [REQUIRED]
The Amazon S3 URI of the connection. To find it, call
ListEnvironmentConnectionsand reads3.sourceUri.
github (dict) –
The account of a GitHub connection.
account (string) – [REQUIRED]
The name of the GitHub organization or user account. This is the
github.accountvalue inListEnvironmentConnections.
sharepoint (dict) –
The tenant of a SharePoint connection.
tenantId (string) – [REQUIRED]
The ID of the Microsoft Entra tenant. This is the
sharepoint.tenantIdvalue inListEnvironmentConnections.
parentId (string) – The ID of the item whose contents you want to list. To list the top level, omit this parameter.
maxResults (integer) – The maximum number of items to return on one page. If you omit it, the operation uses its default page size.
nextToken (string) – The token for the next page of results, from a previous response.
- Return type:
dict
- Returns:
Response Syntax
{ 'items': [ { 'id': 'string', 'kind': 'REPOSITORY'|'SITE'|'LIBRARY'|'FOLDER'|'FILE', 'name': 'string', 'url': 'string', 'sizeBytes': 123, 'updatedAt': datetime(2015, 1, 1) }, ], 'nextToken': 'string' }
Response Structure
(dict) –
items (list) –
The items at the requested level.
(dict) –
An item that a connection can access, such as a folder or a file.
id (string) –
The identifier of the item. To list the contents of the item, pass this value as
parentId. This doesn’t apply to aFILE.kind (string) –
The type of item. Valid values:
FILE– A document that you can link as evidence.FOLDER– A folder that contains other items.LIBRARY– A SharePoint document library.REPOSITORY– A GitHub repository.SITE– A SharePoint site.
name (string) –
The display name of the item.
url (string) –
The URL of the item. This field is present for a
FILE. To add the file as evidence, pass this value asreferencetoPutEvidence.sizeBytes (integer) –
The size of the item in bytes. This field is present for a
FILE.updatedAt (datetime) –
The time when the provider last recorded a change to the item. This field is present for a
FILE.
nextToken (string) –
The token to pass to get the next page of results. Absent on the last page.
Exceptions