🎉 Unlimited Free KYC - Forever!!

Auth + Data
Data Transfer
User Scopes

User Scopes

Scopes are pieces of information that represent user data within the Didit Protocol. Understanding these scopes is crucial for effectively implementing the Auth + Data solution.

Types of Data

  1. Verified Data: Data that has been verified by Didit, such as:

    • Email address
    • Phone number
    • Identity document details
  2. Unverified Data: Data that has not been verified by Didit, including:

    • Addresses
    • User preferences
    • Bank account details

Available User Scopes

The following table provides a comprehensive list of all available user scopes, along with descriptions and examples:

Attribute DescriptionTypeVerification Type
user_idA unique ID that represents the user's identity in your applicationstringVerified
pictureTemporary URL of the user's profile picturestringUnverified
namesFirst name, Last name, and Full name of the userobjectVerified
emailPrimary email of the userobjectVerified
phonePrimary phone number of the userobjectVerified
genderGender of the userobjectVerified
document_detailDetailed information about the user's identity documentobjectVerified
birthdateBirthdate of the userobjectVerified
addressStructured address of the userobjectVerified/Unverified
bank_accountPrimary bank account of the userobjectVerified/Unverified
preferencesUser preferences (language, currency, time zone)objectUnverified
is_verifiedIndicates if the user has verified their identitybooleanVerified
is_over_18Indicates if the user is over 18 years oldbooleanVerified
is_over_21Indicates if the user is over 21 years oldbooleanVerified
instagram_accountInstagram account information of the userobjectVerified
x_accountX account information of the userobjectVerified
tiktok_accountTikTok account information of the userobjectVerified

Some scopes, such as emails, phone numbers, or addresses, can have multiple values. In these cases, the user selects which specific value to share with the application during the data sharing request. Also, the user_id is always mandatory and returned in any case.

Example Response

Here's an example of a full response containing user scopes:

{
  "user_id": "212a7ef2-f934-47e2-94eb-907b94c9d443",
  "picture": "https://example.com/picture.png",
  "names": {
    "first_name": "Alejandro",
    "family_name": "Rosas Garcia",
    "full_name": "Alejandro Rosas Garcia"
  },
  "email": {
    "email": "alejandro@example.com",
    "is_verified": true
  },
  "phone": {
    "phone_number": "+34123456789",
    "is_verified": true
  },
  "gender": {
    "gender": "MALE", // MALE, FEMALE, UNKNOWN
    "is_verified": true
  },
  "document_detail": {
    "type": "P", // P (Passport), ID (ID Card), DL (Driver License), RP (Residence Permit)
    "issuing_country": "ESP",
    "document_number": "123456789",
    "personal_number": "123456789",
    "expiration_date": "2022-12-31",
    "date_of_issue": "2016-06-02",
    "front_image": "https://example.com/front.png",
    "back_image": "https://example.com/back.png",
    "portrait_image": "https://example.com/portrait.png",
    "date_of_birth": "1990-01-01",
    "full_name": "Alejandro Rosas Garcia",
    "gender": "M", // M (Male), F (Female), U (Unknown)
    "is_nfc_verified": true
  },
  "birthdate": {
    "date": "1990-01-01",
    "is_verified": true
  },
  "address": {
    "full_address": "Calle Viladomat, 2, 08023 Barcelona, Barcelona, Spain",
    "street_1": "Calle Viladomat 2",
    "street_2": "3-1",
    "postal_code": "08023",
    "city": "Barcelona",
    "region": "Catalunya",
    "country": "ES",
    "is_verified": true
  },
  "bank_account": {
    "number": "GB03SDNO58754297408866",
    "swift": "SSTTGBX9",
    "country": "GB",
    "is_verified": true
  },
  "preferences": {
    "language": "en",
    "currency": "usd",
    "time_zone": "GMT+1"
  },
  "is_verified": true,
  "is_over_18": true,
  "is_over_21": true,
  "instagram_account": {
    "uid": "123456789",
    "username": "alejandro",
    "email": "alejandro@example.com",
    "profile_url": "https://instagram.com/alejandro",
    "profile_image_url": "https://example.com/profile.png",
    "public_metrics": {
      "followers": 1000,
      "following": 1000,
      "posts": 1000
    },
    "is_verified": true
  },
  "x_account": {
    "uid": "123456789",
    "username": "alejandro",
    "email": "alejandro@example.com",
    "profile_url": "https://x.com/alejandro",
    "profile_image_url": "https://example.com/profile.png",
    "public_metrics": {
      "followers": 1000,
      "following": 1000,
      "posts": 1000
    },
    "is_verified": true
  },
  "tiktok_account": {
    "uid": "123456789",
    "username": "alejandro",
    "email": "alejandro@example.com",
    "profile_url": "https://tiktok.com/alejandro",
    "profile_image_url": "https://example.com/profile.png",
    "public_metrics": {
      "followers": 1000,
      "following": 1000,
      "posts": 1000
    },
    "is_verified": true
  }
}

Requesting User Scopes

To request user scopes, create a data session specifying the desired scopes. The user will be prompted to approve sharing these scopes with your application.

If you are requesting the document_detail attribute, but the user has not verified their identity, they will be prompted to complete the verification process before sharing this information. Check out our Identity Verification guide for more details.