WorkDocs / Client / create_folder

create_folder#

WorkDocs.Client.create_folder(**kwargs)#

Creates a folder with the specified name and parent folder.

See also: AWS API Documentation

Request Syntax

response = client.create_folder(
    AuthenticationToken='string',
    Name='string',
    ParentFolderId='string'
)
Parameters:
  • AuthenticationToken (string) – Amazon WorkDocs authentication token. Not required when using Amazon Web Services administrator credentials to access the API.

  • Name (string) – The name of the new folder.

  • ParentFolderId (string) –

    [REQUIRED]

    The ID of the parent folder.

Return type:

dict

Returns:

Response Syntax

{
    'Metadata': {
        'Id': 'string',
        'Name': 'string',
        'CreatorId': 'string',
        'ParentFolderId': 'string',
        'CreatedTimestamp': datetime(2015, 1, 1),
        'ModifiedTimestamp': datetime(2015, 1, 1),
        'ResourceState': 'ACTIVE'|'RESTORING'|'RECYCLING'|'RECYCLED',
        'Signature': 'string',
        'Labels': [
            'string',
        ],
        'Size': 123,
        'LatestVersionSize': 123
    }
}

Response Structure

  • (dict) –

    • Metadata (dict) –

      The metadata of the folder.

      • Id (string) –

        The ID of the folder.

      • Name (string) –

        The name of the folder.

      • CreatorId (string) –

        The ID of the creator.

      • ParentFolderId (string) –

        The ID of the parent folder.

      • CreatedTimestamp (datetime) –

        The time when the folder was created.

      • ModifiedTimestamp (datetime) –

        The time when the folder was updated.

      • ResourceState (string) –

        The resource state of the folder.

      • Signature (string) –

        The unique identifier created from the subfolders and documents of the folder.

      • Labels (list) –

        List of labels on the folder.

        • (string) –

      • Size (integer) –

        The size of the folder metadata.

      • LatestVersionSize (integer) –

        The size of the latest version of the folder metadata.

Exceptions

  • WorkDocs.Client.exceptions.EntityNotExistsException

  • WorkDocs.Client.exceptions.EntityAlreadyExistsException

  • WorkDocs.Client.exceptions.ProhibitedStateException

  • WorkDocs.Client.exceptions.ConflictingOperationException

  • WorkDocs.Client.exceptions.ConcurrentModificationException

  • WorkDocs.Client.exceptions.LimitExceededException

  • WorkDocs.Client.exceptions.UnauthorizedOperationException

  • WorkDocs.Client.exceptions.UnauthorizedResourceAccessException

  • WorkDocs.Client.exceptions.FailedDependencyException

  • WorkDocs.Client.exceptions.ServiceUnavailableException