The (private) storage provider. This is a pretty generic interface that can be satisfied by a basic object for tests, or a full- blown Dexie db for real usage.
A set of configuration options for remote sync.
Set of configuration options for remote sync.
Database identity on remote peer. String encoding of a thread id.
Apply the local stash back on top of the local changes.
The set of collections to filter on. This means you can fine-tune which changes are apoplied.
Authorize with a remote.
The identity to use for authorization, or the public key of an identity.
Clear the local stash.
Stash local changes. This moves local changes out of the local staging table into a stashed table. Making it possible to pull remote changes and re-apply local changes on top (like a git rebase).
Get the remote configuration options.
Initialize a new remote db/thread. Should only be done once, but only after opening the db.
The thread id for the new db. Will default to random thread id. Can be a thread id object or base32-encode string (the default).
Pull remote changes into local db. Attempts to force pull remote updates. This will automatically request updates from the remote.
A (possibly empty) variadic set of collections to pull.
A promise that resolves to the set of modified keys.
Set the remote configuration options.
The configuration options to use. All are optional.
Create a new gRPC client instance from a supplied key and secret
The KeyInfo object containing {key: string, secret: string, type: 0}. 0 === User Group Key, 1 === Account Key
Create a new gRPC client instance from a supplied user auth object. Assumes all default gRPC settlings. For customization options, use a context object directly. The callback method will automatically refresh expiring credentials.
The user auth object or an async callback that returns a user auth object.
Create a new Remote instance.