Observability
Two ids tie everything together
- The request id — every answer carries
X-Request-Id, and every refusal repeats it asrequestId. Log it with every call; it is what Anis needs to find your call. - The operation id — the id you chose for an order. Log it at every step, from storing the intent to storing the codes. It traces one purchase across your system and Anis.
What to alert on
| Signal | Why |
|---|---|
| Orders whose outcome is unknown — timeouts, lost connections, unverifiable answers, and refusals that may still complete | Each one must be resumed with the same operation id |
| Answers that could not be verified | Something between you and Anis changed an answer, a clock is badly out, or an Anis key rotation was missed. One short burst of unsigned 503s is Anis’s own signing being briefly unavailable |
invalid_credentials on every call |
The key was revoked or replaced, or the clock drifted |
rate_limited |
Your traffic is near a limit Anis staff set |
Never record
Your private key, signatures, signature bases, nonces, the enrolment token, or card codes (serials and vouchers) — anywhere: logs, traces, metrics or error reports.
With the .NET SDK
The SDK reports everything under one name, Anis.Partners.Sdk, for traces and for metrics, and logs through your
own logging:
builder.Services.AddOpenTelemetry()
.WithTracing(tracing => tracing.AddSource("Anis.Partners.Sdk"))
.WithMetrics(metrics => metrics.AddMeter("Anis.Partners.Sdk"));
| Metric | What it tells you |
|---|---|
anis.partners.order.outcomes |
Orders by outcome: completed, processing, replayed — and unknown, the one to alert on |
anis.partners.request.duration |
Every call, by route and status or refusal code |
anis.partners.signature.duration |
Time spent signing — a slow vault shows here |
anis.partners.response.verification.failures |
Answers thrown away, by the rule that failed |
anis.partners.signing_keys.fetches |
Fetches of Anis’s public keys; a rising refresh means a rotation |
Each call’s trace carries the route, the request id and, on orders, the operation id. The SDK never records any of the secrets above — its tests check every log line, trace and metric for them.
More in the .NET SDK page.