Skip to main content

SendEmailByOpenID

Send transactional emails according to OpenID. Ensure that the imported template has been created in SmartLink > Content > Email templates > Transactional.

POST /api/v3/transactional_email/send_email_by_openid

note

The default daily limit for transactional emails sent by a project is 1.5 million, with a QPS (Queries Per Second) of 200. This API requires an exclusive API Key, and cannot use the existing API Key on the system. Before using this API, or to increase the daily limit, reach out to the SmartLink representative or contact SmartLink_service@proximabeta.com 3 working days in advance.

Request Parameters

For more information about query parameters, see Query Parameters.

AttributeData TypeNoteDescription
openidstringrequiredUnique user ID (up to 20 numeric characters)
template_codestringrequiredTemplate ID
A transactional email template will have to be created first
variablesobjectoptionalVariable value replacement, used to replace the variables within {{}} in the template.
  • Up to 100 variable can be replaced.
  • Variables must match variables in the template.
  • Format description:
    • object: formatted as { "key":"value" }, where key is the variable name, value is the content to replace
    • value: string type, cannot exceed 1000 characters

Request example

curl --request POST "https://openapi.smartlink.intlgame.com/api/v3/transactional_email/send_email_by_openid?gameid=${GAME_ID}&seq=${YOUR_RANDOM_STRING}&sig=${SIGNATURE}&ts=${TS}" \
--header 'Content-Type: application/json' \
--data-raw '{
"openid": "1012156612344364",
"template_code": "TR123456",
"variables": {
"code": "t1234",
"code1": "t12345"
}
}'

Response parameters

AttributeData typeDescription
codeintReturn code
msgstringReturn message
datadataResponse message

data

AttributeData typeDescription
transaction_uuidstringUnique request ID, used to query mail delivery status

Response example

{
"code": 0,
"msg": "Success",
"data": {
"transaction_uuid": "6bc92519-5777-43a1-b5bb-6a6a7e24b25b"
},
"seq": "{YOUR_RANDOM_STRING}"
}