twilio 5.4.0 → 5.4.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.
@@ -41,7 +41,7 @@ export interface TranscriptionListInstanceCreateOptions {
41
41
  hints?: string;
42
42
  /** The provider will add punctuation to recognition result */
43
43
  enableAutomaticPunctuation?: boolean;
44
- /** The SID or the unique name of the [IntelligentService](https://www.twilio.com/docs/voice/intelligence/api/service-resource) to process the transcription. */
44
+ /** The SID of the [Voice Intelligence Service](https://www.twilio.com/docs/voice/intelligence/api/service-resource) for persisting transcripts and running post-call Language Operators . */
45
45
  intelligenceService?: string;
46
46
  }
47
47
  export interface TranscriptionContext {
@@ -90,6 +90,7 @@ interface AssistantsKnowledgeResource {
90
90
  status: string;
91
91
  type: string;
92
92
  url: string;
93
+ embedding_model: string;
93
94
  date_created: Date;
94
95
  date_updated: Date;
95
96
  }
@@ -130,6 +131,10 @@ export declare class AssistantsKnowledgeInstance {
130
131
  * The url of the knowledge resource.
131
132
  */
132
133
  url: string;
134
+ /**
135
+ * The embedding model to be used for the knowledge source.
136
+ */
137
+ embeddingModel: string;
133
138
  /**
134
139
  * The date and time in GMT when the Knowledge was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
135
140
  */
@@ -169,6 +174,7 @@ export declare class AssistantsKnowledgeInstance {
169
174
  status: string;
170
175
  type: string;
171
176
  url: string;
177
+ embeddingModel: string;
172
178
  dateCreated: Date;
173
179
  dateUpdated: Date;
174
180
  };
@@ -81,6 +81,7 @@ class AssistantsKnowledgeInstance {
81
81
  this.status = payload.status;
82
82
  this.type = payload.type;
83
83
  this.url = payload.url;
84
+ this.embeddingModel = payload.embedding_model;
84
85
  this.dateCreated = deserialize.iso8601DateTime(payload.date_created);
85
86
  this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated);
86
87
  this._solution = { assistantId, id: id || this.id };
@@ -126,6 +127,7 @@ class AssistantsKnowledgeInstance {
126
127
  status: this.status,
127
128
  type: this.type,
128
129
  url: this.url,
130
+ embeddingModel: this.embeddingModel,
129
131
  dateCreated: this.dateCreated,
130
132
  dateUpdated: this.dateUpdated,
131
133
  };
@@ -41,7 +41,7 @@ export declare class AssistantsV1ServiceKnowledge {
41
41
  /**
42
42
  * The description of knowledge.
43
43
  */
44
- "id"?: string;
44
+ "id": string;
45
45
  /**
46
46
  * The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Knowledge resource.
47
47
  */
@@ -53,7 +53,7 @@ export declare class AssistantsV1ServiceKnowledge {
53
53
  /**
54
54
  * The name of the knowledge source.
55
55
  */
56
- "name"?: string;
56
+ "name": string;
57
57
  /**
58
58
  * The status of processing the knowledge source (\'QUEUED\', \'PROCESSING\', \'COMPLETED\', \'FAILED\')
59
59
  */
@@ -61,19 +61,23 @@ export declare class AssistantsV1ServiceKnowledge {
61
61
  /**
62
62
  * The type of knowledge source (\'Web\', \'Database\', \'Text\', \'File\')
63
63
  */
64
- "type"?: string;
64
+ "type": string;
65
65
  /**
66
66
  * The url of the knowledge resource.
67
67
  */
68
68
  "url"?: string;
69
+ /**
70
+ * The embedding model to be used for the knowledge source.
71
+ */
72
+ "embedding_model"?: string;
69
73
  /**
70
74
  * The date and time in GMT when the Knowledge was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
71
75
  */
72
- "date_created"?: Date;
76
+ "date_created": Date;
73
77
  /**
74
78
  * The date and time in GMT when the Knowledge was last updated specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
75
79
  */
76
- "date_updated"?: Date;
80
+ "date_updated": Date;
77
81
  }
78
82
  export declare class AssistantsV1ServiceSegmentCredential {
79
83
  /**
@@ -27,6 +27,10 @@ export declare class AssistantsV1ServiceCreateKnowledgeRequest {
27
27
  * The type of the knowledge source.
28
28
  */
29
29
  "type": string;
30
+ /**
31
+ * The embedding model to be used for the knowledge source. It\'s required for \'Database\' type but disallowed for other types.
32
+ */
33
+ "embedding_model"?: string;
30
34
  }
31
35
  export declare class AssistantsV1ServiceCreatePolicyRequest {
32
36
  /**
@@ -65,6 +69,10 @@ export declare class AssistantsV1ServiceUpdateKnowledgeRequest {
65
69
  * The description of the knowledge source.
66
70
  */
67
71
  "type"?: string;
72
+ /**
73
+ * The embedding model to be used for the knowledge source. It\'s only applicable to \'Database\' type.
74
+ */
75
+ "embedding_model"?: string;
68
76
  }
69
77
  /**
70
78
  * Options to pass to update a KnowledgeInstance
@@ -197,6 +205,7 @@ interface KnowledgeResource {
197
205
  status: string;
198
206
  type: string;
199
207
  url: string;
208
+ embedding_model: string;
200
209
  date_created: Date;
201
210
  date_updated: Date;
202
211
  }
@@ -237,6 +246,10 @@ export declare class KnowledgeInstance {
237
246
  * The url of the knowledge resource.
238
247
  */
239
248
  url: string;
249
+ /**
250
+ * The embedding model to be used for the knowledge source.
251
+ */
252
+ embeddingModel: string;
240
253
  /**
241
254
  * The date and time in GMT when the Knowledge was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
242
255
  */
@@ -302,6 +315,7 @@ export declare class KnowledgeInstance {
302
315
  status: string;
303
316
  type: string;
304
317
  url: string;
318
+ embeddingModel: string;
305
319
  dateCreated: Date;
306
320
  dateUpdated: Date;
307
321
  };
@@ -127,6 +127,7 @@ class KnowledgeInstance {
127
127
  this.status = payload.status;
128
128
  this.type = payload.type;
129
129
  this.url = payload.url;
130
+ this.embeddingModel = payload.embedding_model;
130
131
  this.dateCreated = deserialize.iso8601DateTime(payload.date_created);
131
132
  this.dateUpdated = deserialize.iso8601DateTime(payload.date_updated);
132
133
  this._solution = { id: id || this.id };
@@ -187,6 +188,7 @@ class KnowledgeInstance {
187
188
  status: this.status,
188
189
  type: this.type,
189
190
  url: this.url,
191
+ embeddingModel: this.embeddingModel,
190
192
  dateCreated: this.dateCreated,
191
193
  dateUpdated: this.dateUpdated,
192
194
  };
@@ -79,12 +79,6 @@ export declare class FlowsPage {
79
79
  export declare class FlowsPageComponent {
80
80
  "label": string;
81
81
  "type": string;
82
- "text"?: string;
83
- "options"?: Array<FlowsPageComponentSelectItem>;
84
- }
85
- export declare class FlowsPageComponentSelectItem {
86
- "id": string;
87
- "title": string;
88
82
  }
89
83
  export declare class ListItem {
90
84
  "id": string;
@@ -16,7 +16,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
16
16
  return (mod && mod.__esModule) ? mod : { "default": mod };
17
17
  };
18
18
  Object.defineProperty(exports, "__esModule", { value: true });
19
- exports.ContentPage = exports.ContentListInstance = exports.ContentInstance = exports.ContentContextImpl = exports.WhatsappCard = exports.WhatsappAuthentication = exports.Types = exports.TwilioText = exports.TwilioQuickReply = exports.TwilioMedia = exports.TwilioLocation = exports.TwilioListPicker = exports.TwilioFlows = exports.TwilioCatalog = exports.TwilioCarousel = exports.TwilioCard = exports.TwilioCallToAction = exports.QuickReplyAction = exports.ListItem = exports.FlowsPageComponentSelectItem = exports.FlowsPageComponent = exports.FlowsPage = exports.ContentCreateRequest = exports.CatalogItem = exports.CarouselCard = exports.CarouselAction = exports.CardAction = exports.CallToActionAction = exports.AuthenticationAction = void 0;
19
+ exports.ContentPage = exports.ContentListInstance = exports.ContentInstance = exports.ContentContextImpl = exports.WhatsappCard = exports.WhatsappAuthentication = exports.Types = exports.TwilioText = exports.TwilioQuickReply = exports.TwilioMedia = exports.TwilioLocation = exports.TwilioListPicker = exports.TwilioFlows = exports.TwilioCatalog = exports.TwilioCarousel = exports.TwilioCard = exports.TwilioCallToAction = exports.QuickReplyAction = exports.ListItem = exports.FlowsPageComponent = exports.FlowsPage = exports.ContentCreateRequest = exports.CatalogItem = exports.CarouselCard = exports.CarouselAction = exports.CardAction = exports.CallToActionAction = exports.AuthenticationAction = void 0;
20
20
  const util_1 = require("util");
21
21
  const Page_1 = __importDefault(require("../../../base/Page"));
22
22
  const deserialize = require("../../../base/deserialize");
@@ -54,9 +54,6 @@ exports.FlowsPage = FlowsPage;
54
54
  class FlowsPageComponent {
55
55
  }
56
56
  exports.FlowsPageComponent = FlowsPageComponent;
57
- class FlowsPageComponentSelectItem {
58
- }
59
- exports.FlowsPageComponentSelectItem = FlowsPageComponentSelectItem;
60
57
  class ListItem {
61
58
  }
62
59
  exports.ListItem = ListItem;
@@ -5,7 +5,7 @@ import Response from "../../../http/response";
5
5
  import V1 from "../V1";
6
6
  export type AddressConfigurationAutoCreationType = "webhook" | "studio" | "default";
7
7
  export type AddressConfigurationMethod = "GET" | "POST";
8
- export type AddressConfigurationType = "sms" | "whatsapp" | "messenger" | "gbm" | "email";
8
+ export type AddressConfigurationType = "sms" | "whatsapp" | "messenger" | "gbm" | "email" | "rcs";
9
9
  /**
10
10
  * Options to pass to update a AddressConfigurationInstance
11
11
  */
@@ -9,7 +9,7 @@ export type WebhookTarget = "webhook" | "flex";
9
9
  export interface WebhookContextUpdateOptions {
10
10
  /** The HTTP method to be used when sending a webhook request. */
11
11
  method?: string;
12
- /** The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onConversationUpdated`, `onConversationRemoved`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved` */
12
+ /** The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onMessageAdd`, `onMessageUpdate`, `onMessageRemove`, `onConversationUpdated`, `onConversationRemoved`, `onConversationAdd`, `onConversationAdded`, `onConversationRemove`, `onConversationUpdate`, `onConversationStateUpdated`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`, `onParticipantAdd`, `onParticipantRemove`, `onParticipantUpdate`, `onDeliveryUpdated`, `onUserAdded`, `onUserUpdate`, `onUserUpdated` */
13
13
  filters?: Array<string>;
14
14
  /** The absolute url the pre-event webhook request should be sent to. */
15
15
  preWebhookUrl?: string;
@@ -87,7 +87,7 @@ export declare class WebhookInstance {
87
87
  accountSid: string;
88
88
  method: WebhookMethod;
89
89
  /**
90
- * The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onConversationUpdated`, `onConversationRemoved`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`
90
+ * The list of webhook event triggers that are enabled for this Service: `onMessageAdded`, `onMessageUpdated`, `onMessageRemoved`, `onMessageAdd`, `onMessageUpdate`, `onMessageRemove`, `onConversationUpdated`, `onConversationRemoved`, `onConversationAdd`, `onConversationAdded`, `onConversationRemove`, `onConversationUpdate`, `onConversationStateUpdated`, `onParticipantAdded`, `onParticipantUpdated`, `onParticipantRemoved`, `onParticipantAdd`, `onParticipantRemove`, `onParticipantUpdate`, `onDeliveryUpdated`, `onUserAdded`, `onUserUpdate`, `onUserUpdated`
91
91
  */
92
92
  filters: Array<string>;
93
93
  /**
@@ -2,7 +2,7 @@ import IamBase from "../IamBase";
2
2
  import Version from "../../base/Version";
3
3
  import { ApiKeyListInstance } from "./v1/apiKey";
4
4
  import { GetApiKeysListInstance } from "./v1/getApiKeys";
5
- import { NewApiKeyListInstance } from "./v1/newApiKey";
5
+ import { KeyListInstance } from "./v1/key";
6
6
  export default class V1 extends Version {
7
7
  /**
8
8
  * Initialize the V1 version of Iam
@@ -14,12 +14,12 @@ export default class V1 extends Version {
14
14
  protected _apiKey?: ApiKeyListInstance;
15
15
  /** getApiKeys - { Twilio.Iam.V1.GetApiKeysListInstance } resource */
16
16
  protected _getApiKeys?: GetApiKeysListInstance;
17
- /** newApiKey - { Twilio.Iam.V1.NewApiKeyListInstance } resource */
18
- protected _newApiKey?: NewApiKeyListInstance;
17
+ /** keys - { Twilio.Iam.V1.KeyListInstance } resource */
18
+ protected _keys?: KeyListInstance;
19
19
  /** Getter for apiKey resource */
20
20
  get apiKey(): ApiKeyListInstance;
21
21
  /** Getter for getApiKeys resource */
22
22
  get getApiKeys(): GetApiKeysListInstance;
23
- /** Getter for newApiKey resource */
24
- get newApiKey(): NewApiKeyListInstance;
23
+ /** Getter for keys resource */
24
+ get keys(): KeyListInstance;
25
25
  }
@@ -19,7 +19,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
19
19
  const Version_1 = __importDefault(require("../../base/Version"));
20
20
  const apiKey_1 = require("./v1/apiKey");
21
21
  const getApiKeys_1 = require("./v1/getApiKeys");
22
- const newApiKey_1 = require("./v1/newApiKey");
22
+ const key_1 = require("./v1/key");
23
23
  class V1 extends Version_1.default {
24
24
  /**
25
25
  * Initialize the V1 version of Iam
@@ -39,10 +39,10 @@ class V1 extends Version_1.default {
39
39
  this._getApiKeys = this._getApiKeys || (0, getApiKeys_1.GetApiKeysListInstance)(this);
40
40
  return this._getApiKeys;
41
41
  }
42
- /** Getter for newApiKey resource */
43
- get newApiKey() {
44
- this._newApiKey = this._newApiKey || (0, newApiKey_1.NewApiKeyListInstance)(this);
45
- return this._newApiKey;
42
+ /** Getter for keys resource */
43
+ get keys() {
44
+ this._keys = this._keys || (0, key_1.KeyListInstance)(this);
45
+ return this._keys;
46
46
  }
47
47
  }
48
48
  exports.default = V1;
@@ -1,43 +1,43 @@
1
1
  /// <reference types="node" />
2
2
  import { inspect, InspectOptions } from "util";
3
3
  import V1 from "../V1";
4
- export type NewApiKeyKeytype = "restricted";
4
+ export type KeyKeytype = "restricted";
5
5
  /**
6
- * Options to pass to create a NewApiKeyInstance
6
+ * Options to pass to create a KeyInstance
7
7
  */
8
- export interface NewApiKeyListInstanceCreateOptions {
8
+ export interface KeyListInstanceCreateOptions {
9
9
  /** The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Payments resource. */
10
10
  accountSid: string;
11
11
  /** A descriptive string that you create to describe the resource. It can be up to 64 characters long. */
12
12
  friendlyName?: string;
13
13
  /** */
14
- keyType?: NewApiKeyKeytype;
14
+ keyType?: KeyKeytype;
15
15
  /** The \\\\`Policy\\\\` object is a collection that specifies the allowed Twilio permissions for the restricted key. For more information on the permissions available with restricted API keys, refer to the [Twilio documentation](https://www.twilio.com/docs/iam/api-keys/restricted-api-keys#permissions-available-with-restricted-api-keys). */
16
16
  policy?: any;
17
17
  }
18
- export interface NewApiKeySolution {
18
+ export interface KeySolution {
19
19
  }
20
- export interface NewApiKeyListInstance {
20
+ export interface KeyListInstance {
21
21
  _version: V1;
22
- _solution: NewApiKeySolution;
22
+ _solution: KeySolution;
23
23
  _uri: string;
24
24
  /**
25
- * Create a NewApiKeyInstance
25
+ * Create a KeyInstance
26
26
  *
27
27
  * @param params - Parameter for request
28
28
  * @param callback - Callback to handle processed record
29
29
  *
30
- * @returns Resolves to processed NewApiKeyInstance
30
+ * @returns Resolves to processed KeyInstance
31
31
  */
32
- create(params: NewApiKeyListInstanceCreateOptions, callback?: (error: Error | null, item?: NewApiKeyInstance) => any): Promise<NewApiKeyInstance>;
32
+ create(params: KeyListInstanceCreateOptions, callback?: (error: Error | null, item?: KeyInstance) => any): Promise<KeyInstance>;
33
33
  /**
34
34
  * Provide a user-friendly representation
35
35
  */
36
36
  toJSON(): any;
37
37
  [inspect.custom](_depth: any, options: InspectOptions): any;
38
38
  }
39
- export declare function NewApiKeyListInstance(version: V1): NewApiKeyListInstance;
40
- interface NewApiKeyResource {
39
+ export declare function KeyListInstance(version: V1): KeyListInstance;
40
+ interface KeyResource {
41
41
  sid: string;
42
42
  friendly_name: string;
43
43
  date_created: Date;
@@ -45,9 +45,9 @@ interface NewApiKeyResource {
45
45
  secret: string;
46
46
  policy: any;
47
47
  }
48
- export declare class NewApiKeyInstance {
48
+ export declare class KeyInstance {
49
49
  protected _version: V1;
50
- constructor(_version: V1, payload: NewApiKeyResource);
50
+ constructor(_version: V1, payload: KeyResource);
51
51
  /**
52
52
  * The unique string that that we created to identify the NewKey resource. You will use this as the basic-auth `user` when authenticating to the API.
53
53
  */
@@ -13,11 +13,11 @@
13
13
  * Do not edit the class manually.
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.NewApiKeyInstance = exports.NewApiKeyListInstance = void 0;
16
+ exports.KeyInstance = exports.KeyListInstance = void 0;
17
17
  const util_1 = require("util");
18
18
  const deserialize = require("../../../base/deserialize");
19
19
  const serialize = require("../../../base/serialize");
20
- function NewApiKeyListInstance(version) {
20
+ function KeyListInstance(version) {
21
21
  const instance = {};
22
22
  instance._version = version;
23
23
  instance._solution = {};
@@ -46,7 +46,7 @@ function NewApiKeyListInstance(version) {
46
46
  data,
47
47
  headers,
48
48
  });
49
- operationPromise = operationPromise.then((payload) => new NewApiKeyInstance(operationVersion, payload));
49
+ operationPromise = operationPromise.then((payload) => new KeyInstance(operationVersion, payload));
50
50
  operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
51
51
  return operationPromise;
52
52
  };
@@ -58,8 +58,8 @@ function NewApiKeyListInstance(version) {
58
58
  };
59
59
  return instance;
60
60
  }
61
- exports.NewApiKeyListInstance = NewApiKeyListInstance;
62
- class NewApiKeyInstance {
61
+ exports.KeyListInstance = KeyListInstance;
62
+ class KeyInstance {
63
63
  constructor(_version, payload) {
64
64
  this._version = _version;
65
65
  this.sid = payload.sid;
@@ -88,4 +88,4 @@ class NewApiKeyInstance {
88
88
  return (0, util_1.inspect)(this.toJSON(), options);
89
89
  }
90
90
  }
91
- exports.NewApiKeyInstance = NewApiKeyInstance;
91
+ exports.KeyInstance = KeyInstance;
@@ -3,7 +3,7 @@ import { inspect, InspectOptions } from "util";
3
3
  import V1 from "../../V1";
4
4
  export type CallSummaryAnsweredBy = "unknown" | "machine_start" | "machine_end_beep" | "machine_end_silence" | "machine_end_other" | "human" | "fax";
5
5
  export type CallSummaryCallState = "ringing" | "completed" | "busy" | "fail" | "noanswer" | "canceled" | "answered" | "undialed";
6
- export type CallSummaryCallType = "carrier" | "sip" | "trunking" | "client";
6
+ export type CallSummaryCallType = "carrier" | "sip" | "trunking" | "client" | "whatsapp";
7
7
  export type CallSummaryProcessingState = "complete" | "partial";
8
8
  /**
9
9
  * Options to pass to fetch a CallSummaryInstance
@@ -5,7 +5,7 @@ import Response from "../../../http/response";
5
5
  import V1 from "../V1";
6
6
  export type CallSummariesAnsweredBy = "unknown" | "machine_start" | "machine_end_beep" | "machine_end_silence" | "machine_end_other" | "human" | "fax";
7
7
  export type CallSummariesCallState = "ringing" | "completed" | "busy" | "fail" | "noanswer" | "canceled" | "answered" | "undialed";
8
- export type CallSummariesCallType = "carrier" | "sip" | "trunking" | "client";
8
+ export type CallSummariesCallType = "carrier" | "sip" | "trunking" | "client" | "whatsapp";
9
9
  export type CallSummariesProcessingState = "complete" | "partial";
10
10
  export type CallSummariesProcessingStateRequest = "completed" | "started" | "partial" | "all";
11
11
  export type CallSummariesSortBy = "start_time" | "end_time";
@@ -2,6 +2,7 @@ import MarketplaceBase from "../MarketplaceBase";
2
2
  import Version from "../../base/Version";
3
3
  import { AvailableAddOnListInstance } from "./v1/availableAddOn";
4
4
  import { InstalledAddOnListInstance } from "./v1/installedAddOn";
5
+ import { ModuleDataListInstance } from "./v1/moduleData";
5
6
  import { ModuleDataManagementListInstance } from "./v1/moduleDataManagement";
6
7
  import { ReferralConversionListInstance } from "./v1/referralConversion";
7
8
  export default class V1 extends Version {
@@ -15,6 +16,8 @@ export default class V1 extends Version {
15
16
  protected _availableAddOns?: AvailableAddOnListInstance;
16
17
  /** installedAddOns - { Twilio.Marketplace.V1.InstalledAddOnListInstance } resource */
17
18
  protected _installedAddOns?: InstalledAddOnListInstance;
19
+ /** moduleData - { Twilio.Marketplace.V1.ModuleDataListInstance } resource */
20
+ protected _moduleData?: ModuleDataListInstance;
18
21
  /** moduleDataManagement - { Twilio.Marketplace.V1.ModuleDataManagementListInstance } resource */
19
22
  protected _moduleDataManagement?: ModuleDataManagementListInstance;
20
23
  /** referralConversion - { Twilio.Marketplace.V1.ReferralConversionListInstance } resource */
@@ -23,6 +26,8 @@ export default class V1 extends Version {
23
26
  get availableAddOns(): AvailableAddOnListInstance;
24
27
  /** Getter for installedAddOns resource */
25
28
  get installedAddOns(): InstalledAddOnListInstance;
29
+ /** Getter for moduleData resource */
30
+ get moduleData(): ModuleDataListInstance;
26
31
  /** Getter for moduleDataManagement resource */
27
32
  get moduleDataManagement(): ModuleDataManagementListInstance;
28
33
  /** Getter for referralConversion resource */
@@ -19,6 +19,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
19
19
  const Version_1 = __importDefault(require("../../base/Version"));
20
20
  const availableAddOn_1 = require("./v1/availableAddOn");
21
21
  const installedAddOn_1 = require("./v1/installedAddOn");
22
+ const moduleData_1 = require("./v1/moduleData");
22
23
  const moduleDataManagement_1 = require("./v1/moduleDataManagement");
23
24
  const referralConversion_1 = require("./v1/referralConversion");
24
25
  class V1 extends Version_1.default {
@@ -42,6 +43,11 @@ class V1 extends Version_1.default {
42
43
  this._installedAddOns || (0, installedAddOn_1.InstalledAddOnListInstance)(this);
43
44
  return this._installedAddOns;
44
45
  }
46
+ /** Getter for moduleData resource */
47
+ get moduleData() {
48
+ this._moduleData = this._moduleData || (0, moduleData_1.ModuleDataListInstance)(this);
49
+ return this._moduleData;
50
+ }
45
51
  /** Getter for moduleDataManagement resource */
46
52
  get moduleDataManagement() {
47
53
  this._moduleDataManagement =
@@ -80,7 +80,7 @@ interface AvailableAddOnResource {
80
80
  friendly_name: string;
81
81
  description: string;
82
82
  pricing_type: string;
83
- configuration_schema: any;
83
+ configuration_schema: Record<string, object>;
84
84
  url: string;
85
85
  links: Record<string, string>;
86
86
  }
@@ -108,7 +108,7 @@ export declare class AvailableAddOnInstance {
108
108
  /**
109
109
  * The JSON object with the configuration that must be provided when installing a given Add-on.
110
110
  */
111
- configurationSchema: any;
111
+ configurationSchema: Record<string, object>;
112
112
  /**
113
113
  * The absolute URL of the resource.
114
114
  */
@@ -140,7 +140,7 @@ export declare class AvailableAddOnInstance {
140
140
  friendlyName: string;
141
141
  description: string;
142
142
  pricingType: string;
143
- configurationSchema: any;
143
+ configurationSchema: Record<string, object>;
144
144
  url: string;
145
145
  links: Record<string, string>;
146
146
  };
@@ -133,7 +133,7 @@ interface InstalledAddOnResource {
133
133
  account_sid: string;
134
134
  friendly_name: string;
135
135
  description: string;
136
- configuration: any;
136
+ configuration: Record<string, object>;
137
137
  unique_name: string;
138
138
  date_created: Date;
139
139
  date_updated: Date;
@@ -164,7 +164,7 @@ export declare class InstalledAddOnInstance {
164
164
  /**
165
165
  * The JSON object that represents the current configuration of installed Add-on.
166
166
  */
167
- configuration: any;
167
+ configuration: Record<string, object>;
168
168
  /**
169
169
  * An application-defined string that uniquely identifies the resource.
170
170
  */
@@ -237,7 +237,7 @@ export declare class InstalledAddOnInstance {
237
237
  accountSid: string;
238
238
  friendlyName: string;
239
239
  description: string;
240
- configuration: any;
240
+ configuration: Record<string, object>;
241
241
  uniqueName: string;
242
242
  dateCreated: Date;
243
243
  dateUpdated: Date;
@@ -0,0 +1,125 @@
1
+ /// <reference types="node" />
2
+ import { inspect, InspectOptions } from "util";
3
+ import V1 from "../V1";
4
+ /**
5
+ * Options to pass to create a ModuleDataInstance
6
+ */
7
+ export interface ModuleDataListInstanceCreateOptions {
8
+ /** A JSON object containing essential attributes that define a Listing. */
9
+ moduleInfo?: string;
10
+ /** A JSON object for providing Listing-specific configuration. Contains button setup, notification URL, and more. */
11
+ configuration?: string;
12
+ }
13
+ export interface ModuleDataSolution {
14
+ }
15
+ export interface ModuleDataListInstance {
16
+ _version: V1;
17
+ _solution: ModuleDataSolution;
18
+ _uri: string;
19
+ /**
20
+ * Create a ModuleDataInstance
21
+ *
22
+ * @param callback - Callback to handle processed record
23
+ *
24
+ * @returns Resolves to processed ModuleDataInstance
25
+ */
26
+ create(callback?: (error: Error | null, item?: ModuleDataInstance) => any): Promise<ModuleDataInstance>;
27
+ /**
28
+ * Create a ModuleDataInstance
29
+ *
30
+ * @param params - Parameter for request
31
+ * @param callback - Callback to handle processed record
32
+ *
33
+ * @returns Resolves to processed ModuleDataInstance
34
+ */
35
+ create(params: ModuleDataListInstanceCreateOptions, callback?: (error: Error | null, item?: ModuleDataInstance) => any): Promise<ModuleDataInstance>;
36
+ /**
37
+ * Fetch a ModuleDataInstance
38
+ *
39
+ * @param callback - Callback to handle processed record
40
+ *
41
+ * @returns Resolves to processed ModuleDataInstance
42
+ */
43
+ fetch(callback?: (error: Error | null, item?: ModuleDataInstance) => any): Promise<ModuleDataInstance>;
44
+ /**
45
+ * Provide a user-friendly representation
46
+ */
47
+ toJSON(): any;
48
+ [inspect.custom](_depth: any, options: InspectOptions): any;
49
+ }
50
+ export declare function ModuleDataListInstance(version: V1): ModuleDataListInstance;
51
+ interface ModuleDataResource {
52
+ url: string;
53
+ sid: string;
54
+ description: Record<string, object>;
55
+ support: Record<string, object>;
56
+ policies: Record<string, object>;
57
+ module_info: Record<string, object>;
58
+ documentation: Record<string, object>;
59
+ configuration: Record<string, object>;
60
+ pricing: Record<string, object>;
61
+ listings: Array<Record<string, object>>;
62
+ }
63
+ export declare class ModuleDataInstance {
64
+ protected _version: V1;
65
+ constructor(_version: V1, payload: ModuleDataResource);
66
+ /**
67
+ * URL to query the subresource.
68
+ */
69
+ url: string;
70
+ /**
71
+ * ModuleSid that identifies this Listing.
72
+ */
73
+ sid: string;
74
+ /**
75
+ * A JSON object describing the module and is displayed under the Description tab of the Module detail page. You can define the main body of the description, highlight key features or aspects of the module and if applicable, provide code samples for developers
76
+ */
77
+ description: Record<string, object>;
78
+ /**
79
+ * A JSON object containing information on how customers can obtain support for the module. Use this parameter to provide details such as contact information and support description.
80
+ */
81
+ support: Record<string, object>;
82
+ /**
83
+ * A JSON object describing the module\'s privacy and legal policies and is displayed under the Policies tab of the Module detail page. The maximum file size for Policies is 5MB
84
+ */
85
+ policies: Record<string, object>;
86
+ /**
87
+ * A JSON object containing essential attributes that define a module. This information is presented on the Module detail page in the Twilio Marketplace Catalog. You can pass the following attributes in the JSON object
88
+ */
89
+ moduleInfo: Record<string, object>;
90
+ /**
91
+ * A JSON object for providing comprehensive information, instructions, and resources related to the module
92
+ */
93
+ documentation: Record<string, object>;
94
+ /**
95
+ * A JSON object for providing listing specific configuration. Contains button setup, notification url, among others.
96
+ */
97
+ configuration: Record<string, object>;
98
+ /**
99
+ * A JSON object for providing Listing specific pricing information.
100
+ */
101
+ pricing: Record<string, object>;
102
+ /**
103
+ *
104
+ */
105
+ listings: Array<Record<string, object>>;
106
+ /**
107
+ * Provide a user-friendly representation
108
+ *
109
+ * @returns Object
110
+ */
111
+ toJSON(): {
112
+ url: string;
113
+ sid: string;
114
+ description: Record<string, object>;
115
+ support: Record<string, object>;
116
+ policies: Record<string, object>;
117
+ moduleInfo: Record<string, object>;
118
+ documentation: Record<string, object>;
119
+ configuration: Record<string, object>;
120
+ pricing: Record<string, object>;
121
+ listings: Record<string, object>[];
122
+ };
123
+ [inspect.custom](_depth: any, options: InspectOptions): string;
124
+ }
125
+ export {};
@@ -0,0 +1,109 @@
1
+ "use strict";
2
+ /*
3
+ * This code was generated by
4
+ * ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
5
+ * | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
6
+ * | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
7
+ *
8
+ * Twilio - Marketplace
9
+ * This is the public Twilio REST API.
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator.
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.ModuleDataInstance = exports.ModuleDataListInstance = void 0;
17
+ const util_1 = require("util");
18
+ const deserialize = require("../../../base/deserialize");
19
+ const serialize = require("../../../base/serialize");
20
+ function ModuleDataListInstance(version) {
21
+ const instance = {};
22
+ instance._version = version;
23
+ instance._solution = {};
24
+ instance._uri = `/Listings`;
25
+ instance.create = function create(params, callback) {
26
+ if (params instanceof Function) {
27
+ callback = params;
28
+ params = {};
29
+ }
30
+ else {
31
+ params = params || {};
32
+ }
33
+ let data = {};
34
+ if (params["moduleInfo"] !== undefined)
35
+ data["ModuleInfo"] = params["moduleInfo"];
36
+ if (params["configuration"] !== undefined)
37
+ data["Configuration"] = params["configuration"];
38
+ const headers = {};
39
+ headers["Content-Type"] = "application/x-www-form-urlencoded";
40
+ headers["Accept"] = "application/json";
41
+ let operationVersion = version, operationPromise = operationVersion.create({
42
+ uri: instance._uri,
43
+ method: "post",
44
+ data,
45
+ headers,
46
+ });
47
+ operationPromise = operationPromise.then((payload) => new ModuleDataInstance(operationVersion, payload));
48
+ operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
49
+ return operationPromise;
50
+ };
51
+ instance.fetch = function fetch(callback) {
52
+ const headers = {};
53
+ headers["Accept"] = "application/json";
54
+ let operationVersion = version, operationPromise = operationVersion.fetch({
55
+ uri: instance._uri,
56
+ method: "get",
57
+ headers,
58
+ });
59
+ operationPromise = operationPromise.then((payload) => new ModuleDataInstance(operationVersion, payload));
60
+ operationPromise = instance._version.setPromiseCallback(operationPromise, callback);
61
+ return operationPromise;
62
+ };
63
+ instance.toJSON = function toJSON() {
64
+ return instance._solution;
65
+ };
66
+ instance[util_1.inspect.custom] = function inspectImpl(_depth, options) {
67
+ return (0, util_1.inspect)(instance.toJSON(), options);
68
+ };
69
+ return instance;
70
+ }
71
+ exports.ModuleDataListInstance = ModuleDataListInstance;
72
+ class ModuleDataInstance {
73
+ constructor(_version, payload) {
74
+ this._version = _version;
75
+ this.url = payload.url;
76
+ this.sid = payload.sid;
77
+ this.description = payload.description;
78
+ this.support = payload.support;
79
+ this.policies = payload.policies;
80
+ this.moduleInfo = payload.module_info;
81
+ this.documentation = payload.documentation;
82
+ this.configuration = payload.configuration;
83
+ this.pricing = payload.pricing;
84
+ this.listings = payload.listings;
85
+ }
86
+ /**
87
+ * Provide a user-friendly representation
88
+ *
89
+ * @returns Object
90
+ */
91
+ toJSON() {
92
+ return {
93
+ url: this.url,
94
+ sid: this.sid,
95
+ description: this.description,
96
+ support: this.support,
97
+ policies: this.policies,
98
+ moduleInfo: this.moduleInfo,
99
+ documentation: this.documentation,
100
+ configuration: this.configuration,
101
+ pricing: this.pricing,
102
+ listings: this.listings,
103
+ };
104
+ }
105
+ [util_1.inspect.custom](_depth, options) {
106
+ return (0, util_1.inspect)(this.toJSON(), options);
107
+ }
108
+ }
109
+ exports.ModuleDataInstance = ModuleDataInstance;
@@ -73,13 +73,14 @@ export declare class ModuleDataManagementContextImpl implements ModuleDataManage
73
73
  interface ModuleDataManagementResource {
74
74
  url: string;
75
75
  sid: string;
76
- description: any;
77
- support: any;
78
- policies: any;
79
- module_info: any;
80
- documentation: any;
81
- configuration: any;
82
- pricing: any;
76
+ description: Record<string, object>;
77
+ support: Record<string, object>;
78
+ policies: Record<string, object>;
79
+ module_info: Record<string, object>;
80
+ documentation: Record<string, object>;
81
+ configuration: Record<string, object>;
82
+ pricing: Record<string, object>;
83
+ listings: Array<Record<string, object>>;
83
84
  }
84
85
  export declare class ModuleDataManagementInstance {
85
86
  protected _version: V1;
@@ -97,31 +98,35 @@ export declare class ModuleDataManagementInstance {
97
98
  /**
98
99
  * A JSON object describing the module and is displayed under the Description tab of the Module detail page. You can define the main body of the description, highlight key features or aspects of the module and if applicable, provide code samples for developers
99
100
  */
100
- description: any;
101
+ description: Record<string, object>;
101
102
  /**
102
103
  * A JSON object containing information on how customers can obtain support for the module. Use this parameter to provide details such as contact information and support description.
103
104
  */
104
- support: any;
105
+ support: Record<string, object>;
105
106
  /**
106
107
  * A JSON object describing the module\'s privacy and legal policies and is displayed under the Policies tab of the Module detail page. The maximum file size for Policies is 5MB
107
108
  */
108
- policies: any;
109
+ policies: Record<string, object>;
109
110
  /**
110
111
  * A JSON object containing essential attributes that define a module. This information is presented on the Module detail page in the Twilio Marketplace Catalog. You can pass the following attributes in the JSON object
111
112
  */
112
- moduleInfo: any;
113
+ moduleInfo: Record<string, object>;
113
114
  /**
114
115
  * A JSON object for providing comprehensive information, instructions, and resources related to the module
115
116
  */
116
- documentation: any;
117
+ documentation: Record<string, object>;
117
118
  /**
118
119
  * A JSON object for providing listing specific configuration. Contains button setup, notification url, among others.
119
120
  */
120
- configuration: any;
121
+ configuration: Record<string, object>;
121
122
  /**
122
123
  * A JSON object for providing Listing specific pricing information.
123
124
  */
124
- pricing: any;
125
+ pricing: Record<string, object>;
126
+ /**
127
+ *
128
+ */
129
+ listings: Array<Record<string, object>>;
125
130
  private get _proxy();
126
131
  /**
127
132
  * Fetch a ModuleDataManagementInstance
@@ -156,13 +161,14 @@ export declare class ModuleDataManagementInstance {
156
161
  toJSON(): {
157
162
  url: string;
158
163
  sid: string;
159
- description: any;
160
- support: any;
161
- policies: any;
162
- moduleInfo: any;
163
- documentation: any;
164
- configuration: any;
165
- pricing: any;
164
+ description: Record<string, object>;
165
+ support: Record<string, object>;
166
+ policies: Record<string, object>;
167
+ moduleInfo: Record<string, object>;
168
+ documentation: Record<string, object>;
169
+ configuration: Record<string, object>;
170
+ pricing: Record<string, object>;
171
+ listings: Record<string, object>[];
166
172
  };
167
173
  [inspect.custom](_depth: any, options: InspectOptions): string;
168
174
  }
@@ -102,6 +102,7 @@ class ModuleDataManagementInstance {
102
102
  this.documentation = payload.documentation;
103
103
  this.configuration = payload.configuration;
104
104
  this.pricing = payload.pricing;
105
+ this.listings = payload.listings;
105
106
  this._solution = { sid: sid || this.sid };
106
107
  }
107
108
  get _proxy() {
@@ -139,6 +140,7 @@ class ModuleDataManagementInstance {
139
140
  documentation: this.documentation,
140
141
  configuration: this.configuration,
141
142
  pricing: this.pricing,
143
+ listings: this.listings,
142
144
  };
143
145
  }
144
146
  [util_1.inspect.custom](_depth, options) {
@@ -38,7 +38,7 @@ export interface ServiceContextUpdateOptions {
38
38
  fallbackToLongCode?: boolean;
39
39
  /** Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance. */
40
40
  areaCodeGeomatch?: boolean;
41
- /** How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. */
41
+ /** How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`. */
42
42
  validityPeriod?: number;
43
43
  /** Reserved. */
44
44
  synchronousValidation?: boolean;
@@ -75,7 +75,7 @@ export interface ServiceListInstanceCreateOptions {
75
75
  fallbackToLongCode?: boolean;
76
76
  /** Whether to enable [Area Code Geomatch](https://www.twilio.com/docs/messaging/services#area-code-geomatch) on the Service Instance. */
77
77
  areaCodeGeomatch?: boolean;
78
- /** How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. */
78
+ /** How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`. */
79
79
  validityPeriod?: number;
80
80
  /** Reserved. */
81
81
  synchronousValidation?: boolean;
@@ -293,7 +293,7 @@ export declare class ServiceInstance {
293
293
  */
294
294
  synchronousValidation: boolean;
295
295
  /**
296
- * How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`.
296
+ * How long, in seconds, messages sent from the Service are valid. Can be an integer from `1` to `14,400`. Default value is `14,400`.
297
297
  */
298
298
  validityPeriod: number;
299
299
  /**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "twilio",
3
3
  "description": "A Twilio helper library",
4
- "version": "5.4.0",
4
+ "version": "5.4.2",
5
5
  "author": "API Team <api@twilio.com>",
6
6
  "contributors": [
7
7
  {