Package 'vatcheckapi'

Title: Client for the 'vatcheckapi.com' VAT Validation API
Description: An R client for the 'vatcheckapi.com' VAT number validation API. The API requires registration of an API key. Basic features are free, some require a paid subscription. You can find the full API documentation at <https://vatcheckapi.com/docs> .
Authors: Dominik Kukacka [aut, cre]
Maintainer: Dominik Kukacka <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2025-02-04 04:24:49 UTC
Source: https://github.com/cran/vatcheckapi

Help Index


Get the current status of the API.

Description

Get the current status of the API.

Usage

get_api_status()

Value

Returns your current quota. Requests to this endpoint do not count against your quota or rate limit.


Validates any given vat number and returns its validity and company information

Description

Validates any given vat number and returns its validity and company information

Usage

get_vat_info(vat_number, country_code = NULL)

Arguments

vat_number

(required) The vat number you want to query (Either: including the country prefix, or without and you specify the country_code)

country_code

An ISO Alpha 2 Country Code for the vat number (e.g. LU)

Value

Returns all available information about the VAT ID.


Vatcheckapi API Key

Description

vatcheckapi.com requires authentication via an API key. For this package, the API key is saved as a environmental variable. In interactive mode, using vatcheckapi_api_key will require you to enter an API key. Alternatively, you can also use Sys.setenv(VATCHECKAPI_API_KEY = <key>) to set the API key manually.

Usage

vatcheckapi_api_key(force = FALSE)

Arguments

force

If TRUE, resets the API key & requires the user to provide a new API key. If FALSE and an API key already exists, the key will be printed to the console. If no key exists, you will be required to enter a key. force. Defaults to FALSE.

Value

Returns the set API key that has been stored as an enviroment variable.