コスタリカ — 交通違反
コスタリカの交通違反照会は 1 枚のナンバーの COSEVI 反則を読みます。plate は必須で 3–6 文字です。検証失敗は MissingParameter ではなくコード 409:invalid_params の HTTP 409 です。反則の無いナンバーは 404 NotFound です。
応答に含まれる項目
plateとtotalRecords- 状態と金額のある
infractions[]
用途
- 車両登録の前に反則を確認します。
- 3–6文字でないナンバーを拒否します。
- 各反則の合計額を読みます。
API リファレンス
Endpoint
GET https://api.verifik.co/v2/cr/traffic-infractions
一致には plate、totalRecords、および系列、番号、日付、状態、機関、金額を持つ infractions があります。
Headers
| 名前 | 値 | 説明 |
|---|---|---|
| Content-Type | application/json | リクエスト形式 |
| Accept | application/json | レスポンス形式 |
| Authorization | Bearer <token> | クライアント JWT |
Parameters
| 名前 | 型 | 必須 | 例 | 説明 |
|---|---|---|---|---|
plate | string | はい | 123456 | ナンバー。3–6文字、空白なし。無い、または長さが違うとコード 409:invalid_params です。 |
Request
- Node.js / JavaScript
- Python
- cURL
import axios from "axios";
const options = {
method: "GET",
url: "https://api.verifik.co/v2/cr/traffic-infractions",
params: {
plate: "123456",
},
headers: {
Accept: "application/json",
Authorization: "Bearer <your_token>",
},
};
try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error.response ? error.response.data : error.message);
}
import requests
url = "https://api.verifik.co/v2/cr/traffic-infractions"
headers = {
"Accept": "application/json",
"Authorization": "Bearer <your_token>",
}
params = {
"plate": "123456",
}
response = requests.get(url, headers=headers, params=params)
print(response.json())
curl -X GET "https://api.verifik.co/v2/cr/traffic-infractions?plate=123456" \
-H "Accept: application/json" \
-H "Authorization: Bearer <your_token>"
Response
- 200 (レコードあり)
- 409 (パラメータ不足)
- 404 (該当なし)
- 401 (未認証)
- 500 (情報源が利用不可)
{
"data": {
"plate": "123456",
"totalRecords": "1",
"infractions": [
{
"series": "1996",
"number": "12052",
"plate": "123456",
"status": "CANCELADA",
"totalAmount": "2000.00"
}
]
},
"signature": {
"dateTime": "November 27, 2026 12:00 PM",
"message": "Certified by Verifik.co"
}
}
{
"code": "409:invalid_params",
"message": "\"plate\" length must be at least 3 characters long"
}
{
"code": "NotFound",
"message": "Record not found."
}
{
"code": "UNAUTHORIZED",
"message": "Authentication required"
}
{
"code": "InternalServerError",
"message": "The official source is temporarily unavailable. Please retry shortly."
}
注意
plateは 3–6 文字です。- 不正なナンバーはコード
409:invalid_paramsです。 - そのナンバーに反則が無いと 404
NotFoundです。 Authorizationヘッダーに Bearer JWT を付けます。- JSON サンプルは項目の形を示します。実呼出しは送った値のレコードを返します。
- キャッシュ迂回フラグは送りません。このページはクライアント向けパラメータだけを説明します。
サンドボックス
| シナリオ | パラメータ | 結果 |
|---|---|---|
| 情報源に記録あり | plate: "123456" | 反則のある 200。 |
| 必須値が無い | Omit plate | コード 409:invalid_params の 409。 |
| 不明な値 | plate: "ABC" | COSEVI に反則が無いと 404 NotFound。 |
401 when the bearer token is missing or rejected.