Skip to content

Concepts

Audit Logs

Credential access, policy decisions, provider calls, and lifecycle events with identity and correlation context.

An audit log is the canonical record of what Alter did and why. Credential retrievals, policy decisions, grant lifecycle events, provider calls, and administrative actions are written with the available identity and correlation context needed for compliance and forensic review.

Audit logging is always enabled; there is no disable flag. Credential-touching backend paths require an explicit success, failure, denial, or error audit terminal. Direct SDK provider calls queue their audit report after the provider response. Audit-write failures are isolated from the primary operation and emit critical diagnostics and failure metrics rather than replacing the operation’s result.

For every app.proxy_request():

  • Caller identity — the API key, agent identity, and caller attribution.

  • Grantee — the user, group, system, or agent the grant is issued to (the legacy wire name is principal). On a delegated call the grantee is the agent holding the delegation; the root grantee is who the access was originally granted to.

  • Grant — the grant_id, provider, and grant kind.

  • Request — method, URL, response status, latency, and available size metadata.

  • Context — application-supplied metadata: tool name, run ID, thread ID, reason.

  • Outcome — success, policy denial, provider error, network error.

  • Deciding policy rule — every policy decision names the rule that decided it: the rule that denied the call (including an IP allowlist the caller’s address is outside, an approval or step-up requirement, and every other rule that also denied), the rule that required an approval, or the rules that shaped a permitted call: obligations (approval, step-up, redaction) and restrictions it satisfied, such as an IP allowlist (decision_basis narrowed). A call that ran an operation which hands the caller a provider credential, because an operator’s credential_minting allowance allowed it, records the operation ids and the allowing rules under credential_minting, with decision_basis credential_minting_allowance for an allowance in "allow" mode, or approval when the call ran after a person approved it. A refusal of such an operation records the operation ids and the ones no allowance covers (needs_allowance). A call no rule restricted records an explicit decision_basis of no_restricting_rule rather than an invented rule.

  • Why a request was denied — a denial by a runtime policy rule or by the agent’s capability allowlist carries one plain sentence saying which control refused it and why, plus the structured detail behind it. Other denials — a suspended or revoked agent, a revoked or expired connection — record their reason without that sentence, and denials recorded before this explanation was added have none:

    • Agent capability check — the agent’s capability allowlist does not cover the connection. The record names the control (agent_capability_allowlist), the specific check that failed (provider_not_allowlisted, scopes_not_allowlisted, ceiling_empty, grant_scopes_malformed, chain_unresolvable, agent_missing, or managed_secret_not_allowlisted), the provider, the agent, and — for scopes_not_allowlisted — the missing_scopes the allowlist does not include. The scope names appear only in the audit record; the error the SDK raises (agent_scope_not_allowed) never contains them. Every delegation refused before it was created because the agent’s allowlist cannot use it (agent_allowlist_exceeded) is recorded with the same explanation — OAuth Connect sessions and their completion, managed-secret Connect approval, delegating from the Wallet, and onward delegation alike. For a managed secret the check is managed_secret_not_allowlisted and the record names the secret’s slug (secret_slug). A Connect session that dropped providers the agent cannot use records which ones in its creation record. A chain_unresolvable record that also carries unhandled_verdict marks a fault inside Alter, not a broken delegation chain: the request was refused to stay safe, retrying it does not help, and the record is the detail to send to Alter support.
    • Runtime policy — a policy rule refused the request. The record names the kind of rule (rule_type) and the level it is set at (rule_level: org, app, provider, managed_secret, group, agent, user, or grant), with a sentence that uses the same names the developer portal shows for them, such as “Blocked by a request condition rule at the application level: the request matched the condition it blocks.” The sentence is built from the rule’s kind, level, and outcome — never from request values.

    The developer portal shows this as Why this was denied at the top of the event’s details, with a link to where the control is changed (the agent’s page, or the Runtime Policies page that lists the rule). The Wallet shows the same explanation to the end user without developer-only detail, and links an account-level limit to the user’s Limits page. alter audit explain prints it from the command line.

