校验意大利税号(codice fiscale),并与个人信息比对
POST
/v1/validate/fiscal-code
const url = 'https://api.vimine.network/v1/validate/fiscal-code';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"code":"example","first_name":"example","last_name":"example","gender":"M","date":"2026-04-15","place":"example","country":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.vimine.network/v1/validate/fiscal-code \ --header 'Content-Type: application/json' \ --data '{ "code": "example", "first_name": "example", "last_name": "example", "gender": "M", "date": "2026-04-15", "place": "example", "country": "example" }'检查结构 + 校验码;提供 first_name / last_name / date / place 或 country 时,还检查个人信息是否一致——并说明税号本身包含什么。入会表单执行相同的检查,但不含性别(那里不比对性别)。
请求体必填
章节“请求体必填”媒体类型application/json
object
code
必填
税号(codice fiscale,16 个字符)
string
first_name
string
last_name
string
gender
string
date
出生日期
string 格式: date
place
出生地:在意大利出生的人填市镇(comune)
string
country
出生国,ISO 3166-1 alpha-2。在意大利出生的人,税号中包含的是市镇;其他所有人的税号则只包含国家:IT 以外的任何值都与该国家比对,并忽略 place
string
响应
章节“响应”200
章节“200”校验结果
媒体类型application/json
object
valid
boolean
error
string
mismatches
当 error 为 mismatch 时,与税号不一致的项
Array<string>
hints
names_swapped:姓和名互换后,税号即可对上
Array<string>
birth_date
税号本身包含的出生日期
string 格式: date
birth_country
税号本身包含的出生国,ISO 3166-1 alpha-2(出生于意大利市镇则为 IT)
string
示例
{ "error": "invalid", "mismatches": [ "lastName" ], "hints": [ "names_swapped" ]}400
章节“400”请求无效
媒体类型application/problem+json
object
type
必填
string 格式: uri
title
必填
string
status
必填
integer
detail
string
code
必填
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
示例自动生成
{ "type": "https://example.com", "title": "example", "status": 1, "detail": "example", "code": "example", "request_id": "example", "errors": [ { "field": "example", "code": "example", "message": "example" } ]}404
章节“404”未找到
媒体类型application/problem+json
object
type
必填
string 格式: uri
title
必填
string
status
必填
integer
detail
string
code
必填
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
示例自动生成
{ "type": "https://example.com", "title": "example", "status": 1, "detail": "example", "code": "example", "request_id": "example", "errors": [ { "field": "example", "code": "example", "message": "example" } ]}429
章节“429”已触发速率限制
媒体类型application/problem+json
object
type
必填
string 格式: uri
title
必填
string
status
必填
integer
detail
string
code
必填
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
示例自动生成
{ "type": "https://example.com", "title": "example", "status": 1, "detail": "example", "code": "example", "request_id": "example", "errors": [ { "field": "example", "code": "example", "message": "example" } ]}500
章节“500”内部错误
媒体类型application/problem+json
object
type
必填
string 格式: uri
title
必填
string
status
必填
integer
detail
string
code
必填
string
request_id
string
errors
Array<object>
object
field
string
code
string
message
string
示例自动生成
{ "type": "https://example.com", "title": "example", "status": 1, "detail": "example", "code": "example", "request_id": "example", "errors": [ { "field": "example", "code": "example", "message": "example" } ]}