Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. See our Privacy Policy and
Terms.
openapi: 3.2.0
info:
title: Ninjas VAT API
description: 'Combined OpenAPI specification for every API Ninjas endpoint. Requests go to https://api.api-ninjas.com with an `X-Api-Key` header; get a free key at https://api-ninjas.com/register. Human-readable docs: https://api-ninjas.com/api. Index for LLMs: https://api-ninjas.com/llms.txt.'
version: 1.0.0
contact:
name: API Ninjas
url: https://api-ninjas.com
license:
name: Proprietary
servers:
- url: https://api.api-ninjas.com
description: API Ninjas Production
security:
- ApiKeyAuth: []
tags:
- name: Vat
paths:
/v1/vat:
get:
summary: Get VAT rates for a specified EU country
description: Returns current and historical VAT rates for a European Union country, filterable by rate type and date range. Requires a two-letter ISO `country` code.
operationId: getVATRates
tags:
- Vat
parameters:
- name: country
in: query
required: true
schema:
type: string
description: Two-letter country code (ISO 3166-1 alpha-2).
- name: type
in: query
schema:
type: string
enum:
- standard
- reduced
- super_reduced
- exempted
- parking
description: VAT rate type.
- name: min_date
in: query
schema:
type: string
format: date
description: Filter results after this date (YYYY-MM-DD format).
- name: max_date
in: query
schema:
type: string
format: date
description: Filter results before this date (YYYY-MM-DD format).
- name: limit
in: query
schema:
type: integer
default: 5
minimum: 1
maximum: 30
description: Number of results to return (1-30). Default is 5.
- name: offset
in: query
schema:
type: integer
default: 0
description: Number of results to offset for pagination. Default is 0.
responses:
'200':
$ref: '#/components/responses/VATRateResponse'
'400':
$ref: '#/components/responses/VatRatesOpenapi_BadRequest'
'401':
$ref: '#/components/responses/VatRatesOpenapi_Unauthorized'
'500':
$ref: '#/components/responses/VatRatesOpenapi_InternalServerError'
security:
- ApiKeyAuth: []
components:
schemas:
VATRate:
type: object
properties:
country:
type: string
description: Two-letter country code (ISO 3166-1 alpha-2).
type:
type: string
description: VAT rate type.
enum:
- standard
- reduced
- super_reduced
- exempted
- parking
rate:
type: number
description: The VAT rate.
date:
type: string
format: date
description: The date when the rate is applicable.
category:
type: string
description: Category of goods or services the rate applies to.
required:
- country
- type
- rate
- date
responses:
VatRatesOpenapi_BadRequest:
description: Bad Request
content:
application/json:
schema:
type: object
properties:
message:
type: string
VatRatesOpenapi_InternalServerError:
description: Internal Server Error
content:
application/json:
schema:
type: object
properties:
message:
type: string
VATRateResponse:
description: A list of VAT rates.
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/VATRate'
VatRatesOpenapi_Unauthorized:
description: Unauthorized
content:
application/json:
schema:
type: object
properties:
message:
type: string
securitySchemes:
ApiKeyAuth:
type: apiKey
in: header
name: X-Api-Key
externalDocs:
description: API Ninjas documentation
url: https://api-ninjas.com/api