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

# useWaitingParticipants

> Returns an object containing an array of all participants waiting for access to the call, along with methods to grant or deny access.

`useWaitingParticipants(params?): Object`

`useWaitingParticipants` can also be used to set up optional callbacks for [`waiting-participant-added`](/reference/daily-js/events/participant-events#waiting-participant-added), [`waiting-participant-updated`](/reference/daily-js/events/participant-events#waiting-participant-updated), and [`waiting-participant-removed`](/reference/daily-js/events/participant-events#waiting-participant-removed) events.

## Parameters (optional)

An object with the following properties:

<ParamField body="onWaitingParticipantAdded" type="Function">
  Callback for the [`waiting-participant-added`](/reference/daily-js/events/participant-events#waiting-participant-added) event.
</ParamField>

<ParamField body="onWaitingParticipantUpdated" type="Function">
  Callback for the [`waiting-participant-updated`](/reference/daily-js/events/participant-events#waiting-participant-updated) event.
</ParamField>

<ParamField body="onWaitingParticipantRemoved" type="Function">
  Callback for the [`waiting-participant-removed`](/reference/daily-js/events/participant-events#waiting-participant-removed) event.
</ParamField>

## Return value

An object with the following properties:

<ResponseField name="waitingParticipants" type="Object[]">
  Details waiting participants, see [`waitingParticipants()`](/reference/daily-js/instance-methods/waiting-participants).
</ResponseField>

<ResponseField name="grantAccess" type="Function">
  Can be used to admit entry to waiting participants. Accepts `'*'` to admit all participants, or a `string` `session_id` to admit a specific participant.
</ResponseField>

<ResponseField name="denyAccess" type="Function">
  Can be used to deny entry to waiting participants. Accepts `'*'` to deny all participants, or a `string` `session_id` to deny a specific participant.
</ResponseField>

## Example

```jsx theme={null}
import { useWaitingParticipants } from '@daily-co/daily-react';

export const UseWaitingParticipantsDemo = () => {
  const { waitingParticipants } = useWaitingParticipants();

  return <div>Waiting participants: {waitingParticipants.length}</div>;
};
```

## See also

<CardGroup>
  <Card title="Hooks" icon="code" iconType="solid">
    * [useParticipant()](/reference/daily-react/use-participant)
    * [useParticipantIds()](/reference/daily-react/use-participant-ids)
    * [useParticipantProperty()](/reference/daily-react/use-participant-property)
    * [useLocalSessionId()](/reference/daily-react/use-local-session-id)
    * [useParticipantCounts()](/reference/daily-react/use-participant-counts)
    * [useActiveParticipant()](/reference/daily-react/use-active-participant)
    * [useActiveSpeakerId()](/reference/daily-react/use-active-speaker-id)
    * [useLocalParticipant()](/reference/daily-react/use-local-participant)
  </Card>

  <Card title="daily-js methods" icon="code" iconType="solid">
    * [waitingParticipants()](/reference/daily-js/instance-methods/waiting-participants)
    * [updateWaitingParticipant()](/reference/daily-js/instance-methods/update-waiting-participant)
  </Card>

  <Card title="Events" icon="bolt" iconType="solid">
    * [waiting-participant-added](/reference/daily-js/events/participant-events#waiting-participant-added)
    * [waiting-participant-updated](/reference/daily-js/events/participant-events#waiting-participant-updated)
    * [waiting-participant-removed](/reference/daily-js/events/participant-events#waiting-participant-removed)
  </Card>
</CardGroup>
