Guide
Views API is provided at https://{YOUR_ACCOUNT}.fibery.io/api/views/json-rpc.
It follows the JSON-RPC specification.
Getting views
To get a list of Views, use the query-views method.
All filters and params are optional. If omitted, all Views will be returned.
curl -X POST https://YOUR_ACCOUNT.fibery.io/api/views/json-rpc \
-H 'Authorization: Token YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d \
'{
"jsonrpc": "2.0",
"method": "query-views",
"params": {
"filter": {
"ids": ["b190008d-3fef-4df5-b8b9-1b432a0e0f05", "dd62b0df-537e-4c12-89f2-d937da128c7b"],
"publicIds": ["1001", "1002"]
}
}
}'
Possible filters are:
ids
| array of UUID strings | Matches views by the fibery/id field. |
publicIds
| array of numeric strings | Matches views by the fibery/public-id field. |
isPrivate
| true or false
| If true, return only matching views from "My space". If false, return only matching views outside of "My space". If omitted, matching views both from and outside of "My space" are returned. |
container
| {type: "entity";
typeId: "6ded97e6-b4ca-4a8c-a740-6c34c3651cd1";
publicIds: ["1", "2"]}
| If provided, the query will return only views attached to entities with the given public ids in the database (type) with the given typeId. |
Creating views
To create one or more Views, use the create-views method:
"Container app" in this example contains a fibery/id reference to the space where the new View is to be created.
curl -X POST https://YOUR_ACCOUNT.fibery.io/api/views/json-rpc \
-H 'Authorization: Token YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d \
'{
"jsonrpc": "2.0",
"method": "create-views",
"params": {
"views": [
{
"fibery/id": "3541bdf6-ab15-4d5e-b17b-eb124b8fe2f7",
"fibery/name": "My Board",
"fibery/type": "board",
"fibery/meta": {},
"fibery/container-app": {
"fibery/id": "760ee2e2-e8ca-4f92-aaf2-4cde7f9dad0e"
}
}
]
}
}'
Updating views
To update one or more Views, use the update-views method:
curl -X POST https://YOUR_ACCOUNT.fibery.io/api/views/json-rpc \
-H 'Authorization: Token YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d \
'{
"jsonrpc": "2.0",
"method": "update-views",
"params": {
"updates": [
{
id: "3541bdf6-ab15-4d5e-b17b-eb124b8fe2f7",
values: {
"fibery/name": "My Updated Board",
"fibery/meta": {},
}
}
]
}
}'
Deleting views
To delete one or more Views, use the delete-views method:
curl -X POST https://YOUR_ACCOUNT.fibery.io/api/views/json-rpc \
-H 'Authorization: Token YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d \
'{
"jsonrpc": "2.0",
"method": "delete-views",
"params": {
"ids": ["3541bdf6-ab15-4d5e-b17b-eb124b8fe2f7"]
}
}'