openapi: 3.0.1 info: license: name: Apache 2.0 url: http://www.apache.org/licenses/LICENSE-2.0.html title: Benchling AA Sequences Folders API version: 2.0.0 description: 'AA Sequences are the working units of cells that make everything run (they help make structures, catalyze reactions and allow for signaling - a kind of internal cell communication). On Benchling, these are comprised of a string of amino acids and collections of other attributes, such as annotations. ' servers: - url: /api/v2 security: - oAuth: [] - basicApiKeyAuth: [] tags: - description: Folders are nested within projects to provide additional organization. name: Folders paths: /folders: get: description: List folders operationId: listFolders parameters: - in: query name: nextToken schema: type: string - in: query name: pageSize schema: default: 50 maximum: 100 minimum: 0 nullable: false type: integer - description: 'Method by which to order search results. Valid sorts are modifiedAt (modified time, most recent first) and name (folder name, alphabetical). Optionally add :asc or :desc to specify ascending or descending order. ' in: query name: sort schema: default: name enum: - createdAt - createdAt:asc - createdAt:desc - modifiedAt - name - modifiedAt:asc - name:asc - modifiedAt:desc - name:desc nullable: false type: string - description: 'Archive reason. Restricts items to those with the specified archive reason. Use "NOT_ARCHIVED" to filter for unarchived folders. Use "ANY_ARCHIVED" to filter for archived folders regardless of reason. Use "ANY_ARCHIVED_OR_NOT_ARCHIVED" to return items for both archived and unarchived. ' examples: 1_not_archived: summary: Only include unarchived items (default). value: NOT_ARCHIVED 2_archived_reason: summary: Includes items archived for a specific reason. value: Retired 3_any_archived: summary: Includes items archived for any reason. value: ANY_ARCHIVED 4_any_archived_or_not_archived: summary: Includes both archived and unarchived items. value: ANY_ARCHIVED_OR_NOT_ARCHIVED in: query name: archiveReason schema: type: string - description: 'Name substring of a folder. Restricts results to those with names that include the provided substring. ' in: query name: nameIncludes schema: type: string - description: ID of a folder. Restricts results to those in the folder. Use "NO_PARENT" to filter for root folders. in: query name: parentFolderId schema: type: string - description: ID of a project. Restricts results to those in the project. in: query name: projectId schema: type: string - description: 'Comma-separated list of ids. Matches all of the provided IDs, or returns a 400 error that includes a list of which IDs are invalid. ' in: query name: ids schema: example: lib_qQFY3WQH,lib_QvXryHdi,lib_3eF8mZjn type: string - description: Name of a folder. Restricts results to those with the specified name. in: query name: name schema: type: string - deprecated: true description: 'Deprecated - Folder types have been merged, however this will restrict to the pre-merge types. ' in: query name: section schema: enum: - INVENTORY - NOTEBOOK type: string responses: '200': content: application/json: schema: $ref: '#/components/schemas/FoldersPaginatedList' description: OK summary: List folders tags: - Folders post: description: Create folder operationId: createFolder requestBody: content: application/json: schema: $ref: '#/components/schemas/FolderCreate' responses: '201': content: application/json: schema: $ref: '#/components/schemas/Folder' description: Created '400': content: application/json: schema: $ref: '#/components/schemas/BadRequestError' description: Bad Request summary: Create folder tags: - Folders /folders/{folder_id}: get: description: Get a folder by ID operationId: getFolder parameters: - description: ID of folder to get in: path name: folder_id required: true schema: type: string responses: '200': content: application/json: schema: $ref: '#/components/schemas/Folder' description: OK '404': content: application/json: schema: $ref: '#/components/schemas/NotFoundError' description: Not Found summary: Get a folder by ID tags: - Folders /folders:archive: post: description: Archives folders and their contents operationId: archiveFolders requestBody: content: application/json: schema: $ref: '#/components/schemas/FoldersArchive' responses: '200': content: application/json: schema: $ref: '#/components/schemas/FoldersArchivalChange' description: OK '400': content: application/json: schema: $ref: '#/components/schemas/BadRequestError' description: Bad Request summary: Archive folders tags: - Folders /folders:unarchive: post: description: Unarchives folders and the contents that were archived along with them operationId: unarchiveFolders requestBody: content: application/json: schema: $ref: '#/components/schemas/FoldersUnarchive' responses: '200': content: application/json: schema: $ref: '#/components/schemas/FoldersArchivalChange' description: OK '400': content: application/json: schema: $ref: '#/components/schemas/BadRequestError' description: Bad Request summary: Unarchive folders tags: - Folders components: schemas: BadRequestError: properties: error: allOf: - $ref: '#/components/schemas/BaseError' - properties: type: enum: - invalid_request_error type: string type: object FoldersUnarchive: additionalProperties: false properties: folderIds: description: A list of folder IDs to unarchive. items: type: string type: array required: - folderIds type: object NotFoundError: properties: error: allOf: - $ref: '#/components/schemas/BaseError' - properties: invalidId: type: string type: enum: - invalid_request_error type: string type: object FoldersArchive: additionalProperties: false properties: folderIds: description: A list of folder IDs to archive. items: type: string type: array reason: description: 'The reason for archiving the provided folders. Accepted reasons may differ based on tenant configuration. ' enum: - Made in error - Retired - Other type: string required: - reason - folderIds type: object FolderCreate: additionalProperties: false properties: name: description: The name of the new folder. type: string parentFolderId: description: The ID of the parent folder. type: string required: - name - parentFolderId BaseError: properties: message: type: string type: type: string userMessage: type: string type: object FoldersPaginatedList: properties: folders: items: $ref: '#/components/schemas/Folder' type: array nextToken: type: string type: object ArchiveRecord: properties: reason: example: Made in error type: string type: object FoldersArchivalChange: description: 'IDs of all items that were archived or unarchived, grouped by resource type. This includes the IDs of folders along with any IDs of folder contents that were unarchived. ' properties: aaSequenceIds: items: type: string type: array customEntityIds: items: type: string type: array dnaSequenceIds: items: type: string type: array entryIds: items: type: string type: array folderIds: items: type: string type: array mixtureIds: items: type: string type: array oligoIds: items: type: string type: array protocolIds: items: type: string type: array type: object Folder: properties: archiveRecord: allOf: - $ref: '#/components/schemas/ArchiveRecord' nullable: true readOnly: true id: readOnly: true type: string name: type: string parentFolderId: description: ID of the parent folder, if it exists nullable: true type: string projectId: description: ID of the containing project readOnly: true type: string securitySchemes: basicApiKeyAuth: description: Use issued API key for standard access to the API scheme: basic type: http basicClientIdSecretAuth: description: Auth used as part of client credentials OAuth flow prior to receiving a bearer token. scheme: basic type: http oAuth: description: OAuth2 Client Credentials flow intended for service access flows: clientCredentials: scopes: {} tokenUrl: /api/v2/token type: oauth2 externalDocs: description: Additional API Documentation url: https://docs.benchling.com