openapi: 3.0.1 servers: - url: / description: Default Server URL paths: /v2/bucket: get: tags: - Bucket summary: Get all buckets operationId: getAll responses: '200': description: OK content: application/json: schema: type: array items: type: string '204': description: No Content /v2/bucket/{bucketName}: get: tags: - Bucket summary: Get the information of a bucket operationId: bucketInfo parameters: - name: bucketName in: path required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/BucketInfo' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' post: tags: - Bucket summary: Create a bucket operationId: createBucket parameters: - name: bucketName in: path required: true schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/CreateBucketOptions' responses: '409': description: Conflict content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '201': description: Created '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' /v2/bucket/{bucketName}/index/{indexName}: put: tags: - Bucket summary: Create an index operationId: createIndex parameters: - name: bucketName in: path required: true schema: type: string - name: indexName in: path required: true schema: type: string requestBody: content: application/json: schema: nullable: true example: '[{"fieldName":"ASC"}]' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' delete: tags: - Bucket summary: Delete an index operationId: deleteIndex parameters: - name: bucketName in: path required: true schema: type: string - name: indexName in: path required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' /v2/bucket/{bucket}: delete: tags: - Bucket summary: Delete a bucket operationId: delete parameters: - name: bucket in: path required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' /v2/bucket/{name}/purge: delete: tags: - Bucket summary: Purge a bucket operationId: purge parameters: - name: name in: path required: true schema: type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' /v2/content/{bucketName}: delete: tags: - Content summary: Delete multiple documents operationId: delete_1 parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: parentId in: query schema: type: string nullable: true requestBody: content: application/json: schema: $ref: '#/components/schemas/Filter' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' /v2/content/{bucketName}/scroll: post: tags: - Content summary: Scroll bucket operationId: scroll parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: size in: query schema: type: integer format: int32 nullable: true - name: parentId in: query schema: type: string nullable: true - name: token in: query schema: type: string nullable: true - name: action in: query schema: type: array nullable: true items: $ref: '#/components/schemas/ContentAction' requestBody: content: application/json: schema: $ref: '#/components/schemas/ScrollRequest' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/TokenPage_StagingDocument_' '204': description: No Content /v2/content/{bucketName}/search: post: tags: - Content summary: Search on a bucket operationId: search parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: parentId in: query schema: type: string nullable: true - name: action in: query schema: type: array nullable: true items: $ref: '#/components/schemas/ContentAction' - name: page in: query description: Zero-based page index (0..N) schema: type: integer minimum: 0 default: 0 - name: size in: query description: The size of the page to be returned schema: type: integer minimum: 1 maximum: 100 default: 25 - name: sort in: query description: 'Sorting criteria in the format: property(,asc|desc). Default sort order is ascending. Multiple sort criteria are supported.' schema: type: array items: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/SearchRequest' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/Page_StagingDocument_' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' '204': description: No Content /v2/content/{bucketName}/{contentId}: get: tags: - Content summary: Get a document operationId: get parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: contentId in: path required: true schema: minLength: 1 type: string - name: action in: query schema: nullable: true allOf: - $ref: '#/components/schemas/ContentAction' - name: include in: query required: true explode: true schema: type: array items: type: string default: - '' - name: exclude in: query required: true explode: true schema: type: array items: type: string default: - '' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/StagingDocument' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' post: tags: - Content summary: Store content operationId: store parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: contentId in: path required: true schema: minLength: 1 type: string - name: parentId in: query schema: type: string nullable: true requestBody: content: application/json: schema: type: string examples: Example 1: value: {} Example 2: value: '[{}]' required: true responses: '201': description: Created content: application/json: schema: $ref: '#/components/schemas/StagingDocument' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' '413': description: Request Entity Too Large delete: tags: - Content summary: Delete a document operationId: delete_2 parameters: - name: bucketName in: path required: true schema: minLength: 1 type: string - name: contentId in: path required: true schema: minLength: 1 type: string responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/AcknowledgedMessage' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessage' components: schemas: AcknowledgedMessage: type: object properties: acknowledged: type: boolean BaseJsonNode: type: object allOf: - $ref: '#/components/schemas/JsonNode' - $ref: '#/components/schemas/JsonSerializable.Base' BucketContent: required: - newest - oldest type: object properties: oldest: $ref: '#/components/schemas/StagingDocument' newest: $ref: '#/components/schemas/StagingDocument' BucketIndex: required: - fields - name - unique type: object properties: name: minLength: 1 type: string fields: minItems: 1 type: array items: $ref: '#/components/schemas/Map.Entry_String.Sort.Order.Direction_' unique: type: boolean example: name: string fields: - fieldName: ASC BucketInfo: required: - config - content - documentCount - indices - name type: object properties: name: type: string documentCount: properties: STORE: type: integer format: int32 DELETE: type: integer format: int32 content: $ref: '#/components/schemas/BucketContent' indices: type: array items: $ref: '#/components/schemas/BucketIndex' config: $ref: '#/components/schemas/ObjectNode' ContainerNode_ObjectNode_: type: object allOf: - $ref: '#/components/schemas/BaseJsonNode' - $ref: '#/components/schemas/JsonNode' - $ref: '#/components/schemas/JsonSerializable.Base' ContentAction: type: string enum: - STORE - DELETE CreateBucketOptions: required: - indices type: object properties: indices: type: array items: $ref: '#/components/schemas/BucketIndex' config: type: object additionalProperties: true ErrorMessage: required: - code - messages - status type: object properties: status: type: integer format: int32 code: type: integer format: int32 messages: type: array items: type: string timestamp: type: string format: date-time Filter: type: object JsonNode: type: object allOf: - $ref: '#/components/schemas/JsonSerializable.Base' - properties: empty: type: boolean valueNode: type: boolean containerNode: type: boolean missingNode: type: boolean array: type: boolean object: type: boolean nodeType: $ref: '#/components/schemas/JsonNodeType' pojo: type: boolean number: type: boolean integralNumber: type: boolean floatingPointNumber: type: boolean short: type: boolean int: type: boolean long: type: boolean float: type: boolean double: type: boolean bigDecimal: type: boolean bigInteger: type: boolean textual: type: boolean boolean: type: boolean 'null': type: boolean binary: type: boolean _this: type: array items: type: object JsonNodeType: type: string enum: - ARRAY - BINARY - BOOLEAN - MISSING - 'NULL' - NUMBER - OBJECT - POJO - STRING JsonSerializable.Base: type: object Map.Entry_String.Sort.Order.Direction_: type: object properties: key: {} value: {} ObjectNode: type: object allOf: - $ref: '#/components/schemas/ContainerNode_ObjectNode_' - $ref: '#/components/schemas/BaseJsonNode' - $ref: '#/components/schemas/JsonNode' - $ref: '#/components/schemas/JsonSerializable.Base' - properties: nodeType: $ref: '#/components/schemas/JsonNodeType' object: type: boolean empty: type: boolean all: type: object additionalProperties: type: array items: type: object Page_StagingDocument_: type: object allOf: - $ref: '#/components/schemas/Slice_StagingDocument_' - required: - totalSize properties: totalSize: type: integer format: int64 totalPages: type: integer format: int32 Pageable: type: object allOf: - $ref: '#/components/schemas/Sort' - required: - size - sort properties: number: type: integer format: int32 size: type: integer format: int32 sort: $ref: '#/components/schemas/Sort' Projection: type: object properties: includes: type: array items: type: string excludes: type: array items: type: string ScrollRequest: type: object properties: filters: $ref: '#/components/schemas/Filter' fields: $ref: '#/components/schemas/Projection' SearchRequest: type: object properties: filters: $ref: '#/components/schemas/Filter' fields: $ref: '#/components/schemas/Projection' Slice_StagingDocument_: required: - content - pageable type: object properties: content: type: array items: $ref: '#/components/schemas/StagingDocument' pageable: $ref: '#/components/schemas/Pageable' pageNumber: type: integer format: int32 offset: type: integer format: int64 size: type: integer format: int32 empty: type: boolean numberOfElements: type: integer format: int32 Sort: required: - orderBy type: object properties: orderBy: type: array items: $ref: '#/components/schemas/Sort.Order' Sort.Order: required: - direction - ignoreCase - property type: object properties: ignoreCase: type: boolean direction: $ref: '#/components/schemas/Sort.Order.Direction' property: type: string ascending: type: boolean Sort.Order.Direction: type: string enum: - ASC - DESC StagingDocument: required: - action - checksum - content - creationTimestamp - id - lastUpdatedTimestamp - parentId - transaction type: object properties: id: type: string creationTimestamp: type: string format: date-time lastUpdatedTimestamp: type: string format: date-time parentId: type: string action: $ref: '#/components/schemas/ContentAction' checksum: type: string content: type: array items: type: object transaction: type: string TokenPage_StagingDocument_: required: - content - token type: object properties: empty: type: boolean token: type: string content: type: array items: $ref: '#/components/schemas/StagingDocument' info: title: 'Pureinsights Discovery Platform: Staging Repository API' version: 2.2.17-develop contact: name: Pureinsights Technology Ltd. url: http://pureinsights.com/