Posting Versions

Two endpoints to register instance versions is provided:

1. Asynchronous Post POST /api/v1/version/async
Using this endpoint, the api will response almost instantly, and the version will be processed asynchronously, and will be ready to be queried in few seconds.
2. Synchronous Post POST /api/v1/version
Using this endpoint, the version will be processed synchronously with a bigger response time. Use this endpoint if you need this versions ready to be queried right after the register post response.

Post Struct

More than only your object instance, you can send other fields to store aditional information about the posted version?

Field Type Required Description
id UUID Yes
The identifier for this version.
This id must be generated by client. It allows the client application to refer to the posted version, in a asynchronous scenario, even if is not processed by Ichno yeat.
object object Yes
The instance to be register.
Send the current state of this instance, after all changes applied. Ichno will compare with the version registered previously and compute all changes.
metadata object No
Additional data to this version.
Use this field to add some additional data to your version. The values in this field cannot be queried, but can be retrieved when you need.
keys
[string]: string | number | boolean
(Key Value List)
Yes
Unique identifier of the instance in the clients system.
Send the id’s of this instance. It is a list to allow sending objects with composite keys. If you are registering versions from diferent instance types, you must send a type identifier as a key too, to avoid conflicts between too instances, with diferent types and same identifier.
labels
[string]: string | number | boolean
(Key Value List)
No
Version label.
Send labels to this version. Labels are additional data for this version but, diferent from metadate, these labels can be used as a filter. You can use this, for example, to send the user id who is changing the instance, enabling you to filter all changes made by a specific user.