validate_postal_code
Validate postal codes for address verification in forms, orders, and data processing using country-specific validation rules.
Instructions
Check whether a postal code exists in a given country.
Use this when someone wants to verify if a postal code is valid before processing an order, form, or address.
Args: postal_code: The postal code to validate country: ISO 3166-1 alpha-2 country code. Defaults to "US".
Returns: Whether the postal code is valid or invalid.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"postal_code": "<postal_code>"
},
"name": "validate_postal_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| postal_code | Yes | ||
| country | No | US |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |