@tellescope/sdk 1.256.2 → 1.256.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.
Files changed (67) hide show
  1. package/lib/cjs/tests/api_tests/metriport_push_form_response.test.d.ts +6 -0
  2. package/lib/cjs/tests/api_tests/metriport_push_form_response.test.d.ts.map +1 -0
  3. package/lib/cjs/tests/api_tests/metriport_push_form_response.test.js +298 -0
  4. package/lib/cjs/tests/api_tests/metriport_push_form_response.test.js.map +1 -0
  5. package/lib/cjs/tests/api_tests/phone_calls_move_enduser.test.d.ts +6 -0
  6. package/lib/cjs/tests/api_tests/phone_calls_move_enduser.test.d.ts.map +1 -0
  7. package/lib/cjs/tests/api_tests/phone_calls_move_enduser.test.js +274 -0
  8. package/lib/cjs/tests/api_tests/phone_calls_move_enduser.test.js.map +1 -0
  9. package/lib/cjs/tests/api_tests/stripe_webhook_triggers.test.d.ts +18 -0
  10. package/lib/cjs/tests/api_tests/stripe_webhook_triggers.test.d.ts.map +1 -0
  11. package/lib/cjs/tests/api_tests/stripe_webhook_triggers.test.js +964 -0
  12. package/lib/cjs/tests/api_tests/stripe_webhook_triggers.test.js.map +1 -0
  13. package/lib/cjs/tests/api_tests/welle_partner_token.test.d.ts +6 -0
  14. package/lib/cjs/tests/api_tests/welle_partner_token.test.d.ts.map +1 -0
  15. package/lib/cjs/tests/api_tests/welle_partner_token.test.js +313 -0
  16. package/lib/cjs/tests/api_tests/welle_partner_token.test.js.map +1 -0
  17. package/lib/cjs/tests/stripe_webhook_helpers.d.ts +204 -0
  18. package/lib/cjs/tests/stripe_webhook_helpers.d.ts.map +1 -0
  19. package/lib/cjs/tests/stripe_webhook_helpers.js +286 -0
  20. package/lib/cjs/tests/stripe_webhook_helpers.js.map +1 -0
  21. package/lib/cjs/tests/tests.d.ts.map +1 -1
  22. package/lib/cjs/tests/tests.js +192 -180
  23. package/lib/cjs/tests/tests.js.map +1 -1
  24. package/lib/cjs/tests/unit_tests/translation.test.d.ts +3 -0
  25. package/lib/cjs/tests/unit_tests/translation.test.d.ts.map +1 -0
  26. package/lib/cjs/tests/unit_tests/translation.test.js.map +1 -0
  27. package/lib/esm/enduser.d.ts +1 -0
  28. package/lib/esm/enduser.d.ts.map +1 -1
  29. package/lib/esm/sdk.d.ts +3 -2
  30. package/lib/esm/sdk.d.ts.map +1 -1
  31. package/lib/esm/session.d.ts +1 -0
  32. package/lib/esm/session.d.ts.map +1 -1
  33. package/lib/esm/tests/api_tests/metriport_push_form_response.test.d.ts +6 -0
  34. package/lib/esm/tests/api_tests/metriport_push_form_response.test.d.ts.map +1 -0
  35. package/lib/esm/tests/api_tests/metriport_push_form_response.test.js +294 -0
  36. package/lib/esm/tests/api_tests/metriport_push_form_response.test.js.map +1 -0
  37. package/lib/esm/tests/api_tests/phone_calls_move_enduser.test.d.ts +6 -0
  38. package/lib/esm/tests/api_tests/phone_calls_move_enduser.test.d.ts.map +1 -0
  39. package/lib/esm/tests/api_tests/phone_calls_move_enduser.test.js +270 -0
  40. package/lib/esm/tests/api_tests/phone_calls_move_enduser.test.js.map +1 -0
  41. package/lib/esm/tests/api_tests/stripe_webhook_triggers.test.d.ts +18 -0
  42. package/lib/esm/tests/api_tests/stripe_webhook_triggers.test.d.ts.map +1 -0
  43. package/lib/esm/tests/api_tests/stripe_webhook_triggers.test.js +960 -0
  44. package/lib/esm/tests/api_tests/stripe_webhook_triggers.test.js.map +1 -0
  45. package/lib/esm/tests/api_tests/welle_partner_token.test.d.ts +6 -0
  46. package/lib/esm/tests/api_tests/welle_partner_token.test.d.ts.map +1 -0
  47. package/lib/esm/tests/api_tests/welle_partner_token.test.js +309 -0
  48. package/lib/esm/tests/api_tests/welle_partner_token.test.js.map +1 -0
  49. package/lib/esm/tests/stripe_webhook_helpers.d.ts +204 -0
  50. package/lib/esm/tests/stripe_webhook_helpers.d.ts.map +1 -0
  51. package/lib/esm/tests/stripe_webhook_helpers.js +267 -0
  52. package/lib/esm/tests/stripe_webhook_helpers.js.map +1 -0
  53. package/lib/esm/tests/tests.d.ts.map +1 -1
  54. package/lib/esm/tests/tests.js +192 -180
  55. package/lib/esm/tests/tests.js.map +1 -1
  56. package/lib/esm/tests/unit_tests/translation.test.d.ts +3 -0
  57. package/lib/esm/tests/unit_tests/translation.test.d.ts.map +1 -0
  58. package/lib/esm/tests/unit_tests/translation.test.js +52 -0
  59. package/lib/esm/tests/unit_tests/translation.test.js.map +1 -0
  60. package/lib/tsconfig.tsbuildinfo +1 -1
  61. package/package.json +10 -10
  62. package/src/tests/api_tests/metriport_push_form_response.test.ts +226 -0
  63. package/src/tests/api_tests/stripe_webhook_triggers.test.ts +676 -0
  64. package/src/tests/api_tests/welle_partner_token.test.ts +249 -0
  65. package/src/tests/stripe_webhook_helpers.ts +240 -0
  66. package/src/tests/tests.ts +6 -0
  67. package/test_generated.pdf +0 -0
