Skip to Content
SDK referenceSession Ratings

Rate a session result

A governed action produces two different kinds of result. The SDK returns a typed result at the moment the action finishes. A session rating is feedback a person adds later, in the portal, once there is enough evidence to judge how the result performed.

Who can use this
Available to
DeveloperAdministratorGovernance EngineerCompliance OfficerBusiness OwnerAuditor

Developers handle the typed result in code. Portal ratings are available to any user whose role can rate the session.

Read the typed result in code

Every core SDK returns the same set of statuses. The names below are the wire values; each language exposes them through its own enum or constant.

StatusReleased valueMeaning
completedYesPolicy allowed the input and the output.
completed_with_warningYesPolicy allowed the action and attached a warning. Surface the message to the user.
transformedYesPolicy replaced the input or the output. The result also carries the effective input.
blockedNoPolicy stopped the input or the output. The portal shows this as Stopped by policy.
review_requiredNoPolicy asked for human review. The result carries a checkpoint to save.
cancelled_by_directiveNoA Stop directive ended the run.
cancelled_by_callerNoThe application cancelled the run.
timed_outNoThe run exceeded the SDK’s operation timeout.
failedNoThe SDK, the runtime, or the protected action failed closed.

Each result also carries a safe message, an evidenceReference, and, when a rule decided the outcome, the policyAction and reasonCode. Results without a value carry an execution state: not_started, completion_unknown, or result_withheld. Reconcile completion_unknown before retrying an external side effect.

Never release a value from a blocked result. Use the status, message, reason code, and evidence reference to handle a result without a value. The language guides show the exact property names: TypeScript, Python, .NET, Java, Go, and Rust.

When VeriProof pauses changes

During an incident, VeriProof can pause writes across the platform. Every core SDK handles the pause the same way.

  • Decisions still fail closed. If VeriProof can’t record the start or policy check, the result is failed with reason code platform_write_freeze and not_started, and the protected action doesn’t run. If it can’t record the release decision after the action ran, the result is failed, platform_write_freeze, and result_withheld. The message says when to try again. Other outages keep their usual result, so you can tell a pause from an outage.
  • Evidence waits instead of disappearing. Records of what already happened, such as a failed, timed-out, cancelled, or withheld run, stay in a bounded in-memory queue and are sent again after the Retry-After time until VeriProof accepts them. Resends use the original request, so VeriProof never records the same run twice. In Edge mode, terminal evidence uses the same queue.
  • The queue is bounded. It holds 256 items by default (the evidence buffer capacity option). When it is full, the oldest item is dropped and counted. Diagnostics report how many items are queued, how many were dropped, and the last error code. Queued evidence never authorizes an action.
  • Shut down cleanly. Shutting down the client tries every queued item once and reports how many could not be sent. Flushing sends the queue now and tells you whether anything is left.

Keep undelivered evidence across a restart

The queue lives in memory, and the SDK never writes evidence to disk. If your process may stop while a pause is still in effect, give the client an undelivered-evidence handler. At shutdown, after the last send attempt, the SDK passes the handler every item it still holds, oldest first. Each item is an opaque JSON text that carries the original request. Store the items wherever you keep evidence, then pass them back to the restore method when the process starts again. The client checks every item, rejects the whole batch if any item is invalid, and sends the rest through the normal queue. Because it sends the original bytes, VeriProof records each run once even if an item was already accepted.

The envelope contains evidence payloads; store it with the same protection as the evidence itself.

SDKHandler optionRestore method
TypeScriptonUndeliveredEvidencerestoreUndeliveredEvidence(items)
Pythonon_undelivered_evidenceawait restore_undelivered_evidence(items)
.NETOnUndeliveredEvidenceRestoreUndeliveredEvidence(items)
JavaonUndeliveredEvidence(handler)restoreUndeliveredEvidence(items)
GoOnUndeliveredEvidenceRestoreUndeliveredEvidence(items)
Ruston_undelivered_evidencerestore_undelivered_evidence(&items)

When the handler returns normally, shutdown no longer reports those items as undelivered. If it fails, or you don’t set one, shutdown reports the count as before.

Retry the refused action after the pause ends. Diagnostics show platform_write_freeze as the last error code while it lasts. The API reference describes the 503 response.

Rate the session in the portal

Open Sessions, select the session, and use Session Rating in the session detail view.

RatingUse when
GoodThe result met expectations
AcceptableThe result met the agreed minimum criteria
BadThe result did not meet expectations
UnknownThere is not enough evidence to rate the result

Select Note to record why you chose the rating, such as a false positive, an accepted exception, or a follow-up action. Saving a rating again replaces the earlier rating and note.

The SDKs do not send ratings. A rating is portal feedback attached to the recorded session after the fact. In sandbox mode the control is read-only and nothing is saved.

Human Review outcomes are different

This page is about a quality rating for a completed or observed session. A Human Review outcome determines what an application may do with a paused, protected action. That flow uses a signed callback, a durable receipt, and a separate application execution acknowledgment. The application owns its checkpoint, worker, and any resumed or revised work.

Use the Human Review callback reference for its outcome names, directives, resume modes, typed responses, cancellation, expiry, replay, and acknowledgment rules.

Review session ratings

Open Sessions, filter by rating when needed, and select a session to review its rating and note. Treat the rating as observed feedback, not as a replacement for the session’s recorded decision or typed result.

Last updated on