Skip to content

mimadottech/kyc-defi-api-documentation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

KYC.Crypto DeFi API Documentation

KYC.Crypto

Description

Note: To use this API, a user must be KYC verified on KYC.Crypto DeFi as a party or as a government.

Once the KYC verification is done on KYC.Crypto DeFi as a party or as a government, follow the instructions to register for an API account to get an API key.

Creating an API Account

PARTNERT API SIGNIN

  • First when you visit dashboard, you will see a signin page. Go to the signup page by clicking on "Signup Here" link shown below the signin button.

PARTNER API SIGNUP

  • In the email field, a user should use the email address that has been used while KYC verification on KYC.Crypto DeFI portal.

  • Upon providing required and correct details for API account creation a user will need to verify email using OTP that will be sent to an email address provided by a user.

  • Once an account is created successfully, a user can sign in into the dashboard.

Creating new API Key

partner api dashboard

  • On clicking GENERATE NEW button, once again an OTP verification will happen
  • Upon successful OTP verification, an API key will be generated and will be ready to use for an API calls

Making API calls

  • Examples provided on this documentation is using .http code. You can test API requests with your API Key, pasting code in .http file and using VSCODE with REST CLIENT EXTENSION.

  • Note: Every API call requires an Authorization header with a basic authentication scheme.

  • In basic authentication scheme, base64 string must be provided with a combination of a username and an API Key. Below is an example of authorization header.

    Authorization: Basic dXNlcm5hbWU6U0M2V0ZQUy1QNFZNQldKLUpXSlQ2VkgtMFJEOEVBUw==
  • Above base64 encoded string is a combination of a username and an API key. Example: username:SC6WFPS-P4VMBWJ-JWJT6VH-0RD8EAS

Test API Key

  • Request Method: GET

  • Request URI: https://api.kyc-crypto.com/api/dashboard/apiKeyAccessible

  • Request Headers: Authorization

    GET https://api.kyc-crypto.com/api/dashboard/apiKeyAccessible HTTP/1.1
    Authorization: Basic dXNlcm5hbWU6U0M2V0ZQUy1QNFZNQldKLUpXSlQ2VkgtMFJEOEVBUw==
  • Successful Response: with valid api key

    { "msg":"ok" }
  • Error Response: with invalid api key

    {
      "errors":[],
      "data":{},
      "msg":"Invalid API Key"
    }

Get a user's KYC status as a partner

  • Request Method: GET

  • Request URI: https://api.kyc-crypto.com/api/partner/getKycStatus/{emailAddress}

  • Request Headers: Authorization, Content-Type

  • Request parameters

    • emailAddress: email address of a user
    GET https://api.kyc-crypto.com/api/partner/getKycStatus/starktechservice@gmail.com HTTP/1.1
    Content-Type: application/json
    Authorization: Basic dXNlcm5hbWU6U0M2V0ZQUy1QNFZNQldKLUpXSlQ2VkgtMFJEOEVBUw==
  • Successful Response: if a user has completed kyc - (status code 200)

    {
      "data": {
        "kycDone": true,
        "fname": "Rahul",
        "lname": "Trivedi",
        "bdate": "1998-01-20",
        "trxAddress": "T9z1aEGata5FENqQJDLZ3W5SnQyehbs25i"
      },
      "msg": "User has completed KYC",
      "errorCode": null
    }
  • Successful Response: if a user has not completed kyc - (status code 200)

    {
      "data": {
        "kycDone": false
      },
      "msg": "User has not completed KYC",
      "errorCode": null
    }
  • Error Response: if a user not found - (status code 403)

    {
      "data": {},
      "msg": "User not found",
      "errorCode": "EU403"
    }
    
  • Error Response: if partner is not allowed access a user detail - (status code 401)

    {
      "data": {},
      "msg": "You are not allowed to access the details of this user",
      "errorCode": "EP101"
    }
  • Error Response: if a user is blocked - (status code 422)

    {
      "data": {},
      "msg": "User is blocked, you can not access details of blocked users",
      "errorCode": "EU100"
    }
  • Error Response: if you are not registered as a partner - (status code 403)

    {
      "data": {},
      "msg": "The given tron address is not registered as a partner",
      "errorCode": "EP403"
    }
  • Error Response: internal system error - (status code 500)

    {
      "data": {},
      "msg": "Something Went Wrong",
      "errorCode": "EI500"
    }

Get a user's KYC status as a government

  • Request Method: GET

  • Request URI: https://api.kyc-crypto.com/api/gov/getKycStatus/{emailAddress}

  • Request Headers: Authorization, Content-Type

  • Request parameters

    • emailAddress: email address of a user
    GET https://api.kyc-crypto.com/api/partner/getKycStatus/starktechservice@gmail.com HTTP/1.1
    Content-Type: application/json
    Authorization: Basic dXNlcm5hbWU6U0M2V0ZQUy1QNFZNQldKLUpXSlQ2VkgtMFJEOEVBUw==
  • Successful Response: if a user has completed kyc - (status code 200)

    {
      "data": {
        "kycDone": true,
        "fname": "Rahul",
        "lname": "Trivedi",
        "bdate": "1998-01-20",
        "trxAddress": "T9z1aEGata5FENqQJDLZ3W5SnQyehbs25i"
      },
      "msg": "User has completed KYC",
      "errorCode": null
    }
  • Successful Response: if a user has not completed kyc - (status code 200)

    {
      "data": {
        "kycDone": false
      },
      "msg": "User has not completed KYC",
      "errorCode": null
    }
  • Error Response: if a user not found - (status code 403)

    {
      "data": {},
      "msg": "User not found",
      "errorCode": "EU403"
    }
    
  • Error Response: if a user is blocked - (status code 422)

    {
      "data": {},
      "msg": "User is blocked, you can not access details of blocked users",
      "errorCode": "EU100"
    }
  • Error Response: if you are not registered as a government - (status code 403)

    {
      "data": {},
      "msg": "The given tron address is not registered as a partner",
      "errorCode": "EG403"
    }
  • Error Response: internal system error - (status code 500)

    {
      "data": {},
      "msg": "Something Went Wrong",
      "errorCode": "EI500"
    }

About

KYC.Crypto DeFi API documentation

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published