> ## 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.

# Get libraryv1

> Gets a library.



## OpenAPI

````yaml /openapis/library.json get /library/v1/{libId}
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/{libId}:
    get:
      tags:
        - library
      description: Gets a library.
      operationId: library:v1beta1.Library.getLibrary
      parameters:
        - $ref: '#/components/parameters/libId_path_parameter'
        - $ref: '#/components/parameters/include_query_parameter'
        - name: updateLastAccessed
          in: query
          description: >-
            Whether to update the lastAccessed field of the library for the
            current user
          required: false
          schema:
            type: boolean
            default: false
        - $ref: '#/components/parameters/securityCode_query_parameter'
        - $ref: '#/components/parameters/domain_query_parameter'
      responses:
        '200':
          description: A ApiLibrary response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiLibrary'
      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:
    libId_path_parameter:
      name: libId
      in: path
      description: The ID of the library
      required: true
      schema:
        type: string
    include_query_parameter:
      name: include
      in: query
      description: >-
        To filter the list of fields to have in the response (everything if left
        empty). The possible choices are: 'NONE', 'CLASSES',
        'CATEGORY_DEFINITIONS', 'VIEWS', 'FOLDER_DEFINITION', 'WORKFLOWS',
        'RELATIONS', 'PERMISSIONS', 'LIBRARY_LABELS'
      required: false
      explode: true
      schema:
        type: array
        items:
          type: string
    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:
    ApiLibrary:
      type: object
      properties:
        allowNonGoogleUsersInDriveOnlyPermissions:
          type: boolean
          description: >-
            Allows sharing Google Drive attachments with non Google email
            addresses
        appMetadata:
          type: object
          description: >-
            App Metadata let developers associate metadata with various
            configuration entities. The metadata is isolated within app
            namespaces in order to prevent one application from interfering with
            another's metadata.
          additionalProperties:
            $ref: '#/components/schemas/ApiNamespacedAppMetadata'
        attachmentMode:
          type: string
          description: Type of the library (it cannot be changed after the creation)
          enum:
            - COMPOSITE
            - GOOGLE_DRIVE
            - DRIVE_CONTROLLED
        attachmentSearchEngine:
          type: string
          description: Engine to index and search the content of attachments
          enum:
            - DRIVE
            - AODOCS
        calendarId:
          type: string
          description: ID of the calendar used to compute business days for this library
        categoryDefinitions:
          $ref: '#/components/schemas/ApiNameValueList'
        createdAt:
          type: integer
          format: int64
          description: The instant this resource was created (read-only
        creator:
          type: string
          description: Creator of the library (read-only)
        currentUserRight:
          type: string
          description: Permission of the current user on the library (read-only)
          enum:
            - NONE
            - READER
            - COMMENTER
            - PROPERTY_EDITOR
            - ATTACHMENT_EDITOR
            - WRITER
            - ADMIN
            - SUPER_ADMIN
        daysBeforeDelete:
          type: integer
          format: int32
          description: The number of days before a trashed document is permanently deleted
        defaultDocumentType:
          type: string
          description: Default document class for the library
        defaultOnlyAdminCanDelete:
          type: boolean
          description: onlyAdminCanDelete setting of the default class (read-only)
        defaultOnlyAdminCanShare:
          type: boolean
          description: onlyAdminCanShare setting of the default class (read-only)
        defaultView:
          type: string
          description: ID of the default view
        documentTypes:
          $ref: '#/components/schemas/ApiNameValueList'
        domainName:
          type: string
          description: The domain the library belong to (read-only)
        driveShortcuts:
          $ref: '#/components/schemas/ApiDriveShortcutOperation'
        enableExternalSharingInDriveOnlyPermissions:
          type: boolean
          description: >-
            Allows sharing Google Drive attachments with users and groups which
            might not be part of the AODocs tenant allowlists
        favorited:
          type: boolean
          description: Whether this library is starred by the current user (read only)
        findableBy:
          type: string
          description: >-
            Determines which users the library will appear to in searches and
            listings.
          enum:
            - READERS
            - CONTRIBUTORS
            - ADMINS
            - NONE
        folderDefinition:
          $ref: '#/components/schemas/ApiFolderDefinition'
        forwardRequestAccessRole:
          type: string
          description: >-
            Sharing requests are forwarded to the users of this role (defaults
            to Administrators)
        historyVisibility:
          $ref: '#/components/schemas/ApiSecurityToken'
        homeUrl:
          type: string
          description: A short URL to access the library
        kind:
          type: string
        lastAccessed:
          type: integer
          format: int64
          description: The instant the current user last accessed this library (read-only)
        lastConfigModified:
          type: integer
          format: int64
          description: >-
            The instant the library configuration was last modified (not only
            this resource) (read only)
        lastModified:
          type: integer
          format: int64
          description: The instant this resource was last modified (read-only)
        libraryId:
          type: string
          description: The ID of the library
        libraryLabels:
          type: array
          description: Labels of the library
          items:
            $ref: '#/components/schemas/ApiReferenceCatalogValue'
        locale:
          type: string
          description: >-
            The locale defines the user's language and is used to display fields
            whose output format may change given this setting
        logoUrl:
          type: string
          description: >-
            The url of the logo for the library (expected size is 240x103, with
            transparent background)
        name:
          type: string
          description: The name of the library
        name_i18n:
          type: string
          description: The internationalized name of the library (read-only)
        notifyUsersAboutPushToMyDrive:
          type: boolean
          description: >-
            Whether the users of the library should receive a notification when
            it is pushed to their My Drive
        objectStorageLocation:
          type: string
          description: >-
            Location of the bucket to store attachments, either a customer owned
            bucket or a AODocs owned bucket(AODOCS_MANAGED)
        onlyAdminsCanEditRootFolder:
          type: boolean
          description: >-
            Whether only the admins can create, move or delete document and
            subfolders in the root of library (true is only supported on Secured
            Folder library type)
        onlyAdminsCanManageFolders:
          type: boolean
          description: >-
            Whether only the admins can manage folders (true is not supported on
            Team Folder library type)
        permissionMode:
          type: string
          description: Permission mode of the library
          enum:
            - HIGH_SECURITY_PRISON
            - LOW_SECURITY_PRISON
            - CLUB_MED
        permissions:
          type: array
          description: Permissions for the library
          items:
            $ref: '#/components/schemas/ApiLibraryPermission'
        pushToMyDrive:
          type: boolean
          description: >-
            Whether the Push to My Drive feature is enabled for this library
            (Team Folders and Secure Folders libraries only)
        redirectUrl:
          type: string
          description: An optional URL to redirect to when accessing the library
        relations:
          type: array
          description: >-
            Deprecated - List of relations on the library (read-only) - use the
            relation API instead
          items:
            $ref: '#/components/schemas/ApiRelation'
        restrictedDownload:
          type: boolean
          description: >-
            Whether document readers should be allowed to download, copy or
            print (library level configuration)
        rootFolderId:
          type: string
          description: ID of the root folder of the library (read-only)
        sequenceId:
          type: integer
          format: int64
          description: Sequence id of the library (read-only)
        state:
          type: string
          description: >-
            State of the library (The update is possible between the following
            states: STANDARD, ARCHIVED for SuperAdmin users
          enum:
            - INITIALIZING
            - STANDARD
            - ARCHIVED
            - DELETING
        storageAdmin:
          type: string
          description: >-
            The storage account for this library (cannot be modified after the
            creation)
        technicalNotificationAddress:
          type: string
          description: The email address that should be notified of custom script failures
        timeZone:
          type: string
          description: >-
            The timezone id of the library used to used to format times in sent
            emails. Formatted as a IANA Time Zone Database Name (ie:
            'Europe/Paris', see: http://www.iana.org/time-zones).
        trashResourceId:
          type: string
          description: ID of the trash folder of the library (read-only)
        views:
          $ref: '#/components/schemas/ApiDisplayableNameValueList'
        visibility:
          $ref: '#/components/schemas/ApiLibraryVisibility'
        welcomeText:
          type: string
          description: The rich text displayed on the library homepage (accepts HTML)
        wokflows:
          $ref: '#/components/schemas/ApiWorkflowList'
    ApiNamespacedAppMetadata:
      type: object
      properties:
        appNamespaceId:
          type: string
          description: The id of the app namespace (read-only)
        kind:
          type: string
        tags:
          type: array
          description: The list of tags (name/value) in the namespace (limited to 10 items)
          items:
            $ref: '#/components/schemas/ApiAppMetadataTag'
    ApiNameValueList:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/ApiNameValue'
        kind:
          type: string
    ApiDriveShortcutOperation:
      type: object
      properties:
        sameLibrary:
          type: string
          enum:
            - KEEP
            - MOVE
    ApiFolderDefinition:
      type: object
      properties:
        dynamicValues:
          type: boolean
        folderId:
          type: string
        folderVisibility:
          type: string
          enum:
            - PRIVATE
            - PUBLIC
            - PUBLICLY_EDITABLE
        id:
          type: string
        kind:
          type: string
        libraryId:
          type: string
        name:
          type: string
        onlyAdminCanEditRootFolder:
          type: boolean
        onlyAdminCanManage:
          type: boolean
    ApiSecurityToken:
      type: object
      properties:
        classId:
          type: string
          description: The ID of the class when type = FIELD
        className:
          type: string
          description: The name of the class when type = FIELD
        description:
          type: string
          description: The description for type in GROUP, ROLE, FIELD
        displayName:
          type: string
          description: >-
            The display name of the user or group, the name of the role
            (read-only field)
        displayName_i18n:
          type: string
          description: >-
            The display name of the user or group, the internationalized name of
            the role (read-only field)
        thumbnailPictureUrl:
          type: string
          description: The URL of the thumbnail picture (especially for users)
        type:
          type: string
          description: >-
            The type of person (user, group, role, field based, domain i.e.
            everybody)
          enum:
            - USER
            - GROUP
            - ROLE
            - FIELD
            - DOMAIN
        value:
          type: string
          description: >-
            The email address if user or group, the ID of the role, the ID of
            the class/field (ignored if type = DOMAIN)
    ApiReferenceCatalogValue:
      type: object
      properties:
        createdAt:
          type: integer
          format: int64
          description: >-
            The timestamp (in ms) at which the catalog value was created
            (read-only field)
        deleted:
          type: boolean
          description: Whether the catalog value should be marked as deleted
        id:
          type: string
          description: The ID of the reference catalog value
        kind:
          type: string
        lastModifiedAt:
          type: integer
          format: int64
          description: >-
            The timestamp (in ms) at which the catalog value was last modified
            (read-only field)
        leaf:
          type: boolean
          description: Whether the value has children values (read-only field)
        level:
          type: integer
          format: int32
          description: >-
            The level of the reference catalog value in the hieararchical
            structure. Level 0 is the first level that has no ancestors
            (read-only field)
        name:
          type: string
          description: The name of the reference catalog value
        parent:
          type: string
          description: The id of the parent of the reference catalog value
        parentIds:
          type: array
          description: >-
            The id's of the ancestors of the reference catalog value (read-only
            field)
          items:
            type: string
        rank:
          type: integer
          format: int32
          description: >-
            Rank of the reference catalog value used for sorting, accepting
            positive integers only
        referenceCatalogId:
          type: string
          description: The ID of the reference catalog (read-only field)
    ApiLibraryPermission:
      type: object
      properties:
        kind:
          type: string
        name:
          type: string
        role:
          type: string
        thumbnailPhotoUrl:
          type: string
        type:
          type: string
        value:
          type: string
        withLink:
          type: boolean
    ApiRelation:
      type: object
      properties:
        description:
          type: string
        fromDescending:
          type: boolean
        fromDisplayColumns:
          type: array
          items:
            $ref: '#/components/schemas/ApiNameValue'
        fromId:
          type: string
        fromName:
          type: string
        fromName_i18n:
          type: string
        fromSort:
          type: string
        id:
          type: string
        kind:
          type: string
        libraryId:
          type: string
        name:
          type: string
        name_i18n:
          type: string
        selfRelated:
          type: boolean
        toDescending:
          type: boolean
        toDisplayColumns:
          type: array
          items:
            $ref: '#/components/schemas/ApiNameValue'
        toId:
          type: string
        toName:
          type: string
        toName_i18n:
          type: string
        toSort:
          type: string
    ApiDisplayableNameValueList:
      type: object
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/ApiDisplayableNameValue'
        kind:
          type: string
    ApiLibraryVisibility:
      type: object
      properties:
        level:
          type: string
          enum:
            - READ
            - WRITE
        scope:
          type: string
          enum:
            - NONE
            - DOMAIN
            - WEB
        withLink:
          type: boolean
    ApiWorkflowList:
      type: object
      properties:
        kind:
          type: string
        workflows:
          type: array
          items:
            $ref: '#/components/schemas/ApiWorkflow'
    ApiAppMetadataTag:
      type: object
      properties:
        kind:
          type: string
        name:
          type: string
          description: The name of the tag
        stringValue:
          type: string
          description: The value of the tag as a String
    ApiNameValue:
      type: object
      properties:
        kind:
          type: string
        name:
          type: string
          description: The name
        name_i18n:
          type: string
          description: The internationalized name
        value:
          type: string
          description: The value
    ApiDisplayableNameValue:
      type: object
      properties:
        canDisplay:
          type: boolean
        kind:
          type: string
        name:
          type: string
          description: The name
        name_i18n:
          type: string
          description: The internationalized name
        value:
          type: string
          description: The value
    ApiWorkflow:
      type: object
      properties:
        classId:
          type: string
        id:
          type: string
        kind:
          type: string
        name:
          type: string
        name_i18n:
          type: string
        states:
          type: array
          items:
            $ref: '#/components/schemas/ApiWorkflowState'
    ApiWorkflowState:
      type: object
      properties:
        description:
          type: string
        displayFlags:
          type: array
          items:
            type: string
            enum:
              - HIDDEN_FROM_WORKFLOW_TASKS
              - HIDDEN_FROM_BROWSEBY
              - HIDDEN_FROM_VIEW_FILTERS
        kind:
          type: string
        name:
          type: string
          description: The name
        name_i18n:
          type: string
          description: The internationalized name
        noAction:
          type: boolean
        transitions:
          type: array
          items:
            $ref: '#/components/schemas/ApiStateTransition'
        value:
          type: string
          description: The value
    ApiStateTransition:
      type: object
      properties:
        commentPolicy:
          type: string
          enum:
            - FORBIDDEN
            - OPTIONAL
            - MANDATORY
        condition:
          type: string
        fromStateId:
          type: string
        fromStateName:
          type: string
        fromStateName_i18n:
          type: string
        id:
          type: string
        kind:
          type: string
        mandatoryComment:
          type: boolean
        name:
          type: string
        name_i18n:
          type: string
        parallel:
          type: boolean
        targetStateId:
          type: string
        targetStateName:
          type: string
        targetStateName_i18n:
          type: string
        validators:
          type: array
          items:
            $ref: '#/components/schemas/ApiValidator'
        value:
          type: string
        workflowId:
          type: string
    ApiValidator:
      type: object
      properties:
        kind:
          type: string
        user:
          $ref: '#/components/schemas/ApiBaseUserProfile'
        validated:
          type: boolean
    ApiBaseUserProfile:
      type: object
      properties:
        email:
          type: string
          description: The email of the user
        kind:
          type: string
        name:
          type: string
          description: The displayed name of the user
        nonGoogle:
          type: boolean
          description: This user is not a google user
        thumbnailPictureUrl:
          type: string
          description: The URL of the thumbnail picture of the user
  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

````