@sandvichxyz/pecans 1.1.1 → 1.1.3

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.
Files changed (107) hide show
  1. package/dist/generated/client.d.ts +2 -0
  2. package/dist/generated/client.d.ts.map +1 -1
  3. package/dist/generated/client.js +8 -2
  4. package/dist/generated/client.js.map +1 -1
  5. package/dist/generated/decoders.d.ts +5 -1
  6. package/dist/generated/decoders.d.ts.map +1 -1
  7. package/dist/generated/decoders.js +33 -0
  8. package/dist/generated/decoders.js.map +1 -1
  9. package/dist/generated/encoders.d.ts +4 -0
  10. package/dist/generated/encoders.d.ts.map +1 -0
  11. package/dist/generated/encoders.js +25 -0
  12. package/dist/generated/encoders.js.map +1 -0
  13. package/dist/generated/enums.d.ts +2 -1
  14. package/dist/generated/enums.d.ts.map +1 -1
  15. package/dist/generated/enums.js +1 -0
  16. package/dist/generated/enums.js.map +1 -1
  17. package/dist/generated/index.d.ts +2 -0
  18. package/dist/generated/index.d.ts.map +1 -1
  19. package/dist/generated/index.js +2 -0
  20. package/dist/generated/index.js.map +1 -1
  21. package/dist/generated/modules/answer.d.ts +28 -1
  22. package/dist/generated/modules/answer.d.ts.map +1 -1
  23. package/dist/generated/modules/answer.js +39 -0
  24. package/dist/generated/modules/answer.js.map +1 -1
  25. package/dist/generated/modules/auth.d.ts +22 -1
  26. package/dist/generated/modules/auth.d.ts.map +1 -1
  27. package/dist/generated/modules/auth.js +26 -0
  28. package/dist/generated/modules/auth.js.map +1 -1
  29. package/dist/generated/modules/forum.d.ts +61 -0
  30. package/dist/generated/modules/forum.d.ts.map +1 -1
  31. package/dist/generated/modules/forum.js +74 -0
  32. package/dist/generated/modules/forum.js.map +1 -1
  33. package/dist/generated/modules/messages.d.ts +29 -0
  34. package/dist/generated/modules/messages.d.ts.map +1 -1
  35. package/dist/generated/modules/messages.js +29 -0
  36. package/dist/generated/modules/messages.js.map +1 -1
  37. package/dist/generated/modules/notify.d.ts +13 -0
  38. package/dist/generated/modules/notify.d.ts.map +1 -1
  39. package/dist/generated/modules/notify.js +13 -0
  40. package/dist/generated/modules/notify.js.map +1 -1
  41. package/dist/generated/modules/profile.d.ts +9 -1
  42. package/dist/generated/modules/profile.d.ts.map +1 -1
  43. package/dist/generated/modules/profile.js +18 -0
  44. package/dist/generated/modules/profile.js.map +1 -1
  45. package/dist/generated/modules/stories.d.ts +6 -8
  46. package/dist/generated/modules/stories.d.ts.map +1 -1
  47. package/dist/generated/modules/stories.js +8 -8
  48. package/dist/generated/modules/stories.js.map +1 -1
  49. package/dist/generated/types.d.ts +153 -0
  50. package/dist/generated/types.d.ts.map +1 -1
  51. package/dist/runtime/index.d.ts +1 -0
  52. package/dist/runtime/index.d.ts.map +1 -1
  53. package/dist/runtime/index.js +1 -0
  54. package/dist/runtime/index.js.map +1 -1
  55. package/dist/runtime/transform.d.ts +19 -0
  56. package/dist/runtime/transform.d.ts.map +1 -0
  57. package/dist/runtime/transform.js +40 -0
  58. package/dist/runtime/transform.js.map +1 -0
  59. package/package.json +1 -1
  60. package/dist/account/index.d.ts +0 -7
  61. package/dist/account/index.d.ts.map +0 -1
  62. package/dist/account/index.js +0 -24
  63. package/dist/account/index.js.map +0 -1
  64. package/dist/answer/index.d.ts +0 -11
  65. package/dist/answer/index.d.ts.map +0 -1
  66. package/dist/answer/index.js +0 -35
  67. package/dist/answer/index.js.map +0 -1
  68. package/dist/auth/index.d.ts +0 -6
  69. package/dist/auth/index.d.ts.map +0 -1
  70. package/dist/auth/index.js +0 -16
  71. package/dist/auth/index.js.map +0 -1
  72. package/dist/client.d.ts +0 -42
  73. package/dist/client.d.ts.map +0 -1
  74. package/dist/client.js +0 -150
  75. package/dist/client.js.map +0 -1
  76. package/dist/drawing/index.d.ts +0 -8
  77. package/dist/drawing/index.d.ts.map +0 -1
  78. package/dist/drawing/index.js +0 -28
  79. package/dist/drawing/index.js.map +0 -1
  80. package/dist/enums.d.ts +0 -11
  81. package/dist/enums.d.ts.map +0 -1
  82. package/dist/enums.js +0 -17
  83. package/dist/enums.js.map +0 -1
  84. package/dist/extensions/ask.d.ts +0 -10
  85. package/dist/extensions/ask.d.ts.map +0 -1
  86. package/dist/extensions/ask.js +0 -25
  87. package/dist/extensions/ask.js.map +0 -1
  88. package/dist/forum/index.d.ts +0 -10
  89. package/dist/forum/index.d.ts.map +0 -1
  90. package/dist/forum/index.js +0 -42
  91. package/dist/forum/index.js.map +0 -1
  92. package/dist/messages/index.d.ts +0 -9
  93. package/dist/messages/index.d.ts.map +0 -1
  94. package/dist/messages/index.js +0 -33
  95. package/dist/messages/index.js.map +0 -1
  96. package/dist/module.d.ts +0 -7
  97. package/dist/module.d.ts.map +0 -1
  98. package/dist/module.js +0 -27
  99. package/dist/module.js.map +0 -1
  100. package/dist/notify/index.d.ts +0 -8
  101. package/dist/notify/index.d.ts.map +0 -1
  102. package/dist/notify/index.js +0 -19
  103. package/dist/notify/index.js.map +0 -1
  104. package/dist/types.d.ts +0 -19
  105. package/dist/types.d.ts.map +0 -1
  106. package/dist/types.js +0 -3
  107. package/dist/types.js.map +0 -1
