REST

To consume REST web services.
FlowerDocs Core exhibits its services as REST web services that can be consumed from different technologies.

Base URL

All REST endpoints are served under:

{host.core}/rest/

Authentication

Every request must include a token header. Obtain a token by authenticating via:

POST {host.core}/rest/authentication HTTP/1.1
Content-Type: application/json

See the authentication example for details.

Common patterns

The REST API follows a consistent CRUD pattern across all resource types:

Operation HTTP method URL pattern
Retrieve GET /rest/{resource}/{ids}
Create POST /rest/{resource}
Update POST /rest/{resource}/{ids}
Delete DELETE /rest/{resource}/{ids}

Where {ids} is one or more identifiers separated by commas.

Content type

All request and response bodies use application/json, except for file upload endpoints which use multipart/form-data.

Batch operations

Most endpoints accept arrays, allowing you to create, update, or delete multiple items in a single request.

Important note on updates


REST updates operate on a cancel and replace basis: unset fields will be cleared. You must send the entire object, not just the fields to modify. It is recommended to first retrieve the resource, make changes, and then call the update endpoint.

Swagger documentation

Documentation for this API is provided through Swagger exhibited by FlowerDocs Core under the path {host.core}/swagger-ui/index.html. You can also find the Swagger in our online demo environment here.

Examples

Detailed usage examples for each resource type are available in the examples section.