@37signals/basecamp 0.18.0 → 0.19.0

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 (82) hide show
  1. package/README.md +94 -2
  2. package/dist/client.d.ts +6 -3
  3. package/dist/client.d.ts.map +1 -1
  4. package/dist/client.js +11 -5
  5. package/dist/client.js.map +1 -1
  6. package/dist/download.js +1 -1
  7. package/dist/errors.d.ts +10 -1
  8. package/dist/errors.d.ts.map +1 -1
  9. package/dist/errors.js +42 -13
  10. package/dist/errors.js.map +1 -1
  11. package/dist/generated/metadata.d.ts +1 -2
  12. package/dist/generated/metadata.d.ts.map +1 -1
  13. package/dist/generated/metadata.js +47 -1
  14. package/dist/generated/metadata.js.map +1 -1
  15. package/dist/generated/metadata.ts +48 -3
  16. package/dist/generated/openapi-stripped.json +772 -16
  17. package/dist/generated/path-mapping.d.ts.map +1 -1
  18. package/dist/generated/path-mapping.js +7 -4
  19. package/dist/generated/path-mapping.js.map +1 -1
  20. package/dist/generated/path-mapping.ts +8 -5
  21. package/dist/generated/person-id-sites.d.ts +2 -0
  22. package/dist/generated/person-id-sites.d.ts.map +1 -0
  23. package/dist/generated/person-id-sites.js +689 -0
  24. package/dist/generated/person-id-sites.js.map +1 -0
  25. package/dist/generated/person-id-sites.ts +690 -0
  26. package/dist/generated/schema.d.ts +643 -12
  27. package/dist/generated/services/event-feed.d.ts +92 -0
  28. package/dist/generated/services/event-feed.d.ts.map +1 -0
  29. package/dist/generated/services/event-feed.js +80 -0
  30. package/dist/generated/services/event-feed.js.map +1 -0
  31. package/dist/generated/services/event-feed.ts +153 -0
  32. package/dist/generated/services/gauges.d.ts +7 -3
  33. package/dist/generated/services/gauges.d.ts.map +1 -1
  34. package/dist/generated/services/gauges.js +4 -1
  35. package/dist/generated/services/gauges.js.map +1 -1
  36. package/dist/generated/services/gauges.ts +10 -3
  37. package/dist/generated/services/index.d.ts +1 -0
  38. package/dist/generated/services/index.d.ts.map +1 -1
  39. package/dist/generated/services/index.js +1 -0
  40. package/dist/generated/services/index.js.map +1 -1
  41. package/dist/generated/services/index.ts +1 -0
  42. package/dist/index.d.ts +6 -2
  43. package/dist/index.d.ts.map +1 -1
  44. package/dist/index.js +11 -3
  45. package/dist/index.js.map +1 -1
  46. package/dist/person-id.d.ts +133 -0
  47. package/dist/person-id.d.ts.map +1 -0
  48. package/dist/person-id.js +163 -0
  49. package/dist/person-id.js.map +1 -0
  50. package/dist/retry.d.ts +2 -1
  51. package/dist/retry.d.ts.map +1 -1
  52. package/dist/retry.js +21 -11
  53. package/dist/retry.js.map +1 -1
  54. package/dist/services/base.d.ts +35 -0
  55. package/dist/services/base.d.ts.map +1 -1
  56. package/dist/services/base.js +387 -55
  57. package/dist/services/base.js.map +1 -1
  58. package/dist/services/comments-extensions.d.ts +89 -0
  59. package/dist/services/comments-extensions.d.ts.map +1 -0
  60. package/dist/services/comments-extensions.js +166 -0
  61. package/dist/services/comments-extensions.js.map +1 -0
  62. package/dist/services/mentions.d.ts +255 -0
  63. package/dist/services/mentions.d.ts.map +1 -0
  64. package/dist/services/mentions.js +1431 -0
  65. package/dist/services/mentions.js.map +1 -0
  66. package/dist/services/merge-safe.d.ts +13 -5
  67. package/dist/services/merge-safe.d.ts.map +1 -1
  68. package/dist/services/merge-safe.js +71 -13
  69. package/dist/services/merge-safe.js.map +1 -1
  70. package/dist/services/recordings-extensions.d.ts +354 -0
  71. package/dist/services/recordings-extensions.d.ts.map +1 -0
  72. package/dist/services/recordings-extensions.js +1940 -0
  73. package/dist/services/recordings-extensions.js.map +1 -0
  74. package/package.json +4 -4
  75. package/src/generated/metadata.ts +48 -3
  76. package/src/generated/openapi-stripped.json +772 -16
  77. package/src/generated/path-mapping.ts +8 -5
  78. package/src/generated/person-id-sites.ts +690 -0
  79. package/src/generated/schema.d.ts +643 -12
  80. package/src/generated/services/event-feed.ts +153 -0
  81. package/src/generated/services/gauges.ts +10 -3
  82. package/src/generated/services/index.ts +1 -0
