> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.resemble.ai/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.resemble.ai/_mcp/server.

# Update auto-reload settings

PUT https://app.resemble.ai/billing/api/v1/wallet/auto_reload
Content-Type: application/json

Enables, disables, or changes wallet auto-reload. Amounts are expressed in cents and must comply with the limits returned by the GET operation.

Reference: https://docs.resemble.ai/api-reference/billing-wallet/update-billing-auto-reload

## Authentication

- `Authorization` header (bearer token, required) — API key from https://app.resemble.ai/hub/api

## Request

### Body (application/json)

This endpoint expects a BillingUpdateAutoReloadRequest.

- `enabled` (boolean, required)
- `reload_amount_cents` (integer, required)
- `minimum_balance_threshold_cents` (integer, required)
- `maximum_monthly_spend_cents` (integer, required)

## Response

### 200

Updated auto-reload configuration.

- `auto_reload` (BillingAutoReloadSetting, optional)

## Errors

### 400 Bad Request Error

The request could not be parsed or contains invalid parameters.

- `error` (string, required) — Human-readable error message.

### 401 Unauthorized Error

A valid API key was not provided.

- `error` (string, required) — Human-readable error message.

### 403 Forbidden Error

The API key owner cannot manage billing, or the Billing API is unavailable for the customer's billing arrangement.

- `error` (string, required) — Human-readable authorization or eligibility error.
- `error_code` (string, optional, nullable) — Machine-readable error code when one is available.

### 422 Unprocessable Entity Error

The request was understood but violates a billing rule.

- `UpdateBillingAutoReloadRequestUnprocessableEntityError`

### 500 Internal Server Error

An unexpected billing error occurred.

- `error` (string, required) — Human-readable error message.

## Types

### BillingAutoReloadSetting

- `enabled` (boolean, optional)
- `reload_amount_cents` (integer, optional)
- `reload_amount_dollars` (double, optional)
- `minimum_balance_threshold_cents` (integer, optional)
- `minimum_balance_threshold_dollars` (double, optional)
- `maximum_monthly_spend_cents` (integer, optional)
- `maximum_monthly_spend_dollars` (double, optional)
- `current_month_spend_cents` (integer, optional)
- `current_month_spend_dollars` (double, optional)
- `remaining_monthly_allowance_cents` (integer, optional)
- `remaining_monthly_allowance_dollars` (double, optional)
- `has_payment_method` (boolean, optional)
- `can_reload` (boolean, optional)

### BillingError

- `error` (string, required) — Human-readable error message.

### BillingValidationErrors

- `errors` (list of string, required)

## Examples

**Request**

```json
{
  "enabled": true,
  "reload_amount_cents": 5000,
  "minimum_balance_threshold_cents": 1000,
  "maximum_monthly_spend_cents": 20000
}
```

**Response**

```json
{
  "auto_reload": {
    "enabled": true,
    "reload_amount_cents": 1,
    "reload_amount_dollars": 1.1,
    "minimum_balance_threshold_cents": 1,
    "minimum_balance_threshold_dollars": 1.1,
    "maximum_monthly_spend_cents": 1,
    "maximum_monthly_spend_dollars": 1.1,
    "current_month_spend_cents": 1,
    "current_month_spend_dollars": 1.1,
    "remaining_monthly_allowance_cents": 1,
    "remaining_monthly_allowance_dollars": 1.1,
    "has_payment_method": true,
    "can_reload": true
  }
}
```

**SDK Code**

```python
import requests

url = "https://app.resemble.ai/billing/api/v1/wallet/auto_reload"

payload = {
    "enabled": True,
    "reload_amount_cents": 5000,
    "minimum_balance_threshold_cents": 1000,
    "maximum_monthly_spend_cents": 20000
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.put(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://app.resemble.ai/billing/api/v1/wallet/auto_reload';
const options = {
  method: 'PUT',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"enabled":true,"reload_amount_cents":5000,"minimum_balance_threshold_cents":1000,"maximum_monthly_spend_cents":20000}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://app.resemble.ai/billing/api/v1/wallet/auto_reload"

	payload := strings.NewReader("{\n  \"enabled\": true,\n  \"reload_amount_cents\": 5000,\n  \"minimum_balance_threshold_cents\": 1000,\n  \"maximum_monthly_spend_cents\": 20000\n}")

	req, _ := http.NewRequest("PUT", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://app.resemble.ai/billing/api/v1/wallet/auto_reload")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"enabled\": true,\n  \"reload_amount_cents\": 5000,\n  \"minimum_balance_threshold_cents\": 1000,\n  \"maximum_monthly_spend_cents\": 20000\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.put("https://app.resemble.ai/billing/api/v1/wallet/auto_reload")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"enabled\": true,\n  \"reload_amount_cents\": 5000,\n  \"minimum_balance_threshold_cents\": 1000,\n  \"maximum_monthly_spend_cents\": 20000\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('PUT', 'https://app.resemble.ai/billing/api/v1/wallet/auto_reload', [
  'body' => '{
  "enabled": true,
  "reload_amount_cents": 5000,
  "minimum_balance_threshold_cents": 1000,
  "maximum_monthly_spend_cents": 20000
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://app.resemble.ai/billing/api/v1/wallet/auto_reload");
var request = new RestRequest(Method.PUT);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"enabled\": true,\n  \"reload_amount_cents\": 5000,\n  \"minimum_balance_threshold_cents\": 1000,\n  \"maximum_monthly_spend_cents\": 20000\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "enabled": true,
  "reload_amount_cents": 5000,
  "minimum_balance_threshold_cents": 1000,
  "maximum_monthly_spend_cents": 20000
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://app.resemble.ai/billing/api/v1/wallet/auto_reload")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "PUT"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```