Consultar la validez de un NIF/CIF
curl --request GET \
--url 'https://api.kubifactu.com/api/id-query?nif={nif}&name={name}' \
--header 'X-Qbikode-ClientApiKey: <api-key>'import requests
url = "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}"
headers = {"X-Qbikode-ClientApiKey": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Qbikode-ClientApiKey': '<api-key>'}};
fetch('https://api.kubifactu.com/api/id-query?nif={nif}&name={name}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Qbikode-ClientApiKey: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Qbikode-ClientApiKey", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.kubifactu.com/api/id-query?nif={nif}&name={name}")
.header("X-Qbikode-ClientApiKey", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kubifactu.com/api/id-query?nif={nif}&name={name}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Qbikode-ClientApiKey"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": {
"nif": "42439999P",
"name": "ANTONIO LÓPEZ JUSTO"
}
}{
"data": {
"error": {
"code": "E-UNAUTH-APIKEY",
"message": "No client with API-KEY '5tVySMGJOpq8HfMgIX28Qz6kF0dFOoq37x55PLZcWsGeGeYkNgJyAcRTlFJ5NbVoDRm8qtCywEoiN3A9JkBanMBXYmxiqR3BItxgxx' was found.",
"http_code": 403,
"errors": null,
"details": {
"request_id": "2cc8ef846029ec69613711ad1d85f6dfebf16ffb"
}
}
}
}API Reference
Consultar la validez de un NIF/CIF
Hace un consulta al Web Service de Calidad de datos identificativos de la AEAT para validar la existencia de un NIF/CIF.
GET
/
api
/
id-query?nif=
{nif}
&name=
{name}
Consultar la validez de un NIF/CIF
curl --request GET \
--url 'https://api.kubifactu.com/api/id-query?nif={nif}&name={name}' \
--header 'X-Qbikode-ClientApiKey: <api-key>'import requests
url = "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}"
headers = {"X-Qbikode-ClientApiKey": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Qbikode-ClientApiKey': '<api-key>'}};
fetch('https://api.kubifactu.com/api/id-query?nif={nif}&name={name}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Qbikode-ClientApiKey: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.kubifactu.com/api/id-query?nif={nif}&name={name}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Qbikode-ClientApiKey", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.kubifactu.com/api/id-query?nif={nif}&name={name}")
.header("X-Qbikode-ClientApiKey", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kubifactu.com/api/id-query?nif={nif}&name={name}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Qbikode-ClientApiKey"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": {
"nif": "42439999P",
"name": "ANTONIO LÓPEZ JUSTO"
}
}{
"data": {
"error": {
"code": "E-UNAUTH-APIKEY",
"message": "No client with API-KEY '5tVySMGJOpq8HfMgIX28Qz6kF0dFOoq37x55PLZcWsGeGeYkNgJyAcRTlFJ5NbVoDRm8qtCywEoiN3A9JkBanMBXYmxiqR3BItxgxx' was found.",
"http_code": 403,
"errors": null,
"details": {
"request_id": "2cc8ef846029ec69613711ad1d85f6dfebf16ffb"
}
}
}
}Authorizations
API-KEY de la empresa que hace la petición. Este dato se puede consultar en el panel web, accediendo a la sección Empresas y accediendo a la ficha de la empresa en.
Query Parameters
NIF/CIF sobre el que se quiere hace la consulta.
Example:
"42439999P"
Nombre de la persona jurídica o física que se quiere consultar. Este campo sólo es obligatorio si la consulta es sobre un persona física.
Example:
"ANTONIO LÓPEZ JUSTO"
Response
Respuesta del Web Service de Calidad de datos identificativos.
Show child attributes
Show child attributes
⌘I