Spanish Total.js
English
Documentation For AI agents
Contents

Data

Look up places of IP addresses, exchange rates, VAT numbers and the weather.

.md Website
On this page

Every service is a POST request with your token. See Call Total API from Total.js and Call Total API over HTTP.

API

rest

POST https://api.totaljs.com/geoip/

Finds the place of an IP address.
ParameterTypeDescription
value String The IP address.

Returns Object The country, region, city, coordinates, provider and time zone of the address.

Total.js
var place = await API('TAPI', 'geoip', '78.98.116.204').promise();
REST
curl -X POST https://api.totaljs.com/geoip/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "78.98.116.204" }'
Response
{
	"ip": "78.98.116.204",
	"isp": "Slovak Telekom, a.s.",
	"country": "Slovakia",
	"country_code": "SK",
	"region": "Banska Bystrica",
	"region_code": "BC",
	"city": "Banská Bystrica",
	"zip": "974 01",
	"continent": "Europe",
	"continent_code": "EU",
	"lat": 48.804,
	"lng": 19.1363,
	"timezone": "Europe/Bratislava"
}
rest

POST https://api.totaljs.com/exchangerates/

Reads the exchange rates of a currency on a day.
ParameterTypeDescription
currency? String The base currency. Default: EUR
date? String The day, for example 2026-11-19. Default: today

Returns Object An object with one rate for each currency.

The answer has more currencies than this example shows.

Total.js
var rates = await API('TAPI', 'exchangerates', { currency: 'EUR', date: '2026-11-19' }).promise();
console.log(rates.USD);
REST
curl -X POST https://api.totaljs.com/exchangerates/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "currency": "EUR", "date": "2026-11-19" }'
Response
{
	"USD": 1.2109,
	"GBP": 0.9,
	"CHF": 1.0764,
	"CZK": 26.239,
	"PLN": 4.4246,
	"JPY": 126.05
}
rest

POST https://api.totaljs.com/checkvat/

Checks whether a company is a VAT payer in the European Union.
ParameterTypeDescription
value String The VAT ID, for example SK2120417167.

Returns Object Whether the company pays VAT, the VAT rate of its country, its name and its address.

It works only with VAT IDs of the European Union. is says whether the company is a VAT payer, and vat is the VAT rate of its country.

Total.js
var company = await API('TAPI', 'checkvat', 'SK2120417167').promise();
REST
curl -X POST https://api.totaljs.com/checkvat/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "SK2120417167" }'
Response
{
	"is": true,
	"vat": 20,
	"name": "Total Avengers s. r. o.",
	"address": "Viestova 6784/28\n97401 Banská Bystrica\nSlovensko"
}
rest

POST https://api.totaljs.com/weather/

Reads the current weather of a place.
ParameterTypeDescription
value String The place, for example Bratislava.

Returns Object The temperature, wind, humidity, pressure, clouds, UV index and sky.

Total.js
var weather = await API('TAPI', 'weather', 'Bratislava').promise();
REST
curl -X POST https://api.totaljs.com/weather/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "Bratislava" }'
Response
{
	"name": "Bratislava",
	"temperature": 22,
	"wind": 20.2,
	"humidity": 65,
	"pressure": 1018,
	"cloud": 25,
	"uv": 6,
	"sky": "Partly cloudy"
}
Made in Europe