The API uses
type for Database and app for Space. See Terminology.Update entity collection Field
Add already existing Entities to an entity collection Field by providing theirfibery/id. Remove Entities from the collection in a similar way.
Get fibery/id either via API or by opening the relevant Entity on UI and exploring the command response in browser’s Network tab.
Cricket/Player Database used as an example
Add
Add two existing Teams to Player’s “Former Teams” entity collection Field (if team already exists in the collection then team will be ignored during addition):Remove
Remove two Teams from Player’s “Former Teams” entity collection Field (if team doesn’t exist in the collection then team will be ignored during removing):Set
Replace two Teams from Player’s “Former Teams” entity collection Field with new team.Replace means deletion of any existing collection items and adding new items.
Reset
Resets “Former Teams” entity collection Field with new team.Update single-select and multi-select Fields
A single-select Field is an entity Field — each option is an Entity with its ownfibery/id. Update it via fibery.entity/update, the same way as any entity Field.
A multi-select Field is an entity collection Field — each option is an Entity with its own fibery/id. Update it via collection commands (add-collection-items, remove-collection-items, set-collection-items, reset-collection-items), the same way as any entity collection Field.
Get an option’s fibery/id either via API or by opening the Entity on UI and exploring the command response in browser’s Network tab.
Cricket/Player Database used as an example
Set single-select Field
SetCricket/Batting Hand on a Player:
Add options to multi-select Field
Add two options toCricket/Playing Roles on a Player:
fibery.entity/remove-collection-items, fibery.entity/set-collection-items, and fibery.entity/reset-collection-items.