<!-- llms.txt: https://workos.com/llms.txt -->

# Directory Sync Widget

import * as directorySync from "./directory-sync.props";
import { PropsTableHydrator } from "../../../components/props-table-hydrator";

![Directory Sync Widget screenshot](https://images.workoscdn.com/images/ad6ecb52-d450-4778-b9b8-239f74b58cbc.png)

The `<DirectorySync />` widget enables users to manage Directory Sync connections in the Admin Portal. It displays the directory status, metadata, and callout messages.

In order to use the Directory Sync widget, a user must have a role that has the `widgets:dsync:manage` permission.

:::code-group

```js language="js" title="Widget Token" tab="js-1"
import { DirectorySync, WorkOsWidgets } from '@workos-inc/widgets';

/**
 * @param {string} authToken - A widget token that was fetched in your backend. See the
 * "Tokens" section of this guide for details on how to generate the token
 */
export function AdminPortal({ authToken }) {
  return (
    <WorkOsWidgets>
      <DirectorySync authToken={authToken} />
    </WorkOsWidgets>
  );
}
```

:::

## API Reference
