curl --request POST \
--url https://api.melso.ai/v1/companies/{company_id}/certificates \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"purpose": "<string>"
}
'import requests
url = "https://api.melso.ai/v1/companies/{company_id}/certificates"
payload = { "purpose": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({purpose: '<string>'})
};
fetch('https://api.melso.ai/v1/companies/{company_id}/certificates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "aeat_tax_compliance",
"status": "pending",
"requested_at": "2023-11-07T05:31:56Z",
"csv": "<string>",
"issued_at": "2023-11-07T05:31:56Z",
"findings": [
"<string>"
],
"document": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filename": "<string>",
"content_type": "<string>",
"size_bytes": 123,
"url": "<string>"
}
}{
"error": "lines[0].vat_rate must be 21, 10, 4 or 0",
"code": "invalid_invoice",
"request_id": "req_01JAB3K9X2"
}{
"error": "invalid token",
"code": "unauthorized",
"request_id": "req_01JAB3K9X2"
}{
"error": "The tax return changed or is not ready for approval",
"code": "version_conflict",
"request_id": "req_01JAB3K9X2"
}Request a certificate
Requests an official certificate for the company, such as being up to date with tax obligations (AEAT) or with the Social Security (TGSS), which lenders and public tenders ask for.
curl --request POST \
--url https://api.melso.ai/v1/companies/{company_id}/certificates \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"purpose": "<string>"
}
'import requests
url = "https://api.melso.ai/v1/companies/{company_id}/certificates"
payload = { "purpose": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({purpose: '<string>'})
};
fetch('https://api.melso.ai/v1/companies/{company_id}/certificates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "aeat_tax_compliance",
"status": "pending",
"requested_at": "2023-11-07T05:31:56Z",
"csv": "<string>",
"issued_at": "2023-11-07T05:31:56Z",
"findings": [
"<string>"
],
"document": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"filename": "<string>",
"content_type": "<string>",
"size_bytes": 123,
"url": "<string>"
}
}{
"error": "lines[0].vat_rate must be 21, 10, 4 or 0",
"code": "invalid_invoice",
"request_id": "req_01JAB3K9X2"
}{
"error": "invalid token",
"code": "unauthorized",
"request_id": "req_01JAB3K9X2"
}{
"error": "The tax return changed or is not ready for approval",
"code": "version_conflict",
"request_id": "req_01JAB3K9X2"
}Authorizations
Your partner secret key, mk_live_… for real companies or mk_test_…
for test companies. Keep it on your servers. See
Authentication.
Headers
A unique key, such as a UUID, that makes a retried create safe. Reusing a key with a different body is refused.
255Path Parameters
The company's ID. Every company-scoped call works in exactly this company.
Body
aeat_tax_compliance: up to date with tax obligations. tgss_compliance: up to date with the Social Security. aeat_census_status: census situation. aeat_vat_registration: registration in the register of exporters and intra-community operators (ROI).
aeat_tax_compliance, tgss_compliance, aeat_census_status, aeat_vat_registration Why it is needed, when the administration asks for it, such as public_procurement or subsidy.
Response
The request, pending until the administration issues it.
aeat_tax_compliance: up to date with tax obligations. tgss_compliance: up to date with the Social Security. aeat_census_status: census situation. aeat_vat_registration: registration in the register of exporters and intra-community operators (ROI).
aeat_tax_compliance, tgss_compliance, aeat_census_status, aeat_vat_registration negative: the administration issued it as not up to date; findings says why.
pending, issued, negative, failed The código seguro de verificación.
Show child attributes
Show child attributes