Working with Apps
After deploying your code to a hosting platform, it is time to go to production and inform Inngest about your apps and functions. Check what Inngest Apps are if you haven't done it yet.
Sync a new app in Inngest Cloud
You can synchronize your app with Inngest using three methods:
- Manually;
- Automatically using an integration;
- With a curl command.
Manually
- Select your environment (for example, "Production") in Inngest Cloud and navigate to the Apps page. You’ll find a button named “Sync App” or “Sync New App”, depending on whether you already have synced apps.
- Provide the location of your app by pasting the URL of your project’s
serve()
endpoint and click on “Sync App”.
- Your app is now synced with Inngest. 🎉
Automatically using an integration
Curl command
Use the curl command to sync from your machine or automate the process within a CI/CD pipeline.
Send a PUT request to your application's serve endpoint using the following command:
curl -X PUT https://<your-app>.com/api/inngest
Before syncing with Inngest, ensure that the latest version of your code is live on your platform. This is because some platforms have rolling deploys that take seconds or minutes until the latest version of your code is live.
This is especially important when setting up your own automated process.
How and when to resync an app
To ensure that your functions are up to date, you need to resync your app with Inngest whenever you deploy new function configurations to your hosted platform.
If you are syncing your app through an integration, this process is automatically handled for you.
How to resync manually
- Navigate to the app you want to resync. You will find a “Resync” button at the top-right corner of the page.
- You will see a confirmation modal. Click on “Resync App”.
If your app location changes, enable the "Override" switch and edit the URL before clicking on "Resync App". Please ensure that the app ID is the same, otherwise Inngest will consider it a new app white resyncing.
Note that if your function configurations remain unchanged, a new sync will not be created when you try to resync. Instead, Inngest updates the "latest sync" time on the existing sync.
Archive an app
Apps cannot be directly archived. Instead, an app is considered archived when all of its functions are archived.
In the image below, you can see how archived apps look like in Inngest Cloud:
Future Archival Feature
Upcoming releases include a manual archival feature, which will provide users with the ability to archive apps based on specific requirements or preferences. Check our roadmap to track the progress on this feature.
Troubleshooting
Why is my app syncing to the wrong environment?
- Apps are synced to one environment. The
INNGEST_SIGNING_KEY
ensures that your app is synced within the correct Inngest environment. Verify that you assigned your signing key to the rightINNGEST_SIGNING_KEY
environment variable in your hosting provider or.env
file locally.
Why do I have duplicated apps?
- Each app ID is considered a persistent identifier. Since the app ID is determined by the ID passed to the serve handler from the Inngest client, changing that ID will result in Inngest not recognizing the app ID during the next sync. As a result, Inngest will create a new app.
Why is my sync inside unattached syncs?
- Failures in automatic syncs may not be immediately visible. In such cases, an unattached sync (a sync without an app) containing the failure message is created.
Why don’t I see my sync in the sync list?
If you're experiencing difficulties with syncing and cannot locate your sync in the sync list, consider the following scenarios:
- Deduped Syncs:
- When you resync the app with identical function configurations to a previous sync, a new sync is not created. Instead, we update the "latest sync" time on the existing sync.
- Solution: Check the latest sync time on the previous sync to verify if the update occurred as expected.
- Different App ID:
- If you resync the app after modifying the app ID, a new app is created, not a new sync within the existing app.
- Solution: Confirm the creation of a new app when changing the app ID.
- Syncing Errors:
- Manual Syncs and Manual Resyncs:
- Sync failures during manual operations are immediately displayed, preventing the creation of a new sync. The image below shows an example of an error while manually syncing:
- Solution: Review the displayed error message and address the syncing issue accordingly.
- Automatic Syncs (such as Vercel Integration):
-
Failures in automatic syncs may not be immediately visible. In such cases, an unattached sync (a sync without an app) containing the failure message is created.
-
Solution: Check for unattached syncs and address the issues outlined in the failure message. The image below shows the location of unattached syncs in Inngest Cloud:
-