# OfflineDBs

## Create an offline db

<mark style="color:green;">`POST`</mark> `https://api-v2.acrcloud.com/api/offlinedbs`

#### Headers

| Name          | Type   | Description  |
| ------------- | ------ | ------------ |
| Authorization | string | Bearer token |

#### Request Body

| Name        | Type   | Description                                                                                                                                                                                          |
| ----------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| name        | string | The offline db name                                                                                                                                                                                  |
| region      | string | us-west-2,eu-west-1,ap-southeast-1                                                                                                                                                                   |
| buckets     | array  | The bucket id array                                                                                                                                                                                  |
| audio\_type | string | <p>linein or recorded. It's the type of audios you want to recognize.<br>linein: Audio of the original files  without noise.<br>recorded: Audio captured via microphone or noisy audio files<br></p> |

{% tabs %}
{% tab title="200 Cake successfully retrieved." %}

```
```

{% endtab %}
{% endtabs %}

## Rebuild the offline db

<mark style="color:orange;">`PUT`</mark> `https://api-v2.acrcloud.com/api/offlinedbs/:id`

#### Path Parameters

| Name | Type   | Description       |
| ---- | ------ | ----------------- |
| id   | number | The offline db id |

#### Headers

| Name          | Type   | Description  |
| ------------- | ------ | ------------ |
| Authorization | string | Bearer token |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}

## Delete the offline db

<mark style="color:red;">`DELETE`</mark> `https://api-v2.acrcloud.com/api/offlinedbs/:id`

#### Path Parameters

| Name | Type   | Description      |
| ---- | ------ | ---------------- |
| id   | string | The offlinedb id |

#### Headers

| Name          | Type   | Description  |
| ------------- | ------ | ------------ |
| Authorization | string | Bearer token |

{% tabs %}
{% tab title="204 " %}

```
```

{% endtab %}
{% endtabs %}

## Download the offlinedb

<mark style="color:blue;">`GET`</mark> `https://api-v2.acrcloud.com/api/offlinedbs/:id`

#### Path Parameters

| Name | Type   | Description      |
| ---- | ------ | ---------------- |
| id   | string | The offlinedb id |

#### Headers

| Name          | Type   | Description  |
| ------------- | ------ | ------------ |
| Authorization | string | Bearer token |

{% tabs %}
{% tab title="200 " %}

```
```

{% endtab %}
{% endtabs %}
