/splice
POST /collection/splice/{collection_id} — Remove and add objects to a collection.
POST /collection/splice/{collection_id} — Remove and add objects to a collection.- The splice call removes
countobjects at positionindexand adds the deliveredobjectsat that position. Existing objects are moved to make room. index,countandobjectsare supplied as fields of the request body object, not as query parameters.indexmust be>= 0and must not exceed the current number of objects.countmust be>= -1;-1deletes all objects fromindexto the end.- Requires an authenticated user with
BAG_READpermission. - Linking objects to a collection requires
LINKpermission. - If objects will be unlinked from the collection, the
UNLINKpermission is needed. - The
_versionof the collection is not changed.
Access token in the Authorization header:
Authorization: Bearer <token>.
The collection id of the collection to access.
Allow storing the collection even if the owner doesn't have the necessary
permissions for all objects to share the rights defined in the _acl property
of the collection. The _invalid_acl flag will be set, if the user doesn't
have sufficient permissions to share all objects of the collection. The user
needs the permission BAG_ACL for the collection in order to use this
parameter.
Differs from easydb 5: this confirmation is driven by the boolean
allow_invalid_acl parameter. easydb 5 instead resolves the 202
confirmation with a collection_rights_policy query parameter; there is no
allow_invalid_acl parameter in easydb 5.
If set, the invalid-ACL validity check (whether the collection owner may
grant the rights of all linked objects) is not run inline. Instead a queued
ACTION_COLLECTION_ACL_CHECK job is scheduled and the request returns
immediately, before the check has resolved.
If set, do not queue index jobs for objects added to or removed from the collection.
The access token in form of Bearer <token>. You can also use authorization
which does the same. authorization is looked at first.
The access token in form of Bearer <token>.
The _version of the collection.
The number of objects linked to this collection. In
/api/collection/splice the number of objects to delete. Use -1 to
delete all objects.
The index to use for /api/collection/splice. Index 0 is to the left of
the first object. Index which equals the number of existing objects in the
collection is to the right of the last object.
The offset of list of objects.
The maximum count of objects to list.
Short response of containing only the number of objects.
The collection owner lacks a grantable right for a linked object
and the caller has BAG_ACL. Re-send with allow_invalid_acl=true
to store the collection with sharing disabled.
The request could not be processed.
No authenticated user. The request must carry a valid access token.
The authenticated user lacks a required permission (BAG_READ
on the collection, LINK on inserted objects, UNLINK on
removed objects).
The collection addressed by the URL does not exist.
Last updated