Skip to content

Getting started

Connecting the the API is easy. You'll need an active subscription, your API key, and an understanding of a Lasso Id.

Connecting to the API

In order to connect to the API you must have an active paid or trial subscription. If you do not have this, sign up for a trial at our website.

The API is located at api.lassox.com. Please use SSL (https) if possible.

Authentication

For every request you make you have to include your API key. To do this, append a header called lasso-api-key to your request, with your API key as the header value. Alternatively you can append a query parameter accessKey to your request URL. Say that your API key is ABC, then you will have to append the following to your query: ?accessKey=ABC.

You locate your API key from the settings area when logged into Lasso. Look under Account information (Kontooplysninger) where you should see something similar to the following:

Locating your API key

Please note that your API key is personal to you. Do not share or expose your API key to third parties.

Understanding the Lasso Id

You are now ready to query the API. In order to query for a specific entity like a company, you will need its unique identifier. In CVR this unique id is a CVR number for companies, and a person id for a person.

In Lasso we use the concept of a Lasso Id:

A Lasso Id is simply an identifier that describes the type, unique id and the data source of an entity, in a single combined string.

For example, a Lasso id for the company Lasso X is CVR-1-34580820. Let's break it down:

Understanding the Lasso Id

First part is the data source identifier: CVR, identifying the Danish Company Registry.

Second part is the entity type number: 1, identifying the type Company. Other types are 2 (production unit) and 3 (person).

Third part is the unique identifier in the given data source: 34580820, which is the CVR number in the Danish company registry. In Microsoft Dynamics CRM the unique identifier would be a Globally unique identifier (GUID).

With this in mind, you can query any supported data source using only the lasso Id. The following section explains how.

Rate Limits

To ensure fair usage of our APIs, we employ rate limiting. Currently, the limit is 500 requests/minute per API Key.

Once you exceed the limit, you will receive the following response with a 429 statuscode:

{
    "errorMessage": "Too many requests. We allow 500 requests per minute.",
    "httpStatusCode": 429,
    "errorCode": 26,
    "friendlyError": "Please retry your request after the seconds indicated in the 'retry-after' response-header.",
    "helpMessage": "For more information about rate limiting, visit our documentation.",
    "helpLink": "https://docs.lassox.com/gettingstarted/#rate-limits"
}

As the friendlyError indicates, you will receive a response-header named 'retry-after', containing the seconds you must wait before you send another request.

How are the requests counted?

The rate limit works in such a way, that the first request will start the window of requests, and after one minute the request window will reset. This effectively means that you cannot make another request before the number of seconds in the retry-after header has passed.