# createAccount

createAccount - Creates a new account for the authenticated user.

Last updated October 2, 2026

## Reference

Authentication: **bearer token required** (see [how to get a token](https://financesavi.com/developers/authentication#get-a-token))

```
createAccount - Creates a new account for the authenticated user.

Parameters:
- ownerId (string, required): ID of the user this account belongs to
- name (string, required): Display name of the account
- description (string, optional): Description of the account
- industryAccountRateId (string, optional): If provided, auto-creates rewards from that industry account rate introOffers
- accountType (string, required): Type of account (DEPOSITORY, CREDIT, LOAN, INVESTMENT, CASH, ASSET, GIFT_CARD, OTHER, GOVERNMENT)
- accountSubtype (string, required): Specific subtype of account
- assetType (string, optional): Asset type (only for ASSET accounts)
- investmentType (string, optional): Investment type (only for INVESTMENT accounts)
- giftCardVendorId (string, optional): Vendor ID (only for GIFT_CARD accounts)
- giftCardVendorName (string, optional): Vendor name fallback (only for GIFT_CARD accounts)
- defaultCurrency (string, required): Currency code (default: CAD)
- savingInterestRate (float, optional): Interest rate for savings accounts
- debtInterestRate (float, optional): Interest rate for debt accounts
- creditLimit (number, optional): Credit limit in cents for credit accounts
- isVariableInterestRate (bool, optional): Variable rate flag for debt accounts
- interestRecurrenceRate (string, optional): DAILY, WEEKLY, BIWEEKLY, MONTHLY, QUARTERLY, SEMIANNUALLY, ANNUALLY
- gracePeriod (string, optional): ISO8601/RFC3339 datetime for debt grace period
- positionOrder (int, optional): Display order
- countryId (int, optional): Country ID for regional availability
- governmentAccountType (string, optional): Government account subtype
- stockSymbol (string, optional): Stock symbol for investment accounts
- stockPrice (float, optional): Stock price
- stockQuantity (float, optional): Stock quantity
- fuelEfficiency (float, optional): KM per liter (only for CAR asset type)
- accountIconPreference (string, optional): GENERIC keeps the account-type icon even when the name matches a known bank; otherwise a recognized bank logo is used when available
- customIcon (string, optional): User-picked icon name from the allowed account icon set (e.g. wallet, piggy-bank, car); shown instead of any logo or account-type icon
- customIconColor (string, optional): "#RRGGBB" background color for the account icon
- customImageFileId (string, optional): ID of a PNG, JPEG, WebP, or GIF image the owner uploaded with uploadFile; shown as the account icon ahead of customIcon and logos; account reads return a time-limited customImageUrl

Returns:
- accountId (string): Newly created account ID
- autoRewardsAttemptedCount (int): Number of auto reward creations attempted
- autoRewardsCreatedCount (int): Number of auto rewards created
- autoRewardsSkippedCount (int): Number of auto rewards skipped

Example:
{
  "method": "createAccount",
  "params": {
    "ownerId": "u_abc123",
    "name": "My Checking Account",
    "accountType": "DEPOSITORY",
    "accountSubtype": "CHECKING",
    "defaultCurrency": "CAD"
  }
}
```

## createAccount request

POST https://api-v2.financesavi.com/rpc · Bearer token required

### cURL

```bash
curl -sS --max-time 30 -X POST 'https://api-v2.financesavi.com/rpc' \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $SAVI_TOKEN" \
  -d '{"jsonrpc":"2.0","method":"createAccount","params":{"ownerId":"user_8f3a1c2d9b","name":"Everyday Chequing","accountType":"DEPOSITORY","accountSubtype":"CHECKING","defaultCurrency":"CAD"},"id":1}'
```

### JavaScript

```javascript
const response = await fetch("https://api-v2.financesavi.com/rpc", {
  method: 'POST',
  signal: AbortSignal.timeout(30_000),
  headers: {
    'Content-Type': 'application/json',
    Authorization: `Bearer ${process.env.SAVI_TOKEN}`,
  },
  body: JSON.stringify({
      "jsonrpc": "2.0",
      "method": "createAccount",
      "params": {
        "ownerId": "user_8f3a1c2d9b",
        "name": "Everyday Chequing",
        "accountType": "DEPOSITORY",
        "accountSubtype": "CHECKING",
        "defaultCurrency": "CAD"
      },
      "id": 1
    }),
});
console.log(await response.json());
```

### TypeScript

```typescript
const response = await fetch("https://api-v2.financesavi.com/rpc", {
  method: 'POST',
  signal: AbortSignal.timeout(30_000),
  headers: {
    'Content-Type': 'application/json',
    Authorization: `Bearer ${process.env.SAVI_TOKEN}`,
  },
  body: JSON.stringify({
      "jsonrpc": "2.0",
      "method": "createAccount",
      "params": {
        "ownerId": "user_8f3a1c2d9b",
        "name": "Everyday Chequing",
        "accountType": "DEPOSITORY",
        "accountSubtype": "CHECKING",
        "defaultCurrency": "CAD"
      },
      "id": 1
    }),
});
console.log(await response.json());
```

### Python

```python
import os
import requests

response = requests.post(
    "https://api-v2.financesavi.com/rpc",
    headers={"Authorization": f"Bearer {os.environ['SAVI_TOKEN']}"},
    json={
        "jsonrpc": "2.0",
        "method": "createAccount",
        "params": {
            "ownerId": "user_8f3a1c2d9b",
            "name": "Everyday Chequing",
            "accountType": "DEPOSITORY",
            "accountSubtype": "CHECKING",
            "defaultCurrency": "CAD",
        },
        "id": 1,
    },
    timeout=30,
)
print(response.json())
```

### Go

```go
package main

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

func main() {
  payload := strings.NewReader("{\"jsonrpc\":\"2.0\",\"method\":\"createAccount\",\"params\":{\"ownerId\":\"user_8f3a1c2d9b\",\"name\":\"Everyday Chequing\",\"accountType\":\"DEPOSITORY\",\"accountSubtype\":\"CHECKING\",\"defaultCurrency\":\"CAD\"},\"id\":1}")
  req, err := http.NewRequest("POST", "https://api-v2.financesavi.com/rpc", payload)
  if err != nil { panic(err) }
  req.Header.Set("Content-Type", "application/json")
  req.Header.Set("Authorization", "Bearer " + os.Getenv("SAVI_TOKEN"))
  client := &http.Client{Timeout: 30 * time.Second}
  res, err := client.Do(req)
  if err != nil { panic(err) }
  defer res.Body.Close()
  body, err := io.ReadAll(res.Body)
  if err != nil { panic(err) }
  fmt.Println(res.Status, string(body))
}
```

### C#

```csharp
// .NET 6 or later
using System;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Text;

using var client = new HttpClient { Timeout = TimeSpan.FromSeconds(30) };
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("SAVI_TOKEN"));
using var content = new StringContent(@"{""jsonrpc"":""2.0"",""method"":""createAccount"",""params"":{""ownerId"":""user_8f3a1c2d9b"",""name"":""Everyday Chequing"",""accountType"":""DEPOSITORY"",""accountSubtype"":""CHECKING"",""defaultCurrency"":""CAD""},""id"":1}", Encoding.UTF8, "application/json");
using var response = await client.PostAsync(@"https://api-v2.financesavi.com/rpc", content);
Console.WriteLine($"HTTP {(int)response.StatusCode}");
Console.WriteLine(await response.Content.ReadAsStringAsync());
```

### Java

```java
// Java 11+: save as SaviExample.java, then run java SaviExample.java
import java.net.URI;
import java.net.http.*;
import java.time.Duration;

class SaviExample {
  public static void main(String[] args) throws Exception {
    var client = HttpClient.newBuilder().connectTimeout(Duration.ofSeconds(30)).build();
    var builder = HttpRequest.newBuilder(URI.create("https://api-v2.financesavi.com/rpc"))
        .timeout(Duration.ofSeconds(30))
        .header("Content-Type", "application/json");
    builder.header("Authorization", "Bearer " + System.getenv("SAVI_TOKEN"));
    var request = builder.POST(HttpRequest.BodyPublishers.ofString("{\"jsonrpc\":\"2.0\",\"method\":\"createAccount\",\"params\":{\"ownerId\":\"user_8f3a1c2d9b\",\"name\":\"Everyday Chequing\",\"accountType\":\"DEPOSITORY\",\"accountSubtype\":\"CHECKING\",\"defaultCurrency\":\"CAD\"},\"id\":1}")).build();
    var response = client.send(request, HttpResponse.BodyHandlers.ofString());
    System.out.println("HTTP " + response.statusCode());
    System.out.println(response.body());
  }
}
```

### PHP

```php
<?php
// Requires the PHP cURL extension.
$curl = curl_init('https://api-v2.financesavi.com/rpc');
curl_setopt_array($curl, [
    CURLOPT_POST => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CONNECTTIMEOUT => 30,
    CURLOPT_TIMEOUT => 30,
    CURLOPT_HTTPHEADER => [
        'Content-Type: application/json',
        'Authorization: Bearer ' . getenv('SAVI_TOKEN'),
    ],
    CURLOPT_POSTFIELDS => '{"jsonrpc":"2.0","method":"createAccount","params":{"ownerId":"user_8f3a1c2d9b","name":"Everyday Chequing","accountType":"DEPOSITORY","accountSubtype":"CHECKING","defaultCurrency":"CAD"},"id":1}',
]);
$body = curl_exec($curl);
if ($body === false) {
    throw new RuntimeException(curl_error($curl));
}
echo "HTTP " . curl_getinfo($curl, CURLINFO_HTTP_CODE) . PHP_EOL;
echo $body . PHP_EOL;
curl_close($curl);
```

### Ruby

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

uri = URI('https://api-v2.financesavi.com/rpc')
request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['Authorization'] = 'Bearer ' + ENV.fetch('SAVI_TOKEN')
request.body = '{"jsonrpc":"2.0","method":"createAccount","params":{"ownerId":"user_8f3a1c2d9b","name":"Everyday Chequing","accountType":"DEPOSITORY","accountSubtype":"CHECKING","defaultCurrency":"CAD"},"id":1}'
response = Net::HTTP.start(uri.host, uri.port,
  use_ssl: uri.scheme == 'https', open_timeout: 30, read_timeout: 30, write_timeout: 30
) { |http| http.request(request) }
puts "HTTP #{response.code}"
puts response.body
```

### Swift

```swift
// Swift 5.5+: save as SaviExample.swift, then run swift SaviExample.swift
import Foundation
#if canImport(FoundationNetworking)
import FoundationNetworking
#endif

var request = URLRequest(url: URL(string: "https://api-v2.financesavi.com/rpc")!)
request.httpMethod = "POST"
request.timeoutInterval = 30
request.setValue("application/json", forHTTPHeaderField: "Content-Type")
guard let token = ProcessInfo.processInfo.environment["SAVI_TOKEN"] else { fatalError("Set SAVI_TOKEN first") }
request.setValue("Bearer " + token, forHTTPHeaderField: "Authorization")
request.httpBody = Data("{\"jsonrpc\":\"2.0\",\"method\":\"createAccount\",\"params\":{\"ownerId\":\"user_8f3a1c2d9b\",\"name\":\"Everyday Chequing\",\"accountType\":\"DEPOSITORY\",\"accountSubtype\":\"CHECKING\",\"defaultCurrency\":\"CAD\"},\"id\":1}".utf8)
let configuration = URLSessionConfiguration.ephemeral
configuration.timeoutIntervalForResource = 30
let session = URLSession(configuration: configuration)
let (data, response) = try await session.data(for: request)
if let http = response as? HTTPURLResponse { print("HTTP", http.statusCode) }
print(String(decoding: data, as: UTF8.self))
```

### Local API capture (scrubbed) (HTTP 200)

```json
{
  "jsonrpc": "2.0",
  "result": {
    "accountId": "account_5kQe2Xv9Lm"
  },
  "id": 1
}
```

Source: https://financesavi.com/developers/api/createAccount
