Skip to content

Create and Deploy an iApp ​

iApps (iExec Applications) are decentralized applications that run on the iExec network. They leverage confidential computing to ensure data privacy and security while providing scalable off-chain computation.

About iApp Generator ​

Bootstrap TEE-compatible applications in minutes without any hardcoding skills, iApp Generator handles all the low-level complexity for you.

  • Select your project mode & language - Get started with either a basic or advanced setup, depending on your experience with the iExec framework. You can use Python or JavaScriptβ€”whichever you prefer!
  • Develop your iApp effortlessly - Write your application logic using familiar programming languages while the generator handles all TEE-specific configurations.
  • Access to TEEs easily - No need to dive into low-level requirements, create iApps that connect to TEEs in minutes.
  • Check and deploy iApps quickly - iApp Generator checks that your iApp complies with the iExec Framework and streamlines its deployment.

Prerequisites ​

Before getting started, make sure you have the following installed:

Installation ​

First, install the iApp Generator CLI tool using your preferred package manager:

sh
npm install -g @iexec/iapp
sh
yarn global add @iexec/iapp
sh
pnpm add -g @iexec/iapp
sh
bun add -g @iexec/iapp

Quick Start ​

Once installed, you can create and deploy your first iApp. The CLI will guide you through an interactive setup process to configure your project name, programming language, and template:

Terminal
$ iapp init
  _    _                
 (_)  / \   _ __  _ __  
 | | / _ \ | '_ \| '_ \ 
 | |/ ___ \| |_) | |_) |
 |_/_/   \_\ .__/| .__/ 
           |_|   |_|    

After the interactive setup, continue with development and deployment:

Development and Testing ​

Navigate to your project and run tests locally to simulate the TEE environment. The CLI will build a Docker image, run your app, and show you the results:

Terminal
$ iapp test

Deployment ​

After your tests pass and the package is built, you can deploy your iApp to a supported network. During deployment, you'll enter your DockerHub credentials, specify your app version, and push both standard and TEE-compatible images:

Terminal
$ iapp deploy
  ____             _             
 |  _ \  ___ _ __ | | ___  _   _ 
 | | | |/ _ \ '_ \| |/ _ \| | | |
 | |_| |  __/ |_) | | (_) | |_| |
 |____/ \___| .__/|_|\___/ \__, |
            |_|            |___/ 

Real Examples ​

Here are some real-world examples of iApps to help you understand how they work in practice.

Email Notification iApp ​

This iApp lets you send updates to your contacts without ever seeing their email addresses, privacy is preserved by design.

js
/* User runs: "Send updates to my contacts about my project" */
const contacts = loadProtectedData(); // User's protected contact list
contacts.forEach((contact) => {
  sendEmail(contact, projectUpdateMessage);
});
// β†’ Emails sent directly, you never see the addresses
python
# User runs: "Send updates to my contacts about my project"
contacts = load_protecteddata()  # User's protected contact list
for contact in contacts:
   send_email(contact, project_update_message)
# β†’ Emails sent directly, you never see the addresses

Oracle Update iApp ​

This iApp securely updates a price oracle using private trading data, ensuring sensitive information stays confidential.

js
// User runs: "Update price oracle with my private trading data"
const tradingData = loadProtectedData(); // User's protected trading history
const averagePrice = calculateWeightedAverage(tradingData);
updateOracleContract(averagePrice);
// β†’ Oracle updated with real data, trading history stays private
python
# User runs: "Update price oracle with my private trading data"
trading_data = load_protecteddata()  # User's protected trading history
average_price = calculate_weighted_average(trading_data)
update_oracle_contract(average_price)
# β†’ Oracle updated with real data, trading history stays private

Automated Transactions iApp ​

This iApp automates monthly payments using protected payment details, so financial information remains private.

js
// User runs: "Automate payments every month"
const paymentInfo = loadProtectedData(); // User's payment details
for (let month = 0; month < 12; month++) {
  processPayment(paymentInfo);
}
// β†’ Payments processed, payment details stay private
python
# User runs: "Automate payments every month"
payment_info = load_protecteddata()  # User's payment details
for month in range(12):
   process_payment(payment_info)
# β†’ Payments processed, payment details stay private