@roarkanalytics/sdk 2.21.0 → 2.21.2
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 +16 -0
- package/README.md +112 -51
- package/api-promise.d.mts +2 -0
- package/api-promise.d.mts.map +1 -0
- package/api-promise.d.ts +2 -0
- package/api-promise.d.ts.map +1 -0
- package/api-promise.js +6 -0
- package/api-promise.js.map +1 -0
- package/api-promise.mjs +2 -0
- package/api-promise.mjs.map +1 -0
- package/client.d.mts +196 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +196 -0
- package/client.d.ts.map +1 -0
- package/client.js +472 -0
- package/client.js.map +1 -0
- package/client.mjs +468 -0
- package/client.mjs.map +1 -0
- package/core/api-promise.d.mts +46 -0
- package/core/api-promise.d.mts.map +1 -0
- package/core/api-promise.d.ts +46 -0
- package/core/api-promise.d.ts.map +1 -0
- package/core/api-promise.js +74 -0
- package/core/api-promise.js.map +1 -0
- package/core/api-promise.mjs +70 -0
- package/core/api-promise.mjs.map +1 -0
- package/core/error.d.mts +46 -0
- package/core/error.d.mts.map +1 -0
- package/core/error.d.ts +46 -0
- package/core/error.d.ts.map +1 -0
- package/core/error.js +113 -0
- package/core/error.js.map +1 -0
- package/core/error.mjs +97 -0
- package/core/error.mjs.map +1 -0
- package/core/resource.d.mts +6 -0
- package/core/resource.d.mts.map +1 -0
- package/core/resource.d.ts +6 -0
- package/core/resource.d.ts.map +1 -0
- package/core/resource.js +11 -0
- package/core/resource.js.map +1 -0
- package/core/resource.mjs +7 -0
- package/core/resource.mjs.map +1 -0
- package/core/uploads.d.mts +3 -0
- package/core/uploads.d.mts.map +1 -0
- package/core/uploads.d.ts +3 -0
- package/core/uploads.d.ts.map +1 -0
- package/core/uploads.js +6 -0
- package/core/uploads.js.map +1 -0
- package/core/uploads.mjs +2 -0
- package/core/uploads.mjs.map +1 -0
- package/error.d.mts +2 -0
- package/error.d.mts.map +1 -0
- package/error.d.ts +1 -46
- package/error.d.ts.map +1 -1
- package/error.js +3 -110
- package/error.js.map +1 -1
- package/error.mjs +1 -96
- package/error.mjs.map +1 -1
- package/index.d.mts +6 -132
- package/index.d.mts.map +1 -0
- package/index.d.ts +5 -131
- package/index.d.ts.map +1 -1
- package/index.js +12 -130
- package/index.js.map +1 -1
- package/index.mjs +5 -103
- package/index.mjs.map +1 -1
- package/internal/builtin-types.d.mts +73 -0
- package/internal/builtin-types.d.mts.map +1 -0
- package/internal/builtin-types.d.ts +73 -0
- package/internal/builtin-types.d.ts.map +1 -0
- package/internal/builtin-types.js +4 -0
- package/internal/builtin-types.js.map +1 -0
- package/internal/builtin-types.mjs +3 -0
- package/internal/builtin-types.mjs.map +1 -0
- package/internal/detect-platform.d.mts +15 -0
- package/internal/detect-platform.d.mts.map +1 -0
- package/internal/detect-platform.d.ts +15 -0
- package/internal/detect-platform.d.ts.map +1 -0
- package/internal/detect-platform.js +162 -0
- package/internal/detect-platform.js.map +1 -0
- package/internal/detect-platform.mjs +157 -0
- package/internal/detect-platform.mjs.map +1 -0
- package/internal/errors.d.mts +3 -0
- package/internal/errors.d.mts.map +1 -0
- package/internal/errors.d.ts +3 -0
- package/internal/errors.d.ts.map +1 -0
- package/internal/errors.js +41 -0
- package/internal/errors.js.map +1 -0
- package/internal/errors.mjs +36 -0
- package/internal/errors.mjs.map +1 -0
- package/internal/headers.d.mts +20 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +20 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +79 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +74 -0
- package/internal/headers.mjs.map +1 -0
- package/internal/parse.d.mts +12 -0
- package/internal/parse.d.mts.map +1 -0
- package/internal/parse.d.ts +12 -0
- package/internal/parse.d.ts.map +1 -0
- package/internal/parse.js +40 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +37 -0
- package/internal/parse.mjs.map +1 -0
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +1 -0
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/formats.js +4 -2
- package/internal/qs/formats.js.map +1 -1
- package/internal/qs/formats.mjs +2 -1
- package/internal/qs/formats.mjs.map +1 -1
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.js +16 -19
- package/internal/qs/stringify.js.map +1 -1
- package/internal/qs/stringify.mjs +17 -19
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +1 -0
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.js +22 -21
- package/internal/qs/utils.js.map +1 -1
- package/internal/qs/utils.mjs +12 -12
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts +75 -0
- package/internal/request-options.d.mts.map +1 -0
- package/internal/request-options.d.ts +75 -0
- package/internal/request-options.d.ts.map +1 -0
- package/internal/request-options.js +14 -0
- package/internal/request-options.js.map +1 -0
- package/internal/request-options.mjs +10 -0
- package/internal/request-options.mjs.map +1 -0
- package/internal/shim-types.d.mts +17 -0
- package/internal/shim-types.d.mts.map +1 -0
- package/internal/shim-types.d.ts +17 -0
- package/internal/shim-types.d.ts.map +1 -0
- package/internal/shim-types.js +4 -0
- package/internal/shim-types.js.map +1 -0
- package/internal/shim-types.mjs +3 -0
- package/internal/shim-types.mjs.map +1 -0
- package/internal/shims.d.mts +20 -0
- package/internal/shims.d.mts.map +1 -0
- package/internal/shims.d.ts +20 -0
- package/internal/shims.d.ts.map +1 -0
- package/internal/shims.js +92 -0
- package/internal/shims.js.map +1 -0
- package/internal/shims.mjs +85 -0
- package/internal/shims.mjs.map +1 -0
- package/internal/to-file.d.mts +45 -0
- package/internal/to-file.d.mts.map +1 -0
- package/internal/to-file.d.ts +45 -0
- package/internal/to-file.d.ts.map +1 -0
- package/internal/to-file.js +91 -0
- package/internal/to-file.js.map +1 -0
- package/internal/to-file.mjs +88 -0
- package/internal/to-file.mjs.map +1 -0
- package/internal/tslib.js +81 -0
- package/internal/tslib.mjs +17 -0
- package/internal/types.d.mts +69 -0
- package/internal/types.d.mts.map +1 -0
- package/internal/types.d.ts +69 -0
- package/internal/types.d.ts.map +1 -0
- package/internal/types.js +4 -0
- package/internal/types.js.map +1 -0
- package/internal/types.mjs +3 -0
- package/internal/types.mjs.map +1 -0
- package/internal/uploads.d.mts +42 -0
- package/internal/uploads.d.mts.map +1 -0
- package/internal/uploads.d.ts +42 -0
- package/internal/uploads.d.ts.map +1 -0
- package/internal/uploads.js +141 -0
- package/internal/uploads.js.map +1 -0
- package/internal/uploads.mjs +131 -0
- package/internal/uploads.mjs.map +1 -0
- package/internal/utils/base64.d.mts +3 -0
- package/internal/utils/base64.d.mts.map +1 -0
- package/internal/utils/base64.d.ts +3 -0
- package/internal/utils/base64.d.ts.map +1 -0
- package/internal/utils/base64.js +38 -0
- package/internal/utils/base64.js.map +1 -0
- package/internal/utils/base64.mjs +33 -0
- package/internal/utils/base64.mjs.map +1 -0
- package/internal/utils/bytes.d.mts +4 -0
- package/internal/utils/bytes.d.mts.map +1 -0
- package/internal/utils/bytes.d.ts +4 -0
- package/internal/utils/bytes.d.ts.map +1 -0
- package/internal/utils/bytes.js +31 -0
- package/internal/utils/bytes.js.map +1 -0
- package/internal/utils/bytes.mjs +26 -0
- package/internal/utils/bytes.mjs.map +1 -0
- package/internal/utils/env.d.mts +9 -0
- package/internal/utils/env.d.mts.map +1 -0
- package/internal/utils/env.d.ts +9 -0
- package/internal/utils/env.d.ts.map +1 -0
- package/internal/utils/env.js +22 -0
- package/internal/utils/env.js.map +1 -0
- package/internal/utils/env.mjs +18 -0
- package/internal/utils/env.mjs.map +1 -0
- package/internal/utils/log.d.mts +37 -0
- package/internal/utils/log.d.mts.map +1 -0
- package/internal/utils/log.d.ts +37 -0
- package/internal/utils/log.d.ts.map +1 -0
- package/internal/utils/log.js +85 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +79 -0
- package/internal/utils/log.mjs.map +1 -0
- package/internal/utils/path.d.mts +15 -0
- package/internal/utils/path.d.mts.map +1 -0
- package/internal/utils/path.d.ts +15 -0
- package/internal/utils/path.d.ts.map +1 -0
- package/internal/utils/path.js +79 -0
- package/internal/utils/path.js.map +1 -0
- package/internal/utils/path.mjs +74 -0
- package/internal/utils/path.mjs.map +1 -0
- package/internal/utils/sleep.d.mts +2 -0
- package/internal/utils/sleep.d.mts.map +1 -0
- package/internal/utils/sleep.d.ts +2 -0
- package/internal/utils/sleep.d.ts.map +1 -0
- package/internal/utils/sleep.js +7 -0
- package/internal/utils/sleep.js.map +1 -0
- package/internal/utils/sleep.mjs +3 -0
- package/internal/utils/sleep.mjs.map +1 -0
- package/internal/utils/uuid.d.mts +5 -0
- package/internal/utils/uuid.d.mts.map +1 -0
- package/internal/utils/uuid.d.ts +5 -0
- package/internal/utils/uuid.d.ts.map +1 -0
- package/internal/utils/uuid.js +19 -0
- package/internal/utils/uuid.js.map +1 -0
- package/internal/utils/uuid.mjs +15 -0
- package/internal/utils/uuid.mjs.map +1 -0
- package/internal/utils/values.d.mts +18 -0
- package/internal/utils/values.d.mts.map +1 -0
- package/internal/utils/values.d.ts +18 -0
- package/internal/utils/values.d.ts.map +1 -0
- package/internal/utils/values.js +112 -0
- package/internal/utils/values.js.map +1 -0
- package/internal/utils/values.mjs +94 -0
- package/internal/utils/values.mjs.map +1 -0
- package/internal/utils.d.mts +7 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +7 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +11 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +8 -0
- package/internal/utils.mjs.map +1 -0
- package/package.json +108 -73
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +1 -5
- package/resource.d.ts.map +1 -1
- package/resource.js +3 -8
- package/resource.js.map +1 -1
- package/resource.mjs +1 -6
- package/resource.mjs.map +1 -1
- package/resources/call.d.mts +1207 -0
- package/resources/call.d.mts.map +1 -0
- package/resources/call.d.ts +9 -10
- package/resources/call.d.ts.map +1 -1
- package/resources/call.js +17 -16
- package/resources/call.js.map +1 -1
- package/resources/call.mjs +17 -16
- package/resources/call.mjs.map +1 -1
- package/resources/evaluation.d.mts +1307 -0
- package/resources/evaluation.d.mts.map +1 -0
- package/resources/evaluation.d.ts +8 -9
- package/resources/evaluation.d.ts.map +1 -1
- package/resources/evaluation.js +15 -14
- package/resources/evaluation.js.map +1 -1
- package/resources/evaluation.mjs +15 -14
- package/resources/evaluation.mjs.map +1 -1
- package/resources/health.d.mts +29 -0
- package/resources/health.d.mts.map +1 -0
- package/resources/health.d.ts +4 -3
- package/resources/health.d.ts.map +1 -1
- package/resources/health.js +1 -1
- package/resources/health.js.map +1 -1
- package/resources/health.mjs +1 -1
- package/resources/health.mjs.map +1 -1
- package/resources/index.d.mts +8 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/integrations.d.mts +114 -0
- package/resources/integrations.d.mts.map +1 -0
- package/resources/integrations.d.ts +5 -4
- package/resources/integrations.d.ts.map +1 -1
- package/resources/integrations.js +1 -1
- package/resources/integrations.js.map +1 -1
- package/resources/integrations.mjs +1 -1
- package/resources/integrations.mjs.map +1 -1
- package/resources/metric.d.mts +75 -0
- package/resources/metric.d.mts.map +1 -0
- package/resources/metric.d.ts +4 -3
- package/resources/metric.d.ts.map +1 -1
- package/resources/metric.js +1 -1
- package/resources/metric.js.map +1 -1
- package/resources/metric.mjs +1 -1
- package/resources/metric.mjs.map +1 -1
- package/resources/persona.d.mts +528 -0
- package/resources/persona.d.mts.map +1 -0
- package/resources/persona.d.ts +8 -9
- package/resources/persona.d.ts.map +1 -1
- package/resources/persona.js +23 -13
- package/resources/persona.js.map +1 -1
- package/resources/persona.mjs +23 -13
- package/resources/persona.mjs.map +1 -1
- package/resources/simulation.d.mts +802 -0
- package/resources/simulation.d.mts.map +1 -0
- package/resources/simulation.d.ts +10 -11
- package/resources/simulation.d.ts.map +1 -1
- package/resources/simulation.js +26 -15
- package/resources/simulation.js.map +1 -1
- package/resources/simulation.mjs +26 -15
- package/resources/simulation.mjs.map +1 -1
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts.map +1 -1
- package/resources.js +2 -15
- package/resources.js.map +1 -1
- package/src/api-promise.ts +2 -0
- package/src/client.ts +842 -0
- package/src/core/README.md +3 -0
- package/src/core/api-promise.ts +92 -0
- package/src/core/error.ts +130 -0
- package/src/core/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -130
- package/src/index.ts +5 -308
- package/src/internal/README.md +3 -0
- package/src/internal/builtin-types.ts +93 -0
- package/src/internal/detect-platform.ts +196 -0
- package/src/internal/errors.ts +33 -0
- package/src/internal/headers.ts +97 -0
- package/src/internal/parse.ts +56 -0
- package/src/internal/qs/formats.ts +2 -1
- package/src/internal/qs/stringify.ts +17 -20
- package/src/internal/qs/utils.ts +14 -14
- package/src/internal/request-options.ts +91 -0
- package/src/internal/shim-types.ts +26 -0
- package/src/internal/shims.ts +107 -0
- package/src/internal/to-file.ts +154 -0
- package/src/internal/types.ts +95 -0
- package/src/internal/uploads.ts +187 -0
- package/src/internal/utils/base64.ts +40 -0
- package/src/internal/utils/bytes.ts +32 -0
- package/src/internal/utils/env.ts +18 -0
- package/src/internal/utils/log.ts +126 -0
- package/src/internal/utils/path.ts +88 -0
- package/src/internal/utils/sleep.ts +3 -0
- package/src/internal/utils/uuid.ts +17 -0
- package/src/internal/utils/values.ts +105 -0
- package/src/internal/utils.ts +8 -0
- package/src/resource.ts +2 -11
- package/src/resources/call.ts +19 -38
- package/src/resources/evaluation.ts +21 -37
- package/src/resources/health.ts +4 -3
- package/src/resources/integrations.ts +7 -6
- package/src/resources/metric.ts +4 -3
- package/src/resources/persona.ts +16 -29
- package/src/resources/simulation.ts +22 -43
- package/src/tsconfig.json +2 -2
- package/src/uploads.ts +2 -255
- package/src/version.ts +1 -1
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +1 -74
- package/uploads.d.ts.map +1 -1
- package/uploads.js +3 -168
- package/uploads.js.map +1 -1
- package/uploads.mjs +1 -157
- package/uploads.mjs.map +1 -1
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/_shims/MultipartBody.d.ts +0 -9
- package/_shims/MultipartBody.d.ts.map +0 -1
- package/_shims/MultipartBody.js +0 -16
- package/_shims/MultipartBody.js.map +0 -1
- package/_shims/MultipartBody.mjs +0 -12
- package/_shims/MultipartBody.mjs.map +0 -1
- package/_shims/README.md +0 -46
- package/_shims/auto/runtime-bun.d.ts +0 -5
- package/_shims/auto/runtime-bun.d.ts.map +0 -1
- package/_shims/auto/runtime-bun.js +0 -21
- package/_shims/auto/runtime-bun.js.map +0 -1
- package/_shims/auto/runtime-bun.mjs +0 -2
- package/_shims/auto/runtime-bun.mjs.map +0 -1
- package/_shims/auto/runtime-node.d.ts +0 -5
- package/_shims/auto/runtime-node.d.ts.map +0 -1
- package/_shims/auto/runtime-node.js +0 -21
- package/_shims/auto/runtime-node.js.map +0 -1
- package/_shims/auto/runtime-node.mjs +0 -2
- package/_shims/auto/runtime-node.mjs.map +0 -1
- package/_shims/auto/runtime.d.ts +0 -5
- package/_shims/auto/runtime.d.ts.map +0 -1
- package/_shims/auto/runtime.js +0 -21
- package/_shims/auto/runtime.js.map +0 -1
- package/_shims/auto/runtime.mjs +0 -2
- package/_shims/auto/runtime.mjs.map +0 -1
- package/_shims/auto/types-node.d.ts +0 -5
- package/_shims/auto/types-node.d.ts.map +0 -1
- package/_shims/auto/types-node.js +0 -21
- package/_shims/auto/types-node.js.map +0 -1
- package/_shims/auto/types-node.mjs +0 -2
- package/_shims/auto/types-node.mjs.map +0 -1
- package/_shims/auto/types.d.ts +0 -101
- package/_shims/auto/types.js +0 -3
- package/_shims/auto/types.mjs +0 -3
- package/_shims/bun-runtime.d.ts +0 -6
- package/_shims/bun-runtime.d.ts.map +0 -1
- package/_shims/bun-runtime.js +0 -14
- package/_shims/bun-runtime.js.map +0 -1
- package/_shims/bun-runtime.mjs +0 -10
- package/_shims/bun-runtime.mjs.map +0 -1
- package/_shims/index.d.ts +0 -83
- package/_shims/index.js +0 -17
- package/_shims/index.mjs +0 -11
- package/_shims/manual-types.d.ts +0 -12
- package/_shims/manual-types.js +0 -3
- package/_shims/manual-types.mjs +0 -3
- package/_shims/node-runtime.d.ts +0 -3
- package/_shims/node-runtime.d.ts.map +0 -1
- package/_shims/node-runtime.js +0 -89
- package/_shims/node-runtime.js.map +0 -1
- package/_shims/node-runtime.mjs +0 -56
- package/_shims/node-runtime.mjs.map +0 -1
- package/_shims/node-types.d.ts +0 -42
- package/_shims/node-types.js +0 -3
- package/_shims/node-types.mjs +0 -3
- package/_shims/registry.d.ts +0 -37
- package/_shims/registry.d.ts.map +0 -1
- package/_shims/registry.js +0 -41
- package/_shims/registry.js.map +0 -1
- package/_shims/registry.mjs +0 -37
- package/_shims/registry.mjs.map +0 -1
- package/_shims/web-runtime.d.ts +0 -5
- package/_shims/web-runtime.d.ts.map +0 -1
- package/_shims/web-runtime.js +0 -78
- package/_shims/web-runtime.js.map +0 -1
- package/_shims/web-runtime.mjs +0 -71
- package/_shims/web-runtime.mjs.map +0 -1
- package/_shims/web-types.d.ts +0 -83
- package/_shims/web-types.js +0 -3
- package/_shims/web-types.mjs +0 -3
- package/core.d.ts +0 -255
- package/core.d.ts.map +0 -1
- package/core.js +0 -929
- package/core.js.map +0 -1
- package/core.mjs +0 -897
- package/core.mjs.map +0 -1
- package/shims/node.d.ts +0 -30
- package/shims/node.d.ts.map +0 -1
- package/shims/node.js +0 -31
- package/shims/node.js.map +0 -1
- package/shims/node.mjs +0 -5
- package/shims/node.mjs.map +0 -1
- package/shims/web.d.ts +0 -26
- package/shims/web.d.ts.map +0 -1
- package/shims/web.js +0 -31
- package/shims/web.js.map +0 -1
- package/shims/web.mjs +0 -5
- package/shims/web.mjs.map +0 -1
- package/src/_shims/MultipartBody.ts +0 -9
- package/src/_shims/README.md +0 -46
- package/src/_shims/auto/runtime-bun.ts +0 -4
- package/src/_shims/auto/runtime-node.ts +0 -4
- package/src/_shims/auto/runtime.ts +0 -4
- package/src/_shims/auto/types-node.ts +0 -4
- package/src/_shims/auto/types.d.ts +0 -101
- package/src/_shims/auto/types.js +0 -3
- package/src/_shims/auto/types.mjs +0 -3
- package/src/_shims/bun-runtime.ts +0 -14
- package/src/_shims/index.d.ts +0 -83
- package/src/_shims/index.js +0 -17
- package/src/_shims/index.mjs +0 -11
- package/src/_shims/manual-types.d.ts +0 -12
- package/src/_shims/manual-types.js +0 -3
- package/src/_shims/manual-types.mjs +0 -3
- package/src/_shims/node-runtime.ts +0 -81
- package/src/_shims/node-types.d.ts +0 -42
- package/src/_shims/node-types.js +0 -3
- package/src/_shims/node-types.mjs +0 -3
- package/src/_shims/registry.ts +0 -67
- package/src/_shims/web-runtime.ts +0 -103
- package/src/_shims/web-types.d.ts +0 -83
- package/src/_shims/web-types.js +0 -3
- package/src/_shims/web-types.mjs +0 -3
- package/src/core.ts +0 -1242
- package/src/shims/node.ts +0 -50
- package/src/shims/web.ts +0 -50
|
@@ -0,0 +1,1207 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../internal/request-options.mjs";
|
|
4
|
+
export declare class Call extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Create a new call with recording, transcript, agents, and customers
|
|
7
|
+
*/
|
|
8
|
+
create(body: CallCreateParams, options?: RequestOptions): APIPromise<CallCreateResponse>;
|
|
9
|
+
/**
|
|
10
|
+
* Returns a paginated list of calls for the authenticated project.
|
|
11
|
+
*/
|
|
12
|
+
list(query?: CallListParams | null | undefined, options?: RequestOptions): APIPromise<CallListResponse>;
|
|
13
|
+
/**
|
|
14
|
+
* Retrieve an existing call by its unique identifier
|
|
15
|
+
*/
|
|
16
|
+
getByID(callID: string, options?: RequestOptions): APIPromise<CallGetByIDResponse>;
|
|
17
|
+
/**
|
|
18
|
+
* Fetch all evaluation run results for a specific call.
|
|
19
|
+
*/
|
|
20
|
+
listEvaluationRuns(callID: string, options?: RequestOptions): APIPromise<CallListEvaluationRunsResponse>;
|
|
21
|
+
/**
|
|
22
|
+
* Fetch all call-level metrics for a specific call, including both
|
|
23
|
+
* system-generated and custom metrics. Only returns successfully computed metrics.
|
|
24
|
+
*/
|
|
25
|
+
listMetrics(callID: string, query?: CallListMetricsParams | null | undefined, options?: RequestOptions): APIPromise<CallListMetricsResponse>;
|
|
26
|
+
/**
|
|
27
|
+
* Fetch detailed sentiment analysis results for a specific call, including
|
|
28
|
+
* emotional tone, key phrases, and sentiment scores.
|
|
29
|
+
*/
|
|
30
|
+
listSentimentRuns(callID: string, options?: RequestOptions): APIPromise<CallListSentimentRunsResponse>;
|
|
31
|
+
}
|
|
32
|
+
export interface CallCreateResponse {
|
|
33
|
+
/**
|
|
34
|
+
* Response after creating a call
|
|
35
|
+
*/
|
|
36
|
+
data: CallCreateResponse.Data;
|
|
37
|
+
}
|
|
38
|
+
export declare namespace CallCreateResponse {
|
|
39
|
+
/**
|
|
40
|
+
* Response after creating a call
|
|
41
|
+
*/
|
|
42
|
+
interface Data {
|
|
43
|
+
/**
|
|
44
|
+
* Unique identifier for the call
|
|
45
|
+
*/
|
|
46
|
+
id: string;
|
|
47
|
+
agents: Array<Data.Agent> | null;
|
|
48
|
+
/**
|
|
49
|
+
* Direction of the call (inbound or outbound)
|
|
50
|
+
*/
|
|
51
|
+
callDirection: 'INBOUND' | 'OUTBOUND';
|
|
52
|
+
createdAt: string | null;
|
|
53
|
+
customers: Array<Data.Customer> | null;
|
|
54
|
+
/**
|
|
55
|
+
* ID of the project this call belongs to
|
|
56
|
+
*/
|
|
57
|
+
projectId: string;
|
|
58
|
+
/**
|
|
59
|
+
* Timestamp when the call started
|
|
60
|
+
*/
|
|
61
|
+
startedAt: string;
|
|
62
|
+
status: 'RINGING' | 'IN_PROGRESS' | 'ENDED' | null;
|
|
63
|
+
}
|
|
64
|
+
namespace Data {
|
|
65
|
+
interface Agent {
|
|
66
|
+
id: string;
|
|
67
|
+
endpoint?: Agent.Endpoint | null;
|
|
68
|
+
}
|
|
69
|
+
namespace Agent {
|
|
70
|
+
interface Endpoint {
|
|
71
|
+
id: string;
|
|
72
|
+
environment: string;
|
|
73
|
+
phoneNumberE164?: string | null;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
interface Customer {
|
|
77
|
+
label?: string | null;
|
|
78
|
+
phoneNumberE164?: string | null;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
export interface CallListResponse {
|
|
83
|
+
data: Array<CallListResponse.Data>;
|
|
84
|
+
pagination: CallListResponse.Pagination;
|
|
85
|
+
}
|
|
86
|
+
export declare namespace CallListResponse {
|
|
87
|
+
/**
|
|
88
|
+
* Response containing call information
|
|
89
|
+
*/
|
|
90
|
+
interface Data {
|
|
91
|
+
/**
|
|
92
|
+
* Unique identifier for the call
|
|
93
|
+
*/
|
|
94
|
+
id: string;
|
|
95
|
+
/**
|
|
96
|
+
* Direction of the call (inbound or outbound)
|
|
97
|
+
*/
|
|
98
|
+
callDirection: 'INBOUND' | 'OUTBOUND';
|
|
99
|
+
/**
|
|
100
|
+
* ID of the project this call belongs to
|
|
101
|
+
*/
|
|
102
|
+
projectId: string;
|
|
103
|
+
/**
|
|
104
|
+
* Timestamp when the call started
|
|
105
|
+
*/
|
|
106
|
+
startedAt: string;
|
|
107
|
+
/**
|
|
108
|
+
* Agent information
|
|
109
|
+
*/
|
|
110
|
+
agents?: Array<Data.Agent> | null;
|
|
111
|
+
/**
|
|
112
|
+
* Timestamp when the call record was created
|
|
113
|
+
*/
|
|
114
|
+
createdAt?: string | null;
|
|
115
|
+
/**
|
|
116
|
+
* Customer information
|
|
117
|
+
*/
|
|
118
|
+
customers?: Array<Data.Customer> | null;
|
|
119
|
+
/**
|
|
120
|
+
* Duration of the call in milliseconds
|
|
121
|
+
*/
|
|
122
|
+
durationMs?: number | null;
|
|
123
|
+
/**
|
|
124
|
+
* Timestamp when the call ended
|
|
125
|
+
*/
|
|
126
|
+
endedAt?: string | null;
|
|
127
|
+
/**
|
|
128
|
+
* Status indicating how the call ended
|
|
129
|
+
*/
|
|
130
|
+
endedStatus?: 'PARTICIPANTS_DID_NOT_SPEAK' | 'AGENT_DID_NOT_ANSWER' | 'AGENT_DID_NOT_SPEAK' | 'AGENT_STOPPED_SPEAKING' | 'AGENT_ENDED_CALL' | 'AGENT_TRANSFERRED_CALL' | 'AGENT_BUSY' | 'AGENT_ERROR' | 'CUSTOMER_ENDED_CALL' | 'VOICE_MAIL_REACHED' | 'SILENCE_TIME_OUT' | 'PHONE_CALL_PROVIDER_CONNECTION_ERROR' | 'CUSTOMER_DID_NOT_ANSWER' | 'CUSTOMER_DID_NOT_SPEAK' | 'CUSTOMER_STOPPED_SPEAKING' | 'CUSTOMER_BUSY' | 'DIAL_ERROR' | 'MAX_DURATION_REACHED' | 'UNKNOWN' | null;
|
|
131
|
+
/**
|
|
132
|
+
* Custom properties associated with the call
|
|
133
|
+
*/
|
|
134
|
+
properties?: {
|
|
135
|
+
[key: string]: unknown;
|
|
136
|
+
} | null;
|
|
137
|
+
/**
|
|
138
|
+
* Pre-signed URL to the call recording (expires in 1 hour)
|
|
139
|
+
*/
|
|
140
|
+
recordingUrl?: string | null;
|
|
141
|
+
/**
|
|
142
|
+
* ID of the simulation job if this call was generated by a simulation
|
|
143
|
+
*/
|
|
144
|
+
simulationJobId?: string | null;
|
|
145
|
+
/**
|
|
146
|
+
* Current status of the call
|
|
147
|
+
*/
|
|
148
|
+
status?: 'RINGING' | 'IN_PROGRESS' | 'ENDED' | null;
|
|
149
|
+
/**
|
|
150
|
+
* Auto-generated summary of the call conversation
|
|
151
|
+
*/
|
|
152
|
+
summary?: string | null;
|
|
153
|
+
/**
|
|
154
|
+
* ID of the call that superseded this one (if applicable)
|
|
155
|
+
*/
|
|
156
|
+
supersededByCallId?: string | null;
|
|
157
|
+
/**
|
|
158
|
+
* Auto-generated title for the call based on content
|
|
159
|
+
*/
|
|
160
|
+
title?: string | null;
|
|
161
|
+
/**
|
|
162
|
+
* Timestamp when the call record was last updated
|
|
163
|
+
*/
|
|
164
|
+
updatedAt?: string | null;
|
|
165
|
+
}
|
|
166
|
+
namespace Data {
|
|
167
|
+
interface Agent {
|
|
168
|
+
id: string;
|
|
169
|
+
endpoint?: Agent.Endpoint | null;
|
|
170
|
+
}
|
|
171
|
+
namespace Agent {
|
|
172
|
+
interface Endpoint {
|
|
173
|
+
id: string;
|
|
174
|
+
environment: string;
|
|
175
|
+
phoneNumberE164?: string | null;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
interface Customer {
|
|
179
|
+
label?: string | null;
|
|
180
|
+
phoneNumberE164?: string | null;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
interface Pagination {
|
|
184
|
+
/**
|
|
185
|
+
* Whether there are more items to fetch
|
|
186
|
+
*/
|
|
187
|
+
hasMore: boolean;
|
|
188
|
+
/**
|
|
189
|
+
* Cursor for the next page of items
|
|
190
|
+
*/
|
|
191
|
+
nextCursor: string | null;
|
|
192
|
+
/**
|
|
193
|
+
* Total number of items
|
|
194
|
+
*/
|
|
195
|
+
total: number;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
export interface CallGetByIDResponse {
|
|
199
|
+
/**
|
|
200
|
+
* Response containing call information
|
|
201
|
+
*/
|
|
202
|
+
data: CallGetByIDResponse.Data;
|
|
203
|
+
}
|
|
204
|
+
export declare namespace CallGetByIDResponse {
|
|
205
|
+
/**
|
|
206
|
+
* Response containing call information
|
|
207
|
+
*/
|
|
208
|
+
interface Data {
|
|
209
|
+
/**
|
|
210
|
+
* Unique identifier for the call
|
|
211
|
+
*/
|
|
212
|
+
id: string;
|
|
213
|
+
/**
|
|
214
|
+
* Direction of the call (inbound or outbound)
|
|
215
|
+
*/
|
|
216
|
+
callDirection: 'INBOUND' | 'OUTBOUND';
|
|
217
|
+
/**
|
|
218
|
+
* ID of the project this call belongs to
|
|
219
|
+
*/
|
|
220
|
+
projectId: string;
|
|
221
|
+
/**
|
|
222
|
+
* Timestamp when the call started
|
|
223
|
+
*/
|
|
224
|
+
startedAt: string;
|
|
225
|
+
/**
|
|
226
|
+
* Agent information
|
|
227
|
+
*/
|
|
228
|
+
agents?: Array<Data.Agent> | null;
|
|
229
|
+
/**
|
|
230
|
+
* Timestamp when the call record was created
|
|
231
|
+
*/
|
|
232
|
+
createdAt?: string | null;
|
|
233
|
+
/**
|
|
234
|
+
* Customer information
|
|
235
|
+
*/
|
|
236
|
+
customers?: Array<Data.Customer> | null;
|
|
237
|
+
/**
|
|
238
|
+
* Duration of the call in milliseconds
|
|
239
|
+
*/
|
|
240
|
+
durationMs?: number | null;
|
|
241
|
+
/**
|
|
242
|
+
* Timestamp when the call ended
|
|
243
|
+
*/
|
|
244
|
+
endedAt?: string | null;
|
|
245
|
+
/**
|
|
246
|
+
* Status indicating how the call ended
|
|
247
|
+
*/
|
|
248
|
+
endedStatus?: 'PARTICIPANTS_DID_NOT_SPEAK' | 'AGENT_DID_NOT_ANSWER' | 'AGENT_DID_NOT_SPEAK' | 'AGENT_STOPPED_SPEAKING' | 'AGENT_ENDED_CALL' | 'AGENT_TRANSFERRED_CALL' | 'AGENT_BUSY' | 'AGENT_ERROR' | 'CUSTOMER_ENDED_CALL' | 'VOICE_MAIL_REACHED' | 'SILENCE_TIME_OUT' | 'PHONE_CALL_PROVIDER_CONNECTION_ERROR' | 'CUSTOMER_DID_NOT_ANSWER' | 'CUSTOMER_DID_NOT_SPEAK' | 'CUSTOMER_STOPPED_SPEAKING' | 'CUSTOMER_BUSY' | 'DIAL_ERROR' | 'MAX_DURATION_REACHED' | 'UNKNOWN' | null;
|
|
249
|
+
/**
|
|
250
|
+
* Custom properties associated with the call
|
|
251
|
+
*/
|
|
252
|
+
properties?: {
|
|
253
|
+
[key: string]: unknown;
|
|
254
|
+
} | null;
|
|
255
|
+
/**
|
|
256
|
+
* Pre-signed URL to the call recording (expires in 1 hour)
|
|
257
|
+
*/
|
|
258
|
+
recordingUrl?: string | null;
|
|
259
|
+
/**
|
|
260
|
+
* ID of the simulation job if this call was generated by a simulation
|
|
261
|
+
*/
|
|
262
|
+
simulationJobId?: string | null;
|
|
263
|
+
/**
|
|
264
|
+
* Current status of the call
|
|
265
|
+
*/
|
|
266
|
+
status?: 'RINGING' | 'IN_PROGRESS' | 'ENDED' | null;
|
|
267
|
+
/**
|
|
268
|
+
* Auto-generated summary of the call conversation
|
|
269
|
+
*/
|
|
270
|
+
summary?: string | null;
|
|
271
|
+
/**
|
|
272
|
+
* ID of the call that superseded this one (if applicable)
|
|
273
|
+
*/
|
|
274
|
+
supersededByCallId?: string | null;
|
|
275
|
+
/**
|
|
276
|
+
* Auto-generated title for the call based on content
|
|
277
|
+
*/
|
|
278
|
+
title?: string | null;
|
|
279
|
+
/**
|
|
280
|
+
* Timestamp when the call record was last updated
|
|
281
|
+
*/
|
|
282
|
+
updatedAt?: string | null;
|
|
283
|
+
}
|
|
284
|
+
namespace Data {
|
|
285
|
+
interface Agent {
|
|
286
|
+
id: string;
|
|
287
|
+
endpoint?: Agent.Endpoint | null;
|
|
288
|
+
}
|
|
289
|
+
namespace Agent {
|
|
290
|
+
interface Endpoint {
|
|
291
|
+
id: string;
|
|
292
|
+
environment: string;
|
|
293
|
+
phoneNumberE164?: string | null;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
interface Customer {
|
|
297
|
+
label?: string | null;
|
|
298
|
+
phoneNumberE164?: string | null;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
export interface CallListEvaluationRunsResponse {
|
|
303
|
+
/**
|
|
304
|
+
* Evaluation run response payload
|
|
305
|
+
*/
|
|
306
|
+
data: Array<CallListEvaluationRunsResponse.Data>;
|
|
307
|
+
}
|
|
308
|
+
export declare namespace CallListEvaluationRunsResponse {
|
|
309
|
+
interface Data {
|
|
310
|
+
/**
|
|
311
|
+
* All block runs for this evaluator, including skipped ones
|
|
312
|
+
*/
|
|
313
|
+
blockRuns: Array<Data.BlockRun>;
|
|
314
|
+
evaluator: Data.Evaluator;
|
|
315
|
+
evidence: Array<Data.Evidence>;
|
|
316
|
+
metrics: Array<Data.Metric>;
|
|
317
|
+
/**
|
|
318
|
+
* Status of the evaluator run
|
|
319
|
+
*/
|
|
320
|
+
status: 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'FAILED';
|
|
321
|
+
/**
|
|
322
|
+
* ID of the evaluator run
|
|
323
|
+
*/
|
|
324
|
+
id?: string;
|
|
325
|
+
/**
|
|
326
|
+
* When the evaluator run completed
|
|
327
|
+
*/
|
|
328
|
+
completedAt?: string | null;
|
|
329
|
+
/**
|
|
330
|
+
* Result of the evaluator run based on score threshold (IRRELEVANT is mapped to
|
|
331
|
+
* SKIPPED)
|
|
332
|
+
*/
|
|
333
|
+
result?: 'SUCCESS' | 'FAILURE' | 'SKIPPED' | null;
|
|
334
|
+
/**
|
|
335
|
+
* Score of the evaluation run (0-1)
|
|
336
|
+
*/
|
|
337
|
+
score?: number | null;
|
|
338
|
+
/**
|
|
339
|
+
* When the evaluator run started
|
|
340
|
+
*/
|
|
341
|
+
startedAt?: string | null;
|
|
342
|
+
/**
|
|
343
|
+
* Summary of the evaluation run
|
|
344
|
+
*/
|
|
345
|
+
summary?: string | null;
|
|
346
|
+
}
|
|
347
|
+
namespace Data {
|
|
348
|
+
interface BlockRun {
|
|
349
|
+
/**
|
|
350
|
+
* ID of the block definition
|
|
351
|
+
*/
|
|
352
|
+
blockDefinitionId: string;
|
|
353
|
+
/**
|
|
354
|
+
* Name of the evaluation block
|
|
355
|
+
*/
|
|
356
|
+
blockName: string;
|
|
357
|
+
/**
|
|
358
|
+
* ID of the block run instance
|
|
359
|
+
*/
|
|
360
|
+
blockRunId: string;
|
|
361
|
+
/**
|
|
362
|
+
* When the block run was created
|
|
363
|
+
*/
|
|
364
|
+
createdAt: string;
|
|
365
|
+
/**
|
|
366
|
+
* Reason for the outcome (pass/fail explanation or skip reason)
|
|
367
|
+
*/
|
|
368
|
+
reason: string | null;
|
|
369
|
+
/**
|
|
370
|
+
* Result of the block run
|
|
371
|
+
*/
|
|
372
|
+
result: 'PASSED' | 'FAILED' | 'SKIPPED' | null;
|
|
373
|
+
/**
|
|
374
|
+
* Score of the block run (0-1)
|
|
375
|
+
*/
|
|
376
|
+
score: number | null;
|
|
377
|
+
/**
|
|
378
|
+
* Status of the block run
|
|
379
|
+
*/
|
|
380
|
+
status: 'PENDING' | 'RUNNING' | 'COMPLETED' | 'FAILED';
|
|
381
|
+
}
|
|
382
|
+
interface Evaluator {
|
|
383
|
+
/**
|
|
384
|
+
* ID of the evaluator
|
|
385
|
+
*/
|
|
386
|
+
id: string;
|
|
387
|
+
/**
|
|
388
|
+
* Name of the evaluator
|
|
389
|
+
*/
|
|
390
|
+
name: string;
|
|
391
|
+
/**
|
|
392
|
+
* Weight of the evaluator
|
|
393
|
+
*/
|
|
394
|
+
weight?: number;
|
|
395
|
+
}
|
|
396
|
+
interface Evidence {
|
|
397
|
+
/**
|
|
398
|
+
* Comment text of the evidence
|
|
399
|
+
*/
|
|
400
|
+
commentText: string | null;
|
|
401
|
+
/**
|
|
402
|
+
* Created at of the evidence
|
|
403
|
+
*/
|
|
404
|
+
createdAt: string;
|
|
405
|
+
/**
|
|
406
|
+
* Is positive of the evidence
|
|
407
|
+
*/
|
|
408
|
+
isPositive: boolean;
|
|
409
|
+
/**
|
|
410
|
+
* Snippet text of the evidence
|
|
411
|
+
*/
|
|
412
|
+
snippetText: string;
|
|
413
|
+
}
|
|
414
|
+
interface Metric {
|
|
415
|
+
/**
|
|
416
|
+
* Boolean value of the metric
|
|
417
|
+
*/
|
|
418
|
+
booleanValue: boolean | null;
|
|
419
|
+
/**
|
|
420
|
+
* Confidence level of the metric (0-1)
|
|
421
|
+
*/
|
|
422
|
+
confidence: number | null;
|
|
423
|
+
/**
|
|
424
|
+
* Created at of the metric
|
|
425
|
+
*/
|
|
426
|
+
createdAt: string;
|
|
427
|
+
/**
|
|
428
|
+
* Name of the metric
|
|
429
|
+
*/
|
|
430
|
+
name: string;
|
|
431
|
+
/**
|
|
432
|
+
* Numeric value of the metric
|
|
433
|
+
*/
|
|
434
|
+
numericValue: number | null;
|
|
435
|
+
/**
|
|
436
|
+
* Reasoning of the metric
|
|
437
|
+
*/
|
|
438
|
+
reasoning: string | null;
|
|
439
|
+
/**
|
|
440
|
+
* Role of the metric
|
|
441
|
+
*/
|
|
442
|
+
role: string;
|
|
443
|
+
/**
|
|
444
|
+
* Text value of the metric
|
|
445
|
+
*/
|
|
446
|
+
textValue: string | null;
|
|
447
|
+
/**
|
|
448
|
+
* Value type of the metric
|
|
449
|
+
*/
|
|
450
|
+
valueType: string;
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
}
|
|
454
|
+
export interface CallListMetricsResponse {
|
|
455
|
+
/**
|
|
456
|
+
* Call metrics response payload grouped by metric definition
|
|
457
|
+
*/
|
|
458
|
+
data: Array<CallListMetricsResponse.Data>;
|
|
459
|
+
}
|
|
460
|
+
export declare namespace CallListMetricsResponse {
|
|
461
|
+
/**
|
|
462
|
+
* Call metric data grouped by metric definition
|
|
463
|
+
*/
|
|
464
|
+
interface Data {
|
|
465
|
+
/**
|
|
466
|
+
* Description of what the metric measures
|
|
467
|
+
*/
|
|
468
|
+
description: string;
|
|
469
|
+
/**
|
|
470
|
+
* Unique identifier for the metric definition
|
|
471
|
+
*/
|
|
472
|
+
metricDefinitionId: string;
|
|
473
|
+
/**
|
|
474
|
+
* Stable metric identifier
|
|
475
|
+
*/
|
|
476
|
+
metricId: string;
|
|
477
|
+
/**
|
|
478
|
+
* Name of the metric
|
|
479
|
+
*/
|
|
480
|
+
name: string;
|
|
481
|
+
/**
|
|
482
|
+
* Whether metric is global or per-participant
|
|
483
|
+
*/
|
|
484
|
+
scope: 'GLOBAL' | 'PER_PARTICIPANT';
|
|
485
|
+
/**
|
|
486
|
+
* Type of value this metric produces
|
|
487
|
+
*/
|
|
488
|
+
type: 'COUNT' | 'NUMERIC' | 'BOOLEAN' | 'SCALE' | 'TEXT' | 'CLASSIFICATION' | 'OFFSET';
|
|
489
|
+
/**
|
|
490
|
+
* Array of metric values (multiple for PER_PARTICIPANT metrics, or multiple
|
|
491
|
+
* segments/turns)
|
|
492
|
+
*/
|
|
493
|
+
values: Array<Data.Value>;
|
|
494
|
+
/**
|
|
495
|
+
* Unit information if applicable
|
|
496
|
+
*/
|
|
497
|
+
unit?: Data.Unit;
|
|
498
|
+
}
|
|
499
|
+
namespace Data {
|
|
500
|
+
interface Value {
|
|
501
|
+
/**
|
|
502
|
+
* ISO 8601 timestamp when the metric was computed
|
|
503
|
+
*/
|
|
504
|
+
computedAt: string;
|
|
505
|
+
/**
|
|
506
|
+
* Confidence score (0-1) for the computed value. Defaults to 1.0 for deterministic
|
|
507
|
+
* metrics.
|
|
508
|
+
*/
|
|
509
|
+
confidence: number;
|
|
510
|
+
/**
|
|
511
|
+
* Context level: CALL (entire call), SEGMENT (single segment), SEGMENT_RANGE
|
|
512
|
+
* (between/across segments)
|
|
513
|
+
*/
|
|
514
|
+
context: 'CALL' | 'SEGMENT' | 'SEGMENT_RANGE';
|
|
515
|
+
/**
|
|
516
|
+
* The metric value (type depends on outputType)
|
|
517
|
+
*/
|
|
518
|
+
value: number | boolean | string;
|
|
519
|
+
/**
|
|
520
|
+
* Starting segment information (for SEGMENT_RANGE context metrics)
|
|
521
|
+
*/
|
|
522
|
+
fromSegment?: Value.FromSegment;
|
|
523
|
+
/**
|
|
524
|
+
* Role of participant (only for PER_PARTICIPANT metrics)
|
|
525
|
+
*/
|
|
526
|
+
participantRole?: 'agent' | 'customer';
|
|
527
|
+
/**
|
|
528
|
+
* Segment information (for SEGMENT context metrics)
|
|
529
|
+
*/
|
|
530
|
+
segment?: Value.Segment;
|
|
531
|
+
/**
|
|
532
|
+
* Ending segment information (for SEGMENT_RANGE context metrics)
|
|
533
|
+
*/
|
|
534
|
+
toSegment?: Value.ToSegment;
|
|
535
|
+
/**
|
|
536
|
+
* Explanation for the metric value (especially useful for AI-computed metrics)
|
|
537
|
+
*/
|
|
538
|
+
valueReasoning?: string;
|
|
539
|
+
}
|
|
540
|
+
namespace Value {
|
|
541
|
+
/**
|
|
542
|
+
* Starting segment information (for SEGMENT_RANGE context metrics)
|
|
543
|
+
*/
|
|
544
|
+
interface FromSegment {
|
|
545
|
+
/**
|
|
546
|
+
* Starting segment ID
|
|
547
|
+
*/
|
|
548
|
+
id: string;
|
|
549
|
+
/**
|
|
550
|
+
* End time offset in milliseconds
|
|
551
|
+
*/
|
|
552
|
+
endOffsetMs: number;
|
|
553
|
+
/**
|
|
554
|
+
* Start time offset in milliseconds
|
|
555
|
+
*/
|
|
556
|
+
startOffsetMs: number;
|
|
557
|
+
/**
|
|
558
|
+
* Starting segment text content
|
|
559
|
+
*/
|
|
560
|
+
text: string;
|
|
561
|
+
}
|
|
562
|
+
/**
|
|
563
|
+
* Segment information (for SEGMENT context metrics)
|
|
564
|
+
*/
|
|
565
|
+
interface Segment {
|
|
566
|
+
/**
|
|
567
|
+
* Segment ID
|
|
568
|
+
*/
|
|
569
|
+
id: string;
|
|
570
|
+
/**
|
|
571
|
+
* End time offset in milliseconds
|
|
572
|
+
*/
|
|
573
|
+
endOffsetMs: number;
|
|
574
|
+
/**
|
|
575
|
+
* Start time offset in milliseconds
|
|
576
|
+
*/
|
|
577
|
+
startOffsetMs: number;
|
|
578
|
+
/**
|
|
579
|
+
* Segment text content
|
|
580
|
+
*/
|
|
581
|
+
text: string;
|
|
582
|
+
}
|
|
583
|
+
/**
|
|
584
|
+
* Ending segment information (for SEGMENT_RANGE context metrics)
|
|
585
|
+
*/
|
|
586
|
+
interface ToSegment {
|
|
587
|
+
/**
|
|
588
|
+
* Ending segment ID
|
|
589
|
+
*/
|
|
590
|
+
id: string;
|
|
591
|
+
/**
|
|
592
|
+
* End time offset in milliseconds
|
|
593
|
+
*/
|
|
594
|
+
endOffsetMs: number;
|
|
595
|
+
/**
|
|
596
|
+
* Start time offset in milliseconds
|
|
597
|
+
*/
|
|
598
|
+
startOffsetMs: number;
|
|
599
|
+
/**
|
|
600
|
+
* Ending segment text content
|
|
601
|
+
*/
|
|
602
|
+
text: string;
|
|
603
|
+
}
|
|
604
|
+
}
|
|
605
|
+
/**
|
|
606
|
+
* Unit information if applicable
|
|
607
|
+
*/
|
|
608
|
+
interface Unit {
|
|
609
|
+
/**
|
|
610
|
+
* Name of the unit
|
|
611
|
+
*/
|
|
612
|
+
name: string;
|
|
613
|
+
/**
|
|
614
|
+
* Symbol for the unit
|
|
615
|
+
*/
|
|
616
|
+
symbol: string | null;
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
}
|
|
620
|
+
export interface CallListSentimentRunsResponse {
|
|
621
|
+
/**
|
|
622
|
+
* Sentiment run response payload
|
|
623
|
+
*/
|
|
624
|
+
data: CallListSentimentRunsResponse.Data;
|
|
625
|
+
}
|
|
626
|
+
export declare namespace CallListSentimentRunsResponse {
|
|
627
|
+
/**
|
|
628
|
+
* Sentiment run response payload
|
|
629
|
+
*/
|
|
630
|
+
interface Data {
|
|
631
|
+
/**
|
|
632
|
+
* Status of the sentiment run
|
|
633
|
+
*/
|
|
634
|
+
status: string;
|
|
635
|
+
/**
|
|
636
|
+
* NEUTRAL / NEGATIVE / POSITIVE
|
|
637
|
+
*/
|
|
638
|
+
averageCategoricalSentiment?: string;
|
|
639
|
+
/**
|
|
640
|
+
* Average sentiment score between 0-1 of the call
|
|
641
|
+
*/
|
|
642
|
+
averageSentiment?: number;
|
|
643
|
+
/**
|
|
644
|
+
* Common emotion of the call
|
|
645
|
+
*/
|
|
646
|
+
commonEmotion?: string;
|
|
647
|
+
}
|
|
648
|
+
}
|
|
649
|
+
export interface CallCreateParams {
|
|
650
|
+
/**
|
|
651
|
+
* Direction of the call (INBOUND or OUTBOUND)
|
|
652
|
+
*/
|
|
653
|
+
callDirection: 'INBOUND' | 'OUTBOUND';
|
|
654
|
+
/**
|
|
655
|
+
* Interface type of the call (PHONE or WEB)
|
|
656
|
+
*/
|
|
657
|
+
interfaceType: 'PHONE' | 'WEB';
|
|
658
|
+
/**
|
|
659
|
+
* URL of source recording (must be an accessible WAV, MP3, or MP4 file). Can be a
|
|
660
|
+
* signed URL.
|
|
661
|
+
*/
|
|
662
|
+
recordingUrl: string;
|
|
663
|
+
/**
|
|
664
|
+
* When the call started (ISO 8601 format)
|
|
665
|
+
*/
|
|
666
|
+
startedAt: string;
|
|
667
|
+
/**
|
|
668
|
+
* Single agent participating in the call. Use this for simpler API when you have
|
|
669
|
+
* only one agent.
|
|
670
|
+
*/
|
|
671
|
+
agent?: CallCreateParams.AgentIdentificationByRoarkID | CallCreateParams.AgentIdentificationByName | CallCreateParams.AgentIdentificationByCustomID;
|
|
672
|
+
/**
|
|
673
|
+
* Agents participating in the call. Each agent requires identification and prompt
|
|
674
|
+
* information.
|
|
675
|
+
*/
|
|
676
|
+
agents?: Array<CallCreateParams.AgentIdentificationByRoarkID | CallCreateParams.AgentIdentificationByName | CallCreateParams.AgentIdentificationByCustomID>;
|
|
677
|
+
/**
|
|
678
|
+
* Single customer participating in the call. Use this for simpler API when you
|
|
679
|
+
* have only one customer.
|
|
680
|
+
*/
|
|
681
|
+
customer?: CallCreateParams.Customer;
|
|
682
|
+
/**
|
|
683
|
+
* Customers participating in the call.
|
|
684
|
+
*/
|
|
685
|
+
customers?: Array<CallCreateParams.Customer>;
|
|
686
|
+
/**
|
|
687
|
+
* High-level call end status, indicating how the call terminated
|
|
688
|
+
*/
|
|
689
|
+
endedStatus?: 'PARTICIPANTS_DID_NOT_SPEAK' | 'AGENT_DID_NOT_ANSWER' | 'AGENT_DID_NOT_SPEAK' | 'AGENT_STOPPED_SPEAKING' | 'AGENT_ENDED_CALL' | 'AGENT_TRANSFERRED_CALL' | 'AGENT_BUSY' | 'AGENT_ERROR' | 'CUSTOMER_ENDED_CALL' | 'VOICE_MAIL_REACHED' | 'SILENCE_TIME_OUT' | 'PHONE_CALL_PROVIDER_CONNECTION_ERROR' | 'CUSTOMER_DID_NOT_ANSWER' | 'CUSTOMER_DID_NOT_SPEAK' | 'CUSTOMER_STOPPED_SPEAKING' | 'CUSTOMER_BUSY' | 'DIAL_ERROR' | 'MAX_DURATION_REACHED' | 'UNKNOWN';
|
|
690
|
+
/**
|
|
691
|
+
* Custom properties to include with the call. These can be used for filtering and
|
|
692
|
+
* will show in the call details page
|
|
693
|
+
*/
|
|
694
|
+
properties?: {
|
|
695
|
+
[key: string]: unknown;
|
|
696
|
+
};
|
|
697
|
+
/**
|
|
698
|
+
* URL of source stereo recording. Must be accessible. Can be a signed URL.
|
|
699
|
+
* Supported formats: WAV, MP3, MP4.
|
|
700
|
+
*/
|
|
701
|
+
stereoRecordingUrl?: string;
|
|
702
|
+
/**
|
|
703
|
+
* List of tool invocations made during the call
|
|
704
|
+
*/
|
|
705
|
+
toolInvocations?: Array<CallCreateParams.ToolInvocation>;
|
|
706
|
+
/**
|
|
707
|
+
* List of transcript entries made during the call
|
|
708
|
+
*/
|
|
709
|
+
transcript?: Array<CallCreateParams.TranscriptEntryAgent | CallCreateParams.TranscriptEntryCustomer>;
|
|
710
|
+
}
|
|
711
|
+
export declare namespace CallCreateParams {
|
|
712
|
+
interface AgentIdentificationByRoarkID {
|
|
713
|
+
/**
|
|
714
|
+
* Existing Roark agent ID
|
|
715
|
+
*/
|
|
716
|
+
roarkId: string;
|
|
717
|
+
/**
|
|
718
|
+
* Endpoint configuration for this agent (optional)
|
|
719
|
+
*/
|
|
720
|
+
endpoint?: AgentIdentificationByRoarkID.AgentEndpointByID | AgentIdentificationByRoarkID.AgentEndpointByValue;
|
|
721
|
+
/**
|
|
722
|
+
* Agent's prompt configuration (optional)
|
|
723
|
+
*/
|
|
724
|
+
prompt?: AgentIdentificationByRoarkID.Prompt;
|
|
725
|
+
}
|
|
726
|
+
namespace AgentIdentificationByRoarkID {
|
|
727
|
+
interface AgentEndpointByID {
|
|
728
|
+
/**
|
|
729
|
+
* Existing Roark endpoint ID
|
|
730
|
+
*/
|
|
731
|
+
id: string;
|
|
732
|
+
}
|
|
733
|
+
/**
|
|
734
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
735
|
+
*/
|
|
736
|
+
interface AgentEndpointByValue {
|
|
737
|
+
/**
|
|
738
|
+
* Type of endpoint (phone or websocket)
|
|
739
|
+
*/
|
|
740
|
+
type: string;
|
|
741
|
+
/**
|
|
742
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
743
|
+
*/
|
|
744
|
+
value: string;
|
|
745
|
+
/**
|
|
746
|
+
* Call direction for this endpoint
|
|
747
|
+
*/
|
|
748
|
+
direction?: string;
|
|
749
|
+
}
|
|
750
|
+
/**
|
|
751
|
+
* Agent's prompt configuration (optional)
|
|
752
|
+
*/
|
|
753
|
+
interface Prompt {
|
|
754
|
+
/**
|
|
755
|
+
* The agent's system prompt used during this call
|
|
756
|
+
*/
|
|
757
|
+
resolvedPrompt: string;
|
|
758
|
+
}
|
|
759
|
+
}
|
|
760
|
+
/**
|
|
761
|
+
* Create a new agent or find existing by customId if provided
|
|
762
|
+
*/
|
|
763
|
+
interface AgentIdentificationByName {
|
|
764
|
+
/**
|
|
765
|
+
* Agent name
|
|
766
|
+
*/
|
|
767
|
+
name: string;
|
|
768
|
+
/**
|
|
769
|
+
* Agent custom ID
|
|
770
|
+
*/
|
|
771
|
+
customId?: string;
|
|
772
|
+
/**
|
|
773
|
+
* Agent description
|
|
774
|
+
*/
|
|
775
|
+
description?: string;
|
|
776
|
+
/**
|
|
777
|
+
* Endpoint configuration for this agent (optional)
|
|
778
|
+
*/
|
|
779
|
+
endpoint?: AgentIdentificationByName.AgentEndpointByID | AgentIdentificationByName.AgentEndpointByValue;
|
|
780
|
+
/**
|
|
781
|
+
* Agent's prompt configuration (optional)
|
|
782
|
+
*/
|
|
783
|
+
prompt?: AgentIdentificationByName.Prompt;
|
|
784
|
+
}
|
|
785
|
+
namespace AgentIdentificationByName {
|
|
786
|
+
interface AgentEndpointByID {
|
|
787
|
+
/**
|
|
788
|
+
* Existing Roark endpoint ID
|
|
789
|
+
*/
|
|
790
|
+
id: string;
|
|
791
|
+
}
|
|
792
|
+
/**
|
|
793
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
794
|
+
*/
|
|
795
|
+
interface AgentEndpointByValue {
|
|
796
|
+
/**
|
|
797
|
+
* Type of endpoint (phone or websocket)
|
|
798
|
+
*/
|
|
799
|
+
type: string;
|
|
800
|
+
/**
|
|
801
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
802
|
+
*/
|
|
803
|
+
value: string;
|
|
804
|
+
/**
|
|
805
|
+
* Call direction for this endpoint
|
|
806
|
+
*/
|
|
807
|
+
direction?: string;
|
|
808
|
+
}
|
|
809
|
+
/**
|
|
810
|
+
* Agent's prompt configuration (optional)
|
|
811
|
+
*/
|
|
812
|
+
interface Prompt {
|
|
813
|
+
/**
|
|
814
|
+
* The agent's system prompt used during this call
|
|
815
|
+
*/
|
|
816
|
+
resolvedPrompt: string;
|
|
817
|
+
}
|
|
818
|
+
}
|
|
819
|
+
interface AgentIdentificationByCustomID {
|
|
820
|
+
/**
|
|
821
|
+
* Existing custom ID for a Roark agent
|
|
822
|
+
*/
|
|
823
|
+
customId: string;
|
|
824
|
+
/**
|
|
825
|
+
* Endpoint configuration for this agent (optional)
|
|
826
|
+
*/
|
|
827
|
+
endpoint?: AgentIdentificationByCustomID.AgentEndpointByID | AgentIdentificationByCustomID.AgentEndpointByValue;
|
|
828
|
+
/**
|
|
829
|
+
* Agent's prompt configuration (optional)
|
|
830
|
+
*/
|
|
831
|
+
prompt?: AgentIdentificationByCustomID.Prompt;
|
|
832
|
+
}
|
|
833
|
+
namespace AgentIdentificationByCustomID {
|
|
834
|
+
interface AgentEndpointByID {
|
|
835
|
+
/**
|
|
836
|
+
* Existing Roark endpoint ID
|
|
837
|
+
*/
|
|
838
|
+
id: string;
|
|
839
|
+
}
|
|
840
|
+
/**
|
|
841
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
842
|
+
*/
|
|
843
|
+
interface AgentEndpointByValue {
|
|
844
|
+
/**
|
|
845
|
+
* Type of endpoint (phone or websocket)
|
|
846
|
+
*/
|
|
847
|
+
type: string;
|
|
848
|
+
/**
|
|
849
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
850
|
+
*/
|
|
851
|
+
value: string;
|
|
852
|
+
/**
|
|
853
|
+
* Call direction for this endpoint
|
|
854
|
+
*/
|
|
855
|
+
direction?: string;
|
|
856
|
+
}
|
|
857
|
+
/**
|
|
858
|
+
* Agent's prompt configuration (optional)
|
|
859
|
+
*/
|
|
860
|
+
interface Prompt {
|
|
861
|
+
/**
|
|
862
|
+
* The agent's system prompt used during this call
|
|
863
|
+
*/
|
|
864
|
+
resolvedPrompt: string;
|
|
865
|
+
}
|
|
866
|
+
}
|
|
867
|
+
interface AgentIdentificationByRoarkID {
|
|
868
|
+
/**
|
|
869
|
+
* Existing Roark agent ID
|
|
870
|
+
*/
|
|
871
|
+
roarkId: string;
|
|
872
|
+
/**
|
|
873
|
+
* Endpoint configuration for this agent (optional)
|
|
874
|
+
*/
|
|
875
|
+
endpoint?: AgentIdentificationByRoarkID.AgentEndpointByID | AgentIdentificationByRoarkID.AgentEndpointByValue;
|
|
876
|
+
/**
|
|
877
|
+
* Agent's prompt configuration (optional)
|
|
878
|
+
*/
|
|
879
|
+
prompt?: AgentIdentificationByRoarkID.Prompt;
|
|
880
|
+
}
|
|
881
|
+
namespace AgentIdentificationByRoarkID {
|
|
882
|
+
interface AgentEndpointByID {
|
|
883
|
+
/**
|
|
884
|
+
* Existing Roark endpoint ID
|
|
885
|
+
*/
|
|
886
|
+
id: string;
|
|
887
|
+
}
|
|
888
|
+
/**
|
|
889
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
890
|
+
*/
|
|
891
|
+
interface AgentEndpointByValue {
|
|
892
|
+
/**
|
|
893
|
+
* Type of endpoint (phone or websocket)
|
|
894
|
+
*/
|
|
895
|
+
type: string;
|
|
896
|
+
/**
|
|
897
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
898
|
+
*/
|
|
899
|
+
value: string;
|
|
900
|
+
/**
|
|
901
|
+
* Call direction for this endpoint
|
|
902
|
+
*/
|
|
903
|
+
direction?: string;
|
|
904
|
+
}
|
|
905
|
+
/**
|
|
906
|
+
* Agent's prompt configuration (optional)
|
|
907
|
+
*/
|
|
908
|
+
interface Prompt {
|
|
909
|
+
/**
|
|
910
|
+
* The agent's system prompt used during this call
|
|
911
|
+
*/
|
|
912
|
+
resolvedPrompt: string;
|
|
913
|
+
}
|
|
914
|
+
}
|
|
915
|
+
/**
|
|
916
|
+
* Create a new agent or find existing by customId if provided
|
|
917
|
+
*/
|
|
918
|
+
interface AgentIdentificationByName {
|
|
919
|
+
/**
|
|
920
|
+
* Agent name
|
|
921
|
+
*/
|
|
922
|
+
name: string;
|
|
923
|
+
/**
|
|
924
|
+
* Agent custom ID
|
|
925
|
+
*/
|
|
926
|
+
customId?: string;
|
|
927
|
+
/**
|
|
928
|
+
* Agent description
|
|
929
|
+
*/
|
|
930
|
+
description?: string;
|
|
931
|
+
/**
|
|
932
|
+
* Endpoint configuration for this agent (optional)
|
|
933
|
+
*/
|
|
934
|
+
endpoint?: AgentIdentificationByName.AgentEndpointByID | AgentIdentificationByName.AgentEndpointByValue;
|
|
935
|
+
/**
|
|
936
|
+
* Agent's prompt configuration (optional)
|
|
937
|
+
*/
|
|
938
|
+
prompt?: AgentIdentificationByName.Prompt;
|
|
939
|
+
}
|
|
940
|
+
namespace AgentIdentificationByName {
|
|
941
|
+
interface AgentEndpointByID {
|
|
942
|
+
/**
|
|
943
|
+
* Existing Roark endpoint ID
|
|
944
|
+
*/
|
|
945
|
+
id: string;
|
|
946
|
+
}
|
|
947
|
+
/**
|
|
948
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
949
|
+
*/
|
|
950
|
+
interface AgentEndpointByValue {
|
|
951
|
+
/**
|
|
952
|
+
* Type of endpoint (phone or websocket)
|
|
953
|
+
*/
|
|
954
|
+
type: string;
|
|
955
|
+
/**
|
|
956
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
957
|
+
*/
|
|
958
|
+
value: string;
|
|
959
|
+
/**
|
|
960
|
+
* Call direction for this endpoint
|
|
961
|
+
*/
|
|
962
|
+
direction?: string;
|
|
963
|
+
}
|
|
964
|
+
/**
|
|
965
|
+
* Agent's prompt configuration (optional)
|
|
966
|
+
*/
|
|
967
|
+
interface Prompt {
|
|
968
|
+
/**
|
|
969
|
+
* The agent's system prompt used during this call
|
|
970
|
+
*/
|
|
971
|
+
resolvedPrompt: string;
|
|
972
|
+
}
|
|
973
|
+
}
|
|
974
|
+
interface AgentIdentificationByCustomID {
|
|
975
|
+
/**
|
|
976
|
+
* Existing custom ID for a Roark agent
|
|
977
|
+
*/
|
|
978
|
+
customId: string;
|
|
979
|
+
/**
|
|
980
|
+
* Endpoint configuration for this agent (optional)
|
|
981
|
+
*/
|
|
982
|
+
endpoint?: AgentIdentificationByCustomID.AgentEndpointByID | AgentIdentificationByCustomID.AgentEndpointByValue;
|
|
983
|
+
/**
|
|
984
|
+
* Agent's prompt configuration (optional)
|
|
985
|
+
*/
|
|
986
|
+
prompt?: AgentIdentificationByCustomID.Prompt;
|
|
987
|
+
}
|
|
988
|
+
namespace AgentIdentificationByCustomID {
|
|
989
|
+
interface AgentEndpointByID {
|
|
990
|
+
/**
|
|
991
|
+
* Existing Roark endpoint ID
|
|
992
|
+
*/
|
|
993
|
+
id: string;
|
|
994
|
+
}
|
|
995
|
+
/**
|
|
996
|
+
* Lookup or create endpoint if one with these values does not exist
|
|
997
|
+
*/
|
|
998
|
+
interface AgentEndpointByValue {
|
|
999
|
+
/**
|
|
1000
|
+
* Type of endpoint (phone or websocket)
|
|
1001
|
+
*/
|
|
1002
|
+
type: string;
|
|
1003
|
+
/**
|
|
1004
|
+
* Endpoint value (phone number in E.164 format or websocket URL)
|
|
1005
|
+
*/
|
|
1006
|
+
value: string;
|
|
1007
|
+
/**
|
|
1008
|
+
* Call direction for this endpoint
|
|
1009
|
+
*/
|
|
1010
|
+
direction?: string;
|
|
1011
|
+
}
|
|
1012
|
+
/**
|
|
1013
|
+
* Agent's prompt configuration (optional)
|
|
1014
|
+
*/
|
|
1015
|
+
interface Prompt {
|
|
1016
|
+
/**
|
|
1017
|
+
* The agent's system prompt used during this call
|
|
1018
|
+
*/
|
|
1019
|
+
resolvedPrompt: string;
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
/**
|
|
1023
|
+
* Single customer participating in the call. Use this for simpler API when you
|
|
1024
|
+
* have only one customer.
|
|
1025
|
+
*/
|
|
1026
|
+
interface Customer {
|
|
1027
|
+
/**
|
|
1028
|
+
* Customer phone number in E.164 format (e.g., +14155551234)
|
|
1029
|
+
*/
|
|
1030
|
+
phoneNumberE164: string | null;
|
|
1031
|
+
/**
|
|
1032
|
+
* Label to identify this customer in the transcript (e.g., "speaker-01",
|
|
1033
|
+
* "speaker-02")
|
|
1034
|
+
*/
|
|
1035
|
+
label?: string | null;
|
|
1036
|
+
}
|
|
1037
|
+
/**
|
|
1038
|
+
* Customer participating in the call
|
|
1039
|
+
*/
|
|
1040
|
+
interface Customer {
|
|
1041
|
+
/**
|
|
1042
|
+
* Customer phone number in E.164 format (e.g., +14155551234)
|
|
1043
|
+
*/
|
|
1044
|
+
phoneNumberE164: string | null;
|
|
1045
|
+
/**
|
|
1046
|
+
* Label to identify this customer in the transcript (e.g., "speaker-01",
|
|
1047
|
+
* "speaker-02")
|
|
1048
|
+
*/
|
|
1049
|
+
label?: string | null;
|
|
1050
|
+
}
|
|
1051
|
+
interface ToolInvocation {
|
|
1052
|
+
/**
|
|
1053
|
+
* Name of the tool that was invoked
|
|
1054
|
+
*/
|
|
1055
|
+
name: string;
|
|
1056
|
+
/**
|
|
1057
|
+
* Parameters provided to the tool during invocation
|
|
1058
|
+
*/
|
|
1059
|
+
parameters: {
|
|
1060
|
+
[key: string]: ToolInvocation.UnionMember0 | unknown;
|
|
1061
|
+
};
|
|
1062
|
+
/**
|
|
1063
|
+
* Result returned by the tool after execution. Can be a string or a JSON object
|
|
1064
|
+
*/
|
|
1065
|
+
result: string | {
|
|
1066
|
+
[key: string]: unknown;
|
|
1067
|
+
};
|
|
1068
|
+
/**
|
|
1069
|
+
* Offset in milliseconds from the start of the call when the tool was invoked
|
|
1070
|
+
*/
|
|
1071
|
+
startOffsetMs: number;
|
|
1072
|
+
/**
|
|
1073
|
+
* Metadata about the agent that invoked this tool - used to match which agent from
|
|
1074
|
+
* the agents array this tool invocation belongs to
|
|
1075
|
+
*/
|
|
1076
|
+
agent?: ToolInvocation.Agent;
|
|
1077
|
+
/**
|
|
1078
|
+
* Description of when the tool should be invoked
|
|
1079
|
+
*/
|
|
1080
|
+
description?: string;
|
|
1081
|
+
/**
|
|
1082
|
+
* Offset in milliseconds from the start of the call when the tool execution
|
|
1083
|
+
* completed. Used to calculate duration of the tool execution
|
|
1084
|
+
*/
|
|
1085
|
+
endOffsetMs?: number;
|
|
1086
|
+
}
|
|
1087
|
+
namespace ToolInvocation {
|
|
1088
|
+
interface UnionMember0 {
|
|
1089
|
+
description?: string;
|
|
1090
|
+
type?: 'string' | 'number' | 'boolean';
|
|
1091
|
+
value?: unknown;
|
|
1092
|
+
}
|
|
1093
|
+
/**
|
|
1094
|
+
* Metadata about the agent that invoked this tool - used to match which agent from
|
|
1095
|
+
* the agents array this tool invocation belongs to
|
|
1096
|
+
*/
|
|
1097
|
+
interface Agent {
|
|
1098
|
+
/**
|
|
1099
|
+
* The custom ID set on the agent
|
|
1100
|
+
*/
|
|
1101
|
+
customId?: string;
|
|
1102
|
+
/**
|
|
1103
|
+
* The Roark ID of the agent
|
|
1104
|
+
*/
|
|
1105
|
+
roarkId?: string;
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
interface TranscriptEntryAgent {
|
|
1109
|
+
endOffsetMs: number;
|
|
1110
|
+
role: 'AGENT';
|
|
1111
|
+
startOffsetMs: number;
|
|
1112
|
+
text: string;
|
|
1113
|
+
/**
|
|
1114
|
+
* Metadata about the agent that spoke this turn - used to match which agent from
|
|
1115
|
+
* the `agents` array this transcript entry belongs to
|
|
1116
|
+
*/
|
|
1117
|
+
agent?: TranscriptEntryAgent.Agent;
|
|
1118
|
+
languageCode?: string;
|
|
1119
|
+
}
|
|
1120
|
+
namespace TranscriptEntryAgent {
|
|
1121
|
+
/**
|
|
1122
|
+
* Metadata about the agent that spoke this turn - used to match which agent from
|
|
1123
|
+
* the `agents` array this transcript entry belongs to
|
|
1124
|
+
*/
|
|
1125
|
+
interface Agent {
|
|
1126
|
+
/**
|
|
1127
|
+
* The custom ID set on the agent
|
|
1128
|
+
*/
|
|
1129
|
+
customId?: string;
|
|
1130
|
+
/**
|
|
1131
|
+
* The Roark ID of the agent
|
|
1132
|
+
*/
|
|
1133
|
+
roarkId?: string;
|
|
1134
|
+
}
|
|
1135
|
+
}
|
|
1136
|
+
interface TranscriptEntryCustomer {
|
|
1137
|
+
endOffsetMs: number;
|
|
1138
|
+
role: 'CUSTOMER';
|
|
1139
|
+
startOffsetMs: number;
|
|
1140
|
+
text: string;
|
|
1141
|
+
/**
|
|
1142
|
+
* Metadata about the customer that spoke this turn - used to match which customer
|
|
1143
|
+
* from the `customers` array this transcript entry belongs to
|
|
1144
|
+
*/
|
|
1145
|
+
customer?: TranscriptEntryCustomer.Customer;
|
|
1146
|
+
languageCode?: string;
|
|
1147
|
+
}
|
|
1148
|
+
namespace TranscriptEntryCustomer {
|
|
1149
|
+
/**
|
|
1150
|
+
* Metadata about the customer that spoke this turn - used to match which customer
|
|
1151
|
+
* from the `customers` array this transcript entry belongs to
|
|
1152
|
+
*/
|
|
1153
|
+
interface Customer {
|
|
1154
|
+
/**
|
|
1155
|
+
* Label matching the `label` field on the `customers` array when creating the call
|
|
1156
|
+
*/
|
|
1157
|
+
label?: string;
|
|
1158
|
+
/**
|
|
1159
|
+
* The phone number of the customer in E.164 format, matching the `phoneNumberE164`
|
|
1160
|
+
* field on the `customers` array when creating the call
|
|
1161
|
+
*/
|
|
1162
|
+
phoneNumberE164?: string;
|
|
1163
|
+
}
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
1166
|
+
export interface CallListParams {
|
|
1167
|
+
/**
|
|
1168
|
+
* Cursor for pagination - use the nextCursor value from a previous response
|
|
1169
|
+
*/
|
|
1170
|
+
after?: string;
|
|
1171
|
+
/**
|
|
1172
|
+
* Maximum number of calls to return (default: 20, max: 100)
|
|
1173
|
+
*/
|
|
1174
|
+
limit?: number;
|
|
1175
|
+
/**
|
|
1176
|
+
* Search text to filter calls by title, summary, or transcript
|
|
1177
|
+
*/
|
|
1178
|
+
searchText?: string;
|
|
1179
|
+
/**
|
|
1180
|
+
* Filter by simulation run plan job ID to get all calls from a specific simulation
|
|
1181
|
+
* batch
|
|
1182
|
+
*/
|
|
1183
|
+
simulationRunPlanJobId?: string;
|
|
1184
|
+
/**
|
|
1185
|
+
* Field to sort by (default: createdAt)
|
|
1186
|
+
*/
|
|
1187
|
+
sortBy?: 'createdAt' | 'startedAt' | 'endedAt' | 'duration' | 'title' | 'status';
|
|
1188
|
+
/**
|
|
1189
|
+
* Sort direction (default: desc)
|
|
1190
|
+
*/
|
|
1191
|
+
sortDirection?: 'asc' | 'desc';
|
|
1192
|
+
/**
|
|
1193
|
+
* Filter by call status
|
|
1194
|
+
*/
|
|
1195
|
+
status?: 'RINGING' | 'IN_PROGRESS' | 'ENDED';
|
|
1196
|
+
}
|
|
1197
|
+
export interface CallListMetricsParams {
|
|
1198
|
+
/**
|
|
1199
|
+
* Whether to return a flat list instead of grouped by metric definition (default:
|
|
1200
|
+
* false)
|
|
1201
|
+
*/
|
|
1202
|
+
flatten?: string;
|
|
1203
|
+
}
|
|
1204
|
+
export declare namespace Call {
|
|
1205
|
+
export { type CallCreateResponse as CallCreateResponse, type CallListResponse as CallListResponse, type CallGetByIDResponse as CallGetByIDResponse, type CallListEvaluationRunsResponse as CallListEvaluationRunsResponse, type CallListMetricsResponse as CallListMetricsResponse, type CallListSentimentRunsResponse as CallListSentimentRunsResponse, type CallCreateParams as CallCreateParams, type CallListParams as CallListParams, type CallListMetricsParams as CallListMetricsParams, };
|
|
1206
|
+
}
|
|
1207
|
+
//# sourceMappingURL=call.d.mts.map
|