@@ -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The analogue of {@link writableString} for the ID-list fields. The `.map()`
152
152
  * it replaces (`(body[key] ?? []).map((p) => p.id)`) has three ways to go wrong
153
153
  * on malformed data: a non-array has no `.map` (a raw `TypeError`), a
154
- * non-object element yields `undefined`, and a non-integer `id` rides through
154
+ * non-object element yields `undefined`, and a wrong-typed `id` rides through
155
155
  * verbatim into the full-replace PUT — the same corruption as a wrong-typed
156
156
  * string, one level down.
157
157
  *
158
- * `Number.isInteger` is the test rather than `typeof === "number"`: `1.5` and
159
- * `NaN` are numbers and neither is a person ID. Booleans fail it outright,
160
- * which is what we want — JavaScript would happily coerce `true` to `1`
161
- * downstream.
158
+ * What it must NOT do is refuse an id the reference accepts. A person id is the
159
+ * one field the reference decodes flexibly (`Person.Id` is
160
+ * `types.FlexibleInt64`), and its projection appends what that produced with no
161
+ * filter, `0` included. So a STRING id is read by the shared `ParseInt` scan,
162
+ * an absent id is `0` and a `null` element is `0`; the per-branch comments
163
+ * below give the reasons.
164
+ *
165
+ * Two residuals are JavaScript's, not choices this could make differently: a
166
+ * number past 2^53 is refused (`Number.isSafeInteger`) rather than written as a
167
+ * rounded, different person's id, where the reference reads it; and a JSON
168
+ * number spelled `1024.0` or `1e3` is accepted, where the reference refuses it,
169
+ * because `JSON.parse` has already made it an integer.
162
170
  */
