You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The API for getting or creating binaries is as follows:
OpenAPI 3.0.2 Specification
openapi: '3.0.2'info:
title: Gentics Meshversion: '2'paths:
'/{project}/nodes/{nodeUuid}/binary/{fieldPath}':
get:
summary: Downloads a binary from a node.responses:
200:
description: "A binary file"post:
summary: Uploads a binary to a node.requestBody:
content:
multipart/form-data:
schema:
type: objectproperties:
language:
description: Language of the node content which contains the binary field which should be updated.type: stringversion:
description: Version of the node which should be updated. This information is used to determine conflicting updates.type: stringbinary:
description: Single binary file part.type: stringformat: binarylistMode:
description: >- How the binary should be inserted into a list. This is ignored if the path is not a list. The following modes are available: * `append` - Appends the binary to the end of the list. * `prepend` - Puts the binary to the beginning of the list, increasing the index of all other elements. * `insert` - Inserts the binary to the given index, increasing the index of all subsequent items. * `replace` - Replaces the binary at the given index. `insert` and `replace` can only be used when an index for the binary list field is provided in the `fieldPath` path parameter. The index in `fieldPath` is ignored if the mode is `append` or `prepend`. The default value is `append` if the {fieldPath} refers to a binary list, `insert` if it refers to an element inside a list.type: stringenum: [append, prepend, insert, replace]responses:
200:
description: "The node response of the updated node."400:
description: "Invalid listMode."parameters:
- $ref: '#/components/parameters/projectParam'
- $ref: '#/components/parameters/nodeUuidParam'
- $ref: '#/components/parameters/fieldPathParam'components:
parameters:
projectParam:
name: projectin: pathdescription: The project of the node.required: trueschema:
type: stringnodeUuidParam:
name: nodeUuidin: pathdescription: The uuid of the node.required: trueschema:
type: stringfieldPathParam:
name: fieldPathin: pathdescription: >- `{fieldPath}` describes the location of a field inside a node. All indices for list fields are zero-based. This table gives examples for all cases:| Field | Path | Example ||-------------------------------------|-----------------------------------------------------------------------------|-----------------------|| Field |`{fieldName}`| `image` || List field |`{fieldName}/{index}`| `images/2` || Field in micronode field |`{micronodeFieldName}/{fieldName}`| `header/image` || Field in micronode list |`{micronodeFieldName}/{micronodeIndex}/{fieldName}`| `contents/1/image` || Field list in micronode |`{micronodeFieldName}/{fieldName}/{fieldIndex}`| `content/images/3` || Field list in micronode list |`{micronodeFieldName}/{micronodeIndex}/{fieldName}/{fieldIndex}`| `contents/2/images/1` |required: trueschema:
type: string
Use https://editor.swagger.io/ and insert the above specification to view the documentation.
Webroot requests to list items or binaries in micronodes are not possible.
Additionally, the binary uuid should be exposed in the node response to allow for removing or reordering binaries in a list, similar to micronode lists.
The text was updated successfully, but these errors were encountered:
Maybe it would be easier and more consistent to use a dedicated endpoint to CRUD binary data. This way we would not clutter and over-complicate the current node API.
The API for getting or creating binaries is as follows:
OpenAPI 3.0.2 Specification
Use https://editor.swagger.io/ and insert the above specification to view the documentation.
Webroot requests to list items or binaries in micronodes are not possible.
Additionally, the binary uuid should be exposed in the node response to allow for removing or reordering binaries in a list, similar to micronode lists.
The text was updated successfully, but these errors were encountered: