Skip to main content

Errors and troubleshooting

Fix common errors with consent receipts, permissions and LiveKit recordings.

Enzuzo Consent Ledger records consent. The LiveKit reference integration uses those records to start and stop recording.


When an outcome is uncertain, the integration treats it as not permitted. Most issues come from a pending receipt, mismatched IDs or an unconfirmed recording state.

Error types

Error

Cause

What to do

ConsentValidationError

Bad input or options, or a revision not greater than the current one

Return HTTP 400 or 409 and ask the caller to reload

ConsentStoreError

The consent store failed; the original error is its cause

Return HTTP 503. Nothing was confirmed.

LedgerHttpError

Bad Consent Ledger settings, or a read from Consent Ledger failed. Has a code. Writes never throw.

Check the error code, Ledger ID and token

PostgresStoreError

A PostgreSQL query failed or a row was invalid. Has code, table and constraint.

Log the code; check grants and connectivity

DrizzleStoreError

The same as above for the Drizzle stores, plus dialect (postgres or sqlite)

Log the code; check grants, connectivity or SQLite locking

TypeError

A missing or invalid option passed to a setup function

Fix the configuration

For errors returned by the Consent Ledger API itself, see Errors. For every function and its results, see the LiveKit API reference.


Troubleshooting

Consent stays pending

Consent Ledger writes records asynchronously, so a receipt may not be readable right away. Call refreshConfirmation() to check again. Do not resubmit the same decision.

Consent Ledger returns an authentication error

Check that the token is valid, belongs to the ledger's owner and has the ledger:read scope. Then confirm the Ledger ID.

Recording does not start

Check each of these:

  • The participant's current decision is accept, and its receipt is confirmed. checkPermission() returns { permitted: false, blocked: [...] } with a reason for each blocked participant.

  • The sessionId matches the LiveKit room name, and the participantId matches the LiveKit identity.

  • The recording controller and storage destination are configured.

  • Your app has made an explicit start request, if your workflow needs one.

Recording started but no media yet

A started result means LiveKit accepted the start and reports a starting or active recording. It does not guarantee media is already flowing. Wait for LiveKit's egress events before treating the recording as active.

Recording is in an unknown state

A request to LiveKit can succeed even if its response was lost. Do not send another start request. Run reconcile() and check the existing recording's status.

Recording keeps showing as stopping

Stopping a LiveKit recording takes time to finalize. Wait for a final state. If shutdown cannot be confirmed, escalate to your operator.

Did this answer your question?