> ## Documentation Index
> Fetch the complete documentation index at: https://developers.tarefy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Make your first call to the Tarefy API in 5 minutes

## Step 1 — Get a JWT token

Sign in with your email and password to receive a JWT valid for 24h.

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://app.tarefy.com/nodeapi/v2/auth/login \
    -H "Content-Type: application/json" \
    -d '{
      "email": "your-email@company.com",
      "password": "your-password"
    }'
  ```

  ```javascript Node theme={null}
  const res = await fetch('https://app.tarefy.com/nodeapi/v2/auth/login', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      email: 'your-email@company.com',
      password: 'your-password',
    }),
  });
  const { token } = await res.json();
  ```

  ```python Python theme={null}
  import requests
  res = requests.post(
      'https://app.tarefy.com/nodeapi/v2/auth/login',
      json={'email': 'your-email@company.com', 'password': 'your-password'}
  )
  token = res.json()['token']
  ```
</CodeGroup>

The response includes a `token` field — store it and send on every subsequent request.

## Step 2 — List your tasks

Pass the token in the `Authorization` header:

<CodeGroup>
  ```bash cURL theme={null}
  curl https://app.tarefy.com/nodeapi/v2/tasks \
    -H "Authorization: Bearer YOUR_TOKEN"
  ```

  ```javascript Node theme={null}
  const tasks = await fetch('https://app.tarefy.com/nodeapi/v2/tasks', {
    headers: { Authorization: `Bearer ${token}` },
  }).then(r => r.json());
  ```

  ```python Python theme={null}
  tasks = requests.get(
      'https://app.tarefy.com/nodeapi/v2/tasks',
      headers={'Authorization': f'Bearer {token}'}
  ).json()
  ```
</CodeGroup>

## Step 3 — Create a task

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://app.tarefy.com/nodeapi/v2/tasks \
    -H "Authorization: Bearer YOUR_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "title": "My first task via API",
      "description": "Created using the quickstart guide"
    }'
  ```

  ```javascript Node theme={null}
  await fetch('https://app.tarefy.com/nodeapi/v2/tasks', {
    method: 'POST',
    headers: {
      Authorization: `Bearer ${token}`,
      'Content-Type': 'application/json',
    },
    body: JSON.stringify({
      title: 'My first task via API',
      description: 'Created using the quickstart guide',
    }),
  });
  ```
</CodeGroup>

## Next steps

<CardGroup cols={2}>
  <Card title="Advanced authentication" icon="key" href="/authentication">
    Token expiry, refresh, management
  </Card>

  <Card title="Full reference" icon="code" href="/api-reference">
    All endpoints documented
  </Card>
</CardGroup>
