Showing 18 blocks

storage: create document

Creates a document in the given storage.


In pins

flow
mutations
Provide the mutations for this document. e.g. use set fields to set existing/new fields.
Storage
The storage this document will be created.
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date.
options (optional)
Options can be given e.g. skip_revisions to skip create revisions for high-update docs.

Out pins

flow
success
guid
object
error (optional)
on error
Yes
v10.2.9

storage: create multiple documents

Creates multiple documents in the given storage, each item in the array becomes a document.


In pins

flow
array
Each item in this array becomes a document, make sure the item is an object.
storage
The storage these documents should be created in.
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date

Out pins

flow
success
array
error (optional)

storage: dynamic storage

In pins

value

Out pins

storage

storage: find existing documents

returns array of existing and non-existing documents in a given storage from an array of objects.

meta key

In pins

flow
Storage
key
Value(code)
values
Array(Object({code: ..}), Object({code: ..}))

Out pins

flow
Existing
Non-Existing

storage: get document

In pins

flow
Storage
guid

Out pins

found
Object
guid (optional)
found (optional)

storage: move documents

Moves documents from one storage to another. It does so by first copying all documents and then updating the old documents with an expiry date. If there is an error during the first phase then the second phase won't be executed. This ensures that everything is moved before expiring the documents in the old storage.


In pins

flow
From Storage
The storage you would like to move these documents from
To Storage
The storage you would like to move these documents to
query
The query will be applied to find the documents that are going to be moved to a different storage
limit
The number of files to be moved, the maximum is 100.000

Out pins

flow
success
error
count

storage: remove document

Removes the given document from the given storage.


In pins

flow
guid
The documents GUID (unique ID) to remove.
object
Yes
v10.2.7
storage
The storage this document should be removed in.
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date

Out pins

flow
success
Returns true in case the removal succeeded
error (optional)

storage: remove multiple documents

Removes multiple documents from the given storage.


In pins

flow
array
storage
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date

Out pins

flow
success
error (optional)

storage: restore document

Restores a single document from the removed state and adds a revisions for this modification.

undo

In pins

flow
object
Yes
v11.1.17
guid
The documents GUID (unique ID) to restore.
storage

Out pins

flow
success
object
error (optional)

storage: restore multiple documents

Restores multiple documents from the removed state.

undo

In pins

flow
array
storage

Out pins

flow
success
error (optional)

storage: search

searches in the given storage based on a query.

database

In pins

flow
Storage
Query
Search will return cached results by default. Turn this behaviour off by adding Disable cache to this query.
Limit (optional)
5000
Offset (optional)

Out pins

flow
Results
Array of objects, each object is a single document. All results always include _meta.
hits
Number of documents found matching the given query.
guids (optional)
Has hits
Profile (optional)
Analyzed profile of the query, this data is gathered only when the query includes the Profile action.

storage: search single

searches in the given storage based on a query and returns maximum one result.

database
v10.6.6

In pins

flow
Storage
Query
Search will return cached results by default. Turn this behaviour off by adding Disable cache to this query.

Out pins

flow
Result
The result if one has been found.
guid
The guid of the result if one has been found.
Has result

storage: search streaming

streams the results of the search in the given database based on a query to a function.

iterator, streaming

In pins

flow
Storage
Query
Search will return cached results by default. Turn this behaviour off by adding Disable cache to this query.
Concurrency (optional)
ID (optional)

Out pins

flow
count
Each result

storage: selector

Lets you choose a storage to be used on the connected blocks.


In pins

Out pins

storage

storage: set document expiry

Updates the expiry of the given document from the given storage.

v11.0.0

In pins

flow
guid
The documents GUID (unique ID) to update.
storage
The storage this document should be updated in.
expiry
The document will be unrecoverably deleted on the given date

Out pins

flow
success
Returns true in case the update succeeded
error (optional)

storage: trigger event

Event is executed when the storage receives an event relevent update (removed, created, updated or saved).


In pins

Out pins

flow
Current Document
The most recent document at the time of this event being executed.
Storage
The storage this document has been triggered on.
Revisions
The revisions triggering this event.
Fields modified
The fields modified triggering this event.

storage: update document

Update document in the given storage and creates a revision for it.


In pins

flow
object
Yes
v9.2.5
guid
The documents GUID (unique ID) to update.
mutations
Provide the mutations for this document. e.g. use set fields to set existing/update fields.
Storage
The storage this document is currently stored in.
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date
options (optional)
Options can be given e.g. skip_revisions to skip create revisions for high-update docs.

Out pins

flow
success
guid
document
error (optional)
on error
Yes
v10.2.9

storage: update multiple documents

Updates multiple documents in the given storage and creates mass-revisions for it, mass-revisions do not include their previous value.


In pins

flow
array
An array of objects or GUIDs representing existing documents.
mutations
storage
The storage these documents should be updated in.
expiry (optional)
When a document is given an expiry date, the document will be unrecoverably deleted on the given date
options (optional)
Provide skip_revisions to update these documents without creating revisions.

Out pins

flow
success
error (optional)

Groups