@mobilerun/sdk 5.4.0 → 5.6.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.
- package/CHANGELOG.md +17 -0
- package/client.d.mts +10 -13
- package/client.d.mts.map +1 -1
- package/client.d.ts +10 -13
- package/client.d.ts.map +1 -1
- package/client.js +1 -3
- package/client.js.map +1 -1
- package/client.mjs +2 -4
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/apps.d.mts +23 -12
- package/resources/apps.d.mts.map +1 -1
- package/resources/apps.d.ts +23 -12
- package/resources/apps.d.ts.map +1 -1
- package/resources/apps.js +8 -3
- package/resources/apps.js.map +1 -1
- package/resources/apps.mjs +8 -3
- package/resources/apps.mjs.map +1 -1
- package/resources/assistant/conversations.d.mts +33 -21
- package/resources/assistant/conversations.d.mts.map +1 -1
- package/resources/assistant/conversations.d.ts +33 -21
- package/resources/assistant/conversations.d.ts.map +1 -1
- package/resources/assistant/conversations.js +16 -15
- package/resources/assistant/conversations.js.map +1 -1
- package/resources/assistant/conversations.mjs +16 -15
- package/resources/assistant/conversations.mjs.map +1 -1
- package/resources/connect/connect.d.mts +2 -2
- package/resources/connect/connect.d.mts.map +1 -1
- package/resources/connect/connect.d.ts +2 -2
- package/resources/connect/connect.d.ts.map +1 -1
- package/resources/connect/connect.js.map +1 -1
- package/resources/connect/connect.mjs.map +1 -1
- package/resources/connect/index.d.mts +1 -1
- package/resources/connect/index.d.mts.map +1 -1
- package/resources/connect/index.d.ts +1 -1
- package/resources/connect/index.d.ts.map +1 -1
- package/resources/connect/index.js.map +1 -1
- package/resources/connect/index.mjs.map +1 -1
- package/resources/connect/proxies.d.mts +118 -19
- package/resources/connect/proxies.d.mts.map +1 -1
- package/resources/connect/proxies.d.ts +118 -19
- package/resources/connect/proxies.d.ts.map +1 -1
- package/resources/connect/proxies.js +19 -0
- package/resources/connect/proxies.js.map +1 -1
- package/resources/connect/proxies.mjs +19 -0
- package/resources/connect/proxies.mjs.map +1 -1
- package/resources/devices/apps.d.mts +37 -17
- package/resources/devices/apps.d.mts.map +1 -1
- package/resources/devices/apps.d.ts +37 -17
- package/resources/devices/apps.d.ts.map +1 -1
- package/resources/devices/apps.js +15 -14
- package/resources/devices/apps.js.map +1 -1
- package/resources/devices/apps.mjs +15 -14
- package/resources/devices/apps.mjs.map +1 -1
- package/resources/devices/browser.d.mts +9 -3
- package/resources/devices/browser.d.mts.map +1 -1
- package/resources/devices/browser.d.ts +9 -3
- package/resources/devices/browser.d.ts.map +1 -1
- package/resources/devices/browser.js +9 -3
- package/resources/devices/browser.js.map +1 -1
- package/resources/devices/browser.mjs +9 -3
- package/resources/devices/browser.mjs.map +1 -1
- package/resources/devices/devices.d.mts +81 -27
- package/resources/devices/devices.d.mts.map +1 -1
- package/resources/devices/devices.d.ts +81 -27
- package/resources/devices/devices.d.ts.map +1 -1
- package/resources/devices/devices.js +24 -11
- package/resources/devices/devices.js.map +1 -1
- package/resources/devices/devices.mjs +24 -11
- package/resources/devices/devices.mjs.map +1 -1
- package/resources/devices/index.d.mts +2 -1
- package/resources/devices/index.d.mts.map +1 -1
- package/resources/devices/index.d.ts +2 -1
- package/resources/devices/index.d.ts.map +1 -1
- package/resources/devices/index.js +3 -1
- package/resources/devices/index.js.map +1 -1
- package/resources/devices/index.mjs +1 -0
- package/resources/devices/index.mjs.map +1 -1
- package/resources/devices/keyboard.d.mts +9 -3
- package/resources/devices/keyboard.d.mts.map +1 -1
- package/resources/devices/keyboard.d.ts +9 -3
- package/resources/devices/keyboard.d.ts.map +1 -1
- package/resources/devices/keyboard.js +3 -3
- package/resources/devices/keyboard.mjs +3 -3
- package/resources/devices/recordings.d.mts +13 -0
- package/resources/devices/recordings.d.mts.map +1 -1
- package/resources/devices/recordings.d.ts +13 -0
- package/resources/devices/recordings.d.ts.map +1 -1
- package/resources/devices/traffic-sessions.d.mts +163 -0
- package/resources/devices/traffic-sessions.d.mts.map +1 -0
- package/resources/devices/traffic-sessions.d.ts +163 -0
- package/resources/devices/traffic-sessions.d.ts.map +1 -0
- package/resources/devices/traffic-sessions.js +37 -0
- package/resources/devices/traffic-sessions.js.map +1 -0
- package/resources/devices/traffic-sessions.mjs +33 -0
- package/resources/devices/traffic-sessions.mjs.map +1 -0
- package/resources/files.d.mts +77 -19
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +77 -19
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +2 -10
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +2 -10
- package/resources/files.mjs.map +1 -1
- package/resources/index.d.mts +5 -6
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +5 -6
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +1 -3
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -2
- package/resources/index.mjs.map +1 -1
- package/resources/mailboxes/connections.d.mts +64 -0
- package/resources/mailboxes/connections.d.mts.map +1 -0
- package/resources/mailboxes/connections.d.ts +64 -0
- package/resources/mailboxes/connections.d.ts.map +1 -0
- package/resources/mailboxes/connections.js +42 -0
- package/resources/mailboxes/connections.js.map +1 -0
- package/resources/mailboxes/connections.mjs +38 -0
- package/resources/mailboxes/connections.mjs.map +1 -0
- package/resources/mailboxes/index.d.mts +2 -1
- package/resources/mailboxes/index.d.mts.map +1 -1
- package/resources/mailboxes/index.d.ts +2 -1
- package/resources/mailboxes/index.d.ts.map +1 -1
- package/resources/mailboxes/index.js +3 -1
- package/resources/mailboxes/index.js.map +1 -1
- package/resources/mailboxes/index.mjs +1 -0
- package/resources/mailboxes/index.mjs.map +1 -1
- package/resources/mailboxes/mailboxes.d.mts +107 -50
- package/resources/mailboxes/mailboxes.d.mts.map +1 -1
- package/resources/mailboxes/mailboxes.d.ts +107 -50
- package/resources/mailboxes/mailboxes.d.ts.map +1 -1
- package/resources/mailboxes/mailboxes.js +34 -24
- package/resources/mailboxes/mailboxes.js.map +1 -1
- package/resources/mailboxes/mailboxes.mjs +34 -24
- package/resources/mailboxes/mailboxes.mjs.map +1 -1
- package/resources/mailboxes/messages.d.mts +2 -2
- package/resources/mailboxes/messages.d.ts +2 -2
- package/resources/mailboxes/messages.js +2 -2
- package/resources/mailboxes/messages.mjs +2 -2
- package/resources/messages/conversations.d.mts +4 -15
- package/resources/messages/conversations.d.mts.map +1 -1
- package/resources/messages/conversations.d.ts +4 -15
- package/resources/messages/conversations.d.ts.map +1 -1
- package/resources/messages/conversations.js +4 -15
- package/resources/messages/conversations.js.map +1 -1
- package/resources/messages/conversations.mjs +4 -15
- package/resources/messages/conversations.mjs.map +1 -1
- package/resources/messages/index.d.mts +1 -1
- package/resources/messages/index.d.mts.map +1 -1
- package/resources/messages/index.d.ts +1 -1
- package/resources/messages/index.d.ts.map +1 -1
- package/resources/messages/index.js.map +1 -1
- package/resources/messages/index.mjs +1 -1
- package/resources/messages/index.mjs.map +1 -1
- package/resources/messages/messages.d.mts +28 -5
- package/resources/messages/messages.d.mts.map +1 -1
- package/resources/messages/messages.d.ts +28 -5
- package/resources/messages/messages.d.ts.map +1 -1
- package/resources/messages/messages.js +11 -4
- package/resources/messages/messages.js.map +1 -1
- package/resources/messages/messages.mjs +11 -4
- package/resources/messages/messages.mjs.map +1 -1
- package/resources/notifications.d.mts +27 -1
- package/resources/notifications.d.mts.map +1 -1
- package/resources/notifications.d.ts +27 -1
- package/resources/notifications.d.ts.map +1 -1
- package/resources/notifications.js +17 -0
- package/resources/notifications.js.map +1 -1
- package/resources/notifications.mjs +17 -0
- package/resources/notifications.mjs.map +1 -1
- package/resources/numbers/index.d.mts +2 -2
- package/resources/numbers/index.d.mts.map +1 -1
- package/resources/numbers/index.d.ts +2 -2
- package/resources/numbers/index.d.ts.map +1 -1
- package/resources/numbers/index.js.map +1 -1
- package/resources/numbers/index.mjs +1 -1
- package/resources/numbers/index.mjs.map +1 -1
- package/resources/numbers/messages.d.mts +60 -1
- package/resources/numbers/messages.d.mts.map +1 -1
- package/resources/numbers/messages.d.ts +60 -1
- package/resources/numbers/messages.d.ts.map +1 -1
- package/resources/numbers/messages.js +21 -0
- package/resources/numbers/messages.js.map +1 -1
- package/resources/numbers/messages.mjs +21 -0
- package/resources/numbers/messages.mjs.map +1 -1
- package/resources/numbers/numbers.d.mts +167 -46
- package/resources/numbers/numbers.d.mts.map +1 -1
- package/resources/numbers/numbers.d.ts +167 -46
- package/resources/numbers/numbers.d.ts.map +1 -1
- package/resources/numbers/numbers.js +25 -40
- package/resources/numbers/numbers.js.map +1 -1
- package/resources/numbers/numbers.mjs +26 -41
- package/resources/numbers/numbers.mjs.map +1 -1
- package/resources/store/apps.d.mts +23 -2
- package/resources/store/apps.d.mts.map +1 -1
- package/resources/store/apps.d.ts +23 -2
- package/resources/store/apps.d.ts.map +1 -1
- package/resources/tasks/tasks.d.mts +84 -75
- package/resources/tasks/tasks.d.mts.map +1 -1
- package/resources/tasks/tasks.d.ts +84 -75
- package/resources/tasks/tasks.d.ts.map +1 -1
- package/resources/tasks/tasks.js +2 -10
- package/resources/tasks/tasks.js.map +1 -1
- package/resources/tasks/tasks.mjs +2 -10
- package/resources/tasks/tasks.mjs.map +1 -1
- package/resources/webhooks/deliveries.d.mts +22 -31
- package/resources/webhooks/deliveries.d.mts.map +1 -1
- package/resources/webhooks/deliveries.d.ts +22 -31
- package/resources/webhooks/deliveries.d.ts.map +1 -1
- package/resources/webhooks/deliveries.js +4 -30
- package/resources/webhooks/deliveries.js.map +1 -1
- package/resources/webhooks/deliveries.mjs +4 -30
- package/resources/webhooks/deliveries.mjs.map +1 -1
- package/resources/webhooks/index.d.mts +1 -0
- package/resources/webhooks/index.d.mts.map +1 -1
- package/resources/webhooks/index.d.ts +1 -0
- package/resources/webhooks/index.d.ts.map +1 -1
- package/resources/webhooks/index.js +3 -1
- package/resources/webhooks/index.js.map +1 -1
- package/resources/webhooks/index.mjs +1 -0
- package/resources/webhooks/index.mjs.map +1 -1
- package/resources/webhooks/integrations.d.mts +77 -0
- package/resources/webhooks/integrations.d.mts.map +1 -0
- package/resources/webhooks/integrations.d.ts +77 -0
- package/resources/webhooks/integrations.d.ts.map +1 -0
- package/resources/webhooks/integrations.js +26 -0
- package/resources/webhooks/integrations.js.map +1 -0
- package/resources/webhooks/integrations.mjs +22 -0
- package/resources/webhooks/integrations.mjs.map +1 -0
- package/resources/webhooks/webhooks.d.mts +280 -71
- package/resources/webhooks/webhooks.d.mts.map +1 -1
- package/resources/webhooks/webhooks.d.ts +280 -71
- package/resources/webhooks/webhooks.d.ts.map +1 -1
- package/resources/webhooks/webhooks.js +27 -60
- package/resources/webhooks/webhooks.js.map +1 -1
- package/resources/webhooks/webhooks.mjs +27 -60
- package/resources/webhooks/webhooks.mjs.map +1 -1
- package/resources/workflows/action-catalog.d.mts +7 -3
- package/resources/workflows/action-catalog.d.mts.map +1 -1
- package/resources/workflows/action-catalog.d.ts +7 -3
- package/resources/workflows/action-catalog.d.ts.map +1 -1
- package/resources/workflows/actions/actions.d.mts +9 -5
- package/resources/workflows/actions/actions.d.mts.map +1 -1
- package/resources/workflows/actions/actions.d.ts +9 -5
- package/resources/workflows/actions/actions.d.ts.map +1 -1
- package/resources/workflows/actions/actions.js +4 -0
- package/resources/workflows/actions/actions.js.map +1 -1
- package/resources/workflows/actions/actions.mjs +4 -0
- package/resources/workflows/actions/actions.mjs.map +1 -1
- package/resources/workflows/events.d.mts +66 -4
- package/resources/workflows/events.d.mts.map +1 -1
- package/resources/workflows/events.d.ts +66 -4
- package/resources/workflows/events.d.ts.map +1 -1
- package/resources/workflows/executions/executions.d.mts +334 -0
- package/resources/workflows/executions/executions.d.mts.map +1 -0
- package/resources/workflows/executions/executions.d.ts +334 -0
- package/resources/workflows/executions/executions.d.ts.map +1 -0
- package/resources/workflows/executions/executions.js +49 -0
- package/resources/workflows/executions/executions.js.map +1 -0
- package/resources/workflows/executions/executions.mjs +44 -0
- package/resources/workflows/executions/executions.mjs.map +1 -0
- package/resources/workflows/executions/index.d.mts +3 -0
- package/resources/workflows/executions/index.d.mts.map +1 -0
- package/resources/workflows/executions/index.d.ts +3 -0
- package/resources/workflows/executions/index.d.ts.map +1 -0
- package/resources/workflows/executions/index.js +9 -0
- package/resources/workflows/executions/index.js.map +1 -0
- package/resources/workflows/executions/index.mjs +4 -0
- package/resources/workflows/executions/index.mjs.map +1 -0
- package/resources/workflows/executions/screenshots.d.mts +18 -0
- package/resources/workflows/executions/screenshots.d.mts.map +1 -0
- package/resources/workflows/executions/screenshots.d.ts +18 -0
- package/resources/workflows/executions/screenshots.d.ts.map +1 -0
- package/resources/workflows/executions/screenshots.js +23 -0
- package/resources/workflows/executions/screenshots.js.map +1 -0
- package/resources/workflows/executions/screenshots.mjs +19 -0
- package/resources/workflows/executions/screenshots.mjs.map +1 -0
- package/resources/workflows/executions.d.mts +1 -190
- package/resources/workflows/executions.d.mts.map +1 -1
- package/resources/workflows/executions.d.ts +1 -190
- package/resources/workflows/executions.d.ts.map +1 -1
- package/resources/workflows/executions.js +2 -36
- package/resources/workflows/executions.js.map +1 -1
- package/resources/workflows/executions.mjs +1 -34
- package/resources/workflows/executions.mjs.map +1 -1
- package/resources/workflows/flows/actions.d.mts +58 -0
- package/resources/workflows/flows/actions.d.mts.map +1 -1
- package/resources/workflows/flows/actions.d.ts +58 -0
- package/resources/workflows/flows/actions.d.ts.map +1 -1
- package/resources/workflows/flows/actions.js +4 -0
- package/resources/workflows/flows/actions.js.map +1 -1
- package/resources/workflows/flows/actions.mjs +4 -0
- package/resources/workflows/flows/actions.mjs.map +1 -1
- package/resources/workflows/flows/flows.d.mts +666 -15
- package/resources/workflows/flows/flows.d.mts.map +1 -1
- package/resources/workflows/flows/flows.d.ts +666 -15
- package/resources/workflows/flows/flows.d.ts.map +1 -1
- package/resources/workflows/flows/flows.js +86 -1
- package/resources/workflows/flows/flows.js.map +1 -1
- package/resources/workflows/flows/flows.mjs +86 -1
- package/resources/workflows/flows/flows.mjs.map +1 -1
- package/resources/workflows/flows/index.d.mts +1 -1
- package/resources/workflows/flows/index.d.mts.map +1 -1
- package/resources/workflows/flows/index.d.ts +1 -1
- package/resources/workflows/flows/index.d.ts.map +1 -1
- package/resources/workflows/flows/index.js.map +1 -1
- package/resources/workflows/flows/index.mjs.map +1 -1
- package/resources/workflows/index.d.mts +2 -2
- package/resources/workflows/index.d.mts.map +1 -1
- package/resources/workflows/index.d.ts +2 -2
- package/resources/workflows/index.d.ts.map +1 -1
- package/resources/workflows/index.js +4 -4
- package/resources/workflows/index.js.map +1 -1
- package/resources/workflows/index.mjs +1 -1
- package/resources/workflows/index.mjs.map +1 -1
- package/resources/workflows/triggers.d.mts +118 -6
- package/resources/workflows/triggers.d.mts.map +1 -1
- package/resources/workflows/triggers.d.ts +118 -6
- package/resources/workflows/triggers.d.ts.map +1 -1
- package/resources/workflows/triggers.js +14 -0
- package/resources/workflows/triggers.js.map +1 -1
- package/resources/workflows/triggers.mjs +14 -0
- package/resources/workflows/triggers.mjs.map +1 -1
- package/resources/workflows/workflows.d.mts +4 -4
- package/resources/workflows/workflows.d.mts.map +1 -1
- package/resources/workflows/workflows.d.ts +4 -4
- package/resources/workflows/workflows.d.ts.map +1 -1
- package/resources/workflows/workflows.js +2 -2
- package/resources/workflows/workflows.js.map +1 -1
- package/resources/workflows/workflows.mjs +2 -2
- package/resources/workflows/workflows.mjs.map +1 -1
- package/src/client.ts +22 -42
- package/src/resources/apps.ts +24 -12
- package/src/resources/assistant/conversations.ts +50 -31
- package/src/resources/connect/connect.ts +6 -0
- package/src/resources/connect/index.ts +3 -0
- package/src/resources/connect/proxies.ts +146 -18
- package/src/resources/devices/apps.ts +41 -17
- package/src/resources/devices/browser.ts +9 -3
- package/src/resources/devices/devices.ts +138 -34
- package/src/resources/devices/index.ts +13 -0
- package/src/resources/devices/keyboard.ts +10 -3
- package/src/resources/devices/recordings.ts +14 -0
- package/src/resources/devices/traffic-sessions.ts +282 -0
- package/src/resources/files.ts +122 -29
- package/src/resources/index.ts +13 -20
- package/src/resources/mailboxes/connections.ts +91 -0
- package/src/resources/mailboxes/index.ts +7 -0
- package/src/resources/mailboxes/mailboxes.ts +190 -49
- package/src/resources/mailboxes/messages.ts +2 -2
- package/src/resources/messages/conversations.ts +4 -15
- package/src/resources/messages/index.ts +6 -1
- package/src/resources/messages/messages.ts +57 -5
- package/src/resources/notifications.ts +37 -0
- package/src/resources/numbers/index.ts +9 -1
- package/src/resources/numbers/messages.ts +92 -1
- package/src/resources/numbers/numbers.ts +197 -55
- package/src/resources/store/apps.ts +291 -2
- package/src/resources/tasks/tasks.ts +126 -93
- package/src/resources/webhooks/deliveries.ts +26 -31
- package/src/resources/webhooks/index.ts +6 -0
- package/src/resources/webhooks/integrations.ts +107 -0
- package/src/resources/webhooks/webhooks.ts +328 -71
- package/src/resources/workflows/action-catalog.ts +11 -3
- package/src/resources/workflows/actions/actions.ts +9 -5
- package/src/resources/workflows/events.ts +86 -4
- package/src/resources/workflows/executions/executions.ts +514 -0
- package/src/resources/workflows/executions/index.ts +12 -0
- package/src/resources/workflows/executions/screenshots.ts +34 -0
- package/src/resources/workflows/executions.ts +1 -296
- package/src/resources/workflows/flows/actions.ts +72 -0
- package/src/resources/workflows/flows/flows.ts +1058 -129
- package/src/resources/workflows/flows/index.ts +12 -0
- package/src/resources/workflows/index.ts +13 -1
- package/src/resources/workflows/triggers.ts +140 -6
- package/src/resources/workflows/workflows.ts +34 -10
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/esims/esims.d.mts +0 -566
- package/resources/esims/esims.d.mts.map +0 -1
- package/resources/esims/esims.d.ts +0 -566
- package/resources/esims/esims.d.ts.map +0 -1
- package/resources/esims/esims.js +0 -205
- package/resources/esims/esims.js.map +0 -1
- package/resources/esims/esims.mjs +0 -200
- package/resources/esims/esims.mjs.map +0 -1
- package/resources/esims/index.d.mts +0 -3
- package/resources/esims/index.d.mts.map +0 -1
- package/resources/esims/index.d.ts +0 -3
- package/resources/esims/index.d.ts.map +0 -1
- package/resources/esims/index.js +0 -9
- package/resources/esims/index.js.map +0 -1
- package/resources/esims/index.mjs +0 -4
- package/resources/esims/index.mjs.map +0 -1
- package/resources/esims/messages.d.mts +0 -106
- package/resources/esims/messages.d.mts.map +0 -1
- package/resources/esims/messages.d.ts +0 -106
- package/resources/esims/messages.d.ts.map +0 -1
- package/resources/esims/messages.js +0 -37
- package/resources/esims/messages.js.map +0 -1
- package/resources/esims/messages.mjs +0 -33
- package/resources/esims/messages.mjs.map +0 -1
- package/resources/esims.d.mts +0 -2
- package/resources/esims.d.mts.map +0 -1
- package/resources/esims.d.ts +0 -2
- package/resources/esims.d.ts.map +0 -1
- package/resources/esims.js +0 -6
- package/resources/esims.js.map +0 -1
- package/resources/esims.mjs +0 -3
- package/resources/esims.mjs.map +0 -1
- package/src/resources/esims/esims.ts +0 -1019
- package/src/resources/esims/index.ts +0 -28
- package/src/resources/esims/messages.ts +0 -187
- package/src/resources/esims.ts +0 -3
|
@@ -4,6 +4,23 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Notifications = void 0;
|
|
5
5
|
const resource_1 = require("../core/resource.js");
|
|
6
6
|
class Notifications extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Replaces your muted event types with a server-computed preset: `recommended`
|
|
9
|
+
* mutes the mobilerun-default noisy lifecycle/progress events, `failures` mutes
|
|
10
|
+
* everything except failures/timeouts/invalid runs, and `everything` unmutes all.
|
|
11
|
+
* The response returns the muted types that were actually stored.
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```ts
|
|
15
|
+
* const response =
|
|
16
|
+
* await client.notifications.applyPreferencesPreset({
|
|
17
|
+
* preset: 'recommended',
|
|
18
|
+
* });
|
|
19
|
+
* ```
|
|
20
|
+
*/
|
|
21
|
+
applyPreferencesPreset(body, options) {
|
|
22
|
+
return this._client.post('/notifications/preferences/apply-preset', { body, ...options });
|
|
23
|
+
}
|
|
7
24
|
/**
|
|
8
25
|
* Returns the catalog of notifiable event types grouped by source category. Each
|
|
9
26
|
* event lists its type identifier, label, and description, which can be referenced
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notifications.js","sourceRoot":"","sources":["../src/resources/notifications.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C,MAAa,aAAc,SAAQ,sBAAW;IAC5C;;;;;;;;;OASG;IACH,OAAO,CAAC,OAAwB;QAC9B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,wBAAwB,EAAE,OAAO,CAAC,CAAC;IAC7D,CAAC;IAED;;;;;;;;;;OAUG;IACH,cAAc,CAAC,OAAwB;QACrC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,4BAA4B,EAAE,OAAO,CAAC,CAAC;IACjE,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACH,iBAAiB,CACf,IAAyC,EACzC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;CACF;
|
|
1
|
+
{"version":3,"file":"notifications.js","sourceRoot":"","sources":["../src/resources/notifications.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C,MAAa,aAAc,SAAQ,sBAAW;IAC5C;;;;;;;;;;;;;OAaG;IACH,sBAAsB,CACpB,IAA8C,EAC9C,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,yCAAyC,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5F,CAAC;IAED;;;;;;;;;OASG;IACH,OAAO,CAAC,OAAwB;QAC9B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,wBAAwB,EAAE,OAAO,CAAC,CAAC;IAC7D,CAAC;IAED;;;;;;;;;;OAUG;IACH,cAAc,CAAC,OAAwB;QACrC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,4BAA4B,EAAE,OAAO,CAAC,CAAC;IACjE,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACH,iBAAiB,CACf,IAAyC,EACzC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;CACF;AAzED,sCAyEC"}
|
|
@@ -1,6 +1,23 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../core/resource.mjs";
|
|
3
3
|
export class Notifications extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Replaces your muted event types with a server-computed preset: `recommended`
|
|
6
|
+
* mutes the mobilerun-default noisy lifecycle/progress events, `failures` mutes
|
|
7
|
+
* everything except failures/timeouts/invalid runs, and `everything` unmutes all.
|
|
8
|
+
* The response returns the muted types that were actually stored.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* const response =
|
|
13
|
+
* await client.notifications.applyPreferencesPreset({
|
|
14
|
+
* preset: 'recommended',
|
|
15
|
+
* });
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
applyPreferencesPreset(body, options) {
|
|
19
|
+
return this._client.post('/notifications/preferences/apply-preset', { body, ...options });
|
|
20
|
+
}
|
|
4
21
|
/**
|
|
5
22
|
* Returns the catalog of notifiable event types grouped by source category. Each
|
|
6
23
|
* event lists its type identifier, label, and description, which can be referenced
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notifications.mjs","sourceRoot":"","sources":["../src/resources/notifications.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAI/C,MAAM,OAAO,aAAc,SAAQ,WAAW;IAC5C;;;;;;;;;OASG;IACH,OAAO,CAAC,OAA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,EAAE,CAAC,CAAC;IAChF,CAAC;CACF"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { Messages, type MessageListResponse, type MessageListParams } from "./messages.mjs";
|
|
2
|
-
export { Numbers, type NumberCreateResponse, type NumberRetrieveResponse, type NumberUpdateResponse, type NumberListResponse, type NumberDeleteResponse, type NumberCountriesResponse, type NumberPurposesResponse, type NumberCreateParams, type NumberUpdateParams, type NumberListParams, } from "./numbers.mjs";
|
|
1
|
+
export { Messages, type MessageListResponse, type MessageSendResponse, type MessageListParams, type MessageSendParams, } from "./messages.mjs";
|
|
2
|
+
export { Numbers, type NumberCreateResponse, type NumberRetrieveResponse, type NumberUpdateResponse, type NumberListResponse, type NumberDeleteResponse, type NumberCapacityResponse, type NumberCountriesResponse, type NumberPurposesResponse, type NumberCreateParams, type NumberUpdateParams, type NumberListParams, type NumberCapacityParams, } from "./numbers.mjs";
|
|
3
3
|
//# sourceMappingURL=index.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,QAAQ,EACR,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,uBAAmB;AACpB,OAAO,EACL,OAAO,EACP,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,EAC5B,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,GAC1B,sBAAkB"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { Messages, type MessageListResponse, type MessageListParams } from "./messages.js";
|
|
2
|
-
export { Numbers, type NumberCreateResponse, type NumberRetrieveResponse, type NumberUpdateResponse, type NumberListResponse, type NumberDeleteResponse, type NumberCountriesResponse, type NumberPurposesResponse, type NumberCreateParams, type NumberUpdateParams, type NumberListParams, } from "./numbers.js";
|
|
1
|
+
export { Messages, type MessageListResponse, type MessageSendResponse, type MessageListParams, type MessageSendParams, } from "./messages.js";
|
|
2
|
+
export { Numbers, type NumberCreateResponse, type NumberRetrieveResponse, type NumberUpdateResponse, type NumberListResponse, type NumberDeleteResponse, type NumberCapacityResponse, type NumberCountriesResponse, type NumberPurposesResponse, type NumberCreateParams, type NumberUpdateParams, type NumberListParams, type NumberCapacityParams, } from "./numbers.js";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,QAAQ,EACR,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,sBAAmB;AACpB,OAAO,EACL,OAAO,EACP,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,EAC5B,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,GAC1B,qBAAkB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0CAMoB;AALlB,oGAAA,QAAQ,OAAA;AAMV,wCAcmB;AAbjB,kGAAA,OAAO,OAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/numbers/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EACL,QAAQ,GAKT,uBAAmB;AACpB,OAAO,EACL,OAAO,GAaR,sBAAkB"}
|
|
@@ -16,6 +16,25 @@ export declare class Messages extends APIResource {
|
|
|
16
16
|
* ```
|
|
17
17
|
*/
|
|
18
18
|
list(id: string, query?: MessageListParams | null | undefined, options?: RequestOptions): APIPromise<MessageListResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Queues an SMS from one of the caller's numbers that can send. Same idempotency
|
|
21
|
+
* contract as the eSIM send: replaying an Idempotency-Key with the same payload
|
|
22
|
+
* returns the original message, reusing it with a different payload returns 422.
|
|
23
|
+
* 409 capability_unavailable: this number cannot send right now. 422
|
|
24
|
+
* invalid_recipient / unsupported_destination / body_too_long: the recipient or
|
|
25
|
+
* text does not fit the number. 429 daily_limit_reached: the rolling 24 h limit
|
|
26
|
+
* for the account is used up; 429 rate_limited: too many sends in a short window.
|
|
27
|
+
* 403 send_disabled: self-service SMS send is switched off.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```ts
|
|
31
|
+
* const response = await client.numbers.messages.send(
|
|
32
|
+
* '550e8400-e29b-41d4-a716-446655440000',
|
|
33
|
+
* { body: 'x', to: '+15551230001' },
|
|
34
|
+
* );
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
send(id: string, body: MessageSendParams, options?: RequestOptions): APIPromise<MessageSendResponse>;
|
|
19
38
|
}
|
|
20
39
|
export interface MessageListResponse {
|
|
21
40
|
items: Array<MessageListResponse.Item>;
|
|
@@ -36,13 +55,53 @@ export declare namespace MessageListResponse {
|
|
|
36
55
|
status: 'received' | 'queued' | 'claimed' | 'sending' | 'sent' | 'sent_unconfirmed' | 'delivered' | 'failed';
|
|
37
56
|
}
|
|
38
57
|
}
|
|
58
|
+
export interface MessageSendResponse {
|
|
59
|
+
data: MessageSendResponse.Data;
|
|
60
|
+
}
|
|
61
|
+
export declare namespace MessageSendResponse {
|
|
62
|
+
interface Data {
|
|
63
|
+
id: string;
|
|
64
|
+
body: string | null;
|
|
65
|
+
createdAt: string;
|
|
66
|
+
deliveryStatus: string | null;
|
|
67
|
+
detectedSender: string | null;
|
|
68
|
+
direction: 'inbound' | 'outbound';
|
|
69
|
+
esimId: string | null;
|
|
70
|
+
occurredAt: string;
|
|
71
|
+
peerKey: string | null;
|
|
72
|
+
peerNumber: string | null;
|
|
73
|
+
status: 'received' | 'queued' | 'claimed' | 'sending' | 'sent' | 'sent_unconfirmed' | 'delivered' | 'failed';
|
|
74
|
+
}
|
|
75
|
+
}
|
|
39
76
|
export interface MessageListParams {
|
|
40
77
|
direction?: 'all' | 'inbound' | 'outbound';
|
|
41
78
|
page?: number;
|
|
42
79
|
pageSize?: number;
|
|
43
80
|
since?: string;
|
|
44
81
|
}
|
|
82
|
+
export interface MessageSendParams {
|
|
83
|
+
/**
|
|
84
|
+
* SMS body text, up to 1600 characters (rejected with 400 beyond that, before
|
|
85
|
+
* hashing). A number's own limit may be lower and is answered 422 body_too_long.
|
|
86
|
+
*/
|
|
87
|
+
body: string;
|
|
88
|
+
/**
|
|
89
|
+
* Recipient phone number, as E.164 or a US 10/11-digit number. Destinations the
|
|
90
|
+
* number cannot send to are rejected with 422 unsupported_destination, non-numbers
|
|
91
|
+
* with 422 invalid_recipient.
|
|
92
|
+
*/
|
|
93
|
+
to: string;
|
|
94
|
+
/**
|
|
95
|
+
* @deprecated Deprecated: use the Idempotency-Key header instead. Optional
|
|
96
|
+
* idempotency key. Replaying the same key and payload returns the original send.
|
|
97
|
+
*/
|
|
98
|
+
clientRequestId?: string;
|
|
99
|
+
/**
|
|
100
|
+
* Request a delivery report. Defaults to false.
|
|
101
|
+
*/
|
|
102
|
+
deliveryReport?: boolean;
|
|
103
|
+
}
|
|
45
104
|
export declare namespace Messages {
|
|
46
|
-
export { type MessageListResponse as MessageListResponse, type MessageListParams as MessageListParams };
|
|
105
|
+
export { type MessageListResponse as MessageListResponse, type MessageSendResponse as MessageSendResponse, type MessageListParams as MessageListParams, type MessageSendParams as MessageSendParams, };
|
|
47
106
|
}
|
|
48
107
|
//# sourceMappingURL=messages.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messages.d.mts","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,KAAK,MAAM,sBAAkB;AACpC,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,EAAE,EAAE,MAAM,EACV,KAAK,GAAE,iBAAiB,GAAG,IAAI,GAAG,SAAc,EAChD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"messages.d.mts","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,KAAK,MAAM,sBAAkB;AACpC,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE,qBAAa,QAAS,SAAQ,WAAW;IACvC;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AS,EAAE,MAAM,CAAC;QAElB,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;QAE9B,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;QAE9B,SAAS,EAAE,SAAS,GAAG,UAAU,CAAC;QAElC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;QAEtB,UAAU,EAAE,MAAM,CAAC;QAEnB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;QAEvB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;QAE1B,MAAM,EACF,UAAU,GACV,QAAQ,GACR,SAAS,GACT,SAAS,GACT,MAAM,GACN,kBAAkB,GAClB,WAAW,GACX,QAAQ,CAAC;KACd;CACF;AAED,MAAM,WAAW,iBAAiB;IAChC,SAAS,CAAC,EAAE,KAAK,GAAG,SAAS,GAAG,UAAU,CAAC;IAE3C,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;OAIG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;CACH"}
|
|
@@ -16,6 +16,25 @@ export declare class Messages extends APIResource {
|
|
|
16
16
|
* ```
|
|
17
17
|
*/
|
|
18
18
|
list(id: string, query?: MessageListParams | null | undefined, options?: RequestOptions): APIPromise<MessageListResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Queues an SMS from one of the caller's numbers that can send. Same idempotency
|
|
21
|
+
* contract as the eSIM send: replaying an Idempotency-Key with the same payload
|
|
22
|
+
* returns the original message, reusing it with a different payload returns 422.
|
|
23
|
+
* 409 capability_unavailable: this number cannot send right now. 422
|
|
24
|
+
* invalid_recipient / unsupported_destination / body_too_long: the recipient or
|
|
25
|
+
* text does not fit the number. 429 daily_limit_reached: the rolling 24 h limit
|
|
26
|
+
* for the account is used up; 429 rate_limited: too many sends in a short window.
|
|
27
|
+
* 403 send_disabled: self-service SMS send is switched off.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```ts
|
|
31
|
+
* const response = await client.numbers.messages.send(
|
|
32
|
+
* '550e8400-e29b-41d4-a716-446655440000',
|
|
33
|
+
* { body: 'x', to: '+15551230001' },
|
|
34
|
+
* );
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
send(id: string, body: MessageSendParams, options?: RequestOptions): APIPromise<MessageSendResponse>;
|
|
19
38
|
}
|
|
20
39
|
export interface MessageListResponse {
|
|
21
40
|
items: Array<MessageListResponse.Item>;
|
|
@@ -36,13 +55,53 @@ export declare namespace MessageListResponse {
|
|
|
36
55
|
status: 'received' | 'queued' | 'claimed' | 'sending' | 'sent' | 'sent_unconfirmed' | 'delivered' | 'failed';
|
|
37
56
|
}
|
|
38
57
|
}
|
|
58
|
+
export interface MessageSendResponse {
|
|
59
|
+
data: MessageSendResponse.Data;
|
|
60
|
+
}
|
|
61
|
+
export declare namespace MessageSendResponse {
|
|
62
|
+
interface Data {
|
|
63
|
+
id: string;
|
|
64
|
+
body: string | null;
|
|
65
|
+
createdAt: string;
|
|
66
|
+
deliveryStatus: string | null;
|
|
67
|
+
detectedSender: string | null;
|
|
68
|
+
direction: 'inbound' | 'outbound';
|
|
69
|
+
esimId: string | null;
|
|
70
|
+
occurredAt: string;
|
|
71
|
+
peerKey: string | null;
|
|
72
|
+
peerNumber: string | null;
|
|
73
|
+
status: 'received' | 'queued' | 'claimed' | 'sending' | 'sent' | 'sent_unconfirmed' | 'delivered' | 'failed';
|
|
74
|
+
}
|
|
75
|
+
}
|
|
39
76
|
export interface MessageListParams {
|
|
40
77
|
direction?: 'all' | 'inbound' | 'outbound';
|
|
41
78
|
page?: number;
|
|
42
79
|
pageSize?: number;
|
|
43
80
|
since?: string;
|
|
44
81
|
}
|
|
82
|
+
export interface MessageSendParams {
|
|
83
|
+
/**
|
|
84
|
+
* SMS body text, up to 1600 characters (rejected with 400 beyond that, before
|
|
85
|
+
* hashing). A number's own limit may be lower and is answered 422 body_too_long.
|
|
86
|
+
*/
|
|
87
|
+
body: string;
|
|
88
|
+
/**
|
|
89
|
+
* Recipient phone number, as E.164 or a US 10/11-digit number. Destinations the
|
|
90
|
+
* number cannot send to are rejected with 422 unsupported_destination, non-numbers
|
|
91
|
+
* with 422 invalid_recipient.
|
|
92
|
+
*/
|
|
93
|
+
to: string;
|
|
94
|
+
/**
|
|
95
|
+
* @deprecated Deprecated: use the Idempotency-Key header instead. Optional
|
|
96
|
+
* idempotency key. Replaying the same key and payload returns the original send.
|
|
97
|
+
*/
|
|
98
|
+
clientRequestId?: string;
|
|
99
|
+
/**
|
|
100
|
+
* Request a delivery report. Defaults to false.
|
|
101
|
+
*/
|
|
102
|
+
deliveryReport?: boolean;
|
|
103
|
+
}
|
|
45
104
|
export declare namespace Messages {
|
|
46
|
-
export { type MessageListResponse as MessageListResponse, type MessageListParams as MessageListParams };
|
|
105
|
+
export { type MessageListResponse as MessageListResponse, type MessageSendResponse as MessageSendResponse, type MessageListParams as MessageListParams, type MessageSendParams as MessageSendParams, };
|
|
47
106
|
}
|
|
48
107
|
//# sourceMappingURL=messages.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,KAAK,MAA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OAGG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;OAIG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;CACH"}
|
|
@@ -20,6 +20,27 @@ class Messages extends resource_1.APIResource {
|
|
|
20
20
|
list(id, query = {}, options) {
|
|
21
21
|
return this._client.get((0, path_1.path) `/numbers/phones/${id}/messages`, { query, ...options });
|
|
22
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* Queues an SMS from one of the caller's numbers that can send. Same idempotency
|
|
25
|
+
* contract as the eSIM send: replaying an Idempotency-Key with the same payload
|
|
26
|
+
* returns the original message, reusing it with a different payload returns 422.
|
|
27
|
+
* 409 capability_unavailable: this number cannot send right now. 422
|
|
28
|
+
* invalid_recipient / unsupported_destination / body_too_long: the recipient or
|
|
29
|
+
* text does not fit the number. 429 daily_limit_reached: the rolling 24 h limit
|
|
30
|
+
* for the account is used up; 429 rate_limited: too many sends in a short window.
|
|
31
|
+
* 403 send_disabled: self-service SMS send is switched off.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* const response = await client.numbers.messages.send(
|
|
36
|
+
* '550e8400-e29b-41d4-a716-446655440000',
|
|
37
|
+
* { body: 'x', to: '+15551230001' },
|
|
38
|
+
* );
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
send(id, body, options) {
|
|
42
|
+
return this._client.post((0, path_1.path) `/numbers/phones/${id}/messages`, { body, ...options });
|
|
43
|
+
}
|
|
23
44
|
}
|
|
24
45
|
exports.Messages = Messages;
|
|
25
46
|
//# sourceMappingURL=messages.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAIlD,uDAAiD;AAEjD,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,EAAU,EACV,QAA8C,EAAE,EAChD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;CACF;
|
|
1
|
+
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAIlD,uDAAiD;AAEjD,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,EAAU,EACV,QAA8C,EAAE,EAChD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,IAAI,CAAC,EAAU,EAAE,IAAuB,EAAE,OAAwB;QAChE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;CACF;AA1CD,4BA0CC"}
|
|
@@ -17,5 +17,26 @@ export class Messages extends APIResource {
|
|
|
17
17
|
list(id, query = {}, options) {
|
|
18
18
|
return this._client.get(path `/numbers/phones/${id}/messages`, { query, ...options });
|
|
19
19
|
}
|
|
20
|
+
/**
|
|
21
|
+
* Queues an SMS from one of the caller's numbers that can send. Same idempotency
|
|
22
|
+
* contract as the eSIM send: replaying an Idempotency-Key with the same payload
|
|
23
|
+
* returns the original message, reusing it with a different payload returns 422.
|
|
24
|
+
* 409 capability_unavailable: this number cannot send right now. 422
|
|
25
|
+
* invalid_recipient / unsupported_destination / body_too_long: the recipient or
|
|
26
|
+
* text does not fit the number. 429 daily_limit_reached: the rolling 24 h limit
|
|
27
|
+
* for the account is used up; 429 rate_limited: too many sends in a short window.
|
|
28
|
+
* 403 send_disabled: self-service SMS send is switched off.
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* ```ts
|
|
32
|
+
* const response = await client.numbers.messages.send(
|
|
33
|
+
* '550e8400-e29b-41d4-a716-446655440000',
|
|
34
|
+
* { body: 'x', to: '+15551230001' },
|
|
35
|
+
* );
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
send(id, body, options) {
|
|
39
|
+
return this._client.post(path `/numbers/phones/${id}/messages`, { body, ...options });
|
|
40
|
+
}
|
|
20
41
|
}
|
|
21
42
|
//# sourceMappingURL=messages.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"messages.mjs","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAIlD,OAAO,EAAE,IAAI,EAAE,sCAAkC;AAEjD,MAAM,OAAO,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,EAAU,EACV,QAA8C,EAAE,EAChD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;CACF"}
|
|
1
|
+
{"version":3,"file":"messages.mjs","sourceRoot":"","sources":["../../src/resources/numbers/messages.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAIlD,OAAO,EAAE,IAAI,EAAE,sCAAkC;AAEjD,MAAM,OAAO,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,EAAU,EACV,QAA8C,EAAE,EAChD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,IAAI,CAAC,EAAU,EAAE,IAAuB,EAAE,OAAwB;QAChE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,mBAAmB,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvF,CAAC;CACF"}
|