Sensitive headers (Authorization, Cookie, AWS signing headers) are stripped before storage. The audit record stores call metadata — method, URL, status, latency, and request/response sizes when available — never the request or response body. Capturing request and response payloads is a separate, opt-in feature; see Request and response payload capture below.

For every grant lifecycle event:

  • Created, revoked, deleted, scope-drifted, policy-violated.
  • Who initiated the event (end user via Wallet, operator via portal, SDK call).
  • When an agent is granted access, or a delegation’s terms change: the delegation terms — the requested and applied scope constraint, whether the delegate may re-delegate, and the expiry. An update additionally records the previous terms, so the trail shows whether a delegation was narrowed, widened, or otherwise modified without reconstructing it from current grant state.
  • Every delegation event — including revocations, and the cascading teardowns that follow when a parent grant, group membership, secret, agent, or user is removed — identifies the delegation edge itself: the recipient agent (ID and name, snapshotted at write time so the record survives later agent deletion) and the delegated child grant alongside its parent grant. The event answers “which agent received — or lost — this access?” on its own, without correlating against current grant state. A cascade event describes one bulk teardown, so it lists the affected delegations along with the total number revoked; very large teardowns list a capped subset and state how many were not listed, so the recorded set is never mistaken for the complete one.

For every administrative action:

  • Provider configuration changes, API key mint/rotate/revoke, agent create/update/revoke, identity provider configuration.
  • Policy-rule changes, whoever makes them: operators in the portal or CLI, and end users who create, update, or delete their own policies in the Wallet. Each row names the changed rule’s id, so a rule is findable by id across both authoring surfaces.
  • Read-only administrative access, including grant/policy listings, captured-payload views, audit exports, and integrity checks. These rows are classified as Read and their count/offset payload is labeled Read Summary; it is never presented as a created resource or state change.

Successful administrative rows carry an effect classification: Read for data access and Write for state changes. An unsuccessful outcome overrides that intended effect and is classified as Error. An unknown successful action defaults to Write so a newly added mutation cannot disappear from compliance review.

For every user-provisioning event (the Provisioning tab in the portal’s Audit Logs view):

  • Users and groups created, updated, or deprovisioned — whether by an IDP webhook, a directory sync run, or a first sign-in.
  • Group membership transitions that change access: a member removed (group-grant access revoked) and a membership restored after the member reappears in the directory.
  • Each row records the originating path, the outcome (success, no-op, skipped, denied, error), and the reason.
  • A deprovisioning records a causation id on the triggering provisioning event (with the IDP event id or directory import run) and on every grant revocation, delegation revocation, and managed-secret revocation it caused, so the full consequence of one deprovisioning is retrievable by that id rather than by timing: searching an app’s audit log for the causation id returns exactly the rows that deprovisioning wrote.

By default, Alter records call metadata in the audit trail — never the request or response body. Capturing request and response payloads is a separate feature that is off by default and turned on per app by an admin in the developer portal under Settings → Payload Capture. Capture can be narrowed to specific agents or end users.

Capture applies wherever the audit trail sees the bodies:

Narrowing by end user behaves differently on the two execution paths, deliberately. A backend-executed call is matched against both end-user identities it knows — the grantee and the calling end user. A call the SDK executes and reports is matched against the grantee only: the caller identity on that report is client-asserted, and an unverified claim is never allowed to widen what a compliance surface records. So a capture list narrowed to a caller-side end user records nothing for SDK-executed calls; narrow by agent, or by the grantee, to cover both paths.

