Data SDK
Check the user's consent status for consent-based user data items registered in the mini app. If the user has agreed to the latest consent terms, the actual data value is returned; if they have not yet agreed or have refused consent, a URL that can take them to the consent screen is returned instead of the data.
Business error code
The errors below respond with HTTP 200 and resultType: FAIL.
4010
Authentication information could not be found.
This is client-certificate-based mTLS authentication issued to the partner. The mini app is identified by the certificate's CN. Refer to the Use the server API document for how to issue and manage certificates.
It's a key for authenticating users. It can be obtained through the Get user information API
12345678This is the request body for consent-based user data lookup.
This is the key that identifies the consent-based user data item to look up. It is issued when the consent-based user data item is registered in the partner workspace console.
cud_1234567890abcdef1234567890abcdefThis is the result of request processing. Use the value of resultType to distinguish between success and failure.
The request body is not in the correct format. Check the field-by-field details in error.data.errorDetails.
This is an unclassified server error. If it keeps failing, please contact the partner support channel.
POST /api-partner/v1/apps-in-toss/data-sdk/get-consented-user-data HTTP/1.1
Host: apps-in-toss-api.toss.im
x-toss-user-key: {userKey}
Content-Type: application/json
{
"consentedUserDataKey": "cud_1234567890abcdef1234567890abcdef"
}{
"resultType": "SUCCESS",
"success": {
"type": "PROVIDED",
"data": {
"ANY_ADDITIONAL_PROPERTY": "text"
}
}
}Was this helpful?