Obtain EUID

最新更新:2025-03-18

EUID is the unique user ID of the EngageLab MA platform. You can use the following API to obtain the EUID based on the user identifier.

Invocation Address

POST /v1/user/register

Invocation Verification

The EngageLab REST API uses the verification method of HTTP Basic Authentication: Add Authorization to the HTTP Header:

Authorization: Basic ${base64_auth_string}
          Authorization: Basic ${base64_auth_string}

        
このコードブロックはフローティングウィンドウ内に表示されます

The generation algorithm for the above base64_auth_string is: base64(api_key:api_secret)

  • The header name is "Authorization", and the value is the base64-converted "username:password" pair (with a colon in the middle).
  • In the scenario of the MA API, the username is the APIKey, and the password is the APISecret. Please add a data source of the API type in the data source to obtain the APIKey and API Secret.

Request Example

Request Header

> POST /v1/user/register > Content-Type: application/json > Authorization: Basic N2Q0MzFlNDJkZmE2YTZkNjkzYWMyZDA0OjVlOTg3YWM2ZDJlMDRkOTVhOWQ4ZjBkMQ==
          > POST /v1/user/register
> Content-Type: application/json
> Authorization: Basic N2Q0MzFlNDJkZmE2YTZkNjkzYWMyZDA0OjVlOTg3YWM2ZDJlMDRkOTVhOWQ4ZjBkMQ==

        
このコードブロックはフローティングウィンドウ内に表示されます

Request Body

{ "identity_name":"user_id", // User identifier name "identity_values": [ "18012345678", // User identifier value "18012345678" ] }
          {
    "identity_name":"user_id", // User identifier name
    "identity_values": [
        "18012345678",    // User identifier value
        "18012345678"
        ]
}

        
このコードブロックはフローティングウィンドウ内に表示されます

Request Parameters

Field Type Required Description
identity_name String Yes User identifier name, supports passing values such as user_id, anonymous_id, registration_id
identity_values list Yes Values of user identifiers, supporting up to 100 values, and each value cannot exceed 256 characters

Return Parameters

Field Type Required Description
code Int Yes Indicates whether the interface call is successful. 0 means successful or partially successful, and other values represent failure
message String Yes Description of the interface call result, an explanation of the return code
data Array No A list of EUIDs corresponding to the user identifiers returned
identity_value String Yes The value of the user identifier
euid Long Yes The corresponding unique user ID of EngageLab MA
error_code Int Yes Indicates whether the EUID is successfully obtained. 0 represents success, and other values represent failure

All Successful

{ "code": 0, "message": "success", "data": [ { "identity_value": "18012345678", // User identifier value "euid": 10362473, // Generated EUID, null if the acquisition fails "error_code": 0 // Corresponding error code, 0 for success, and not empty for failure, such as 40006 }, { "identity_value": "18012340000", "euid": 10362474, "error_code": 0 } ] }
          {
    "code": 0,
    "message": "success",
    "data": [
        {
            "identity_value": "18012345678",   // User identifier value
            "euid": 10362473, // Generated EUID, null if the acquisition fails
            "error_code": 0   // Corresponding error code, 0 for success, and not empty for failure, such as 40006
        },
        {
            "identity_value": "18012340000",
            "euid": 10362474,
            "error_code": 0
        }
    ]
}

        
このコードブロックはフローティングウィンドウ内に表示されます

All Failed

{ "code": 55101, "message": "Exceeded the limit of user identifiers" }
          {
    "code": 55101,
    "message": "Exceeded the limit of user identifiers"
}

        
このコードブロックはフローティングウィンドウ内に表示されます

Partially Successful

{ "code": 0, "message": "success", "data": [ { "identity_value": "18012345678", // User identifier value "euid": null, // null for failure "error_code": -1 // Corresponding error code, 0 for success, and not empty for failure }, { "identity_value": "1801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400008012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000", "euid": null, "error_code": 55105 } ] }
          {
    "code": 0,
    "message": "success",
    "data": [
        {
            "identity_value": "18012345678",   // User identifier value
            "euid": null, // null for failure
            "error_code": -1     // Corresponding error code, 0 for success, and not empty for failure
        },
        {
            "identity_value": "1801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400008012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000180123400001801234000018012340000",
            "euid": null,
            "error_code": 55105
        }
    ]
}

        
このコードブロックはフローティングウィンドウ内に表示されます

Error Code

|Code| Description| Detailed Explanation | | ----- | -------- | ----------------------- | -------------------------- | | 40050 | Interface authentication failed.| Confirm whether the project ID and project secret key are correct. | | 40007 | EUID is empty.|Please check the value of EUID.| | 50031 | Project ID is invalid.|Please check whether the APIKey and APISecret are correct.| | 50034 | Project ID does not exist.|Please check whether the APIKey and APISecret are correct, and check whether the project has been deleted.| | 50074 | API data source does not exist.|Please check whether the APIKey and APISecret are correct, and check whether the API data source has been deleted.| | 55004 | Business parameters are invalid.|Please check whether the fields of the request parameters are correct.| | 55101 | The number of user identifiers exceeds the limit.|Confirm whether the number of values of the user identification exceeds 100.| | 55102 | There are invalid user attribute names.|Confirm whether the attribute name meets the naming requirements, and whether it is empty/uses reserved characters/exceeds the length limit.| | 55103 | User attribute values cannot be empty.|Confirm whether the value of the user attribute in the request body is empty.| | 55105 | The value of the user identifier cannot exceed 256 characters.|Confirm whether the value of the user identification exceeds 256 characters.| | 55106 | The name of the user identifier is not within the supported range.|Confirm whether the name of the user identification is user_id, anonymous_id, or registration_id.| | 55107 | The value of the user identifier is empty.|Confirm whether the value of the user identification in the request body is empty.| | 55108 | Invalid EUID.|Please check the value of EUID.| | -1 | Internal server error.|Please contact EngageLab technical support.|

在文档中心打开
icon
お問い合わせ