@@ -0,0 +1,267 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ var __generator = (this && this.__generator) || function (thisArg, body) {
11
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
12
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ function verb(n) { return function (v) { return step([n, v]); }; }
14
+ function step(op) {
15
+ if (f) throw new TypeError("Generator is already executing.");
16
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
17
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
18
+ if (y = 0, t) op = [op[0] & 2, t.value];
19
+ switch (op[0]) {
20
+ case 0: case 1: t = op; break;
21
+ case 4: _.label++; return { value: op[1], done: false };
22
+ case 5: _.label++; y = op[1]; op = [0]; continue;
23
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
24
+ default:
25
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
26
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
27
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
28
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
29
+ if (t[2]) _.ops.pop();
30
+ _.trys.pop(); continue;
31
+ }
32
+ op = body.call(thisArg, _);
33
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
34
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
35
+ }
36
+ };
37
+ import crypto from "crypto";
38
+ var host = process.env.API_URL || 'http://localhost:8080';
39
+ // Marks the throwaway integrations created by tests so a run can clear residue left by an earlier
40
+ // run that exited early. The test harness calls process.exit(1) on the first failed assertion, which
41
+ // skips finally blocks, so cleanup cannot be relied on.
42
+ export var TEST_STRIPE_ENVIRONMENT = 'tellescope-test-stripe-webhooks';
43
+ // title must be exactly STRIPE_TITLE for the webhook handler to find the integration
44
+ var STRIPE_TITLE = 'Stripe';
45
+ var uniqueCounter = 0;
46
+ var unique_suffix = function () { return "".concat(Date.now(), "_").concat(uniqueCounter++); };
47
+ /**
48
+ * Stripe signs `${timestamp}.${rawBody}` with HMAC-SHA256 and sends it hex-encoded in a
49
+ * `t=<unixSeconds>,v1=<hex>` header. Reproducing it here lets tests exercise the real webhook
50
+ * route — signature verification included — without Stripe or network access.
51
+ *
52
+ * The default timestamp is always in tolerance (Stripe allows 300s and only rejects old ones);
53
+ * pass an old timestamp explicitly to test rejection.
54
+ */
55
+ export var sign_stripe_payload = function (rawBody, secret, timestamp) {
56
+ if (timestamp === void 0) { timestamp = Math.floor(Date.now() / 1000); }
57
+ return ("t=".concat(timestamp, ",v1=").concat(crypto.createHmac('sha256', secret).update("".concat(timestamp, ".").concat(rawBody), 'utf8').digest('hex')));
58
+ };
59
+ /**
60
+ * POSTs an event to the custom Stripe webhook route.
61
+ *
62
+ * Serializes the body here and signs those exact bytes, because the route uses
63
+ * express.raw and the signature covers the raw body verbatim — handing a pre-serialized
64
+ * string to fetch is what keeps the two in sync.
65
+ *
66
+ * Pass `signature` to override the computed one (for rejection tests).
67
+ */
68
+ export var post_stripe_webhook = function (_a) {
69
+ var stripePublicKey = _a.stripePublicKey, event = _a.event, secret = _a.secret, signature = _a.signature;
70
+ return __awaiter(void 0, void 0, void 0, function () {
71
+ var rawBody, res;
72
+ var _b;
73
+ return __generator(this, function (_c) {
74
+ switch (_c.label) {
75
+ case 0:
76
+ rawBody = JSON.stringify(event);
77
+ return [4 /*yield*/, fetch("".concat(host, "/v1/webhooks/stripe/custom/").concat(stripePublicKey), {
78
+ method: 'POST',
79
+ headers: {
80
+ // express.raw({ type: 'application/json' }) leaves req.body unset without this
81
+ 'Content-Type': 'application/json',
82
+ 'stripe-signature': signature !== null && signature !== void 0 ? signature : sign_stripe_payload(rawBody, secret),
83
+ },
84
+ body: rawBody,
85
+ })];
86
+ case 1:
87
+ res = _c.sent();
88
+ _b = { status: res.status };
89
+ return [4 /*yield*/, res.text()];
90
+ case 2: return [2 /*return*/, (_b.data = _c.sent(), _b)];
91
+ }
92
+ });
93
+ });
94
+ };
95
+ /**
96
+ * Creates a throwaway custom Stripe integration and returns the values needed to sign webhooks for
97
+ * it, plus a cleanup function to call in a finally block.
98
+ *
99
+ * The access token is never used: neither invoice.payment_failed nor customer.subscription.deleted
100
+ * calls the Stripe API, and constructing a Stripe client doesn't validate the key or hit the network.
101
+ */
102
+ export var setup_stripe_test_integration = function (sdk) { return __awaiter(void 0, void 0, void 0, function () {
103
+ var stripePublicKey, webhooksSecret, integration;
104
+ return __generator(this, function (_a) {
105
+ switch (_a.label) {
106
+ case 0:
107
+ stripePublicKey = "pk_test_tellescope_".concat(unique_suffix());
108
+ webhooksSecret = "whsec_test_".concat(crypto.randomBytes(16).toString('hex'));
109
+ return [4 /*yield*/, cleanup_stripe_test_integrations(sdk)];
110
+ case 1:
111
+ _a.sent();
112
+ return [4 /*yield*/, sdk.api.integrations.createOne({
113
+ title: STRIPE_TITLE,
114
+ environment: TEST_STRIPE_ENVIRONMENT,
115
+ authentication: {
116
+ type: 'apiKey',
117
+ info: {
118
+ // all of these are required by integrationAuthenticationsValidator, and only
119
+ // external_id (the public key in the webhook URL) is actually read by the handler
120
+ access_token: 'sk_test_unused_by_this_path',
121
+ refresh_token: 'unused',
122
+ scope: '',
123
+ expiry_date: Date.now(),
124
+ token_type: 'Bearer',
125
+ external_id: stripePublicKey,
126
+ },
127
+ },
128
+ // never readable afterwards (redactions: ['all']), so the caller must keep the returned value
129
+ webhooksSecret: webhooksSecret,
130
+ })];
131
+ case 2:
132
+ integration = _a.sent();
133
+ return [2 /*return*/, {
134
+ stripePublicKey: stripePublicKey,
135
+ webhooksSecret: webhooksSecret,
136
+ integrationId: integration.id,
137
+ cleanup: function () { return sdk.api.integrations.deleteOne(integration.id); },
138
+ }];
139
+ }
140
+ });
141
+ }); };
142
+ /** Deletes any test Stripe integrations left behind by a run that exited before its cleanup. */
143
+ export var cleanup_stripe_test_integrations = function (sdk) { return __awaiter(void 0, void 0, void 0, function () {
144
+ var existing;
145
+ return __generator(this, function (_a) {
146
+ switch (_a.label) {
147
+ case 0: return [4 /*yield*/, sdk.api.integrations.getSome({ filter: { title: STRIPE_TITLE } })
148
+ .catch(function () { return []; })];
149
+ case 1:
150
+ existing = _a.sent();
151
+ return [4 /*yield*/, Promise.all(existing
152
+ .filter(function (i) { return i.environment === TEST_STRIPE_ENVIRONMENT; })
153
+ .map(function (i) { return sdk.api.integrations.deleteOne(i.id).catch(console.error); }))];
154
+ case 2:
155
+ _a.sent();
156
+ return [2 /*return*/];
157
+ }
158
+ });
159
+ }); };
160
+ /* ------------------------------- event fixtures ------------------------------- */
161
+ // An invoice line item references its product through price.product on every modern line item, and
162
+ // through plan.product only on subscription/proration lines. Either may be a bare id or an expanded
163
+ // object, so each shape gets a builder.
164
+ export var line_with_price_product = function (stripeProductId) { return ({
165
+ price: { product: stripeProductId },
166
+ }); };
167
+ export var line_with_expanded_price_product = function (stripeProductId) { return ({
168
+ price: { product: { id: stripeProductId, object: 'product' } },
169
+ }); };
170
+ export var line_with_plan_product = function (stripeProductId) { return ({
171
+ price: null,
172
+ plan: { product: stripeProductId },
173
+ }); };
174
+ /**
175
+ * Minimal invoice.payment_failed envelope. constructEvent only requires valid JSON — it does not
176
+ * validate id/object/api_version — so this carries just the fields the handler reads.
177
+ */
178
+ export var invoice_payment_failed_event = function (_a) {
179
+ var stripeCustomerId = _a.stripeCustomerId, _b = _a.lines, lines = _b === void 0 ? [] : _b, _c = _a.has_more, has_more = _c === void 0 ? false : _c;
180
+ return ({
181
+ type: 'invoice.payment_failed',
182
+ data: {
183
+ object: {
184
+ id: "in_test_".concat(unique_suffix()),
185
+ customer: stripeCustomerId,
186
+ lines: { object: 'list', data: lines, has_more: has_more },
187
+ },
188
+ },
189
+ });
190
+ };
191
+ /** Minimal customer.subscription.deleted envelope; the handler reads items.data[].plan.product. */
192
+ export var subscription_deleted_event = function (_a) {
193
+ var stripeCustomerId = _a.stripeCustomerId, _b = _a.stripeProductIds, stripeProductIds = _b === void 0 ? [] : _b;
194
+ return ({
195
+ type: 'customer.subscription.deleted',
196
+ data: {
197
+ object: {
198
+ id: "sub_test_".concat(unique_suffix()),
199
+ customer: stripeCustomerId,
200
+ items: {
201
+ object: 'list',
202
+ data: stripeProductIds.map(function (product) { return ({ plan: { product: product } }); }),
203
+ },
204
+ },
205
+ },
206
+ });
207
+ };
208
+ /**
209
+ * A subscription item references its product through price.product on every modern item, and through
210
+ * plan.product on legacy ones. Either may be a bare id or an expanded object.
211
+ */
212
+ export var item_with_price_product = function (stripeProductId) { return ({
213
+ price: { product: stripeProductId },
214
+ }); };
215
+ export var item_with_expanded_price_product = function (stripeProductId) { return ({
216
+ price: { product: { id: stripeProductId, object: 'product' } },
217
+ }); };
218
+ export var item_with_plan_product = function (stripeProductId) { return ({
219
+ price: null,
220
+ plan: { product: stripeProductId },
221
+ }); };
222
+ /** A pause_collection value, as Stripe carries it on a paused-collection subscription. */
223
+ export var PAUSE_COLLECTION = { behavior: 'void', resumes_at: null };
224
+ /**
225
+ * customer.subscription.updated envelope. `previousAttributes` is the whole previous_attributes bag,
226
+ * so a case can express "pause_collection key absent" (pass {}) distinctly from
227
+ * "pause_collection was null" (pass { pause_collection: null }) — that distinction is the entire
228
+ * gate the handler uses to avoid running on every renewal.
229
+ */
230
+ export var subscription_updated_event = function (_a) {
231
+ var stripeCustomerId = _a.stripeCustomerId, _b = _a.items, items = _b === void 0 ? [] : _b, _c = _a.previousAttributes, previousAttributes = _c === void 0 ? {} : _c, _d = _a.pauseCollection, pauseCollection = _d === void 0 ? null : _d, _e = _a.status, status = _e === void 0 ? 'active' : _e;
232
+ return ({
233
+ type: 'customer.subscription.updated',
234
+ data: {
235
+ object: {
236
+ id: "sub_test_".concat(unique_suffix()),
237
+ customer: stripeCustomerId,
238
+ status: status,
239
+ pause_collection: pauseCollection,
240
+ items: { object: 'list', data: items, has_more: false },
241
+ },
242
+ previous_attributes: previousAttributes,
243
+ },
244
+ });
245
+ };
246
+ /**
247
+ * The dedicated customer.subscription.paused / .resumed events, which Stripe emits only for
248
+ * status='paused' transitions. The handler fires unconditionally on these, so no previous_attributes.
249
+ */
250
+ var subscription_pause_event = function (type) { return function (_a) {
251
+ var stripeCustomerId = _a.stripeCustomerId, _b = _a.items, items = _b === void 0 ? [] : _b, status = _a.status;
252
+ return ({
253
+ type: type,
254
+ data: {
255
+ object: {
256
+ id: "sub_test_".concat(unique_suffix()),
257
+ customer: stripeCustomerId,
258
+ status: status !== null && status !== void 0 ? status : (type === 'customer.subscription.paused' ? 'paused' : 'active'),
259
+ pause_collection: null,
260
+ items: { object: 'list', data: items, has_more: false },
261
+ },
262
+ },
263
+ });
264
+ }; };
265
+ export var subscription_paused_event = subscription_pause_event('customer.subscription.paused');
266
+ export var subscription_resumed_event = subscription_pause_event('customer.subscription.resumed');
267
+ //# sourceMappingURL=stripe_webhook_helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stripe_webhook_helpers.js","sourceRoot":"","sources":["../../../src/tests/stripe_webhook_helpers.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,MAAM,MAAM,QAAQ,CAAA;AAI3B,IAAM,IAAI,GAAG,OAAO,CAAC,GAAG,CAAC,OAAO,IAAI,uBAAuB,CAAA;AAE3D,kGAAkG;AAClG,qGAAqG;AACrG,wDAAwD;AACxD,MAAM,CAAC,IAAM,uBAAuB,GAAG,iCAAiC,CAAA;AAExE,qFAAqF;AACrF,IAAM,YAAY,GAAG,QAAQ,CAAA;AAE7B,IAAI,aAAa,GAAG,CAAC,CAAA;AACrB,IAAM,aAAa,GAAG,cAAM,OAAA,UAAG,IAAI,CAAC,GAAG,EAAE,cAAI,aAAa,EAAE,CAAE,EAAlC,CAAkC,CAAA;AAE9D;;;;;;;GAOG;AACH,MAAM,CAAC,IAAM,mBAAmB,GAAG,UACjC,OAAe,EACf,MAAc,EACd,SAAyC;IAAzC,0BAAA,EAAA,YAAY,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC;IACtC,OAAA,CACH,YAAK,SAAS,iBAAO,MAAM,CAAC,UAAU,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC,MAAM,CAAC,UAAG,SAAS,cAAI,OAAO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