> ## Documentation Index
> Fetch the complete documentation index at: https://api.aodocs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Post libraryv1library 1

> Creates a library on the domain.



## OpenAPI

````yaml /openapis/library.json post /library/v1/library/{libraryName}
openapi: 3.0.1
info:
  description: "The AODocs REST API exposes most of the features of AODocs. It can be used to implement custom applications, third-party integration, bulk tools, or\n\t\t\t\t\t\t\t\t\t\tjust to experiment with AODocs."
  version: '69.4'
  title: AODocs REST API
servers:
  - url: https://aodocs.altirnao.com/api
security: []
tags:
  - name: library
    description: >-
      Lets you list existing libraries, create new libraries, get storage
      account e-mail (beta version, subject to change)
paths:
  /library/v1/library/{libraryName}:
    post:
      tags:
        - library
      description: Creates a library on the domain.
      operationId: library:v1beta1.Library.createLibrary
      parameters:
        - name: libraryName
          in: path
          description: The name of the library
          required: true
          schema:
            type: string
        - name: storageAdmin
          in: query
          description: >-
            The email address of the storage account. If empty, the default
            storage account will be used.
          required: false
          schema:
            type: string
        - name: libraryTemplateId
          in: query
          description: >-
            The ID of a library template (can be empty if either source library
            ID or Drive folder ID is not). To create standard library types, use
            one of: DOCUMENT_MANAGEMENT, TEAM_FOLDER, SECURED_FOLDER (short
            versions are also supported: DMS, TF, SF).
          required: false
          schema:
            type: string
        - name: sourceLibraryId
          in: query
          description: >-
            The ID of a library in the same domain to create the library from
            (can be empty if either template library ID or Drive folder ID is
            not)
          required: false
          schema:
            type: string
        - name: driveFolderId
          in: query
          description: >-
            The ID of a Drive folder that will become the root folder of the new
            library (can be empty if either template library ID or source
            library ID is not). All files within this folder will be imported
            into the new library.
          required: false
          schema:
            type: string
        - name: objectStorageLocation
          in: query
          description: >-
            Location of the bucket to store attachments, either a customer owned
            bucket or a AODocs owned bucket(AODOCS_MANAGED)
          required: false
          schema:
            type: string
        - $ref: '#/components/parameters/securityCode_query_parameter'
        - $ref: '#/components/parameters/domain_query_parameter'
        - name: locale
          in: query
          description: The locale of the library
          required: false
          schema:
            type: string
        - name: keepDocumentCreationDate
          in: query
          description: >-
            Whether the documents copied from template library have their
            creation date set based on the original document's creation date.
            Else it will be the library's creation date
          required: false
          schema:
            type: boolean
            default: false
        - name: documentCopyMode
          in: query
          description: >-
            The mode of copy of the documents when creating the library from a
            template library (default value: NO_VERSION) or by copy from a
            source library (default value: NONE). The possible values are:
            'NONE' (no document is copied), 'NO_VERSION' (only the head version
            of the documents is copied), 'WITH_VERSION' (all versions of the
            documents are copied)
          required: false
          schema:
            type: string
            enum:
              - NONE
              - NO_VERSION
              - WITH_VERSION
      responses:
        '200':
          description: A ApiCreateLibraryResponse response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiCreateLibraryResponse'
      security:
        - google_id_token-a99f12e0:
            - https://www.googleapis.com/auth/userinfo.email
        - google_id_token_legacy-a99f12e0:
            - https://www.googleapis.com/auth/userinfo.email
components:
  parameters:
    securityCode_query_parameter:
      name: securityCode
      in: query
      description: The security code
      required: false
      schema:
        type: string
    domain_query_parameter:
      name: domain
      in: query
      description: The G Suite domain
      required: false
      schema:
        type: string
  schemas:
    ApiCreateLibraryResponse:
      type: object
      properties:
        jobId:
          type: string
        kind:
          type: string
        libraryId:
          type: string
        libraryName:
          type: string
  securitySchemes:
    google_id_token-a99f12e0:
      type: oauth2
      x-google-issuer: https://accounts.google.com
      x-google-jwks_uri: https://www.googleapis.com/oauth2/v1/certs
      x-google-audiences: >-
        755040865326-h5gomu85549lkh2qf9d3lku39vnaf6ii.apps.googleusercontent.com,563231141203-231sn7f6ptedncun5h00h7ktbe3o2nd5.apps.googleusercontent.com,993707107224.apps.googleusercontent.com,ao-docs,aodocs-core-eu-1,ao-docs-staging,ao-docs-dev,aodocs-core-dev-us,aodocs-total-poc-euw3
      flows:
        implicit:
          authorizationUrl: https://accounts.google.com/o/oauth2/v2/auth
          scopes:
            https://www.googleapis.com/auth/userinfo.email: View your email address
    google_id_token_legacy-a99f12e0:
      type: oauth2
      x-google-issuer: accounts.google.com
      x-google-jwks_uri: https://www.googleapis.com/oauth2/v1/certs
      x-google-audiences: >-
        755040865326-h5gomu85549lkh2qf9d3lku39vnaf6ii.apps.googleusercontent.com,563231141203-231sn7f6ptedncun5h00h7ktbe3o2nd5.apps.googleusercontent.com,993707107224.apps.googleusercontent.com,ao-docs,aodocs-core-eu-1,ao-docs-staging,ao-docs-dev,aodocs-core-dev-us,aodocs-total-poc-euw3
      flows:
        implicit:
          authorizationUrl: https://accounts.google.com/o/oauth2/v2/auth
          scopes:
            https://www.googleapis.com/auth/userinfo.email: View your email address

````