Make your first Request
Last updated
Last updated
Get your token
Before you can use any of the APIs, you need to log in to your Laigo account or, if you don’t have one, create a new one.
For creating the token, please visit our platform and go to API-Client Page to create and copy your client credentials.
Once you logged in, then you can start to create your client secret and client id by selecting the API page on the left sidebar of the dashboard.
For generating your client_id and client_secret you can click on the button ‘Request new’ then you can have your credentials that you can use for creating a token.
Create an access token. To request access tokens, an application must make a POST request with the following multipart form data to the token URI: grant_type=client_credentials.
The application must pass basic HTTP auth credentials using the client_id as the user and client_secret as the password access tokens are obtained by calling the https://account.laigo.io/realms/SmartTools/protocol/openid-connect/token endpoint, and the required secrets are available in the API tab for your need.
Create an access token
POST
https://account.laigo.io/realms/SmartTools/protocol/openid-connect/token
Get your sample code
Once your access tokens are obtained by following the steps shown above the required secrets are available in the API tab for your task. In our example we will show how to use the API call to the smartICR tool. First you have to make a POST request to the following route, since you are uploading a new document.
POST
https://use.laigo.io/api/FileUpload/v1/Upload/smartICR
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
Name | Type | Description |
---|---|---|
client_id*
String
The ClientId that has been generated for this function.
client_secret*
String
The ClientSecret that has been generated for this function.
grant_type*
String
Here you put your client credentials
email*
String
If you want to sent the result to your email, you can define the destination email with this parameter
outputFormats*
String
As output format you can choose PDF and/ TEXT (e.g. outputFormats=PDF,TEXT)
languageHint
String
If you prefer the detection in a special language, you can force to use a language. Default Language is English. For choosing a Language, use the ISO-Langauge Code – 639-1
accessToken*
String
A JWT issued to your application by the Laigo identity provider.
file*
String
The file for uploading