@@ -22,6 +22,16 @@ class ForumModule extends runtime_1.Module {
22
22
  },
23
23
  });
24
24
  }
25
+ /**
26
+ * View posts in a thread.
27
+ *
28
+ * @param threadId - Id of the thread to view.
29
+ * @param fetchType - "new" to fetch new posts, "backscroll" to fetch older posts.
30
+ * @param postId - Id of the post to start fetching from. Defaults to 0 (the first post).
31
+ * @param reverse - If true, fetch posts in reverse order (newest first). Defaults to false.
32
+ * @param includePost - If true, include the post with id `postId` in the results. Defaults to true.
33
+ * @returns A ViewPostsResponse object containing the requested posts and thread metadata.
34
+ */
25
35
  viewPosts(threadId, fetchType, postId = 0, reverse = false, includePost = true) {
26
36
  return new runtime_1.Call(this.client, {
27
37
  fn: "forum.viewposts",
@@ -35,6 +45,13 @@ class ForumModule extends runtime_1.Module {
35
45
  },
36
46
  });
37
47
  }
48
+ /**
49
+ * Reply to a thread with a new post.
50
+ *
51
+ * @param text - Body text of the reply (UCP markup).
52
+ * @param threadId - Id of the thread to reply to.
53
+ * @returns A TCResponse object indicating the result of the reply attempt.
54
+ */
38
55
  replyThread(text, threadId) {
39
56
  return new runtime_1.Call(this.client, {
40
57
  fn: "forum.replythread",
@@ -44,6 +61,13 @@ class ForumModule extends runtime_1.Module {
44
61
  },
45
62
  });
46
63
  }
64
+ /**
65
+ * Mark a thread as read, clearing the new-post indicator for that thread.
66
+ *
67
+ * @param postId - Id of the last post read in the thread.
68
+ * @param threadId - Id of the thread to mark as read.
69
+ * @returns A TCResponse object indicating the result of the operation.
70
+ */
47
71
  readThread(postId, threadId) {
48
72
  return new runtime_1.Call(this.client, {
49
73
  fn: "forum.readthread",
@@ -53,6 +77,13 @@ class ForumModule extends runtime_1.Module {
53
77
  },
54
78
  });
55
79
  }
80
+ /**
81
+ * Edit a post's text.
82
+ *
83
+ * @param postId - Id of the post to edit.
84
+ * @param text - New body text for the post (UCP markup).
85
+ * @returns A TCResponse object indicating the result of the edit attempt.
86
+ */
56
87
  editPost(postId, text) {
57
88
  return new runtime_1.Call(this.client, {
58
89
  fn: "forum.editpost",
@@ -62,6 +93,12 @@ class ForumModule extends runtime_1.Module {
62
93
  },
63
94
  });
64
95
  }
96
+ /**
97
+ * Search the forum for posts matching a query.
98
+ *
99
+ * @param query - Search query string.
100
+ * @returns A ForumSearchResponse object containing the search results.
101
+ */
65
102
  search(query) {
66
103
  return new runtime_1.Call(this.client, {
67
104
  fn: "forum.search",
@@ -70,12 +107,24 @@ class ForumModule extends runtime_1.Module {
70
107
  },
71
108
  });
72
109
  }
110
+ /**
111
+ * Get the list of forum categories.
112
+ *
113
+ * @returns A ForumCategoriesResponse object containing the list of categories.
114
+ */
73
115
  categoriesGet() {
74
116
  return new runtime_1.Call(this.client, {
75
117
  fn: "forum.categoriesget",
76
118
  payload: {},
77
119
  });
78
120
  }
121
+ /**
122
+ * Get the list of threads in a category.
123
+ *
124
+ * @param category - Id of the category to fetch threads from.
125
+ * @param offset - Number of threads to skip (for pagination). Defaults to 0.
126
+ * @returns A ThreadListResponse object containing the list of threads in the category.
127
+ */
79
128
  threadList(category, offset = 0) {
80
129
  return new runtime_1.Call(this.client, {
81
130
  fn: "forum.threadlist",
@@ -114,6 +163,31 @@ class ForumModule extends runtime_1.Module {
114
163
  },
115
164
  });
116
165
  }
166
+ /**
167
+ * Flag a post for mod attention.
168
+ *
169
+ * @param postId - Id of the post being flagged.
170
+ * @param comment - Reason the post is being flagged.
171
+ */
172
+ flagPost(postId, comment) {
173
+ return new runtime_1.Call(this.client, {
174
+ fn: "forum.flagpost",
175
+ payload: {
176
+ postId: postId,
177
+ comment: comment,
178
+ },
179
+ });
180
+ }
181
+ /**
182
+ * Mark every thread as read, clearing all new-post indicators. This is
183
+ * irreversible and sets `ForumCategory.newThreads` to 0 for every category.
184
+ */
185
+ readAll() {
186
+ return new runtime_1.Call(this.client, {
187
+ fn: "forum.readall",
188
+ payload: {},
189
+ });
190
+ }
117
191
  }
