Dify
Protect your Dify AI applications with Trappr by connecting through Dify's OpenAI-compatible custom model provider. All LLM calls route through the Trappr Gateway with zero changes to your Dify apps or workflows.
How Dify model providers work
Dify is not a workflow automation tool — it's an LLM application builder. You build apps inside a Dify workspace: Chatbots that answer questions, Agents that use tools, Workflows that chain LLM nodes visually, and Text Generators for structured outputs. Each app runs on a configured model provider.
The critical difference from n8n or Make: the model provider is configured once at the workspace level — not per-workflow, not per-node. When you add Trappr as a custom provider and an app's model is switched to it, every LLM call that app makes — regardless of how many nodes or how complex the workflow — automatically routes through Trappr. You configure it once; all apps benefit.
Setup
In your Dify workspace, go to Settings → Model Provider. Scroll to the bottom and click + Add Custom Provider (available in Dify Cloud and self-hosted).
Fill in the following fields:
| Field | Value |
|---|---|
| Provider name | Trappr Gateway |
| API endpoint URL | https://gateway.trappr.net/v1 |
| API key | Your Trappr Gateway key (cht_gw_*) |
| Model name | gpt-4o (or any model you've configured in Trappr) |
Click Save and Verify to confirm the connection works.
For each Dify app you want to protect, go to the app's Settings → Modeland switch the model provider from OpenAI to Trappr Gateway. Select the model name you configured.
Send a test message in your Dify app. In the Trappr dashboard under Gateway → Logs, you should see the request appear with the model and token count.
Supported Dify app types
| App type | Supported | Notes |
|---|---|---|
| Chatbot | Full | All LLM calls routed through gateway |
| Agent | Full | Tool calls logged separately |
| Workflow | Full | Each LLM node uses the configured provider |
| Text Generator | Full | Standard completions API |