# Authentication

## Authentication flow

To use the Lancerkit API, you'll need to use an API key. To have an API key, you must first be sure to have created an account on our application: <https://lancerkit.com>&#x20;

> Your API key may be found in the Lancerkit application under the "Settings > Integrations" menu.&#x20;

After you have your API key, you may authenticate to the API by putting it in the HTTP header "Authorization" of your API queries. The Authorization header should look like "Authorization: Bearer \[your-api-key]".&#x20;

This provides a safe and dependable method of accessing your Lancerkit data, guaranteeing that only authorized people may use the API. This article will walk you through the process of authenticating to the Lancerkit API using your API key so you can start developing sophisticated integrations and custom apps with ease This article will walk you through the process of authenticating to the Lancerkit API using your API key so you can start developing sophisticated integrations and custom apps with ease.&#x20;

For instance, you can try the following call:&#x20;

## List all the contacts

<mark style="color:blue;">`GET`</mark> `https://api.Lancerkit.com/contacts`

List all the contacts in the application

#### Headers

| Name          | Type            | Description |
| ------------- | --------------- | ----------- |
| Authorization | Bearer API\_KEY |             |

{% tabs %}
{% tab title="200 Your API key is correct" %}

```javascript
{
    "name"="Wilson",
    "owner": {
        "id": "sha7891bikojbkreuy",
        "name": "Samuel Passet",
    "species": "Dog",}
    "breed": "Golden Retriever",
}
```

{% endtab %}

{% tab title="401 Your API key is not correct" %}

{% endtab %}
{% endtabs %}

{% hint style="info" %}
**Good to know:** If your API key is incorrect, or, if your authorization header is not present, all your requests will fail with a HTTP 401 or 403 status
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://apidoc.lancerkit.com/reference/api-reference/authentication.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