What is and isn’t stored:

  • The caller-supplied request body and the provider response body are captured. Both are size-capped, and an incomplete capture always says so: the stored payload carries a truncation flag and the original size on both execution paths. Calls the SDK executes and reports are capped by the SDK before it reports them — an oversize body is replaced by a placeholder noting its size, and a body that is not valid UTF-8 is replaced by a placeholder whatever its size — and that upstream truncation is recorded on the stored payload rather than being mistaken for a complete body. A captured body from that path is evidence of what was sent, not always a byte-exact copy. A deployment whose payload storage cannot hold both bodies at their full cap shortens them further, the larger first, and flags each shortened body as truncated with its original size.
  • Streamed calls and calls with a binary request body are never captured, whatever the capture setting, in either direction. Their rows still record status and byte counts.
  • A call that can hand over a credential, or that carries raw card data, is never captured. Any call the credential refusal would match (whether or not an allowance lets it through), and any call with a card number or security code in its body or query, records metadata only.
  • A call to an operation Alter has not reviewed is never captured. An unreviewed operation of the provider’s published API (one alter providers operations list shows as UNREVIEWED) may return a secret nothing has checked for, so its call is not captured, whatever the capture setting and whether or not a rule applies. Its row still records status and byte counts.
  • Calls to a provider with a managed SDK mask more. On managed operations, raw proxied calls and SDK-reported calls to such a provider, every field Alter’s reviewed inventory for the provider marks sensitive (an SSN, a bank account number, a tax file number) is stored masked in the request and the response, including fields the inventory locates only by operation, and binary bodies and multipart parts that are files are withheld, in both directions. A raw or SDK-reported call to such a provider whose path is outside its managed SDK’s operations is not captured, because the inventory names none of its fields.
  • The injected credential is never captured. The request body is recorded before Alter injects the credential, so a stored payload never contains the secret.
  • Other secrets in a body are redacted before it is stored. A body can carry credentials Alter did not inject: a token a provider issues and returns, or a password or API key the agent sends. In JSON, URL-encoded form (application/x-www-form-urlencoded), multipart (multipart/form-data, multipart/mixed, multipart/related and multipart/alternative), XML and YAML bodies, the value of any field whose name marks it as a secret (access_token, refresh_token, id_token, client_secret, password, api_key / apiKey, private_key, authorization, assertion, code_verifier, secret, token, their plurals such as api_keys, and similar names written in snake_case, camelCase, kebab-case or upper case) is stored as [REDACTED], whether it is a string, a number, or an object or array (every value inside it). Pagination cursors such as next_page_token and usage counts such as max_tokens are kept, and an object under auth, authorization, credentials or session keeps its other fields (a payment authorization’s amount stays readable). In any text body, values with a recognizable credential format (GitHub, GitLab, Slack, Stripe, OpenAI, Anthropic, npm, Google, SendGrid, Shopify and Hugging Face tokens, AWS access key IDs, Alter API keys and access tokens, JWTs, authorization values such as Bearer, Basic and Token, PEM and PGP private keys), the password in a URL such as postgresql://user:password@host, a secret-named query parameter in a URL, and a quoted or name=value secret-named value (client_secret=…, "password": "…") are also stored as [REDACTED]. Only those values change: the rest of the body keeps its exact bytes, including formatting and number spellings. The recorded size is the size of the body as sent or received, before redaction; the size cap applies to that original body, and the truncation flag says whether the stored body is incomplete. If a body cannot be redacted it is withheld, never stored as sent: the payload records that the body was withheld, with its original size. A multipart body is split into parts by the same strict rules Alter’s policy checks use, and each part is redacted by its name and its own type. A part whose value is not plain UTF-8 text (sent with a base64 or quoted-printable transfer encoding, or in a character set other than UTF-8 or ASCII, such as UTF-16) is stored as [REDACTED] whole, and so is a part whose Content-Type carries any parameter other than a plain charset (and boundary on a nested multipart part), such as an encoded charset*=utf-8''utf-16le, which some readers take as the character set. A part’s Content-Disposition, Content-Type and Content-Transfer-Encoding headers keep their values, with recognizable credentials in them stored as [REDACTED], and of their parameters only name, filename, filename*, boundary and charset keep their values; every other parameter, and every other part header (an Authorization or X-Api-Key line, for example), keeps its name and has its value stored as [REDACTED], unless the name itself has a recognizable credential format, in which case it is not stored. A kept value that holds a recognizable credential once percent-decoded (as in filename*=UTF-8''…) is stored as [REDACTED] whole. A part whose name readers interpret differently (an encoded or continued name*, name*0 or filename*0, or an unquoted name with a space, quote or other separator, such as name= "to", or an unquoted name or file name with whitespace other than a space or tab before or after it) is stored as [REDACTED] whole, headers included, and so is a part whose headers would grow past the length a reader accepts once redacted, after first keeping only the Content-Disposition, Content-Type and Content-Transfer-Encoding headers and their kept parameters. A multipart body is withheld whole when it cannot be read unambiguously: text before the first boundary or after the last, the boundary string inside a part, a line break other than CRLF, a part header that cannot be read, a Content-Type whose boundary is not unambiguous (a repeated parameter, an encoded boundary* or any other parameter except boundary, charset, type, start and start-info, or one of those whose value mentions a boundary; a boundary, quoted or not, that contains boundary= in any case, or contains a lowercase boundary when the parameter is not written as lowercase boundary=, since some servers search the header for that word and read a different boundary after it; an unquoted boundary containing ,, a space, " or \, which some servers end early, or written with a space, tab or other whitespace before or after it, which some servers read as part of the boundary, or one containing another separator such as =, /, ? or : when a line of the body would be a boundary to a server that reads only the part before that separator; or a quoted one containing ,, ; or a space), a charset other than UTF-8 or ASCII on the body itself, a charset on the body or a part written with whitespace other than a space or tab before or after it, or forms nested more than three deep. A multipart body captured earlier in such a shape is withheld when it is viewed. When a multipart body is longer than the size cap, the complete parts that fit are stored redacted, and the part the cap cuts through keeps its headers (redacted as above) with its value replaced by [REDACTED] before it is stored, so a stored body never holds part of a value. Payloads captured before redaction was introduced are redacted when they are viewed. Binary response bodies (images, audio, video, fonts, and other bodies that are not text) of providers without a managed SDK are stored as received. A secret with no recognizable format under a field name that does not mark it as one (for example a token returned in a field called value, an AWS secret access key under a neutral name, or an unquoted YAML-style password: … line in a body that is not YAML) cannot be recognized, so narrow payload capture away from agents whose calls set or rotate credentials on a provider without a managed SDK.
  • Captured payloads are a diagnostic tier, not part of the permanent audit record: the default retention window is 30 days, after which they are deleted. They are never included in audit exports.
  • Every captured payload records where its bytes came from, and the portal labels it: proxy-captured means Alter observed the bytes itself (it sent the request and received the response); client-reported means the SDK executed the call and reported the bodies, so they are the application’s own account of the call rather than something Alter witnessed. The two are never presented interchangeably.

