---
title: Data
project: Total API
version: 2026
section: reference
language: en
license: 
url: https://totaljs.es/docs/total-api/2026/reference/data/
updated: 2026-11-20T06:51:47.968Z
---

# Data

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

Every service is a `POST` request with your token. See [Call Total API from Total.js](../../guides/call-from-totaljs/) and [Call Total API over HTTP](../../guides/call-over-http/).

## API

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

Type: `rest`

Finds the place of an IP address.

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `value` | `String` | yes |  | The IP address. |

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

Example: Total.js
```js
var place = await API('TAPI', 'geoip', '78.98.116.204').promise();
```

Example: REST
```bash
curl -X POST https://api.totaljs.com/geoip/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "78.98.116.204" }'
```

Example: Response
```json
{
	"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"
}
```

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

Type: `rest`

Reads the exchange rates of a currency on a day.

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `currency` | `String` | no | `EUR` | The base currency. |
| `date` | `String` | no | `today` | The day, for example `2026-11-19`. |

Returns: `Object` An object with one rate for each currency.

The answer has more currencies than this example shows.

Example: Total.js
```js
var rates = await API('TAPI', 'exchangerates', { currency: 'EUR', date: '2026-11-19' }).promise();
console.log(rates.USD);
```

Example: REST
```bash
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" }'
```

Example: Response
```json
{
	"USD": 1.2109,
	"GBP": 0.9,
	"CHF": 1.0764,
	"CZK": 26.239,
	"PLN": 4.4246,
	"JPY": 126.05
}
```

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

Type: `rest`

Checks whether a company is a VAT payer in the European Union.

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `value` | `String` | yes |  | 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.

Example: Total.js
```js
var company = await API('TAPI', 'checkvat', 'SK2120417167').promise();
```

Example: REST
```bash
curl -X POST https://api.totaljs.com/checkvat/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "SK2120417167" }'
```

Example: Response
```json
{
	"is": true,
	"vat": 20,
	"name": "Total Avengers s. r. o.",
	"address": "Viestova 6784/28\n97401 Banská Bystrica\nSlovensko"
}
```

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

Type: `rest`

Reads the current weather of a place.

| Parameter | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| `value` | `String` | yes |  | The place, for example `Bratislava`. |

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

Example: Total.js
```js
var weather = await API('TAPI', 'weather', 'Bratislava').promise();
```

Example: REST
```bash
curl -X POST https://api.totaljs.com/weather/ \
	-H "Content-Type: application/json" \
	-H "X-Token: YOUR_TOKEN" \
	-d '{ "value": "Bratislava" }'
```

Example: Response
```json
{
	"name": "Bratislava",
	"temperature": 22,
	"wind": 20.2,
	"humidity": 65,
	"pressure": 1018,
	"cloud": 25,
	"uv": 6,
	"sky": "Partly cloudy"
}
```
