Insertar o actualizar un receptor en base al emisor
curl --request POST \
--url https://rest.yafacture.com/receptores \
--header 'x-api-key: <api-key>'const options = {method: 'POST', headers: {'x-api-key': '<api-key>'}};
fetch('https://rest.yafacture.com/receptores', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://rest.yafacture.com/receptores"
headers = {"x-api-key": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://rest.yafacture.com/receptores",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.post("https://rest.yafacture.com/receptores")
.header("x-api-key", "<api-key>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://rest.yafacture.com/receptores"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"_id": "<string>",
"emisorId": "<string>",
"rfc": "<string>",
"nombreFiscal": "<string>",
"codigoPostal": "<string>",
"regimenFiscal": "<string>",
"idCif": "",
"correos": [],
"telefono": "",
"constancia": {},
"origen": [],
"fechaCreacion": "2026-07-14T05:45:16.491Z",
"fechaActualizacion": "2026-07-14T05:45:16.492Z",
"status": true
}{
"message": "Forbidden resource",
"error": "Forbidden",
"statusCode": 403
}Receptores
Insertar o actualizar un receptor en base al emisor
POST
/
receptores
Insertar o actualizar un receptor en base al emisor
curl --request POST \
--url https://rest.yafacture.com/receptores \
--header 'x-api-key: <api-key>'const options = {method: 'POST', headers: {'x-api-key': '<api-key>'}};
fetch('https://rest.yafacture.com/receptores', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://rest.yafacture.com/receptores"
headers = {"x-api-key": "<api-key>"}
response = requests.post(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://rest.yafacture.com/receptores",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.post("https://rest.yafacture.com/receptores")
.header("x-api-key", "<api-key>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://rest.yafacture.com/receptores"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"_id": "<string>",
"emisorId": "<string>",
"rfc": "<string>",
"nombreFiscal": "<string>",
"codigoPostal": "<string>",
"regimenFiscal": "<string>",
"idCif": "",
"correos": [],
"telefono": "",
"constancia": {},
"origen": [],
"fechaCreacion": "2026-07-14T05:45:16.491Z",
"fechaActualizacion": "2026-07-14T05:45:16.492Z",
"status": true
}{
"message": "Forbidden resource",
"error": "Forbidden",
"statusCode": 403
}Authorizations
x-api-keybearer
X-API-Key authentication header for the development token generated in Yafacture
Response
Identificador único del receptor
Identificador único del receptor
RFC (Registro Federal de Contribuyentes)
Required string length:
12 - 13Nombre o razón social fiscal
Código postal
Régimen fiscal del contribuyente
Identificador CIF
Lista de correos electrónicos
Número telefónico
Constancia de situación fiscal
Origen del registro (app, api, importación, etc.)
Fecha de creación del registro
Fecha de última actualización del registro
Estado activo/inactivo del receptor

