Error: unknown_field
The request body includes a field the schema does not allow.
unknown_field
unknown_fieldHTTP status: 400
The request body contains a field name that the API schema does not recognize. The API rejects unknown fields instead of silently ignoring them.
Why this happens
- A field was renamed in a newer SDK version and the old name is still being sent (e.g.,
genderafter thesexmigration in SDK v0.5.1). - The request was hand-crafted or built from outdated documentation.
- A typo in the field name.
- You are sending a field that is valid on a different endpoint.
What to do
- Read the
paramfield in the error response — it contains a JSON Pointer (e.g.,/gender) identifying the unknown field. - Remove the field or rename it to the current canonical name.
- Consult the API Reference for the current field list for the endpoint you are calling.
- If you are using an SDK, upgrade to the latest version — the SDK enforces current field names at the type level.
Example response
{
"type": "https://zyins.isaapi.com/errors/unknown-field",
"title": "Unknown field",
"status": 400,
"detail": "Request body contains an unknown field '/gender'. The canonical field name is 'sex' (since v0.5.1).",
"code": "unknown_field",
"advice_code": "remove_or_rename_field",
"param": "/gender",
"request_id": "req_01HZK2N5GQR9T8X4B6FJW3Y1AS"
}SDK exceptions
| Language | Exception class |
|---|---|
| TypeScript | IsaUnknownFieldError |
| Python | IsaUnknownFieldError |
| Go | *zyins.UnknownFieldError |
| PHP | Isa\Sdk\Zyins\Exception\IsaUnknownFieldException |
| C# | IsaUnknownFieldException |
See also
Updated about 10 hours ago