# Fixing errors and debugging
Source: https://docs.leap.new/best-practices/debugging
How to debug and fix errors effectively.
Errors will inevitably happen when building software, whether the code is written by an AI or a human. When working with Leap, the key is not to panic or waste credits by repeatedly pasting the same error. Instead, use a systematic debugging approach. Leap works best when you provide clear context and precise, focused instructions.
This guide explains how to debug issues effectively, collaborate with Leap, and unblock yourself when things don’t go as expected.
## 1) Provide Detailed Bug Reports
When you encounter an issue, the fastest way to get to a fix is by writing a strong bug report.
Just like when working with a developer, the more context you share, the easier it is for Leap to understand what went wrong and how to fix it.
A strong bug report typically includes:
* A clear description of the problem
* Steps to reproduce the issue
* What you expected to happen
* What actually happened
* Any relevant logs, screenshots, or error messages
**Tip:** The quality of your prompt directly shapes the quality of the fix. Avoid vague requests and include the exact error, a minimal snippet, and what you tried.
Instead of:
```text theme={null}
It's broken, fix it
```
Try:
```text theme={null}
When I click the "Save" button on the form, nothing happens.
Expected: The form should save and show a success message.
Actual: No response, and the following error appears in the console: "TypeError: handleSubmit is not defined".
```
## 2) Add relevant logs
If Leap struggles fixing the issue even after providing a strong bug report, it can be a good idea to add additional logging.
Example:
```text theme={null}
When I submit the form, I get the error "TypeError: handleSubmit is not defined".
Please add relevant console.log statements around the submit handler so I can gather more details.
```
After running the updated code, check the Logs panel in Leap or your browser’s Console. Share the new output in your next bug report so Leap can refine the fix.
## 3) Use Iterative Debugging
Big issues are often solved step by step. Instead of asking Leap to “fix everything,” try breaking down the problem:
* Ask Leap to identify why the error is happening
* Add logging or test cases if the cause is unclear
* Apply the suggested fix and retest
* Share updated results with Leap
By iterating, you avoid burning credits on large, unfocused requests and make steady progress toward a solution.
# Effective Prompting
Source: https://docs.leap.new/best-practices/prompting
How to craft effective prompts when working with Leap.
Leap is capable of building production-ready applications based on your instructions and specifications. Clear and detailed instructions, prompts, lead to better results.
A prompt is what you write to tell the AI what you want it to do. Think of the AI like your engineering partner, not an all-knowing oracle: it can only respond based on the information you give it.
This guide will help you communicate effectively with Leap to get the results you want.
## The Basics
**Be specific about what you're building.** The more details you provide, the better Leap can understand your vision.
Instead of:
```
Build a todo app.
```
Try:
```
Build a task management app where users can create projects, add tasks with due dates,
and assign them to team members.
```
**Describe your data.** Mention the key entities in your application and how they relate to each other.
```
Build a book review site where users can:
- Rate books (1-5 stars)
- Write reviews
- See other users' reviews
- Browse books by genre
```
**Start simple, then iterate.** Begin with core functionality and add complexity through follow-up prompts. Whenever you've completed a feature, it's good to use the *Merge change* feature to save your work and clear the chat. This optimizes token usage and makes it easy to revert back to a working version of your app later on.
## Real Examples That Work Well
Here's a prompt that consistently produces great results:
```
Build an expense tracking app where users can:
- Log expenses with amounts, dates, and categories
- See monthly spending summaries
- Set budget limits for different categories
- Get notifications when approaching budget limits
```
This works because it clearly defines the core features and data model without overwhelming Leap with implementation details.
For a backend-focused application:
```
Build an API for a product inventory system with:
- Product management (create, update, search)
- Inventory tracking across multiple warehouses
- Order processing that updates inventory levels
- Low stock alerts
```
## Integrating with Third-Party Services
Leap can often easily integrate with popular third-party services. Simply mention them in your prompt:
```
Build a newsletter platform that uses Resend for email delivery and Stripe for subscription payments.
```
Some popular integrations that work well:
* Payment processing (Stripe, Polar)
* Email services (Resend, SendGrid)
* Authentication providers (Clerk, Auth0)
* Analytics tools (PostHog, Mixpanel)
* .. and more
**Sometimes Leap needs more context:** AI is notoriously bad at recognizing what it doesn’t know. When working with lesser-known services, Leap might hallucinate API endpoints or make assumptions based on common patterns that don't actually apply. If you notice Leap getting it wrong, it helps to copy relevant sections from the service’s documentation into your prompt. This gives Leap the context it needs to generate accurate code.
## Prompt Patterns to Follow
**Start with the purpose:** Begin by stating what the application is for.
```
Build a platform for scheduling and managing fitness classes...
```
**List key features:** Use bullet points for clarity.
```
Users should be able to:
- Book classes based on availability
- Manage their bookings
- Receive reminders before class
```
**Mention technical requirements only when necessary:**
```
The application should use PostgreSQL for data storage and include user authentication.
```
Keep in mind Leap can only implement supported technologies and will not be able to use arbitrary programming languages and infrastructure. On the backend side, Leap uses [Encore](https://encore.dev/) as the backend framework which comes with native support for PostgreSQL, microservices, Pub/Sub, Object storage, and more.
## How NOT to Prompt Leap
Leap is designed to build applications based on clear, specific feature requests. It’s not intended for general questions or vague feedback. To get the best results, describe exactly what you want to build or fix, and include helpful context like user actions, expected behavior, error messages, logs, or screenshots.
These types of prompts won’t work well:
**INEFFECTIVE:**\
"Can you fix all the bugs in the application?"\
"The login is broken."\
"Please review and test everything you've built."
Instead, be specific and provide context:
**EFFECTIVE:**\
"Allow guests to start the checkout process without signing up for an account."
"Fix the TypeError: Cannot read property 'email' of undefined shown in the console after submitting the login form."
"Adjust the layout so that the cards are horizontally aligned on the index page (see screenshot attached)."
## When You Get Stuck
If you've gotten stuck, it may be helpful to revert to your latest merged version by clicking *Discard change*.
This clears the context and makes Leap more effective.
After reverting to your latest merged version, try these approaches to produce better results:
**Be more concrete.** Provide specific examples of how features should work.
**Simplify your request.** Break complex applications into smaller pieces.
**Ask for guidance.** If you're not sure how to describe something, Leap can help you structure your prompt better.
## Sample Prompt Template
Here's a template you can adapt for most applications:
```
Build a [type of application] that helps users [solve this problem].
Key functionality:
- [Feature 1]
- [Feature 2]
- [Feature 3]
The application should have:
- [Any specific technical requirements]
- [Any specific design requirements]
```
## A Note on Backend Features
Leap excels at building proper backend infrastructure. Don't hesitate to request:
* Database schemas and migrations
* API endpoints with proper error handling
* Scheduled jobs
* Event-driven architecture
* Authentication and authorization
Unlike many AI tools that focus on frontends, Leap can generate robust backend code that's ready for production.
***
Remember that Leap is designed to handle complex requirements, but clear communication is key. Focus on what you want to build, not how you think it should be implemented, and Leap will handle the technical details.
# Reaching users
Source: https://docs.leap.new/best-practices/reaching-users
Get your Leap app discovered and gain initial traction with these proven strategies
Even the most talented builders face the same challenge: **"How do I get users to try this great thing I built?"**
You've just created a production-ready application with Leap, complete with backend APIs, database, and cloud deployment. Now it's time to get it in front of users who need it.
Here's your step-by-step action plan to gain initial traction:
## Go where your users are
The most effective marketing happens where your potential users already spend their time. Instead of trying to pull them to you, meet them where they are.
**Reddit is your best friend for niche apps.** If you built a gardening app, the people in r/gardening are exactly who you need to reach. Same goes for fitness apps in r/fitness, or productivity tools in r/entrepreneur. The key is being genuinely helpful, not promotional. Share what you learned building the app, ask for feedback, and let people discover it naturally.
**Think beyond the obvious platforms.** Your users might hang out in unexpected places. A meal planning app might find users in r/MealPrepSunday, but also in Facebook groups for busy parents or Discord servers for fitness enthusiasts.
**Pro tip**: Spend time in these communities before you post about your app. Understand the culture, contribute helpful comments, and build relationships. When you do share your project, you'll already be a trusted community member.
## Start with your network
Your personal network is underrated. These people already know and trust you, which means they're more likely to try your app and give honest feedback.
**Don't overthink it** - just tell people what you built. Send a message to former colleagues who might find it useful. Post on your personal social media. Ask friends to try it out. Even if they're not your target users, they might know someone who is.
The goal isn't to get thousands of users from your network. It's to get your first 10-20 users who can give you feedback and help you refine your messaging for larger audiences.
## Make it easy to share
Once people try your app, make it simple for them to tell others about it. A 30-second screen recording showing your app in action is worth more than any written description.
Keep it real and focused on the problem you're solving. People don't care about your tech stack - they care about whether your app makes their life easier.
## Plan a bigger launch
Once you've tested your messaging with your network and niche communities, you're ready for broader visibility.
**Product Hunt** remains the gold standard for product launches. Submit your app, launch Tuesday-Thursday for maximum visibility, and rally your supporters for launch day. A compelling tagline and demo GIF are essential.
**Other launch platforms** worth considering: [Hacker News Show HN](https://news.ycombinator.com/showhn.html) works well for developer tools, [Indie Hackers](https://indiehackers.com) is perfect for solo projects, and [Beta List](https://betalist.com) helps with early-stage apps.
The key is timing these launches after you've already refined your messaging and gathered some initial users and feedback.
**Remember**: Marketing is not a one-time launch event. The most successful apps combine a strong initial push with consistent, ongoing efforts to reach new users and engage existing ones.
# Optimize token usage
Source: https://docs.leap.new/best-practices/tokens
How to work more efficiently and keep your costs down
Leap uses Anthropic’s Claude 4 Sonnet and Google's Gemini models to power its AI. These models process *tokens*, which is defined by Anthropic as:
> The smallest individual units of a language model. A token can represent a word, part of a word, a character, or even a byte (especially in the case of Unicode).
Each token comes with a cost, and Leap is billed by the AI providers for each token it uses. This is why our paid plans are priced based on how many tokens you get in each plan.
## How Leap uses tokens
Tokens are consumed in three main ways when using Leap:
* Messages between you and the AI.
* The AI writing new code for your application.
* The AI reading and analyzing your existing codebase, including any changes you've made.
## How Leap optimizes token usage
We're always working to make Leap consume tokens in the most efficient way, and are investing heavily in building smart logic and advanced tools for optimizing what context is passed to the AI and have it produce only relevant output.
This already includes strategies like:
* Only including relevant chat history and change history from the current open **Change**, not all historical context.
* Controlling the AI output and focusing it on writing functional and efficient code.
## Tips to reduce your token usage
Here are some simple ways you can reduce token usage and improve performance:
### Merge early and often
When you first send a prompt in Leap, it creates a **Change** for the ongoing chat with the AI. You can think of this as a branch.
Whenever you have accomplished an atomic implementation in your application, we recommend clicking **Merge change** and continuing with a new one. You can think of this as merging a pull request.
Merging early and often ensures the context passed to the AI is focused only on what is relevant for the changes you are currently working on.
### Use Scope context
If you have a large codebase, manually defining what part of the codebase is send to the AI can be used to significantly optimize token usage. Click **Scope context** in the prompt text area to select which files and folders are relevant to the change you are working on.
**Example:** If you are asking the AI to only make UI changes on a specific page, use the Scope context feature to select the relevant page.
### Avoid repeated "Attempt Fix" attempts
Repeatedly clicking **Attempt Fix** can quickly consume unnecessary tokens. After an attempt, review the changes and refine your next request if needed. Not every issue can be fixed automatically, without providing more context to the AI, so it’s often worth debugging the error or making manual edits if fixes fail.
### Add error handling and logging
If you're stuck in an error loop, prompt Leap to add detailed logging and stronger error handling. Leap is good at inserting useful logs at key steps, and these logs help the AI understand what’s going wrong and allow it to respond with more precise fixes in future attempts.
### Use the Undo functionality
If something goes wrong, you can **Undo** the latest revision to immediately return to the previous state. Using Undo is more efficient than asking the AI to revert the change.
Undoing a revision is permanent, there’s no redo, so make sure you're ready before using it.
### Use the Discard change functionality
If you’ve made multiple revisions in a Change and aren’t happy with the result, you can revert to the latest merged state by clicking **Discard change** on the active Change. Discarding is more efficient than asking the AI to revert the changes.
Discarding a change is permanent, there’s no un-discard, so make sure you're ready before using it.
# Leap vs Bolt
Source: https://docs.leap.new/comparisons/leap-vs-bolt
Production-grade infrastructure vs browser-based development - when to use each approach
Bolt excels at browser-based development and rapid prototyping with WebContainers. Leap builds production-grade distributed systems with real cloud infrastructure.
## Key differences
| | Leap | Bolt |
| --------------------------------------- | ------------------------------------ | ------------------------- |
| **Approach** | Production-grade distributed systems | Browser-based development |
| **Deploys to your own cloud (AWS/GCP)** | ✅ Yes | ❌ No |
| **Real backend logic & microservices** | ✅ Yes | ❌ Limited |
| **Infrastructure-as-code by default** | ✅ Yes | ❌ No |
| **Built-in distributed tracing** | ✅ Yes | ❌ No |
| **Multi-environment support** | ✅ Yes | ❌ Limited |
| **Type-safe distributed systems** | ✅ Yes | ❌ No |
| **Avoids vendor lock-in** | ✅ Yes | ❌ No |
## When to choose each
**Choose Bolt for:**
* Quick full-stack prototyping in the browser
* Learning frameworks without local setup
* Single applications deploying to Netlify/Cloudflare
* Rapid experimentation and iteration
**Choose Leap for:**
* Production distributed systems with microservices
* Real backend infrastructure and databases
* Deployment to your own AWS/GCP account
* Enterprise applications requiring scalability
## The difference
**Bolt** generates single applications that work well for standalone projects and platform deployment.
**Leap** generates complete distributed systems with multiple services, databases, and cloud infrastructure that scale to enterprise requirements.
# Leap vs Cursor
Source: https://docs.leap.new/comparisons/leap-vs-cursor
System generation meets intelligent coding - better together than competing
Cursor is an AI-powered code editor. Leap generates complete distributed systems. They work better together than apart.
## Key differences
| | Leap | Cursor |
| ----------------------------------- | --------------------------------- | -------------------------------- |
| **Best for** | Starting new projects (0→1) | Working with existing code (1→N) |
| **Primary use case** | Generate systems & infrastructure | Daily coding & refactoring |
| **Generates distributed systems** | ✅ Yes | ❌ No |
| **Works with any existing project** | ❌ No | ✅ Yes |
| **Creates cloud infrastructure** | ✅ Yes | ❌ No |
| **Enhanced IDE coding** | ❌ No | ✅ Yes |
| **Production observability** | ✅ Yes | ❌ No |
## Why they're complementary
**Use Leap to:**
* Generate your system architecture and infrastructure
* Create new services and major features
* Set up databases and cloud deployment
**Use Cursor to:**
* Implement detailed business logic
* Debug and optimize existing code
* Refactor and add comprehensive testing
## Recommended workflow
1. **Generate foundation with Leap** - Complete distributed system in minutes
2. **Develop with Cursor** - AI-powered coding with [Encore optimization rules](https://encore.dev/docs/ts/quick-start#optional-add-encore-llm-instructions)
3. **Switch between tools** - GitHub integration keeps everything in sync
**The combination saves months of architecture work** while providing the best AI-enhanced development experience.
# Leap vs Lovable
Source: https://docs.leap.new/comparisons/leap-vs-lovable
Production-grade infrastructure vs rapid prototyping - when to use each approach
Lovable excels at rapid frontend prototyping for non-technical users. Leap builds production-grade backend systems for professional developers.
## Key differences
| | Leap | Lovable |
| --------------------------------------- | ------------------------------- | ----------------- |
| **Approach** | Production-grade infrastructure | Rapid prototyping |
| **Deploys to your own cloud (AWS/GCP)** | ✅ Yes | ❌ No |
| **Real backend logic & microservices** | ✅ Yes | ❌ No |
| **Infrastructure-as-code by default** | ✅ Yes | ❌ No |
| **Built-in distributed tracing** | ✅ Yes | ❌ No |
| **Multi-environment support** | ✅ Yes | ❌ No |
| **Type-safe distributed systems** | ✅ Yes | ❌ No |
| **Avoids vendor lock-in** | ✅ Yes | ❌ No |
## When to choose each
**Choose Lovable for:**
* Quick frontend demos and validation
* Non-technical founders building prototypes
* Simple apps with basic Supabase integration
* Speed over production architecture
**Choose Leap for:**
* Backend-heavy applications with real infrastructure
* Production systems requiring scalability
* Microservices and distributed architectures
* Deployment to your own cloud
## The difference
**Lovable** creates React frontends with basic backend integration - perfect for demos and validation.
**Leap** creates complete distributed systems with proper backend services, databases, and cloud infrastructure - built for production from day one.
# Leap vs Windsurf
Source: https://docs.leap.new/comparisons/leap-vs-windsurf
System generation meets accessible AI coding - perfect combination for growing teams
Windsurf is a beginner-friendly AI IDE with clean UX. Leap generates production distributed systems. Perfect combination for accessible development.
## Key differences
| | Leap | Windsurf |
| ----------------------------------- | --------------------------------- | ----------------------------- |
| **Best for** | Starting new projects (0→1) | Accessible AI coding (1→N) |
| **Primary use case** | Generate systems & infrastructure | Beginner-friendly development |
| **Generates distributed systems** | ✅ Yes | ❌ No |
| **Works with any existing project** | ❌ No | ✅ Yes |
| **Creates cloud infrastructure** | ✅ Yes | ❌ No |
| **Intuitive AI for beginners** | ❌ No | ✅ Yes |
| **Production observability** | ✅ Yes | ❌ No |
## Why they work well together
**Use Leap to:**
* Generate complete system architecture
* Create backend services and databases
* Set up production infrastructure and deployment
**Use Windsurf to:**
* Accessible AI-powered feature development
* Intuitive multi-file editing with Cascade
* Clean development experience without complexity
## Recommended workflow
1. **Generate foundation with Leap** - Production system with proper architecture
2. **Develop with Windsurf** - Accessible AI assistance for ongoing work
3. **Seamless transitions** - GitHub integration keeps everything synchronized
# Connect AWS Account
Source: https://docs.leap.new/deployment/aws
Deploy your Leap application to your own AWS account through Encore Cloud
Connect your AWS account to Encore Cloud to deploy your Leap application directly to your own AWS infrastructure. This gives you full data sovereignty while leveraging Encore's deployment automation.
## Prerequisites
* Active AWS account with appropriate permissions
* Ability to create IAM roles in your AWS account
* Understanding of which AWS region you want to deploy to
* Your application built and tested with Leap
* Preview environment validated and working
* Ready to deploy to production infrastructure
## Connection Process
In your Leap project:
1. Go to the [Encore Cloud dashboard](https://app.encore.cloud/)
2. Select your application
3. Navigate to **App Settings** → **Integrations** → **Connect Cloud**
4. Select **Amazon Web Services (AWS)**
Follow the detailed instructions provided on the Connect Cloud page to:
* Create a new IAM Role in your AWS account
* Configure the trust relationship with Encore Cloud
* Attach the necessary permissions for infrastructure provisioning
**Security requirement**: Make sure to check **"Require external ID"** and specify the external ID provided in the Encore Cloud instructions. This is critical for security.
Back in Encore Cloud:
* Enter the ARN of the IAM role you created
* Verify the external ID matches what you configured
* Test the connection to ensure Encore can assume the role
Select which AWS region you want Encore Cloud to provision resources in:
* Consider latency to your users
* Review AWS region capabilities and compliance requirements
* Factor in your existing AWS infrastructure location
[Learn more about AWS regions](https://aws.amazon.com/about-aws/global-infrastructure/regions_az/)
## What Gets Deployed
When you deploy to your AWS account through Encore Cloud, the following infrastructure is automatically provisioned:
**Container-based application hosting**
* AWS services appropriate for your application architecture
* Auto-scaling based on demand
* Load balancing for high availability
* Security groups with proper network isolation
**Managed database services**
* Amazon RDS for PostgreSQL (or your configured database)
* Automated backups and maintenance
* Multi-AZ deployment for production environments
* Proper security configuration and access controls
**Production-ready network configuration**
* VPC with appropriate subnet configuration
* Security groups following least-privilege principles
* SSL/TLS certificates for secure communication
* IAM roles and policies for service access
**Observability integration**
* CloudWatch integration for metrics and logs
* Integration with Encore's monitoring dashboard
* Alerting configuration for critical events
* Performance monitoring and optimization insights
## IAM Permissions
The IAM role you create needs appropriate permissions to provision and manage infrastructure in your AWS account. The exact permissions required will be specified in the Connect Cloud setup instructions, but typically include:
**Essential AWS services for application deployment**
* **Compute**: ECS, Fargate, or EC2 for running your application
* **Database**: RDS for managed database services
* **Networking**: VPC, subnets, security groups, and load balancers
* **Storage**: S3 for application assets and backups
**IAM and security service permissions**
* **IAM**: Create and manage service roles
* **Secrets Manager**: Store and manage application secrets
* **Certificate Manager**: Provision SSL certificates
* **CloudWatch**: Monitoring and logging
**Recommended security configuration**
✅ **Use external ID**: Always require external ID for role assumption ✅ **Least privilege**: Only grant permissions necessary for deployment ✅ **Regular review**: Periodically review and update permissions ✅ **Condition policies**: Use condition policies to restrict access further
## Managing Your Deployment
**Monitor and manage through Encore**
* View application performance and health
* Access logs and distributed tracing
* Manage deployments and rollbacks
* Configure environments and settings
**Direct access to your infrastructure**
* View and manage AWS resources directly
* Access detailed CloudWatch metrics
* Configure additional AWS services
* Manage billing and cost optimization
## Important Considerations
**Understanding infrastructure lifecycle**
* Encore Cloud provisions infrastructure in your AWS account
* Resources are billed directly to your AWS account
* **Manual approval required** for resource deletion for safety
* If you disconnect or delete environments, you must explicitly approve infrastructure deletion in the Encore Cloud dashboard
**Controlling AWS costs**
* Use AWS Cost Explorer to monitor spending
* Set up billing alerts in your AWS account
* Leverage existing AWS Reserved Instances or Savings Plans
* Consider AWS resource optimization recommendations
**Maintaining security standards**
* Your data remains in your AWS account at all times
* Leverage your existing AWS security policies
* Use AWS CloudTrail for audit logging
* Implement your organization's compliance requirements
## Troubleshooting
**Common IAM role problems**
**Problem**: Encore Cloud cannot assume the IAM role **Solution**:
* Verify the external ID is correctly configured
* Check that the trust relationship includes Encore's account
* Ensure the role has necessary permissions
* Confirm you're using the correct role ARN
**Insufficient permissions during deployment**
**Problem**: Deployment fails due to missing permissions **Solution**:
* Review the permissions required in the Connect Cloud instructions
* Check AWS CloudTrail logs for specific permission denials
* Ensure the IAM role has all required service permissions
* Contact support if you need clarification on required permissions
**Deployment region problems**
**Problem**: Resources cannot be created in selected region **Solution**:
* Verify the region supports all required AWS services
* Check for any organization-level region restrictions
* Ensure your AWS account has appropriate limits in the region
* Consider selecting an alternative region if needed
## Getting Help
If you encounter issues during the AWS connection process:
**Additional AWS resources**
* [AWS IAM Roles Documentation](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user.html)
* [AWS Regions and Availability Zones](https://aws.amazon.com/about-aws/global-infrastructure/regions_az/)
* AWS Support for account-specific issues
***
**Next steps**: After connecting your AWS account, you can deploy your application by clicking **Deploy** in your Leap project and selecting your AWS environment. The first deployment typically takes 10-15 minutes as infrastructure is provisioned.
# Custom Domains
Source: https://docs.leap.new/deployment/custom-domains
Connect your Leap application to a custom domain
When your Leap application is ready for production, you may want to serve it from your own domain rather than the default Encore-provided URL. This guide walks you through the process of connecting a custom domain to your Leap application.
Custom domains are available for [Leap Pro plan](https://leap.new/#pricing) subscribers.
## Setting up a Custom Domain
Follow these steps to connect your domain to your Leap application:
1. In your Leap project, click the **Deploy** button in the top-right corner
2. After deployment, click the **+ Custom Domain** button which will take you to the Domains settings page.
3. Click the **Add Domain** button to open the domain configuration modal
In the Add Domain modal:
1. Enter your domain (e.g., `your-domain.com`)
2. The modal will show you the DNS record you need to add to your domain provider:
```
Type: CNAME
DNS Record: api.your-domain.com (your subdomain)
Value: custom-domain.encr.app
```
3. Select the environment you want to assign the domain to.
4. Click **Add Domain** to complete the setup
5. Add the specified DNS record with your domain provider (see DNS Configuration section below)
Your custom domain comes with DDoS protection powered by Cloudflare WAF.
## DNS Configuration
After adding your domain, you'll need to set up the appropriate DNS records with your domain registrar. Select your provider below for specific instructions.
1. Log in to your Namecheap account
2. Go to **Domain List** and click **Manage** next to your domain
3. Select the **Advanced DNS** tab
4. Click **Add New Record**
5. Enter the following details:
* Type: CNAME Record
* Host: Enter your subdomain (e.g., `api` for `api.your-domain.com`)
* Value: `custom-domain.encr.app`
* TTL: Automatic
6. Click **Save All Changes**
1. Log in to your GoDaddy account
2. Navigate to **My Products** > **Domains**
3. Select the domain you want to use
4. Click **DNS**
5. Under **Records**, click **Add**
6. Select **CNAME** from the Type dropdown
7. Enter the following details:
* Host: Enter your subdomain (e.g., `api` for `api.your-domain.com`)
* Points to: `custom-domain.encr.app`
* TTL: 1 Hour
8. Click **Save**
1. Log in to your Cloudflare account
2. Select your domain
3. Go to the **DNS** tab
4. Click **Add record**
5. Select **CNAME** from the Type dropdown
6. Enter the following details:
* Name: Enter your subdomain (e.g., `api` for `api.your-domain.com`)
* Target: `custom-domain.encr.app`
* Proxy status: Proxied (recommended)
7. Click **Save**
1. Log in to your Google Domains account
2. Select your domain
3. Go to **DNS**
4. Scroll down to **Custom resource records**
5. Enter the following details:
* Name: Enter your subdomain (e.g., `api` for `api.your-domain.com`)
* Type: CNAME
* TTL: 1h
* Data: `custom-domain.encr.app`
6. Click **Add**
For other DNS providers, you'll need to:
1. Log in to your domain registrar's account
2. Locate the DNS or Domain Management section
3. Look for an option to add a new DNS record
4. Create a CNAME record with:
* Host/Name: Your subdomain (e.g., `api` for `api.your-domain.com`) or `@` for root domain
* Value/Target/Points to: `custom-domain.encr.app`
* TTL: 3600 (1 hour) or the lowest available value
## Verifying Your Domain
After setting up the DNS record:
1. It may take some time for DNS changes to propagate (typically 15 minutes to 48 hours)
2. You can check the status of your domain on the Domains settings page
3. Once verified, your application will be accessible via your custom domain
## Troubleshooting
If you encounter issues with your custom domain setup:
* Verify that your DNS record is correct and matches the provided instructions
* Check if your DNS changes have propagated using a tool like [dnschecker.org](https://dnschecker.org)
* Ensure your domain doesn't have conflicting DNS records
* Contact support via the Encore Cloud dashboard if you continue to experience issues
# Connect Google Cloud Account
Source: https://docs.leap.new/deployment/gcp
Deploy your Leap application to your own GCP account through Encore Cloud
Connect your Google Cloud Platform account to Encore Cloud to deploy your Leap application directly to your own GCP infrastructure. Encore provides a dedicated GCP Service Account for your application and guides you through the setup process.
## Prerequisites
* Access to a GCP Organization account
* **Organization Policy Administrator** role (required for setup)
* Billing enabled on your GCP project
* Understanding of which GCP region you want to deploy to
* Your application built and tested with Leap
* Preview environment validated and working
* Ready to deploy to production infrastructure
## Connection Process
In your Leap project:
1. Go to the [Encore Cloud dashboard](https://app.encore.cloud/)
2. Select your application
3. Navigate to **App Settings** → **Integrations** → **Connect Cloud**
4. Select **Google Cloud Platform (GCP)**
Encore Cloud provides a unique GCP Service Account for your application:
* Find your app's Service Account email on the Connect Cloud page
* Copy this email address - you'll need it for the next steps
* This Service Account will be used by Encore to provision infrastructure
Update your GCP Organization's domain restricted sharing policy:
* Add Encore Cloud to your allowed domains list
* Follow the specific instructions provided on the Connect Cloud page
* This allows Encore's Service Account to access your organization
**Permission required**: You need the **Organization Policy Administrator** role to modify this policy.
Provide the necessary permissions to Encore's Service Account:
* Use the Service Account email from step 2
* Follow the detailed permission instructions on the Connect Cloud page
* Grant access to provision infrastructure in your GCP project
## Required Permissions
**Required for initial setup**
If you don't have the Organization Policy Administrator role:
1. Ask your GCP Organization Administrator to grant you the role
2. Alternatively, have them complete the domain restriction setup for you
**If you are a GCP Organization Administrator:**
1. Go to the [IAM & Admin page](https://console.cloud.google.com/iam-admin/iam) in GCP Console
2. Find your user account in the members list
3. Click the pencil icon to edit your account
4. Add the **Organization Policy Administrator** role
5. Click Save
**Infrastructure provisioning permissions**
The Encore Service Account needs permissions to:
* Create and manage compute resources
* Provision managed database services
* Configure networking and security
* Set up monitoring and logging
* Manage IAM roles for your application
Specific permissions will be detailed in the Connect Cloud setup instructions.
## What Gets Deployed
When you deploy to your GCP account through Encore Cloud, the following infrastructure is automatically provisioned:
**Cloud-native application hosting**
* Google Cloud Run or Compute Engine services
* Load balancing and auto-scaling
* VPC and firewall configuration
* SSL certificates and domain management
**Managed database and storage**
* Cloud SQL for managed databases
* Cloud Storage for application assets
* Automated backups and maintenance
* Security and access controls
**Enterprise security configuration**
* IAM roles and service accounts
* Security policies and firewall rules
* Encryption at rest and in transit
* Network isolation and access controls
**Observability and management**
* Cloud Monitoring integration
* Cloud Logging for centralized logs
* Integration with Encore's monitoring
* Performance tracking and alerting
## Managing Multiple GCP Accounts
**Working with multiple GCP accounts**
If you have access to multiple GCP accounts:
* Ensure you're logged in with the correct account
* Verify the correct organization is selected in GCP Console
* Double-check you're modifying policies for the right organization
* Use the account switcher in GCP Console if needed
**Understanding GCP organization hierarchy**
* **Organization**: Top-level container for all GCP resources
* **Folders**: Optional grouping for projects (if used)
* **Projects**: Where your actual resources will be deployed
* **Resources**: The infrastructure Encore provisions
## Troubleshooting Common Issues
**Missing Organization Policy Administrator role**
**Problem**: You can't access or modify the Domain restricted sharing policy
**Solution**:
* You need the **Organization Policy Administrator** role
* Ask your GCP Organization Administrator to grant you this role
* Alternatively, have them complete the setup for you
* Follow the role assignment steps in the permissions section above
**Service Account access issues**
**Problem**: Unable to grant access to the Encore Cloud service account
**Possible causes and solutions**:
* **Domain restriction not configured**: Ensure you've added Encore Cloud to your Domain restricted sharing policy
* **Wrong GCP account**: Verify you're logged in with the correct account
* **Wrong organization**: Ensure the correct organization is selected in GCP Console
* **Multiple accounts**: If using several GCP accounts, make sure you're working with the right one
**Organization connectivity issues**
**Problem**: Error message about missing Organization ID
**Solution**:
* Verify you've completed all steps in the Connect Cloud page
* Ensure Encore Cloud has been granted access to your GCP Organization
* Check that you're logged in with the correct GCP account
* Confirm the correct organization is selected in GCP Console
* If using multiple GCP accounts, verify you're working with the intended one
**Insufficient permissions for infrastructure provisioning**
**Problem**: Deployment fails due to missing permissions
**Solution**:
* Review the permission requirements in the Connect Cloud instructions
* Ensure the Encore Service Account has all necessary permissions
* Check GCP audit logs for specific permission denials
* Verify you're working within the correct GCP project
## After Connection
Once you've successfully connected your GCP account:
* Encore Cloud will test the connection to your GCP account
* You should see a success confirmation
* Your GCP account will appear as an available deployment target
Select which GCP region you want for your deployment:
* Consider latency to your users
* Review regional service availability
* Factor in compliance and data residency requirements
* Consider integration with existing GCP infrastructure
* Click **Deploy** in your Leap project
* Select your GCP environment
* Monitor the deployment progress in Encore Cloud dashboard
* First deployment typically takes 10-15 minutes
## Important Notes
**Understanding infrastructure lifecycle**
* Encore Cloud provisions infrastructure in your GCP account
* Resources are billed directly to your GCP account
* **Manual approval required** for resource deletion for safety
* Always approve infrastructure deletion in Encore Cloud dashboard when disconnecting
**Managing GCP costs**
* All infrastructure costs appear in your GCP billing
* Use GCP's cost management tools to monitor spending
* Leverage existing GCP committed use discounts
* Set up billing alerts in your GCP account
**Maintaining your security posture**
* Your data remains in your GCP account at all times
* Leverage your existing GCP security policies
* Use Cloud Audit Logs for compliance tracking
* Implement your organization's security requirements
## Getting Help
If you encounter issues during the GCP connection process:
**Additional GCP resources**
* [GCP IAM Documentation](https://cloud.google.com/iam/docs)
* [Organization Policy Constraints](https://cloud.google.com/resource-manager/docs/organization-policy/org-policy-constraints)
* GCP Support for account-specific issues
***
**Next steps**: After connecting your GCP account, you can deploy your application by selecting your GCP environment in the deployment options. Monitor the deployment progress through the Encore Cloud dashboard.
# Deployment Overview
Source: https://docs.leap.new/deployment/overview
Deploy your Leap applications to Encore Cloud or your own AWS/GCP infrastructure
When you're ready to share your app with the world, it's time to deploy it.
Leap apps can be deployed automatically using Leap's integration with Encore Cloud. Just click **Deploy** in the top-right corner of Leap to open the deployment dialog. From there, you can choose to deploy to a free Encore Cloud-hosted environment or connect your own AWS or GCP account.
Encore Cloud's built-in hosting is ideal for small-scale projects and comes with [**usage limits**](https://encore.dev/docs/platform/management/usage). To remove these limits, you can deploy to your own AWS or GCP account, where resources are billed directly to you.
**Same experience either way**: Whether you deploy to Encore's infrastructure or your own cloud, you get the same monitoring, scaling, and developer experience through Encore Cloud.
## Deploying to your own cloud
With Encore Cloud you can automate deployments to your own AWS or GCP account. This requires an [Encore Cloud Pro subscription](https://encore.cloud/pricing), which enables Encore Cloud to orchestrate the deployment to your cloud provider.
Here's what you get:
* **One click deploys** - Encore Cloud handles CI/CD and orchestrates infrastructure provisioning
* **Data sovereignty** - Your data stays in your cloud account
* **Compliance** - Meet enterprise and regulatory requirements
* **Cost control** - Use existing cloud discounts and reserved instances
* **Security** - Deploy within your existing VPC and security models
**Setup guides**
Complete guide for AWS deployment
Step-by-step GCP setup
***
**Ready to deploy?** Start with one-click deployment to Encore infrastructure, then connect your cloud account when you're ready for production control. [Build your first app →](/getting-started/quickstart)
# Meet Leap
Source: https://docs.leap.new/getting-started/introduction
AI developer agent that builds production-grade apps and deploys them to your own cloud
Leap is an AI developer agent that builds **production-ready applications** and deploys them directly to your AWS or Google Cloud. Unlike other AI tools that generate toy frontends or lock you into proprietary platforms, Leap creates real backend systems with databases, APIs, and infrastructure.
Build your first full-stack app in under 3 minutes
## Built for developers who want to move fast
**Generate complete systems, not just code snippets.** While other AI tools help you write functions or components, Leap creates entire backend architectures with microservices, databases, and cloud infrastructure.
**Deploy to your own cloud from day one.** Your apps run on your AWS or GCP account. No vendor lock-in, no proprietary hosting, no surprises. You own your infrastructure and data.
**Work the way you already do.** Every app comes with GitHub integration, proper version control, and fits into your existing development workflow. Use Leap to generate your foundation, then switch to your favorite IDE.
## What you can build
Leap excels at **backend-heavy applications** that other AI tools can't handle:
* **API services** with authentication, databases, and complex business logic
* **Microservices systems** with proper service communication and error handling
* **Data processing platforms** with queues, events, and real-time processing
* **SaaS applications** with user management, billing, and multi-tenancy
* **Integration hubs** that orchestrate multiple external services
**Perfect for new projects**: Leap works great for spinning up new systems or building isolated components within existing products. Generate your architecture with AI, then develop however you prefer.
## How it works
Tell Leap what you want to build. Be specific about features, integrations, and requirements.
Leap creates your complete architecture with services, APIs, databases, and infrastructure. Review changes with diffs before deploying.
Test in preview environments, deploy to production, then add features using AI or your regular development workflow.
## Built on proven technology
Leap generates apps using [Encore.ts](https://encore.dev), the open-source framework trusted by thousands of developers for building distributed systems. This foundation gives you:
* **High-performance APIs** with multi-threaded Rust validation
* **Infrastructure-as-code** with automatic provisioning on AWS/GCP
* **Type-safe** service communication across your entire system
* **Built-in observability** with distributed tracing and metrics
**Why Encore.ts?** Unlike frameworks that require complex setup, Encore handles infrastructure, service communication, and deployment automatically. Your generated apps are production-ready from day one. [Learn more about Encore →](https://encore.dev/docs/introduction)
## Ready to build?
Generate a production system in 3 minutes
***
# Quickstart
Source: https://docs.leap.new/getting-started/quickstart
Create a full-stack application with backend APIs, database, and cloud deployment in under 3 minutes
# Build a production app in 3 minutes
This quickstart takes you from zero to a deployed, production-ready application in under 3 minutes. You'll build a **movie recommendation API** with real backend services, database integration, and live deployment.
**Why a movie API?** It showcases real backend logic, database operations, external API integrations, and multiple service endpoints - everything you need for production applications.
**Built on Encore.ts**: Leap generates apps using [Encore's framework](https://encore.dev/docs) for type-safe distributed systems. Unlike other AI tools that just generate code snippets, you get complete systems with APIs, databases, and infrastructure that actually work together. [Learn more →](https://encore.dev/docs/introduction)
## What you'll build
By the end of this guide, you'll have:
* **Backend API service** with multiple endpoints
* **Database integration** for storing movie data
* **External API integration** with TMDB (The Movie Database)
* **Live architecture diagrams** showing your system
* **Deployed application** running on your cloud
* **GitHub repository** with full source code
## Generate your app
### Describe what you want to build
In the chat interface, describe your system:
```
Build a movie recommendation API service that:
- Gets popular movies from TMDB API
- Stores user favorites in a database
- Provides search functionality
- Has endpoints for getting movie details
- Includes user rating system
```
### Watch Leap create your system
Leap generates your complete application in 30-60 seconds, including:
* Backend services with type-safe APIs
* Database schema for users and favorites
* TMDB integration for movie data
* Authentication endpoints
* Rating and recommendation logic
Here's what the generated code looks like:
```typescript theme={null}
// movies/encore.service.ts
import { api } from "encore.dev/api";
import { SQLDatabase } from "encore.dev/storage/sqldb";
const db = new SQLDatabase("movies", {
migrations: "./migrations",
});
export const search = api(
{ method: "GET", path: "/movies/search" },
async ({ query }: { query: string }) => {
// Your movie search logic here
return await searchMovies(query);
}
);
```
**How it works**: Each `encore.service.ts` file defines your APIs and Encore automatically handles the HTTP endpoints, database connections, and service communication. [See how services work →](https://encore.dev/docs/primitives/services-and-apis)
## Explore what you built
Once generation completes, you'll see several tabs:
**Your complete codebase**
* `movies/` - Main service with API endpoints
* `users/` - User management and authentication
* Database schemas and migrations
* Type-safe service communication
**Live application**
* Interactive frontend showing movie recommendations
* Real API calls to your backend services
* Live data from TMDB integration
* Fully functional user interface
**System diagrams**
* Live diagrams showing service relationships
* Database connections and schemas
* External API integrations
* Updates automatically as your app evolves
**Service catalog**
* Interactive API documentation
* Test your endpoints with real data
* Authentication and error handling
* Request/response schemas
## Deploy your app
### Deploy to Encore Cloud
Click **Deploy** and your app goes live in under 60 seconds with:
* Automatic HTTPS and domain
* Production database provisioning
* Secrets management for API keys
* Built-in monitoring and tracing
### Connect to GitHub (optional)
Click **GitHub** to:
* Create a repository with your code
* Enable automatic deployments on push
* Set up collaborative development workflow
### Deploy to your own cloud (optional)
Want to deploy to your own AWS or GCP account? See our [deployment guides](/deployment/overview):
* Connect your cloud account in Deploy settings
* Your app deploys to your own infrastructure
* No vendor lock-in or runtime dependencies
## What you just built
Congratulations! You've created a **production-ready distributed system** that includes:
* **Multiple microservices** with type-safe communication
* **Database integration** with automatic migrations
* **External API integration** with proper error handling
* **Authentication and authorization** built-in
* **Distributed tracing** for debugging and performance
* **Automatic API documentation** that stays in sync
* **Live architecture diagrams** for understanding your system
* **Built-in observability** with metrics and logs
* **Git integration** for version control and collaboration
* **Preview environments** for testing changes safely
* **Infrastructure as code** for reproducible deployments
* **Type safety** across your entire system
## Next step
Learn how your movie API works - the interface, services, infrastructure, and development patterns that apply to any Leap application
# Anthropic Integration
Source: https://docs.leap.new/integrations/anthropic
Add Claude AI capabilities for document analysis, customer support, and intelligent content generation
Leap makes it easy to integrate [Anthropic's Claude](https://anthropic.com) for advanced AI capabilities. Describe what you want to build, and Leap generates the integration with proper message handling and safety features.
## How it works
1. **Describe your Claude integration needs** in a prompt
2. **Leap generates the integration** with Anthropic's API
3. **Add your API key** to secrets when prompted
**LLM results vary**, but we've had success getting Anthropic integrations working in one or two shots with proper conversation management.
## Example prompt
```
Add Claude AI for customer support that analyzes user messages,
provides intelligent responses based on documentation,
and escalates complex issues to human agents automatically
```
# Import Databases
Source: https://docs.leap.new/integrations/import-databases
Import your existing databases using a connection string
Leap supports seamless integration with existing PostgreSQL databases. By providing a connection string, Leap automatically reads your schema and generates full-stack applications that leverage your existing data models.
## Features
* **One-Click Import:** Connect to any PostgreSQL-compatible database using a connection string.
* **Automatic Schema Reading:** Leap analyzes your database schema, including tables, relationships, and constraints, to understand your data model.
* **Contextual App Generation:** Applications generated by Leap are aware of your data structure and use it intelligently throughout the backend and frontend.
* **Schema Sync:** Use the Pull database schema button in the Infrastructure tab to sync your schema changes at any time.
* **Environment Portability:** Applications continue to function seamlessly across environments when deployed with Encore Cloud.
## Use Cases
* **Dashboards**\
Build interactive dashboards to visualize, explore, and manage your data in real time.
* **CRM Extensions**\
Integrate with user databases to trigger actions, automate workflows, and enrich customer data.
* **Custom Agents**\
Combine your database with an AI API key to create agents that automate internal processes and decision-making.
* **Internal Tools**\
Streamline operations with tools for user lookups, permission management, approval flows, and more.
## Step-by-step guide
### **1. Connect your database**
Provide your PostgreSQL connection string to import your existing database. You can do this either in the prompt area when creating a new app, or in the **Infrastructure** view within an existing app, by clicking **Connect database** in the **External databases** section.
### **2. Leap automatically analyzes your schema**
Leap automatically reads and understands your schema, adding this to the context of your application. You don't need to do anything.
### **3. Prompt to build your app**
Prompt Leap to build an application, it will automatically know how to use your database and what the schema looks like.
### 4. Pull in updates
Your database schema can continue evolving outside of Leap using your preferred tools and workflows. If changes occur, click **Pull database schema** in the Infrastructure viewer to update Leap’s understanding of your schema automatically.
## Supported Databases
Database imports work with any PostgreSQL-compatible provider, including:
* AWS RDS PostgreSQL
* Google Cloud SQL
* Prisma Postgres
* Supabase
* Neon
* And many others
# OpenAI Integration
Source: https://docs.leap.new/integrations/openai
Integrate GPT models for content generation, AI chat, document analysis, and semantic search
Leap makes it easy to add AI capabilities using [OpenAI's GPT models](https://openai.com). Just describe your AI features, and Leap generates the integration with proper rate limiting and error handling.
## How it works
1. **Describe your AI needs** in a prompt
2. **Leap generates the integration** with OpenAI's API
3. **Add your API key** to secrets when prompted
**LLM results vary**, but we've had success getting OpenAI integrations working in one shot with proper streaming and error handling.
## Example prompt
```
Add AI content generation using OpenAI that creates blog posts from user topics,
generates product descriptions from specifications,
and provides AI chat support with conversation history
```
# Other Integrations
Source: https://docs.leap.new/integrations/other
Integrate with 50+ popular services including Twilio, Discord, Auth0, Algolia, and hundreds more
Leap can integrate with hundreds of popular services and APIs. Just describe what you want to build, and Leap generates the integration code with proper error handling, authentication, and best practices.
**LLM results vary**, but we've had success getting Anthropic integrations working in one or two shots with proper conversation management.
## Communication & Messaging
**[Twilio](https://twilio.com)**
```
Add SMS notifications using Twilio for order updates and
two-factor authentication with phone verification
```
**[Discord](https://discord.com)**
```
Send Discord notifications to channels when important events
happen with rich embeds and mentions
```
**[Slack](https://slack.com)**
```
Create Slack bot that posts updates to channels and responds
to commands for system status
```
**[SendGrid](https://sendgrid.com)**
```
Implement SendGrid for transactional emails with templates,
analytics, and delivery optimization
```
**[Mailgun](https://mailgun.com)**
```
Add Mailgun integration for email sending, validation,
and detailed delivery tracking
```
## AI & Machine Learning
**[Replicate](https://replicate.com)**
```
Add image generation using Replicate's hosted AI models
with queue management for processing
```
**[Hugging Face](https://huggingface.co)**
```
Integrate Hugging Face models for text classification,
sentiment analysis, and custom ML workflows
```
**[Stability AI](https://stability.ai)**
```
Add Stable Diffusion image generation with prompt optimization
and batch processing capabilities
```
**[Cohere](https://cohere.ai)**
```
Implement Cohere for text generation, semantic search,
and classification with multilingual support
```
## Analytics & Monitoring
**[Google Analytics](https://analytics.google.com)**
```
Add Google Analytics 4 tracking for page views, conversions,
and custom events with enhanced ecommerce
```
**[Amplitude](https://amplitude.com)**
```
Implement Amplitude for user behavior tracking, cohort analysis,
and product insights with custom properties
```
**[Sentry](https://sentry.io)**
```
Add Sentry for error tracking, performance monitoring,
and release health with custom context
```
**[DataDog](https://datadoghq.com)**
```
Integrate DataDog for application performance monitoring,
logs, and custom metrics dashboards
```
**[New Relic](https://newrelic.com)**
```
Add New Relic for full-stack observability, distributed tracing,
and infrastructure monitoring
```
## Payment Processing
**[PayPal](https://paypal.com)**
```
Add PayPal integration for checkout, subscriptions,
and marketplace payments with buyer protection
```
**[Square](https://squareup.com)**
```
Implement Square for in-person and online payments
with inventory management integration
```
**[Paddle](https://paddle.com)**
```
Add Paddle for SaaS subscription billing with tax handling,
invoicing, and global payment methods
```
**[LemonSqueezy](https://lemonsqueezy.com)**
```
Integrate LemonSqueezy for selling digital products
with automatic tax compliance and fraud protection
```
## Social Media & Content
**[GitHub](https://github.com)**
```
Add GitHub integration for repository management, issue tracking,
and automated deployment workflows
```
**[YouTube](https://youtube.com)**
```
Integrate YouTube API for video metadata, playlist management,
and content discovery features
```
**[Twitter/X](https://twitter.com)**
```
Add Twitter API for social media posting, thread creation,
and media uploads with rate limiting
```
**[Instagram](https://instagram.com)**
```
Implement Instagram Basic Display API for photo feeds
and user content integration
```
**[TikTok](https://tiktok.com)**
```
Add TikTok API integration for content discovery
and social media management features
```
## Search & Discovery
**[Algolia](https://algolia.com)**
```
Add Algolia for instant search with typo tolerance,
faceting, and personalized results
```
**[Elasticsearch](https://elastic.co)**
```
Implement Elasticsearch for full-text search, analytics,
and log aggregation with custom scoring
```
**[Pinecone](https://pinecone.io)**
```
Add Pinecone for semantic search, recommendation systems,
and AI-powered content discovery
```
**[Meilisearch](https://meilisearch.com)**
```
Integrate Meilisearch for fast, typo-tolerant search
with instant results and faceted filtering
```
## Management Tools
**[Linear](https://linear.app)**
```
Integrate Linear for project management, issue tracking,
and automated workflow updates
```
**[Notion](https://notion.so)**
```
Connect Notion for content management, documentation sync,
and collaborative workspace features
```
**[Airtable](https://airtable.com)**
```
Add Airtable integration for flexible database management
with API access and automation workflows
```
## Authentication & Security
**[Auth0](https://auth0.com)**
```
Implement Auth0 for user authentication, single sign-on,
and multi-factor authentication with social logins
```
**[Clerk](https://clerk.dev)**
```
Add Clerk for complete user management with authentication,
user profiles, and organization features
```
**[WorkOS](https://workos.com)**
```
Integrate WorkOS for enterprise SSO, directory sync,
and compliance features for B2B applications
```
**[Okta](https://okta.com)**
```
Add Okta integration for enterprise identity management,
SSO, and API access management
```
## Maps & Location
**[Google Maps](https://developers.google.com/maps)**
```
Add Google Maps for location services, geocoding,
and interactive maps with custom markers
```
**[Mapbox](https://mapbox.com)**
```
Implement Mapbox for custom map styling, navigation,
and location-based features with vector tiles
```
**[Here Maps](https://here.com)**
```
Integrate Here Maps for routing, geocoding,
and fleet management with real-time traffic
```
## CRM & Sales
**[HubSpot](https://hubspot.com)**
```
Integrate HubSpot for contact management, lead tracking,
and marketing automation with custom properties
```
**[Salesforce](https://salesforce.com)**
```
Add Salesforce integration for customer relationship management,
opportunity tracking, and sales automation
```
**[Pipedrive](https://pipedrive.com)**
```
Implement Pipedrive for sales pipeline management,
deal tracking, and activity automation
```
## Productivity & Collaboration
**[Google Workspace](https://workspace.google.com)**
```
Add Google Workspace integration for document management,
calendar sync, and collaboration features
```
**[Microsoft 365](https://microsoft.com/microsoft-365)**
```
Integrate Microsoft 365 for document processing,
email management, and team collaboration
```
**[Zapier](https://zapier.com)**
```
Add Zapier webhooks for workflow automation
and integration with 5000+ applications
```
**[Make](https://make.com)**
```
Implement Make for complex workflow automation
with visual scenario building and data transformation
```
***
**Need a specific integration?** Join our [Discord community](https://encore.dev/discord) where developers share successful integration prompts and get help with custom implementations.
**Popular integration combinations:**
* **SaaS Stack**: Stripe + Resend + PostHog + Supabase for complete SaaS functionality
* **E-commerce**: Stripe + Cloudinary + SendGrid + Google Analytics for online stores
* **AI Platform**: OpenAI + Pinecone + Supabase + Vercel for AI-powered applications
* **Enterprise**: Auth0 + Salesforce + Slack + DataDog for business applications
# PostHog Integration
Source: https://docs.leap.new/integrations/posthog
Comprehensive analytics with event tracking, feature flags, conversion funnels, and user insights
Leap makes it easy to add comprehensive analytics using [PostHog](https://posthog.com). Just describe your tracking needs, and Leap generates the integration with event tracking, feature flags, and user analytics.
## How it works
1. **Describe your analytics needs** in a prompt
2. **Leap generates the integration** with PostHog's API
3. **Add your project API key** to secrets when prompted
**LLM results vary**, but we've had success getting PostHog integrations working in one shot with proper event tracking.
## Example prompt
```
Add PostHog analytics to track user signups,
feature usage, and conversion funnels with A/B testing for new features
and session recording for debugging user issues
```
# Prisma ORM
Source: https://docs.leap.new/integrations/prisma
Instructions for using Prisma ORM in Leap
Leap makes it easy to use ORMs like [Prisma](https://www.prisma.io/orm). Just describe your data design, and Leap generates the integration.
## How it works
1. **Describe your data layer** in a prompt, including the specifics from the example prompt below
2. **Leap generates the integration**
3. **On build** Prisma generates migration files and Leap generates the database client
**LLM results vary**, but we've had success getting Prisma set up and working on the first try—including schema definitions, client imports, and connection handling.
## Example prompt
```
Each Encore service must import the db and create its own instance of a PrismaClient, e.g:
import db from "../dbs/main";
import { PrismaClient } from "../dbs/main/gen/client";
export const prisma = new PrismaClient({ datasources: { db: {url: db.connectionString}}});
Migration files will be automatically generated by Prisma on build.
The client will be automatically generated on build and placed in the ./main/gen/client module
```
# Resend Integration
Source: https://docs.leap.new/integrations/resend
Modern email delivery with transactional emails, templates, and delivery optimization
Leap makes it easy to add email functionality using [Resend](https://resend.com). Just describe what you want, and Leap generates the integration with proper error handling and best practices.
## How it works
1. **Describe your email needs** in a prompt
2. **Leap generates the integration** with Resend's API
3. **Add your API key** to secrets when prompted
**LLM results vary**, but we've had success getting Resend integrations working in one or two shots.
## Example prompt
```
Add email sending using Resend for welcome emails when users sign up,
password reset links with secure tokens,
and order confirmations with PDF receipts attached
```
# Stripe Integration
Source: https://docs.leap.new/integrations/stripe
Complete payment processing with subscriptions, webhooks, customer management, and billing
Leap makes payment processing simple with Stripe. Describe your payment requirements and get a complete integration with webhooks and secure payment handling.
## How it works
1. **Describe your payment needs** in a prompt
2. **Leap generates the integration** with Stripe's APIs
3. **Add your API keys** to secrets when prompted
**LLM results vary**, but we consistently get working Stripe integrations in one shot, including webhook verification.
## Example prompt
```
Add Stripe payments for subscription billing with three tiers,
one-time product purchases, and automatic invoice generation with
webhook handling for failed payments and cancellations
```
# Tigris Integration
Source: https://docs.leap.new/integrations/tigris
S3-compatible object storage with global edge distribution for files, images, and media
Leap makes object storage simple with [Tigris](https://tigrisdata.com). Get S3-compatible storage with global edge distribution for your files and media.
## How it works
1. **Describe your storage needs** in a prompt
2. **Leap generates Tigris integration** with bucket management
3. **Add your credentials** to secrets when prompted
**LLM results vary**, but Tigris integrations typically work in one shot since it uses the standard S3 API.
## Example prompt
```
Add file storage using Tigris for user profile images with automatic resizing,
document uploads with virus scanning, and video storage with CDN delivery
and signed URLs for private content
```
# Plans and Credits
Source: https://docs.leap.new/plans-credits/overview
An overview of Leap plans and the credit system
Leap uses AI to generate code and build applications. Running AI models requires powerful datacenters, which come at a cost. To keep billing simple and aligned with the value you get, Leap uses a credit-based model:
* Each plan gives you a monthly balance of credits.
* Each time you ask the AI to do something, it will use an amount of credits which are deducted from your balance. Every request is unique and therefore uses a different amount of credits.
## Plans
### Free
Our Free plan is designed to help you get started with Leap.
* You receive 15 monthly credits, with a daily limit of 5 credits.
* This means if you use the maximum daily allowance, you’ll get about **3 days of free usage per month**.
* On average Free plan users can send **\~3-5** AI requests within the daily limit.
* For more usage, you can upgrade to a paid plan.
### Leap Pro
Leap Pro includes everything in the Free plan, plus:
* **No daily usage limits**
* **More monthly credits** (based on the package you choose)
* **Custom domains**
* **Early access to new features**
Available Pro packages:
* **Pro 100:** 100 Credits @ \$30/month
* **Pro 200:** 200 Credits @ \$60/month
* **Pro 300:** 300 Credits @ \$90/month
* **Pro 400:** 400 Credits @ \$120/month
* **Pro 500:** 500 Credits @ \$150/month
* **Pro 1000:** 1000 Credits @ \$300/month
* **Pro 2500:** 2500 Credits @ \$750/month
#### Example
* On average, Free plan users can send **\~3-5 requests per day**, or about **10-15 requests per month**.
* With the **Pro 100 plan**, you'd get about **100 requests per month**.
* With the **Pro 200 plan**, you’d get about **200 requests per month**.
* Etc.
Keep in mind that each request is unique and will use a different amount of credits depending on the scope of what you're asking the AI to do. Small requests use fewer credits (so you can do more of them), and big requests use more credits (so you can't do as many before running out of credits).
#### Upgrading to Leap Pro
To upgrade to Leap Pro, click the **Upgrade plan** button in the lefthand sidenav in Leap.
#### Buy Extra Credits
One time purchases are available to Leap Pro subscribers that want to top up with credits without upgrading to a higher monthly plan.
Do this by opening **My subscription** and click **Buy extra credits**.
This lets you add between 50 - 5000 credits to your balance with a one time purchase.
Extra credits are added to your balance immediately and remain valid for 2 months from the date of purchase.\
\
Please note that credits included in paid plans are priced lower than standalone credit top-ups. If you find yourself buying extra credits frequently, upgrading your plan is usually the more cost-effective option.
### Leap Team
Leap Team is a separate paid plain, available to organizations. It includes everything in the Leap Pro plan, plus:
* **Shared Team Workspace**
* **Real-time collaboration**
* **Group billing**
* **Priority support**
Available Team plan packages with monthly credits for your organization to share:
* Team 500 plan — **\$500** worth of monthly credits
* Team 1000 plan — **\$1,000** worth of monthly credits
* Team 1500 plan — **\$1,500** worth of monthly credits
* Team 2000 plan — **\$2,000** worth of monthly credits
* Team 2500 plan — **\$2,500** worth of monthly credits
#### Upgrading to the Team plan
First, create an organization by clicking **Invite Team** in the Leap lefthand sidebar.
Once you've created your organization, click \*\*Team Subscription \*\*in the sidebar, and click Upgrade in the modal.
Your organization account comes with a separate workspace and subscription from your personal account. If you already have an app you want to move over to your org workspace, contact [hello@leap.new](mailto:hello@leap.new) for assistance.
## Changing plans
#### Upgrading
When you upgrade, we charge your saved payment method the full price of the new plan, add the full amount of new credits to your account immediately, and reset your renewal date to one month from today.
Don't worry, any credits remaining in your current plan are kept.
#### Downgrading
When you downgrade, the change takes effect at your next renewal. Your current credits remain available until then.
## Managing your subscription & payments
To change plans, cancel, see your billing history, or update your payment details, click **My subscription** in the lefthand sidenav in Leap.
This will open a modal where you can see your credits and let you take the following actions:
* Click **Change plan** to upgrade, downgrade, or cancel your paid plan.
* Click **Manage billing & payment settings** to update payment details and see your billing history.
# Authentication using Clerk
Source: https://docs.leap.new/tutorials/authentication
A step by step guide for implementing user authentication.
Leap recommends using [Clerk](https://clerk.com) for user authentication, it's a scalable and enterprise-ready authentication solution that comes with a generous free tier.
Leap has an integration with Clerk, which handles all the implementation steps to set up user authentication for your app. Here's how you use it.
**1. Prompt Leap**
Once you've created your app and are ready to add user authentication, paste this prompt in the chat box and send:
```text theme={null}
Implement authentication using Clerk
```
Leap will now implement the auth flow using Clerk and set up all the required public and secret keys.
**2. Create a Clerk account and claim your app**
* Once Leap has finished, you will see a new **Users** page in Leap's top navigation, open it.
* Here you will see a message instructing you to **claim your application**, click the link to go to Clerk's website where you can create an account and then claim your app.
* Once you've done this, you're app is all set with user authentication for the Preview and any Staging environments you create.
## Best practices before releasing your app
**Verify the code that Leap generated**
Authentication is an important part of your application. We recommend always spending some time verifying that the implementation is correct. Ask a developer colleague or friend if you need help.
* You can ask Leap to point you to files to review, open them and confirm:
* A top-level provider or wrapper for Clerk on the client.
* Server routes or middleware that verify the session using the secret key.
* Example protected routes that check for a signed-in user.
**Test the full auth flow**
* In your running app, click **Sign up** or **Sign in** and complete the flow.
* Visit a protected page to confirm redirect and access rules.
**Production readiness**
* When Leap sets up the Clerk integration, it uses Clerk's development instance. This is Clerk's default for development and staging environments.
* Before releasing your app to the public, Clerk recommends creating a Production instance. [Learn more in Clerk's production readiness guide](https://clerk.com/docs/guides/development/deployment/production)
# Encore Services
Source: https://docs.leap.new/understanding-your-leap-app/encore-services
How encore.service.ts files work to define APIs, databases, and business logic with automatic infrastructure
The core of any Leap-generated app is built with **Encore.ts services**. Each `encore.service.ts` file defines a microservice with its APIs, database connections, and business logic.
## How services work
```typescript theme={null}
// users/encore.service.ts
import { api } from "encore.dev/api";
import { SQLDatabase } from "encore.dev/storage/sqldb";
// This creates a database for this service
const db = new SQLDatabase("users", {
migrations: "./migrations",
});
// This creates an HTTP API endpoint
export const createUser = api(
{ method: "POST", path: "/users" },
async (data: CreateUserRequest): Promise => {
// Your business logic here
return await db.queryRow`
INSERT INTO users (email, name)
VALUES (${data.email}, ${data.name})
RETURNING *
`;
}
);
```
## What makes this special
* **Automatic infrastructure**: Encore creates the database, HTTP endpoints, and connections
* **Type safety**: Full TypeScript support across services with automatic validation
* **Service communication**: Services can call each other with type-safe RPC
* **Built-in observability**: Automatic tracing, metrics, and logging
**Learn more**: Encore.ts handles all the infrastructure complexity so you can focus on business logic. [See how services work →](https://encore.dev/docs/primitives/services-and-apis)
# Leap Interface
Source: https://docs.leap.new/understanding-your-leap-app/leap-interface
Navigate the Leap interface and understand the Code, Preview, Architecture, Infrastructure, and Service Catalog tabs
When you generate an app with Leap, you get a complete development interface with multiple views of your system. Here's how to navigate and understand what you're looking at.
## The main interface tabs
Your app opens with several tabs that give you different views of your system:
**Your complete codebase structure**
* File explorer showing your services and components
* Real-time code editing with syntax highlighting
* Git change tracking and diff viewing
* Direct integration with your GitHub repository
The file structure follows Encore's service-based architecture where each folder represents a microservice.
**Live running application**
* Your frontend connected to real backend APIs
* Live data from external services
* Real user interactions and functionality
* Instant updates when you make changes
This isn't a mock—it's your actual app running in a preview environment.
**System visualization**
* Live diagrams showing how your services connect
* Database relationships and schemas
* External API integrations
* Auto-updating as your system evolves
Think of this as your system's blueprint that stays current with your code.
**Cloud resources and configuration**
* Secrets management for API keys
* Database and compute provisioning
* Environment configurations
* Deployment status and health
This is where you manage the infrastructure that powers your app.
**API documentation and testing**
* Interactive endpoint documentation
* Test your APIs with real data
* Request/response schemas
* Authentication requirements
Your APIs are automatically documented and ready to test.
# Monitoring & Observability
Source: https://docs.leap.new/understanding-your-leap-app/monitoring-and-observability
Enterprise-grade distributed tracing, live architecture diagrams, and performance monitoring built into every Leap app
Your Leap-generated app comes with enterprise-grade observability that would normally take months to set up. This is automatically generated from your code and stays in sync as your app evolves.
## Accessing the Encore Cloud dashboard
To see your app's full observability:
1. **Click "Deploy"** to deploy your app to Encore Cloud
2. **Visit your app dashboard** at `https://app.encore.cloud`
3. **Explore your running system** with production-grade monitoring
## What you get automatically
### Live Architecture Diagrams
Real-time system diagrams showing service dependencies, database connections, external API integrations, and performance bottlenecks. These update automatically as your system evolves.
### Distributed Tracing
See exactly how requests flow through your services. Identify slow database queries, debug errors with full stack traces, and get performance profiling across your entire system.
### API Explorer
Interactive API documentation built into the dashboard. Test your APIs directly, see real request/response examples, and monitor authentication flows and performance.
### System Metrics
Production monitoring with request rates, response times, error rates, database performance, and infrastructure costs. All the metrics you need to keep your system healthy.
The Encore dashboard gives you the same observability that large companies spend months building. It's automatically generated from your code, so it stays in sync as your app evolves. [Learn more about Encore Cloud →](https://encore.cloud)