@roarkanalytics/sdk 0.329.0 → 0.331.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.
@@ -1,5 +1,134 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  import { APIResource } from '../resource';
4
+ import * as Core from '../core';
4
5
 
5
- export class Integrations extends APIResource {}
6
+ export class Integrations extends APIResource {
7
+ /**
8
+ * Process and upload a Retell call to Roark evaluation
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const response = await client.integrations.createRetellCall(
13
+ * { retellCallEndedPayload: { event: 'bar', call: 'bar' } },
14
+ * );
15
+ * ```
16
+ */
17
+ createRetellCall(
18
+ body: IntegrationCreateRetellCallParams,
19
+ options?: Core.RequestOptions,
20
+ ): Core.APIPromise<IntegrationCreateRetellCallResponse> {
21
+ return this._client.post('/v1/retell/call', { body, ...options });
22
+ }
23
+
24
+ /**
25
+ * Process and upload a VAPI call to Roark evaluation
26
+ *
27
+ * @example
28
+ * ```ts
29
+ * const response = await client.integrations.createVapiCall({
30
+ * vapiEndOfCallReportPayload: {
31
+ * call: 'bar',
32
+ * type: 'bar',
33
+ * status: 'bar',
34
+ * assistant: 'bar',
35
+ * customer: 'bar',
36
+ * phoneNumber: 'bar',
37
+ * artifact: 'bar',
38
+ * startedAt: 'bar',
39
+ * endedAt: 'bar',
40
+ * endedReason: 'bar',
41
+ * },
42
+ * });
43
+ * ```
44
+ */
45
+ createVapiCall(
46
+ body: IntegrationCreateVapiCallParams,
47
+ options?: Core.RequestOptions,
48
+ ): Core.APIPromise<IntegrationCreateVapiCallResponse> {
49
+ return this._client.post('/v1/vapi/call', { body, ...options });
50
+ }
51
+ }
52
+
53
+ export interface IntegrationCreateRetellCallResponse {
54
+ /**
55
+ * Retell call upload response
56
+ */
57
+ data: IntegrationCreateRetellCallResponse.Data;
58
+ }
59
+
60
+ export namespace IntegrationCreateRetellCallResponse {
61
+ /**
62
+ * Retell call upload response
63
+ */
64
+ export interface Data {
65
+ /**
66
+ * ID of the uploaded call
67
+ */
68
+ callId: string;
69
+ }
70
+ }
71
+
72
+ export interface IntegrationCreateVapiCallResponse {
73
+ /**
74
+ * Vapi call upload response
75
+ */
76
+ data: IntegrationCreateVapiCallResponse.Data;
77
+ }
78
+
79
+ export namespace IntegrationCreateVapiCallResponse {
80
+ /**
81
+ * Vapi call upload response
82
+ */
83
+ export interface Data {
84
+ /**
85
+ * ID of the uploaded call
86
+ */
87
+ callId: string;
88
+ }
89
+ }
90
+
91
+ export interface IntegrationCreateRetellCallParams {
92
+ /**
93
+ * Raw Retell data forwarded directly from the Retell call_ended webhook
94
+ */
95
+ retellCallEndedPayload: Record<string, unknown>;
96
+
97
+ /**
98
+ * Optional metadata (key-value pairs) to include with the call. Useful for
99
+ * filtering and display in call details.
100
+ */
101
+ properties?: Record<string, unknown>;
102
+
103
+ /**
104
+ * Skip already imported Retell calls with the same Retell call id.
105
+ */
106
+ skipAlreadyImported?: boolean;
107
+ }
108
+
109
+ export interface IntegrationCreateVapiCallParams {
110
+ /**
111
+ * Raw Vapi data forwarded directly from the Vapi end-of-call-report webhook
112
+ */
113
+ vapiEndOfCallReportPayload: Record<string, unknown>;
114
+
115
+ /**
116
+ * Optional metadata (key-value pairs) to include with the call. Useful for
117
+ * filtering and display in call details.
118
+ */
119
+ properties?: Record<string, unknown>;
120
+
121
+ /**
122
+ * Skip already imported Vapi calls with the same Vapi call id.
123
+ */
124
+ skipAlreadyImported?: boolean;
125
+ }
126
+
127
+ export declare namespace Integrations {
128
+ export {
129
+ type IntegrationCreateRetellCallResponse as IntegrationCreateRetellCallResponse,
130
+ type IntegrationCreateVapiCallResponse as IntegrationCreateVapiCallResponse,
131
+ type IntegrationCreateRetellCallParams as IntegrationCreateRetellCallParams,
132
+ type IntegrationCreateVapiCallParams as IntegrationCreateVapiCallParams,
133
+ };
134
+ }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.329.0'; // x-release-please-version
1
+ export const VERSION = '0.331.0'; // x-release-please-version
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.329.0";
1
+ export declare const VERSION = "0.331.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.329.0'; // x-release-please-version
4
+ exports.VERSION = '0.331.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.329.0'; // x-release-please-version
1
+ export const VERSION = '0.331.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map