118
192
  exports.ForumModule = ForumModule;
119
193
  //# sourceMappingURL=forum.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"forum.js","sourceRoot":"","sources":["../../../src/generated/modules/forum.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAW7C,MAAa,WAAY,SAAQ,gBAAM;IACnC;;;;;;;OAOG;IACI,SAAS,CAAC,QAAgB,EAAE,KAAa,EAAE,IAAY;QAC1D,OAAO,IAAI,cAAI,CAAoB,IAAI,CAAC,MAAM,EAAE;YAC5C,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,QAAQ,EAAE,QAAQ;gBAClB,KAAK,EAAE,KAAK;gBACZ,IAAI,EAAE,IAAI;aACb;SACJ,CAAC,CAAC;IACP,CAAC;IAEM,SAAS,CACZ,QAAgB,EAChB,SAAiB,EACjB,SAAiB,CAAC,EAClB,UAAmB,KAAK,EACxB,cAAuB,IAAI;QAE3B,OAAO,IAAI,cAAI,CAAo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C"}
@@ -1,9 +1,38 @@
1
1
  import { Call, Module } from "../../runtime";
2
2
  import { FolderListResponse, FolderViewResponse, MessageViewResponse, TCResponse } from "../types";
3
3
  export declare class MessagesModule extends Module {
4
+ /**
5
+ * Get a list of messages in a folder.
6
+ *
7
+ * @param folder - The folder to view. Defaults to "inbox".
8
+ * @param page - The page number to view. Defaults to 1.
9
+ * @returns A FolderViewResponse object containing the messages in the folder.
10
+ */
4
11
  folderView(folder?: string, page?: number): Call<FolderViewResponse>;
12
+ /**
13
+ * View a conversation thread.
14
+ *
15
+ * @param conversationId - The id of the conversation to view.
16
+ * @param includeHeader - Whether to include the conversation header in the response. Defaults to true.
17
+ * @param markAsRead - Whether to mark the conversation as read. Defaults to true.
18
+ * @param page - The page number of messages to view. Defaults to 1.
19
+ * @returns A MessageViewResponse object containing the messages in the conversation and the header if requested.
20
+ */
5
21
  view(conversationId: string, includeHeader?: boolean, markAsRead?: boolean, page?: number): Call<MessageViewResponse>;
22
+ /**
23
+ * Reply to a conversation thread.
24
+ *
25
+ * @param conversationId - The id of the conversation to reply to.
26
+ * @param text - The body text of the reply (UCP markup).
27
+ * @param unanonymize - Whether to send the reply as your real username instead of anonymously. Defaults to false.
28
+ * @returns A TCResponse object indicating the result of the reply attempt.
29
+ */
6
30
  reply(conversationId: string, text: string, unanonymize?: boolean): Call<TCResponse>;
31
+ /**
32
+ * Get a list of the user's message folders.
33
+ *
34
+ * @returns A FolderListResponse object containing the user's message folders.
35
+ */
7
36
  folderList(): Call<FolderListResponse>;
8
37
  /**
9
38
  * Start a new conversation with one or more recipients.
@@ -1 +1 @@
1
- {"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/messages.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEnG,qB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OAAc,EAC1B,IAAI,GAAE,MAAU,GACjB,IAAI,CAAC,mBAAmB,CAAC;IAY5B;;;;;;;OAOG;IACI,KAAK,CACR,cAAc,EAAE,MAAM,EACtB,IAAI,EAAE,MAAM,EACZ,WAAW,GAAE,OAAe,GAC7B,IAAI,CAAC,UAAU,CAAC;IAWnB;;;;OAIG;IACI,UAAU,IAAI,IAAI,CAAC,kBAAkB,CAAC;IAO7C;;;;;;OAMG;IACI,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,UAAU,CAAC;IAW7F;;;;OAIG;IACI,MAAM,CAAC,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;IASvD;;;;;OAKG;IACI,YAAY,CAAC,cAAc,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;CAShF"}
@@ -4,6 +4,13 @@ exports.MessagesModule = void 0;
4
4
  /* Generated by pecans-spec. Do not edit. */
5
5
  const runtime_1 = require("../../runtime");
6
6
  class MessagesModule extends runtime_1.Module {
7
+ /**
8
+ * Get a list of messages in a folder.
9
+ *
10
+ * @param folder - The folder to view. Defaults to "inbox".
11
+ * @param page - The page number to view. Defaults to 1.
12
+ * @returns A FolderViewResponse object containing the messages in the folder.
13
+ */
7
14
  folderView(folder = "inbox", page = 1) {
8
15
  return new runtime_1.Call(this.client, {
9
16
  fn: "messages.folderview",
@@ -13,6 +20,15 @@ class MessagesModule extends runtime_1.Module {
13
20
  },
14
21
  });
15
22
  }
23
+ /**
24
+ * View a conversation thread.
25
+ *
26
+ * @param conversationId - The id of the conversation to view.
27
+ * @param includeHeader - Whether to include the conversation header in the response. Defaults to true.
28
+ * @param markAsRead - Whether to mark the conversation as read. Defaults to true.
29
+ * @param page - The page number of messages to view. Defaults to 1.
30
+ * @returns A MessageViewResponse object containing the messages in the conversation and the header if requested.
31
+ */
16
32
  view(conversationId, includeHeader = true, markAsRead = true, page = 1) {
17
33
  return new runtime_1.Call(this.client, {
18
34
  fn: "messages.view",
@@ -24,6 +40,14 @@ class MessagesModule extends runtime_1.Module {
24
40
  },
25
41
  });
26
42
  }
43
+ /**
44
+ * Reply to a conversation thread.
45
+ *
46
+ * @param conversationId - The id of the conversation to reply to.
47
+ * @param text - The body text of the reply (UCP markup).
48
+ * @param unanonymize - Whether to send the reply as your real username instead of anonymously. Defaults to false.
49
+ * @returns A TCResponse object indicating the result of the reply attempt.
50
+ */
27
51
  reply(conversationId, text, unanonymize = false) {
28
52
  return new runtime_1.Call(this.client, {
29
53
  fn: "messages.reply",
@@ -34,6 +58,11 @@ class MessagesModule extends runtime_1.Module {
34
58
  },
35
59
  });
36
60
  }
61
+ /**
62
+ * Get a list of the user's message folders.
63
+ *
64
+ * @returns A FolderListResponse object containing the user's message folders.
65
+ */
37
66
  folderList() {
38
67
  return new runtime_1.Call(this.client, {
39
68
  fn: "messages.folderlist",
@@ -1 +1 @@
1
- {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/generated/modules/messages.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAG7C,MAAa,cAAe,SAAQ,gBAAM;IAC/B,UAAU,CAAC,SAAiB,OAAO,EAAE,OAAe,CAAC;QACxD,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,qBAAqB;YACzB,OAAO,EAAE;gBACL,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,IAAI;aACb;SACJ,CAAC,CAAC;IACP,CAAC;IAEM,IAAI,CACP,cAAsB,EACtB,gBAAyB,IAAI,EAC7B,aAAsB,IAAI,EAC1B,OAAe,CAAC;QAEhB,OAAO,IAAI,cAAI,CAAsB,IAAI,CAAC,MAAM,EAAE;YAC9C,EAAE,EAAE,eAAe;YACnB,OAAO,EAAE;gBACL,cAAc,EAAE,cAAc;gBAC9B,aAAa,EAAE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"}
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/generated/modules/messages.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAG7C,MAAa,cAAe,SAAQ,gBAAM;IACtC;;;;;;OAMG;IACI,UAAU,CAAC,SAAiB,OAAO,EAAE,OAAe,CAAC;QACxD,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,qBAAqB;YACzB,OAAO,EAAE;gBACL,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,IAAI;aACb;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;;;;OAQG;IACI,IAAI,CACP,cAAsB,EACtB,gBAAyB,IAAI,EAC7B,aAAsB,IAAI,EAC1B,OAAe,CAAC;QAEhB,OAAO,IAAI,cAAI,CAAsB,IAAI,CAAC,MAAM,EAAE;YAC9C,EAAE,EAAE,eAAe;YACnB,OAAO,EAAE;gBACL,cAAc,EAAE,cAAc;gBAC9B,aAAa,EAAE,aAAa;gBAC5B,UAAU,EAAE,UAAU;gBACtB,IAAI,EAAE,IAAI;aACb;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;;;OAOG;IACI,KAAK,CACR,cAAsB,EACtB,IAAY,EACZ,cAAuB,KAAK;QAE5B,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,gBAAgB;YACpB,OAAO,EAAE;gBACL,cAAc,EAAE,cAAc;gBAC9B,IAAI,EAAE,IAAI;gBACV,WAAW,EAAE,WAAW;aAC3B;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;OAIG;IACI,UAAU;QACb,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,qBAAqB;YACzB,OAAO,EAAE,EAAE;SACd,CAAC,CAAC;IACP,CAAC;IAED;;;;;;OAMG;IACI,iBAAiB,CAAC,KAAa,EAAE,IAAY,EAAE,UAAoB;QACtE,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,4BAA4B;YAChC,OAAO,EAAE;gBACL,KAAK,EAAE,KAAK;gBACZ,IAAI,EAAE,IAAI;gBACV,UAAU,EAAE,UAAU;aACzB;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;OAIG;IACI,MAAM,CAAC,cAAsB;QAChC,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,cAAc,EAAE,cAAc;aACjC;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,YAAY,CAAC,cAAsB,EAAE,MAAc;QACtD,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,uBAAuB;YAC3B,OAAO,EAAE;gBACL,cAAc,EAAE,cAAc;gBAC9B,MAAM,EAAE,MAAM;aACjB;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AA9HD,wCA8HC"}
@@ -2,7 +2,20 @@ import { Call, Module } from "../../runtime";
2
2
  import { NotifySyncResponse, TCResponse, WhosOnlineResponse } from "../types";
3
3
  import { Feature } from "../enums";
4
4
  export declare class NotifyModule extends Module {
5
+ /**
6
+ * Synchronize notifications for a given feature.
7
+ *
8
+ * @param feature - The feature for which to synchronize notifications.
9
+ * @returns A NotifySyncResponse object containing the result of the synchronization.
10
+ */
5
11
  sync(feature: Feature): Call<NotifySyncResponse>;
12
+ /**
13
+ * Fetch a list of users currently online for a given feature. Currently
14
+ * only supports the `Feature.FORUM` feature.
15
+ *
16
+ * @param feature - The feature for which to fetch online users.
17
+ * @returns A WhosOnlineResponse object containing the list of online users.
18
+ */
6
19
  fetchOnlineUsers(feature: Feature): Call<WhosOnlineResponse>;
7
20
  /**
8
21
  * Register that you're viewing a page, for presence and read-tracking.
@@ -1 +1 @@
1
- {"version":3,"file":"notify.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/notify.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAC9E,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAEnC,qBAAa,YAAa,SAAQ,MAAM;IAC7B,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,kBAAkB,CAAC;IAShD,gBAAgB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,kBAAkB,CAAC;IASnE;;;;OAIG;IACI,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;CAQjD"}
1
+ {"version":3,"file":"notify.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/notify.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAC9E,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAEnC,qBAAa,YAAa,SAAQ,MAAM;IACpC;;;;;OAKG;IACI,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,kBAAkB,CAAC;IASvD;;;;;;OAMG;IACI,gBAAgB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,kBAAkB,CAAC;IASnE;;;;OAIG;IACI,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;CAQjD"}
@@ -4,6 +4,12 @@ exports.NotifyModule = void 0;
4
4
  /* Generated by pecans-spec. Do not edit. */
5
5
  const runtime_1 = require("../../runtime");
6
6
  class NotifyModule extends runtime_1.Module {
7
+ /**
8
+ * Synchronize notifications for a given feature.
9
+ *
10
+ * @param feature - The feature for which to synchronize notifications.
11
+ * @returns A NotifySyncResponse object containing the result of the synchronization.
12
+ */
7
13
  sync(feature) {
8
14
  return new runtime_1.Call(this.client, {
9
15
  fn: "notify.sync",
@@ -12,6 +18,13 @@ class NotifyModule extends runtime_1.Module {
12
18
  },
13
19
  });
14
20
  }
21
+ /**
22
+ * Fetch a list of users currently online for a given feature. Currently
23
+ * only supports the `Feature.FORUM` feature.
24
+ *
25
+ * @param feature - The feature for which to fetch online users.
26
+ * @returns A WhosOnlineResponse object containing the list of online users.
27
+ */
15
28
  fetchOnlineUsers(feature) {
16
29
  return new runtime_1.Call(this.client, {
17
30
  fn: "notify.whosonline",
@@ -1 +1 @@
1
- {"version":3,"file":"notify.js","sourceRoot":"","sources":["../../../src/generated/modules/notify.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAI7C,MAAa,YAAa,SAAQ,gBAAM;IAC7B,IAAI,CAAC,OAAgB;QACxB,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,aAAa;YACjB,OAAO,EAAE;gBACL,OAAO,EAAE,OAAO;aACnB;SACJ,CAAC,CAAC;IACP,CAAC;IAEM,gBAAgB,CAAC,OAAgB;QACpC,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,mBAAmB;YACvB,OAAO,EAAE;gBACL,OAAO,EAAE,OAAO;aACnB;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;OAIG;IACI,QAAQ,CAAC,GAAW;QACvB,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,GAAG,EAAE,GAAG;aACX;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AAhCD,oCAgCC"}
1
+ {"version":3,"file":"notify.js","sourceRoot":"","sources":["../../../src/generated/modules/notify.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAI7C,MAAa,YAAa,SAAQ,gBAAM;IACpC;;;;;OAKG;IACI,IAAI,CAAC,OAAgB;QACxB,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,aAAa;YACjB,OAAO,EAAE;gBACL,OAAO,EAAE,OAAO;aACnB;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;;OAMG;IACI,gBAAgB,CAAC,OAAgB;QACpC,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,mBAAmB;YACvB,OAAO,EAAE;gBACL,OAAO,EAAE,OAAO;aACnB;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;OAIG;IACI,QAAQ,CAAC,GAAW;QACvB,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,GAAG,EAAE,GAAG;aACX;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AA7CD,oCA6CC"}
@@ -1,5 +1,5 @@
1
1
  import { Call, Module } from "../../runtime";
2
- import { ProfileDetailsResponse, ProfileGetResponse, TCResponse } from "../types";
2
+ import { ListFollowersResponse, ListFollowsResponse, ProfileDetailsResponse, ProfileGetResponse, TCResponse } from "../types";
3
3
  export declare class ProfileModule extends Module {
4
4
  /**
5
5
  * Check whether a profile exists and resolve its canonical id.
@@ -30,5 +30,13 @@ export declare class ProfileModule extends Module {
30
30
  * @param follow - True to follow, false to unfollow.
31
31
  */
32
32
  toggleFollow(id: string, follow: boolean): Call<TCResponse>;
33
+ /**
34
+ * List the users who follow you.
35
+ */
36
+ listFollowers(): Call<ListFollowersResponse>;
37
+ /**
38
+ * List the users you follow (your subscriptions).
39
+ */
40
+ listFollows(): Call<ListFollowsResponse>;
33
41
  }
34
42
  //# sourceMappingURL=profile.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"profile.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/profile.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAElF,qBAAa,aAAc,SAAQ,MAAM;IACrC;;;;;OAKG;IACI,GAAG,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC,kBAAkB,CAAC;IAShD;;;;;;OAMG;IACI,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC,sBAAsB,CAAC;IAUzE;;;;;OAKG;IACI,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;IAU3D;;;;;OAKG;IACI,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC,UAAU,CAAC;CASrE"}
1
+ {"version":3,"file":"profile.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/profile.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EACH,qBAAqB,EACrB,mBAAmB,EACnB,sBAAsB,EACtB,kBAAkB,EAClB,UAAU,EACb,MAAM,UAAU,CAAC;AAElB,qBAAa,aAAc,SAAQ,MAAM;IACrC;;;;;OAKG;IACI,GAAG,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC,kBAAkB,CAAC;IAShD;;;;;;OAMG;IACI,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC,sBAAsB,CAAC;IAUzE;;;;;OAKG;IACI,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;IAU3D;;;;;OAKG;IACI,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,GAAG,IAAI,CAAC,UAAU,CAAC;IAUlE;;OAEG;IACI,aAAa,IAAI,IAAI,CAAC,qBAAqB,CAAC;IAOnD;;OAEG;IACI,WAAW,IAAI,IAAI,CAAC,mBAAmB,CAAC;CAMlD"}
@@ -64,6 +64,24 @@ class ProfileModule extends runtime_1.Module {
64
64
  },
65
65
  });
66
66
  }
67
+ /**
68
+ * List the users who follow you.
69
+ */
70
+ listFollowers() {
71
+ return new runtime_1.Call(this.client, {
72
+ fn: "profile.listfollowers",
73
+ payload: {},
74
+ });
75
+ }
76
+ /**
77
+ * List the users you follow (your subscriptions).
78
+ */
79
+ listFollows() {
80
+ return new runtime_1.Call(this.client, {
81
+ fn: "profile.listfollows",
82
+ payload: {},
83
+ });
84
+ }
67
85
  }
68
86
  exports.ProfileModule = ProfileModule;
69
87
  //# sourceMappingURL=profile.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"profile.js","sourceRoot":"","sources":["../../../src/generated/modules/profile.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAG7C,MAAa,aAAc,SAAQ,gBAAM;IACrC;;;;;OAKG;IACI,GAAG,CAAC,EAAU;QACjB,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,aAAa;YACjB,OAAO,EAAE;gBACL,EAAE,EAAE,EAAE;aACT;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;;OAMG;IACI,OAAO,CAAC,IAAY,EAAE,KAAa;QACtC,OAAO,IAAI,cAAI,CAAyB,IAAI,CAAC,MAAM,EAAE;YACjD,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,IAAI,EAAE,IAAI;gBACV,KAAK,EAAE,KAAK;aACf;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,IAAI,CAAC,KAAa,EAAE,KAAa;QACpC,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,cAAc;YAClB,OAAO,EAAE;gBACL,KAAK,EAAE,KAAK;gBACZ,KAAK,EAAE,KAAK;aACf;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,YAAY,CAAC,EAAU,EAAE,MAAe;QAC3C,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,sBAAsB;YAC1B,OAAO,EAAE;gBACL,EAAE,EAAE,EAAE;gBACN,MAAM,EAAE,MAAM;aACjB;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AAhED,sCAgEC"}
1
+ {"version":3,"file":"profile.js","sourceRoot":"","sources":["../../../src/generated/modules/profile.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAS7C,MAAa,aAAc,SAAQ,gBAAM;IACrC;;;;;OAKG;IACI,GAAG,CAAC,EAAU;QACjB,OAAO,IAAI,cAAI,CAAqB,IAAI,CAAC,MAAM,EAAE;YAC7C,EAAE,EAAE,aAAa;YACjB,OAAO,EAAE;gBACL,EAAE,EAAE,EAAE;aACT;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;;OAMG;IACI,OAAO,CAAC,IAAY,EAAE,KAAa;QACtC,OAAO,IAAI,cAAI,CAAyB,IAAI,CAAC,MAAM,EAAE;YACjD,EAAE,EAAE,iBAAiB;YACrB,OAAO,EAAE;gBACL,IAAI,EAAE,IAAI;gBACV,KAAK,EAAE,KAAK;aACf;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,IAAI,CAAC,KAAa,EAAE,KAAa;QACpC,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,cAAc;YAClB,OAAO,EAAE;gBACL,KAAK,EAAE,KAAK;gBACZ,KAAK,EAAE,KAAK;aACf;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,YAAY,CAAC,EAAU,EAAE,MAAe;QAC3C,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,sBAAsB;YAC1B,OAAO,EAAE;gBACL,EAAE,EAAE,EAAE;gBACN,MAAM,EAAE,MAAM;aACjB;SACJ,CAAC,CAAC;IACP,CAAC;IAED;;OAEG;IACI,aAAa;QAChB,OAAO,IAAI,cAAI,CAAwB,IAAI,CAAC,MAAM,EAAE;YAChD,EAAE,EAAE,uBAAuB;YAC3B,OAAO,EAAE,EAAE;SACd,CAAC,CAAC;IACP,CAAC;IAED;;OAEG;IACI,WAAW;QACd,OAAO,IAAI,cAAI,CAAsB,IAAI,CAAC,MAAM,EAAE;YAC9C,EAAE,EAAE,qBAAqB;YACzB,OAAO,EAAE,EAAE;SACd,CAAC,CAAC;IACP,CAAC;CACJ;AApFD,sCAoFC"}
@@ -1,18 +1,16 @@
1
1
  import { Call, Module } from "../../runtime";
2
- import { FerrytellBackground, FerrytellText, StoriesViewListResponse, TCResponse } from "../types";
2
+ import { FerrytellCreateResponse, StoriesViewListResponse, StoryBackgroundInput, StoryText } from "../types";
3
3
  export declare class StoriesModule extends Module {
4
4
  /**
5
- * List the stories currently live across the site.
6
- *
7
- * @returns The live stories, one per user.
5
+ * List the stories currently visible to you.
8
6
  */
9
7
  viewList(): Call<StoriesViewListResponse>;
10
8
  /**
11
- * Post a new story ("ferry tell") with three lines of text over a background.
9
+ * Create a new story ("ferrytell").
12
10
  *
13
- * @param text - The top, middle, and bottom lines and their colors.
14
- * @param bg - The background: an image or a gradient.
11
+ * @param text - The three lines of text and their colors.
12
+ * @param bg - The story background.
15
13
  */
16
- create(text: FerrytellText, bg: FerrytellBackground): Call<TCResponse>;
14
+ create(text: StoryText, bg: StoryBackgroundInput): Call<FerrytellCreateResponse>;
17
15
  }
18
16
  //# sourceMappingURL=stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"stories.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/stories.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,mBAAmB,EAAE,aAAa,EAAE,uBAAuB,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEnG,qBAAa,aAAc,SAAQ,MAAM;IACrC;;;;OAIG;IACI,QAAQ,IAAI,IAAI,CAAC,uBAAuB,CAAC;IAOhD;;;;;OAKG;IACI,MAAM,CAAC,IAAI,EAAE,aAAa,EAAE,EAAE,EAAE,mBAAmB,GAAG,IAAI,CAAC,UAAU,CAAC;CAShF"}
1
+ {"version":3,"file":"stories.d.ts","sourceRoot":"","sources":["../../../src/generated/modules/stories.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EACH,uBAAuB,EACvB,uBAAuB,EACvB,oBAAoB,EACpB,SAAS,EACZ,MAAM,UAAU,CAAC;AAIlB,qBAAa,aAAc,SAAQ,MAAM;IACrC;;OAEG;IACI,QAAQ,IAAI,IAAI,CAAC,uBAAuB,CAAC;IAWhD;;;;;OAKG;IACI,MAAM,CAAC,IAAI,EAAE,SAAS,EAAE,EAAE,EAAE,oBAAoB,GAAG,IAAI,CAAC,uBAAuB,CAAC;CAS1F"}
@@ -3,29 +3,29 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.StoriesModule = void 0;
4
4
  /* Generated by pecans-spec. Do not edit. */
5
5
  const runtime_1 = require("../../runtime");
6
+ const decoders_1 = require("../decoders");
7
+ const encoders_1 = require("../encoders");
6
8
  class StoriesModule extends runtime_1.Module {
7
9
  /**
8
- * List the stories currently live across the site.
9
- *
10
- * @returns The live stories, one per user.
10
+ * List the stories currently visible to you.
11
11
  */
12
12
  viewList() {
13
13
  return new runtime_1.Call(this.client, {
14
14
  fn: "stories.viewlist",
15
15
  payload: {},
16
- });
16
+ }, decoders_1.decodeStoriesViewListResponse);
17
17
  }
18
18
  /**
19
- * Post a new story ("ferry tell") with three lines of text over a background.
19
+ * Create a new story ("ferrytell").
20
20
  *
21
- * @param text - The top, middle, and bottom lines and their colors.
22
- * @param bg - The background: an image or a gradient.
21
+ * @param text - The three lines of text and their colors.
22
+ * @param bg - The story background.
23
23
  */
24
24
  create(text, bg) {
25
25
  return new runtime_1.Call(this.client, {
26
26
  fn: "ferrytell.create",
27
27
  payload: {
28
- text: text,
28
+ text: text == null ? text : (0, encoders_1.encodeStoryText)(text),
29
29
  bg: bg,
30
30
  },
31
31
  });
@@ -1 +1 @@
1
- {"version":3,"file":"stories.js","sourceRoot":"","sources":["../../../src/generated/modules/stories.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAG7C,MAAa,aAAc,SAAQ,gBAAM;IACrC;;;;OAIG;IACI,QAAQ;QACX,OAAO,IAAI,cAAI,CAA0B,IAAI,CAAC,MAAM,EAAE;YAClD,EAAE,EAAE,kBAAkB;YACtB,OAAO,EAAE,EAAE;SACd,CAAC,CAAC;IACP,CAAC;IAED;;;;;OAKG;IACI,MAAM,CAAC,IAAmB,EAAE,EAAuB;QACtD,OAAO,IAAI,cAAI,CAAa,IAAI,CAAC,MAAM,EAAE;YACrC,EAAE,EAAE,kBAAkB;YACtB,OAAO,EAAE;gBACL,IAAI,EAAE,IAAI;gBACV,EAAE,EAAE,EAAE;aACT;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AA5BD,sCA4BC"}
1
+ {"version":3,"file":"stories.js","sourceRoot":"","sources":["../../../src/generated/modules/stories.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAC5C,2CAA6C;AAO7C,0CAA4D;AAC5D,0CAA8C;AAE9C,MAAa,aAAc,SAAQ,gBAAM;IACrC;;OAEG;IACI,QAAQ;QACX,OAAO,IAAI,cAAI,CACX,IAAI,CAAC,MAAM,EACX;YACI,EAAE,EAAE,kBAAkB;YACtB,OAAO,EAAE,EAAE;SACd,EACD,wCAA6B,CAChC,CAAC;IACN,CAAC;IAED;;;;;OAKG;IACI,MAAM,CAAC,IAAe,EAAE,EAAwB;QACnD,OAAO,IAAI,cAAI,CAA0B,IAAI,CAAC,MAAM,EAAE;YAClD,EAAE,EAAE,kBAAkB;YACtB,OAAO,EAAE;gBACL,IAAI,EAAE,IAAI,IAAI,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAA,0BAAe,EAAC,IAAI,CAAC;gBACjD,EAAE,EAAE,EAAE;aACT;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AA9BD,sCA8BC"}
@@ -154,6 +154,11 @@ export type ExistingCookieResponse = TCResponse & {
154
154
  success: boolean;
155
155
  yourId: string;
156
156
  };
157
+ export type LogoutResponse = TCResponse & {
158
+ success: boolean;
159
+ ripToken: string;
160
+ user: string;
161
+ };
157
162
  export type AnswerReplyResponse = TCResponse & {
158
163
  id: number;
159
164
  time: number;
@@ -183,6 +188,9 @@ export type AnswerQuestion = Question & {
183
188
  author?: string;
184
189
  poll?: Poll1;
185
190
  };
191
+ export type SavedQuestionsResponse = TCResponse & {
192
+ questions: SavedQuestion[];
193
+ };
186
194
  export type ListDataResponse = TCResponse & {
187
195
  /**
188
196
  * Question headers, without their body text.
@@ -283,6 +291,21 @@ export type ProfileDetailsResponse = TCResponse & {
283
291
  [k: string]: unknown;
284
292
  };
285
293
  };
294
+ /**
295
+ * An entry in your followers list; adds block state.
296
+ */
297
+ export type FollowerEntry = FollowEntry & {
298
+ /**
299
+ * True if you have blocked this follower.
300
+ */
301
+ blocked: boolean;
302
+ };
303
+ export type ListFollowersResponse = TCResponse & {
304
+ followers: FollowerEntry[];
305
+ };
306
+ export type ListFollowsResponse = TCResponse & {
307
+ follows: FollowEntry[];
308
+ };
286
309
  export type QaGetPinnedResponse = TCResponse & {
287
310
  /**
288
311
  * The questions the user has pinned to their profile.
@@ -320,6 +343,15 @@ export type SettingsGetResponse = TCResponse & {
320
343
  */
321
344
  msgHideAnon: boolean;
322
345
  };
346
+ export type StoriesViewListResponse = TCResponse & {
347
+ stories: Story[];
348
+ };
349
+ export type FerrytellCreateResponse = TCResponse & {
350
+ /**
351
+ * Id of the newly created story.
352
+ */
353
+ storyId: number;
354
+ };
323
355
  export interface TCFollowInfo {
324
356
  in: number;
325
357
  out: number;
@@ -340,6 +372,14 @@ export interface TCUser {
340
372
  id?: string;
341
373
  anon?: boolean;
342
374
  }
375
+ /**
376
+ * An RGB color, normalized from whatever encoded form the Twocans API uses.
377
+ */
378
+ export interface Rgb {
379
+ r: number;
380
+ g: number;
381
+ b: number;
382
+ }
343
383
  export interface ForumCategory {
344
384
  id: string;
345
385
  name: string;
@@ -479,6 +519,20 @@ export interface Poll1 {
479
519
  options: PollOption[];
480
520
  answered: boolean;
481
521
  }
522
+ /**
523
+ * A question the user has saved for later, as shown on the
524
+ * Saved Questions page.
525
+ */
526
+ export interface SavedQuestion {
527
+ /**
528
+ * The question id.
529
+ */
530
+ id: number;
531
+ /**
532
+ * Short preview of the question body.
533
+ */
534
+ preview: string;
535
+ }
482
536
  export interface PollOptionRaw {
483
537
  /**
484
538
  * Number of votes this option has received.
@@ -650,6 +704,19 @@ export interface PostQuestionBody {
650
704
  export interface NewPoll1 {
651
705
  choices: NewPollChoice[];
652
706
  }
707
+ /**
708
+ * One entry in a follower/following list.
709
+ */
710
+ export interface FollowEntry {
711
+ /**
712
+ * The other user's id.
713
+ */
714
+ id: string;
715
+ /**
716
+ * True if the follow relationship is reciprocated.
717
+ */
718
+ mutual: boolean;
719
+ }
653
720
  export interface PinnedQuestion {
654
721
  id: number;
655
722
  /**
@@ -800,4 +867,90 @@ export interface DashboardPointlessNums1 {
800
867
  */
801
868
  questionsAndAnswers: number;
802
869
  }
870
+ /**
871
+ * One line of text on a story. The color is normalized to an `Rgb` struct in
872
+ * both directions, though the wire form is asymmetric: a packed 0xRRGGBB
873
+ * integer when creating a story, an `[r, g, b]` tuple when reading one back.
874
+ */
875
+ export interface StoryLine {
876
+ /**
877
+ * The line's text content.
878
+ */
879
+ value: string;
880
+ color: Rgb1;
881
+ }
882
+ /**
883
+ * An RGB color, normalized from whatever encoded form the Twocans API uses.
884
+ */
885
+ export interface Rgb1 {
886
+ r: number;
887
+ g: number;
888
+ b: number;
889
+ }
890
+ /**
891
+ * The three lines of text composing a story.
892
+ */
893
+ export interface StoryText {
894
+ top: StoryLine;
895
+ middle: StoryLine;
896
+ bottom: StoryLine;
897
+ }
898
+ /**
899
+ * The background of a story, as sent when creating one.
900
+ */
901
+ export interface StoryBackgroundInput {
902
+ /**
903
+ * Background kind, e.g. "image".
904
+ */
905
+ type: string;
906
+ /**
907
+ * Image id, present when `type` is "image".
908
+ */
909
+ image?: string;
910
+ }
911
+ /**
912
+ * The background of a story, as returned by the view list.
913
+ */
914
+ export interface StoryBackground {
915
+ /**
916
+ * True when the background is an image rather than a solid color.
917
+ */
918
+ isImage: boolean;
919
+ /**
920
+ * Image id, present when `isImage` is true.
921
+ */
922
+ imageId?: string;
923
+ }
924
+ /**
925
+ * A story shown in the stories tray.
926
+ */
927
+ export interface Story {
928
+ /**
929
+ * Id of the user whose story this is.
930
+ */
931
+ userId: string;
932
+ background: StoryBackground1;
933
+ text: StoryText1;
934
+ }
935
+ /**
936
+ * The background of a story, as returned by the view list.
937
+ */
938
+ export interface StoryBackground1 {
939
+ /**
940
+ * True when the background is an image rather than a solid color.
941
+ */
942
+ isImage: boolean;
943
+ /**
944
+ * Image id, present when `isImage` is true.
945
+ */
946
+ imageId?: string;
947
+ }
948
+ /**
949
+ * The three lines of text composing a story.
950
+ */
951
+ export interface StoryText1 {
952
+ top: StoryLine;
953
+ middle: StoryLine;
954
+ bottom: StoryLine;
955
+ }
803
956
  //# sourceMappingURL=types.d.ts.map