---
title: "First API Call | Tajo"
description: "Make your first API call to the Brevo API and verify your setup"
url: https://tajo.io/docs/quick-start/first-api-call/
markdown: https://tajo.io/docs/quick-start/first-api-call.md
lang: en-US
author: "Set Noa"
author_url: https://tajo.io/set-noa/
---

# First API Call

[Set Noa](https://tajo.io/set-noa/)

Let’s make your first API call to verify your Brevo API setup is working correctly.

## Prerequisites

- A Brevo account
- An API key from your dashboard
- A tool for making HTTP requests (curl, Postman, or similar)

## Get Account Information

The simplest first call is to get your account information:

### Using cURL

```bash
curl -X GET "https://api.brevo.com/v3/account" \
  -H "Accept: application/json" \
  -H "api-key: YOUR_API_KEY"
```

### Using JavaScript (Node.js)

```javascript
const fetch = require('node-fetch');

const getAccount = async () => {
  try {
    const response = await fetch('https://api.brevo.com/v3/account', {
      method: 'GET',
      headers: {
        'Accept': 'application/json',
        'api-key': 'YOUR_API_KEY'
      }
    });

    const data = await response.json();
    console.log('Account Info:', data);
  } catch (error) {
    console.error('Error:', error);
  }
};

getAccount();
```

### Using Python

```python
import requests

url = "https://api.brevo.com/v3/account"
headers = {
    "Accept": "application/json",
    "api-key": "YOUR_API_KEY"
}

response = requests.get(url, headers=headers)
print(response.json())
```

### Using PHP

```php
<?php
$url = 'https://api.brevo.com/v3/account';
$headers = [
    'Accept: application/json',
    'api-key: YOUR_API_KEY'
];

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
```

## Expected Response

If successful, you’ll receive a response like this:

```json
{
  "email": "your-email@company.com",
  "firstName": "John",
  "lastName": "Doe",
  "companyName": "Your Company",
  "address": {
    "street": "123 Main Street",
    "city": "New York",
    "zipCode": "10001",
    "country": "United States"
  },
  "plan": [
    {
      "type": "payAsYouGo",
      "credits": 10000,
      "creditsUsed": 1500
    }
  ]
}
```

## Error Handling

If you encounter errors, check these common issues:

### Invalid API Key (401 Unauthorized)

```json
{
  "code": "unauthorized",
  "message": "Invalid API key provided"
}
```

**Solution**: Verify your API key is correct and has the proper permissions.

### Rate Limit Exceeded (429 Too Many Requests)

```json
{
  "code": "too_many_requests",
  "message": "Rate limit exceeded"
}
```

**Solution**: Wait before making another request or upgrade your plan.

### Server Error (500 Internal Server Error)

```json
{
  "code": "internal_error",
  "message": "An internal error occurred"
}
```

**Solution**: Check our [status page](https://status.brevo.com/) or contact support.

## Next Steps

Now that you’ve made your first successful API call:

1. [Set up authentication](https://tajo.io/docs/authentication/) properly
2. [Install an SDK](https://tajo.io/docs/sdks-libraries/) for your language
3. [Learn about rate limits](https://tajo.io/docs/rate-limits/)
4. [Explore email endpoints](https://tajo.io/docs/email-messaging/)