163
171
  export declare function writableIdList(body: Record<string, unknown>, key: string, opts: {
164
172
  record: string;
@@ -1 +1 @@
1
- {"version":3,"file":"merge-safe.d.ts","sourceRoot":"","sources":["../../src/services/merge-safe.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,OAAO,EAAgC,KAAK,aAAa,EAAE,MAAM,cAAc,CAAC;AAMhF;;;;;;;;;GASG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAQpD;AAED;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,aAAa,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;;GAeG;AACH,wBAAgB,uBAAuB,CACrC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,GAAG,EAAE,MAAM,EACX,IAAI,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GACvC,OAAO,CAgBT;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,GAAG,EAAE,MAAM,EACX,IAAI,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GACvC,OAAO,CAIT;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,cAAc,CAC5B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,GAAG,EAAE,MAAM,EACX,IAAI,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GACvC,MAAM,EAAE,CAwEV"}
@@ -31,6 +31,7 @@
31
31
  * intended end state for all of them.
32
32
  */
33
33
  import { Errors, truncateErrorMessage } from "../errors.js";
34
+ import { personIdNumber, scanPersonId } from "../person-id.js";
34
35
  const resendHint = (escape) => "The merge-safe update/edit resend this field verbatim, so a coerced or empty value " +
35
36
  `would overwrite the current one. Use ${escape} to write the record deliberately.`;
36
37
  /**
@@ -184,14 +185,22 @@ export function writableBoolean(body, key, opts) {
184
185
  * The analogue of {@link writableString} for the ID-list fields. The `.map()`
185
186
  * it replaces (`(body[key] ?? []).map((p) => p.id)`) has three ways to go wrong
186
187
  * on malformed data: a non-array has no `.map` (a raw `TypeError`), a
187
- * non-object element yields `undefined`, and a non-integer `id` rides through
188
+ * non-object element yields `undefined`, and a wrong-typed `id` rides through
188
189
  * verbatim into the full-replace PUT — the same corruption as a wrong-typed
189
190
  * string, one level down.
190
191
  *
191
- * `Number.isInteger` is the test rather than `typeof === "number"`: `1.5` and
192
- * `NaN` are numbers and neither is a person ID. Booleans fail it outright,
193
- * which is what we want — JavaScript would happily coerce `true` to `1`
194
- * downstream.
192
+ * What it must NOT do is refuse an id the reference accepts. A person id is the
193
+ * one field the reference decodes flexibly (`Person.Id` is
194
+ * `types.FlexibleInt64`), and its projection appends what that produced with no
195
+ * filter, `0` included. So a STRING id is read by the shared `ParseInt` scan,
196
+ * an absent id is `0` and a `null` element is `0`; the per-branch comments
197
+ * below give the reasons.
198
+ *
199
+ * Two residuals are JavaScript's, not choices this could make differently: a
200
+ * number past 2^53 is refused (`Number.isSafeInteger`) rather than written as a
201
+ * rounded, different person's id, where the reference reads it; and a JSON
202
+ * number spelled `1024.0` or `1e3` is accepted, where the reference refuses it,
203
+ * because `JSON.parse` has already made it an integer.
195
204
  */
196
205
  export function writableIdList(body, key, opts) {
197
206
  const value = body[key];
@@ -201,17 +210,66 @@ export function writableIdList(body, key, opts) {
201
210
  throw malformedResponse(`${opts.record} field "${key}" is not an array: ${describeValue(value)}`, resendHint(opts.escape));
202
211
  }
203
212
  return value.map((element, index) => {
204
- if (typeof element !== "object" || element === null || Array.isArray(element)) {
213
+ // A null element is 0, not a malformed one. The reference decodes a JSON
214
+ // null in this array into its zero `Person`, whose `Id` is 0, and
215
+ // `fieldsFromTodo` appends that like any other id — measured through the
216
+ // reference's own Update composite.
217
+ if (element === null)
218
+ return 0;
219
+ if (typeof element !== "object" || Array.isArray(element)) {
205
220
  throw malformedResponse(`${opts.record} field "${key}"[${index}] is not an object: ${describeValue(element)}`, resendHint(opts.escape));
206
221
  }
207
- const id = element["id"];
208
- if (id === undefined || id === null) {
209
- throw malformedResponse(`${opts.record} field "${key}"[${index}] has no "id"`, resendHint(opts.escape));
210
- }
211
- if (typeof id !== "number" || !Number.isInteger(id)) {
212
- throw malformedResponse(`${opts.record} field "${key}"[${index}].id is not an integer: ${describeValue(id)}`, resendHint(opts.escape));
222
+ const record = element;
223
+ // An ABSENT id is the zero value with no error, while an explicit null
224
+ // FAILS the read. The reference's flexible decoder is only called for a
225
+ // value that is there; for a JSON null it IS called, its number path leaves
226
+ // the buffer empty, and `ParseInt("")` fails. Two different answers, so the
227
+ // two cases cannot be tested together with `id == null`.
228
+ if (!("id" in record))
229
+ return 0;
230
+ const id = record["id"];
231
+ const refuse = () => {
232
+ throw malformedResponse(`${opts.record} field "${key}"[${index}].id is not a person id: ${describeValue(id)}`, resendHint(opts.escape));
233
+ };
234
+ // A NUMBER id. `Number.isInteger` is the test rather than `typeof`: `1.5`
235
+ // and `NaN` are numbers and neither is a person id, and a boolean fails it
236
+ // outright, which is what we want — JavaScript would coerce `true` to 1
237
+ // downstream. `Number.isSafeInteger` is the second half and is the same
238
+ // judgment `personIdNumber` makes for a string: past 2^53 `JSON.parse` has
239
+ // already rounded, so the only honest answers are "unreadable" or a wrong
240
+ // id, and the reference refuses this row anyway once it is past int64.
241
+ if (typeof id === "number")
242
+ return Number.isSafeInteger(id) ? id : refuse();
243
+ // A STRING id. BC3 serializes person ids as strings in some responses, and
244
+ // this reader must not lean on the pre-decode normalizer having converted
245
+ // one: which keys that walk covers is the walk's rule, and it is being held
246
+ // to the reference's own positional surfaces. The reference has no gap
247
+ // here either way, because it covers this site with a DECODER — `Person.Id`
248
+ // is `types.FlexibleInt64`, and `fieldsFromTodo` appends what that produced
249
+ // without filtering. Same grammar as the walk, so the two cannot disagree
250
+ // about a person depending on which of them saw it first.
251
+ if (typeof id === "string") {
252
+ const scan = scanPersonId(id);
253
+ // A SYNTAX refusal is the system actor, not an error: that is what the
254
+ // reference reads `"basecamp"` as, and the RANGE refusal beside it fails
255
+ // the read. Which one a string earns is decided inside the scan, so they
256
+ // cannot be told apart after the fact by looking at the string.
257
+ if (scan.kind === "syntax")
258
+ return 0;
259
+ if (scan.kind === "range")
260
+ return refuse();
261
+ // Outside ±(2^53 - 1) the number is already rounded, so refusing the ID
262
+ // is the local resolution `personIdNumber` documents — a residual
263
+ // divergence from a reference that answers in `int64`, recorded rather
264
+ // than papered over with a wrong id.
265
+ return personIdNumber(scan.value) ?? refuse();
213
266
  }
214
- return id;
267
+ // Everything else is a decode failure at the reference, an explicit
268
+ // `"id": null` included: the flexible decoder IS called for a JSON null,
269
+ // its number path leaves the buffer empty, and `ParseInt("")` fails. An
270
+ // absent key never reaches here, and is 0 — the two cannot be tested
271
+ // together with `id == null`.
272
+ return refuse();
215
273
  });
216
274
  }
217
275
  //# sourceMappingURL=merge-safe.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"merge-safe.js","sourceRoot":"","sources":["../../src/services/merge-safe.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,OAAO,EAAE,MAAM,EAAE,oBAAoB,EAAsB,MAAM,cAAc,CAAC;AAEhF,MAAM,UAAU,GAAG,CAAC,MAAc,EAAU,EAAE,CAC5C,qFAAqF;IACrF,wCAAwC,MAAM,oCAAoC,CAAC;AAErF;;;;;;;;;GASG;AACH,MAAM,UAAU,aAAa,CAAC,KAAc;IAC1C,MAAM,IAAI,GAAG,KAAK,KAAK,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,KAAK,CAAC;IACrF,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;QACvC,OAAO,QAAQ,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,IAAI,IAAI,oBAAoB,CAAC,QAAQ,CAAC,EAAE,CAAC;IACrF,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,iBAAiB,CAAC,OAAe,EAAE,IAAY;IAC7D,OAAO,MAAM,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ecordingsService.summarize` — a compact projection of one recording,
3
+ * resolved from the pointer an account event feed row or a webhook carries
4
+ * (bucket id, recording id, and the event type or recording type) through the
5
+ * typed read that type names.
6
+ *
7
+ * It exists for consumers that must decide something about a recording without
8
+ * paying for its full payload: an agent connector's admission step, an MCP tool
9
+ * answering "what is this?".
10
+ *
11
+ * The SDK has no untyped recording read (BC3 has no such route), so the type is
12
+ * the routing key: `comment.created` reads a comment, `card.created` reads a
13
+ * card, and so on — one typed read per type. Chat lines are the exception,
14
+ * because their read needs the Campfire id and the pointer does not carry it;
15
+ * `summarize` discovers the Campfire first (see {@link RecordingsService.summarize}
16
+ * and the discovery notes further down).
17
+ *
18
+ * This is hand-written composition over the generated services (SPEC §18,
19
+ * Appendix F). It makes no wire request of its own, and it mints no operation
20
+ * identity: hooks see the constituent reads under their own names (§18 rule 3).
21
+ * It lives in `src/services/*-extensions.ts` and is wired in `client.ts`, the
22
+ * placement §18 rule 5 designates for TypeScript.
23
+ */
24
+ import type { BasecampHooks } from "../hooks.js";
25
+ import { BasecampError } from "../errors.js";
26
+ import type { BasecampErrorOptions, ErrorCode } from "../errors.js";
27
+ import { RecordingsService as GeneratedRecordingsService } from "../generated/services/recordings.js";
28
+ import type { RawClient } from "./base.js";
29
+ import type { components } from "../generated/schema.js";
30
+ import type { Person } from "../generated/services/people.js";
31
+ import type { BasecampClient } from "../client.js";
32
+ /** The nested identities the projection carries verbatim from the read. */
33
+ type RecordingParent = components["schemas"]["RecordingParent"];
34
+ type RecordingBucket = components["schemas"]["RecordingBucket"];
35
+ /**
36
+ * The generated services `summarize` composes, as the client exposes them.
37
+ *
38
+ * Named rather than taken as the whole client so the composite's reach is
39
+ * stated: every one of these is a public generated wire method, which is what
40
+ * §18 rule 1 asks for.
41
+ */
42
+ export type RecordingReadSources = Pick<BasecampClient, "campfires" | "cardColumns" | "cards" | "cardSteps" | "cardTables" | "checkins" | "clientApprovals" | "clientCorrespondences" | "cloudFiles" | "comments" | "documents" | "forwards" | "googleDocuments" | "messageBoards" | "messages" | "projects" | "schedules" | "todolists" | "todos" | "todosets" | "uploads" | "vaults">;
43
+ /** Points at one recording the way an event feed row does. */
44
+ export interface RecordingRef {
45
+ /**
46
+ * The project the recording lives in. Required: it scopes the Campfire
47
+ * discovery for chat lines, and the read is checked against it so a pointer
48
+ * from one project can never resolve to a recording in another.
49
+ */
50
+ bucketId: number;
51
+ /** The recording's id. */
52
+ recordingId: number;
53
+ /**
54
+ * The account event feed type that named the recording —
55
+ * `"comment.created"`, `"card.assignment_changed"`, `"chat.line.created"`.
56
+ * The segment before the action names the recording type. Used when
57
+ * `recordingType` is absent.
58
+ */
59
+ eventType?: string;
60
+ /**
61
+ * The recording's own type as BC3 spells it — `"Comment"`, `"Kanban::Card"`,
62
+ * `"Chat::Lines::Text"`. When set it takes precedence over `eventType`, being
63
+ * the more exact of the two.
64
+ */
65
+ recordingType?: string;
66
+ }
67
+ /**
68
+ * The projection {@link RecordingsService.summarize} returns.
69
+ *
70
+ * Keys are the wire spelling, as everywhere else in this SDK: the generated
71
+ * types are the API's own snake_case shapes, and a camelCase projection here
72
+ * would be the one object in the surface that disagreed with them.
73
+ *
74
+ * Fields a type does not have are absent: a Comment has no `assignees`, a Vault
75
+ * no `content` worth the name.
76
+ */
77
+ export interface RecordingSummary {
78
+ id: number;
79
+ status: string;
80
+ /** The recording type as BC3 spells it (`"Comment"`, `"Kanban::Card"`). */
81
+ type: string;
82
+ title: string;
83
+ app_url: string;
84
+ /**
85
+ * The recording this one hangs off — the commented recording for a comment,
86
+ * the Campfire for a chat line, the column for a card.
87
+ */
88
+ parent?: RecordingParent;
89
+ bucket?: RecordingBucket;
90
+ creator?: Person;
91
+ /** Set for the assignable types (to-dos, cards, card steps). */
92
+ assignees?: Person[];
93
+ /**
94
+ * The people `content` mentions, per `mentionedPersonIds`. Never absent, so a
95
+ * JSON consumer reads `[]` rather than a missing key.
96
+ */
97
+ mentioned_person_ids: number[];
98
+ /**
99
+ * The mentions in `content` that name a real person this SDK cannot report as
100
+ * a number — a valid `int64` past `Number.MAX_SAFE_INTEGER`, as the decimal
101
+ * string it arrived as.
102
+ *
103
+ * ABSENT whenever there are none, which is every payload BC3 sends today, so
104
+ * a JSON consumer sees no new key until one actually appears. Present only
105
+ * when `mentioned_person_ids` is therefore short, which is what makes the
106
+ * skip visible: without it a text naming three people and a text naming two
107
+ * would read identically.
108
+ *
109
+ * These ids are skipped rather than thrown over on purpose. `content` is
110
+ * written by whoever wrote the comment and the sgid's signature is never
111
+ * verified, so refusing the read would hand any author a way to make the
112
+ * recording unreadable. Reported, not fatal, and untrusted either way.
113
+ */
114
+ unnameable_mention_ids?: string[];
115
+ /**
116
+ * The recording's rich text, in full: the comment body, the message body, a
117
+ * to-do's description, a card's content, the chat line.
118
+ */
119
+ content: string;
120
+ updated_at: string;
121
+ /**
122
+ * The Campfire a chat line was found under — the reply destination for a chat
123
+ * trigger. Absent for every other type.
124
+ */
125
+ campfire_id?: number;
126
+ }
127
+ /**
128
+ * The identities `summarize` fails with, beyond a read's own error.
129
+ *
130
+ * Matched on {@link RecordingSummaryError.kind}, never parsed out of a message:
131
+ * `recording_unresolved` in particular is a conclusion the composite reached,
132
+ * not a status any one request returned, and a consumer has to be able to tell
133
+ * it from a read that failed.
134
+ */
135
+ export type RecordingSummaryErrorKind =
136
+ /**
137
+ * The event type names no recording type — `boost.created`, whose recording
138
+ * is the boost's target and whose type the feed row does not carry. A
139
+ * consumer resolves those from its own record of what it posted, not through
140
+ * `summarize`.
141
+ */
142
+ "no_recording_type"
143
+ /** Neither `eventType` nor `recordingType` names a type in the routing table. */
144
+ | "unknown_recording_type"
145
+ /**
146
+ * A chat line was found under none of the Campfires the caller can currently
147
+ * see in its bucket. Distinct from a failed read (any non-404 answer is
148
+ * raised as itself) and from `campfire_discovery_incomplete`: every candidate
149
+ * answered 404. It is not distinct from lost visibility — BC3 answers 404 for
150
+ * a Campfire the caller may not see, too — so a consumer marks the record
151
+ * blocked and retries on its own schedule; see
152
+ * {@link UnresolvedRecordingError.staleCampfireIds}.
153
+ */
154
+ | "recording_unresolved"
155
+ /**
156
+ * Discovery could not be carried to a conclusion — the Campfire listing
157
+ * overflowed its cap, or a bucket has more visible Campfires than the
158
+ * candidate budget. Candidates were left unsearched, so nothing can be
159
+ * reported absent.
160
+ */
161
+ | "campfire_discovery_incomplete"
162
+ /** The recording the read returned lives in a different bucket from the pointer's. */
163
+ | "bucket_mismatch";
164
+ /**
165
+ * The base class for every failure that is the composite's own conclusion
166
+ * rather than one read's HTTP answer.
167
+ *
168
+ * It is a {@link BasecampError} so an existing `catch` keeps working, and it
169
+ * carries a `kind` so the conclusions stay distinguishable from each other and
170
+ * from the read errors whose `code` they share. Every one of them is
171
+ * **statusless**: no single request returned a status that describes the
172
+ * conclusion, so a consumer seeing `code: "not_found"` with no `httpStatus`
173
+ * knows it is looking at a composite's verdict and not at a 404 off the wire.
174
+ */
175
+ export declare class RecordingSummaryError extends BasecampError {
176
+ readonly kind: RecordingSummaryErrorKind;
177
+ constructor(kind: RecordingSummaryErrorKind, code: ErrorCode, message: string, options?: BasecampErrorOptions);
178
+ }
179
+ /**
180
+ * A {@link RecordingRef} `summarize` cannot route, raised before any request.
181
+ *
182
+ * `usage`: nothing was asked of the API — the pointer names no read.
183
+ */
184
+ export declare class RecordingRoutingError extends RecordingSummaryError {
185
+ readonly ref: RecordingRef;
186
+ constructor(ref: RecordingRef, kind: "no_recording_type" | "unknown_recording_type");
187
+ }
188
+ /** A chat line found under no visible Campfire. */
189
+ export declare class UnresolvedRecordingError extends RecordingSummaryError {
190
+ readonly bucketId: number;
191
+ readonly recordingId: number;
192
+ /** The candidates tried, in order; empty when the bucket has no visible Campfire at all. */
193
+ readonly campfireIds: number[];
194
+ /**
195
+ * Whether the cached discovery sources were re-read before concluding. False
196
+ * when every source had been read within the last
197
+ * {@link CAMPFIRE_INDEX_MIN_REFRESH_MS}, so a Campfire created in that window
198
+ * was not seen: the conclusion stands on data up to that old, and a retry
199
+ * after the floor sees the current sources.
200
+ */
201
+ readonly refreshed: boolean;
202
+ /**
203
+ * Candidates from the cache that the refreshed sources no longer list —
204
+ * Campfires the caller could see when the cache filled and cannot now. Set
205
+ * only when {@link refreshed}.
206
+ */
207
+ readonly staleCampfireIds: number[];
208
+ constructor(init: {
209
+ bucketId: number;
210
+ recordingId: number;
211
+ campfireIds: number[];
212
+ refreshed: boolean;
213
+ staleCampfireIds: number[];
214
+ });
215
+ }
216
+ /**
217
+ * Discovery stopped short of a conclusion, and why.
218
+ *
219
+ * `usage`, non-retryable, settled across every port on
220
+ * {@link https://app.basecamp.com/2914079/buckets/48699913/card_tables/cards/10308122086 | card 40}
221
+ * after the merged ports shipped two different answers — this one and Python
222
+ * said `api_error`, Kotlin said `usage`, and a caller got exit 7 from one SDK
223
+ * and exit 1 from another for the same condition.
224
+ *
225
+ * `usage` is one of only THREE coarse codes no HTTP response can produce: the
226
+ * status mapping yields `auth_required`, `forbidden`, `not_found`,
227
+ * `rate_limit`, `validation`, `limit_exceeded` and `api_error`, and `network`
228
+ * and `ambiguous` are equally unreachable from a status. `usage` is the one of
229
+ * those three that also describes a call the SDK declined to complete, which is
230
+ * why it and not the other two. A verdict the composite reached on its own
231
+ * therefore can never be read back as a constituent read's own answer — the
232
+ * property the composite exists to protect. It is
233
+ * explicitly not `not_found`, because nothing left unsearched may be reported
234
+ * absent.
235
+ *
236
+ * Retryability is a separate field and is unchanged: {@link
237
+ * RecordingSummaryError} forces `retryable: false` on every identity, and both
238
+ * of this one's reasons are deterministic for the same account state, so a
239
+ * retry loop would re-run the identical search forever.
240
+ */
241
+ export declare class CampfireDiscoveryIncompleteError extends RecordingSummaryError {
242
+ readonly bucketId: number;
243
+ readonly recordingId: number;
244
+ readonly reason: string;
245
+ constructor(init: {
246
+ bucketId: number;
247
+ recordingId: number;
248
+ reason: string;
249
+ });
250
+ }
251
+ /**
252
+ * A read whose bucket disagrees with the pointer.
253
+ *
254
+ * `usage`: the pointer named a bucket the recording is not in, which is the
255
+ * caller's argument being wrong rather than the API misbehaving. This doc
256
+ * comment argued the opposite — `api_error`, citing SPEC §6's statusless rule —
257
+ * for as long as the code said so, and went on saying it after the code
258
+ * changed, which is the half of a rename that editor hover and generated API
259
+ * docs actually show a consumer.
260
+ *
261
+ * The ports on `main` did NOT agree here, and the disagreement was bigger than
262
+ * the value: `exitCode` derives from the code, so this identity exited 1 in
263
+ * Python, Ruby, Kotlin and this port (`usage`) and 2 in Rust (`not_found`, "the
264
+ * recording the pointer names is not where it was looked for"). Settled for
265
+ * every SDK on {@link https://app.basecamp.com/2914079/buckets/48699913/card_tables/cards/10308966794 | card 41} as `usage`, and on the
266
+ * argument rather than the four-to-one majority: `not_found` says the recording
267
+ * is not there, which is false — the read FOUND it, in another bucket, and
268
+ * returned it. Nothing is absent. What failed is the caller's pointer.
269
+ *
270
+ * The shared fixture had no case for this identity at all, so nothing pinned
271
+ * the code: five ports carried two answers and two carried none, with every
272
+ * case green in all seven. It has one now, and it pins the code alongside the
273
+ * identity.
274
+ */
275
+ export declare class BucketMismatchError extends RecordingSummaryError {
276
+ readonly ref: RecordingRef;
277
+ /** The bucket the read returned. */
278
+ readonly bucketId: number;
279
+ constructor(ref: RecordingRef, bucketId: number);
280
+ }
281
+ /**
282
+ * The recording types `summarize` routes by `recordingType`, sorted, with the
283
+ * `Chat::Lines` subtypes represented by their shared prefix
284
+ * (`"Chat::Lines::*"`). The set is deliberate rather than exhaustive — see
285
+ * {@link RECORDING_TYPES} — and any other type is `unknown_recording_type` by
286
+ * design.
287
+ */
288
+ export declare function summarizableRecordingTypes(): string[];
289
+ /**
290
+ * The account event feed subjects `summarize` routes by `eventType` — an event
291
+ * type is `<subject>.<action>`, and any action on a listed subject routes to
292
+ * that subject's read — sorted. `boost` is absent on purpose: it is
293
+ * `no_recording_type`.
294
+ */
295
+ export declare function summarizableEventTypes(): string[];
296
+ /**
297
+ * How long a cached discovery source — a bucket's project dock, the account's
298
+ * Campfire listing — is reused before it is read again.
299
+ */
300
+ export declare const CAMPFIRE_INDEX_TTL_MS: number;
301
+ /**
302
+ * Bounds how many Campfires one `summarize` call tries, across both sources and
303
+ * the refresh. A project has one Campfire and a handful of pings; a bucket past
304
+ * this bound is not a shape BC3 produces, and the call reports
305
+ * `campfire_discovery_incomplete` rather than calling the rest absent.
306
+ */
307
+ export declare const MAX_CAMPFIRE_CANDIDATES = 50;
308
+ /**
309
+ * Caps the account-wide Campfire listing the fallback source reads. A listing
310
+ * that overflows it is not cached and the call reports
311
+ * `campfire_discovery_incomplete`: the dock covers every project, so the
312
+ * listing only ever serves the leftover, and an account with more Campfires
313
+ * than this should not pay a full walk per ten minutes for it.
314
+ */
315
+ export declare const MAX_CAMPFIRE_LISTING = 1000;
316
+ /**
317
+ * `RecordingsService` with the hand-written `summarize` composite on top of the
318
+ * generated surface (`list`, `trash`, ...).
319
+ *
320
+ * The composite reaches its sibling reads through the client that built it, so
321
+ * every request is the same public generated method a caller would have made
322
+ * and hooks see each under its own operation identity.
323
+ */
324
+ export declare class RecordingsService extends GeneratedRecordingsService {
325
+ #private;
326
+ constructor(client: RawClient, hooks?: BasecampHooks, fetchPage?: (url: string) => Promise<Response>, maxPages?: number, authenticatedFetch?: (url: string, init: RequestInit) => Promise<Response>, baseUrl?: string, sources?: () => RecordingReadSources, now?: () => number);
327
+ /**
328
+ * Resolves a recording pointer into a {@link RecordingSummary} through the
329
+ * typed read its type names. See {@link RecordingRef} for the routing inputs.
330
+ *
331
+ * Errors: a routing failure (`no_recording_type` / `unknown_recording_type`)
332
+ * before any request; the read's own {@link BasecampError} otherwise — a 404
333
+ * is `not_found`, as from the typed read itself; for chat lines,
334
+ * {@link UnresolvedRecordingError} when every visible Campfire answered 404,
335
+ * which is distinct from a read that failed (any non-404 from a candidate is
336
+ * raised as that error, and the loop stops there) and from
337
+ * {@link CampfireDiscoveryIncompleteError} (candidates were left unsearched);
338
+ * {@link BucketMismatchError} when the read returned a recording from another
339
+ * bucket.
340
+ *
341
+ * @example
342
+ * ```ts
343
+ * const summary = await client.recordings.summarize({
344
+ * bucketId: 2085958499,
345
+ * recordingId: 1069479361,
346
+ * eventType: "comment.created",
347
+ * });
348
+ * summary.mentioned_person_ids; // [1049715915]
349
+ * ```
350
+ */
351
+ summarize(ref: RecordingRef): Promise<RecordingSummary>;
352
+ }
353
+ export {};
354
+ //# sourceMappingURL=recordings-extensions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"recordings-extensions.d.ts","sourceRoot":"","sources":["../../src/services/recordings-extensions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,aAAa,EAAiD,MAAM,cAAc,CAAC;AAC5F,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,EAAE,iBAAiB,IAAI,0BAA0B,EAAE,MAAM,qCAAqC,CAAC;AACtG,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAC3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AAE9D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAyBnD,2EAA2E;AAC3E,KAAK,eAAe,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;AAChE,KAAK,eAAe,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;AAEhE;;;;;;GAMG;AACH,MAAM,MAAM,oBAAoB,GAAG,IAAI,CACrC,cAAc,EACZ,WAAW,GACX,aAAa,GACb,OAAO,GACP,WAAW,GACX,YAAY,GACZ,UAAU,GACV,iBAAiB,GACjB,uBAAuB,GACvB,YAAY,GACZ,UAAU,GACV,WAAW,GACX,UAAU,GACV,iBAAiB,GACjB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