> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bijection.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Debugging authentication

If a call arrives as an `anonymous` principal, check that the client was connected with
an auth adapter: `connect(url, { token: auth })`. In React, feed
the adapter its provider's state in a component inside the provider with
`useClientAuth(auth, useAuth())`. With Bijection Auth, also pass the
[HTTP and live connection proofs](https://docs.bijection.com/access/authentication/providers/bijection-auth#quick-start).
Check that the deployment verifies the issuer and audience in
`bijection/sign-in.ts`. A server request needs its own client, connected
with that user's token.

Inside an admitted function, `ctx.frame.as` shows who the host verified:
`kind` is `anonymous` for a signed-out frame. A verified principal still needs
a live grant of a role that the function's `allow` names; without one the
client sees a `Disallowed` refusal. A `Forbidden` refusal carries `guard`, the path of the
guard that refused. See [Identity in functions](https://docs.bijection.com/access/authentication/functions.md)
and [Grants](https://docs.bijection.com/access/grants.md).

If an email invitation is refused after sign-in, check that the recipient
used the addressed email and that their source supplies
[trusted verified email](https://docs.bijection.com/access/authentication#trust-verified-email-for-invitations).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.