purecloud-flow-scripting-api-sdk-javascript 0.63.5 → 0.63.7

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/types.d.ts CHANGED
@@ -735,7 +735,7 @@ export class ArchEnums {
735
735
  * Remember some actions like {@link ArchActionSwitch} will have dynamic outputs and dynamically
736
736
  * added outputs will have identifiers that are not in the enum above.
737
737
  */
738
- readonly OUTPUT_IDS: {"active":"active","canceled":"canceled","closed":"closed","conditionsNotMet":"conditionsNotMet","default":"default","disconnect":"disconnect","emergency":"emergency","error":"error","event":"event","failure":"failure","formOutputs":"formOutputs","found":"found","holiday":"holiday","inactive":"inactive","knowledge":"knowledge","loop":"loop","loopNext":"loopNext","loopsMax":"loopsMax","matchExact":"matchExact","matchMultiple":"matchMultiple","maxNoInputs":"maxNoInputs","maxNoMatches":"maxNoMatches","no":"no","noInput":"noInput","noIntent":"noIntent","notFound":"notFound","open":"open","partiallyFound":"partiallyFound","skipResponseCapture":"skipResponseCapture","success":"success","timeout":"timeout","voicemail":"voicemail","yes":"yes"};
738
+ readonly OUTPUT_IDS: {"active":"active","canceled":"canceled","closed":"closed","conditionsNotMet":"conditionsNotMet","default":"default","disconnect":"disconnect","emergency":"emergency","error":"error","event":"event","failure":"failure","formOutputs":"formOutputs","found":"found","holiday":"holiday","inactive":"inactive","invalid":"invalid","knowledge":"knowledge","loop":"loop","loopNext":"loopNext","loopsMax":"loopsMax","matchExact":"matchExact","matchMultiple":"matchMultiple","maxNoInputs":"maxNoInputs","maxNoMatches":"maxNoMatches","no":"no","noInput":"noInput","noIntent":"noIntent","notFound":"notFound","open":"open","partiallyFound":"partiallyFound","skipResponseCapture":"skipResponseCapture","success":"success","timeout":"timeout","valid":"valid","voicemail":"voicemail","yes":"yes"};
739
739
  /**
740
740
  * Returns a string array that contains all valid output identifier strings.
741
741
  */
@@ -2989,7 +2989,10 @@ declare type callbackVoid = () => void;
2989
2989
  * create the factory instance as needed.
2990
2990
  */
2991
2991
  export class ArchFactoryFlows extends ArchBaseFactory {
2992
- // constructor();
2992
+ /**
2993
+ * Returns true indicating that this is an ArchFactoryFlows instance.
2994
+ */
2995
+ readonly isArchFactoryFlows: boolean;
2993
2996
  /**
2994
2997
  * The default division to use for flow creation calls like {@link ArchFactoryFlows#createFlowInboundCallAsync} if no division
2995
2998
  * is specified in the flowDivision parameter.
@@ -3007,17 +3010,12 @@ export class ArchFactoryFlows extends ArchBaseFactory {
3007
3010
  * A logging string for the Architect Factory Flows instance.
3008
3011
  */
3009
3012
  readonly logStr: string;
3010
- /**
3011
- * Returns true indicating that this is an ArchFactoryFlows instance.
3012
- */
3013
- readonly isArchFactoryFlows: boolean;
3014
3013
  /**
3015
3014
  * Creates a new [bot flow]{@link ArchFlowBot} flow in memory.
3016
3015
  * Upon successful creation the callback function that's passed in will be called with the newly
3017
3016
  * created Architect flow scripting object. Calling operations such as {@link ArchBaseFlow#saveAsync} and
3018
3017
  * {@link ArchBaseFlow#publishAsync} will create these flows in the cloud. Use the {@link ArchBaseFlow#isCreated}
3019
3018
  * property to see if the flow is created within Genesys Cloud.
3020
- *
3021
3019
  * The bot flow will have a bot that is already created which you can access via.
3022
3020
  * the [startUpObject]{@link ArchBaseFlowWorkflow#startUpObject} property off of the flow.
3023
3021
  * It's important to note that when you create a bot flow, unlike other flow types, Architect Scripting will have already
@@ -3281,6 +3279,30 @@ export class ArchFactoryFlows extends ArchBaseFactory {
3281
3279
  * @returns - while this method returns a promise, you should use the callback function to perform any processing because that callback will be passed the newly created {@link ArchFlowInboundChat} object instance.
3282
3280
  */
3283
3281
  createFlowInboundChatAsync(flowName: string, flowDescription?: string, defaultSupportedLanguage?: ArchLanguage, callbackFunction?: callbackArchFlowInboundChat, flowDivision?: ArchDivision): Promise<ArchFlowInboundChat>;
3282
+ /**
3283
+ * Creates a new [voice]{@link ArchFlowVoice} flow in memory.
3284
+ * Upon successful creation the callback function that's passed in will be called with the newly
3285
+ * created Architect flow scripting object. Calling operations such as {@link ArchBaseFlow#saveAsync} and
3286
+ * {@link ArchBaseFlow#publishAsync} will create these flows in the cloud. Use the {@link ArchBaseFlow#isCreated}
3287
+ * property to see if the flow is created within Genesys Cloud.
3288
+ * @param flowName - the name for the new flow.
3289
+ * @param [flowDescription] - the description for the new flow.
3290
+ * @param [defaultSupportedLanguage] - {@link ArchLanguages#englishUnitedStates} - the default language to use for the flow.
3291
+ * @param [callbackFunction] - a callback function to call if the voice call flow is successfully
3292
+ * created. The first parameter passed to the callback function will
3293
+ * be the created in-memory flow.
3294
+ * @param [flowDivision] - if specified, the division in which to create the flow. This must be a division where
3295
+ * the division's {@link ArchDivision#canAddFlow} property returns true. If not specified,
3296
+ * the division stored in the {@link ArchFactoryFlows#defaultFlowCreationDivision} will be used.
3297
+ * @param [creationData] - if specified, the supplied JSON object will contain a natural language understanding configuration.
3298
+ * Similar to exporting the Natural Language Understanding configuration in Architect's UI, the JSON object
3299
+ * must have an nluDomainVersion property at the root to be valid and then subsequent natural language
3300
+ * configuration meta data underneath it. Slot names within the JSON object should be compliant with
3301
+ * Architect variable naming standards. If not specified, a default blank Natural Language Understanding
3302
+ * configuration will be used by Architect Scripting.
3303
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing because the callback will be passed the newly created {@link ArchFlowVoice} instance.
3304
+ */
3305
+ createFlowVoiceAsync(flowName: string, flowDescription?: string, defaultSupportedLanguage?: ArchLanguage, callbackFunction?: (...params: any[]) => any, flowDivision?: ArchDivision, creationData?: any): Promise<ArchFlowVoice>;
3284
3306
  /**
3285
3307
  * Creates a new [voicemail flow]{@link ArchFlowVoicemail} in memory. Upon successful creation the callback function that's
3286
3308
  * passed in will be called with the newly created Architect flow scripting object. The voicemail flow will have
@@ -3336,7 +3358,7 @@ export class ArchFactoryFlows extends ArchBaseFactory {
3336
3358
  * @returns - while this method returns a promise, you should use the callback function to perform any processing because the
3337
3359
  * callback will be passed the newly created {@link ArchFlowVoiceSurvey} instance.
3338
3360
  */
3339
- static createFlowVoiceSurveyAsync(flowName: string, flowDescription?: string, defaultSupportedLanguage?: ArchLanguage, callbackFunction?: (...params: any[]) => any, flowDivision?: ArchDivision, creationData?: any, surveyFormName?: string, surveyFormId?: string, createNluFromSurveyForm?: boolean, configureFlowFromSurveyForm?: boolean): Promise<ArchFlowVoiceSurvey>;
3361
+ createFlowVoiceSurveyAsync(flowName: string, flowDescription?: string, defaultSupportedLanguage?: ArchLanguage, callbackFunction?: (...params: any[]) => any, flowDivision?: ArchDivision, creationData?: any, surveyFormName?: string, surveyFormId?: string, createNluFromSurveyForm?: boolean, configureFlowFromSurveyForm?: boolean): Promise<ArchFlowVoiceSurvey>;
3340
3362
  /**
3341
3363
  * Creates a new [workflow]{@link ArchFlowWorkflow} flow in memory.
3342
3364
  * Upon successful creation the callback function that's passed in will be called with the newly
@@ -3559,7 +3581,7 @@ export class ArchFactoryFlows extends ArchBaseFactory {
3559
3581
  * @param [callbackFunction] - a callback function to call if the flow can be found on the server by id and type.
3560
3582
  * The first parameter passed to the callback function will be the Architect Scripting
3561
3583
  * flow instance.
3562
- * @returns - while this method returns a promise, you should use the callback function to perform any processing because that callback will be passed the ArchBaseFlow instance.
3584
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing because that callback will be passed the {@link ArchBaseFlow} instance.
3563
3585
  */
3564
3586
  checkoutAndLoadFlowByFlowIdAsync<T extends ArchBaseFlow = ArchBaseFlow>(flowId: string, flowType: string, forceUnlock?: boolean, flowVersion?: string, callbackFunction?: callbackArchBaseFlow): Promise<T>;
3565
3587
  /**
@@ -4042,7 +4064,6 @@ export class ArchLanguage extends ArchBaseCoreObject {
4042
4064
  * from various methods as they'll represent actual language instances.
4043
4065
  */
4044
4066
  export class ArchLanguages extends ArchBaseObject {
4045
- // constructor();
4046
4067
  /**
4047
4068
  * Returns the display type name string 'ArchLanguages'.
4048
4069
  */
@@ -4281,8 +4302,9 @@ export class ArchLogging {
4281
4302
  readonly displayTypeName: string;
4282
4303
  /**
4283
4304
  * Logs an error. This accepts parameters similar to how you would call console.log.
4305
+ * @param args - the values to log, similar to console.log parameters.
4284
4306
  */
4285
- logError(): void;
4307
+ logError(...args: any[]): void;
4286
4308
  /**
4287
4309
  * Logs an error and then throws an exception with the supplied
4288
4310
  * error message text.
@@ -4291,16 +4313,19 @@ export class ArchLogging {
4291
4313
  logErrorAndThrow(message: string): void;
4292
4314
  /**
4293
4315
  * Logs a note. This accepts parameters similar to how you would call console.log.
4316
+ * @param args - the values to log, similar to console.log parameters.
4294
4317
  */
4295
- logNote(): void;
4318
+ logNote(...args: any[]): void;
4296
4319
  /**
4297
4320
  * Logs a verbose note. This accepts parameters similar to how you would call console.log.
4321
+ * @param args - the values to log, similar to console.log parameters.
4298
4322
  */
4299
- logNoteVerbose(): void;
4323
+ logNoteVerbose(...args: any[]): void;
4300
4324
  /**
4301
4325
  * Logs a warning. This accepts parameters similar to how you would call console.log.
4326
+ * @param args - the values to log, similar to console.log parameters.
4302
4327
  */
4303
- logWarning(): void;
4328
+ logWarning(...args: any[]): void;
4304
4329
  /**
4305
4330
  * A method where you can pass in a callback function that will get called when Architect logging is going
4306
4331
  * to log a message. This will let you intercept the message, perform your own logging and conditionally
@@ -13429,12 +13454,12 @@ export class ArchActionSetPostFlow extends ArchBaseAction {
13429
13454
  * The target flow to call for this ArchActionSetPostFlow instance. Note that this function accepts either an {@link ArchFlowInfo} or an {@link ArchFlowInfoBasic}
13430
13455
  * instance. If the flow information supplied to the setter does not specify a flow, it will throw an exception.
13431
13456
  * The type of flow specified must also match the type specified in the action instance's actionType property
13432
- * @param targetFlowInfo - the {@link ArchFlowInfoBasic} that specifies the flow to execute.
13457
+ * @param targetFlowInfo - the {@link ArchFlowInfoBasic} or {@link ArchFlowInfo} that specifies the flow to execute.
13433
13458
  * @param [callbackFunction] - a callback function to call if the flow is successfully
13434
13459
  * configured on this action. The first parameter passed to the
13435
13460
  * callback function will be this Architect Set Post Flow action instance.
13436
13461
  */
13437
- setTargetFlowInfoAsync(targetFlowInfo: ArchFlowInfoBasic, callbackFunction?: (...params: any[]) => any): void;
13462
+ setTargetFlowInfoAsync(targetFlowInfo: ArchFlowInfo | ArchFlowInfoBasic, callbackFunction?: (...params: any[]) => any): void;
13438
13463
  /**
13439
13464
  * Returns the target type string for the currently configured [action type]{@link ArchActionSetPostFlow#actionType}.
13440
13465
  */
@@ -17486,14 +17511,22 @@ declare type ExportInfoType = {
17486
17511
  */
17487
17512
  declare type callbackExportFullPath = (exportFullPath: string) => void;
17488
17513
 
17489
- /**
17490
- * The base Architect Scripting class for flows.
17491
- * Instances of this class will be created by Architect Scripting as needed. The {@link ArchFactoryFlows} has methods
17492
- * available to create flows.
17493
- * @param coreFlowViewModel - ( *Internal* ) an Architect core flow view model.
17494
- */
17495
17514
  export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17496
17515
  // constructor(coreFlowViewModel: any);
17516
+ /**
17517
+ * Returns a definition for this flow type which provides access to information about this flow such as {@link ArchDefinitionFlow#isAvailable}.
17518
+ * ```
17519
+ * // Example code - remember, only access this when your Scripting session is connected!
17520
+ * let archIncomingCallFlowDefinition = scripting.viewModels.flows.ArchFlowInboundCall.definition;
17521
+ * // or for a given ArchFlowInboundCall flow instance:
17522
+ * let archIncomingCallFlowDefinition = archInboundCallFlowInstance.definition;
17523
+ * ```
17524
+ */
17525
+ readonly definition: ArchDefinitionFlow;
17526
+ /**
17527
+ * Returns true indicating that this is an ArchBaseFlow instance.
17528
+ */
17529
+ readonly isArchBaseFlow: boolean;
17497
17530
  /**
17498
17531
  * This adds a new variable to the flow.
17499
17532
  * @param name - the name of the variable to add. Remember that variable names must
@@ -17523,7 +17556,7 @@ export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17523
17556
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
17524
17557
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
17525
17558
  */
17526
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
17559
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
17527
17560
  /**
17528
17561
  * Returns the display type name string 'ArchBaseFlow'.
17529
17562
  */
@@ -17576,7 +17609,7 @@ export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17576
17609
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
17577
17610
  * flow instance.
17578
17611
  */
17579
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
17612
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
17580
17613
  /**
17581
17614
  * Creates a new flow on the server and saves its configuration
17582
17615
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -17665,7 +17698,7 @@ export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17665
17698
  * on this flow. The first parameter passed to the callback function will be this
17666
17699
  * Architect flow instance.
17667
17700
  */
17668
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
17701
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
17669
17702
  /**
17670
17703
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
17671
17704
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -17676,11 +17709,2693 @@ export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17676
17709
  * on this flow. The first parameter passed to the callback function will be this
17677
17710
  * Architect flow instance.
17678
17711
  */
17679
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
17712
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
17680
17713
  /**
17681
- * Returns true indicating that this is an ArchBaseFlow instance.
17714
+ * Returns whether or not the flow is created in Genesys Cloud.
17682
17715
  */
17683
- readonly isArchBaseFlow: boolean;
17716
+ readonly isCreated: boolean;
17717
+ /**
17718
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
17719
+ * scripting but not saved, checked in or published will report that they are not read-only.
17720
+ */
17721
+ readonly isReadOnly: boolean;
17722
+ /**
17723
+ * Returns whether or not the flow is secure. That means it contains something that is
17724
+ * secure like a secure variable or secure action.
17725
+ */
17726
+ readonly isSecure: boolean;
17727
+ /**
17728
+ * Returns true indicating the flow acts as a variable container which means you can
17729
+ * add variables to it.
17730
+ */
17731
+ readonly isVariableContainer: boolean;
17732
+ /**
17733
+ * The language settings for the flow. This property is now deprecated.
17734
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
17735
+ */
17736
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
17737
+ /**
17738
+ * The name of the flow
17739
+ */
17740
+ name: string;
17741
+ /**
17742
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
17743
+ * steps can fail and reject the promise. Operations are not atomic.
17744
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
17745
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
17746
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
17747
+ * flow instance.
17748
+ */
17749
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
17750
+ /**
17751
+ * Save the current flow configuration, creating the flow if needed.
17752
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
17753
+ * flow instance.
17754
+ */
17755
+ saveAsync(): Promise<any>;
17756
+ /**
17757
+ * Returns the error handling settings for the flow.
17758
+ */
17759
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlow;
17760
+ /**
17761
+ * Returns the action default settings for the flow.
17762
+ */
17763
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
17764
+ /**
17765
+ * The supported language settings for the flow.
17766
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
17767
+ * to calling this method to see if a flow supports languages or not.
17768
+ */
17769
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
17770
+ /**
17771
+ * Returns whether or not this flow supports audio channel.
17772
+ */
17773
+ readonly supportsAudio: boolean;
17774
+ /**
17775
+ * Returns whether or not this flow supports error handling.
17776
+ */
17777
+ readonly supportsErrorHandling: boolean;
17778
+ /**
17779
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
17780
+ * when creating it to use English United States.
17781
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
17782
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
17783
+ */
17784
+ readonly supportsLanguages: boolean;
17785
+ /**
17786
+ * Returns whether or not this flow supports setting a supported language as the default.
17787
+ */
17788
+ readonly supportsDefaultLanguage: boolean;
17789
+ /**
17790
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
17791
+ * the returned URL will be blank.
17792
+ */
17793
+ readonly url: string;
17794
+ /**
17795
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
17796
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
17797
+ * validation results.
17798
+ */
17799
+ validateAsync(): Promise<ArchValidationResults>;
17800
+ /**
17801
+ * Returns an array of variables defined at the flow scope for this flow.
17802
+ */
17803
+ readonly variables: ArchBaseVariable[];
17804
+ /**
17805
+ * The identifier string for this object.
17806
+ */
17807
+ readonly id: string;
17808
+ /**
17809
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
17810
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
17811
+ * an extremely rare case.
17812
+ */
17813
+ readonly idMayBeBlank: string;
17814
+ /**
17815
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
17816
+ */
17817
+ readonly isArchBaseCoreObject: boolean;
17818
+ /**
17819
+ * This method iterates over this object and ArchBaseCoreObject instances
17820
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
17821
+ * with a filter and call the supplied callback function if isMatch returns true.
17822
+ * The callback will be passed an {@link ArchTraverseInfo} with details
17823
+ * about the match such as the match object itself along with current contextual
17824
+ * information such as the object hierarchy for the match object relative to
17825
+ * the object on which this traverse call is being made.
17826
+ *
17827
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
17828
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
17829
+ * or clause containers to it. If not specified, this function will use a
17830
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
17831
+ *
17832
+ * Here is an example that does a simple flow traversal using the default
17833
+ * filter and logs information about objects in the callback from the
17834
+ * traverse object that's passed back:
17835
+ *
17836
+ * ```
17837
+ * archInboundCallFlow.traverse(function(traverseInfo) {
17838
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
17839
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
17840
+ * });
17841
+ * ```
17842
+ * This might be enough for most uses and you can check various aspects
17843
+ * about the object in the callback such as "is this an Architect action?" by
17844
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
17845
+ * a filter for the traversal code to use as well and only have it call your
17846
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
17847
+ * the filter. Here's an example that creates a filter for callbacks on
17848
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
17849
+ * [decision action]{@link ArchActionDecision} or objects whose name
17850
+ * property case insensitively matches the word 'foo'. While this could all be done
17851
+ * with one property callback clause the example will use multiple clauses for
17852
+ * the sake of simplicity:
17853
+ * ```
17854
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
17855
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
17856
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
17857
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
17858
+ * // We fully spelled out the function signature above but archContainingObject and propName are
17859
+ * // not needed in this case. The archContainingObject is the object that contains the
17860
+ * // property and propName is the property name itself. We pass in propName because the same
17861
+ * // function could be used for multiple property callback clauses.
17862
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
17863
+ * return propValue && propValue.toLowerCase() === 'foo';
17864
+ * });
17865
+ * archTask.traverse(function(traverseContext) {
17866
+ * // You will only be called back here for ArchBaseCoreObject instances that
17867
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
17868
+ * }, myTraverseFilter);
17869
+ * ```
17870
+ * If you supply a filter with no clauses, this tells the traverse method to
17871
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
17872
+ *
17873
+ * If you want traversal itself to stop after a callback, simply return boolean
17874
+ * false from the callback function you supply to the traverse call.
17875
+ *
17876
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
17877
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
17878
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
17879
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
17880
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
17881
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
17882
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
17883
+ *
17884
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
17885
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
17886
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
17887
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
17888
+ *
17889
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
17890
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
17891
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
17892
+ *
17893
+ * This function returns the number of times it called the callback function.
17894
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
17895
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
17896
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
17897
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
17898
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
17899
+ */
17900
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
17901
+ /**
17902
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
17903
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
17904
+ * logging str contents wouldn't be set up.
17905
+ */
17906
+ readonly logStrTypeOnly: string;
17907
+ /**
17908
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
17909
+ * @param errorStr - the error string to log.
17910
+ */
17911
+ logError(errorStr: string): void;
17912
+ /**
17913
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
17914
+ * the string in the errorStr parameter.
17915
+ * @param errorStr - the error string to log. This should be a non-blank string.
17916
+ */
17917
+ logErrorAndThrow(errorStr: string): void;
17918
+ /**
17919
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
17920
+ * @param noteStr - the note string to log. This should be a non-blank string.
17921
+ */
17922
+ logNote(noteStr: string): void;
17923
+ /**
17924
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
17925
+ * @param noteStr - the note string to log. This should be a non-blank string.
17926
+ */
17927
+ logNoteVerbose(noteStr: string): void;
17928
+ /**
17929
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
17930
+ * @param warningStr - the warning string to log. This should be a non-blank string.
17931
+ */
17932
+ logWarning(warningStr: string): void;
17933
+ /**
17934
+ * Returns whether or not this Architect Scripting object is a match
17935
+ * for the supplied ArchFilterObject instance.
17936
+ * @param archFilterObject - the object filter to use to determine if it's a match.
17937
+ */
17938
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
17939
+ }
17940
+
17941
+ export class ArchBaseFlowBot extends ArchBaseFlowWorkflow {
17942
+ // constructor(coreBotViewModel: any);
17943
+ /**
17944
+ * Returns the display type name string 'ArchBaseFlowBot'.
17945
+ */
17946
+ readonly displayTypeName: string;
17947
+ /**
17948
+ * Returns true indicating that this is an ArchBaseFlowBot instance.
17949
+ */
17950
+ readonly isArchBaseFlowBot: boolean;
17951
+ /**
17952
+ * The user input settings for the flow.
17953
+ */
17954
+ readonly userInputSettings: ArchSettingsUserInput;
17955
+ /**
17956
+ * Returns the error handling settings for the flow.
17957
+ */
17958
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlowBot;
17959
+ /**
17960
+ * This function deletes the specified state from this flow.
17961
+ * @param stateToDelete - the state to delete.
17962
+ */
17963
+ deleteState(stateToDelete: ArchState): void;
17964
+ /**
17965
+ * Sets the specified state to be the starting state on the flow.
17966
+ * @param archState - An Architect Scripting state object.
17967
+ */
17968
+ setStartingState(archState: ArchState): void;
17969
+ /**
17970
+ * Returns the starting state for this flow.
17971
+ * If there is no startup object configured, accessing this property returns null.
17972
+ */
17973
+ readonly startUpObject: ArchState;
17974
+ /**
17975
+ * The states in the flow.
17976
+ */
17977
+ readonly states: ArchState[];
17978
+ /**
17979
+ * This function deletes the specified reusable task from this flow.
17980
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
17981
+ * property on the specified task instance is true.
17982
+ */
17983
+ deleteTask(taskToDelete: ArchTask): void;
17984
+ /**
17985
+ * Returns an array of the currently defined reusable tasks for this flow.
17986
+ */
17987
+ readonly tasksReusable: ArchTask[];
17988
+ /**
17989
+ * This adds a new variable to the flow.
17990
+ * @param name - the name of the variable to add. Remember that variable names must
17991
+ * start with a letter and can then be followed by one or more letters, numbers
17992
+ * or underscore characters to be valid. Submitting the variable scope on the name
17993
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
17994
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
17995
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
17996
+ * @param type - the data type for the new variable. Remember that type must be supported
17997
+ * in the flow type for which you're looking to add the variable. If you are
17998
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
17999
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
18000
+ * @param [description] - the description for the new variable.
18001
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
18002
+ */
18003
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
18004
+ /**
18005
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
18006
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
18007
+ * @param archVariable - the flow scoped variable you wish to delete
18008
+ * @returns - true if the variable was removed successfully, false otherwise.
18009
+ */
18010
+ removeVariable(archVariable: ArchBaseVariable): boolean;
18011
+ /**
18012
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
18013
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
18014
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
18015
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
18016
+ */
18017
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
18018
+ /**
18019
+ * Returns the division associated with this flow.
18020
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
18021
+ * If not available, nothing is returned.
18022
+ */
18023
+ readonly division: ArchDivision;
18024
+ /**
18025
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
18026
+ * longer be considered valid after loading new configuration.
18027
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
18028
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
18029
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
18030
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
18031
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
18032
+ */
18033
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
18034
+ /**
18035
+ * Returns a string suitable for logging that describes the flow
18036
+ */
18037
+ readonly logStr: string;
18038
+ /**
18039
+ * Unlocks this flow.
18040
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
18041
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
18042
+ */
18043
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
18044
+ /**
18045
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
18046
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
18047
+ * value.
18048
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
18049
+ * language must have at least one region sub-tag.
18050
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
18051
+ */
18052
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
18053
+ /**
18054
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
18055
+ * if any or more than one can be added.
18056
+ */
18057
+ canAddSupportedLanguage(): boolean;
18058
+ /**
18059
+ * Checks in and unlocks the flow for the current user, does a save first
18060
+ * Assumes the flow has been created, throws if not
18061
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
18062
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
18063
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18064
+ * flow instance.
18065
+ */
18066
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
18067
+ /**
18068
+ * Creates a new flow on the server and saves its configuration
18069
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18070
+ * flow instance.
18071
+ */
18072
+ createAsync(): Promise<any>;
18073
+ /**
18074
+ * Accessing this property returns an object with properties whose keys are data type names and values are
18075
+ * {@link ArchDataType} instances.
18076
+ */
18077
+ readonly dataTypes: any;
18078
+ /**
18079
+ * The description of the flow
18080
+ */
18081
+ description: string;
18082
+ /**
18083
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
18084
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
18085
+ * browser.
18086
+ * @param [destinationDir] - the directory where the flow export should be saved.
18087
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
18088
+ * flow export was saved.
18089
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
18090
+ * it will default to the Architect format.
18091
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
18092
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
18093
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
18094
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
18095
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
18096
+ */
18097
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
18098
+ /**
18099
+ * Exports the flow to a JSON object. The object passed back in the callback function
18100
+ * will be a JSON object with a content and fileName property where the content holds
18101
+ * the flow export contents and the fileName property holds the file name where the
18102
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
18103
+ * @param callbackFunction - the function to call back with the export information contained
18104
+ * in the parameter passed to it.
18105
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
18106
+ * it will default to the Architect format.
18107
+ */
18108
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
18109
+ /**
18110
+ * The type of the flow. The string
18111
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
18112
+ */
18113
+ readonly flowType: string;
18114
+ /**
18115
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
18116
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
18117
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
18118
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
18119
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
18120
+ * browser.
18121
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
18122
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
18123
+ * working directory.
18124
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
18125
+ * formats. If no format is supplied, it will use the Architect format.
18126
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
18127
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
18128
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
18129
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
18130
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
18131
+ */
18132
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
18133
+ /**
18134
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
18135
+ * If the variable name cannot be found, nothing is returned.
18136
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
18137
+ */
18138
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
18139
+ /**
18140
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
18141
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
18142
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
18143
+ */
18144
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
18145
+ /**
18146
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
18147
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
18148
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
18149
+ * do work with the flow on which this is being called until the callback is called.
18150
+ * @param exportContent - the contents from a flow export.
18151
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
18152
+ * on this flow. The first parameter passed to the callback function will be this
18153
+ * Architect flow instance.
18154
+ */
18155
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18156
+ /**
18157
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
18158
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
18159
+ * do work with the flow on which this is being called until the callback is called.
18160
+ * Also note that this method should not be used if running in a browser.
18161
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
18162
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
18163
+ * on this flow. The first parameter passed to the callback function will be this
18164
+ * Architect flow instance.
18165
+ */
18166
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18167
+ /**
18168
+ * Returns whether or not the flow is created in Genesys Cloud.
18169
+ */
18170
+ readonly isCreated: boolean;
18171
+ /**
18172
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
18173
+ * scripting but not saved, checked in or published will report that they are not read-only.
18174
+ */
18175
+ readonly isReadOnly: boolean;
18176
+ /**
18177
+ * Returns whether or not the flow is secure. That means it contains something that is
18178
+ * secure like a secure variable or secure action.
18179
+ */
18180
+ readonly isSecure: boolean;
18181
+ /**
18182
+ * Returns true indicating the flow acts as a variable container which means you can
18183
+ * add variables to it.
18184
+ */
18185
+ readonly isVariableContainer: boolean;
18186
+ /**
18187
+ * The language settings for the flow. This property is now deprecated.
18188
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
18189
+ */
18190
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
18191
+ /**
18192
+ * The name of the flow
18193
+ */
18194
+ name: string;
18195
+ /**
18196
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
18197
+ * steps can fail and reject the promise. Operations are not atomic.
18198
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
18199
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
18200
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18201
+ * flow instance.
18202
+ */
18203
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
18204
+ /**
18205
+ * Save the current flow configuration, creating the flow if needed.
18206
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18207
+ * flow instance.
18208
+ */
18209
+ saveAsync(): Promise<any>;
18210
+ /**
18211
+ * Returns the action default settings for the flow.
18212
+ */
18213
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
18214
+ /**
18215
+ * The supported language settings for the flow.
18216
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
18217
+ * to calling this method to see if a flow supports languages or not.
18218
+ */
18219
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
18220
+ /**
18221
+ * Returns whether or not this flow supports audio channel.
18222
+ */
18223
+ readonly supportsAudio: boolean;
18224
+ /**
18225
+ * Returns whether or not this flow supports error handling.
18226
+ */
18227
+ readonly supportsErrorHandling: boolean;
18228
+ /**
18229
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
18230
+ * when creating it to use English United States.
18231
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
18232
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
18233
+ */
18234
+ readonly supportsLanguages: boolean;
18235
+ /**
18236
+ * Returns whether or not this flow supports setting a supported language as the default.
18237
+ */
18238
+ readonly supportsDefaultLanguage: boolean;
18239
+ /**
18240
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
18241
+ * the returned URL will be blank.
18242
+ */
18243
+ readonly url: string;
18244
+ /**
18245
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
18246
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
18247
+ * validation results.
18248
+ */
18249
+ validateAsync(): Promise<ArchValidationResults>;
18250
+ /**
18251
+ * Returns an array of variables defined at the flow scope for this flow.
18252
+ */
18253
+ readonly variables: ArchBaseVariable[];
18254
+ /**
18255
+ * The identifier string for this object.
18256
+ */
18257
+ readonly id: string;
18258
+ /**
18259
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
18260
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
18261
+ * an extremely rare case.
18262
+ */
18263
+ readonly idMayBeBlank: string;
18264
+ /**
18265
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
18266
+ */
18267
+ readonly isArchBaseCoreObject: boolean;
18268
+ /**
18269
+ * This method iterates over this object and ArchBaseCoreObject instances
18270
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
18271
+ * with a filter and call the supplied callback function if isMatch returns true.
18272
+ * The callback will be passed an {@link ArchTraverseInfo} with details
18273
+ * about the match such as the match object itself along with current contextual
18274
+ * information such as the object hierarchy for the match object relative to
18275
+ * the object on which this traverse call is being made.
18276
+ *
18277
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
18278
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
18279
+ * or clause containers to it. If not specified, this function will use a
18280
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
18281
+ *
18282
+ * Here is an example that does a simple flow traversal using the default
18283
+ * filter and logs information about objects in the callback from the
18284
+ * traverse object that's passed back:
18285
+ *
18286
+ * ```
18287
+ * archInboundCallFlow.traverse(function(traverseInfo) {
18288
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
18289
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
18290
+ * });
18291
+ * ```
18292
+ * This might be enough for most uses and you can check various aspects
18293
+ * about the object in the callback such as "is this an Architect action?" by
18294
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
18295
+ * a filter for the traversal code to use as well and only have it call your
18296
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
18297
+ * the filter. Here's an example that creates a filter for callbacks on
18298
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
18299
+ * [decision action]{@link ArchActionDecision} or objects whose name
18300
+ * property case insensitively matches the word 'foo'. While this could all be done
18301
+ * with one property callback clause the example will use multiple clauses for
18302
+ * the sake of simplicity:
18303
+ * ```
18304
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
18305
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
18306
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
18307
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
18308
+ * // We fully spelled out the function signature above but archContainingObject and propName are
18309
+ * // not needed in this case. The archContainingObject is the object that contains the
18310
+ * // property and propName is the property name itself. We pass in propName because the same
18311
+ * // function could be used for multiple property callback clauses.
18312
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
18313
+ * return propValue && propValue.toLowerCase() === 'foo';
18314
+ * });
18315
+ * archTask.traverse(function(traverseContext) {
18316
+ * // You will only be called back here for ArchBaseCoreObject instances that
18317
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
18318
+ * }, myTraverseFilter);
18319
+ * ```
18320
+ * If you supply a filter with no clauses, this tells the traverse method to
18321
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
18322
+ *
18323
+ * If you want traversal itself to stop after a callback, simply return boolean
18324
+ * false from the callback function you supply to the traverse call.
18325
+ *
18326
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
18327
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
18328
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
18329
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
18330
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
18331
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
18332
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
18333
+ *
18334
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
18335
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
18336
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
18337
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
18338
+ *
18339
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
18340
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
18341
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
18342
+ *
18343
+ * This function returns the number of times it called the callback function.
18344
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
18345
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
18346
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
18347
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
18348
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
18349
+ */
18350
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
18351
+ /**
18352
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
18353
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
18354
+ * logging str contents wouldn't be set up.
18355
+ */
18356
+ readonly logStrTypeOnly: string;
18357
+ /**
18358
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
18359
+ * @param errorStr - the error string to log.
18360
+ */
18361
+ logError(errorStr: string): void;
18362
+ /**
18363
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
18364
+ * the string in the errorStr parameter.
18365
+ * @param errorStr - the error string to log. This should be a non-blank string.
18366
+ */
18367
+ logErrorAndThrow(errorStr: string): void;
18368
+ /**
18369
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
18370
+ * @param noteStr - the note string to log. This should be a non-blank string.
18371
+ */
18372
+ logNote(noteStr: string): void;
18373
+ /**
18374
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
18375
+ * @param noteStr - the note string to log. This should be a non-blank string.
18376
+ */
18377
+ logNoteVerbose(noteStr: string): void;
18378
+ /**
18379
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
18380
+ * @param warningStr - the warning string to log. This should be a non-blank string.
18381
+ */
18382
+ logWarning(warningStr: string): void;
18383
+ /**
18384
+ * Returns whether or not this Architect Scripting object is a match
18385
+ * for the supplied ArchFilterObject instance.
18386
+ * @param archFilterObject - the object filter to use to determine if it's a match.
18387
+ */
18388
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
18389
+ }
18390
+
18391
+ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
18392
+ // constructor(coreBotWithKnowledgeViewModel: any);
18393
+ /**
18394
+ * Returns the display type name string 'isArchBaseFlowBotWithKnowledge'.
18395
+ */
18396
+ readonly displayTypeName: string;
18397
+ /**
18398
+ * Returns true indicating that this is an isArchBaseFlowBotWithKnowledge instance.
18399
+ */
18400
+ readonly isArchBaseFlowBotWithKnowledge: boolean;
18401
+ /**
18402
+ * The natural language understanding knowledge settings for the bot flow.
18403
+ * Note that if your organization does not have knowledge base support or the
18404
+ * flow's supported language does not support knowledge, accessing this property
18405
+ * will return null.
18406
+ */
18407
+ readonly knowledgeSettings: ArchSettingsNluKnowledge | null;
18408
+ /**
18409
+ * Bot-specific settings for the flow.
18410
+ */
18411
+ readonly botFlowSettings: ArchSettingsBotFlow;
18412
+ /**
18413
+ * Returns true indicating that this is an ArchBaseFlowBot instance.
18414
+ */
18415
+ readonly isArchBaseFlowBot: boolean;
18416
+ /**
18417
+ * The user input settings for the flow.
18418
+ */
18419
+ readonly userInputSettings: ArchSettingsUserInput;
18420
+ /**
18421
+ * Returns the error handling settings for the flow.
18422
+ */
18423
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlowBot;
18424
+ /**
18425
+ * This function deletes the specified state from this flow.
18426
+ * @param stateToDelete - the state to delete.
18427
+ */
18428
+ deleteState(stateToDelete: ArchState): void;
18429
+ /**
18430
+ * Sets the specified state to be the starting state on the flow.
18431
+ * @param archState - An Architect Scripting state object.
18432
+ */
18433
+ setStartingState(archState: ArchState): void;
18434
+ /**
18435
+ * Returns the starting state for this flow.
18436
+ * If there is no startup object configured, accessing this property returns null.
18437
+ */
18438
+ readonly startUpObject: ArchState;
18439
+ /**
18440
+ * The states in the flow.
18441
+ */
18442
+ readonly states: ArchState[];
18443
+ /**
18444
+ * This function deletes the specified reusable task from this flow.
18445
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
18446
+ * property on the specified task instance is true.
18447
+ */
18448
+ deleteTask(taskToDelete: ArchTask): void;
18449
+ /**
18450
+ * Returns an array of the currently defined reusable tasks for this flow.
18451
+ */
18452
+ readonly tasksReusable: ArchTask[];
18453
+ /**
18454
+ * This adds a new variable to the flow.
18455
+ * @param name - the name of the variable to add. Remember that variable names must
18456
+ * start with a letter and can then be followed by one or more letters, numbers
18457
+ * or underscore characters to be valid. Submitting the variable scope on the name
18458
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
18459
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
18460
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
18461
+ * @param type - the data type for the new variable. Remember that type must be supported
18462
+ * in the flow type for which you're looking to add the variable. If you are
18463
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
18464
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
18465
+ * @param [description] - the description for the new variable.
18466
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
18467
+ */
18468
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
18469
+ /**
18470
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
18471
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
18472
+ * @param archVariable - the flow scoped variable you wish to delete
18473
+ * @returns - true if the variable was removed successfully, false otherwise.
18474
+ */
18475
+ removeVariable(archVariable: ArchBaseVariable): boolean;
18476
+ /**
18477
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
18478
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
18479
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
18480
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
18481
+ */
18482
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
18483
+ /**
18484
+ * Returns the division associated with this flow.
18485
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
18486
+ * If not available, nothing is returned.
18487
+ */
18488
+ readonly division: ArchDivision;
18489
+ /**
18490
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
18491
+ * longer be considered valid after loading new configuration.
18492
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
18493
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
18494
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
18495
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
18496
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
18497
+ */
18498
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
18499
+ /**
18500
+ * Returns a string suitable for logging that describes the flow
18501
+ */
18502
+ readonly logStr: string;
18503
+ /**
18504
+ * Unlocks this flow.
18505
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
18506
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
18507
+ */
18508
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
18509
+ /**
18510
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
18511
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
18512
+ * value.
18513
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
18514
+ * language must have at least one region sub-tag.
18515
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
18516
+ */
18517
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
18518
+ /**
18519
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
18520
+ * if any or more than one can be added.
18521
+ */
18522
+ canAddSupportedLanguage(): boolean;
18523
+ /**
18524
+ * Checks in and unlocks the flow for the current user, does a save first
18525
+ * Assumes the flow has been created, throws if not
18526
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
18527
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
18528
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18529
+ * flow instance.
18530
+ */
18531
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
18532
+ /**
18533
+ * Creates a new flow on the server and saves its configuration
18534
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18535
+ * flow instance.
18536
+ */
18537
+ createAsync(): Promise<any>;
18538
+ /**
18539
+ * Accessing this property returns an object with properties whose keys are data type names and values are
18540
+ * {@link ArchDataType} instances.
18541
+ */
18542
+ readonly dataTypes: any;
18543
+ /**
18544
+ * The description of the flow
18545
+ */
18546
+ description: string;
18547
+ /**
18548
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
18549
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
18550
+ * browser.
18551
+ * @param [destinationDir] - the directory where the flow export should be saved.
18552
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
18553
+ * flow export was saved.
18554
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
18555
+ * it will default to the Architect format.
18556
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
18557
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
18558
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
18559
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
18560
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
18561
+ */
18562
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
18563
+ /**
18564
+ * Exports the flow to a JSON object. The object passed back in the callback function
18565
+ * will be a JSON object with a content and fileName property where the content holds
18566
+ * the flow export contents and the fileName property holds the file name where the
18567
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
18568
+ * @param callbackFunction - the function to call back with the export information contained
18569
+ * in the parameter passed to it.
18570
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
18571
+ * it will default to the Architect format.
18572
+ */
18573
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
18574
+ /**
18575
+ * The type of the flow. The string
18576
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
18577
+ */
18578
+ readonly flowType: string;
18579
+ /**
18580
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
18581
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
18582
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
18583
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
18584
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
18585
+ * browser.
18586
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
18587
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
18588
+ * working directory.
18589
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
18590
+ * formats. If no format is supplied, it will use the Architect format.
18591
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
18592
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
18593
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
18594
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
18595
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
18596
+ */
18597
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
18598
+ /**
18599
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
18600
+ * If the variable name cannot be found, nothing is returned.
18601
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
18602
+ */
18603
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
18604
+ /**
18605
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
18606
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
18607
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
18608
+ */
18609
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
18610
+ /**
18611
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
18612
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
18613
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
18614
+ * do work with the flow on which this is being called until the callback is called.
18615
+ * @param exportContent - the contents from a flow export.
18616
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
18617
+ * on this flow. The first parameter passed to the callback function will be this
18618
+ * Architect flow instance.
18619
+ */
18620
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18621
+ /**
18622
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
18623
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
18624
+ * do work with the flow on which this is being called until the callback is called.
18625
+ * Also note that this method should not be used if running in a browser.
18626
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
18627
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
18628
+ * on this flow. The first parameter passed to the callback function will be this
18629
+ * Architect flow instance.
18630
+ */
18631
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18632
+ /**
18633
+ * Returns whether or not the flow is created in Genesys Cloud.
18634
+ */
18635
+ readonly isCreated: boolean;
18636
+ /**
18637
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
18638
+ * scripting but not saved, checked in or published will report that they are not read-only.
18639
+ */
18640
+ readonly isReadOnly: boolean;
18641
+ /**
18642
+ * Returns whether or not the flow is secure. That means it contains something that is
18643
+ * secure like a secure variable or secure action.
18644
+ */
18645
+ readonly isSecure: boolean;
18646
+ /**
18647
+ * Returns true indicating the flow acts as a variable container which means you can
18648
+ * add variables to it.
18649
+ */
18650
+ readonly isVariableContainer: boolean;
18651
+ /**
18652
+ * The language settings for the flow. This property is now deprecated.
18653
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
18654
+ */
18655
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
18656
+ /**
18657
+ * The name of the flow
18658
+ */
18659
+ name: string;
18660
+ /**
18661
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
18662
+ * steps can fail and reject the promise. Operations are not atomic.
18663
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
18664
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
18665
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18666
+ * flow instance.
18667
+ */
18668
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
18669
+ /**
18670
+ * Save the current flow configuration, creating the flow if needed.
18671
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18672
+ * flow instance.
18673
+ */
18674
+ saveAsync(): Promise<any>;
18675
+ /**
18676
+ * Returns the action default settings for the flow.
18677
+ */
18678
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
18679
+ /**
18680
+ * The supported language settings for the flow.
18681
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
18682
+ * to calling this method to see if a flow supports languages or not.
18683
+ */
18684
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
18685
+ /**
18686
+ * Returns whether or not this flow supports audio channel.
18687
+ */
18688
+ readonly supportsAudio: boolean;
18689
+ /**
18690
+ * Returns whether or not this flow supports error handling.
18691
+ */
18692
+ readonly supportsErrorHandling: boolean;
18693
+ /**
18694
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
18695
+ * when creating it to use English United States.
18696
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
18697
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
18698
+ */
18699
+ readonly supportsLanguages: boolean;
18700
+ /**
18701
+ * Returns whether or not this flow supports setting a supported language as the default.
18702
+ */
18703
+ readonly supportsDefaultLanguage: boolean;
18704
+ /**
18705
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
18706
+ * the returned URL will be blank.
18707
+ */
18708
+ readonly url: string;
18709
+ /**
18710
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
18711
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
18712
+ * validation results.
18713
+ */
18714
+ validateAsync(): Promise<ArchValidationResults>;
18715
+ /**
18716
+ * Returns an array of variables defined at the flow scope for this flow.
18717
+ */
18718
+ readonly variables: ArchBaseVariable[];
18719
+ /**
18720
+ * The identifier string for this object.
18721
+ */
18722
+ readonly id: string;
18723
+ /**
18724
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
18725
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
18726
+ * an extremely rare case.
18727
+ */
18728
+ readonly idMayBeBlank: string;
18729
+ /**
18730
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
18731
+ */
18732
+ readonly isArchBaseCoreObject: boolean;
18733
+ /**
18734
+ * This method iterates over this object and ArchBaseCoreObject instances
18735
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
18736
+ * with a filter and call the supplied callback function if isMatch returns true.
18737
+ * The callback will be passed an {@link ArchTraverseInfo} with details
18738
+ * about the match such as the match object itself along with current contextual
18739
+ * information such as the object hierarchy for the match object relative to
18740
+ * the object on which this traverse call is being made.
18741
+ *
18742
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
18743
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
18744
+ * or clause containers to it. If not specified, this function will use a
18745
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
18746
+ *
18747
+ * Here is an example that does a simple flow traversal using the default
18748
+ * filter and logs information about objects in the callback from the
18749
+ * traverse object that's passed back:
18750
+ *
18751
+ * ```
18752
+ * archInboundCallFlow.traverse(function(traverseInfo) {
18753
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
18754
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
18755
+ * });
18756
+ * ```
18757
+ * This might be enough for most uses and you can check various aspects
18758
+ * about the object in the callback such as "is this an Architect action?" by
18759
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
18760
+ * a filter for the traversal code to use as well and only have it call your
18761
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
18762
+ * the filter. Here's an example that creates a filter for callbacks on
18763
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
18764
+ * [decision action]{@link ArchActionDecision} or objects whose name
18765
+ * property case insensitively matches the word 'foo'. While this could all be done
18766
+ * with one property callback clause the example will use multiple clauses for
18767
+ * the sake of simplicity:
18768
+ * ```
18769
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
18770
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
18771
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
18772
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
18773
+ * // We fully spelled out the function signature above but archContainingObject and propName are
18774
+ * // not needed in this case. The archContainingObject is the object that contains the
18775
+ * // property and propName is the property name itself. We pass in propName because the same
18776
+ * // function could be used for multiple property callback clauses.
18777
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
18778
+ * return propValue && propValue.toLowerCase() === 'foo';
18779
+ * });
18780
+ * archTask.traverse(function(traverseContext) {
18781
+ * // You will only be called back here for ArchBaseCoreObject instances that
18782
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
18783
+ * }, myTraverseFilter);
18784
+ * ```
18785
+ * If you supply a filter with no clauses, this tells the traverse method to
18786
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
18787
+ *
18788
+ * If you want traversal itself to stop after a callback, simply return boolean
18789
+ * false from the callback function you supply to the traverse call.
18790
+ *
18791
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
18792
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
18793
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
18794
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
18795
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
18796
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
18797
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
18798
+ *
18799
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
18800
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
18801
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
18802
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
18803
+ *
18804
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
18805
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
18806
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
18807
+ *
18808
+ * This function returns the number of times it called the callback function.
18809
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
18810
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
18811
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
18812
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
18813
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
18814
+ */
18815
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
18816
+ /**
18817
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
18818
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
18819
+ * logging str contents wouldn't be set up.
18820
+ */
18821
+ readonly logStrTypeOnly: string;
18822
+ /**
18823
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
18824
+ * @param errorStr - the error string to log.
18825
+ */
18826
+ logError(errorStr: string): void;
18827
+ /**
18828
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
18829
+ * the string in the errorStr parameter.
18830
+ * @param errorStr - the error string to log. This should be a non-blank string.
18831
+ */
18832
+ logErrorAndThrow(errorStr: string): void;
18833
+ /**
18834
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
18835
+ * @param noteStr - the note string to log. This should be a non-blank string.
18836
+ */
18837
+ logNote(noteStr: string): void;
18838
+ /**
18839
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
18840
+ * @param noteStr - the note string to log. This should be a non-blank string.
18841
+ */
18842
+ logNoteVerbose(noteStr: string): void;
18843
+ /**
18844
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
18845
+ * @param warningStr - the warning string to log. This should be a non-blank string.
18846
+ */
18847
+ logWarning(warningStr: string): void;
18848
+ /**
18849
+ * Returns whether or not this Architect Scripting object is a match
18850
+ * for the supplied ArchFilterObject instance.
18851
+ * @param archFilterObject - the object filter to use to determine if it's a match.
18852
+ */
18853
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
18854
+ }
18855
+
18856
+ export class ArchBaseFlowInQueueWorkflow extends ArchBaseFlowWorkflow {
18857
+ // constructor(coreInQueueDigitalFlow: any);
18858
+ /**
18859
+ * Returns the display type name string 'ArchBaseFlowInQueueWorkflow'.
18860
+ */
18861
+ readonly displayTypeName: string;
18862
+ /**
18863
+ * Returns true indicating that this is an ArchBaseFlowInQueueWorkflow object.
18864
+ * This will be true for in-queue email and in-queue short message flows.
18865
+ */
18866
+ readonly isArchBaseFlowInQueueWorkflow: boolean;
18867
+ /**
18868
+ * Returns the periodic state for this flow.
18869
+ */
18870
+ readonly periodicState: ArchState;
18871
+ /**
18872
+ * This function deletes the specified state from this flow.
18873
+ * @param stateToDelete - the state to delete.
18874
+ */
18875
+ deleteState(stateToDelete: ArchState): void;
18876
+ /**
18877
+ * Sets the specified state to be the starting state on the flow.
18878
+ * @param archState - An Architect Scripting state object.
18879
+ */
18880
+ setStartingState(archState: ArchState): void;
18881
+ /**
18882
+ * Returns the starting state for this flow.
18883
+ * If there is no startup object configured, accessing this property returns null.
18884
+ */
18885
+ readonly startUpObject: ArchState;
18886
+ /**
18887
+ * The states in the flow.
18888
+ */
18889
+ readonly states: ArchState[];
18890
+ /**
18891
+ * This function deletes the specified reusable task from this flow.
18892
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
18893
+ * property on the specified task instance is true.
18894
+ */
18895
+ deleteTask(taskToDelete: ArchTask): void;
18896
+ /**
18897
+ * Returns an array of the currently defined reusable tasks for this flow.
18898
+ */
18899
+ readonly tasksReusable: ArchTask[];
18900
+ /**
18901
+ * This adds a new variable to the flow.
18902
+ * @param name - the name of the variable to add. Remember that variable names must
18903
+ * start with a letter and can then be followed by one or more letters, numbers
18904
+ * or underscore characters to be valid. Submitting the variable scope on the name
18905
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
18906
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
18907
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
18908
+ * @param type - the data type for the new variable. Remember that type must be supported
18909
+ * in the flow type for which you're looking to add the variable. If you are
18910
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
18911
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
18912
+ * @param [description] - the description for the new variable.
18913
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
18914
+ */
18915
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
18916
+ /**
18917
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
18918
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
18919
+ * @param archVariable - the flow scoped variable you wish to delete
18920
+ * @returns - true if the variable was removed successfully, false otherwise.
18921
+ */
18922
+ removeVariable(archVariable: ArchBaseVariable): boolean;
18923
+ /**
18924
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
18925
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
18926
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
18927
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
18928
+ */
18929
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
18930
+ /**
18931
+ * Returns the division associated with this flow.
18932
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
18933
+ * If not available, nothing is returned.
18934
+ */
18935
+ readonly division: ArchDivision;
18936
+ /**
18937
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
18938
+ * longer be considered valid after loading new configuration.
18939
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
18940
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
18941
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
18942
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
18943
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
18944
+ */
18945
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
18946
+ /**
18947
+ * Returns a string suitable for logging that describes the flow
18948
+ */
18949
+ readonly logStr: string;
18950
+ /**
18951
+ * Unlocks this flow.
18952
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
18953
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
18954
+ */
18955
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
18956
+ /**
18957
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
18958
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
18959
+ * value.
18960
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
18961
+ * language must have at least one region sub-tag.
18962
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
18963
+ */
18964
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
18965
+ /**
18966
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
18967
+ * if any or more than one can be added.
18968
+ */
18969
+ canAddSupportedLanguage(): boolean;
18970
+ /**
18971
+ * Checks in and unlocks the flow for the current user, does a save first
18972
+ * Assumes the flow has been created, throws if not
18973
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
18974
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
18975
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18976
+ * flow instance.
18977
+ */
18978
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
18979
+ /**
18980
+ * Creates a new flow on the server and saves its configuration
18981
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
18982
+ * flow instance.
18983
+ */
18984
+ createAsync(): Promise<any>;
18985
+ /**
18986
+ * Accessing this property returns an object with properties whose keys are data type names and values are
18987
+ * {@link ArchDataType} instances.
18988
+ */
18989
+ readonly dataTypes: any;
18990
+ /**
18991
+ * The description of the flow
18992
+ */
18993
+ description: string;
18994
+ /**
18995
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
18996
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
18997
+ * browser.
18998
+ * @param [destinationDir] - the directory where the flow export should be saved.
18999
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
19000
+ * flow export was saved.
19001
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19002
+ * it will default to the Architect format.
19003
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19004
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19005
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19006
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19007
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19008
+ */
19009
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
19010
+ /**
19011
+ * Exports the flow to a JSON object. The object passed back in the callback function
19012
+ * will be a JSON object with a content and fileName property where the content holds
19013
+ * the flow export contents and the fileName property holds the file name where the
19014
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
19015
+ * @param callbackFunction - the function to call back with the export information contained
19016
+ * in the parameter passed to it.
19017
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19018
+ * it will default to the Architect format.
19019
+ */
19020
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
19021
+ /**
19022
+ * The type of the flow. The string
19023
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
19024
+ */
19025
+ readonly flowType: string;
19026
+ /**
19027
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
19028
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
19029
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
19030
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
19031
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
19032
+ * browser.
19033
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
19034
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
19035
+ * working directory.
19036
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
19037
+ * formats. If no format is supplied, it will use the Architect format.
19038
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19039
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19040
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19041
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19042
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19043
+ */
19044
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
19045
+ /**
19046
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
19047
+ * If the variable name cannot be found, nothing is returned.
19048
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
19049
+ */
19050
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
19051
+ /**
19052
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
19053
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
19054
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
19055
+ */
19056
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
19057
+ /**
19058
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
19059
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
19060
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19061
+ * do work with the flow on which this is being called until the callback is called.
19062
+ * @param exportContent - the contents from a flow export.
19063
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19064
+ * on this flow. The first parameter passed to the callback function will be this
19065
+ * Architect flow instance.
19066
+ */
19067
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19068
+ /**
19069
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
19070
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19071
+ * do work with the flow on which this is being called until the callback is called.
19072
+ * Also note that this method should not be used if running in a browser.
19073
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
19074
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19075
+ * on this flow. The first parameter passed to the callback function will be this
19076
+ * Architect flow instance.
19077
+ */
19078
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19079
+ /**
19080
+ * Returns whether or not the flow is created in Genesys Cloud.
19081
+ */
19082
+ readonly isCreated: boolean;
19083
+ /**
19084
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
19085
+ * scripting but not saved, checked in or published will report that they are not read-only.
19086
+ */
19087
+ readonly isReadOnly: boolean;
19088
+ /**
19089
+ * Returns whether or not the flow is secure. That means it contains something that is
19090
+ * secure like a secure variable or secure action.
19091
+ */
19092
+ readonly isSecure: boolean;
19093
+ /**
19094
+ * Returns true indicating the flow acts as a variable container which means you can
19095
+ * add variables to it.
19096
+ */
19097
+ readonly isVariableContainer: boolean;
19098
+ /**
19099
+ * The language settings for the flow. This property is now deprecated.
19100
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
19101
+ */
19102
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
19103
+ /**
19104
+ * The name of the flow
19105
+ */
19106
+ name: string;
19107
+ /**
19108
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
19109
+ * steps can fail and reject the promise. Operations are not atomic.
19110
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
19111
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
19112
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19113
+ * flow instance.
19114
+ */
19115
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
19116
+ /**
19117
+ * Save the current flow configuration, creating the flow if needed.
19118
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19119
+ * flow instance.
19120
+ */
19121
+ saveAsync(): Promise<any>;
19122
+ /**
19123
+ * Returns the error handling settings for the flow.
19124
+ */
19125
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlow;
19126
+ /**
19127
+ * Returns the action default settings for the flow.
19128
+ */
19129
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
19130
+ /**
19131
+ * The supported language settings for the flow.
19132
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
19133
+ * to calling this method to see if a flow supports languages or not.
19134
+ */
19135
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
19136
+ /**
19137
+ * Returns whether or not this flow supports audio channel.
19138
+ */
19139
+ readonly supportsAudio: boolean;
19140
+ /**
19141
+ * Returns whether or not this flow supports error handling.
19142
+ */
19143
+ readonly supportsErrorHandling: boolean;
19144
+ /**
19145
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
19146
+ * when creating it to use English United States.
19147
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
19148
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
19149
+ */
19150
+ readonly supportsLanguages: boolean;
19151
+ /**
19152
+ * Returns whether or not this flow supports setting a supported language as the default.
19153
+ */
19154
+ readonly supportsDefaultLanguage: boolean;
19155
+ /**
19156
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
19157
+ * the returned URL will be blank.
19158
+ */
19159
+ readonly url: string;
19160
+ /**
19161
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
19162
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
19163
+ * validation results.
19164
+ */
19165
+ validateAsync(): Promise<ArchValidationResults>;
19166
+ /**
19167
+ * Returns an array of variables defined at the flow scope for this flow.
19168
+ */
19169
+ readonly variables: ArchBaseVariable[];
19170
+ /**
19171
+ * The identifier string for this object.
19172
+ */
19173
+ readonly id: string;
19174
+ /**
19175
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
19176
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
19177
+ * an extremely rare case.
19178
+ */
19179
+ readonly idMayBeBlank: string;
19180
+ /**
19181
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
19182
+ */
19183
+ readonly isArchBaseCoreObject: boolean;
19184
+ /**
19185
+ * This method iterates over this object and ArchBaseCoreObject instances
19186
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
19187
+ * with a filter and call the supplied callback function if isMatch returns true.
19188
+ * The callback will be passed an {@link ArchTraverseInfo} with details
19189
+ * about the match such as the match object itself along with current contextual
19190
+ * information such as the object hierarchy for the match object relative to
19191
+ * the object on which this traverse call is being made.
19192
+ *
19193
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
19194
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
19195
+ * or clause containers to it. If not specified, this function will use a
19196
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
19197
+ *
19198
+ * Here is an example that does a simple flow traversal using the default
19199
+ * filter and logs information about objects in the callback from the
19200
+ * traverse object that's passed back:
19201
+ *
19202
+ * ```
19203
+ * archInboundCallFlow.traverse(function(traverseInfo) {
19204
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
19205
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
19206
+ * });
19207
+ * ```
19208
+ * This might be enough for most uses and you can check various aspects
19209
+ * about the object in the callback such as "is this an Architect action?" by
19210
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
19211
+ * a filter for the traversal code to use as well and only have it call your
19212
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
19213
+ * the filter. Here's an example that creates a filter for callbacks on
19214
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
19215
+ * [decision action]{@link ArchActionDecision} or objects whose name
19216
+ * property case insensitively matches the word 'foo'. While this could all be done
19217
+ * with one property callback clause the example will use multiple clauses for
19218
+ * the sake of simplicity:
19219
+ * ```
19220
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
19221
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
19222
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
19223
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
19224
+ * // We fully spelled out the function signature above but archContainingObject and propName are
19225
+ * // not needed in this case. The archContainingObject is the object that contains the
19226
+ * // property and propName is the property name itself. We pass in propName because the same
19227
+ * // function could be used for multiple property callback clauses.
19228
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
19229
+ * return propValue && propValue.toLowerCase() === 'foo';
19230
+ * });
19231
+ * archTask.traverse(function(traverseContext) {
19232
+ * // You will only be called back here for ArchBaseCoreObject instances that
19233
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
19234
+ * }, myTraverseFilter);
19235
+ * ```
19236
+ * If you supply a filter with no clauses, this tells the traverse method to
19237
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
19238
+ *
19239
+ * If you want traversal itself to stop after a callback, simply return boolean
19240
+ * false from the callback function you supply to the traverse call.
19241
+ *
19242
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
19243
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
19244
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
19245
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
19246
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
19247
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
19248
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
19249
+ *
19250
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
19251
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
19252
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
19253
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
19254
+ *
19255
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
19256
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
19257
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
19258
+ *
19259
+ * This function returns the number of times it called the callback function.
19260
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
19261
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
19262
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
19263
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
19264
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
19265
+ */
19266
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
19267
+ /**
19268
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
19269
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
19270
+ * logging str contents wouldn't be set up.
19271
+ */
19272
+ readonly logStrTypeOnly: string;
19273
+ /**
19274
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
19275
+ * @param errorStr - the error string to log.
19276
+ */
19277
+ logError(errorStr: string): void;
19278
+ /**
19279
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
19280
+ * the string in the errorStr parameter.
19281
+ * @param errorStr - the error string to log. This should be a non-blank string.
19282
+ */
19283
+ logErrorAndThrow(errorStr: string): void;
19284
+ /**
19285
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
19286
+ * @param noteStr - the note string to log. This should be a non-blank string.
19287
+ */
19288
+ logNote(noteStr: string): void;
19289
+ /**
19290
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
19291
+ * @param noteStr - the note string to log. This should be a non-blank string.
19292
+ */
19293
+ logNoteVerbose(noteStr: string): void;
19294
+ /**
19295
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
19296
+ * @param warningStr - the warning string to log. This should be a non-blank string.
19297
+ */
19298
+ logWarning(warningStr: string): void;
19299
+ /**
19300
+ * Returns whether or not this Architect Scripting object is a match
19301
+ * for the supplied ArchFilterObject instance.
19302
+ * @param archFilterObject - the object filter to use to determine if it's a match.
19303
+ */
19304
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
19305
+ }
19306
+
19307
+ export class ArchBaseFlowInboundOutboundSecureCall extends ArchBaseFlowWithMenus {
19308
+ // constructor(coreInboundOutboundSecureFlowViewModel: any);
19309
+ /**
19310
+ * Returns the display type name string 'ArchBaseFlowInboundOutboundSecureCall'.
19311
+ */
19312
+ readonly displayTypeName: string;
19313
+ /**
19314
+ * The initial audio set on the flow.
19315
+ */
19316
+ readonly initialAudio: ArchAudio;
19317
+ /**
19318
+ * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
19319
+ */
19320
+ readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
19321
+ /**
19322
+ * Sets the specified menu to be the starting task on the flow.
19323
+ * @param archMenu - An Architect Scripting menu object.
19324
+ */
19325
+ setStartingMenu(archMenu: ArchMenu): void;
19326
+ /**
19327
+ * Sets the specified task to be the starting task on the flow.
19328
+ * @param archTask - An Architect Scripting task object.
19329
+ */
19330
+ setStartingTask(archTask: ArchTask): void;
19331
+ /**
19332
+ * The menu settings for the flow.
19333
+ */
19334
+ readonly settingsMenu: ArchSettingsMenuFlow;
19335
+ /**
19336
+ * The prompt settings for the flow.
19337
+ */
19338
+ readonly settingsPrompts: ArchSettingsPromptsFlow;
19339
+ /**
19340
+ * The speech rec settings for the flow.
19341
+ */
19342
+ readonly settingsSpeechRec: ArchSettingsSpeechRecFlow;
19343
+ /**
19344
+ * Returns the starting task or menu for this call flow.
19345
+ * If there is no startup object configured, accessing this property returns null.
19346
+ */
19347
+ readonly startUpObject: ArchTask | ArchMenu | null;
19348
+ /**
19349
+ * The outbound settings for the flow such as contact list and default wrapup code.
19350
+ */
19351
+ readonly settingsOutboundCall: ArchSettingsOutboundCallFlow;
19352
+ /**
19353
+ * This function deletes the specified reusable menu from this flow.
19354
+ * @param menuToDelete - the menu to delete. This must be a reusable menu which means the {@link ArchMenu#isReusableMenu}
19355
+ * property on the specified menu instance is true.
19356
+ */
19357
+ deleteMenu(menuToDelete: ArchMenu): void;
19358
+ /**
19359
+ * Returns an array of the currently defined reusable menus for this flow.
19360
+ */
19361
+ readonly menusReusable: ArchBaseMenu[];
19362
+ /**
19363
+ * This function deletes the specified reusable task from this flow.
19364
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
19365
+ * property on the specified task instance is true.
19366
+ */
19367
+ deleteTask(taskToDelete: ArchTask): void;
19368
+ /**
19369
+ * Returns an array of the currently defined reusable tasks for this flow.
19370
+ */
19371
+ readonly tasksReusable: ArchTask[];
19372
+ /**
19373
+ * This adds a new variable to the flow.
19374
+ * @param name - the name of the variable to add. Remember that variable names must
19375
+ * start with a letter and can then be followed by one or more letters, numbers
19376
+ * or underscore characters to be valid. Submitting the variable scope on the name
19377
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
19378
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
19379
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
19380
+ * @param type - the data type for the new variable. Remember that type must be supported
19381
+ * in the flow type for which you're looking to add the variable. If you are
19382
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
19383
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
19384
+ * @param [description] - the description for the new variable.
19385
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
19386
+ */
19387
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
19388
+ /**
19389
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
19390
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
19391
+ * @param archVariable - the flow scoped variable you wish to delete
19392
+ * @returns - true if the variable was removed successfully, false otherwise.
19393
+ */
19394
+ removeVariable(archVariable: ArchBaseVariable): boolean;
19395
+ /**
19396
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
19397
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
19398
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
19399
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
19400
+ */
19401
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
19402
+ /**
19403
+ * Returns the division associated with this flow.
19404
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
19405
+ * If not available, nothing is returned.
19406
+ */
19407
+ readonly division: ArchDivision;
19408
+ /**
19409
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
19410
+ * longer be considered valid after loading new configuration.
19411
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
19412
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
19413
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
19414
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
19415
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
19416
+ */
19417
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
19418
+ /**
19419
+ * Returns a string suitable for logging that describes the flow
19420
+ */
19421
+ readonly logStr: string;
19422
+ /**
19423
+ * Unlocks this flow.
19424
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
19425
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
19426
+ */
19427
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
19428
+ /**
19429
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
19430
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
19431
+ * value.
19432
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
19433
+ * language must have at least one region sub-tag.
19434
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
19435
+ */
19436
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
19437
+ /**
19438
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
19439
+ * if any or more than one can be added.
19440
+ */
19441
+ canAddSupportedLanguage(): boolean;
19442
+ /**
19443
+ * Checks in and unlocks the flow for the current user, does a save first
19444
+ * Assumes the flow has been created, throws if not
19445
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
19446
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
19447
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19448
+ * flow instance.
19449
+ */
19450
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
19451
+ /**
19452
+ * Creates a new flow on the server and saves its configuration
19453
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19454
+ * flow instance.
19455
+ */
19456
+ createAsync(): Promise<any>;
19457
+ /**
19458
+ * Accessing this property returns an object with properties whose keys are data type names and values are
19459
+ * {@link ArchDataType} instances.
19460
+ */
19461
+ readonly dataTypes: any;
19462
+ /**
19463
+ * The description of the flow
19464
+ */
19465
+ description: string;
19466
+ /**
19467
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
19468
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
19469
+ * browser.
19470
+ * @param [destinationDir] - the directory where the flow export should be saved.
19471
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
19472
+ * flow export was saved.
19473
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19474
+ * it will default to the Architect format.
19475
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19476
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19477
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19478
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19479
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19480
+ */
19481
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
19482
+ /**
19483
+ * Exports the flow to a JSON object. The object passed back in the callback function
19484
+ * will be a JSON object with a content and fileName property where the content holds
19485
+ * the flow export contents and the fileName property holds the file name where the
19486
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
19487
+ * @param callbackFunction - the function to call back with the export information contained
19488
+ * in the parameter passed to it.
19489
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19490
+ * it will default to the Architect format.
19491
+ */
19492
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
19493
+ /**
19494
+ * The type of the flow. The string
19495
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
19496
+ */
19497
+ readonly flowType: string;
19498
+ /**
19499
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
19500
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
19501
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
19502
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
19503
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
19504
+ * browser.
19505
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
19506
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
19507
+ * working directory.
19508
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
19509
+ * formats. If no format is supplied, it will use the Architect format.
19510
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19511
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19512
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19513
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19514
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19515
+ */
19516
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
19517
+ /**
19518
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
19519
+ * If the variable name cannot be found, nothing is returned.
19520
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
19521
+ */
19522
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
19523
+ /**
19524
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
19525
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
19526
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
19527
+ */
19528
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
19529
+ /**
19530
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
19531
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
19532
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19533
+ * do work with the flow on which this is being called until the callback is called.
19534
+ * @param exportContent - the contents from a flow export.
19535
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19536
+ * on this flow. The first parameter passed to the callback function will be this
19537
+ * Architect flow instance.
19538
+ */
19539
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19540
+ /**
19541
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
19542
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19543
+ * do work with the flow on which this is being called until the callback is called.
19544
+ * Also note that this method should not be used if running in a browser.
19545
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
19546
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19547
+ * on this flow. The first parameter passed to the callback function will be this
19548
+ * Architect flow instance.
19549
+ */
19550
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19551
+ /**
19552
+ * Returns whether or not the flow is created in Genesys Cloud.
19553
+ */
19554
+ readonly isCreated: boolean;
19555
+ /**
19556
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
19557
+ * scripting but not saved, checked in or published will report that they are not read-only.
19558
+ */
19559
+ readonly isReadOnly: boolean;
19560
+ /**
19561
+ * Returns whether or not the flow is secure. That means it contains something that is
19562
+ * secure like a secure variable or secure action.
19563
+ */
19564
+ readonly isSecure: boolean;
19565
+ /**
19566
+ * Returns true indicating the flow acts as a variable container which means you can
19567
+ * add variables to it.
19568
+ */
19569
+ readonly isVariableContainer: boolean;
19570
+ /**
19571
+ * The language settings for the flow. This property is now deprecated.
19572
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
19573
+ */
19574
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
19575
+ /**
19576
+ * The name of the flow
19577
+ */
19578
+ name: string;
19579
+ /**
19580
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
19581
+ * steps can fail and reject the promise. Operations are not atomic.
19582
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
19583
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
19584
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19585
+ * flow instance.
19586
+ */
19587
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
19588
+ /**
19589
+ * Save the current flow configuration, creating the flow if needed.
19590
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19591
+ * flow instance.
19592
+ */
19593
+ saveAsync(): Promise<any>;
19594
+ /**
19595
+ * Returns the error handling settings for the flow.
19596
+ */
19597
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlow;
19598
+ /**
19599
+ * Returns the action default settings for the flow.
19600
+ */
19601
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
19602
+ /**
19603
+ * The supported language settings for the flow.
19604
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
19605
+ * to calling this method to see if a flow supports languages or not.
19606
+ */
19607
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
19608
+ /**
19609
+ * Returns whether or not this flow supports audio channel.
19610
+ */
19611
+ readonly supportsAudio: boolean;
19612
+ /**
19613
+ * Returns whether or not this flow supports error handling.
19614
+ */
19615
+ readonly supportsErrorHandling: boolean;
19616
+ /**
19617
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
19618
+ * when creating it to use English United States.
19619
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
19620
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
19621
+ */
19622
+ readonly supportsLanguages: boolean;
19623
+ /**
19624
+ * Returns whether or not this flow supports setting a supported language as the default.
19625
+ */
19626
+ readonly supportsDefaultLanguage: boolean;
19627
+ /**
19628
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
19629
+ * the returned URL will be blank.
19630
+ */
19631
+ readonly url: string;
19632
+ /**
19633
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
19634
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
19635
+ * validation results.
19636
+ */
19637
+ validateAsync(): Promise<ArchValidationResults>;
19638
+ /**
19639
+ * Returns an array of variables defined at the flow scope for this flow.
19640
+ */
19641
+ readonly variables: ArchBaseVariable[];
19642
+ /**
19643
+ * The identifier string for this object.
19644
+ */
19645
+ readonly id: string;
19646
+ /**
19647
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
19648
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
19649
+ * an extremely rare case.
19650
+ */
19651
+ readonly idMayBeBlank: string;
19652
+ /**
19653
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
19654
+ */
19655
+ readonly isArchBaseCoreObject: boolean;
19656
+ /**
19657
+ * This method iterates over this object and ArchBaseCoreObject instances
19658
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
19659
+ * with a filter and call the supplied callback function if isMatch returns true.
19660
+ * The callback will be passed an {@link ArchTraverseInfo} with details
19661
+ * about the match such as the match object itself along with current contextual
19662
+ * information such as the object hierarchy for the match object relative to
19663
+ * the object on which this traverse call is being made.
19664
+ *
19665
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
19666
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
19667
+ * or clause containers to it. If not specified, this function will use a
19668
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
19669
+ *
19670
+ * Here is an example that does a simple flow traversal using the default
19671
+ * filter and logs information about objects in the callback from the
19672
+ * traverse object that's passed back:
19673
+ *
19674
+ * ```
19675
+ * archInboundCallFlow.traverse(function(traverseInfo) {
19676
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
19677
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
19678
+ * });
19679
+ * ```
19680
+ * This might be enough for most uses and you can check various aspects
19681
+ * about the object in the callback such as "is this an Architect action?" by
19682
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
19683
+ * a filter for the traversal code to use as well and only have it call your
19684
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
19685
+ * the filter. Here's an example that creates a filter for callbacks on
19686
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
19687
+ * [decision action]{@link ArchActionDecision} or objects whose name
19688
+ * property case insensitively matches the word 'foo'. While this could all be done
19689
+ * with one property callback clause the example will use multiple clauses for
19690
+ * the sake of simplicity:
19691
+ * ```
19692
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
19693
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
19694
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
19695
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
19696
+ * // We fully spelled out the function signature above but archContainingObject and propName are
19697
+ * // not needed in this case. The archContainingObject is the object that contains the
19698
+ * // property and propName is the property name itself. We pass in propName because the same
19699
+ * // function could be used for multiple property callback clauses.
19700
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
19701
+ * return propValue && propValue.toLowerCase() === 'foo';
19702
+ * });
19703
+ * archTask.traverse(function(traverseContext) {
19704
+ * // You will only be called back here for ArchBaseCoreObject instances that
19705
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
19706
+ * }, myTraverseFilter);
19707
+ * ```
19708
+ * If you supply a filter with no clauses, this tells the traverse method to
19709
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
19710
+ *
19711
+ * If you want traversal itself to stop after a callback, simply return boolean
19712
+ * false from the callback function you supply to the traverse call.
19713
+ *
19714
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
19715
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
19716
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
19717
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
19718
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
19719
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
19720
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
19721
+ *
19722
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
19723
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
19724
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
19725
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
19726
+ *
19727
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
19728
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
19729
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
19730
+ *
19731
+ * This function returns the number of times it called the callback function.
19732
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
19733
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
19734
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
19735
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
19736
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
19737
+ */
19738
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
19739
+ /**
19740
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
19741
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
19742
+ * logging str contents wouldn't be set up.
19743
+ */
19744
+ readonly logStrTypeOnly: string;
19745
+ /**
19746
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
19747
+ * @param errorStr - the error string to log.
19748
+ */
19749
+ logError(errorStr: string): void;
19750
+ /**
19751
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
19752
+ * the string in the errorStr parameter.
19753
+ * @param errorStr - the error string to log. This should be a non-blank string.
19754
+ */
19755
+ logErrorAndThrow(errorStr: string): void;
19756
+ /**
19757
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
19758
+ * @param noteStr - the note string to log. This should be a non-blank string.
19759
+ */
19760
+ logNote(noteStr: string): void;
19761
+ /**
19762
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
19763
+ * @param noteStr - the note string to log. This should be a non-blank string.
19764
+ */
19765
+ logNoteVerbose(noteStr: string): void;
19766
+ /**
19767
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
19768
+ * @param warningStr - the warning string to log. This should be a non-blank string.
19769
+ */
19770
+ logWarning(warningStr: string): void;
19771
+ /**
19772
+ * Returns whether or not this Architect Scripting object is a match
19773
+ * for the supplied ArchFilterObject instance.
19774
+ * @param archFilterObject - the object filter to use to determine if it's a match.
19775
+ */
19776
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
19777
+ }
19778
+
19779
+ export class ArchBaseFlowWithMenus extends ArchBaseFlowWithTasks {
19780
+ // constructor(coreFlowViewModel: any);
19781
+ /**
19782
+ * This function deletes the specified reusable menu from this flow.
19783
+ * @param menuToDelete - the menu to delete. This must be a reusable menu which means the {@link ArchMenu#isReusableMenu}
19784
+ * property on the specified menu instance is true.
19785
+ */
19786
+ deleteMenu(menuToDelete: ArchMenu): void;
19787
+ /**
19788
+ * Returns an array of the currently defined reusable menus for this flow.
19789
+ */
19790
+ readonly menusReusable: ArchBaseMenu[];
19791
+ /**
19792
+ * This function deletes the specified reusable task from this flow.
19793
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
19794
+ * property on the specified task instance is true.
19795
+ */
19796
+ deleteTask(taskToDelete: ArchTask): void;
19797
+ /**
19798
+ * Returns an array of the currently defined reusable tasks for this flow.
19799
+ */
19800
+ readonly tasksReusable: ArchTask[];
19801
+ /**
19802
+ * This adds a new variable to the flow.
19803
+ * @param name - the name of the variable to add. Remember that variable names must
19804
+ * start with a letter and can then be followed by one or more letters, numbers
19805
+ * or underscore characters to be valid. Submitting the variable scope on the name
19806
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
19807
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
19808
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
19809
+ * @param type - the data type for the new variable. Remember that type must be supported
19810
+ * in the flow type for which you're looking to add the variable. If you are
19811
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
19812
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
19813
+ * @param [description] - the description for the new variable.
19814
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
19815
+ */
19816
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
19817
+ /**
19818
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
19819
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
19820
+ * @param archVariable - the flow scoped variable you wish to delete
19821
+ * @returns - true if the variable was removed successfully, false otherwise.
19822
+ */
19823
+ removeVariable(archVariable: ArchBaseVariable): boolean;
19824
+ /**
19825
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
19826
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
19827
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
19828
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
19829
+ */
19830
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
19831
+ /**
19832
+ * Returns the division associated with this flow.
19833
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
19834
+ * If not available, nothing is returned.
19835
+ */
19836
+ readonly division: ArchDivision;
19837
+ /**
19838
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
19839
+ * longer be considered valid after loading new configuration.
19840
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
19841
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
19842
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
19843
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
19844
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
19845
+ */
19846
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
19847
+ /**
19848
+ * Returns a string suitable for logging that describes the flow
19849
+ */
19850
+ readonly logStr: string;
19851
+ /**
19852
+ * Unlocks this flow.
19853
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
19854
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
19855
+ */
19856
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
19857
+ /**
19858
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
19859
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
19860
+ * value.
19861
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
19862
+ * language must have at least one region sub-tag.
19863
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
19864
+ */
19865
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
19866
+ /**
19867
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
19868
+ * if any or more than one can be added.
19869
+ */
19870
+ canAddSupportedLanguage(): boolean;
19871
+ /**
19872
+ * Checks in and unlocks the flow for the current user, does a save first
19873
+ * Assumes the flow has been created, throws if not
19874
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
19875
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
19876
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19877
+ * flow instance.
19878
+ */
19879
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
19880
+ /**
19881
+ * Creates a new flow on the server and saves its configuration
19882
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
19883
+ * flow instance.
19884
+ */
19885
+ createAsync(): Promise<any>;
19886
+ /**
19887
+ * Accessing this property returns an object with properties whose keys are data type names and values are
19888
+ * {@link ArchDataType} instances.
19889
+ */
19890
+ readonly dataTypes: any;
19891
+ /**
19892
+ * The description of the flow
19893
+ */
19894
+ description: string;
19895
+ /**
19896
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
19897
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
19898
+ * browser.
19899
+ * @param [destinationDir] - the directory where the flow export should be saved.
19900
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
19901
+ * flow export was saved.
19902
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19903
+ * it will default to the Architect format.
19904
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19905
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19906
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19907
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19908
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19909
+ */
19910
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
19911
+ /**
19912
+ * Exports the flow to a JSON object. The object passed back in the callback function
19913
+ * will be a JSON object with a content and fileName property where the content holds
19914
+ * the flow export contents and the fileName property holds the file name where the
19915
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
19916
+ * @param callbackFunction - the function to call back with the export information contained
19917
+ * in the parameter passed to it.
19918
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
19919
+ * it will default to the Architect format.
19920
+ */
19921
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
19922
+ /**
19923
+ * The type of the flow. The string
19924
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
19925
+ */
19926
+ readonly flowType: string;
19927
+ /**
19928
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
19929
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
19930
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
19931
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
19932
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
19933
+ * browser.
19934
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
19935
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
19936
+ * working directory.
19937
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
19938
+ * formats. If no format is supplied, it will use the Architect format.
19939
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
19940
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
19941
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
19942
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
19943
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
19944
+ */
19945
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
19946
+ /**
19947
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
19948
+ * If the variable name cannot be found, nothing is returned.
19949
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
19950
+ */
19951
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
19952
+ /**
19953
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
19954
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
19955
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
19956
+ */
19957
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
19958
+ /**
19959
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
19960
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
19961
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19962
+ * do work with the flow on which this is being called until the callback is called.
19963
+ * @param exportContent - the contents from a flow export.
19964
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19965
+ * on this flow. The first parameter passed to the callback function will be this
19966
+ * Architect flow instance.
19967
+ */
19968
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19969
+ /**
19970
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
19971
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
19972
+ * do work with the flow on which this is being called until the callback is called.
19973
+ * Also note that this method should not be used if running in a browser.
19974
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
19975
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
19976
+ * on this flow. The first parameter passed to the callback function will be this
19977
+ * Architect flow instance.
19978
+ */
19979
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
19980
+ /**
19981
+ * Returns whether or not the flow is created in Genesys Cloud.
19982
+ */
19983
+ readonly isCreated: boolean;
19984
+ /**
19985
+ * Returns whether or not the flow is read-only. Flows that have been created locally in
19986
+ * scripting but not saved, checked in or published will report that they are not read-only.
19987
+ */
19988
+ readonly isReadOnly: boolean;
19989
+ /**
19990
+ * Returns whether or not the flow is secure. That means it contains something that is
19991
+ * secure like a secure variable or secure action.
19992
+ */
19993
+ readonly isSecure: boolean;
19994
+ /**
19995
+ * Returns true indicating the flow acts as a variable container which means you can
19996
+ * add variables to it.
19997
+ */
19998
+ readonly isVariableContainer: boolean;
19999
+ /**
20000
+ * The language settings for the flow. This property is now deprecated.
20001
+ * Please replace calls to this property with {@link ArchBaseFlow#settingsSupportedLanguages} instead.
20002
+ */
20003
+ readonly languageSettings: ArchSettingsSupportedLanguagesFlow;
20004
+ /**
20005
+ * The name of the flow
20006
+ */
20007
+ name: string;
20008
+ /**
20009
+ * Publishes the flow. This will do a validate, save, checkin and then publish last. Any of these
20010
+ * steps can fail and reject the promise. Operations are not atomic.
20011
+ * @param [ensureSearchable] - whether or not to poll after successful publish to ensure that the flow is available for flow
20012
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
20013
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
20014
+ * flow instance.
20015
+ */
20016
+ publishAsync(ensureSearchable?: boolean): Promise<any>;
20017
+ /**
20018
+ * Save the current flow configuration, creating the flow if needed.
20019
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
20020
+ * flow instance.
20021
+ */
20022
+ saveAsync(): Promise<any>;
20023
+ /**
20024
+ * Returns the error handling settings for the flow.
20025
+ */
20026
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlow;
20027
+ /**
20028
+ * Returns the action default settings for the flow.
20029
+ */
20030
+ readonly settingsActionDefaults: ArchSettingsActionDefaults;
20031
+ /**
20032
+ * The supported language settings for the flow.
20033
+ * This method will throw if the flow doesn't support languages. You can check {@link ArchBaseFlow#supportsLanguages} prior
20034
+ * to calling this method to see if a flow supports languages or not.
20035
+ */
20036
+ readonly settingsSupportedLanguages: ArchSettingsSupportedLanguagesFlow;
20037
+ /**
20038
+ * Returns whether or not this flow supports audio channel.
20039
+ */
20040
+ readonly supportsAudio: boolean;
20041
+ /**
20042
+ * Returns whether or not this flow supports error handling.
20043
+ */
20044
+ readonly supportsErrorHandling: boolean;
20045
+ /**
20046
+ * Returns whether or not this flow supports languages. If false, that means you have to configure the flow
20047
+ * when creating it to use English United States.
20048
+ * Note: At this time this functionality is available while we're determining the needs of workflow and
20049
+ * inbound email flow types. This property may go away in a future release of Architect Scripting.
20050
+ */
20051
+ readonly supportsLanguages: boolean;
20052
+ /**
20053
+ * Returns whether or not this flow supports setting a supported language as the default.
20054
+ */
20055
+ readonly supportsDefaultLanguage: boolean;
20056
+ /**
20057
+ * Returns a URL for this flow. If the flow has not been created or there is no startup object set on the flow,
20058
+ * the returned URL will be blank.
20059
+ */
20060
+ readonly url: string;
20061
+ /**
20062
+ * Validates the flow. Promise returns an {@link ArchValidationResults} instance.
20063
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be the
20064
+ * validation results.
20065
+ */
20066
+ validateAsync(): Promise<ArchValidationResults>;
20067
+ /**
20068
+ * Returns an array of variables defined at the flow scope for this flow.
20069
+ */
20070
+ readonly variables: ArchBaseVariable[];
20071
+ /**
20072
+ * The identifier string for this object.
20073
+ */
20074
+ readonly id: string;
20075
+ /**
20076
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
20077
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
20078
+ * an extremely rare case.
20079
+ */
20080
+ readonly idMayBeBlank: string;
20081
+ /**
20082
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
20083
+ */
20084
+ readonly isArchBaseCoreObject: boolean;
20085
+ /**
20086
+ * This method iterates over this object and ArchBaseCoreObject instances
20087
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
20088
+ * with a filter and call the supplied callback function if isMatch returns true.
20089
+ * The callback will be passed an {@link ArchTraverseInfo} with details
20090
+ * about the match such as the match object itself along with current contextual
20091
+ * information such as the object hierarchy for the match object relative to
20092
+ * the object on which this traverse call is being made.
20093
+ *
20094
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
20095
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
20096
+ * or clause containers to it. If not specified, this function will use a
20097
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
20098
+ *
20099
+ * Here is an example that does a simple flow traversal using the default
20100
+ * filter and logs information about objects in the callback from the
20101
+ * traverse object that's passed back:
20102
+ *
20103
+ * ```
20104
+ * archInboundCallFlow.traverse(function(traverseInfo) {
20105
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
20106
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
20107
+ * });
20108
+ * ```
20109
+ * This might be enough for most uses and you can check various aspects
20110
+ * about the object in the callback such as "is this an Architect action?" by
20111
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
20112
+ * a filter for the traversal code to use as well and only have it call your
20113
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
20114
+ * the filter. Here's an example that creates a filter for callbacks on
20115
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
20116
+ * [decision action]{@link ArchActionDecision} or objects whose name
20117
+ * property case insensitively matches the word 'foo'. While this could all be done
20118
+ * with one property callback clause the example will use multiple clauses for
20119
+ * the sake of simplicity:
20120
+ * ```
20121
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
20122
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
20123
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
20124
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
20125
+ * // We fully spelled out the function signature above but archContainingObject and propName are
20126
+ * // not needed in this case. The archContainingObject is the object that contains the
20127
+ * // property and propName is the property name itself. We pass in propName because the same
20128
+ * // function could be used for multiple property callback clauses.
20129
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
20130
+ * return propValue && propValue.toLowerCase() === 'foo';
20131
+ * });
20132
+ * archTask.traverse(function(traverseContext) {
20133
+ * // You will only be called back here for ArchBaseCoreObject instances that
20134
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
20135
+ * }, myTraverseFilter);
20136
+ * ```
20137
+ * If you supply a filter with no clauses, this tells the traverse method to
20138
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
20139
+ *
20140
+ * If you want traversal itself to stop after a callback, simply return boolean
20141
+ * false from the callback function you supply to the traverse call.
20142
+ *
20143
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
20144
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
20145
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
20146
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
20147
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
20148
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
20149
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
20150
+ *
20151
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
20152
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
20153
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
20154
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
20155
+ *
20156
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
20157
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
20158
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
20159
+ *
20160
+ * This function returns the number of times it called the callback function.
20161
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
20162
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
20163
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
20164
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
20165
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
20166
+ */
20167
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
20168
+ /**
20169
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
20170
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
20171
+ * logging str contents wouldn't be set up.
20172
+ */
20173
+ readonly logStrTypeOnly: string;
20174
+ /**
20175
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
20176
+ * @param errorStr - the error string to log.
20177
+ */
20178
+ logError(errorStr: string): void;
20179
+ /**
20180
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
20181
+ * the string in the errorStr parameter.
20182
+ * @param errorStr - the error string to log. This should be a non-blank string.
20183
+ */
20184
+ logErrorAndThrow(errorStr: string): void;
20185
+ /**
20186
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
20187
+ * @param noteStr - the note string to log. This should be a non-blank string.
20188
+ */
20189
+ logNote(noteStr: string): void;
20190
+ /**
20191
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
20192
+ * @param noteStr - the note string to log. This should be a non-blank string.
20193
+ */
20194
+ logNoteVerbose(noteStr: string): void;
20195
+ /**
20196
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
20197
+ * @param warningStr - the warning string to log. This should be a non-blank string.
20198
+ */
20199
+ logWarning(warningStr: string): void;
20200
+ /**
20201
+ * Returns whether or not this Architect Scripting object is a match
20202
+ * for the supplied ArchFilterObject instance.
20203
+ * @param archFilterObject - the object filter to use to determine if it's a match.
20204
+ */
20205
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
20206
+ }
20207
+
20208
+ export class ArchBaseFlowWithTasks extends ArchBaseFlow {
20209
+ // constructor(coreFlowViewModel: any);
20210
+ /**
20211
+ * This function deletes the specified reusable task from this flow.
20212
+ * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
20213
+ * property on the specified task instance is true.
20214
+ */
20215
+ deleteTask(taskToDelete: ArchTask): void;
20216
+ /**
20217
+ * Returns an array of the currently defined reusable tasks for this flow.
20218
+ */
20219
+ readonly tasksReusable: ArchTask[];
20220
+ /**
20221
+ * This adds a new variable to the flow.
20222
+ * @param name - the name of the variable to add. Remember that variable names must
20223
+ * start with a letter and can then be followed by one or more letters, numbers
20224
+ * or underscore characters to be valid. Submitting the variable scope on the name
20225
+ * is optional. If specified, it must be 'Flow.' in order to be valid since you're
20226
+ * adding the variable to a flow. You can also specify 'Slot.' to add a slot variable
20227
+ * to the flow as long as the forceSlotVariableCreation parameter is true.
20228
+ * @param type - the data type for the new variable. Remember that type must be supported
20229
+ * in the flow type for which you're looking to add the variable. If you are
20230
+ * not sure if a type is creatable, see the {@link ArchDataType#isScriptCreatableForFlowType} or
20231
+ * {@link ArchDataType#isScriptCreatableForFlow} method.
20232
+ * @param [description] - the description for the new variable.
20233
+ * @param [forceSlotVariableCreation] - if true, will force the creation of a slot variable even when a Slot is not created in the Natural Language Understanding (NLU).
20234
+ */
20235
+ addVariable(name: string, type: ArchDataType, description?: string, forceSlotVariableCreation?: boolean): ArchBaseVariable;
20236
+ /**
20237
+ * This deletes the supplied variable from the flow. Remember you can call {@link ArchBaseVariable#canDelete}
20238
+ * prior to calling this method to know if the supplied flow scoped variable can be deleted.
20239
+ * @param archVariable - the flow scoped variable you wish to delete
20240
+ * @returns - true if the variable was removed successfully, false otherwise.
20241
+ */
20242
+ removeVariable(archVariable: ArchBaseVariable): boolean;
20243
+ /**
20244
+ * Checkout this flow. This function returns an ArchInfo instance for it to the supplied callback function.
20245
+ * @param [forceUnlock] - if true, will force an unlock of the flow.
20246
+ * @param [callbackFunction] - a callback function to call if the flow was checked out.
20247
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
20248
+ */
20249
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
20250
+ /**
20251
+ * Returns the division associated with this flow.
20252
+ * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
20253
+ * If not available, nothing is returned.
20254
+ */
20255
+ readonly division: ArchDivision;
20256
+ /**
20257
+ * Loads a specific version of the flow. Any previously returned Architect Scripting objects associated with this flow should no
20258
+ * longer be considered valid after loading new configuration.
20259
+ * @param [flowVersion = "latest"] - the version of the flow to get. Valid values are "latest" to get the latest saved configuration of a flow,
20260
+ * a version value such as "2.0" or "2", "debug" to get the currently published debug version configuration of a flow,
20261
+ * or "published" to get the currently published version configuration of a flow. If you do not specify a version, then the latest saved configuration will be loaded.
20262
+ * @param [callbackFunction] - a callback function to call if the flow was loaded.
20263
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing when the flow is loaded.
20264
+ */
20265
+ loadAsync(flowVersion?: string, callbackFunction?: callbackVoid): Promise<any>;
20266
+ /**
20267
+ * Returns a string suitable for logging that describes the flow
20268
+ */
20269
+ readonly logStr: string;
20270
+ /**
20271
+ * Unlocks this flow.
20272
+ * @param [callbackFunction] - a callback function to call if the flow can be unlocked.
20273
+ * @returns - while this method returns a promise, you should use the callback function to perform any processing once this flow is unlocked.
20274
+ */
20275
+ unlockAsync(callbackFunction?: callbackVoid): Promise<any>;
20276
+ /**
20277
+ * Helper method that accesses the flow's [settingsSupportedLanguages]{@link ArchBaseFlow#settingsSupportedLanguages} and then calls
20278
+ * the [addSupportedLanguage]{@link ArchSettingsSupportedLanguagesFlow#addSupportedLanguage} function on the returned {@link ArchSettingsSupportedLanguagesFlow}
20279
+ * value.
20280
+ * @param archLanguage - the language to add to supported languages on the flow. Note that any language used as a supported
20281
+ * language must have at least one region sub-tag.
20282
+ * @param [setAsDefaultLanguage] - if true, the language will be set as the default language on the flow.
20283
+ */
20284
+ addFlowSupportedLanguage(archLanguage: ArchLanguage, setAsDefaultLanguage?: boolean): ArchSettingsSupportedLanguage;
20285
+ /**
20286
+ * Checks flow to see if a language can be added in its current state. Some flows may have restrictions
20287
+ * if any or more than one can be added.
20288
+ */
20289
+ canAddSupportedLanguage(): boolean;
20290
+ /**
20291
+ * Checks in and unlocks the flow for the current user, does a save first
20292
+ * Assumes the flow has been created, throws if not
20293
+ * @param [ensureSearchable] - whether or not to poll after successful checkin to ensure that the flow is available for flow
20294
+ * search operations such as {@link ArchFactoryFlows#getFlowInfoByFlowNameAsync} or {@link ArchFactoryFlows#getFlowInfoByFlowIdAsync}
20295
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
20296
+ * flow instance.
20297
+ */
20298
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
20299
+ /**
20300
+ * Creates a new flow on the server and saves its configuration
20301
+ * @returns - On your promise's then handler, the first parameter passed to the then function will be this
20302
+ * flow instance.
20303
+ */
20304
+ createAsync(): Promise<any>;
20305
+ /**
20306
+ * Accessing this property returns an object with properties whose keys are data type names and values are
20307
+ * {@link ArchDataType} instances.
20308
+ */
20309
+ readonly dataTypes: any;
20310
+ /**
20311
+ * The description of the flow
20312
+ */
20313
+ description: string;
20314
+ /**
20315
+ * Exports the current flow to a file in the specified directory. This destination directory *must* exist
20316
+ * for the export to succeed. Note that this uses the file system and should not be used when running in a
20317
+ * browser.
20318
+ * @param [destinationDir] - the directory where the flow export should be saved.
20319
+ * @param [callbackFunction] - the function to call back and pass in the full path where the
20320
+ * flow export was saved.
20321
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
20322
+ * it will default to the Architect format.
20323
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
20324
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
20325
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
20326
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
20327
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
20328
+ */
20329
+ exportToDirAsync(destinationDir?: string, callbackFunction?: callbackExportFullPath, flowFormat?: string, fileName?: string): Promise<string>;
20330
+ /**
20331
+ * Exports the flow to a JSON object. The object passed back in the callback function
20332
+ * will be a JSON object with a content and fileName property where the content holds
20333
+ * the flow export contents and the fileName property holds the file name where the
20334
+ * export would be written if {@link ArchBaseFlow#exportToDirAsync} is called.
20335
+ * @param callbackFunction - the function to call back with the export information contained
20336
+ * in the parameter passed to it.
20337
+ * @param [flowFormat = archEnums.FLOW_FORMAT_TYPES.architect] - the desired export format to use on an export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export formats. If no format is used,
20338
+ * it will default to the Architect format.
20339
+ */
20340
+ exportToObjectAsync(callbackFunction: callbackExportObject, flowFormat?: string): Promise<ExportInfoType>;
20341
+ /**
20342
+ * The type of the flow. The string
20343
+ * values in {@link ArchEnums#FLOW_TYPES} lists valid flow type values.
20344
+ */
20345
+ readonly flowType: string;
20346
+ /**
20347
+ * This function will return the file path where a flow export will be written when calling the {@link ArchBaseFlow#exportToDirAsync}
20348
+ * method for the supplied destination directory and export flow format. A typical use case for this function would be
20349
+ * to get the export file path prior to calling the {@link ArchBaseFlow#exportToDirAsync} so you could see if the file already exists
20350
+ * and decide if you want to perform an export or not since {@link ArchBaseFlow#exportToDirAsync} will attempt to overwrite
20351
+ * a file if it already exists. Note that this uses the file system and should not be used when running in a
20352
+ * browser.
20353
+ * @param [destinationDir] - the directory where the flow export should be written. If no directory path is given, this method uses the
20354
+ * current working directory. If a relative path is supplied, it will be resolved relative to the current
20355
+ * working directory.
20356
+ * @param [flowFormat = ArchEnums.FLOW_FORMAT_TYPES.architect] - the desired flow format to use for the export. See {@link ArchEnums#FLOW_FORMAT_TYPES} for allowable export
20357
+ * formats. If no format is supplied, it will use the Architect format.
20358
+ * @param [fileName] - the file name to use for the exported flow. If a file extension is not added to the file name, it will use the default file extension for the desired export type for
20359
+ * the desired export format and flow that you are exporting. If the format is YAML, the extension is always '.yaml' regardless of flow type. However, if it is the Architect format, the extension is unique per flow-type.
20360
+ * To find the correct file extension for the Architect format, you can either export a flow from the Architect UI or look at the [flow definition]{@link ArchBaseFlow#definition}
20361
+ * for a flow type and access the [fileExtension]{@link ArchDefinitionFlow#fileExtension} property to get the value. If an extension is found on the file name other than what is
20362
+ * expected, the correct extension will be appended to the end of the exported file as per the logic described previously.
20363
+ */
20364
+ getExportFilePath(destinationDir?: string, flowFormat?: string, fileName?: string): string;
20365
+ /**
20366
+ * Returns the flow scoped variable for the supplied variable identifier ( if it exists ).
20367
+ * If the variable name cannot be found, nothing is returned.
20368
+ * @param variableId - the supllied variable identifier to look up such as __CALL_ANI__.
20369
+ */
20370
+ getVariableById<T extends ArchBaseVariable = ArchBaseVariable>(variableId: string): T;
20371
+ /**
20372
+ * Returns the flow scoped variable for the supplied fully scoped variable name ( if it exists ). Remember, looking
20373
+ * up variables by name is case insensitive. If the variable name cannot be found, nothing is returned.
20374
+ * @param variableName - the fully scoped variable name to look up such as Flow.MyVar.
20375
+ */
20376
+ getVariableByName<T extends ArchBaseVariable = ArchBaseVariable>(variableName: string): T;
20377
+ /**
20378
+ * Imports the flow content from the supplied content string. This content string should be for a flow of the
20379
+ * same type as the one you're importing in to. Upon successful import, the callback function passed in
20380
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
20381
+ * do work with the flow on which this is being called until the callback is called.
20382
+ * @param exportContent - the contents from a flow export.
20383
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
20384
+ * on this flow. The first parameter passed to the callback function will be this
20385
+ * Architect flow instance.
20386
+ */
20387
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
20388
+ /**
20389
+ * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
20390
+ * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
20391
+ * do work with the flow on which this is being called until the callback is called.
20392
+ * Also note that this method should not be used if running in a browser.
20393
+ * @param exportFilePath - the file path to an Architect flow export file that should be imported.
20394
+ * @param [callbackFunction] - a function to call if the export content successfully loaded and configured
20395
+ * on this flow. The first parameter passed to the callback function will be this
20396
+ * Architect flow instance.
20397
+ */
20398
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
17684
20399
  /**
17685
20400
  * Returns whether or not the flow is created in Genesys Cloud.
17686
20401
  */
@@ -17773,80 +20488,157 @@ export class ArchBaseFlow extends ArchBaseCoreObjectWithId {
17773
20488
  */
17774
20489
  readonly variables: ArchBaseVariable[];
17775
20490
  /**
17776
- * Returns a definition for this flow type which provides access to information about this flow such as {@link ArchDefinitionFlow#isAvailable}.
17777
- * ```
17778
- * // Example code - remember, only access this when your Scripting session is connected!
17779
- * let archIncomingCallFlowDefinition = scripting.viewModels.flows.ArchFlowInboundCall.definition;
17780
- * // or for a given ArchFlowInboundCall flow instance:
17781
- * let archIncomingCallFlowDefinition = archInboundCallFlowInstance.definition;
17782
- * ```
20491
+ * The identifier string for this object.
17783
20492
  */
17784
- readonly definition: ArchDefinitionFlow;
17785
- }
17786
-
17787
- /**
17788
- * The Architect Scripting class for the Base Bot flow class.
17789
- * Instances of this Architect Scripting object should be created by calling {@link ArchFactoryFlows#createFlowBotAsync}
17790
- * @param coreBotViewModel - ( *Internal* ) an Architect core Bot view model.
17791
- */
17792
- export class ArchBaseFlowBot extends ArchBaseFlowWorkflow {
17793
- // constructor(coreBotViewModel: any);
20493
+ readonly id: string;
17794
20494
  /**
17795
- * Returns the display type name string 'ArchBaseFlowBot'.
20495
+ * Returns whether or not the id property may be blank or undefined for this object. For example, the returned settings from {@link ArchMenu#settingsMenu}
20496
+ * will have a blank identifier along with the settings returned from {@link ArchMenu#settingsSpeechRec}. Note that this is
20497
+ * an extremely rare case.
17796
20498
  */
17797
- readonly displayTypeName: string;
20499
+ readonly idMayBeBlank: string;
17798
20500
  /**
17799
- * Returns true indicating that this is an ArchBaseFlowBot instance.
20501
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
17800
20502
  */
17801
- readonly isArchBaseFlowBot: boolean;
20503
+ readonly isArchBaseCoreObject: boolean;
17802
20504
  /**
17803
- * The user input settings for the flow.
20505
+ * This method iterates over this object and ArchBaseCoreObject instances
20506
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
20507
+ * with a filter and call the supplied callback function if isMatch returns true.
20508
+ * The callback will be passed an {@link ArchTraverseInfo} with details
20509
+ * about the match such as the match object itself along with current contextual
20510
+ * information such as the object hierarchy for the match object relative to
20511
+ * the object on which this traverse call is being made.
20512
+ *
20513
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
20514
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
20515
+ * or clause containers to it. If not specified, this function will use a
20516
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
20517
+ *
20518
+ * Here is an example that does a simple flow traversal using the default
20519
+ * filter and logs information about objects in the callback from the
20520
+ * traverse object that's passed back:
20521
+ *
20522
+ * ```
20523
+ * archInboundCallFlow.traverse(function(traverseInfo) {
20524
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
20525
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
20526
+ * });
20527
+ * ```
20528
+ * This might be enough for most uses and you can check various aspects
20529
+ * about the object in the callback such as "is this an Architect action?" by
20530
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
20531
+ * a filter for the traversal code to use as well and only have it call your
20532
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
20533
+ * the filter. Here's an example that creates a filter for callbacks on
20534
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
20535
+ * [decision action]{@link ArchActionDecision} or objects whose name
20536
+ * property case insensitively matches the word 'foo'. While this could all be done
20537
+ * with one property callback clause the example will use multiple clauses for
20538
+ * the sake of simplicity:
20539
+ * ```
20540
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
20541
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
20542
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
20543
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
20544
+ * // We fully spelled out the function signature above but archContainingObject and propName are
20545
+ * // not needed in this case. The archContainingObject is the object that contains the
20546
+ * // property and propName is the property name itself. We pass in propName because the same
20547
+ * // function could be used for multiple property callback clauses.
20548
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
20549
+ * return propValue && propValue.toLowerCase() === 'foo';
20550
+ * });
20551
+ * archTask.traverse(function(traverseContext) {
20552
+ * // You will only be called back here for ArchBaseCoreObject instances that
20553
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
20554
+ * }, myTraverseFilter);
20555
+ * ```
20556
+ * If you supply a filter with no clauses, this tells the traverse method to
20557
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
20558
+ *
20559
+ * If you want traversal itself to stop after a callback, simply return boolean
20560
+ * false from the callback function you supply to the traverse call.
20561
+ *
20562
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
20563
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
20564
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
20565
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
20566
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
20567
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
20568
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
20569
+ *
20570
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
20571
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
20572
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
20573
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
20574
+ *
20575
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
20576
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
20577
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
20578
+ *
20579
+ * This function returns the number of times it called the callback function.
20580
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
20581
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
20582
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
20583
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
20584
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
17804
20585
  */
17805
- readonly userInputSettings: ArchSettingsUserInput;
20586
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
17806
20587
  /**
17807
- * Returns the error handling settings for the flow.
20588
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
20589
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
20590
+ * logging str contents wouldn't be set up.
17808
20591
  */
17809
- readonly settingsErrorHandling: ArchSettingsEventErrorFlowBot;
17810
- }
17811
-
17812
- export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
17813
- // constructor(coreBotWithKnowledgeViewModel: any);
20592
+ readonly logStrTypeOnly: string;
17814
20593
  /**
17815
- * Returns the display type name string 'isArchBaseFlowBotWithKnowledge'.
20594
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
20595
+ * @param errorStr - the error string to log.
17816
20596
  */
17817
- readonly displayTypeName: string;
20597
+ logError(errorStr: string): void;
17818
20598
  /**
17819
- * Returns true indicating that this is an isArchBaseFlowBotWithKnowledge instance.
20599
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
20600
+ * the string in the errorStr parameter.
20601
+ * @param errorStr - the error string to log. This should be a non-blank string.
17820
20602
  */
17821
- readonly isArchBaseFlowBotWithKnowledge: boolean;
20603
+ logErrorAndThrow(errorStr: string): void;
17822
20604
  /**
17823
- * The natural language understanding knowledge settings for the bot flow.
17824
- * Note that if your organization does not have knowledge base support or the
17825
- * flow's supported language does not support knowledge, accessing this property
17826
- * will return null.
20605
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
20606
+ * @param noteStr - the note string to log. This should be a non-blank string.
17827
20607
  */
17828
- readonly knowledgeSettings: ArchSettingsNluKnowledge;
20608
+ logNote(noteStr: string): void;
17829
20609
  /**
17830
- * Bot-specific settings for the flow.
20610
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
20611
+ * @param noteStr - the note string to log. This should be a non-blank string.
17831
20612
  */
17832
- readonly botFlowSettings: ArchSettingsBotFlow;
20613
+ logNoteVerbose(noteStr: string): void;
17833
20614
  /**
17834
- * Returns true indicating that this is an ArchBaseFlowBot instance.
20615
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
20616
+ * @param warningStr - the warning string to log. This should be a non-blank string.
17835
20617
  */
17836
- readonly isArchBaseFlowBot: boolean;
20618
+ logWarning(warningStr: string): void;
17837
20619
  /**
17838
- * The user input settings for the flow.
20620
+ * Returns whether or not this Architect Scripting object is a match
20621
+ * for the supplied ArchFilterObject instance.
20622
+ * @param archFilterObject - the object filter to use to determine if it's a match.
17839
20623
  */
17840
- readonly userInputSettings: ArchSettingsUserInput;
20624
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
20625
+ }
20626
+
20627
+ export class ArchBaseFlowWorkflow extends ArchBaseFlowWithTasks {
20628
+ // constructor(coreBaseWorkflowViewModel: any);
17841
20629
  /**
17842
- * Returns the error handling settings for the flow.
20630
+ * Returns true indicating that this is an ArchBaseFlowWorkflow object.
17843
20631
  */
17844
- readonly settingsErrorHandling: ArchSettingsEventErrorFlowBot;
20632
+ readonly isArchBaseFlowWorkflow: boolean;
17845
20633
  /**
17846
20634
  * This function deletes the specified state from this flow.
17847
20635
  * @param stateToDelete - the state to delete.
17848
20636
  */
17849
20637
  deleteState(stateToDelete: ArchState): void;
20638
+ /**
20639
+ * Returns the display type name string 'ArchBaseFlowWorkflow'.
20640
+ */
20641
+ readonly displayTypeName: string;
17850
20642
  /**
17851
20643
  * Sets the specified state to be the starting state on the flow.
17852
20644
  * @param archState - An Architect Scripting state object.
@@ -17900,7 +20692,7 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
17900
20692
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
17901
20693
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
17902
20694
  */
17903
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
20695
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
17904
20696
  /**
17905
20697
  * Returns the division associated with this flow.
17906
20698
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -17949,7 +20741,7 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
17949
20741
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
17950
20742
  * flow instance.
17951
20743
  */
17952
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
20744
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
17953
20745
  /**
17954
20746
  * Creates a new flow on the server and saves its configuration
17955
20747
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -18038,7 +20830,7 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
18038
20830
  * on this flow. The first parameter passed to the callback function will be this
18039
20831
  * Architect flow instance.
18040
20832
  */
18041
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
20833
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18042
20834
  /**
18043
20835
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
18044
20836
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -18049,7 +20841,7 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
18049
20841
  * on this flow. The first parameter passed to the callback function will be this
18050
20842
  * Architect flow instance.
18051
20843
  */
18052
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
20844
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
18053
20845
  /**
18054
20846
  * Returns whether or not the flow is created in Genesys Cloud.
18055
20847
  */
@@ -18093,6 +20885,10 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
18093
20885
  * flow instance.
18094
20886
  */
18095
20887
  saveAsync(): Promise<any>;
20888
+ /**
20889
+ * Returns the error handling settings for the flow.
20890
+ */
20891
+ readonly settingsErrorHandling: ArchSettingsEventErrorFlow;
18096
20892
  /**
18097
20893
  * Returns the action default settings for the flow.
18098
20894
  */
@@ -18274,157 +21070,6 @@ export class ArchBaseFlowBotWithKnowledge extends ArchBaseFlowBot {
18274
21070
  isFilterMatch(archFilterObject: ArchFilterObject): boolean;
18275
21071
  }
18276
21072
 
18277
- /**
18278
- * The Architect Scripting class for the base workflow instance.
18279
- * @param coreInQueueDigitalFlow - ( *Internal* ) an Architect core in-queue email or short message flow.
18280
- */
18281
- export class ArchBaseFlowInQueueWorkflow extends ArchBaseFlowWorkflow {
18282
- // constructor(coreInQueueDigitalFlow: any);
18283
- /**
18284
- * Returns the display type name string 'ArchBaseFlowInQueueWorkflow'.
18285
- */
18286
- readonly displayTypeName: string;
18287
- /**
18288
- * Returns true indicating that this is an ArchBaseFlowInQueueWorkflow object.
18289
- * This will be true for in-queue email and in-queue short message flows.
18290
- */
18291
- readonly isArchBaseFlowInQueueWorkflow: boolean;
18292
- /**
18293
- * Sets the specified state to be the periodic state on the in-queue
18294
- * email or short message flow. Remember the same state cannot be used
18295
- * for both the starting state and the periodic state.
18296
- * @param archState - An Architect Scripting state object.
18297
- */
18298
- setPeriodicState(archState: ArchState): void;
18299
- /**
18300
- * Returns the periodic state for this flow.
18301
- */
18302
- readonly periodicState: ArchState;
18303
- }
18304
-
18305
- /**
18306
- * Creates an instance of an ArchBaseFlowInboundOutboundSecureCall. This is the base class for inbound / outbound / secure call flows.
18307
- * @param coreInboundOutboundSecureFlowViewModel - ( *Internal* ) an Architect core inbound, outbound or secure call flow view model.
18308
- */
18309
- export class ArchBaseFlowInboundOutboundSecureCall extends ArchBaseFlowWithMenus {
18310
- // constructor(coreInboundOutboundSecureFlowViewModel: any);
18311
- /**
18312
- * Returns the display type name string 'ArchBaseFlowInboundOutboundSecureCall'.
18313
- */
18314
- readonly displayTypeName: string;
18315
- /**
18316
- * The initial audio set on the flow.
18317
- */
18318
- readonly initialAudio: ArchAudio;
18319
- /**
18320
- * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
18321
- */
18322
- readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
18323
- /**
18324
- * Sets the specified menu to be the starting task on the flow.
18325
- * @param archMenu - An Architect Scripting menu object.
18326
- */
18327
- setStartingMenu(archMenu: ArchMenu): void;
18328
- /**
18329
- * Sets the specified task to be the starting task on the flow.
18330
- * @param archTask - An Architect Scripting task object.
18331
- */
18332
- setStartingTask(archTask: ArchTask): void;
18333
- /**
18334
- * The menu settings for the flow.
18335
- */
18336
- readonly settingsMenu: ArchSettingsMenuFlow;
18337
- /**
18338
- * The prompt settings for the flow.
18339
- */
18340
- readonly settingsPrompts: ArchSettingsPromptsFlow;
18341
- /**
18342
- * The speech rec settings for the flow.
18343
- */
18344
- readonly settingsSpeechRec: ArchSettingsSpeechRecFlow;
18345
- /**
18346
- * Returns the starting task or menu for this call flow.
18347
- * If there is no startup object configured, accessing this property returns null.
18348
- */
18349
- readonly startUpObject: ArchTask | ArchMenu;
18350
- /**
18351
- * The outbound settings for the flow such as contact list and default wrapup code.
18352
- */
18353
- readonly settingsOutboundCall: ArchSettingsOutboundCallFlow;
18354
- }
18355
-
18356
- /**
18357
- * Creates an instance of an ArchBaseFlowWithMenus. This is the base class for flows that contain menus.
18358
- * @param coreFlowViewModel - ( *Internal* ) an Architect core flow view model object that contains menus.
18359
- */
18360
- export class ArchBaseFlowWithMenus extends ArchBaseFlowWithTasks {
18361
- // constructor(coreFlowViewModel: any);
18362
- /**
18363
- * This function deletes the specified reusable menu from this flow.
18364
- * @param menuToDelete - the menu to delete. This must be a reusable menu which means the {@link ArchMenu#isReusableMenu}
18365
- * property on the specified menu instance is true.
18366
- */
18367
- deleteMenu(menuToDelete: ArchMenu): void;
18368
- /**
18369
- * Returns an array of the currently defined reusable menus for this flow.
18370
- */
18371
- readonly menusReusable: ArchBaseMenu[];
18372
- }
18373
-
18374
- /**
18375
- * The Architect Scripting class for flows that contain tasks. Note that a task is not considered to be the same thing
18376
- * as the repeating task in an in-queue call flow.
18377
- * @param coreFlowViewModel - ( *Internal* ) an Architect core flow view model object that contains tasks.
18378
- */
18379
- export class ArchBaseFlowWithTasks extends ArchBaseFlow {
18380
- // constructor(coreFlowViewModel: any);
18381
- /**
18382
- * This function deletes the specified reusable task from this flow.
18383
- * @param taskToDelete - the task to delete. This must be a reusable task which means the {@link ArchTask#isReusableTask}
18384
- * property on the specified task instance is true.
18385
- */
18386
- deleteTask(taskToDelete: ArchTask): void;
18387
- /**
18388
- * Returns an array of the currently defined reusable tasks for this flow.
18389
- */
18390
- readonly tasksReusable: ArchTask[];
18391
- }
18392
-
18393
- /**
18394
- * The Architect Scripting class for the base workflow instance.
18395
- * @param coreBaseWorkflowViewModel - ( *Internal* ) an Architect core base workflow view model.
18396
- */
18397
- export class ArchBaseFlowWorkflow extends ArchBaseFlowWithTasks {
18398
- // constructor(coreBaseWorkflowViewModel: any);
18399
- /**
18400
- * This function deletes the specified state from this flow.
18401
- * @param stateToDelete - the state to delete.
18402
- */
18403
- deleteState(stateToDelete: ArchState): void;
18404
- /**
18405
- * Returns the display type name string 'ArchBaseFlowWorkflow'.
18406
- */
18407
- readonly displayTypeName: string;
18408
- /**
18409
- * Returns true indicating that this is an ArchBaseFlowWorkflow object.
18410
- */
18411
- readonly isArchBaseFlowWorkflow: boolean;
18412
- /**
18413
- * Sets the specified state to be the starting state on the flow.
18414
- * @param archState - An Architect Scripting state object.
18415
- */
18416
- setStartingState(archState: ArchState): void;
18417
- /**
18418
- * Returns the starting state for this flow.
18419
- * If there is no startup object configured, accessing this property returns null.
18420
- */
18421
- readonly startUpObject: ArchState;
18422
- /**
18423
- * The states in the flow.
18424
- */
18425
- readonly states: ArchState[];
18426
- }
18427
-
18428
21073
  /**
18429
21074
  * The Architect Scripting class that provides internal support for Architect Scripting menu and menu choice objects.
18430
21075
  */
@@ -24850,7 +27495,7 @@ export class ArchFlowBot extends ArchBaseFlowBotWithKnowledge {
24850
27495
  * flow's supported language does not support knowledge, accessing this property
24851
27496
  * will return null.
24852
27497
  */
24853
- readonly knowledgeSettings: ArchSettingsNluKnowledge;
27498
+ readonly knowledgeSettings: ArchSettingsNluKnowledge | null;
24854
27499
  /**
24855
27500
  * Bot-specific settings for the flow.
24856
27501
  */
@@ -24925,7 +27570,7 @@ export class ArchFlowBot extends ArchBaseFlowBotWithKnowledge {
24925
27570
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
24926
27571
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
24927
27572
  */
24928
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
27573
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
24929
27574
  /**
24930
27575
  * Returns the division associated with this flow.
24931
27576
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -24974,7 +27619,7 @@ export class ArchFlowBot extends ArchBaseFlowBotWithKnowledge {
24974
27619
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
24975
27620
  * flow instance.
24976
27621
  */
24977
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
27622
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
24978
27623
  /**
24979
27624
  * Creates a new flow on the server and saves its configuration
24980
27625
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -25063,7 +27708,7 @@ export class ArchFlowBot extends ArchBaseFlowBotWithKnowledge {
25063
27708
  * on this flow. The first parameter passed to the callback function will be this
25064
27709
  * Architect flow instance.
25065
27710
  */
25066
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
27711
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25067
27712
  /**
25068
27713
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
25069
27714
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -25074,7 +27719,7 @@ export class ArchFlowBot extends ArchBaseFlowBotWithKnowledge {
25074
27719
  * on this flow. The first parameter passed to the callback function will be this
25075
27720
  * Architect flow instance.
25076
27721
  */
25077
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
27722
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25078
27723
  /**
25079
27724
  * Returns whether or not the flow is created in Genesys Cloud.
25080
27725
  */
@@ -25351,7 +27996,7 @@ export class ArchFlowCommonModule extends ArchBaseFlow {
25351
27996
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
25352
27997
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
25353
27998
  */
25354
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
27999
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
25355
28000
  /**
25356
28001
  * Returns the division associated with this flow.
25357
28002
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -25400,7 +28045,7 @@ export class ArchFlowCommonModule extends ArchBaseFlow {
25400
28045
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
25401
28046
  * flow instance.
25402
28047
  */
25403
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
28048
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
25404
28049
  /**
25405
28050
  * Creates a new flow on the server and saves its configuration
25406
28051
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -25489,7 +28134,7 @@ export class ArchFlowCommonModule extends ArchBaseFlow {
25489
28134
  * on this flow. The first parameter passed to the callback function will be this
25490
28135
  * Architect flow instance.
25491
28136
  */
25492
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
28137
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25493
28138
  /**
25494
28139
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
25495
28140
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -25500,7 +28145,7 @@ export class ArchFlowCommonModule extends ArchBaseFlow {
25500
28145
  * on this flow. The first parameter passed to the callback function will be this
25501
28146
  * Architect flow instance.
25502
28147
  */
25503
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
28148
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25504
28149
  /**
25505
28150
  * Returns whether or not the flow is created in Genesys Cloud.
25506
28151
  */
@@ -25753,7 +28398,7 @@ export class ArchFlowDigitalBot extends ArchBaseFlowBotWithKnowledge {
25753
28398
  * flow's supported language does not support knowledge, accessing this property
25754
28399
  * will return null.
25755
28400
  */
25756
- readonly knowledgeSettings: ArchSettingsNluKnowledge;
28401
+ readonly knowledgeSettings: ArchSettingsNluKnowledge | null;
25757
28402
  /**
25758
28403
  * Bot-specific settings for the flow.
25759
28404
  */
@@ -25828,7 +28473,7 @@ export class ArchFlowDigitalBot extends ArchBaseFlowBotWithKnowledge {
25828
28473
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
25829
28474
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
25830
28475
  */
25831
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
28476
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
25832
28477
  /**
25833
28478
  * Returns the division associated with this flow.
25834
28479
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -25877,7 +28522,7 @@ export class ArchFlowDigitalBot extends ArchBaseFlowBotWithKnowledge {
25877
28522
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
25878
28523
  * flow instance.
25879
28524
  */
25880
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
28525
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
25881
28526
  /**
25882
28527
  * Creates a new flow on the server and saves its configuration
25883
28528
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -25966,7 +28611,7 @@ export class ArchFlowDigitalBot extends ArchBaseFlowBotWithKnowledge {
25966
28611
  * on this flow. The first parameter passed to the callback function will be this
25967
28612
  * Architect flow instance.
25968
28613
  */
25969
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
28614
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25970
28615
  /**
25971
28616
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
25972
28617
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -25977,7 +28622,7 @@ export class ArchFlowDigitalBot extends ArchBaseFlowBotWithKnowledge {
25977
28622
  * on this flow. The first parameter passed to the callback function will be this
25978
28623
  * Architect flow instance.
25979
28624
  */
25980
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
28625
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
25981
28626
  /**
25982
28627
  * Returns whether or not the flow is created in Genesys Cloud.
25983
28628
  */
@@ -26253,7 +28898,7 @@ export class ArchFlowInQueueCall extends ArchBaseFlow {
26253
28898
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
26254
28899
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
26255
28900
  */
26256
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
28901
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
26257
28902
  /**
26258
28903
  * Returns the division associated with this flow.
26259
28904
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -26302,7 +28947,7 @@ export class ArchFlowInQueueCall extends ArchBaseFlow {
26302
28947
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
26303
28948
  * flow instance.
26304
28949
  */
26305
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
28950
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
26306
28951
  /**
26307
28952
  * Creates a new flow on the server and saves its configuration
26308
28953
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -26391,7 +29036,7 @@ export class ArchFlowInQueueCall extends ArchBaseFlow {
26391
29036
  * on this flow. The first parameter passed to the callback function will be this
26392
29037
  * Architect flow instance.
26393
29038
  */
26394
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29039
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
26395
29040
  /**
26396
29041
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
26397
29042
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -26402,7 +29047,7 @@ export class ArchFlowInQueueCall extends ArchBaseFlow {
26402
29047
  * on this flow. The first parameter passed to the callback function will be this
26403
29048
  * Architect flow instance.
26404
29049
  */
26405
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29050
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
26406
29051
  /**
26407
29052
  * Returns whether or not the flow is created in Genesys Cloud.
26408
29053
  */
@@ -26642,12 +29287,10 @@ export class ArchFlowInQueueEmail extends ArchBaseFlowInQueueWorkflow {
26642
29287
  */
26643
29288
  readonly isArchFlowInQueueEmail: boolean;
26644
29289
  /**
26645
- * Sets the specified state to be the periodic state on the in-queue
26646
- * email or short message flow. Remember the same state cannot be used
26647
- * for both the starting state and the periodic state.
26648
- * @param archState - An Architect Scripting state object.
29290
+ * Returns true indicating that this is an ArchBaseFlowInQueueWorkflow object.
29291
+ * This will be true for in-queue email and in-queue short message flows.
26649
29292
  */
26650
- setPeriodicState(archState: ArchState): void;
29293
+ readonly isArchBaseFlowInQueueWorkflow: boolean;
26651
29294
  /**
26652
29295
  * Returns the periodic state for this flow.
26653
29296
  */
@@ -26710,7 +29353,7 @@ export class ArchFlowInQueueEmail extends ArchBaseFlowInQueueWorkflow {
26710
29353
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
26711
29354
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
26712
29355
  */
26713
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
29356
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
26714
29357
  /**
26715
29358
  * Returns the division associated with this flow.
26716
29359
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -26759,7 +29402,7 @@ export class ArchFlowInQueueEmail extends ArchBaseFlowInQueueWorkflow {
26759
29402
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
26760
29403
  * flow instance.
26761
29404
  */
26762
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
29405
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
26763
29406
  /**
26764
29407
  * Creates a new flow on the server and saves its configuration
26765
29408
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -26848,7 +29491,7 @@ export class ArchFlowInQueueEmail extends ArchBaseFlowInQueueWorkflow {
26848
29491
  * on this flow. The first parameter passed to the callback function will be this
26849
29492
  * Architect flow instance.
26850
29493
  */
26851
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29494
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
26852
29495
  /**
26853
29496
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
26854
29497
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -26859,7 +29502,7 @@ export class ArchFlowInQueueEmail extends ArchBaseFlowInQueueWorkflow {
26859
29502
  * on this flow. The first parameter passed to the callback function will be this
26860
29503
  * Architect flow instance.
26861
29504
  */
26862
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29505
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
26863
29506
  /**
26864
29507
  * Returns whether or not the flow is created in Genesys Cloud.
26865
29508
  */
@@ -27099,12 +29742,10 @@ export class ArchFlowInQueueShortMessage extends ArchBaseFlowInQueueWorkflow {
27099
29742
  */
27100
29743
  readonly isArchFlowInQueueShortMessage: boolean;
27101
29744
  /**
27102
- * Sets the specified state to be the periodic state on the in-queue
27103
- * email or short message flow. Remember the same state cannot be used
27104
- * for both the starting state and the periodic state.
27105
- * @param archState - An Architect Scripting state object.
29745
+ * Returns true indicating that this is an ArchBaseFlowInQueueWorkflow object.
29746
+ * This will be true for in-queue email and in-queue short message flows.
27106
29747
  */
27107
- setPeriodicState(archState: ArchState): void;
29748
+ readonly isArchBaseFlowInQueueWorkflow: boolean;
27108
29749
  /**
27109
29750
  * Returns the periodic state for this flow.
27110
29751
  */
@@ -27167,7 +29808,7 @@ export class ArchFlowInQueueShortMessage extends ArchBaseFlowInQueueWorkflow {
27167
29808
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
27168
29809
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
27169
29810
  */
27170
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
29811
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
27171
29812
  /**
27172
29813
  * Returns the division associated with this flow.
27173
29814
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -27216,7 +29857,7 @@ export class ArchFlowInQueueShortMessage extends ArchBaseFlowInQueueWorkflow {
27216
29857
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
27217
29858
  * flow instance.
27218
29859
  */
27219
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
29860
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
27220
29861
  /**
27221
29862
  * Creates a new flow on the server and saves its configuration
27222
29863
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -27305,7 +29946,7 @@ export class ArchFlowInQueueShortMessage extends ArchBaseFlowInQueueWorkflow {
27305
29946
  * on this flow. The first parameter passed to the callback function will be this
27306
29947
  * Architect flow instance.
27307
29948
  */
27308
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29949
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
27309
29950
  /**
27310
29951
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
27311
29952
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -27316,7 +29957,7 @@ export class ArchFlowInQueueShortMessage extends ArchBaseFlowInQueueWorkflow {
27316
29957
  * on this flow. The first parameter passed to the callback function will be this
27317
29958
  * Architect flow instance.
27318
29959
  */
27319
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
29960
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
27320
29961
  /**
27321
29962
  * Returns whether or not the flow is created in Genesys Cloud.
27322
29963
  */
@@ -27559,6 +30200,10 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27559
30200
  * The initial audio set on the flow.
27560
30201
  */
27561
30202
  readonly initialAudio: ArchAudio;
30203
+ /**
30204
+ * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
30205
+ */
30206
+ readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
27562
30207
  /**
27563
30208
  * Sets the specified menu to be the starting task on the flow.
27564
30209
  * @param archMenu - An Architect Scripting menu object.
@@ -27585,7 +30230,7 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27585
30230
  * Returns the starting task or menu for this call flow.
27586
30231
  * If there is no startup object configured, accessing this property returns null.
27587
30232
  */
27588
- readonly startUpObject: ArchTask | ArchMenu;
30233
+ readonly startUpObject: ArchTask | ArchMenu | null;
27589
30234
  /**
27590
30235
  * The outbound settings for the flow such as contact list and default wrapup code.
27591
30236
  */
@@ -27639,7 +30284,7 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27639
30284
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
27640
30285
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
27641
30286
  */
27642
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
30287
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
27643
30288
  /**
27644
30289
  * Returns the division associated with this flow.
27645
30290
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -27688,7 +30333,7 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27688
30333
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
27689
30334
  * flow instance.
27690
30335
  */
27691
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
30336
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
27692
30337
  /**
27693
30338
  * Creates a new flow on the server and saves its configuration
27694
30339
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -27777,7 +30422,7 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27777
30422
  * on this flow. The first parameter passed to the callback function will be this
27778
30423
  * Architect flow instance.
27779
30424
  */
27780
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
30425
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
27781
30426
  /**
27782
30427
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
27783
30428
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -27788,7 +30433,7 @@ export class ArchFlowInboundCall extends ArchBaseFlowInboundOutboundSecureCall {
27788
30433
  * on this flow. The first parameter passed to the callback function will be this
27789
30434
  * Architect flow instance.
27790
30435
  */
27791
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
30436
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
27792
30437
  /**
27793
30438
  * Returns whether or not the flow is created in Genesys Cloud.
27794
30439
  */
@@ -28085,7 +30730,7 @@ export class ArchFlowInboundChat extends ArchBaseFlowWorkflow {
28085
30730
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
28086
30731
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
28087
30732
  */
28088
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
30733
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
28089
30734
  /**
28090
30735
  * Returns the division associated with this flow.
28091
30736
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -28134,7 +30779,7 @@ export class ArchFlowInboundChat extends ArchBaseFlowWorkflow {
28134
30779
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
28135
30780
  * flow instance.
28136
30781
  */
28137
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
30782
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
28138
30783
  /**
28139
30784
  * Creates a new flow on the server and saves its configuration
28140
30785
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -28223,7 +30868,7 @@ export class ArchFlowInboundChat extends ArchBaseFlowWorkflow {
28223
30868
  * on this flow. The first parameter passed to the callback function will be this
28224
30869
  * Architect flow instance.
28225
30870
  */
28226
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
30871
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
28227
30872
  /**
28228
30873
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
28229
30874
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -28234,7 +30879,7 @@ export class ArchFlowInboundChat extends ArchBaseFlowWorkflow {
28234
30879
  * on this flow. The first parameter passed to the callback function will be this
28235
30880
  * Architect flow instance.
28236
30881
  */
28237
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
30882
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
28238
30883
  /**
28239
30884
  * Returns whether or not the flow is created in Genesys Cloud.
28240
30885
  */
@@ -28539,7 +31184,7 @@ export class ArchFlowInboundEmail extends ArchBaseFlowWorkflow {
28539
31184
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
28540
31185
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
28541
31186
  */
28542
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
31187
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
28543
31188
  /**
28544
31189
  * Returns the division associated with this flow.
28545
31190
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -28588,7 +31233,7 @@ export class ArchFlowInboundEmail extends ArchBaseFlowWorkflow {
28588
31233
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
28589
31234
  * flow instance.
28590
31235
  */
28591
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
31236
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
28592
31237
  /**
28593
31238
  * Creates a new flow on the server and saves its configuration
28594
31239
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -28677,7 +31322,7 @@ export class ArchFlowInboundEmail extends ArchBaseFlowWorkflow {
28677
31322
  * on this flow. The first parameter passed to the callback function will be this
28678
31323
  * Architect flow instance.
28679
31324
  */
28680
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
31325
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
28681
31326
  /**
28682
31327
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
28683
31328
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -28688,7 +31333,7 @@ export class ArchFlowInboundEmail extends ArchBaseFlowWorkflow {
28688
31333
  * on this flow. The first parameter passed to the callback function will be this
28689
31334
  * Architect flow instance.
28690
31335
  */
28691
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
31336
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
28692
31337
  /**
28693
31338
  * Returns whether or not the flow is created in Genesys Cloud.
28694
31339
  */
@@ -28985,7 +31630,7 @@ export class ArchFlowInboundShortMessage extends ArchBaseFlowWorkflow {
28985
31630
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
28986
31631
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
28987
31632
  */
28988
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
31633
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
28989
31634
  /**
28990
31635
  * Returns the division associated with this flow.
28991
31636
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -29034,7 +31679,7 @@ export class ArchFlowInboundShortMessage extends ArchBaseFlowWorkflow {
29034
31679
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
29035
31680
  * flow instance.
29036
31681
  */
29037
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
31682
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
29038
31683
  /**
29039
31684
  * Creates a new flow on the server and saves its configuration
29040
31685
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -29123,7 +31768,7 @@ export class ArchFlowInboundShortMessage extends ArchBaseFlowWorkflow {
29123
31768
  * on this flow. The first parameter passed to the callback function will be this
29124
31769
  * Architect flow instance.
29125
31770
  */
29126
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
31771
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
29127
31772
  /**
29128
31773
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
29129
31774
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -29134,7 +31779,7 @@ export class ArchFlowInboundShortMessage extends ArchBaseFlowWorkflow {
29134
31779
  * on this flow. The first parameter passed to the callback function will be this
29135
31780
  * Architect flow instance.
29136
31781
  */
29137
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
31782
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
29138
31783
  /**
29139
31784
  * Returns whether or not the flow is created in Genesys Cloud.
29140
31785
  */
@@ -29724,6 +32369,10 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29724
32369
  * The initial audio set on the flow.
29725
32370
  */
29726
32371
  readonly initialAudio: ArchAudio;
32372
+ /**
32373
+ * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
32374
+ */
32375
+ readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
29727
32376
  /**
29728
32377
  * Sets the specified menu to be the starting task on the flow.
29729
32378
  * @param archMenu - An Architect Scripting menu object.
@@ -29750,7 +32399,7 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29750
32399
  * Returns the starting task or menu for this call flow.
29751
32400
  * If there is no startup object configured, accessing this property returns null.
29752
32401
  */
29753
- readonly startUpObject: ArchTask | ArchMenu;
32402
+ readonly startUpObject: ArchTask | ArchMenu | null;
29754
32403
  /**
29755
32404
  * The outbound settings for the flow such as contact list and default wrapup code.
29756
32405
  */
@@ -29804,7 +32453,7 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29804
32453
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
29805
32454
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
29806
32455
  */
29807
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
32456
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
29808
32457
  /**
29809
32458
  * Returns the division associated with this flow.
29810
32459
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -29853,7 +32502,7 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29853
32502
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
29854
32503
  * flow instance.
29855
32504
  */
29856
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
32505
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
29857
32506
  /**
29858
32507
  * Creates a new flow on the server and saves its configuration
29859
32508
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -29942,7 +32591,7 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29942
32591
  * on this flow. The first parameter passed to the callback function will be this
29943
32592
  * Architect flow instance.
29944
32593
  */
29945
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
32594
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
29946
32595
  /**
29947
32596
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
29948
32597
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -29953,7 +32602,7 @@ export class ArchFlowOutboundCall extends ArchBaseFlowInboundOutboundSecureCall
29953
32602
  * on this flow. The first parameter passed to the callback function will be this
29954
32603
  * Architect flow instance.
29955
32604
  */
29956
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
32605
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
29957
32606
  /**
29958
32607
  * Returns whether or not the flow is created in Genesys Cloud.
29959
32608
  */
@@ -30196,6 +32845,10 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30196
32845
  * The initial audio set on the flow.
30197
32846
  */
30198
32847
  readonly initialAudio: ArchAudio;
32848
+ /**
32849
+ * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
32850
+ */
32851
+ readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
30199
32852
  /**
30200
32853
  * Sets the specified menu to be the starting task on the flow.
30201
32854
  * @param archMenu - An Architect Scripting menu object.
@@ -30222,7 +32875,7 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30222
32875
  * Returns the starting task or menu for this call flow.
30223
32876
  * If there is no startup object configured, accessing this property returns null.
30224
32877
  */
30225
- readonly startUpObject: ArchTask | ArchMenu;
32878
+ readonly startUpObject: ArchTask | ArchMenu | null;
30226
32879
  /**
30227
32880
  * The outbound settings for the flow such as contact list and default wrapup code.
30228
32881
  */
@@ -30276,7 +32929,7 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30276
32929
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
30277
32930
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
30278
32931
  */
30279
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
32932
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
30280
32933
  /**
30281
32934
  * Returns the division associated with this flow.
30282
32935
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -30325,7 +32978,7 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30325
32978
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
30326
32979
  * flow instance.
30327
32980
  */
30328
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
32981
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
30329
32982
  /**
30330
32983
  * Creates a new flow on the server and saves its configuration
30331
32984
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -30414,7 +33067,7 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30414
33067
  * on this flow. The first parameter passed to the callback function will be this
30415
33068
  * Architect flow instance.
30416
33069
  */
30417
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33070
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
30418
33071
  /**
30419
33072
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
30420
33073
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -30425,7 +33078,7 @@ export class ArchFlowSecureCall extends ArchBaseFlowInboundOutboundSecureCall {
30425
33078
  * on this flow. The first parameter passed to the callback function will be this
30426
33079
  * Architect flow instance.
30427
33080
  */
30428
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33081
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
30429
33082
  /**
30430
33083
  * Returns whether or not the flow is created in Genesys Cloud.
30431
33084
  */
@@ -30722,7 +33375,7 @@ export class ArchFlowSurveyInvite extends ArchBaseFlowWorkflow {
30722
33375
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
30723
33376
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
30724
33377
  */
30725
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
33378
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
30726
33379
  /**
30727
33380
  * Returns the division associated with this flow.
30728
33381
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -30771,7 +33424,7 @@ export class ArchFlowSurveyInvite extends ArchBaseFlowWorkflow {
30771
33424
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
30772
33425
  * flow instance.
30773
33426
  */
30774
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
33427
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
30775
33428
  /**
30776
33429
  * Creates a new flow on the server and saves its configuration
30777
33430
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -30860,7 +33513,7 @@ export class ArchFlowSurveyInvite extends ArchBaseFlowWorkflow {
30860
33513
  * on this flow. The first parameter passed to the callback function will be this
30861
33514
  * Architect flow instance.
30862
33515
  */
30863
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33516
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
30864
33517
  /**
30865
33518
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
30866
33519
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -30871,7 +33524,7 @@ export class ArchFlowSurveyInvite extends ArchBaseFlowWorkflow {
30871
33524
  * on this flow. The first parameter passed to the callback function will be this
30872
33525
  * Architect flow instance.
30873
33526
  */
30874
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33527
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
30875
33528
  /**
30876
33529
  * Returns whether or not the flow is created in Genesys Cloud.
30877
33530
  */
@@ -31194,7 +33847,7 @@ export class ArchFlowVoiceSurvey extends ArchBaseFlowBot {
31194
33847
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
31195
33848
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
31196
33849
  */
31197
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
33850
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
31198
33851
  /**
31199
33852
  * Returns the division associated with this flow.
31200
33853
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -31243,7 +33896,7 @@ export class ArchFlowVoiceSurvey extends ArchBaseFlowBot {
31243
33896
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
31244
33897
  * flow instance.
31245
33898
  */
31246
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
33899
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
31247
33900
  /**
31248
33901
  * Creates a new flow on the server and saves its configuration
31249
33902
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -31332,7 +33985,7 @@ export class ArchFlowVoiceSurvey extends ArchBaseFlowBot {
31332
33985
  * on this flow. The first parameter passed to the callback function will be this
31333
33986
  * Architect flow instance.
31334
33987
  */
31335
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33988
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
31336
33989
  /**
31337
33990
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
31338
33991
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -31343,7 +33996,7 @@ export class ArchFlowVoiceSurvey extends ArchBaseFlowBot {
31343
33996
  * on this flow. The first parameter passed to the callback function will be this
31344
33997
  * Architect flow instance.
31345
33998
  */
31346
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
33999
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
31347
34000
  /**
31348
34001
  * Returns whether or not the flow is created in Genesys Cloud.
31349
34002
  */
@@ -31582,6 +34235,10 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31582
34235
  * The initial audio set on the flow.
31583
34236
  */
31584
34237
  readonly initialAudio: ArchAudio;
34238
+ /**
34239
+ * Returns true indicating that this is an ArchBaseFlowInboundOutboundSecureCall object.
34240
+ */
34241
+ readonly isArchBaseFlowInboundOutboundSecureCall: boolean;
31585
34242
  /**
31586
34243
  * Sets the specified menu to be the starting task on the flow.
31587
34244
  * @param archMenu - An Architect Scripting menu object.
@@ -31608,7 +34265,7 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31608
34265
  * Returns the starting task or menu for this call flow.
31609
34266
  * If there is no startup object configured, accessing this property returns null.
31610
34267
  */
31611
- readonly startUpObject: ArchTask | ArchMenu;
34268
+ readonly startUpObject: ArchTask | ArchMenu | null;
31612
34269
  /**
31613
34270
  * The outbound settings for the flow such as contact list and default wrapup code.
31614
34271
  */
@@ -31662,7 +34319,7 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31662
34319
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
31663
34320
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
31664
34321
  */
31665
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
34322
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
31666
34323
  /**
31667
34324
  * Returns the division associated with this flow.
31668
34325
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -31711,7 +34368,7 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31711
34368
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
31712
34369
  * flow instance.
31713
34370
  */
31714
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
34371
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
31715
34372
  /**
31716
34373
  * Creates a new flow on the server and saves its configuration
31717
34374
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -31800,7 +34457,7 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31800
34457
  * on this flow. The first parameter passed to the callback function will be this
31801
34458
  * Architect flow instance.
31802
34459
  */
31803
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
34460
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
31804
34461
  /**
31805
34462
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
31806
34463
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -31811,7 +34468,7 @@ export class ArchFlowVoicemail extends ArchBaseFlowInboundOutboundSecureCall {
31811
34468
  * on this flow. The first parameter passed to the callback function will be this
31812
34469
  * Architect flow instance.
31813
34470
  */
31814
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
34471
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
31815
34472
  /**
31816
34473
  * Returns whether or not the flow is created in Genesys Cloud.
31817
34474
  */
@@ -32108,7 +34765,7 @@ export class ArchFlowWorkflow extends ArchBaseFlowWorkflow {
32108
34765
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
32109
34766
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
32110
34767
  */
32111
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
34768
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
32112
34769
  /**
32113
34770
  * Returns the division associated with this flow.
32114
34771
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -32157,7 +34814,7 @@ export class ArchFlowWorkflow extends ArchBaseFlowWorkflow {
32157
34814
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
32158
34815
  * flow instance.
32159
34816
  */
32160
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
34817
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
32161
34818
  /**
32162
34819
  * Creates a new flow on the server and saves its configuration
32163
34820
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -32246,7 +34903,7 @@ export class ArchFlowWorkflow extends ArchBaseFlowWorkflow {
32246
34903
  * on this flow. The first parameter passed to the callback function will be this
32247
34904
  * Architect flow instance.
32248
34905
  */
32249
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
34906
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
32250
34907
  /**
32251
34908
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
32252
34909
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -32257,7 +34914,7 @@ export class ArchFlowWorkflow extends ArchBaseFlowWorkflow {
32257
34914
  * on this flow. The first parameter passed to the callback function will be this
32258
34915
  * Architect flow instance.
32259
34916
  */
32260
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
34917
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
32261
34918
  /**
32262
34919
  * Returns whether or not the flow is created in Genesys Cloud.
32263
34920
  */
@@ -32558,7 +35215,7 @@ export class ArchFlowWorkitem extends ArchBaseFlowWorkflow {
32558
35215
  * @param [callbackFunction] - a callback function to call if the flow was checked out.
32559
35216
  * @returns - while this method returns a promise, you should use the callback function to perform any processing once the flow is checked out.
32560
35217
  */
32561
- checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<any>;
35218
+ checkoutAsync(forceUnlock?: boolean, callbackFunction?: callbackVoid): Promise<ArchFlowInfo>;
32562
35219
  /**
32563
35220
  * Returns the division associated with this flow.
32564
35221
  * This method first calls {@link ArchOrganizationInfo#areDivisionsAvailable} to ensure that divisions are available.
@@ -32607,7 +35264,7 @@ export class ArchFlowWorkitem extends ArchBaseFlowWorkflow {
32607
35264
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
32608
35265
  * flow instance.
32609
35266
  */
32610
- checkInAsync(ensureSearchable?: boolean): Promise<any>;
35267
+ checkInAsync(ensureSearchable?: boolean): Promise<ArchBaseFlow | undefined>;
32611
35268
  /**
32612
35269
  * Creates a new flow on the server and saves its configuration
32613
35270
  * @returns - On your promise's then handler, the first parameter passed to the then function will be this
@@ -32696,7 +35353,7 @@ export class ArchFlowWorkitem extends ArchBaseFlowWorkflow {
32696
35353
  * on this flow. The first parameter passed to the callback function will be this
32697
35354
  * Architect flow instance.
32698
35355
  */
32699
- importFromContentAsync(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
35356
+ importFromContentAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportContent: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
32700
35357
  /**
32701
35358
  * Imports the flow content from the supplied file path. Upon successful import, the callback function passed in
32702
35359
  * will be called. Importing flow contents in to a flow is something where you should *not* attempt to
@@ -32707,7 +35364,7 @@ export class ArchFlowWorkitem extends ArchBaseFlowWorkflow {
32707
35364
  * on this flow. The first parameter passed to the callback function will be this
32708
35365
  * Architect flow instance.
32709
35366
  */
32710
- importFromFileAsync(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<any>;
35367
+ importFromFileAsync<T extends ArchBaseFlow = ArchBaseFlow>(exportFilePath: string, callbackFunction?: (...params: any[]) => any): Promise<T>;
32711
35368
  /**
32712
35369
  * Returns whether or not the flow is created in Genesys Cloud.
32713
35370
  */
@@ -34265,7 +36922,7 @@ export class ArchSettingsDetectionJobIntent extends ArchBaseObject {
34265
36922
  /**
34266
36923
  * Returns true indicating that this is an ArchSettingsDetectionJobIntent instance.
34267
36924
  */
34268
- readonly isArchSettingsDetectionJobIntent: any;
36925
+ readonly isArchSettingsDetectionJobIntent: boolean;
34269
36926
  /**
34270
36927
  * A string suitable for logging that contains information about this ArchSettingsDetectionJobIntent.
34271
36928
  */
@@ -34737,8 +37394,9 @@ export class ArchSettingsNluIntent extends ArchBaseObject {
34737
37394
  * Associates the given reusable task with the current {@link ArchSettingsNluIntent}. When you associate an intent with a task with input values in a digital flow,
34738
37395
  * and the task is invoked, the runtime will not supply any values for them so any input variables will pick up their
34739
37396
  * default values.
37397
+ * @param archReusableTask - the {@link ArchTask} to associate with this intent
34740
37398
  */
34741
- associateWithTask: any;
37399
+ associateWithTask(archReusableTask: ArchTask): void;
34742
37400
  /**
34743
37401
  * Returns the {@link ArchTask} that is associated with this {@link ArchSettingsNluIntent}. If one is not associated with
34744
37402
  * this intent or a task is not found, undefined is returned.
@@ -37152,7 +39810,6 @@ export class ArchTtsEngine extends ArchBaseCoreObjectWithId {
37152
39810
  * property to see if your organization supports this functionality.
37153
39811
  */
37154
39812
  export class ArchTtsEngines extends ArchBaseObject {
37155
- // constructor();
37156
39813
  /**
37157
39814
  * A logging string for the ArchTtsEngines instance.
37158
39815
  */
@@ -37406,17 +40063,9 @@ export class ArchTraverseSettings {
37406
40063
  shouldContinue: boolean;
37407
40064
  }
37408
40065
 
37409
- /**
37410
- * Creates an instance of an ArchValidationIssue object.
37411
- * This object holds validation error and warning information for an object in a flow. The archObject property
37412
- * will point to the Architect Scripting object for which this issue object is for. You can then look at the
37413
- * errors or warnings for that object by accessing the error or warning properties on this class.
37414
- * Instances of this object will be created by Architect Scripting when the {@link ArchBaseFlow#validateAsync} method
37415
- * is called and will be returned in the [validation results]{@link ArchValidationResults} returned from that call.
37416
- * @param coreValidationIssue - ( *Internal* ) an Architect core validation issue object
37417
- */
37418
40066
  export class ArchValidationIssue extends ArchBaseCoreObject {
37419
40067
  // constructor(coreValidationIssue: any);
40068
+ readonly isArchValidationIssue: boolean;
37420
40069
  /**
37421
40070
  * Returns the display type name string 'ArchValidationIssue'.
37422
40071
  */
@@ -37483,7 +40132,6 @@ export class ArchValidationIssue extends ArchBaseCoreObject {
37483
40132
  * @param [prefix] - a string to prefix before each line in the returned string.
37484
40133
  */
37485
40134
  getSummaryStr(wantDetails: boolean, prefix?: string): string;
37486
- readonly isArchValidationIssue: boolean;
37487
40135
  /**
37488
40136
  * The count of rollup errors for this issue.
37489
40137
  */
@@ -37508,17 +40156,136 @@ export class ArchValidationIssue extends ArchBaseCoreObject {
37508
40156
  * Returns a string array of warnings in this issue. If there are no warnings, no value is returned.
37509
40157
  */
37510
40158
  readonly warnings: string[];
40159
+ /**
40160
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
40161
+ */
40162
+ readonly isArchBaseCoreObject: boolean;
40163
+ /**
40164
+ * This method iterates over this object and ArchBaseCoreObject instances
40165
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
40166
+ * with a filter and call the supplied callback function if isMatch returns true.
40167
+ * The callback will be passed an {@link ArchTraverseInfo} with details
40168
+ * about the match such as the match object itself along with current contextual
40169
+ * information such as the object hierarchy for the match object relative to
40170
+ * the object on which this traverse call is being made.
40171
+ *
40172
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
40173
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
40174
+ * or clause containers to it. If not specified, this function will use a
40175
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
40176
+ *
40177
+ * Here is an example that does a simple flow traversal using the default
40178
+ * filter and logs information about objects in the callback from the
40179
+ * traverse object that's passed back:
40180
+ *
40181
+ * ```
40182
+ * archInboundCallFlow.traverse(function(traverseInfo) {
40183
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
40184
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
40185
+ * });
40186
+ * ```
40187
+ * This might be enough for most uses and you can check various aspects
40188
+ * about the object in the callback such as "is this an Architect action?" by
40189
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
40190
+ * a filter for the traversal code to use as well and only have it call your
40191
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
40192
+ * the filter. Here's an example that creates a filter for callbacks on
40193
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
40194
+ * [decision action]{@link ArchActionDecision} or objects whose name
40195
+ * property case insensitively matches the word 'foo'. While this could all be done
40196
+ * with one property callback clause the example will use multiple clauses for
40197
+ * the sake of simplicity:
40198
+ * ```
40199
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
40200
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
40201
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
40202
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
40203
+ * // We fully spelled out the function signature above but archContainingObject and propName are
40204
+ * // not needed in this case. The archContainingObject is the object that contains the
40205
+ * // property and propName is the property name itself. We pass in propName because the same
40206
+ * // function could be used for multiple property callback clauses.
40207
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
40208
+ * return propValue && propValue.toLowerCase() === 'foo';
40209
+ * });
40210
+ * archTask.traverse(function(traverseContext) {
40211
+ * // You will only be called back here for ArchBaseCoreObject instances that
40212
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
40213
+ * }, myTraverseFilter);
40214
+ * ```
40215
+ * If you supply a filter with no clauses, this tells the traverse method to
40216
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
40217
+ *
40218
+ * If you want traversal itself to stop after a callback, simply return boolean
40219
+ * false from the callback function you supply to the traverse call.
40220
+ *
40221
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
40222
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
40223
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
40224
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
40225
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
40226
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
40227
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
40228
+ *
40229
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
40230
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
40231
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
40232
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
40233
+ *
40234
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
40235
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
40236
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
40237
+ *
40238
+ * This function returns the number of times it called the callback function.
40239
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
40240
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
40241
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
40242
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
40243
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
40244
+ */
40245
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
40246
+ /**
40247
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
40248
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
40249
+ * logging str contents wouldn't be set up.
40250
+ */
40251
+ readonly logStrTypeOnly: string;
40252
+ /**
40253
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
40254
+ * @param errorStr - the error string to log.
40255
+ */
40256
+ logError(errorStr: string): void;
40257
+ /**
40258
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
40259
+ * the string in the errorStr parameter.
40260
+ * @param errorStr - the error string to log. This should be a non-blank string.
40261
+ */
40262
+ logErrorAndThrow(errorStr: string): void;
40263
+ /**
40264
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
40265
+ * @param noteStr - the note string to log. This should be a non-blank string.
40266
+ */
40267
+ logNote(noteStr: string): void;
40268
+ /**
40269
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
40270
+ * @param noteStr - the note string to log. This should be a non-blank string.
40271
+ */
40272
+ logNoteVerbose(noteStr: string): void;
40273
+ /**
40274
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
40275
+ * @param warningStr - the warning string to log. This should be a non-blank string.
40276
+ */
40277
+ logWarning(warningStr: string): void;
40278
+ /**
40279
+ * Returns whether or not this Architect Scripting object is a match
40280
+ * for the supplied ArchFilterObject instance.
40281
+ * @param archFilterObject - the object filter to use to determine if it's a match.
40282
+ */
40283
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
37511
40284
  }
37512
40285
 
37513
- /**
37514
- * Creates an instance of an ArchValidationResults object. The validation results object will be returned
37515
- * from flow [validation]{@link ArchBaseFlow#validateAsync} and contain information about warnings and errors that were reported during validation.
37516
- * There are issues within this results object that can further be accessed to get at more specifics about
37517
- * errors, warnings and the Architect Scripting objects they're associated with.
37518
- * @param coreValidationResultsViewModel - *Internal* The core validation results object
37519
- */
37520
40286
  export class ArchValidationResults extends ArchBaseCoreObject {
37521
40287
  // constructor(coreValidationResultsViewModel: any);
40288
+ readonly isArchValidationResults: boolean;
37522
40289
  /**
37523
40290
  * Returns the display type name string 'ArchValidationResults'.
37524
40291
  */
@@ -37684,7 +40451,131 @@ export class ArchValidationResults extends ArchBaseCoreObject {
37684
40451
  * and adding up the warningCount property for each validation issue.
37685
40452
  */
37686
40453
  readonly warningCountTotal: number;
37687
- readonly isArchValidationResults: boolean;
40454
+ /**
40455
+ * Returns true indicating that this is an ArchBaseCoreObject instance.
40456
+ */
40457
+ readonly isArchBaseCoreObject: boolean;
40458
+ /**
40459
+ * This method iterates over this object and ArchBaseCoreObject instances
40460
+ * within it. For each object it will call the {@link ArchBaseObject#isFilterMatch} method
40461
+ * with a filter and call the supplied callback function if isMatch returns true.
40462
+ * The callback will be passed an {@link ArchTraverseInfo} with details
40463
+ * about the match such as the match object itself along with current contextual
40464
+ * information such as the object hierarchy for the match object relative to
40465
+ * the object on which this traverse call is being made.
40466
+ *
40467
+ * The traverse [filter]{@link ArchFilterObject} is one which you can create
40468
+ * by calling {@link ArchFactoryFilters#createFilterObject} and then add desired clauses
40469
+ * or clause containers to it. If not specified, this function will use a
40470
+ * [default filter]{@link ArchFactoryFilters#createFilterTraverseDefault}.
40471
+ *
40472
+ * Here is an example that does a simple flow traversal using the default
40473
+ * filter and logs information about objects in the callback from the
40474
+ * traverse object that's passed back:
40475
+ *
40476
+ * ```
40477
+ * archInboundCallFlow.traverse(function(traverseInfo) {
40478
+ * archLogging.logNote(' Object : ' + traverseInfo.matchObject.logStr);
40479
+ * archLogging.logNote(' Hierarchy: ' + traverseInfo.context.hierarchyStr);
40480
+ * });
40481
+ * ```
40482
+ * This might be enough for most uses and you can check various aspects
40483
+ * about the object in the callback such as "is this an Architect action?" by
40484
+ * seeing if traverseInfo.matchObject.isArchBaseAction is true. You can specify
40485
+ * a filter for the traversal code to use as well and only have it call your
40486
+ * callback when the object's {@link ArchBaseCoreObject#isFilterMatch} method returns true for
40487
+ * the filter. Here's an example that creates a filter for callbacks on
40488
+ * [any type of transfer action]{@link ArchBaseActionTransfer}, any
40489
+ * [decision action]{@link ArchActionDecision} or objects whose name
40490
+ * property case insensitively matches the word 'foo'. While this could all be done
40491
+ * with one property callback clause the example will use multiple clauses for
40492
+ * the sake of simplicity:
40493
+ * ```
40494
+ * const myTraverseFilter = filterFactory.createFilterObject(archEnums.FILTER_CONTAINER_OPERATORS.or);
40495
+ * myTraverseFilter.addClausePropertyValueEquals('isArchBaseActionTransfer', true);
40496
+ * myTraverseFilter.addClausePropertyValueEquals('isArchActionDecision', true);
40497
+ * myTraverseFilter.addClausePropertyCallback('name', function(propValue, archContainingObject, propName) {
40498
+ * // We fully spelled out the function signature above but archContainingObject and propName are
40499
+ * // not needed in this case. The archContainingObject is the object that contains the
40500
+ * // property and propName is the property name itself. We pass in propName because the same
40501
+ * // function could be used for multiple property callback clauses.
40502
+ * // Remember to return a boolean true, false or undefined from ths callback. :)
40503
+ * return propValue && propValue.toLowerCase() === 'foo';
40504
+ * });
40505
+ * archTask.traverse(function(traverseContext) {
40506
+ * // You will only be called back here for ArchBaseCoreObject instances that
40507
+ * // have the isArchBaseActionTransfer or isArchActionDecision property values equal to true.
40508
+ * }, myTraverseFilter);
40509
+ * ```
40510
+ * If you supply a filter with no clauses, this tells the traverse method to
40511
+ * call the supplied callback function for every {@link ArchBaseCoreObject} it traverses.
40512
+ *
40513
+ * If you want traversal itself to stop after a callback, simply return boolean
40514
+ * false from the callback function you supply to the traverse call.
40515
+ *
40516
+ * The traverse method does not process deprecated property names such as [orgId]{@link ArchSession#orgId},
40517
+ * [orgName]{@link ArchSession#orgName} or [languageSettings]{@link ArchBaseFlow#languageSettings}. Additionally
40518
+ * it does not traverse in to properties that would "jump out" of the current traversal. An example of this
40519
+ * would be if the code was traversing an {@link ArchActionJumpToMenu} action that it would not start traversing
40520
+ * in to the menu that it jumps to. Another example would be a {@link ArchActionChangeState} action where
40521
+ * it would not traverse in to the target state of the action. This also means traversal does not traverse
40522
+ * in to the {@link ArchBaseValue#flowLevelDefault} property.
40523
+ *
40524
+ * And lastly, as Scripting evolves over time with new versions, you can expect to get callbacks for new object
40525
+ * types such as new actions or new properties on objects. As such, it's important not to assume any particular
40526
+ * order in callbacks to keep code most compatible with traversal callbacks. Or if you use inequality checks in filter
40527
+ * clauses remember that new "stuff" may satisfy an inequality check which may or may not be anticipated in your logic.
40528
+ *
40529
+ * Note: This traverse method is a helper method and is very handy for iterating over Architect Scripting
40530
+ * objects and their properties in a generic fashion with filtering capabilities. Obviously you can write
40531
+ * your own custom traversal code if this implementation doesn't cut it for some reason. :)
40532
+ *
40533
+ * This function returns the number of times it called the callback function.
40534
+ * @param callbackFunction - the callback function to call for objects that match the traverse filter.
40535
+ * @param [traverseFilter = {@link ArchFactoryFilters#createFilterTraverseDefault}] - the filter to use when performing the traversal to determine which
40536
+ * {@link ArchBaseCoreObject} instances you wish to be called back for. If no
40537
+ * filter is specified, this function will call {@link ArchFactoryFilters#createFilterTraverseDefault} and
40538
+ * use that traversal default filter. The wantArchBaseValues parameter on that call is set to true.
40539
+ */
40540
+ traverse(callbackFunction: callbackTraverseInfo, traverseFilter?: ArchFilterObject): number;
40541
+ /**
40542
+ * This is a string suitable for logging information about this object where it's just the object's type. This is normally used
40543
+ * when logging errors that occur in constructor parameter checking because the scripting object isn't set up and the normal
40544
+ * logging str contents wouldn't be set up.
40545
+ */
40546
+ readonly logStrTypeOnly: string;
40547
+ /**
40548
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true.
40549
+ * @param errorStr - the error string to log.
40550
+ */
40551
+ logError(errorStr: string): void;
40552
+ /**
40553
+ * Logs an error to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logErrors} is true and then throws
40554
+ * the string in the errorStr parameter.
40555
+ * @param errorStr - the error string to log. This should be a non-blank string.
40556
+ */
40557
+ logErrorAndThrow(errorStr: string): void;
40558
+ /**
40559
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotes} is true.
40560
+ * @param noteStr - the note string to log. This should be a non-blank string.
40561
+ */
40562
+ logNote(noteStr: string): void;
40563
+ /**
40564
+ * Logs a note to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logNotesVerbose} is true.
40565
+ * @param noteStr - the note string to log. This should be a non-blank string.
40566
+ */
40567
+ logNoteVerbose(noteStr: string): void;
40568
+ /**
40569
+ * Logs a warning to the logging service with a log header from this object's [logStr]{@link ArchBaseObject#logStr} property value when {@link ArchLogging#logWarnings} is true.
40570
+ * @param warningStr - the warning string to log. This should be a non-blank string.
40571
+ */
40572
+ logWarning(warningStr: string): void;
40573
+ /**
40574
+ * Returns whether or not this Architect Scripting object is a match
40575
+ * for the supplied ArchFilterObject instance.
40576
+ * @param archFilterObject - the object filter to use to determine if it's a match.
40577
+ */
40578
+ isFilterMatch(archFilterObject: ArchFilterObject): boolean;
37688
40579
  }
37689
40580
 
37690
40581
  export class ArchChoice extends ArchBaseCoreObject {
@@ -88491,6 +91382,7 @@ declare module 'purecloud-flow-scripting-api-sdk-javascript' {
88491
91382
  let ArchBaseFilterClausePropertyValue: ArchBaseFilterClausePropertyValue;
88492
91383
  let ArchBaseFilterMatching: ArchBaseObjectFilterCommon;
88493
91384
  let ArchBaseFlow: ArchBaseFlow;
91385
+ let ArchBaseFlowBot: ArchBaseFlowBot;
88494
91386
  let ArchBaseFlowInboundOutboundSecureCall: ArchBaseFlowInboundOutboundSecureCall;
88495
91387
  let ArchBaseFlowWithMenus: ArchBaseFlowWithMenus;
88496
91388
  let ArchBaseFlowWithTasks: ArchBaseFlowWithTasks;