Change the URL
With SDK 1.0 and later, the SDK selects the version itself. It calls
/v2/classify on the deployment your URL identifies. When that call answers 403, 404, or 405, the deployment may predate version 2, and the SDK calls /classify instead. It then derives each decision from the version 1 result. confidence and severity are null on those decisions. SDK versions before 1.0 call version 1.
For direct HTTP, keep any path prefix before /classify. The API key, headers, and error responses do not change.
Keep the request
A body accepted by/classify is accepted by /v2/classify with the same meaning. The legacy threshold and temperature request fields are not part of version 2.
Map the response
Version 2 returns no
outcome_scores or other score maps. Every key of a decision is always present and is null when empty.
Compare responses
Each pair shows the two versions’ responses for the same result. The version 1 bodies show the fields that map to version 2.Model block
Governance block
Batch
When confidence and severity are null
confidence and severity describe the Firewall’s assessment of the item, and are set only when that assessment is the reason for the block. Both are null:
- on an allow
- on a block that came from a governance policy
- on a block the Firewall reached without that assessment
action is block and source is model. Do not use these fields to decide whether to block.
Update enforcement
In version 1, a client stops an event whenprediction is MALICIOUS or governance.action is block. In version 2, action is the only field to enforce on: stop an event when action is anything other than allow. Apply that check to every item in results.