# Zitadel

{% hint style="info" %}
Refer to [Zitadel's documentation](https://zitadel.com/docs) on how to install it.
{% endhint %}

1. Log in to Zitadel's web interface.
2. Create a project.
3. Add a new application within the project.
4. Select **Web** for application type.

   <figure><img src="/files/J4Nqobx08Hi9aEwDI0CO" alt=""><figcaption></figcaption></figure>
5. Choose **Code** for authorization method.

   <figure><img src="/files/ltoxFF1bNnPdaCy9mf3J" alt=""><figcaption></figcaption></figure>
6. Enter a redirect URI for your Defguard instance. The URI is in the form `<DEFGUARD_DASHBOARD_URL>/auth/callback`, for example `https://defguard.example.com/auth/callback`. (If Defguard has been launched on the *localhost*, select **Development Mode** and enter `http://localhost:8000/auth/callback`). If you'd like to use OpenID enrollment through proxy, make sure to enter an additional URI here in the form of `<DEFGUARD_ENROLLMENT_URL>/openid/callback`.

   <figure><img src="/files/yIsOvE8Iiqd5oDO4D0RM" alt=""><figcaption></figcaption></figure>
7. **Create** the application.
8. Copy the provided **Client ID** and **Client Secret** and enter these in the Defguard's OpenID settings.
9. Finally, in the **Token Settings**, enable **User Info inside ID Token**.

   <figure><img src="/files/LFiP9qWGDAdhSPgkaFvt" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.defguard.net/1.6/features/external-openid-providers/zitadel.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
