Skip to main content
PATCH
/
configuration
Updates the client configuration
curl --request PATCH \
  --url https://api.sandbox.goteal.co/configuration \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '
{
  "payslip_upload_enabled": true,
  "payroll_period_months": 24,
  "client_logo": "image.png",
  "client_callback_url": "https://app.client.com/callback",
  "recurring_checks_enabled": true,
  "recurring_check_frequency": "WEEKLY",
  "recurring_check_end_date": "2019-05-17T00:00:00.000Z",
  "payroll_connections_enabled": true,
  "client_display_name": "Acme Corporation"
}
'
import requests

url = "https://api.sandbox.goteal.co/configuration"

payload = {
    "payslip_upload_enabled": True,
    "payroll_period_months": 24,
    "client_logo": "image.png",
    "client_callback_url": "https://app.client.com/callback",
    "recurring_checks_enabled": True,
    "recurring_check_frequency": "WEEKLY",
    "recurring_check_end_date": "2019-05-17T00:00:00.000Z",
    "payroll_connections_enabled": True,
    "client_display_name": "Acme Corporation"
}
headers = {
    "X-API-KEY": "<api-key>",
    "Content-Type": "application/json"
}

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

print(response.text)
const options = {
  method: 'PATCH',
  headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
  body: JSON.stringify({
    payslip_upload_enabled: true,
    payroll_period_months: 24,
    client_logo: 'image.png',
    client_callback_url: 'https://app.client.com/callback',
    recurring_checks_enabled: true,
    recurring_check_frequency: 'WEEKLY',
    recurring_check_end_date: '2019-05-17T00:00:00.000Z',
    payroll_connections_enabled: true,
    client_display_name: 'Acme Corporation'
  })
};

fetch('https://api.sandbox.goteal.co/configuration', 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.goteal.co/configuration",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PATCH",
  CURLOPT_POSTFIELDS => json_encode([
    'payslip_upload_enabled' => true,
    'payroll_period_months' => 24,
    'client_logo' => 'image.png',
    'client_callback_url' => 'https://app.client.com/callback',
    'recurring_checks_enabled' => true,
    'recurring_check_frequency' => 'WEEKLY',
    'recurring_check_end_date' => '2019-05-17T00:00:00.000Z',
    'payroll_connections_enabled' => true,
    'client_display_name' => 'Acme Corporation'
  ]),
  CURLOPT_HTTPHEADER => [
    "Content-Type: application/json",
    "X-API-KEY: <api-key>"
  ],
]);

$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.goteal.co/configuration"

	payload := strings.NewReader("{\n  \"payslip_upload_enabled\": true,\n  \"payroll_period_months\": 24,\n  \"client_logo\": \"image.png\",\n  \"client_callback_url\": \"https://app.client.com/callback\",\n  \"recurring_checks_enabled\": true,\n  \"recurring_check_frequency\": \"WEEKLY\",\n  \"recurring_check_end_date\": \"2019-05-17T00:00:00.000Z\",\n  \"payroll_connections_enabled\": true,\n  \"client_display_name\": \"Acme Corporation\"\n}")

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

	req.Header.Add("X-API-KEY", "<api-key>")
	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.patch("https://api.sandbox.goteal.co/configuration")
  .header("X-API-KEY", "<api-key>")
  .header("Content-Type", "application/json")
  .body("{\n  \"payslip_upload_enabled\": true,\n  \"payroll_period_months\": 24,\n  \"client_logo\": \"image.png\",\n  \"client_callback_url\": \"https://app.client.com/callback\",\n  \"recurring_checks_enabled\": true,\n  \"recurring_check_frequency\": \"WEEKLY\",\n  \"recurring_check_end_date\": \"2019-05-17T00:00:00.000Z\",\n  \"payroll_connections_enabled\": true,\n  \"client_display_name\": \"Acme Corporation\"\n}")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.sandbox.goteal.co/configuration")

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

request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"payslip_upload_enabled\": true,\n  \"payroll_period_months\": 24,\n  \"client_logo\": \"image.png\",\n  \"client_callback_url\": \"https://app.client.com/callback\",\n  \"recurring_checks_enabled\": true,\n  \"recurring_check_frequency\": \"WEEKLY\",\n  \"recurring_check_end_date\": \"2019-05-17T00:00:00.000Z\",\n  \"payroll_connections_enabled\": true,\n  \"client_display_name\": \"Acme Corporation\"\n}"

response = http.request(request)
puts response.read_body
{
  "payslip_upload_enabled": true,
  "payroll_period_months": 24,
  "client_logo": "image.png",
  "client_callback_url": "https://app.client.com/callback",
  "recurring_checks_enabled": true,
  "recurring_check_frequency": "WEEKLY",
  "recurring_check_end_date": "2019-05-17T00:00:00.000Z",
  "payroll_connections_enabled": true,
  "client_display_name": "Acme Corporation"
}
{
  "errors": [
    "The request is missing the required field `name`"
  ]
}
{
  "errors": [
    "No X-API-KEY header provided or wrong value"
  ]
}

Authorizations

X-API-KEY
string
header
required

Body

application/json
payslip_upload_enabled
boolean

Determines if payslip upload via documents is allowed as a fallback if there is not connection to payroll providers

Example:

true

payroll_period_months
integer<int32>

Lookback period of the payroll to search on account creation

Example:

24

Client logo asset or URL

Example:

"image.png"

client_callback_url
string

Callback URL for client application. This will be redirected to once the user completes their journey on Teal's platform

Example:

"https://app.client.com/callback"

recurring_checks_enabled
boolean

Determines if recurring checks are enabled client-wide

Example:

true

recurring_check_frequency
string

Frequency of the recurring check for the client. Available frequencies in production are [WEEKLY, MONTHLY]. Sandbox allows HOURLY frequency in addition.

Example:

"WEEKLY"

recurring_check_end_date
string<date-time>

End date of the recurring check schedule client-wide

Example:

"2019-05-17T00:00:00.000Z"

payroll_connections_enabled
boolean

Determines if payroll connections feature is enabled for this client. When disabled, the payroll connections endpoint will return an error.

Example:

true

client_display_name
string | null

Editable display name for the client. This can be customized and is separate from the internal client name.

Example:

"Acme Corporation"

Response

OK

payslip_upload_enabled
boolean

Determines if payslip upload via documents is allowed as a fallback if there is not connection to payroll providers

Example:

true

payroll_period_months
integer<int32>

Lookback period of the payroll to search on account creation

Example:

24

Client logo asset or URL

Example:

"image.png"

client_callback_url
string

Callback URL for client application. This will be redirected to once the user completes their journey on Teal's platform

Example:

"https://app.client.com/callback"

recurring_checks_enabled
boolean

Determines if recurring checks are enabled client-wide

Example:

true

recurring_check_frequency
string

Frequency of the recurring check for the client. Available frequencies in production are [WEEKLY, MONTHLY]. Sandbox allows HOURLY frequency in addition.

Example:

"WEEKLY"

recurring_check_end_date
string<date-time>

End date of the recurring check schedule client-wide

Example:

"2019-05-17T00:00:00.000Z"

payroll_connections_enabled
boolean

Determines if payroll connections feature is enabled for this client. When disabled, the payroll connections endpoint will return an error.

Example:

true

client_display_name
string | null

Editable display name for the client. This can be customized and is separate from the internal client name.

Example:

"Acme Corporation"