kvk_get_naamgeving: Retrieve the Naamgeving for a given KvK number

View source: R/kvk_retrieve.R

kvk_get_naamgevingR Documentation

Retrieve the Naamgeving for a given KvK number

Description

This function retrieves the name information (naamgeving) for a given KvK number (kvkNummer) using the KvK Naamgevingen API.

Usage

kvk_get_naamgeving(kvkNummer, test_environment = FALSE)

Arguments

kvkNummer

A string representing the KvK number for which the name information is requested.

test_environment

A logical value indicating whether to use the test environment (TRUE) or the production environment (FALSE). Defaults to FALSE.

Details

The function also supports the test_environment argument. When set to TRUE, the function will query the KvK test API environment, providing a set of fictitious test data.

The function retrieves data from the KvK Naamgevingen API.

Important: If test_environment = TRUE, no actual API key is required. You will be using test data from the KvK test environment.

Value

A tibble containing the retrieved name information.

Examples


# Examples using the production API (requires API key)
# Retrieve naamgeving for a given KvK number
naamgeving <- kvk_get_naamgeving(kvkNummer = "68750110")
print(naamgeving)

# Examples using test environment (no API key required)
naamgeving_test <- kvk_get_naamgeving(kvkNummer = "68727720", test_environment = TRUE)
print(naamgeving_test)


kvkapiR documentation built on June 25, 2025, 5:11 p.m.