curl --request PATCH \
--url https://api.enterprise.sandbox.uphold.com/core/kyc/processes/crypto-risk-assessment \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"answers": {
"financial-information": {
"annual-income-range": "20000-30000"
}
}
}
}
'{
"cryptoRiskAssessment": {
"status": "pending",
"input": {
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"answers": {
"financial-information": {
"annual-income-range": "20000-30000"
}
}
},
"hint": {
"type": "form",
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"schema": {
"type": "object",
"properties": {
"financial-information": {
"type": "object",
"title": "Level of income",
"description": "Please select your income level.",
"properties": {
"annual-income-range": {
"type": "string",
"oneOf": [
{
"const": "0-20000",
"title": "< $ 20,000"
},
{
"const": "20000-30000",
"title": "$ 20,000 - $ 30,000"
},
{
"const": "30000-40000",
"title": "$ 30,000 - $ 40,000"
},
{
"const": "40000-60000",
"title": "$ 40,000 - $ 60,000"
},
{
"const": "60000-80000",
"title": "$ 60,000 - $ 80,000"
},
{
"const": "80000-130000",
"title": "$ 80,000 - $ 130,000"
},
{
"const": "130000-210000",
"title": "$ 130,000 - $ 210,000"
},
{
"const": "210000-or-more",
"title": "$ 210,000 or more"
}
]
}
},
"required": [
"annual-income-range"
]
},
"attitude-towards-risk": {
"type": "object",
"title": "Attitude to risk",
"description": "I am okay with the risk of my crypto investments having significant value fluctuations.",
"properties": {
"willingness-to-fluctuations": {
"type": "string",
"oneOf": [
{
"const": "strongly_agree",
"title": "Strongly agree"
},
{
"const": "agree",
"title": "Agree"
},
{
"const": "neither_agree_or_disagree",
"title": "Neither agree nor disagree"
},
{
"const": "disagree",
"title": "Disagree"
},
{
"const": "strongly_disagree",
"title": "Strongly disagree"
}
]
}
},
"required": [
"willingness-to-fluctuations"
]
}
}
},
"uiSchema": {
"type": "Categorization",
"elements": [
{
"type": "Category",
"label": "Level of income",
"elements": [
{
"type": "Control",
"scope": "#/properties/financial-information/properties/annual-income-range"
}
]
},
{
"type": "Category",
"label": "Attitude to risk",
"elements": [
{
"type": "Control",
"scope": "#/properties/attitude-towards-risk/properties/willingness-to-fluctuations"
}
]
}
]
}
}
}
}Update the crypto risk assessment process for a user.
curl --request PATCH \
--url https://api.enterprise.sandbox.uphold.com/core/kyc/processes/crypto-risk-assessment \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"input": {
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"answers": {
"financial-information": {
"annual-income-range": "20000-30000"
}
}
}
}
'{
"cryptoRiskAssessment": {
"status": "pending",
"input": {
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"answers": {
"financial-information": {
"annual-income-range": "20000-30000"
}
}
},
"hint": {
"type": "form",
"formId": "7a0f4229-e3de-4dfd-8f91-9b1308b2dc33",
"schema": {
"type": "object",
"properties": {
"financial-information": {
"type": "object",
"title": "Level of income",
"description": "Please select your income level.",
"properties": {
"annual-income-range": {
"type": "string",
"oneOf": [
{
"const": "0-20000",
"title": "< $ 20,000"
},
{
"const": "20000-30000",
"title": "$ 20,000 - $ 30,000"
},
{
"const": "30000-40000",
"title": "$ 30,000 - $ 40,000"
},
{
"const": "40000-60000",
"title": "$ 40,000 - $ 60,000"
},
{
"const": "60000-80000",
"title": "$ 60,000 - $ 80,000"
},
{
"const": "80000-130000",
"title": "$ 80,000 - $ 130,000"
},
{
"const": "130000-210000",
"title": "$ 130,000 - $ 210,000"
},
{
"const": "210000-or-more",
"title": "$ 210,000 or more"
}
]
}
},
"required": [
"annual-income-range"
]
},
"attitude-towards-risk": {
"type": "object",
"title": "Attitude to risk",
"description": "I am okay with the risk of my crypto investments having significant value fluctuations.",
"properties": {
"willingness-to-fluctuations": {
"type": "string",
"oneOf": [
{
"const": "strongly_agree",
"title": "Strongly agree"
},
{
"const": "agree",
"title": "Agree"
},
{
"const": "neither_agree_or_disagree",
"title": "Neither agree nor disagree"
},
{
"const": "disagree",
"title": "Disagree"
},
{
"const": "strongly_disagree",
"title": "Strongly disagree"
}
]
}
},
"required": [
"willingness-to-fluctuations"
]
}
}
},
"uiSchema": {
"type": "Categorization",
"elements": [
{
"type": "Category",
"label": "Level of income",
"elements": [
{
"type": "Control",
"scope": "#/properties/financial-information/properties/annual-income-range"
}
]
},
{
"type": "Category",
"label": "Attitude to risk",
"elements": [
{
"type": "Control",
"scope": "#/properties/attitude-towards-risk/properties/willingness-to-fluctuations"
}
]
}
]
}
}
}
}GET /core/kyc?detailed=cryptoRiskAssessment, you will get a hint property which includes a JSON form schema and UI schema.
The hint property will also be available in responses of this endpoint, in case there are still questions to be answered.
For more information about forms, refer to the form-based processes section.OAuth 2.0 authentication.
The natural language and locale that the client prefers.
Input of the KYC process.
Show child attributes
The answers property follows the JSON Forms specification for data objects and has two key behaviors:
The KYC process starts its evaluation once the last question has been answered, ensuring that all necessary information has been provided before proceeding with the assessment.
The form identifier returned in the formId property of the KYC process hint. Include this value when you need to persist or resume the current form state over an extended period (for example, across user sessions or long-running saves).
Output of the KYC process.
Show child attributes
The result of the verification.
approved, rejected The date and time of the verification.
KYC crypto risk assessment process updated.
Show child attributes
Status of the KYC process.
ok, failed, running, pending, exempt Output of the KYC process.
Show child attributes
The result of the verification.
approved, rejected The attempts state of the verification.
Show child attributes
The date and time of the verification.
Hints for the KYC process.
Show child attributes
The type of the hint.
form The definition of the structure and validation rules for this KYC process form.
It follows the JSON Schema specification with the power of JSON Forms.
The schema is iterative, meaning that new questions and properties can be added dynamically as the KYC process evolves. This allows for a flexible and adaptive form structure that can accommodate changes and new requirements over time.
The uiSchema property defines the general layout and presentation of the form by means of different UI schema elements.
It follows the JSON Forms specification and is used to customize the appearance and behavior of the form fields.
The uiSchema includes the following elements:
Layouts: Used to structure the form layout. It includes properties like type to define the layout type (e.g., Categorization) and elements to define the child elements.Controls: Used to define the form controls. It includes properties like scope to point to the corresponding schema property and label to define the control's label.Rules: Used to define conditional visibility rules for form controls. It includes properties like effect to define the rule effect (e.g., SHOW) and condition to define the rule condition.The uiSchema is iterative, meaning that new controls and layout elements can be added dynamically as the KYC process evolves. This allows for a flexible and dynamic form layout, enhancing the user experience by providing a structured and intuitive form design that can adapt to new requirements and changes over time.
The id of the form.