Connecting to the Cloud Service

Handl is a server-side solution. If you want to test it, use the web demo. We do not use long-term data storage, all incoming files are transferred to the server via a secure protocol, processed in RAM and deleted immediately after the results are returned to the user.

To set up the use of the cloud API you need to make a correct request for the necessary API-method. To do that, first familiarize yourself with the description of the service you need and its API-specification. After that proceed to making the required request:

Action sequence for the correct request

  1. Get your license key from our manager. If you don't have one, mail us: [email protected]

  2. Find a picture of the test document. For testing purposes, you can use the Japanese id, covid form or an invoice.

  3. Build a query using Swagger UI at latest.handl.ai/try:

    1. Click on Authorize in the upper right corner of the page and enter your license key in any Value field;

    2. Select the API method you want. For example, if you need to recognize passport fields, select the /recognize method

    3. Click Try it out;

    4. Select the necessary values for the API request parameters. If a parameter is optional, you don't have to choose its value; it will be the default;

    5. Scroll down to the big blue button Execute, press Select file opposite to the image caption, in case of the passport from Wikipedia - Pasport_RF.jpg file;

    6. press Execute.

  4. In the curl field, you will get a correct curl-request. Copy it to the clipboard.

  5. To check the curl query, use a console such as PowerShell. To do this, go to the directory where the file you selected in step 3.5 is located. For example: cd C:\Downloads. Paste the curl query from the clipboard and execute it.

The curl-request can be converted into the programming language you want by using online converters such as curl.trillworks.com

The request to the cloud must include the API_TOKEN license key. Its transfer options are given below (the END_POINT means a certain method such as /recognize).

# token in header, option №1
$ curl -siX POST \
    -H "Authorization: Token <API_TOKEN>" \
    -F "[email protected]" \
    "https://latest.handl.ai/<END_POINT>"

# token in header, option №2
$ curl -siX POST \
    -H "Authorization: <API_TOKEN>" \
    -F "[email protected]" \
    "https://latest.handl.ai/<END_POINT>"

# token in request
$ curl -siX POST \
    -F "[email protected]" \
    "https://latest.handl.ai/<END_POINT>?token=<API_TOKEN>"

# token in cookies
$ curl -siX POST \
    -H "Cookie: token=<API_TOKEN>"
    -F "[email protected]" \
    "https://latest.handl.ai/<END_POINT>"

Last updated

Was this helpful?