Login

Update time: 2023/09/25 01:40:18

Callback - log in

  • Example - request of login callback

    32.1. HTTP example

    32.2. cURL example

    32.3. JSON field in message body

32.1 HTTP example:

httpPOST /receiveMsg.action HTTP/1.1
Host: yunxinservice.com.cn
AppKey: 158983881e092b052194d219453d6542
CurTime: 1541583920979
MD5: e89c284a5ad9a76b3176e23108920f81
CheckSum: 6f08c5ee2dd16a5fc34a12005e5d5f1411e657a1
Content-Type: application/json
Cache-Control: no-cache

{"eventType":35,"fromAccount":"wm1","fromClientIp":"36.18.111.225","fromClientPort":"39632","fromClientType":"AOS","fromDeviceId":"ef6b789c-3079-463b-a52b-4924ae539e01","msgFromAccid":"wm1","msgId":184409700039655569,"msgidClient":"b897b26234d246858031291f12bc498d","opeType":8,"time":1590482455336,"timestamp":"1590482457381","toAccount":"2747918666"}

32.2 cURL example:

curlcurl -X POST \
  http://yunxinservice.com.cn/receiveMsg.action \
  -H 'appkey: 158983881e092b052194d219453d6542' \
  -H 'cache-control: no-cache' \
  -H 'checksum: 6f08c5ee2dd16a5fc34a12005e5d5f1411e657a1' \
  -H 'content-type: application/json' \
  -H 'curtime: 1541583920979' \
  -H 'md5: e89c284a5ad9a76b3176e23108920f81' \
  -d '{"eventType":35,"fromAccount":"wm1","fromClientIp":"36.18.111.225","fromClientPort":"39632","fromClientType":"AOS","fromDeviceId":"ef6b789c-3079-463b-a52b-4924ae539e01","msgFromAccid":"wm1","msgId":184409700039655569,"msgidClient":"b897b26234d246858031291f12bc498d","opeType":8,"time":1590482455336,"timestamp":"1590482457381","toAccount":"2747918666"}'

32.3 JSON field in message body:

javaNot every field in the callback message will necessarily be copied. Please pay attention to the nulling of each field.
NameTypeRequiredDescription
eventTypeIntegerYesValue is 36, which indicates login callback
fromAccountStringYesOperator account
fromDeviceIdStringYesOperator device id
fromClientTypeStringYesOperator client type: AOS、IOS、PC、WINPHONE、WEB、REST
fromClientIpStringNoOperator's client IP address
fromClientPortStringNoOperator's client port number
tokenStringYesLogin token
authTypeIntegerYesLogin authentication mode, 0 indicates classic mode, 1 indicates dynamic token mode, 2 indicates verification based on third-party callbacks (in this mode, CommsEase will not verify tokens)
loginExtStringYesLogin extension field
customTagStringYesLogin custom tag
customClientTypeStringYesCustom client type
autoLoginIntegerNoWhether the login is automatic
timestampStringYesOperation time, string type
Was this page helpful?
Yes
No
  • Callback - log in
  • 32.1 HTTP example:
  • 32.2 cURL example:
  • 32.3 JSON field in message body: