Skip to content

Commit

Permalink
feat(clevertap): support clevertap-cordova 3.3.0 (#4883)
Browse files Browse the repository at this point in the history
* feat(clevertap): add CleverTap plugin

* style(clevertap): cleanup stray lint error

* refactor

* feat(clevertap): update for latest CleverTap Cordova plugin

* chore: Update Repo from Ionic Native Repo

* fix: Code Changes for parity SDK-155

* fix: Indentation fixes for SDK-155

* fix: Code Repo fix while updating fork branch

* fix: Remove unnecessary adder .scripts Folder

* fix: Remove unwanted added folder .circleci

* fix: Remove unwanted added File .npmrc

* fix: Revert .Github Folder Changes to as per Ionic-Native master

* fix: Update changes as per ionic-native master

* fix: Code Repo fix while updating fork branch

fix: Remove unnecessary adder .scripts Folder

fix: Remove unwanted added folder .circleci

fix: Remove unwanted added File .npmrc

fix: Revert .Github Folder Changes to as per Ionic-Native master

fix: Update changes as per ionic-native master

* fix(CleverTap): Fix for missing methods issue #3491

* refactor(profile): remove setProfile methods for fb and google

* refactor(dynamic variables): remove Product A/B Testing (Dynamic Variables) code

* fix(product config): add key param to product config getters

* feat(identity): add a new public method getCleverTapID and deprecate existing CleverTapID methods

* feat(profile): add public methods to increment/decrement values set via User properties

* feat(profile): add public methods to increment/decrement values set via User properties

* feat(inapp): add public methods for suspending/discarding & resuming InApp Notifications

* feat(inbox): add new api for iOS to delete bulk inbox messages for given message ids

* refactor(xiaomi-push): add region as an extra mandatory parameter to setPushXiaomiToken

* Update index.ts to support cordova 2.7.0

* Update index.ts

* feat(clevertap): support clevertap-cordova 2.7.2

* feat(clevertap): support clevertap-cordova 2.7.2

* feat(clevertap): support clevertap-cordova 2.7.2

* task(SDK-3757) - Add support for cordova v3.0.0

- Adds 2 new APIs = clearInAppResources() and fetchInApps()

* task(SDK-3757) - Add support for cordova v3.2.0

- Removes xiaomi related APIs

* task(SDK-4148) - Add support for cordova v3.3.0

- Custom Templates
- File Variables

---------

Co-authored-by: Peter Wilkniss <[email protected]>
Co-authored-by: Daniel Sogl <[email protected]>
Co-authored-by: Darshan Pania <[email protected]>
Co-authored-by: Surya <[email protected]>
Co-authored-by: SuryaClevertap <[email protected]>
Co-authored-by: Piyush Kukadiya <[email protected]>
Co-authored-by: piyush-kukadiya <[email protected]>
Co-authored-by: AishwaryaNanna <[email protected]>
  • Loading branch information
9 people authored Dec 16, 2024
1 parent eca218a commit 21e3e37
Showing 1 changed file with 192 additions and 0 deletions.
192 changes: 192 additions & 0 deletions src/@awesome-cordova-plugins/plugins/clevertap/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -662,6 +662,17 @@ export class CleverTap extends AwesomeCordovaNativePlugin {
return;
}

/**
* Deletes all types of files which are preloaded for SDK features like custom in-app templates, app functions and variables etc.
*
* @param expiredOnly {boolean} - to clear only assets which will not be needed further for inapps
* @returns {Promise<any>}
*/
@Cordova()
clearFileResources(expiredOnly: boolean): Promise<any> {
return;
}

/**
* Fetches In Apps from server.
*
Expand Down Expand Up @@ -1132,6 +1143,16 @@ export class CleverTap extends AwesomeCordovaNativePlugin {
return;
}

/**
* Create File Variable
* @returns {Promise<any>}
* @param {string} variable The String specifying the name of file varible to be created.
*/
@Cordova()
defineFileVariable(variable: string): Promise<any> {
return;
}

/**
* Get a variable or a group for the specified name.
* @param {string} name - name.
Expand Down Expand Up @@ -1170,6 +1191,177 @@ export class CleverTap extends AwesomeCordovaNativePlugin {
return;
}


/**
* Called when the value of the file variable is downloaded and ready
* @param {name} string the name of the variable
* @returns {Promise<any>}
*/
@Cordova()
onFileValueChanged(name: string): Promise<any> {
return;
}

/**
* Adds a callback to be invoked when variables are initialised with server values. Will be called only once on app start, or when added if server values are already received
* @returns {Promise<any>}
*/
@Cordova()
onOneTimeVariablesChanged(): Promise<any> {
return;
}

/**
* Adds a callback to be invoked when no files need to be downloaded or all downloads have been completed. It is called each time new values are fetched and downloads are completed.
* @returns {Promise<any>}
*/
@Cordova()
onVariablesChangedAndNoDownloadsPending(): Promise<any> {
return;
}

/**
* Adds a callback to be invoked only once for when new values are fetched and downloaded
* @returns {Promise<any>}
*/
@Cordova()
onceVariablesChangedAndNoDownloadsPending(): Promise<any> {
return;
}


/****************************
* Custom Templates methods
****************************/

/**
*
* Uploads Custom in-app templates and app functions to the server. Requires Development/Debug build/configuration.
* @returns {Promise<any>}
*/
@Cordova()
syncCustomTemplates(): Promise<any> {
return;
}

/**
* Uploads Custom in-app templates and app functions to the server.
* @param {boolean} isProduction Provide `true` if templates must be sync in Productuon build/configuration.
* @returns {Promise<any>}
*
*
* Note: This is NO-OP in Android
*/
@Cordova()
syncCustomTemplatesInProd(isProduction: boolean): Promise<any> {
return;
}

/**
* Notify the SDK that an active custom template is dismissed. The active custom template is considered to be
* visible to the user until this method is called. Since the SDK can show only one InApp message at a time, all
* other messages will be queued until the current one is dismissed.
* @param {string} templateName The name of the active template
* @returns {Promise<any>}
*/
@Cordova()
customTemplateSetDismissed(templateName: string): Promise<any> {
return;
}


/**
* Notify the SDK that an active custom template is presented to the user.
* @param {string} templateName The name of the active template
* @returns {Promise<any>}
*/
@Cordova()
customTemplateSetPresented(templateName: string): Promise<any> {
return;
}

/**
* Trigger a custom template action argument by name.
*
* @param {string} templateName The name of an active template for which the action is defined
* @param {string} argName The action argument na
* @returns {Promise<any>}
*/
@Cordova()
customTemplateRunAction(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Retrieve a string argument by name.
*
* @param {string} templateName The name of an active template for which the argument is defined
* @param {string} argName The action argument name
* @returns {Promise<any>}
*/
@Cordova()
customTemplateGetStringArg(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Retrieve a number argument by name.
*
* @param {string} templateName The name of an active template for which the argument is defined
* @param {string} argName The action argument name
* @returns {Promise<any>}
*/
@Cordova()
customTemplateGetNumberArg(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Retrieve a boolean argument by name.
*
* @param {string} templateName The name of an active template for which the argument is defined
* @param {string} argName The action argument name
* @returns {Promise<any>}
*/
@Cordova()
customTemplateGetBooleanArg(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Retrieve a file argument by name.
*
* @param {string} templateName The name of an active template for which the argument is defined
* @param {string} argName The action argument name
* @returns {Promise<any>}
*/
@Cordova()
customTemplateGetFileArg(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Retrieve an object argument by name.
*
* @param {string} templateName The name of an active template for which the argument is defined
* @param {string} argName The action argument name
* @returns {Promise<any>}
*/
@Cordova()
customTemplateGetObjectArg(templateName: string, argName: string): Promise<any> {
return;
}

/**
* Get a string representation of an active's template context with information about all arguments.
* @param {string} templateName The name of an active template
* @returns {Promise<any>}
*/
@Cordova()
customTemplateContextToString(templateName: string): Promise<any> {
return;
}

/****************************
* Android 13 Push Primer
****************************/
Expand Down

0 comments on commit 21e3e37

Please sign in to comment.