Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[VC-977] Release v0.7.6 #46

Merged
merged 51 commits into from
Jan 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
cdbb618
Merge pull request #27 from CleverTap/sync_develop_with_main
shivamsharma2710 Oct 9, 2024
4cad2ec
fix(VC-978): remove invalid character from SDK's podspec file
shivamsharma2710 Dec 23, 2024
5b2796e
update lefthook.yml to fix pre-commit issue which blocks commits
shivamsharma2710 Dec 23, 2024
3f10935
run yarn, commit .lock and autogenerated files
shivamsharma2710 Dec 23, 2024
9b4a736
task(VC-968): replace sc remote dependency with a local .aar dependency
shivamsharma2710 Dec 23, 2024
75d9901
consume metaData of CT creds from local.properties
shivamsharma2710 Dec 23, 2024
2b60d4b
consume signed call creds from .env file
shivamsharma2710 Dec 23, 2024
0e64e85
task(VC-968): upgrade minSdk and targetSdk
shivamsharma2710 Dec 23, 2024
99613bf
task(VC-968): update sample app to target API level 34
shivamsharma2710 Dec 23, 2024
0292476
Remove .env file from version control
shivamsharma2710 Dec 23, 2024
d76069c
update gitignore
shivamsharma2710 Dec 29, 2024
60d2621
Remove .env from version control
shivamsharma2710 Dec 29, 2024
d81e574
update gitignore
shivamsharma2710 Dec 30, 2024
acf92b3
fix(VC-968): fix runTimeException - Requested enabled DevSupportManag…
shivamsharma2710 Dec 30, 2024
3aee152
task(VC-968): create lib folder to consume local v0.0.7.6.aar file
shivamsharma2710 Dec 30, 2024
65faef9
feat(VC-969): replace deprecated approach with the latest callback ha…
shivamsharma2710 Dec 30, 2024
a3be2d9
refactor(VC-969):
shivamsharma2710 Dec 30, 2024
edfaa50
task(VC-971): sdk module and sample app UI changes to configure the b…
shivamsharma2710 Dec 31, 2024
3db294f
fix buttonTheme handling in sample app
shivamsharma2710 Dec 31, 2024
6101aaf
task(VC-975): sample app UI changes to input remote_context
shivamsharma2710 Dec 31, 2024
eb8d8af
task(VC-974): expose callScreenOnSignalling API param
shivamsharma2710 Dec 31, 2024
3cf094a
task(VC-987): make outgoingCallResponse callback instance to hold the…
shivamsharma2710 Dec 31, 2024
5054ae9
task(VC-975): add remoteContext field in SignedCallOnCallStatusChang…
shivamsharma2710 Dec 31, 2024
44b84a3
Merge branch 'task/VC-975/remote_context_for_call' of github.com:Clev…
shivamsharma2710 Dec 31, 2024
28a39a3
Merge branch 'task/VC-974/expose_callScreenOnSignalling_parameter' of…
shivamsharma2710 Dec 31, 2024
c13d8ea
task(VC-988): expose callback events in parity with v0.0.7.6
shivamsharma2710 Dec 31, 2024
36e3e06
task(VC-988): support CleanupCall callState
shivamsharma2710 Dec 31, 2024
705e226
task(VC-970): expose fcm processing mode implementation
shivamsharma2710 Dec 31, 2024
c22853f
task(VC-989): expose signalling channel
shivamsharma2710 Dec 31, 2024
ab9ff1e
fix(VC-989): revert model name
shivamsharma2710 Dec 31, 2024
3821fe8
task(VC-990): update SDK's podSpec to version lock the SC iOS to 0.0.9
shivamsharma2710 Dec 31, 2024
8700c42
task(VC-990): run `pod repo update`
shivamsharma2710 Jan 1, 2025
48115c1
task(VC-990):
shivamsharma2710 Jan 1, 2025
7076709
task(VC-990): support remoteContext in callOptions parameter
shivamsharma2710 Jan 1, 2025
c3d99cd
- supports SC v0.0.7.6
shivamsharma2710 Jan 2, 2025
14c2df8
remove SC .aar libs
shivamsharma2710 Jan 2, 2025
f0546ae
pushprofile with email, remove logo to prevent from UI to strip off
shivamsharma2710 Jan 6, 2025
64e8df3
commit bundle file and iOS project config
shivamsharma2710 Jan 6, 2025
518c1ba
update, readme, changelog and versioning
shivamsharma2710 Jan 6, 2025
6eef845
Merge pull request #45 from CleverTap/doc/VC-1001/changelog_readme
shivamsharma2710 Jan 6, 2025
e8a9e26
Merge pull request #44 from CleverTap/task/VC-990/support_ios_v0.0.9
shivamsharma2710 Jan 6, 2025
1769a63
Merge pull request #43 from CleverTap/task/VC-989/expose_singalling_c…
shivamsharma2710 Jan 6, 2025
3c01831
Merge pull request #42 from CleverTap/task/VC-970/fcm_processing_mode
shivamsharma2710 Jan 6, 2025
c248312
Merge pull request #41 from CleverTap/task/VC-988/expose_callback_eve…
shivamsharma2710 Jan 6, 2025
750ca73
Merge pull request #40 from CleverTap/task/VC-987/garabge-collector_fix
shivamsharma2710 Jan 6, 2025
0fff1f4
Merge pull request #39 from CleverTap/task/VC-974/expose_callScreenOn…
shivamsharma2710 Jan 6, 2025
f84cc9b
Merge pull request #38 from CleverTap/task/VC-975/remote_context_for_…
shivamsharma2710 Jan 6, 2025
7040837
Merge pull request #37 from CleverTap/task/VC-971/expose_cancelCountd…
shivamsharma2710 Jan 6, 2025
443695c
Merge pull request #36 from CleverTap/task/VC-969/task/new_missedCall…
shivamsharma2710 Jan 6, 2025
68b4740
Merge pull request #35 from CleverTap/task/VC-968/support_android_v0.…
shivamsharma2710 Jan 6, 2025
e616a40
Merge pull request #34 from CleverTap/fix/VC-978/fix_podspec_invalid_…
shivamsharma2710 Jan 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
# XDE
.expo/

