The “Notify Contact Information” event will be used when we need to modify the contact's information. For this, via Mobile SDK, we will use the method sendContactInfo(contactInfo: ContactInfo).
How it works
In the contact information submission, we will use the ContactInfo class and its properties to notify changes in the user's information with sendContactInfo(contactInfo: ContactInfo).
Attribute | Definition | Required | Type | Limitations |
---|---|---|---|---|
contactInfo |
Additional user information |
Yes | ContactInfo |
ContactInfo Structure
Attribute | Definition | Required | Type | Limitations |
---|---|---|---|---|
name |
Name |
No | String | |
surname |
Surname |
No | String | |
birthdate |
Birthdate |
No | Date | |
mobilePhone |
Mobile phone |
No | String | Must include a valid country prefix (e.g.: +34) |
This type of event automatically collects the following information:
- Operating system: Android or iOS.
- App version.
- Operating system version.
- Connectif SDK version.
Example
The notification will look like this:
Connectif.sendContactInfo(ContactInfo( name: "John", surname: "Doe", birthdate: Date(), mobilePhone: "+34675675679"))
Callbacks (Opcional)
Si queremos tener feedback de posibles errores al enviar eventos, podremos añadir un EventCallbacks cuando usemos nuestro método.
EventCallbacks( onSuccess: { // Manejo en caso de éxito }, onError: { error in // Manejo en caso de error })
Keep Learning!
To fully unlock the potential of your Connectif account, we recommend continuing with the following articles:
- Android SDK Get Started, to add Connectif Mobile SDK to your Android project.
- Firebase Cloud Messaging Setup, to enable push sending and receiving via the Android Mobile SDK.
- iOS SDK Get Started, to add Connectif Mobile SDK to your iOS project.
- Apple Push Notifications Service Setup, to enable push sending and receiving via the iOS Mobile SDK.