GraphQL schema for Secure Scuttlebot, meant to be used as a plugin with open-app-graphql-server. You can also add it to your existing schema using schema stitching.
Install it with npm i -S ssb-graphql-defaults
and use it with your GraphQL server, or use it as a plugin with the open-app-graphql-server.
Get id of the current sbot user.
Get a message by its hash-id. Use fragments to get the content of specific messages such as a post
:
query {
message(id: "%NgcMlAco0ZKI8lIteD/LRJMHKhFZrQxJvUrXaFmEIcQ=.sha256") {
key
author
... on PostMessage {
content {
type
text
}
}
}
}
Get a blob by its ID.
Get the current peerlist.
Construct a message using sbot's current user, and add it to the DB.
content
(stringified object): The content of the message.-
type
(string): The object's type.
Publish post
message with text.
Listen for gossip events.
Listen to replicate events.
Callsback true if source follows dest, false otherwise.
Callsback true if source blocks dest, false otherwise.
Attempt to decrypt the content of an encrypted message.
Begin searching the network for the blob of the given hash.
Add a new blob to the DB.
Remove a blob from the store.
Publish an encrypted message.
content
(object): The content of the message.recps
(array of feedids): The recipients of the message (limit 7).
Retrieve messages with a given type, ordered by receive-time.
Fetch messages ordered by their claimed timestamps
Fetch messages ordered by the time received.
Fetch messages from a specific user, ordered by sequence numbers.
Fetch messages from a specific user, ordered by sequence numbers.
rel
(string, optional): Filters the links by the relation string.
Get a stream of messages, feeds, or blobs that are linked to/from an id.
List the hashes of the blobs in the DB.
Listen for any newly-downloaded blobs.
Live-stream the ids of feeds which meet the given hops query. If meta option is set, then will return steam of {id, hops}