curl --request GET \
--url https://api.fintoc.com/v1/tax_returns/{id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.fintoc.com/v1/tax_returns/{id}"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.fintoc.com/v1/tax_returns/{id}', 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.fintoc.com/v1/tax_returns/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <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.fintoc.com/v1/tax_returns/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<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.fintoc.com/v1/tax_returns/{id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fintoc.com/v1/tax_returns/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "taxret_nMNejK7BT8oGbvO4",
"object": "tax_return",
"currency": "CLP",
"document_number": "12345",
"fiscal_year": 2021,
"institution_id": "cl_fiscal_sii",
"institution_tax_return": {
"due_amount": 0,
"income": {
"fees": 5700000,
"fees_with_retention": 4500000,
"fees_without_retention": 1200000,
"salary": 12000000,
"withheld_fees": 562500
},
"refund_account": {
"holder_id": "111111111",
"holder_name": "Fintoc SpA",
"institution": {
"id": "cl_banco_de_chile",
"country": "cl",
"name": "Banco de Chile"
},
"number": 123123123
},
"refund_amount": 350000
},
"taxpayer": {
"id": "111111111",
"institution_tax_payer": {
"activities": [
{
"category": "1",
"code": "620200",
"description": "Servicios de tecnología",
"iva": false,
"started_at": "2020-04-16T04:00:00.000Z"
}
],
"addresses": [
{
"apartment": null,
"city": "Santiago",
"code": "84345463",
"commune": "PROVIDENCIA",
"number": "2461",
"region": "REGION METROPOLITANA",
"street": "LOS CONQUISTADORES"
}
],
"authorized_documents": [
{
"authorized_at": "2021-11-30T15:57:38.584Z",
"code": "33",
"description": "FACTURA ELECTRONICA",
"max_documents": 414
}
],
"email": "hello@fintoc.com",
"institution_office": null,
"phone": "999999999"
},
"name": "Fintoc SpA"
}
}{
"error": {
"type": "invalid_request_error",
"code": "empty_string",
"param": "link_token",
"message": "Empty string is invalid: link_token",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}{
"error": {
"type": "authentication_error",
"code": "invalid_api_key",
"message": "Invalid API Key: invalid-*oken"
}
}{
"error": {
"type": "invalid_request_error",
"code": "invalid_link_token",
"param": "link_token",
"message": "Invalid access token for link: link_nMNejK7BT8oGbvO4_token_****",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}{
"error": {
"type": "invalid_request_error",
"code": "missing_resource",
"param": "id",
"message": "No such tax_return: taxret_nMNejK7BT8oGbvO4",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}Get a tax return
Retrieves a tax return by its id, using the link’s link_token to authenticate the request. You can only retrieve tax returns that belong to the link’s fiscal account.
curl --request GET \
--url https://api.fintoc.com/v1/tax_returns/{id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.fintoc.com/v1/tax_returns/{id}"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.fintoc.com/v1/tax_returns/{id}', 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.fintoc.com/v1/tax_returns/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <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.fintoc.com/v1/tax_returns/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<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.fintoc.com/v1/tax_returns/{id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fintoc.com/v1/tax_returns/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "taxret_nMNejK7BT8oGbvO4",
"object": "tax_return",
"currency": "CLP",
"document_number": "12345",
"fiscal_year": 2021,
"institution_id": "cl_fiscal_sii",
"institution_tax_return": {
"due_amount": 0,
"income": {
"fees": 5700000,
"fees_with_retention": 4500000,
"fees_without_retention": 1200000,
"salary": 12000000,
"withheld_fees": 562500
},
"refund_account": {
"holder_id": "111111111",
"holder_name": "Fintoc SpA",
"institution": {
"id": "cl_banco_de_chile",
"country": "cl",
"name": "Banco de Chile"
},
"number": 123123123
},
"refund_amount": 350000
},
"taxpayer": {
"id": "111111111",
"institution_tax_payer": {
"activities": [
{
"category": "1",
"code": "620200",
"description": "Servicios de tecnología",
"iva": false,
"started_at": "2020-04-16T04:00:00.000Z"
}
],
"addresses": [
{
"apartment": null,
"city": "Santiago",
"code": "84345463",
"commune": "PROVIDENCIA",
"number": "2461",
"region": "REGION METROPOLITANA",
"street": "LOS CONQUISTADORES"
}
],
"authorized_documents": [
{
"authorized_at": "2021-11-30T15:57:38.584Z",
"code": "33",
"description": "FACTURA ELECTRONICA",
"max_documents": 414
}
],
"email": "hello@fintoc.com",
"institution_office": null,
"phone": "999999999"
},
"name": "Fintoc SpA"
}
}{
"error": {
"type": "invalid_request_error",
"code": "empty_string",
"param": "link_token",
"message": "Empty string is invalid: link_token",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}{
"error": {
"type": "authentication_error",
"code": "invalid_api_key",
"message": "Invalid API Key: invalid-*oken"
}
}{
"error": {
"type": "invalid_request_error",
"code": "invalid_link_token",
"param": "link_token",
"message": "Invalid access token for link: link_nMNejK7BT8oGbvO4_token_****",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}{
"error": {
"type": "invalid_request_error",
"code": "missing_resource",
"param": "id",
"message": "No such tax_return: taxret_nMNejK7BT8oGbvO4",
"doc_url": "https://docs.fintoc.com/reference/errors"
}
}Autorizaciones
Parámetros de ruta
The id of the tax return to retrieve.
Parámetros de consulta
The link_token of the link that holds the fiscal account, returned when you exchange the link.
"link_Q0xVGPvijElLRMwE_token_FhsFVurz5q5FycHA5xxhTpzX"
Respuesta
The tax return.
Annual income tax return (F22 form) the taxpayer filed with the Chilean tax authority (SII) for a fiscal year.
Unique identifier of the tax return.
"taxret_nMNejK7BT8oGbvO4"
Type of the object. Always tax_return.
Three-letter ISO 4217 currency code of the amounts in the tax return. Always CLP.
"CLP"
Folio number of the declaration at the Chilean tax authority (SII).
"12345"
Fiscal year the tax return corresponds to.
2021
ID of the fiscal authority that received the declaration. Always cl_fiscal_sii.
"cl_fiscal_sii"
Figures of the tax return the taxpayer filed for the fiscal year, as reported by the Chilean tax authority (SII).
Show child attributes
Show child attributes
Taxpayer the declaration belongs to, identified by a Chilean tax ID (RUT).
Show child attributes
Show child attributes
¿Esta página le ayudó?