curl --request PUT \
--url https://api.sandbox.teal.dev/v0/platform/instances/{instance_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc"
}
'import requests
url = "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}"
payload = {
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({entries_start: '2024-01-01T00:00:00Z', name: 'ACME Goods Inc'})
};
fetch('https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'entries_start' => '2024-01-01T00:00:00Z',
'name' => 'ACME Goods Inc'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}"
payload := strings.NewReader("{\n \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\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(string(body))
}HttpResponse<String> response = Unirest.put("https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}")
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 \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\n}"
response = http.request(request)
puts response.read_body{
"id": "RKtPbubK5NcbBsUmU1ktSP",
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc",
"subscription": "tier3",
"accounting_package": "platformgl",
"accounting_basis": "accrual"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}Update an Instance
Updates the entries_start or name of an Instance.
curl --request PUT \
--url https://api.sandbox.teal.dev/v0/platform/instances/{instance_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc"
}
'import requests
url = "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}"
payload = {
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({entries_start: '2024-01-01T00:00:00Z', name: 'ACME Goods Inc'})
};
fetch('https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'entries_start' => '2024-01-01T00:00:00Z',
'name' => 'ACME Goods Inc'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}"
payload := strings.NewReader("{\n \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\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(string(body))
}HttpResponse<String> response = Unirest.put("https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.teal.dev/v0/platform/instances/{instance_id}")
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 \"entries_start\": \"2024-01-01T00:00:00Z\",\n \"name\": \"ACME Goods Inc\"\n}"
response = http.request(request)
puts response.read_body{
"id": "RKtPbubK5NcbBsUmU1ktSP",
"entries_start": "2024-01-01T00:00:00Z",
"name": "ACME Goods Inc",
"subscription": "tier3",
"accounting_package": "platformgl",
"accounting_basis": "accrual"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}{
"message": "<string>",
"data": "<unknown>",
"display_message": "<string>",
"error_code": "invalid_date"
}Authorizations
Bearer authentication header of the form Bearer , where is your auth token.
Path Parameters
The instance ID
Body
The datetime in UTC time from which the API will sync an Instance's accounting data. Transactions or journal entries cannot be entered before this date. The time component is ignored — the value is always stored as start-of-day UTC (00:00:00Z).
"2024-01-01T00:00:00Z"
The name of the business.
"ACME Goods Inc"
Response
Successful Response
The unique ID of the object.
"RKtPbubK5NcbBsUmU1ktSP"
The datetime in UTC time from which the API will sync an Instance's accounting data. Transactions or journal entries cannot be entered before this date. The time component is ignored — the value is always stored as start-of-day UTC (00:00:00Z).
"2024-01-01T00:00:00Z"
The name of the business.
"ACME Goods Inc"
The Instance's subscription tier.
tier0, tier1, tier2, tier3, tier4 "tier3"
The type of accounting package the Instance uses as the source of truth for their books.
platformgl "platformgl"
The accounting method used: cash basis or accrual basis.
cash, accrual "accrual"