Captured bodies are visible to app admins from the audit log detail view in the developer portal.

Alter’s audit model is built around two questions that traditional credential systems struggle with:

  • “What was Alice’s data used for?” — calls carrying Alice’s app-scoped principal can be filtered by end-user identifier and followed through related keys, grants, and traces.
  • “What did Agent X access?” — calls attributed to Agent X can be examined in the app’s views grouped by actor and trace.

The developer portal exposes end-user, managed-agent, originally-granted-to, provider, action, policy-decision, and time filters, plus key, trace, and thread drill-downs. The CLI supports app, actor, root-grantee, provider, action, policy-decision, and time filters with actor, trace, and thread drill-down commands. The managed-agent filter and an agent’s drill-down list the events the agent performed together with every delegation made to it: a delegation’s creation, updates, revocation and refusals appear there even before the agent uses it.

When a user delegates access to an agent, and that agent shares it onward, each call is made by the agent at the end of the chain, but the access traces back to the grantee of the grant it was first delegated from: the root grantee. That is the user who delegated it, or the group when a member delegated a group’s grant. When a user, group or agent used its own grant directly, the root grantee is that user, group or agent.

The Originally granted to filter (on the portal’s Access & Requests and All Activity tabs; alter audit list --root-grantee <id> in the CLI) narrows the audit trail, and an export, by root grantee. Pick the user, group or agent (deprovisioned users and revoked agents included), or paste its ID.

