@graffiti-garden/api 0.6.3 → 0.6.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,171 +2,90 @@ import type { GraffitiObjectUrl, GraffitiObject, GraffitiObjectBase, GraffitiPat
2
2
  import type { JSONSchema } from "json-schema-to-ts";
3
3
  /**
4
4
  * This API describes a small but powerful set of methods that
5
- * can be used to create many different kinds of social media applications,
6
- * all of which can interoperate.
7
- * These methods should satisfy all of an application's needs for
5
+ * can be used to create many different kinds of social applications,
6
+ * from applications like Twitter, to Messenger, to Wikipedia, to many more new designs.
7
+ * See the [Graffiti project website](https://graffiti.garden)
8
+ * for links to example applications. Additionally, apps built on top
9
+ * of the API interoperate with each other so you can seamlessly switch
10
+ * between apps without losing your friends or data.
11
+ *
12
+ * These API methods should satisfy all of an application's needs for
8
13
  * the communication, storage, and access management of social data.
9
14
  * The rest of the application can be built with standard client-side
10
- * user interface tools to present and interact with the data
11
- * no server code necessary.
12
- * The Typescript source for this API is available at
13
- * [graffiti-garden/api](https://github.com/graffiti-garden/api).
15
+ * user interface tools to present and interact with that data—no server code necessary!
16
+ *
17
+ * The Typescript code for this API is [open source on Github](https://github.com/graffiti-garden/api).
14
18
  *
15
19
  * There are several different implementations of this Graffiti API available,
16
- * including a [federated implementation](https://github.com/graffiti-garden/implementation-federated),
17
- * that lets users choose where their data is stored,
20
+ * including a [federated implementation](https://github.com/graffiti-garden/implementation-remote),
21
+ * that lets people choose where their data is stored (you do not need to host your own server)
18
22
  * and a [local implementation](https://github.com/graffiti-garden/implementation-local)
19
- * that can be used for testing and development. In our design of Graffiti, this API is our
20
- * primary focus as it is the layer that shapes the experience
21
- * of developing applications. While different implementations can provide tradeoffs between
22
- * other important properties (e.g. privacy, security, scalability), those properties
23
- * are useless if the system as a whole doesn't expose useful functionality to developers.
24
- *
25
- * On the other side of the stack, there is [Vue plugin](https://github.com/graffiti-garden/wrapper-vue/)
26
- * that wraps around this API to provide reactivity. Other high-level libraries
27
- * will be available in the future.
28
- *
29
- * ## Overview
30
- *
31
- * Graffiti provides applications with methods to create and store data
32
- * on behalf of their users using standard CRUD operations:
33
- * {@link put}, {@link get}, {@link patch}, and {@link delete}.
34
- * This data can represent both social artifacts (e.g. posts, profiles) and
35
- * activities (e.g. likes, follows) and is stored as JSON.
36
- *
37
- * The social aspect of Graffiti comes from the {@link discover} method
38
- * which allows applications to find objects that other users made.
39
- * It is a lot like a traditional query operation, but it only
40
- * returns objects that have been placed in particular
41
- * {@link GraffitiObjectBase.channels | `channels`}
42
- * specified by the discovering application.
23
+ * that can be used for testing and development. Different implementations can
24
+ * be swapped-in in the future without changing the API or any of the apps built on
25
+ * top of it. In fact, we're working on an end-to-end encrypted version now!
26
+ * [Follow Theia on BlueSky for updates](https://bsky.app/profile/theias.place).
43
27
  *
44
- * Graffiti builds on well known concepts and standards wherever possible.
45
- * JSON Objects can be typed with [JSON Schema](https://json-schema.org/) and patches
46
- * can be applied with [JSON Patch](https://jsonpatch.com).
47
- * For interoperability between Graffiti applications, we recommend that
48
- * objects use established properties from the
49
- * [Activity Vocabulary](https://www.w3.org/TR/activitystreams-vocabulary/) when available,
50
- * however it is always possible to create additional properties, contributing
51
- * to the broader [folksonomy](https://en.wikipedia.org/wiki/Folksonomy).
28
+ * On the other side of the stack, there is [Vue plugin](https://vue.graffiti.garden/variables/GraffitiPlugin.html)
29
+ * that wraps around this API to provide reactivity. Other plugin frameworks
30
+ * and high-level libraries will be available in the future.
52
31
  *
53
- * {@link GraffitiObjectBase.channels | `channels`} are one of the major concepts
54
- * unique to Graffiti along with *interaction relativity*, defined below.
55
- * Channels create boundaries between public spaces and work to prevent
56
- * [context collapse](https://en.wikipedia.org/wiki/Context_collapse)
57
- * even in a highly interoperable environment.
58
- * Interaction relativity means that all interactions between users are
59
- * actually atomic single-user operations that can be interpreted in different ways,
60
- * which also supports interoperability and pluralism.
32
+ * ## API Overview
61
33
  *
62
- * ### Channels
34
+ * The Graffiti API provides applications with methods for {@link login} and {@link logout},
35
+ * methods to store data objects using standard database operations ({@link put}, {@link get}, {@link patch}, and {@link delete}),
36
+ * and a method to {@link discover} data objects from other people.
37
+ * These data objects have a couple structured properties:
38
+ * - {@link GraffitiObjectBase.url | `url`} (string): A globally unique identifier and locator for the object.
39
+ * - {@link GraffitiObjectBase.actor | `actor`} (string): An unforgeable identifier for the creator of the object.
40
+ * - {@link GraffitiObjectBase.allowed | `allowed`} (string[] | undefined): An array of the identities who are allowed to access the object (undefined for public objects).
41
+ * - {@link GraffitiObjectBase.channels | `channels`} (string[]): An array of the *contexts* in which the object should appear.
42
+ * - {@link GraffitiObjectBase.lastModified | `revision`} (number): A number to compare different versions of an object.
63
43
  *
64
- * {@link GraffitiObjectBase.channels | `channels`}
65
- * are a way for the creators of social data to express the intended audience of their
66
- * data. When a user creates data using the {@link put} method, they
67
- * can place their data in one or more channels.
68
- * Content consumers using the {@link discover} method will only see data
69
- * contained in one of the channels they specify.
70
- *
71
- * While many channels may be public, they partition
72
- * the public into different "contexts", mitigating the
73
- * phenomenon of [context collapse](https://en.wikipedia.org/wiki/Context_collapse) or the "flattening of multiple audiences."
74
- * Any [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier) can be used as a channel, and so channels can represent people,
75
- * comment threads, topics, places (real or virtual), pieces of media, and more.
76
- *
77
- * For example, consider a comment on a post. If we place that comment in the channel
78
- * represented by the post's URL, then only people viewing the post will know to
79
- * look in that channel, giving it visibility akin to a comment on a blog post
80
- * or comment on Instagram ([since 2019](https://www.buzzfeednews.com/article/katienotopoulos/instagrams-following-activity-tab-is-going-away)).
81
- * If we also place the comment in the channel represented by the commenter's URI (their
82
- * {@link GraffitiObjectBase.actor | `actor` URI}), then people viewing the commenter's profile
83
- * will also see the comment, giving it more visibility, like a reply on Twitter.
84
- * If we *only* place the comment in the channel represented by the commenter's URI, then
85
- * it becomes like a quote tweet ([prior to 2020](https://x.com/Support/status/1300555325750292480)),
86
- * where the comment is only visible to the commenter's followers but not the audience
87
- * of the original post.
88
- *
89
- * The channel model differs from other models of communication such as the
90
- * [actor model](https://www.w3.org/TR/activitypub/#Overview) used by ActivityPub,
91
- * the protocol underlying Mastodon, or the [firehose model](https://bsky.social/about/blog/5-5-2023-federation-architecture)
92
- * used by the AT Protocol, the protocol underlying BlueSky.
93
- * The actor model is a fusion of direct messaging (like Email) and broadcasting
94
- * (like RSS) and works well for follow-based communication but struggles
95
- * to pass information via other rendez-vous.
96
- * In the actor model, even something as simple as comments can be
97
- * [very tricky and require server "side effects"](https://seb.jambor.dev/posts/understanding-activitypub-part-3-the-state-of-mastodon/).
98
- * The firehose model dumps all user data into one public database,
99
- * which doesn't allow for the carving out of different contexts that we did in our comment
100
- * example above. In the firehose model a comment will always be visible to *both* the original post's audience and
101
- * the commenter's followers.
102
- *
103
- * In some sense, channels provide a sort of "social access control" by forming
104
- * expectations about the audiences of different online spaces.
105
- * As a real world analogy, oftentimes support groups, such as alcoholics
106
- * anonymous, are open to the public but people in those spaces feel comfortable sharing intimate details
107
- * because they have expectations about the other people attending.
108
- * If someone malicious went to support groups just to spread people's secrets,
109
- * they would be shamed for violating these norms.
110
- * Similarly, in Graffiti, while you could spider public channels like a search engine
111
- * to find content about a person, revealing that you've done such a thing
112
- * would be shameful.
44
+ * All other data is stored in the object's unstructured {@link GraffitiObjectBase.value | `value`} property.
45
+ * This data can be used to represent social artifacts (e.g. posts, profiles) and activities (e.g. likes, follows).
46
+ * For example, a post might have the value:
47
+
48
+ * ```js
49
+ * {
50
+ * title: "My First Post",
51
+ * content: "Hello, world!",
52
+ * published: 1630483200000
53
+ * }
54
+ * ```
113
55
  *
114
- * Still, social access control is not perfect and so in situations where privacy is important,
115
- * objects can also be given
116
- * an {@link GraffitiObjectBase.allowed | `allowed`} list.
117
- * For example, to send someone a direct message you should put an object representing
118
- * that message in the channel that represents them (their {@link GraffitiObjectBase.actor | `actor` URI}),
119
- * so they can find it, *and* set the `allowed` field to only include the recipient,
120
- * so only they can read it.
56
+ * a profile might have the value:
121
57
  *
122
- * ### Interaction relativity
58
+ * ```js
59
+ * {
60
+ * name: "Theia Henderson",
61
+ * pronouns: "she/her",
62
+ * describes: "did:web:theias.place" // Theia's actor ID
63
+ * }
64
+ * ```
123
65
  *
124
- * Interaction relativity posits that "interaction between two individuals only
125
- * exists relative to an observer," or equivalently, all interaction is [reified](https://en.wikipedia.org/wiki/Reification_(computer_science)).
126
- * For example, if one user creates a post and another user wants to "like" that post,
127
- * their like is not modifying the original post, it is simply another data object that points
128
- * to the post being liked, via its {@link GraffitiObjectBase.url | URL}.
66
+ * and a "Like" might have the value:
129
67
  *
130
- * ```json
68
+ * ```js
131
69
  * {
132
- * activity: 'like',
133
- * target: 'url-of-the-post-i-like',
134
- * actor: 'my-user-id'
70
+ * activity: "Like",
71
+ * target: "graffiti:remote:pod.graffiti.garden/12345" // The URL of the graffiti object being liked
135
72
  * }
136
73
  * ```
137
74
  *
138
- * In Graffiti, all interactions including *moderation* and *collaboration* are relative.
139
- * This means that applications can freely choose which interactions
140
- * they want to express to their users and how.
141
- * For example, one application could have a single fixed moderator,
142
- * another could allow users to choose which moderators they would like filter their content
143
- * like [Bluesky's stackable moderation](https://bsky.social/about/blog/03-12-2024-stackable-moderation),
144
- * and another could implement a fully democratic system like [PolicyKit](https://policykit.org/).
145
- * Each of these applications is one interpretation of the underlying refieid user interactions and
146
- * users can freely switch between them.
75
+ * New social artifacts and activities can be easily created, simply
76
+ * by creating new objects with appropriate properties. Despite the lack of
77
+ * structure, we expect Graffiti object properties to adhere to a "[folksonomy](https://en.wikipedia.org/wiki/Folksonomy)",
78
+ * similar to hashtags. Any string can be used as a hashtag on Twitter,
79
+ * but there is social value in using the same hashtags at other people and
80
+ * so a structure naturally emerges. Similarly, Graffiti objects
81
+ * can have arbitrary properties but if people use the same properties as each other,
82
+ * their apps will interoperate, which has social value.
147
83
  *
148
- * Interaction relativy also allows applications to introduce new sorts of interactions
149
- * without having to coordinate with all the other existing applications,
150
- * keeping the ecosystem flexible and interoperable.
151
- * For example, an application could [add a "Trust" button to posts](https://social.cs.washington.edu/pub_details.html?id=trustnet)
152
- * and use it assess the truthfulness of posts made on applications across Graffiti.
153
- * New sorts of interactions like these can be smoothly absorbed by the broader ecosystem
154
- * as a [folksonomy](https://en.wikipedia.org/wiki/Folksonomy).
155
- *
156
- * Interactivy relativity is realized in Graffiti through two design decisions:
157
- * 1. The creators of objects can only modify their own objects. It is important for
158
- * users to be able to change and delete their own content to respect their
159
- * [right to be forgotten](https://en.wikipedia.org/wiki/Right_to_be_forgotten),
160
- * but beyond self-correction and self-censorship all other interaction is reified.
161
- * Many interactions can be reified via pointers, as in the "like" example above, and collaborative
162
- * edits can be refieid via [CRDTs](https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type).
163
- * 2. No one owns channels. Unlike IRC/Slack channels or [Matrix rooms](https://matrix.org/docs/matrix-concepts/rooms_and_events/),
164
- * anyone can post to any channel, so long as they know the URI of that channel.
165
- * It is up to applications to hide content from channels either according to manual
166
- * filters or in response to user action.
167
- * For example, a user may create a post with the flag `disableReplies`.
168
- * Applications could then filter out any content from the replies channel
169
- * that the original poster has not specifically approved.
84
+ * For a more complete and detailed overview of Graffiti's design, please
85
+ * refer to [this section of the Graffiti paper](https://dl.acm.org/doi/10.1145/3746059.3747627#sec-3),
86
+ * published in ACM UIST 2025. The paper also overviews {@link GraffitiObjectBase.channels | `channels`},
87
+ * which are Graffiti's means of organizing data contextually, and a concept called "total reification",
88
+ * which handles explains how moderation, collaboration, and other interactions are managed.
170
89
  *
171
90
  * @groupDescription CRUD Methods
172
91
  * Methods for {@link put | creating}, {@link get | reading}, {@link patch | updating},
@@ -174,7 +93,7 @@ import type { JSONSchema } from "json-schema-to-ts";
174
93
  * @groupDescription Query Methods
175
94
  * Methods that retrieve or accumulate information about multiple {@link GraffitiObjectBase | Graffiti objects} at a time.
176
95
  * @groupDescription Session Management
177
- * Methods and properties for logging in and out of a Graffiti implementation.
96
+ * Methods and properties for logging in and out.
178
97
  */
179
98
  export declare abstract class Graffiti {
180
99
  /**
@@ -192,7 +111,7 @@ export declare abstract class Graffiti {
192
111
  * @throws {@link GraffitiErrorForbidden} if the {@link GraffitiObjectBase.actor | `actor`}
193
112
  * is not the same `actor` as the one who created the object.
194
113
  *
195
- * @returns The object that was replaced if one one exists, otherwise an object with
114
+ * @returns Returns the object that was replaced if one one exists, otherwise returns an object with
196
115
  * with an empty {@link GraffitiObjectBase.value | `value`},
197
116
  * {@link GraffitiObjectBase.channels | `channels`}, and {@link GraffitiObjectBase.allowed | `allowed`}
198
117
  * list.
@@ -205,7 +124,7 @@ export declare abstract class Graffiti {
205
124
  /**
206
125
  * The object to be put. This object is statically type-checked against the [JSON schema](https://json-schema.org/) that can be optionally provided
207
126
  * as the generic type parameter. We highly recommend providing a schema to
208
- * ensure that the PUT object matches subsequent {@link get} or {@link discover}
127
+ * ensure that the put object matches subsequent {@link get} or {@link discover}
209
128
  * methods.
210
129
  */
211
130
  object: GraffitiPutObject<Schema>,
@@ -224,9 +143,11 @@ export declare abstract class Graffiti {
224
143
  * the object's `actor`,
225
144
  * the object's {@link GraffitiObjectBase.allowed | `allowed`} and
226
145
  * {@link GraffitiObjectBase.channels | `channels`} properties are
227
- * not revealed, similar to a BCC.
146
+ * not revealed, similar to a BCC email.
147
+ *
148
+ * @returns Returns the retrieved object.
228
149
  *
229
- * @throws {@link GraffitiErrorNotFound} if the object does not exist, has been deleted, or the user is not
150
+ * @throws {@link GraffitiErrorNotFound} if the object does not exist, has been deleted, or the actor is not
230
151
  * {@link GraffitiObjectBase.allowed | `allowed`} to access it.
231
152
  *
232
153
  * @throws {@link GraffitiErrorSchemaMismatch} if the retrieved object does not match the provided schema.
@@ -254,12 +175,12 @@ export declare abstract class Graffiti {
254
175
  * The patching {@link GraffitiObjectBase.actor | `actor`} must be the same as the
255
176
  * `actor` that created the object.
256
177
  *
257
- * @returns The original object prior to the patch with its
178
+ * @returns Returns the original object prior to the patch with its
258
179
  * {@link GraffitiObjectBase.lastModified | `lastModified`}
259
- * property updated to the time of deletion.
180
+ * property updated to the time of patching.
260
181
  *
261
182
  * @throws {@link GraffitiErrorNotFound} if the object does not exist, has already been deleted,
262
- * or the user is not {@link GraffitiObjectBase.allowed | `allowed`} to access it.
183
+ * or the actor is not {@link GraffitiObjectBase.allowed | `allowed`} to access it.
263
184
  *
264
185
  * @throws {@link GraffitiErrorForbidden} if the {@link GraffitiObjectBase.actor | `actor`}
265
186
  * is not the same `actor` as the one who created the object.
@@ -287,17 +208,17 @@ export declare abstract class Graffiti {
287
208
  * `actor` that created the object.
288
209
  *
289
210
  * It is not possible to re-{@link put} an object that has been deleted
290
- * to ensure a user's [right to be forgotten](https://en.wikipedia.org/wiki/Right_to_be_forgotten).
211
+ * to ensure a person's [right to be forgotten](https://en.wikipedia.org/wiki/Right_to_be_forgotten).
291
212
  * In cases where deleting and restoring an object is useful, an object's
292
213
  * {@link GraffitiObjectBase.allowed | `allowed`} property can be set to
293
- * an empty list to hide it from all users except the creator.
214
+ * an empty list to hide it from all actors except the creator.
294
215
  *
295
- * @returns The object that was deleted with its
216
+ * @returns Returns the object that was deleted with its
296
217
  * {@link GraffitiObjectBase.lastModified | `lastModified`}
297
218
  * property updated to the time of deletion.
298
219
  *
299
220
  * @throws {@link GraffitiErrorNotFound} if the object does not exist, has already been deleted,
300
- * or the user is not {@link GraffitiObjectBase.allowed | `allowed`} to access it.
221
+ * or the actor is not {@link GraffitiObjectBase.allowed | `allowed`} to access it.
301
222
  *
302
223
  * @throws {@link GraffitiErrorForbidden} if the {@link GraffitiObjectBase.actor | `actor`}
303
224
  * is not the same `actor` as the one who created the object.
@@ -315,7 +236,7 @@ export declare abstract class Graffiti {
315
236
  */
316
237
  session: GraffitiSession): Promise<GraffitiObjectBase>;
317
238
  /**
318
- * Discovers objects created by any user that are contained
239
+ * Discovers objects created by any actor that are contained
319
240
  * in at least one of the given {@link GraffitiObjectBase.channels | `channels`}
320
241
  * and match the given [JSON Schema](https://json-schema.org).
321
242
  *
@@ -344,7 +265,7 @@ export declare abstract class Graffiti {
344
265
  * {@link GraffitiObjectBase.lastModified | `lastModified`} fields must be used
345
266
  * to determine which object is the most recent.
346
267
  *
347
- * @returns A stream of objects that match the given {@link GraffitiObjectBase.channels | `channels`}
268
+ * @returns Returns a stream of objects that match the given {@link GraffitiObjectBase.channels | `channels`}
348
269
  * and [JSON Schema](https://json-schema.org).
349
270
  *
350
271
  * @group Query Methods
@@ -370,18 +291,18 @@ export declare abstract class Graffiti {
370
291
  * {@link GraffitiObjectBase.channels | `channels`}
371
292
  * that were created by the querying {@link GraffitiObjectBase.actor | `actor`}
372
293
  * and match the given [JSON Schema](https://json-schema.org).
373
- * Unlike {@link discover}, this method will not return objects created by other users.
294
+ * Unlike {@link discover}, this method will not return objects created by other actors.
374
295
  *
375
- * This method is not useful for most applications, but necessary for
376
- * getting a global view of all a user's Graffiti data or debugging
377
- * channel usage.
296
+ * Like {@link channelStats}, this method is not useful for most applications,
297
+ * but necessary for getting a global view of all an actor's Graffiti data
298
+ * to implement something like Facebook's Activity Log or a debugging interface.
378
299
  *
379
300
  * Like {@link discover}, objects are returned asynchronously as they are discovered,
380
301
  * the stream will end once all leads have been exhausted, and the stream
381
302
  * can be continued using the {@link GraffitiObjectStreamReturn.continue | `continue`}
382
303
  * method or {@link GraffitiObjectStreamReturn.cursor | `cursor`} string.
383
304
  *
384
- * @returns A stream of objects created by the querying {@link GraffitiObjectBase.actor | `actor`}
305
+ * @returns Returns a stream of objects created by the querying {@link GraffitiObjectBase.actor | `actor`}
385
306
  * that do not belong to any {@link GraffitiObjectBase.channels | `channels`}
386
307
  * and match the given [JSON Schema](https://json-schema.org).
387
308
  *
@@ -400,17 +321,18 @@ export declare abstract class Graffiti {
400
321
  /**
401
322
  * Returns statistics about all the {@link GraffitiObjectBase.channels | `channels`}
402
323
  * that an {@link GraffitiObjectBase.actor | `actor`} has posted to.
403
- * This is not very useful for most applications, but
404
- * necessary for certain applications where a user wants a
405
- * global view of all their Graffiti data or to debug
406
- * channel usage.
324
+ * This method will not return statistics related to any other actor's channel usage.
407
325
  *
408
- * Like {@link discover}, objects are returned asynchronously as they are discovered,
326
+ * Like {@link recoverOrphans}, this method is not useful for most applications,
327
+ * but necessary for getting a global view of all an actor's Graffiti data
328
+ * to implement something like Facebook's Activity Log or a debugging interface.
329
+ *
330
+ * Like {@link discover}, objects are returned asynchronously as they are discovered and
409
331
  * the stream will end once all leads have been exhausted.
410
332
  *
411
333
  * @group Query Methods
412
334
  *
413
- * @returns A stream of statistics for each {@link GraffitiObjectBase.channels | `channel`}
335
+ * @returns Returns a stream of statistics for each {@link GraffitiObjectBase.channels | `channel`}
414
336
  * that the {@link GraffitiObjectBase.actor | `actor`} has posted to.
415
337
  */
416
338
  abstract channelStats(
@@ -449,8 +371,9 @@ export declare abstract class Graffiti {
449
371
  abstract continueObjectStream(cursor: string, session?: GraffitiSession | null): GraffitiObjectStreamContinue<{}>;
450
372
  /**
451
373
  * Begins the login process. Depending on the implementation, this may
452
- * involve redirecting the user to a login page or opening a popup,
453
- * so it should always be called in response to a user action.
374
+ * involve redirecting to a login page or opening a popup,
375
+ * so it should always be called in response to a gesture, such as clicking
376
+ * a button, due to the [feature-gating browser security feature](https://developer.mozilla.org/en-US/docs/Web/Security/User_activation).
454
377
  *
455
378
  * The {@link GraffitiSession | session} object is returned
456
379
  * asynchronously via {@link Graffiti.sessionEvents | sessionEvents}
@@ -489,9 +412,10 @@ export declare abstract class Graffiti {
489
412
  scope?: {};
490
413
  }): Promise<void>;
491
414
  /**
492
- * Begins the logout process. Depending on the implementation, this may
415
+ * Begins the logout process for a particular {@link GraffitiSession | session}. Depending on the implementation, this may
493
416
  * involve redirecting the user to a logout page or opening a popup,
494
- * so it should always be called in response to a user action.
417
+ * so it should always be called in response to a gesture, such as clicking
418
+ * a button, due to the [feature-gating browser security feature](https://developer.mozilla.org/en-US/docs/Web/Security/User_activation).
495
419
  *
496
420
  * A confirmation will be returned asynchronously via
497
421
  * {@link Graffiti.sessionEvents | sessionEvents}
@@ -506,7 +430,7 @@ export declare abstract class Graffiti {
506
430
  session: GraffitiSession): Promise<void>;
507
431
  /**
508
432
  * An event target that can be used to listen for the following
509
- * events and they're corresponding event types:
433
+ * events and their corresponding event types:
510
434
  * - `login` - {@link GraffitiLoginEvent}
511
435
  * - `logout` - {@link GraffitiLogoutEvent}
512
436
  * - `initialized` - {@link GraffitiSessionInitializedEvent}
@@ -1 +1 @@
1
- {"version":3,"file":"1-api.d.ts","sourceRoot":"","sources":["../../src/1-api.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,iBAAiB,EACjB,cAAc,EACd,kBAAkB,EAClB,aAAa,EACb,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EAEpB,0BAA0B,EAC1B,4BAA4B,EAC7B,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+KG;AACH,8BAAsB,QAAQ;IAC5B;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,QAAQ,CAAC,GAAG,CAAC,MAAM,SAAS,UAAU;IACpC;;;;;OAKG;IACH,MAAM,EAAE,iBAAiB,CAAC,MAAM,CAAC;IACjC;;;OAGG;IACH,OAAO,EAAE,eAAe,GACvB,OAAO,CAAC,kBAAkB,CAAC;IAE9B;;;;;;;;;;;;;;;;;;OAkBG;IACH,QAAQ,CAAC,GAAG,CAAC,MAAM,SAAS,UAAU;IACpC;;OAEG;IACH,GAAG,EAAE,MAAM,GAAG,iBAAiB;IAC/B;;OAEG;IACH,MAAM,EAAE,MAAM;IACd;;;;;OAK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Ae,GAAG,IAAI,GAC/B,4BAA4B,CAAC,EAAE,CAAC;IAEnC;;;;;;;;;;;OAWG;IACH,QAAQ,CAAC,KAAK;IACZ;;;;OAIG;IACH,QAAQ,CAAC,EAAE;QACT;;;;;;;;WAQG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;QACf;;;;;;;;;;WAUG;QACH,KAAK,CAAC,EAAE,EAAE,CAAC;KACZ,GACA,OAAO,CAAC,IAAI,CAAC;IAEhB;;;;;;;;;;;OAWG;IACH,QAAQ,CAAC,MAAM;IACb;;OAEG;IACH,OAAO,EAAE,eAAe,GACvB,OAAO,CAAC,IAAI,CAAC;IAEhB;;;;;;;;OAQG;IACH,QAAQ,CAAC,QAAQ,CAAC,aAAa,EAAE,WAAW,CAAC;CAC9C"}
@@ -32,8 +32,8 @@ export interface GraffitiObjectBase {
32
32
  * {@link Graffiti.discover} method. This allows creators to express the intended audience of their object
33
33
  * which helps to prevent [context collapse](https://en.wikipedia.org/wiki/Context_collapse) even
34
34
  * in the highly interoperable ecosystem that Graffiti envisions. For example, channel URIs may be:
35
- * - A user's own {@link actor | `actor`} URI. Putting an object in this channel is a way to broadcast
36
- * the object to the user's followers, like posting a tweet.
35
+ * - A actor's own {@link actor | `actor`} URI. Putting an object in this channel is a way to broadcast
36
+ * the object to the actor's followers, like posting a tweet.
37
37
  * - The URL of a Graffiti post. Putting an object in this channel is a way to broadcast to anyone viewing
38
38
  * the post, like commenting on a tweet.
39
39
  * - A URI representing a topic. Putting an object in this channel is a way to broadcast to anyone interested
@@ -46,8 +46,8 @@ export interface GraffitiObjectBase {
46
46
  * also know the right {@link channels | `channel` } to look in). An object can always be accessed by its creator, even if
47
47
  * the `allowed` array is empty.
48
48
  *
49
- * The `allowed` array is not revealed to users other than the creator, like
50
- * a BCC email. A user may choose to add a `to` property to the object's {@link value | `value`} to indicate
49
+ * The `allowed` array is not revealed to actors other than the creator, like
50
+ * a BCC email. An actor may choose to add a `to` property to the object's {@link value | `value`} to indicate
51
51
  * other recipients, however this is not enforced by Graffiti and may not accurately reflect the actual `allowed` array.
52
52
  *
53
53
  * `allowed` can be combined with {@link channels | `channels`}. For example, to send someone a direct message
@@ -82,22 +82,27 @@ export interface GraffitiObjectBase {
82
82
  * to pull from multiple coexisting Graffiti implementations without collision.
83
83
  * Existing schemes include `graffiti:local:` for objects stored locally
84
84
  * (see the [local implementation](https://github.com/graffiti-garden/implementation-local))
85
- * and `graffiti:remote:` for objects stored on Graffiti-specific web servers (see the
86
- * [remote implementation](https://github.com/graffiti-garden/implementation-remote)).
85
+ * and `graffiti:remote:` for objects stored on Graffiti-specific web servers (see the [remote implementation](https://github.com/graffiti-garden/implementation-remote))
87
86
  * Options available in the future might include `graffiti:solid:` for objects stored on Solid servers
88
87
  * or `graffiti:p2p:` for objects stored on a peer-to-peer network.
89
88
  */
90
89
  url: string;
91
90
  /**
92
- * The time the object was last modified, measured in milliseconds since January 1, 1970.
93
- * It can be used to compare object versions.
94
- * A number, rather than an ISO string or Date object, is used for easy comparison, sorting,
95
- * and JSON Schema [range queries](https://json-schema.org/understanding-json-schema/reference/numeric#range).
91
+ * A number used to compare different versions of an object that has been
92
+ * updated via replacement (see {@link Graffiti.put}) or
93
+ * patch (see {@link Graffiti.patch}). Newer versions of
94
+ * an object have larger `revision` values than older versions.
95
+ * The `revision` can only
96
+ * be used to compare different versions of the same object,
97
+ * but cannot reliably be used to compare different objects.
98
+ * In cases where comparing different objects by time is useful,
99
+ * you could instead add `createdAt` or `lastModified` timestamp properties
100
+ * to an object's {@link value | `value`}.
96
101
  *
97
- * It is possible to use this value to sort objects in a user's interface but in many cases it would be better to
98
- * use a [`published`](https://www.w3.org/TR/activitystreams-vocabulary/#dfn-published)
99
- * property in the object's {@link value | `value`} to indicate when the object was created
100
- * rather than when it was modified.
102
+ * Depending on the implementation, the revision may be a timestamp,
103
+ * an incremental counter, may include randomness for obfuscation, and so on.
104
+ * Be careful not to rely on any of these specific `revision` instantiations
105
+ * as they may not be consistent across different implementations.
101
106
  */
102
107
  lastModified: number;
103
108
  }
@@ -150,13 +155,13 @@ export declare const GraffitiObjectJSONSchema: {
150
155
  /**
151
156
  * This is an object containing only the {@link GraffitiObjectBase.url | `url`}
152
157
  * property of a {@link GraffitiObjectBase | GraffitiObject}.
153
- * It is used as a utility type so that users can call {@link Graffiti.get},
158
+ * It is used as a utility type so that applications can call {@link Graffiti.get},
154
159
  * {@link Graffiti.patch}, or {@link Graffiti.delete} directly on an object
155
160
  * rather than on `object.url`.
156
161
  */
157
162
  export type GraffitiObjectUrl = Pick<GraffitiObjectBase, "url">;
158
163
  /**
159
- * This object is a subset of {@link GraffitiObjectBase} that a user must construct locally before calling {@link Graffiti.put}.
164
+ * This object is a subset of {@link GraffitiObjectBase} that must be constructed locally before calling {@link Graffiti.put}.
160
165
  * This local copy does not require system-generated properties and may be statically typed with
161
166
  * a [JSON schema](https://json-schema.org/) to prevent the accidental creation of erroneous objects.
162
167
  *
@@ -209,13 +214,12 @@ export declare const GraffitiPutObjectJSONSchema: {
209
214
  };
210
215
  /**
211
216
  * This object contains information that the underlying implementation can
212
- * use to verify that a user has permission to operate a
213
- * particular {@link GraffitiObjectBase.actor | `actor`}.
217
+ * use to authenticate a particular {@link GraffitiObjectBase.actor | `actor`}.
214
218
  * This object is required of all {@link Graffiti} methods
215
219
  * that modify objects and is optional for methods that read objects.
216
220
  *
217
221
  * At a minimum the `session` object must contain the
218
- * {@link GraffitiSession.actor | `actor`} URI the user wants to authenticate with.
222
+ * {@link GraffitiSession.actor | `actor`} URI to authenticate with.
219
223
  * However it is likely that the `session` object must contain other
220
224
  * implementation-specific properties.
221
225
  * For example, a Solid implementation might include a
@@ -226,7 +230,7 @@ export declare const GraffitiPutObjectJSONSchema: {
226
230
  * As to why the `session` object is passed as an argument to every method
227
231
  * rather than being an internal property of the {@link Graffiti} instance,
228
232
  * this is primarily for type-checking to catch bugs related to login state.
229
- * Graffiti applications can expose some functionality to users who are not logged in
233
+ * Graffiti applications can expose some functionality to people who are not logged in
230
234
  * with {@link Graffiti.get} and {@link Graffiti.discover} but without type-checking
231
235
  * the `session` it can be easy to forget to hide buttons that trigger
232
236
  * other methods that require login.
@@ -240,14 +244,14 @@ export declare const GraffitiPutObjectJSONSchema: {
240
244
  */
241
245
  export interface GraffitiSession {
242
246
  /**
243
- * The {@link GraffitiObjectBase.actor | `actor`} a user wants to authenticate with.
247
+ * The {@link GraffitiObjectBase.actor | `actor`} to authenticate with.
244
248
  */
245
249
  actor: string;
246
250
  /**
247
251
  * A yet undefined property detailing what operations the session
248
- * grants the user to perform. For example, to allow a user to
252
+ * grants the actor to perform. For example, to allow a actor to
249
253
  * read private messages from a particular set of channels or
250
- * to allow the user to write object matching a particular schema.
254
+ * to allow the actor to write object matching a particular schema.
251
255
  */
252
256
  scope?: {};
253
257
  }
@@ -343,7 +347,7 @@ export interface GraffitiObjectStreamEntry<Schema extends JSONSchema> {
343
347
  * A result from a {@link GraffitiObjectStreamContinue} that indicated
344
348
  * an object has been deleted since the original stream was run.
345
349
  * Only sparse metadata about the deleted object is returned to respect
346
- * the deleting user's privacy.
350
+ * the deleting actor's privacy.
347
351
  *
348
352
  * @internal
349
353
  */
@@ -359,7 +363,7 @@ export interface GraffitiObjectStreamContinueTombstone {
359
363
  tombstone: true;
360
364
  /**
361
365
  * Sparse metadata about the deleted object. The full object is not returned
362
- * to respect a user's privacy.
366
+ * to respect a actor's privacy.
363
367
  */
364
368
  object: {
365
369
  /**
@@ -392,7 +396,7 @@ export type GraffitiObjectStreamContinueEntry<Schema extends JSONSchema> = Graff
392
396
  * that allows the stream to be continued from where it left off.
393
397
  *
394
398
  * The {@link continue} function preserves the typing of the original stream,
395
- * where as the {@link cursor} string can be serialized for use after a user
399
+ * where as the {@link cursor} string can be serialized for use after a person
396
400
  * has closed and reopened an application.
397
401
  *
398
402
  * The continued stream may include `tombstone`s of objects that have been
@@ -459,7 +463,7 @@ export type GraffitiChannelStatsStream = AsyncGenerator<GraffitiStreamError | {
459
463
  }>;
460
464
  /**
461
465
  * The event type produced in {@link Graffiti.sessionEvents}
462
- * when a user logs in manually from {@link Graffiti.login}
466
+ * when a actor logs in manually from {@link Graffiti.login}
463
467
  * or when their session is restored from a previous login.
464
468
  * The event name to listen for is `login`.
465
469
  */
@@ -472,7 +476,7 @@ export type GraffitiLoginEvent = CustomEvent<{
472
476
  }>;
473
477
  /**
474
478
  * The event type produced in {@link Graffiti.sessionEvents}
475
- * when a user logs out either manually with {@link Graffiti.logout}
479
+ * when a actor logs out either manually with {@link Graffiti.logout}
476
480
  * or when their session times out or otherwise becomes invalid.
477
481
  * The event name to listen for is `logout`.
478
482
  */
@@ -491,8 +495,8 @@ export type GraffitiLogoutEvent = CustomEvent<{
491
495
  * their own {@link GraffitiLoginEvent} events.
492
496
  *
493
497
  * This event optionally returns an `href` property
494
- * representing the URL the user originated a login request
495
- * from, which may be useful for redirecting the user back to
498
+ * representing the URL that originated a login request,
499
+ * which may be useful for redirecting the user back to
496
500
  * the page they were on after login.
497
501
  * The event name to listen for is `initialized`.
498
502
  */
@@ -1 +1 @@
1
- {"version":3,"file":"2-types.d.ts","sourceRoot":"","sources":["../../src/2-types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAChE,OAAO,KAAK,EAAE,SAAS,IAAI,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAEvE;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,WAAW,kBAAkB;IACjC;;;;;OAKG;IACH,KAAK,EAAE,EAAE,CAAC;IAEV;;;;;;;;;;;;OAYG;IACH,QAAQ,EAAE,MAAM,EAAE,CAAC;IAEnB;;;;;;;;;;;;;OAaG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAE1B;;;;;;;;;;;;OAYG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;;;;;;;;;;;;;;;;OAiBG;IACH,GAAG,EAAE,MAAM,CA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