Skip to main content
GET
/
api
/
settings
Get workspace settings
curl --request GET \
  --url https://api.staging.whilst.app/api/settings \
  --cookie whilst_session=
import requests

url = "https://api.staging.whilst.app/api/settings"

headers = {"cookie": "whilst_session="}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {cookie: 'whilst_session='}};

fetch('https://api.staging.whilst.app/api/settings', 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.staging.whilst.app/api/settings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_COOKIE => "whilst_session=",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

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

func main() {

url := "https://api.staging.whilst.app/api/settings"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("cookie", "whilst_session=")

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

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

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.staging.whilst.app/api/settings")
.header("cookie", "whilst_session=")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.staging.whilst.app/api/settings")

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

request = Net::HTTP::Get.new(url)
request["cookie"] = 'whilst_session='

response = http.request(request)
puts response.read_body
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "name": "<string>",
  "slug": "<string>",
  "metadata": {},
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z"
}
{
"message": "<string>",
"code": "<string>",
"details": {}
}
{
"message": "<string>",
"code": "<string>",
"details": {}
}
{
"message": "<string>",
"code": "<string>",
"details": {}
}

Authorizations

whilst_session
string
cookie
required

JWT session token for authenticated users

Response

Workspace settings retrieved

id
string<uuid>
required
name
string
required

Workspace display name

slug
string
required

Unique workspace identifier (WorkOS org ID)

status
enum<string>
required
Available options:
active,
suspended,
cancelled
metadata
object

Additional workspace metadata

createdAt
string<date-time>
updatedAt
string<date-time>