curl -X POST " https://api.playground.try.be/shop/tax-configurations/abc123/calculate " \
-H " Authorization: Bearer YOUR_API_KEY " \
-H " Accept: application/json " \
-H " Content-Type: application/json " \
-d ' {
"amount": "string",
"date": "2026-01-15T09:30:00+00:00"
} ' const response = await fetch ( ' https://api.playground.try.be/shop/tax-configurations/abc123/calculate ' , {
method : ' POST ' ,
headers : {
Authorization : ' Bearer YOUR_API_KEY ' ,
' Content-Type ' : ' application/json ' ,
Accept : ' application/json ' ,
},
body : JSON . stringify ( {
" amount " : " string " ,
" date " : " 2026-01-15T09:30:00+00:00 "
} ) ,
} )
if ( ! response . ok ) {
throw new Error ( ` Trybe API ${ response . status } : ${ await response . text () }` )
}
const data = await response . json () import httpx
response = httpx . post (
" https://api.playground.try.be/shop/tax-configurations/abc123/calculate " ,
headers = {
" Authorization " : " Bearer YOUR_API_KEY " ,
" Accept " : " application/json " ,
" Content-Type " : " application/json " ,
},
json = {
" amount " : " string " ,
" date " : " 2026-01-15T09:30:00+00:00 "
},
)
response . raise_for_status ()
data = response . json () <? php
$ client = new \ GuzzleHttp \ Client ();
$ response = $ client -> request ( ' POST ' , ' https://api.playground.try.be/shop/tax-configurations/abc123/calculate ' , [
' headers ' => [
' Authorization ' => ' Bearer YOUR_API_KEY ' ,
' Accept ' => ' application/json ' ,
' Content-Type ' => ' application/json ' ,
],
' json ' => [
' amount ' => ' string ' ,
' date ' => ' 2026-01-15T09:30:00+00:00 '
],
]);
$ data = json_decode ($ response -> getBody (), true ); package main
import (
" bytes "
" encoding/json "
" net/http "
)
func main () {
payload , _ := json . Marshal ( map [ string ] interface {}{
" amount " : " string " ,
" date " : " 2026-01-15T09:30:00+00:00 " ,
})
req , _ := http . NewRequest ( " POST " , " https://api.playground.try.be/shop/tax-configurations/abc123/calculate " , bytes . NewBuffer ( payload ))
req . Header . Set ( " Authorization " , " Bearer YOUR_API_KEY " )
req . Header . Set ( " Accept " , " application/json " )
req . Header . Set ( " Content-Type " , " application/json " )
resp , err := http . DefaultClient . Do ( req )
if err != nil {
panic ( err )
}
defer resp . Body . Close ()
var data map [ string ] interface {}
json . NewDecoder ( resp . Body ). Decode ( & data )
} 200 401 403 404 422
The results of a tax calculation for a tax configuration.
{
" data " : {
" net_amount " : 1667 ,
" gross_amount " : 10000 ,
" taxes " : [
{
" name " : " VAT " ,
" inclusive " : true ,
" basis " : " net " ,
" percentage " : 20 ,
" amount " : 1667 ,
" base_amount " : 8333 ,
" item_amount " : 10000 ,
" included_remainder " : 1
}
]
}
} {
" message " : " Unauthenticated "
} {
" message " : " This action is unauthorized. "
} {
" message " : " The requested resource could not be found "
} {
" errors " : {},
" message " : " The request didn't pass validation "
}