Who performed an event, and on whose behalf

Section titled “Who performed an event, and on whose behalf”

Every event written under the audit record contract (attribution_version 2) describes the people and identities involved with the same four terms, under the same field names in every export, whatever kind of event it is: the grantee (the identity the event’s grant is issued to), the root grantee (who the access was originally granted to), the actor (who performed the event: the agent, the application, an operator, an end user, or the platform) and the subject (the person the event was performed for, or by: the approver on a delegation approval). An event carries each fact it has: the grantee and the root grantee whenever the grant and its delegation chain were identified (an attempt refused before then names neither), and the subject only when the event was performed for or by a person. The detail view shows them as Granted to, Originally granted to, Performed by (with the channel: SDK, Dashboard, CLI, End user for the Wallet and hosted Connect pages, or System) and On behalf of, and a human decision’s event names who requested it under Requested by.

Today the search is partial. Every filtered response says so in its root_grantee_coverage field, and a filtered export carries the same value in a response header. The value is contract_and_legacy_direct, and the portal and the CLI show what it means:

Records that carry attribution_version 2 are found wherever they name their root grantee: credential use, direct or through a delegation, refreshes, provider calls, grant and delegation lifecycle events, and approvals. Of older records, which carry no attribution_version, only token and managed-secret records of the user’s, group’s or agent’s direct use of its own grant are found. Attempts refused before the grant or its delegation chain was identified, Connect session requests, and older records of every other kind are not included.

Existing records are never filled in later, so an empty result does not mean the access was never used. A response without a root_grantee_coverage value comes from a backend that predates the filter, so its rows are the unfiltered trail. In that case alter audit list --root-grantee prints no rows, says on stderr that the filter was not applied, and exits 1. The portal shows an error in place of the results instead of the unfiltered rows, and an export downloads nothing and says the filter was not applied. A root_grantee_coverage value the portal or the CLI does not recognize still marks the result as partial, so both show a general partial-result notice naming the value.

The trail has two planes, and they answer to different roles.

Runtime rows — credential retrievals, provider calls, policy decisions, grant lifecycle, approvals, identity assertions, policy changes end users make in the Wallet, and the trace / thread / agent views built on them — are organization-scoped and readable by every member of the organization. Members build the agents that produce these rows, so they need them to debug their own work.

Management rows — who created or revoked an API key, changed an identity provider, edited a policy, or archived an app, together with the acting operator’s identity and the before/after values — are the record used to detect insider misuse. They are scoped to organization admins. A non-admin member sees only the management rows they produced themselves, which keeps their own history available without exposing anyone else’s.

This matches how comparable platforms treat an administrative audit log: GitHub restricts the organization audit log to owners, Okta’s System Log to admin roles, and Slack’s audit API to org owners, while everyday request logs stay broadly readable.

A narrowed view always announces itself — the portal shows a notice above the feed, the CLI prints one to stderr, and a narrowed export carries an X-Audit-Management-Visibility header — so a short result set is never mistaken for a quiet month.

Two surfaces are admin-only outright rather than narrowed, because they produce or verify the organization’s compliance evidence rather than showing a view of it: bulk export (see below) and the integrity check that re-verifies each record’s tamper-evident hashes: its content hash and, on credential records that carry one, a lineage hash over the attribution fields the content hash does not cover (the access path, delegation chain, grantee and root grantee). Placing a legal hold and revealing a captured payload are admin-only for the same reason.

  • Developer portal — every app has an Audit Logs view with filtering, search, and export.
  • End-user Wallet — each end user sees the app-scoped slice of the audit trail concerning their own grants, including the application’s reason when supplied. Wallet users are not organization members and never see the management plane.
  • Export — see Audit log export for downloads, CLI ingestion, telemetry mirroring, and SIEM delivery.

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand how our website, product, and documentation are used.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

Advertising

Shares visits and sign-ups with Meta, Reddit, and X so we can measure which of our ads work.

You can change these choices at any time from Cookie settings.