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

# PendingConsent

> Describes all the properties and methods available to customize the Universal Login `pending-consent` screen.

The PendingConsent class implements the `pending-consent` screen functionality. This screen is a waiting room displayed during Rich Authorization Requests (RAR) flows when no `customized-consent` prompt is configured. The user approves or denies the request off-browser through the My Account experience while this screen polls for the outcome.

![ACUL Pending Consent](https://mintlify.s3.us-west-1.amazonaws.com/auth0/docs/images/acul/pending-consent.png)

## Constructors

Create an instance of PendingConsent screen manager:

```typescript Example theme={null}
import PendingConsent from '@auth0/auth0-acul-js/pending-consent';
const pendingConsentManager = new PendingConsent();
const control = pendingConsentManager.pollingManager({
  intervalMs: 5000,
  onCompleted: () => pendingConsentManager.continue(),
});
control.startPolling();
```

The constructor throws an error if the Universal Login Context isn't available or if the current screen isn't `pending-consent`.

## Properties

**branding** `[BrandingMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/BrandingMembers)`

Provides branding-related configurations, such as branding theme and settings.

**client** `[ClientMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/ClientMembers)`

Provides client-related configurations, such as `id`, `name`, and `logoUrl`, for the `pending-consent` screen.

**countryCodes** `[CountryCodesMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/CountryCodesMembers)`

Provides country code data for phone number entry, such as `available` and `recommended`, for the `pending-consent` screen.

**experiment** `[ExperimentMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/ExperimentMembers)`

The active [Experiment Center](https://auth0.com/docs/customize/experiment-center) experiment for this screen, or `null` when no experiment is active (or the screen has not opted in via `context_configuration`).

**organization** `[OrganizationMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/OrganizationMembers)`

Provides information about the user's Organization, such as `id` and `name`.

**prompt** `[PromptMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/PromptMembers)`

Contains data about the current prompt in the authentication flow.

**screen** `[ScreenMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/ScreenMembers)`

Contains details specific to the `pending-consent` screen, including its configuration and context.

**tenant** `[TenantMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/TenantMembers)`

Contains data related to the tenant, such as `id` and associated metadata.

**transaction** `[TransactionMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/TransactionMembers)`

Provides transaction-specific data for the `pending-consent` screen, such as active identifiers and flow states.

**untrustedData** `[UntrustedDataMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/UntrustedDataMembers)`

Handles untrusted data passed to the SDK, such as user input during the consent flow.

**user** `[UserMembers](/docs/libraries/acul/js-sdk/Screens/interfaces/UserMembers)`

Details of the active user, including `username`, `email`, and `roles`.

## Methods

**continue** `Promise\<void\>`

Continues the flow after the user approves or denies the consent off-browser. Auth0 applies the outcome, so there are no separate accept or deny methods. If the consent is still pending, Auth0 renders this screen again.

```typescript Example theme={null}
import PendingConsent from '@auth0/auth0-acul-js/pending-consent';
const pendingConsentManager = new PendingConsent();
await pendingConsentManager.continue();
```

**pollingManager** `[MfaPushPollingControl](/docs/libraries/acul/js-sdk/Screens/interfaces/MfaPushPollingControl)`

Starts and manages polling for the pending consent status. Polling checks the endpoint at the specified interval until the user approves or denies the consent, then calls `onCompleted` and stops. Call `continue()` from `onCompleted` to advance the flow. HTTP 429 responses are handled internally: polling waits for the rate limit to reset before retrying.

```typescript Example theme={null}
import PendingConsent from '@auth0/auth0-acul-js/pending-consent';

const pendingConsentManager = new PendingConsent();

// Poll every 5 seconds until the consent is approved or denied off-browser
const control = pendingConsentManager.pollingManager({
  intervalMs: 5000,
  onCompleted: () => pendingConsentManager.continue(),
  onError: (error) => console.error('Polling error:', error),
});

control.startPolling();

// Later, cancel polling if needed
control.stopPolling();
```

Polling stops after a network error or a non-200 response other than 429. Offer a manual fallback, such as a "Try again" button that calls `continue()`, and hide the button while polling runs.

**Method Parameters**

**Parameters**

**options**

[MfaPollingOptions](https://auth0.com/docs/libraries/acul/js-sdk/Screens/type-aliases/MfaPollingOptions).

**intervalMs?** `number`

The polling interval in milliseconds. Defaults to the SDK's internal value, typically 5000 ms.

**onCompleted?** `() =\> void`

Called once when the consent has been approved or denied.

**onError?** `(error: Error) =\> void`

Called when a polling error occurs. Polling stops after an error.
