curl --request PUT \
--url https://api.initdesk.com/organizations/{organization_id}/business-hours/ \
--header 'Content-Type: application/json' \
--header 'X-Initdesk-Token: <api-key>' \
--data '
{
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": null,
"sun": null
}
}
'import requests
url = "https://api.initdesk.com/organizations/{organization_id}/business-hours/"
payload = {
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": None,
"sun": None
}
}
headers = {
"X-Initdesk-Token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-Initdesk-Token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
timezone: 'America/Sao_Paulo',
weekly_hours: {
mon: {opens_at: '09:00', closes_at: '18:00'},
tue: {opens_at: '09:00', closes_at: '18:00'},
wed: {opens_at: '09:00', closes_at: '18:00'},
thu: {opens_at: '09:00', closes_at: '18:00'},
fri: {opens_at: '09:00', closes_at: '18:00'},
sat: null,
sun: null
}
})
};
fetch('https://api.initdesk.com/organizations/{organization_id}/business-hours/', 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.initdesk.com/organizations/{organization_id}/business-hours/",
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([
'timezone' => 'America/Sao_Paulo',
'weekly_hours' => [
'mon' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'tue' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'wed' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'thu' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'fri' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'sat' => null,
'sun' => null
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Initdesk-Token: <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.initdesk.com/organizations/{organization_id}/business-hours/"
payload := strings.NewReader("{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-Initdesk-Token", "<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.put("https://api.initdesk.com/organizations/{organization_id}/business-hours/")
.header("X-Initdesk-Token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.initdesk.com/organizations/{organization_id}/business-hours/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-Initdesk-Token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}"
response = http.request(request)
puts response.read_body{
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": null,
"sun": null
},
"is_open_now": false,
"next_open": "2026-10-12T12:00:00Z",
"next_open_display": "Monday, October 12, 9:00 AM (BRT)"
}Replace business hours
curl --request PUT \
--url https://api.initdesk.com/organizations/{organization_id}/business-hours/ \
--header 'Content-Type: application/json' \
--header 'X-Initdesk-Token: <api-key>' \
--data '
{
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": null,
"sun": null
}
}
'import requests
url = "https://api.initdesk.com/organizations/{organization_id}/business-hours/"
payload = {
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": None,
"sun": None
}
}
headers = {
"X-Initdesk-Token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-Initdesk-Token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
timezone: 'America/Sao_Paulo',
weekly_hours: {
mon: {opens_at: '09:00', closes_at: '18:00'},
tue: {opens_at: '09:00', closes_at: '18:00'},
wed: {opens_at: '09:00', closes_at: '18:00'},
thu: {opens_at: '09:00', closes_at: '18:00'},
fri: {opens_at: '09:00', closes_at: '18:00'},
sat: null,
sun: null
}
})
};
fetch('https://api.initdesk.com/organizations/{organization_id}/business-hours/', 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.initdesk.com/organizations/{organization_id}/business-hours/",
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([
'timezone' => 'America/Sao_Paulo',
'weekly_hours' => [
'mon' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'tue' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'wed' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'thu' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'fri' => [
'opens_at' => '09:00',
'closes_at' => '18:00'
],
'sat' => null,
'sun' => null
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Initdesk-Token: <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.initdesk.com/organizations/{organization_id}/business-hours/"
payload := strings.NewReader("{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-Initdesk-Token", "<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.put("https://api.initdesk.com/organizations/{organization_id}/business-hours/")
.header("X-Initdesk-Token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.initdesk.com/organizations/{organization_id}/business-hours/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-Initdesk-Token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"timezone\": \"America/Sao_Paulo\",\n \"weekly_hours\": {\n \"mon\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"tue\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"wed\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"thu\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"fri\": {\n \"opens_at\": \"09:00\",\n \"closes_at\": \"18:00\"\n },\n \"sat\": null,\n \"sun\": null\n }\n}"
response = http.request(request)
puts response.read_body{
"timezone": "America/Sao_Paulo",
"weekly_hours": {
"mon": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"tue": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"wed": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"thu": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"fri": {
"opens_at": "09:00",
"closes_at": "18:00"
},
"sat": null,
"sun": null
},
"is_open_now": false,
"next_open": "2026-10-12T12:00:00Z",
"next_open_display": "Monday, October 12, 9:00 AM (BRT)"
}Authorizations
Path Parameters
Body
Organization schedule. Send timezone and weekly_hours to save.
is_open_now, next_open, and next_open_display are read-only. No saved schedule returns timezone null and weekly_hours {}.
IANA time zone, for example America/Sao_Paulo. Required when saving. Null only when no schedule is saved.
1Keys mon, tue, wed, thu, fri, sat, sun. null means closed. One range is {"opens_at": "09:00", "closes_at": "18:00"} (24-hour HH:MM, no seconds). Omit a key to store that day as closed.
Show child attributes
Show child attributes
{
"mon": { "opens_at": "09:00", "closes_at": "18:00" },
"tue": { "opens_at": "09:00", "closes_at": "18:00" },
"wed": { "opens_at": "09:00", "closes_at": "18:00" },
"thu": { "opens_at": "09:00", "closes_at": "18:00" },
"fri": { "opens_at": "09:00", "closes_at": "18:00" },
"sat": null,
"sun": null
}
Response
Organization schedule. Send timezone and weekly_hours to save.
is_open_now, next_open, and next_open_display are read-only. No saved schedule returns timezone null and weekly_hours {}.
IANA time zone, for example America/Sao_Paulo. Required when saving. Null only when no schedule is saved.
Keys mon, tue, wed, thu, fri, sat, sun. null means closed. One range is {"opens_at": "09:00", "closes_at": "18:00"} (24-hour HH:MM, no seconds). Omit a key to store that day as closed.
Show child attributes
Show child attributes
{
"mon": { "opens_at": "09:00", "closes_at": "18:00" },
"tue": { "opens_at": "09:00", "closes_at": "18:00" },
"wed": { "opens_at": "09:00", "closes_at": "18:00" },
"thu": { "opens_at": "09:00", "closes_at": "18:00" },
"fri": { "opens_at": "09:00", "closes_at": "18:00" },
"sat": null,
"sun": null
}
True when the organization is open at the current time.
Start of the next opening after the current stretch, as ISO-8601 UTC. Null when there is no next opening.
next_open in the organization working language. Empty when there is no next opening.
Was this page helpful?

