> For the complete documentation index, see [llms.txt](https://ayakaleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ayakaleaf-pro.ayaka.space/on-premises/configuration/overleaf-toolkit/zotero-integration.md).

# Zotero Integration

{% hint style="info" %}
This feature is initially developed by [davrot](https://github.com/davrot) and [yu-i-i/overleaf-cep](https://github.com/yu-i-i/overleaf-cep), modified by [ayaka-notes/overleaf-pro](https://github.com/ayaka-notes/overleaf-pro) with OAuth. It is introduced from v6.2.0 and later. It's still in beta status. We need your feedback if you have any problem.
{% endhint %}

<div data-with-frame="true"><figure><img src="/files/aroRoexObZHHVDl5sbQq" alt=""><figcaption></figcaption></figure></div>

<div data-with-frame="true"><figure><img src="/files/ka14obobsGwT8N4xuzwB" alt=""><figcaption></figcaption></figure></div>

### Setup Zotero Integration

1. Open [this link](https://www.zotero.org/oauth/apps) to create a Zotero OAuth client (as image shows)
2. Choose **Application Type**: **Browser**
3. Setup Callback URL with your `${OVERLEAF_SITE_URL}/user/zotero/oauth/callback`
4. Configure your `config/variables.env`

<figure><img src="/files/tXoaogRdLBtm7Sr7ytK7" alt="" width="375"><figcaption></figcaption></figure>

{% code title="config/variables.env" %}

```dotenv
#################
#    Zotero     #
#################
# 'zotero' must be in ENABLED_LINKED_FILE_TYPES (set in develop/docker-compose.yml)
ENABLED_LINKED_FILE_TYPES=project_file,project_output_file,url,zotero

# From a Zotero OAuth client (register at https://www.zotero.org/oauth/apps)
# Application Type: Browser 
# Callback URL -> ${OVERLEAF_SITE_URL}/user/zotero/oauth/callback
ZOTERO_CLIENT_ID=
ZOTERO_CLIENT_SECRET=
# Encrypts the Zotero API key in mongo (set in dev to avoid writing a key file
# to /var/lib/overleaf/data, which the dev web container can't create)
# How to generate: `openssl rand -hex 32`
ZOTERO_CIPHER_PASSWORD=dev-zotero-cipher-password
# Optional: route the module's server-side Zotero requests (OAuth + API) through
# an HTTP proxy (must be reachable from the web container; same as github-sync)
# http://10.0.0.1:10808
# (Optional) ZOTERO_PROXY_URL=
```

{% endcode %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://ayakaleaf-pro.ayaka.space/on-premises/configuration/overleaf-toolkit/zotero-integration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
