post https://api.imiconnect.io/resources/v2/customerappprofile/<appid>
This API is used to create customer's application profile.
Request
The create app profile request is specified as follows:
URI | https://api.imiconnect.io/resources/v2/customerappprofile/*appid**: Specifies the application id. |
Method | POST |
Request Headers
The following table describes the request headers:
Request Header | Description |
---|---|
key | Client profile key |
content-type | application/json |
##Request Examples
{
"Records": [{
"customerId": "8955",
"Attributes": {
"status": "1",
"verified": "1",
"psid": "1652750724851329",
"createdOn": "2018-08-26 12:26:03",
"customerId": "1842"
"name": "Ravipudi Durgaprasad",
"profile_pic": "https://platform-lookaside.fbsbx.com/platform/profilepic/? psid=1652750724851329&width=1024&ext=1537878362&hash=AeQ6XJBhDeMC7RUN",
"gender": "male",
"locale": "en_US",
"timezone": "5.5",
"channel": "fb",
"updatedOn": "2018-09-19 07:13:50"
}
},
{
"customerId": "8956",
"Attributes": {
"status": "1",
"verified": "1",
"psid": "1652750724851134",
"createdOn": "2018-08-26 12:26:03",
"customerId": "1845"
"name": "Anil Dhar",
"profile_pic": "https://platform-lookaside.fbsbx.com/platform/profilepic/? psid=1652750724851329&width=1024&ext=1537878362&hash=AeQ6XJBhDeMC7RUN",
"gender": "male",
"locale": "en_US",
"timezone": "5.5",
"channel": "fb",
"updatedOn": "2018-09-25 07:14:35" }
}]
}
{
"Records": [{
"customerId": "8957",
"Attributes": {
"status": "1",
"verified": "1",
"twitterid": "3424284794",
"twitter_handle": "BalajiSatuluri",
"twitter_name": "Balaji Satuluri",
"customerId": "3330",
"geolocation": "",
"timezone": "",
"channel": "twitter",
"createdOn": "2016-10-14 05:27:50",
"updatedOn": "2018-09-19 07:07:29"
}
}]
{
"Records": [{
"customerId": "9876",
"Attributes": {
"created_on": ISODate('2018-04-02T07:09:30.395Z'),
"updated_on": ISODate('2018-04-02T07:25:22.660Z'),
"customerId": "8953",
"city": "",
"verified": "2018-04-02T07:25:22.660Z",
"createdOn": "2018-04-02T06:09:30.611Z",
"nick": "cogniti",
"status": "1",
"gender": "Female",
"province": "",
"language": "en",
"country": "India"
}
},
{
"customerId": "9877",
"Attributes": {
"created_on": ISODate('2018-04-02T07:10:30.395Z'),
"updated_on": ISODate('2018-04-02T08:26:22.660Z'),
"customerId": "8954",
"city": "",
"verified": "2018-05-02T07:25:23.660Z",
"createdOn": "2018-05-02T06:09:30.611Z",
"nick": "cogniti",
"status": "1",
"gender": "Female",
"province": "",
"language": "en",
"country": "India"
}
}
]
}
{
"Records": [{
"customerId": "9879",
"Attributes": {
"status": "",
"verified": "0",
"customerId": "0774943838490264760"
"connectStatus": "1",
"appId": "",
"userId": "30774943838490264760",
"password": "",
"deviceId": "HT59TBE00192",
"batterylevel": "",
"Bluetooth": "",
"cellid": "",
"connectType": "",
"email": "",
"externalmemory": "",
"foreground": "",
"foregroundapp": "",
"idlescreen": "",
"imei": "",
"imsi": "",
"internalmemory": "",
"IP": "",
"language": "",
"oldlocation": "[]",
"location": "",
"MAC": "",
"make": "HTC",
"MCC": "",
"MNC": "",
"model": "HTC One A9",
"NFC": "",
"os": "Android",
"osversion": "6.0.1",
"phonemode": "",
"presence": "",
"RAM": "",
"resolution": "",
"roaming": "",
"serialnumber": "",
"signalstrength": "",
"teleco": "",
"timespent": "",
"timezone": "",
"useragent": "",
"pushId": "fwYj0eb9jmM:APA91bF3hHgNR51OgRJ64dC2bmHa3Hh6BWHjSnDCv4ZFfvSgEiCx0p6bqeB0Ij9DdAy41t275Hhd02TC6BufvakJimEuGw_68nyUA9JWZXGylmfSkcC_2RSsys3yR6HLvZgu8esif_jd",
"rtmId": "30774943838490264760_HT59TBE00192",
"createdOn": "2018-09-11 15:37:28",
"last_opened": "2018-09-12T10:24:59.907Z",
"last_upgraded": "2018-09-11T15:37:29.067Z",
"channel": "rt",
"accounts": "",
"sdkversion": "",
}
}]
}
{
"Records": [{
"customerId": "9879",
"Attributes": {
"status": "",
"verified": "0",
"customerId": "0774943838490264760"
"connectStatus": "1",
"appId": "",
"userId": "30774943838490264760",
"password": "",
"deviceId": "HT59TBE00192",
"batterylevel": "",
"Bluetooth": "",
"cellid": "",
"connectType": "",
"email": "",
"externalmemory": "",
"foreground": "",
"foregroundapp": "",
"idlescreen": "",
"imei": "",
"imsi": "",
"internalmemory": "",
"IP": "",
"language": "",
"oldlocation": "[]",
"location": "",
"MAC": "",
"make": "HTC",
"MCC": "",
"MNC": "",
"model": "HTC One A9",
"NFC": "",
"os": "Android",
"osversion": "6.0.1",
"phonemode": "",
"presence": "",
"RAM": "",
"resolution": "",
"roaming": "",
"serialnumber": "",
"signalstrength": "",
"teleco": "",
"timespent": "",
"timezone": "",
"useragent": "",
"pushId": "fwYj0eb9jmM:APA91bF3hHgNR51OgRJ64dC2bmHa3Hh6BWHjSnDCv4ZFfvSgEiCx0p6bqeB0Ij9DdAy41t275Hhd02TC6BufvakJimEuGw_68nyUA9JWZXGylmfSkcC_2RSsys3yR6HLvZgu8esif_jd",
"rtmId": "30774943838490264760_HT59TBE00192",
"createdOn": "2018-09-11 15:37:28",
"last_opened": "2018-09-12T10:24:59.907Z",
"last_upgraded": "2018-09-11T15:37:29.067Z",
"channel": "rt",
"accounts": "",
"sdkversion": "",
}
}]
}
Request Body
The following table describes the elements in the request body:
Parameter | Type | Mandatory | Description |
---|---|---|---|
customerid | String | Yes | Customer ID is a Client specific ID (such as CRN) to uniquely identify a customer. |
attributes | JSONObject | Yes | Key value pairs to add. Facebook:
Twitter:
WeChat:
In-App:
Push:
|
Profile details are encapsulated within the Attributes section. Additional key value pairs may be added as required.
##Response Examples
{
"response": {
"code": "1001",
"description": "Queued",
"transid": "5457ee77-53c8-12ac-8a58-ee6e062cae8a"
}
}
{
"response": {
"code": "1001",
"description": "Queued",
"transid": "5457ee77-43c8-42ac-8a58-ee6e062cae8a"
}
}
{
"response": {
"code": "1001",
"description": "Queued",
"transid": "5487ff77-53c8-42ac-8a58-ee6e062cae8a"
}
}
{
"response": {
"code": "1001",
"description": "Queued",
"transid": "5247ee77-63c8-42ac-8a58-ee6e062cae8a"
}
}
To know the status of the request
Use transid from the response and make a Get Profile status API call to get status of the request.
Status Codes
This API may return the following response codes:
Response Code | Message | Description |
---|---|---|
1000 | Queued | Returned when the request is queued. |
1002 | Partial success | Returned when at least one app profile could not be created successfully. |
7000 | Invalid JSON | Returned when an invalid JSON request is sent. |
7001 | Authentication failed | Returned when the invalid service key or profile key is provided in the request. |
7002 | Service Key Missing | Returned when the parameter key is missing in the message request. |
7003 | Mandatory parameters missing | Click here |
7006 | Internal error occurred | Returned when an internal error occurs. |
7010 | Source IP is not white listed | Returned when a request is sent from an IP that is not whitelisted in IMIconnect. |
7011 | Invalid Attribute Value | Returned when an invalid value is provided for the customer or app profile Attributes object. |
7018 | invalid app profile or app profile is not linked to this client | Returned when an application master profile does not exists. |