Dify Quick Start: Build Your First AI App in 30 Minutes

Build a complete Dify AI app in 30 minutes: create, connect a model, debug, and publish.
Using a multi-platform content generator as the example project, this guide walks through the full Dify development loop in roughly 30 minutes: creating a Workflow app from scratch, connecting an LLM via Model Provider, running tests and reading node logs to debug, then publishing via web app, API, embed, or MCP service. The key takeaway is less about the individual steps and more about developing a complete mental model of the LLM app development lifecycle.
Many people install Dify and immediately get stuck at square one — they can't figure out how to actually build an AI app that works. This guide, based on Dify tutorial series by Bilibili creator "大叔大", walks you through a real-world example covering the complete loop: create → connect → debug → deploy. The whole thing takes about 30 minutes.
Why Choose Dify as Your AI App Development Platform
Dify is a visual LLM application development platform built around one core idea: go from concept to working app in one place. It abstracts away the complexity of model calls, prompt engineering, and flow control into nodes on a canvas — just drag, drop, and connect to build your logic. The barrier to building AI apps drops significantly.
The demo project for this tutorial is a multi-platform content generator: you feed it a piece of copy and a target platform, and it automatically produces content tailored to each platform's style. This is a common real-world need in content operations, and it's a great starter project — the logic is clean, the inputs and outputs are obvious, and it's easy to verify the whole pipeline actually works.
Here's roughly how the time breaks down: ~1 minute to create the app, ~1 minute to connect a model, ~1 minute for a test run, and ~3–7 minutes to publish. The real challenge isn't the mechanics — it's building a mental model of what a complete AI app actually needs.
Dify supports two core application types: Chatflow and Workflow. Chatflow is built for conversational scenarios — it maintains multi-turn context, making it ideal for customer service bots and Q&A assistants. Workflow is a stateless, single-pass execution pipeline: every run starts from scratch and moves through all nodes in sequence, which makes it a better fit for batch content generation, data processing, and other task-oriented scenarios. This tutorial uses Workflow because content generation is a linear "input → process → output" task with no need for conversation history. Dify also offers a RAG knowledge base (Retrieval-Augmented Generation) feature, which lets you connect private documents to your app so the model can answer questions based on your own data — extremely useful for enterprise knowledge bases and product documentation Q&A.
Step 1: Create a Dify App
Open Studio, go to the sidebar, choose "Create from Blank", and select Workflow as the type. Give your app a name — something like Multi-Platform Content Generator — and click Create to land on the canvas.
Getting to Know the Dify Canvas
The canvas is Dify's main workspace, split into three areas: a node library on the left, an arrangement area in the center, and all your logic expressed as nodes you drag and connect on the canvas. The first node to know is the "User Input" node — it's the starting point of every workflow.
If you prefer a local deployment, refer to the official Docker Compose docs: clone the repo, navigate into the docker directory under Dify, configure your environment variables, run docker compose up to start the service, then open the local install URL in your browser to complete initialization.

Step 2: Connect a Large Language Model
At this point your app is just a shell — nothing runs without a model. Connecting one takes two steps.
First, install a model provider. Go to Model Provider under Integrations and install the provider you need. All the major options are supported: OpenAI, Qwen, DeepSeek, and more.
Second, set a default model. Click Default Models in the top-right corner and set your primary inference model. The workflow will call it automatically from that point on.
It's worth noting that the domestic Chinese model ecosystem is rich with options: Qwen, DeepSeek, Zhipu GLM, Moonshot, and others are all available with essentially the same integration process — just enter the corresponding API Key. This means you can switch underlying models based on cost or performance without touching any of the app logic above it.
An API Key is the credential used to call an LLM service — essentially a string issued by the model provider after you register an account. Each API call consumes token quota and incurs a cost, so keep your keys secure and never expose them. For DeepSeek, register on their website and navigate to the "API Keys" page to generate one; for Qwen, you'll need to get it from Alibaba Cloud's Bailian platform. Once you enter it in Dify's Model Provider settings, Dify stores it encrypted on the server side and automatically includes it in workflow calls — you don't need to pass it in manually at each node. If you're just testing locally, you can also connect a local open-source model running via Ollama (such as Llama 3 or Qwen2) — completely free, with your data never leaving your machine.
Step 3: Test Run and Debugging
Once the canvas is set up, confirm there are no errors in the checklist, then click Test Run in the top-right corner. There are three steps:
- Enter input data: Fill in your draft copy, target platform, language, and tone, then click Run;
- Check the output: On success, you'll see content adapted for each platform;
- Troubleshoot errors: If something fails, check the Last Run log on the relevant node to pinpoint the exact cause.

The value here is turning a "black box" into a "white box" — every node's inputs and outputs are traceable. When something goes wrong, you don't have to guess; just read the logs. For newcomers, building the habit of checking the error checklist first and then the run logs will save a lot of debugging time.
Step 4: Publish and Deployment Options
Once debugging looks good, click Publish in the top-right corner and your app goes live immediately. Dify automatically generates multiple deployment options for every app, covering everything from end-user access to developer integration:
- Web app: Generates a shareable link your users can open directly;
- API access: Grab an API key and integrate it into your own product;
- Embed in site: Drop it into any webpage as a chat widget or iframe;
- MCP service: Connect it to AI tools like Cursor or Claude Desktop.

These four deployment paths cover the main ways AI apps actually reach users. The MCP service support is particularly interesting — it means your app can be invoked as a tool by other AI clients, which opens up a lot of possibilities as the Agent ecosystem continues to mature.

One thing to remember: every time you modify the app, you must click Publish again for the changes to take effect. This is a detail that trips up a lot of beginners.
MCP (Model Context Protocol) is an open protocol proposed by Anthropic in late 2024, designed to standardize how AI models communicate with external tools and data sources. Think of it as the "USB interface" of the AI world — any MCP-compliant client (like Cursor, Claude Desktop, or Cline) can automatically discover and call MCP-compliant services without needing custom adapter code for each tool. Dify's support for publishing apps as MCP services means your content generator, data query tool, or any other app you build can be exposed directly to MCP-compatible AI coding assistants or Agent frameworks, becoming part of their toolbox and significantly extending the reuse value of what you build.
The Complete Loop, Recapped
Putting the full 30 minutes together:
- Create the app: In Studio, create from blank, choose Workflow, name it, enter the canvas;
- Connect a model: Install a provider in Model Provider, then configure the default model;
- Test and debug: Confirm no checklist errors, click Test Run, enter data, review output, check logs;
- Publish: One-click Publish, with support for web app, API, embed, and MCP.
The point of this loop isn't just to "get a demo running" — it's to build a complete mental model of the full LLM application development lifecycle. According to the original creator, the next installment will go deep on node orchestration for both Workflow and Chatflow, unpacking the workflow we moved through quickly here.
The recommendation: follow these steps right now and build an app yourself, end to end. There's no substitute for actually doing it when it comes to internalizing this whole process.
Related articles

Desert Ant Labs: On-Device AI Model Local Inference Solutions
Desert Ant Labs builds AI models that run fast on local devices, offering data privacy, zero latency, and offline availability through advanced model optimization techniques.

Claude Credits Gone in 10 Minutes? A Guide to Token Consumption Analysis and Optimization
Why does Claude drain your quota so fast? We break down context accumulation, coding tool costs, and share token tracking tools and optimization tips for developers.

LangGraph Failover: A Complete Guide to Model Provenance and Cost Tracking
How LangGraph failover loses model provenance, error types, and cost metadata — and how Conifer's gateway layer solves it with typed receipts and cost ceilings.