Space SDK Package

Space SDK Package

  • Users
  • Storage
  • Space Docs

@spacehq/sdk > GundbMetadataStore

GundbMetadataStore class

A Users Storage Metadata store backed by gundsdb.

This is the default MetadataStore used by UserStorage.

Signature:

export declare class GundbMetadataStore implements UserMetadataStore 

Implements: UserMetadataStore

Methods

MethodModifiersDescription
addUserRecentlySharedWith(user)Add user to set of users current user has recently shared files with.
createBucket(bucketSlug, dbId, bucketKey)Create a BucketSchema record with dbId belonging to the current user.It should fail if a bucketSlug with similar dbId already exists.
findBucket(bucketSlug)Find bucket metadata with slug belonging to the current user matching
findFileMetadata(bucketSlug, dbId, path)Find existing metadata information about the file at path.
findFileMetadataByUuid(uuid)Find existing metadata information about the file with uuid
findSharedFilesByInvitation(invitationId)Lookup a received shared file by invitation id.
fromIdentity(username, userpass, gunOrServer, logger)staticCreates a new instance of this metadata store for users identity.
getNotificationsLastSeenAt()Get the notifications last seen at
listBuckets()Returns a list of all bucket schemas belonging to the current user
listSharedByMeFiles()List all shared files current user has shared with other users.
listSharedWithMeFiles()List all shared with me files for the existing user
listUsersRecentlySharedWith()List set of users the current user has recently shared files with
setFilePublic(metadata)Make the file with uuid publicly accessible by storing in a datastore domain that is public.
setNotificationsLastSeenAt(timestamp)Set the notifications last seen at
upsertFileMetadata(metadata)Updates the metadata information about a specific file.
upsertSharedByMeFile(fileData)Inserts a new file. If a file with the same dbId, path and bucket slug exists, the existing record would be updated and returned.
upsertSharedWithMeFile(fileData)Inserts a new shared with me file. If a file with the same dbId, path and bucket slug exists, the existing record would be updated and returned.
  • GundbMetadataStore class
  • Methods
Space SDK Package
Docs
Getting StartedUsersStorage
Resources
All DocumentationProject SlackBlog
More
GitHubStar
Follow @spacestorage