identifierKey: "string" // optional -- if defined, we must require a value
identifierValue: "string" // optional -- if defined, we must require a value
table: "string" // optional
"/api/entity" is Lytics.configuration.dataEndpoint
"/user" is either Lytics.configuration.defaultTable or the table parameter
"/email" is either Lytics.configuration.primaryIdentityKey or the identifier parameter
"/aaron@aaron.com" is the value of Lytics.currentUser.identifiers[email]
example response from API
{
// save this field to the user model
"data": {
"segments": [
"email_us_based",
"web_users",
"all"
]
},
"message": "success",
// ignore this field for now
"meta": {
"by_fields": [
"user_id",
"email",
"fbuid",
"_uids"
],
"format": "json",
"name": "user"
},
"status": 200
}
Add method Lytics.getProfile()
https://github.com/lytics/android-sdk/blob/main/lytics-sdk/src/main/java/com/lytics/android/LyticsUser.kt
This method should take the following parameters:
Default
When this method is called, it should send a request to the API (see reference below) and return the data received back from the API
API Reference: https://learn.lytics.com/documentation/developer/api-docs/personalization#personalization-personalization-get
example request to API
GET /api/entity/user/email/aaron@aaron.com where
"/api/entity" is Lytics.configuration.dataEndpoint "/user" is either Lytics.configuration.defaultTable or the table parameter "/email" is either Lytics.configuration.primaryIdentityKey or the identifier parameter "/aaron@aaron.com" is the value of Lytics.currentUser.identifiers[email]
example response from API