example/.env

# VSCode
.vscode/
jsconfig.json
Expand Down
44 changes: 44 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,49 @@
# Change Log

### Version 0.7.6 (June 06, 2025)

---
**What's new**
* **[Android Platform]**
* Supports Signed Call Android SDK [v0.0.7.6](https://repo1.maven.org/maven2/com/clevertap/android/clevertap-signedcall-sdk/0.0.7.6/) which is compatible with CleverTap Android SDK [v6.2.1](https://github.com/CleverTap/clevertap-android-sdk/blob/master/docs/CTCORECHANGELOG.md#version-620-april-3-2024).
* **CallStyle Notifications on Android 12 and Onwards**:
* Replaced regular call notifications with the CallStyle notifications for incoming, outgoing and ongoing calls. This update adheres to the new standards for non-dismissible notifications as outlined in the [Android 14 behavior changes](https://developer.android.com/about/versions/14/behavior-changes-all#non-dismissable-notifications). These notifications are given top priority in the notification shade or tray.
* **Call Quality Control Enhancements**: Introduced network quality checks at both the initiator and receiver ends to ensure optimal call quality.
- At the **Initiator Side**, the SDK checks network latency before processing a call request. If the network latency exceeds the benchmark, set by the SDK, an error with `5004` error-code within the `SignedCallResponse` promise object is returned.
- At the **Receiver Side**, the SDK evaluates network quality before showing the incoming call screen. The network quality score (ranging from -1 to 100) is provided via the `onNetworkQualityResponse(int score)` callback, allowing the app to decide whether to proceed with or decline the call. Refer to the [SDK documentation](https://developer.clevertap.com/docs/signed-call-react-native-sdk#receiver-side) for detailed usage.
* **Support new parameters in the `initProperties` object which gets passed to the ` SignedCall.initialize(initProperties)` method**:
* `fcmProcessingMode` and `fcmProcessingNotification`: SDK supports the two modes for processing FCM calls: `FcmProcessingMode.foreground` and `FCMProcessingMode.background`. These modes determine how the SDK handles incoming calls whether in background or in a foreground service depending on whether the app is actively running or is running in the background. The `FcmProcessingMode.background` is default mode. If choosing the `FcmProcessingMode.foreground`, the `fcmProcessingNotification` parameter is mandatory. Refer to the [SDK documentation](https://developer.clevertap.com/docs/signed-call-react-native-sdk#configure-fcm-processing-mode) for more details on overriding the default mode.
* `callScreenOnSignalling` : A `Boolean` property to control when the outgoing call screen appears relative to the signaling process. By default, the SDK immediately displays the outgoing call screen upon a call request and performs the validations in background. Please refer to [SDK documentation](https://developer.clevertap.com/docs/signed-call-react-native-sdk#control-call-screen-display-timing) for detailed usage.
* **Support new call events in the `SignedCall.SignedCallOnCallStatusChanged` handler**:
* `CallEvent.AppInitiatedDeclinedDueToNetworkQuality`: Allows to determine the cases where app initiates the call-decline based on the network quality score provided within `onNetworkQualityResponse(int score)` callback.
* `CallEvent.EndedDueToLocalNetworkLoss`: Allows to determine when the call disconnects due to network loss at the local end.
* `CallEvent.EndedDueToRemoteNetworkLoss`: Allows to determine when the call disconnects due to network loss at the remote end.
**NOTE:** The `CallEvent.EndedDueToLocalNetworkLoss` and `CallEvent.EndedDueToRemoteNetworkLoss` events are reported alongside the existing `CallEvent.Ended` event to maintain backward compatibility.

* **[iOS Platform]**
* Supports [Signed Call iOS SDK v0.0.9](https://github.com/CleverTap/clevertap-signedcall-ios-sdk/blob/main/CHANGELOG.md#version-009-november-19-2024) which is compatible with [CleverTap iOS SDK v7.0.2](https://github.com/CleverTap/clevertap-ios-sdk/blob/master/CHANGELOG.md#version-702-october-10-2024) and higher.

* **[Android and iOS Platform]**
* **Remote Context Configuration for Call Screens:**
* Added support for setting a *remoteContext* parameter within `callProperties` object during call initiation, allowing to pass custom context for receiver's call screens.

**Bug Fixes**
* **[iOS Platform]**
* Resolved **sa_family_t** declaration issue to ensure compatibility with Xcode 16.
* Resolves `EXC_BAD_ACCESS` error that occurred when clicking the mute button on the CallKit screen. This exception was only observed in debugging mode.
* Fixes synchronization issues regarding the Mute and Speaker controllers between the CallKit and native screens.

**Behaviour Changes**
* **[Android Platform]**
* Optimized screen launch delay when initiating a call. The SDK now launches the outgoing call screen immediately, without waiting for signaling confirmation. A countdown ProgressBar is displayed around the cancel button until signaling is completed. You can use the `cancelCountdownColor` parameter within the `overrideDefaultBranding` initProperty to customize the countdown ProgressBar's color. The default color is *yellow (#F5FA55)*. Please refer to [SDK documentation](https://staging.docs.dev.clevertap.net/docs/signed-call-react-native-sdk#overridedefaultbranding-all-platforms) for the details on usage.

**Enhancements**
* **[Android Platform]**
* Optimized delay in the heads-up behavior of the call notification when the user exits from the call screen.
* Added fallback to the regular notification template for call notifications when using the CallStyle template, in case the full-screen intent permission is not granted.
* Prevented the call notification popup when the SDK requests microphone permissions after the call is accepted.
* Local branding configured during SDK initialization is now interoperable with the remote branding configured via the CleverTap dashboard, allows to override the specific branding properties without requiring all properties to be set at once.

### Version 0.5.5 (June 24, 2024)

---
Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,12 @@ To get started, sign up [here](https://clevertap.com/live-product-demo/).
- To add the **CleverTap Signed Call React Native SDK** to your project, run below command on terminal:

```text
npm install @clevertap/clevertap-signed-call-react-native
npm install @clevertap/clevertap-signed-call-react-native // for P2P feature
```
or,

```text
npm install @clevertap/[email protected] // for M2P feature
```

- Now, in your TypeScript or JavaScript code, you can use:
Expand Down
4 changes: 2 additions & 2 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
//Required dependencies for Signed Call Android SDK
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
compileOnly "com.clevertap.android:clevertap-android-sdk:6.2.0"
compileOnly "com.clevertap.android:clevertap-signedcall-sdk:0.0.5.5"
compileOnly "com.clevertap.android:clevertap-android-sdk:6.2.1"
compileOnly "com.clevertap.android:clevertap-signedcall-sdk:0.0.7.6"
compileOnly 'androidx.work:work-runtime:2.7.1'
compileOnly('io.socket:socket.io-client:2.1.0') {
exclude group: 'org.json', module: 'json'
Expand Down
4 changes: 2 additions & 2 deletions android/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ClevertapSignedCallReactNative_kotlinVersion=1.7.0
ClevertapSignedCallReactNative_minSdkVersion=21
ClevertapSignedCallReactNative_targetSdkVersion=33
ClevertapSignedCallReactNative_compileSdkVersion=33
ClevertapSignedCallReactNative_targetSdkVersion=34
ClevertapSignedCallReactNative_compileSdkVersion=34
ClevertapSignedCallReactNative_ndkversion=21.4.7075529
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,18 @@ import com.clevertap.rnsignedcallandroid.internal.util.PayloadConverter.toSigned
import com.clevertap.rnsignedcallandroid.internal.util.PayloadConverter.toWriteableMap
import com.clevertap.rnsignedcallandroid.internal.util.Utils.log
import com.clevertap.rnsignedcallandroid.internal.util.toJson
import com.facebook.react.bridge.*
import com.facebook.react.bridge.Promise
import com.facebook.react.bridge.ReactApplicationContext
import com.facebook.react.bridge.ReactContext
import com.facebook.react.bridge.ReactContextBaseJavaModule
import com.facebook.react.bridge.ReactMethod
import com.facebook.react.bridge.ReadableMap

class CleverTapSignedCallModule(private val reactContext: ReactApplicationContext) :
ReactContextBaseJavaModule(reactContext) {
private var mSignedCall: SignedCallAPI? = null
private var cleverTapAPI: CleverTapAPI? = null
private lateinit var outgoingCallResponse: OutgoingCallResponse

init {
cleverTapAPI = CleverTapAPI.getDefaultInstance(reactContext)
Expand Down Expand Up @@ -75,6 +81,11 @@ class CleverTapSignedCallModule(private val reactContext: ReactApplicationContex
log(message = "SignedCallOnCallStatusListener is invoked in foreground or background: $data")
EventEmitter.emit(context, ON_CALL_STATUS_CHANGED, data.toWriteableMap())
}

SignedCallAPI.getInstance().setMissedCallNotificationOpenedHandler { _, data ->
log(message = "MissedCallNotificationOpenedHandler is invoked in foreground or background: $data")
EventEmitter.emit(context, ON_MISSED_CALL_ACTION_CLICKED, data.toWriteableMap())
}
}
}

Expand All @@ -100,7 +111,7 @@ class CleverTapSignedCallModule(private val reactContext: ReactApplicationContex
val signedCallAPI: SignedCallAPI = getSignedCallAPI()
initProperties?.let {
try {
val initConfiguration: SignedCallInitConfiguration? = getInitConfigFromReadableMap(it)
val initConfiguration: SignedCallInitConfiguration? = getInitConfigFromReadableMap(it, reactContext.applicationContext)
signedCallAPI.init(
reactContext.applicationContext,
initConfiguration,
Expand Down Expand Up @@ -134,20 +145,23 @@ class CleverTapSignedCallModule(private val reactContext: ReactApplicationContex
val signedCallAPI: SignedCallAPI = getSignedCallAPI()
try {
val callOptions = callProperties?.toJson()

outgoingCallResponse = object: OutgoingCallResponse {
override fun onSuccess() {
promise.resolve(signedCallResponseToWritableMap(exception = null))
}

override fun onFailure(callException: CallException?) {
promise.resolve(signedCallResponseToWritableMap(callException))
}
}

signedCallAPI.call(
reactContext,
receiverCuid,
callContext,
callOptions,
object : OutgoingCallResponse {
override fun onSuccess() {
promise.resolve(signedCallResponseToWritableMap(exception = null))
}

override fun onFailure(callException: CallException?) {
promise.resolve(signedCallResponseToWritableMap(callException))
}
}
outgoingCallResponse
)
} catch (throwable: Throwable) {
val errorMessage = "Exception while initiating the VoIP Call"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ open class SignedCallOnCallStatusListener {
log(message = "SignedCallOnCallStatusListener is invoked in killed state: $data")
EventEmitter.emit(context, Events.ON_CALL_STATUS_CHANGED, data.toWriteableMap())
}

SignedCallAPI.getInstance().setMissedCallNotificationOpenedHandler { _, data ->
log(message = "MissedCallNotificationOpenedHandler is invoked in killed state: $data")
EventEmitter.emit(context, Events.ON_MISSED_CALL_ACTION_CLICKED, data.toWriteableMap())
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import com.clevertap.rnsignedcallandroid.internal.util.Utils
/**
* Missed Call CTA handler for SignedCall Missed Call Notifications
*/
internal class MissedCallActionClickHandler : MissedCallNotificationOpenedHandler {
internal open class MissedCallActionClickHandler : MissedCallNotificationOpenedHandler {

/**
* Gets called from the SC SDK when the user taps on the missed call CTA
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,31 @@ object Constants {
"promptReceiverReadPhoneStatePermission"
const val KEY_NOTIFICATION_PERMISSION_REQUIRED =
"notificationPermissionRequired"
const val KEY_CALL_SCREEN_ON_SIGNALLING =
"callScreenOnSignalling"
const val KEY_SWIPE_OFF_BEHAVIOUR_IN_FOREGROUND_SERVICE =
"swipeOffBehaviourInForegroundService"
const val KEY_FCM_PROCESSING_MODE =
"fcmProcessingMode"
const val KEY_FCM_NOTIFICATION = "fcmProcessingNotification"
const val KEY_FCM_NOTIFICATION_TITLE = "title"
const val KEY_FCM_NOTIFICATION_SUBTITLE = "subtitle"
const val KEY_FCM_NOTIFICATION_LARGE_ICON = "largeIcon"
const val KEY_FCM_NOTIFICATION_CANCEL_CTA_LABEL = "cancelCtaLabel"
const val KEY_OVERRIDE_DEFAULT_BRANDING = "overrideDefaultBranding"
const val KEY_MISSED_CALL_ACTIONS = "missedCallActions"
const val KEY_BG_COLOR = "bgColor"
const val KEY_FONT_COLOR = "fontColor"
const val KEY_LOGO_URL = "logoUrl"
const val KEY_BUTTON_THEME = "buttonTheme"
const val KEY_CANCEL_COUNTDOWN_COLOR = "cancelCountdownColor"
const val KEY_SHOW_POWERED_BY_SIGNED_CALL = "showPoweredBySignedCall"
const val KEY_RECEIVER_CUID = "receiverCuid"
const val KEY_CALL_CONTEXT = "callContext"
const val KEY_CHANNEL = "channel"
const val KEY_INITIATOR_IMAGE = "initiatorImage"
const val KEY_RECEIVER_IMAGE = "receiverImage"
const val KEY_REMOTE_CONTEXT = "remoteContext"
const val KEY_ERROR_CODE = "errorCode"
const val KEY_ERROR_MESSAGE = "errorMessage"
const val KEY_ERROR_DESCRIPTION = "errorDescription"
Expand Down
Loading
Loading