# Overview

The 9bits Voice Messaging API uses HTTP verbs and standard HTTP status codes to make it easier for you to integrate communications into your code. To secure your requests to our servers, we serve our API calls over HTTPs.

**Note**: The current version of the API is **v1**.

**API Endpoint**

> POST   <https://api.9bits.net/v1/sendvoice>

### API requests

9bits exposes a list of APIs to perform various actions. You can use these to deliver voice messages.

### Authentication

All requests to 9bits API are authenticated with Bearer Token using the API key that appears on the settings => security tab of the dashboard.

### Content-Type

9bits only accepts input of the type **application/json**.

All POST request arguments must be passed as text in JSON format with the Content-Type set as **application/json**.

### Asynchronous requests

All requests to 9bits APIs are asynchronous in nature. When you made an API call, 9bits returns a generic response with a reference id, and sends the API responses to your callback URL. To set the callback URL, navigate to settings => Webhook on the dashboard.

### API responses

9bits API endpoints returns responses in JSON format. 9bits sets a reference id in each response to uniquely identify your request. Each API call returns one of these HTTP status codes depending on whether the call succeeds or fails.

***

> 200     Request has been executed
>
> 201      Resource created
>
> 401      Authentication failed
>
> 405     HTTP method not allowed
>
> 429     Too many requests, rate limited
>
> 500     Server error

### Response example

<mark style="color:green;">Success</mark>

{% code overflow="wrap" %}

```json
{
    "status_code": 200,
    "message": "Request is being processed",
    "ref_id": "9azmf1ntcl358gczduzz4rs0u"
}
```

{% endcode %}

<mark style="color:red;">Error</mark>

```json
{
    "status_code": 401,
    "message": "Authentication failed: Signature verification failed"
}
```

### First Step

The first thing to do is to create an account on the [web portal](https://dashboard.9bits.net). This activity automatically provisions a caller ID that is mandatory for sending a voice message.
