Consent Data Categories API

Introduction

Consent Data Categories define the specific types of personal data or personally identifiable information(PII) for which consent is being collected from the Data Principal. They help clearly identify the scope of data processing authorized by the user, ensuring transparency, purpose limitation, and regulatory compliance under the Digital Personal Data Protection Act (DPDPA), 2023. Examples may include identity information, contact details, financial data, employment records, educational information, location data, or verification documents depending on the business use case and processing purpose.

Refer to Consent Data Categories to read more.

API Definition

Request

TypeURLVersion
POSThttps://api.attestr.com/api/{version/public/consent/data-categoriesUse "v3" for DPDA compliant version

Request Body Parameters

TypeNameDescriptionOptional (default)Min VersionMax Version
StringtypeProvide the consent purpose. Allowed values are - kyc_verification background_verification Read more at Consent PurposeRequiredv3
Array<Service Object>servicesList of services for which data categories are required to be fetched. Refer Service object definition below.Requiredv3

Service Object Definition

TypeNameDescriptionOptional (default)Min VersionMax Version
StringserviceProvide the Service code. Attestr assigns a unique service code to each product and service it offers. For example, the service code for Bank Account Verification is BANK_ACC. Please refer to the relevant product documentation to identify the correct service code for the service you intend to use.Requiredv3
ObjectoptionsReserved for future use. Used for specifying service specific options which helps to decide the associated data categories.Optionalv3

Request Header Parameters

TypeNameValue / DescriptionOptionalMin VersionMax Version
StringContent-Typeapplication/jsonRequiredv3
StringAuthorizationBasic {authToken}Requiredv3

If you do not have the authentication token, please refer to Register App to generate one.

Sample Request Payload

JSON
Copy

Response

Http Status 200

API returns an array of objects. Each object includes one data category and list of associated data types. The object definition is as below.

KeyDescriptionTypeMin VersionMax Version
categoryData category for the provided serviceStringv3
valuesAssociated data types as mapped to the provided serviceArray<String>v3

Sample Response

Sample response for valid input

JSON
Copy

Error Response

ParameterTypeDescription
codeNumberUnique error codes for different errors. Always available.
httpStatusCodeStringStandard HTTP status code for the error
messageStringError message describing the error. Always Available.
detailsStringDetail error message. Available only for certain types of errors.

Error Codes

HTTP StatusError CodeError Message
4004001Malformed data or missing required parameter values
4004005Operation could not be performed due to low credits balance
4014016Invalid client authorization
4034031Unauthorized access
4034035Requested service is not provisioned for your account
4034039Client's IP address is not whitelisted
4034035Requested service is not provisioned for your account
4294291Maximum account rate limit exceeded
4294292Maximum API rate limit exceeded
4294293Maximum account daily limit exceeded
4294294Maximum API daily limit exceeded
5005001Request could not be processed

Sample Error Response

JSON
Copy

Get Free Trial

Create a free account Or “Talk to Us” for price information and other queries.

VariableType to search · ESC to discard
GlossaryType to search · ESC to discard
InsertType to search · ESC to discard
No matches