# API reference

## Getting started

The Loop API lets you access Loop's functionality.&#x20;

## Authentication

To start using the API, you first need to get your API token. Get it from your Loop web settings, click the **API keys** tab, then the [**Create a new token**](https://docs.intheloop.io/creating-api-tokens) link.

NOTE You need to be part of an workspace with a paid plan in order to generate API tokens.

You must transmit your user token as a `Bearer` token in the `Authorization` HTTP header.

```
POST /api/v1/report/export
Host: api.intheloop.io
Authorization: Bearer 720a62b5-1245-aa31-b111-11290f8079b8
```

## **Responses**

All API responses are formatted as [JSON](http://www.json.org/), including errors. Successful `POST` requests may return the [201](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes) status code with no body.

## **Evaluating Responses**

You should infer the success of your requests from the returned HTTP status code. A successful request will return either a [200](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes) or [201](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes) status code.

## **Post Bodies**

You must explicitly send POST requests with `Content-Type: application/json`.

```
POST /v1/drafts
Host: api.intheloop.io
Authorization: Bearer 720a62b5-1245-aa31-b111-11290f8079b8
Content-Type: application/json

```
