Get point balance
curl --request GET \
--url https://api.atlas.kitchen/accounts/v1/point_balance \
--header 'X-Channel-Id: <api-key>' \
--header 'X-Session-Id: <api-key>'import requests
url = "https://api.atlas.kitchen/accounts/v1/point_balance"
headers = {
"X-Channel-Id": "<api-key>",
"X-Session-Id": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Channel-Id': '<api-key>', 'X-Session-Id': '<api-key>'}
};
fetch('https://api.atlas.kitchen/accounts/v1/point_balance', 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.atlas.kitchen/accounts/v1/point_balance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Channel-Id: <api-key>",
"X-Session-Id: <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"
"net/http"
"io"
)
func main() {
url := "https://api.atlas.kitchen/accounts/v1/point_balance"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Channel-Id", "<api-key>")
req.Header.Add("X-Session-Id", "<api-key>")
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.atlas.kitchen/accounts/v1/point_balance")
.header("X-Channel-Id", "<api-key>")
.header("X-Session-Id", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atlas.kitchen/accounts/v1/point_balance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Channel-Id"] = '<api-key>'
request["X-Session-Id"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"points": 540,
"value": 540,
"expiring_points": 40,
"expiring_value": 40
}{
"error": "Unauthorized"
}Get point balance
The diner’s points in the channel’s point program. value is what the points are worth, in cents. Expiring points are those that expire in the next month.
If the channel has no point program, every field is 0.
GET
/
point_balance
Get point balance
curl --request GET \
--url https://api.atlas.kitchen/accounts/v1/point_balance \
--header 'X-Channel-Id: <api-key>' \
--header 'X-Session-Id: <api-key>'import requests
url = "https://api.atlas.kitchen/accounts/v1/point_balance"
headers = {
"X-Channel-Id": "<api-key>",
"X-Session-Id": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Channel-Id': '<api-key>', 'X-Session-Id': '<api-key>'}
};
fetch('https://api.atlas.kitchen/accounts/v1/point_balance', 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.atlas.kitchen/accounts/v1/point_balance",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Channel-Id: <api-key>",
"X-Session-Id: <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"
"net/http"
"io"
)
func main() {
url := "https://api.atlas.kitchen/accounts/v1/point_balance"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Channel-Id", "<api-key>")
req.Header.Add("X-Session-Id", "<api-key>")
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.atlas.kitchen/accounts/v1/point_balance")
.header("X-Channel-Id", "<api-key>")
.header("X-Session-Id", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atlas.kitchen/accounts/v1/point_balance")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Channel-Id"] = '<api-key>'
request["X-Session-Id"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"points": 540,
"value": 540,
"expiring_points": 40,
"expiring_value": 40
}{
"error": "Unauthorized"
}Authorizations
Was this page helpful?