> For the complete documentation index, see [llms.txt](https://demcp.gitbook.io/demcp-integration-guide/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://demcp.gitbook.io/demcp-integration-guide/quick-configuration/quickstart.md).

# Connecting to the DefiLlama MCP Service

### Step 1: Connect Wallet

Visit the DeMCP official DApp: <https://dapp.demcp.ai/>, click "Login", and select a wallet.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FfHhdxwe418VIa81EZoPi%2Fimage.png?alt=media&amp;token=cb84202f-d778-47c2-861f-e98b78b96cd8" alt=""><figcaption></figcaption></figure>

After connecting your wallet, a signature request will automatically pop up. Sign it to complete the login successfully. We currently support login via **Solana** chain.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2Fw6d6edz8orYaL6oFDcAI%2Fimage.png?alt=media&amp;token=675fcd81-031b-4855-bc08-27ebb411074b" alt=""><figcaption></figcaption></figure>

### Step 2: Create an API Key

API key is used to verify your API requests. Please ensure to save your key properly and do not share it with others. If you suspect the key has been compromised, please immediately regenerate it.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2Fgu6pzenSD2uVaTxPuRYQ%2Fimage.png?alt=media&amp;token=f0d542b4-20b6-4fe2-9e36-4b846963dc4a" alt=""><figcaption></figcaption></figure>

Copy and save your **API Key** securely.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FIa3rdiTtpTs3qs0Ra0OU%2Fimage.png?alt=media&amp;token=f48619aa-fc31-4efb-98a9-220ece88b4df" alt=""><figcaption></figcaption></figure>

### Step 3: Obtain the DefiLlama MCP Configuration

1. Using the Cursor platform as an example, open <https://dapp.demcp.ai/mcp/2277>
2. In the **Install** section on the right, copy the provided JSON configuration data.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FZ90BaBAuchjen2UUcl4W%2Fimage.png?alt=media&amp;token=f1ac9bbf-be40-45e4-be7d-4b0795c22557" alt=""><figcaption></figcaption></figure>

3. **Important:** Replace `{API_KEY}` in the URL with the actual API key you obtained in Step 2.

* The replaced URL should look like: `https://gateway.demcp.ai/api/phala_defillama/123456/sse`
* Make sure to remove the curly braces and use only the API key value itself.

### Step 4: Configure Your Client

1. Open your client application (Cursor is recommended: <https://www.cursor.com/>).
2. Find the Setting.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2F0MiY0x1EOv1COeotziMw%2Fimage.png?alt=media&amp;token=739e6f95-40ce-42b3-b2dd-2e3ff6251e86" alt=""><figcaption></figcaption></figure>

3. Click on the **MCP** option.
4. In the MCP settings, **select Add New Global MCP Server.**

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FO37lB5Gd7QwyuW8OIoRa%2Fimage.png?alt=media&amp;token=e7484269-9c5d-4685-995a-c6bfa8e34ac2" alt=""><figcaption></figcaption></figure>

5. Paste the JSON configuration you obtained from DeMCP and press `Cmd + S` to save the configuration.

**Note:** If you have previously configured an MCP, make sure to paste only the internal configuration content. Remove the outer structure `{"mcpServers": {}}` and keep only the core configuration data.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FrEPHcBrvtDYrod6BDJCB%2Fimage.png?alt=media&amp;token=4331b10c-5366-47fd-9dbc-d54b9799587f" alt=""><figcaption></figcaption></figure>

### Step 5: Activate the Service

1. Return to the MCP settings page.
2. Locate the newly added **DefiLlama MCP** entry.
3. Click the **Refresh** button to activate the connection.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FcZcFwp6BOjVK3C8WAnWR%2Fimage.png?alt=media&amp;token=2306b711-7d36-417c-b395-96d35142e96f" alt=""><figcaption></figcaption></figure>

4. Select an LLM model that supports MCP, such as **GPT-4o, Claude 3.5, or Gemini 2.0**.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2Fdj6MG5tar30bnNtQtb3J%2Fimage.png?alt=media&amp;token=56c1bf34-7b4e-4eee-9120-97f69fc4e0c2" alt=""><figcaption></figcaption></figure>

### Step 6: Start Using the Service

After completing the configuration, you can immediately start using the DefiLlama data service. Try querying the TVL (Total Value Locked) data for **Lido** to experience the convenience of real-time financial data services.

<figure><img src="https://996349794-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHUFmfKF7gL7z1OMgpNXX%2Fuploads%2FOERA2iy18snE8fdhf0Ik%2Fimage.png?alt=media&amp;token=d55288e3-1a08-44c0-84c7-d97d6f911e25" alt=""><figcaption></figcaption></figure>

\----------------------------------------------------------------------------------------------------------------

Enjoy your experience!\
If you need any assistance, please feel free to contact our support team.(<https://t.me/DeMCPHelp>)
