3. Create DApp Template

Overview
This feature allows users to quickly generate a decentralized application (Dapp) template with predefined configurations, enabling faster development on the Cardano blockchain. It simplifies the setup process, providing essential components and dependencies for building a functional Dapp.
User Story
As a user, I want to generate a pre-configured Dapp template so that I can streamline development and focus on building my application without manually setting up the project structure.
User Flow
User navigates to the "Create Dapp Template" page
The system display a form with these input fields:
Off-chain Interaction SDK (Lucid, Mesh,...)
On-chain Programming Language (currently support Aiken)
Project Metadata
Project Location
Project Name
User clicks the "Generate" button, initiating the project creation process.
The backend calls the POST /dapp-template endpoint, which retrieves the appropriate template based on user input.
The webview emits event with the template folder to the Extension.
The Extension generates the project based on the received template
User can begin development once the template is generated
User Flow Diagrams

Note:
We will set up several templates that align with Cardano's best practices and meet project requirements.
The system will further process project metadata to enhance frontend integration and customization.
Troubleshooting & Common Issues
Issue
Possible Cause
Solution
Unable to retrieve the template
API request failed
Check console logs for errors
"Request Timed Out" error
Network issue or API down
Retry after a few minutes
API Reference
POST
/dapp-template
Get dapp template
Headers
Content-Type
application/json
Body
offChainSDK
string
off-chain sdk
language
string
on-chain language for develop Cardano smart contract
Response
{
"data": {
"success": true,
"data": {
"name": "lucid-aiken",
"type": "directory",
"children": [
{
"name": "aiken",
"type": "directory",
"children": [
{
"name": "README.md",
"type": "file",
"content": "# \n\nWrite validators in the `validators` folder..."
},
{
"name": "aiken.toml",
"type": "file",
"content": "name = \"\"\nversion = \"0.0.0\"\n..."
},
{
"name": "validators",
"type": "directory",
"children": [
{
"name": "contract.ak",
"type": "file",
"content": ""
}
]
}
]
},
{
"name": "frontend",
"type": "directory",
"children": [
{
"name": "eslint.config.js",
"type": "file",
"content": "import js from '@eslint/js'\n..."
},
{
"name": "index.html",
"type": "file",
"content": "<!doctype html>\n<html lang=\"en\">..."
}
]
}
]
}
},
"msg": "OK",
"code": 201
}
Demo
Screenshot

Video
🔹 For any issues, please refer to the Troubleshooting Section or open an Issue on GitHub.
Last updated