> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # Package: appInstallations # Webhook link: https://dev.wix.com/docs/api-reference/app-management/app-installations/app-installation-deleted.md ## Introduction Triggered when an app installation record is permanently removed. This happens when the site the app is installed on is deleted, or when the app transitions to an [Apps Created by Wix](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/platform/about-apps-created-by-wix.md) app. It doesn't trigger when a site owner uninstalls the app. In that case, `status` changes to `UNINSTALLED` and [App Installation Updated](https://dev.wix.com/docs/api-reference/app-management/app-installations/app-installation-updated.md) triggers. --- ## REST API ### Schema ``` Webhook: App Installation Deleted Description: Triggered when an app installation record is permanently removed. This happens when the site the app is installed on is deleted, or when the app transitions to an [Apps Created by Wix](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/platform/about-apps-created-by-wix.md) app. It doesn't trigger when a site owner uninstalls the app. In that case, `status` changes to `UNINSTALLED` and [App Installation Updated](https://dev.wix.com/docs/api-reference/app-management/app-installations/app-installation-updated.md) triggers. Event body: - name: id | type: string | description: Unique event ID. Allows clients to ignore duplicate events. - name: entityFqdn | type: string | description: Fully qualified domain name of the entity associated with the event. - name: slug | type: string | description: Event name. - name: entityId | type: string | description: ID of the entity associated with the event. - name: eventTime | type: string (date-time) | description: Event timestamp. - name: triggeredByAnonymizeRequest | type: boolean | description: Whether the event was triggered as a result of a privacy regulation application such as GDPR. - name: originatedFrom | type: string | description: If present, indicates the action that triggered the event. ``` ### Examples ```curl { "id": "b7d2c5e1-4a8f-49b3-9e6c-1d4f2a7b8e95", "entityFqdn": "wix.app.installations.v1.app_installation", "slug": "deleted", "entityId": "8046df3c-7575-4098-a5ab-c91ad8f33c47", "deletedEvent": { "deletedEntityAsJson": "{\"appInstallation\":{\"id\":\"8046df3c-7575-4098-a5ab-c91ad8f33c47\",\"instanceId\":\"a1b2c3d4-e5f6-7890-abcd-ef1234567890\",\"appId\":\"2b4d6452-e1a7-4f28-9747-13d77225e6b6\",\"appVersion\":\"1.234\",\"status\":\"INSTALLED\",\"siteInfo\":{\"siteUrl\":\"https://example.wixsite.com\",\"businessName\":\"My Business\",\"countryCode\":\"US\"},\"planInfo\":{\"planName\":\"Premium\",\"planStatus\":\"UPGRADED\"},\"firstInstallationDate\":\"2025-06-15T09:00:00.000Z\",\"createdDate\":\"2025-06-15T09:00:00.000Z\",\"updatedDate\":\"2026-03-05T11:42:00.000Z\",\"revision\":5}}" }, "eventTime": "2026-03-05T11:42:00.789012Z", "triggeredByAnonymizeRequest": false } ``` --- ## JavaScript SDK ### Schema ``` Webhook: onAppInstallationDeleted Description: Triggered when an app installation record is permanently removed. This happens when the site the app is installed on is deleted, or when the app transitions to an [Apps Created by Wix](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/platform/about-apps-created-by-wix.md) app. It doesn't trigger when a site owner uninstalls the app. In that case, `status` changes to `UNINSTALLED` and [App Installation Updated](https://dev.wix.com/docs/api-reference/app-management/app-installations/app-installation-updated.md) triggers. Payload: AppInstallationDeletedEnvelope - name: entity | type: AppInstallation | description: none - name: _id | type: string | description: App installation GUID. - name: instanceId | type: string | description: Unique identifier of the app instance on the site. Stable across uninstalls and reinstalls of the same app on the same site. - name: _createdDate | type: Date | description: Date and time the app installation was created. - name: _updatedDate | type: Date | description: Date and time the app installation was last updated. - name: revision | type: string | description: Revision number, which increments by 1 each time the app installation is updated. - name: firstInstallationDate | type: Date | description: Date and time the app was first installed on the site. Preserved across uninstalls and reinstalls. - name: siteInfo | type: SiteInfo | description: Information about the site the app is installed on. - name: siteId | type: string | description: Site GUID. - name: businessName | type: string | description: Business name displayed on the site. - name: siteUrl | type: string | description: Public URL of the site. - name: businessEmail | type: string | description: Business email address configured on the site. - name: countryCode | type: string | description: 2-letter country code in [ISO-3166 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format. - name: businessCategory | type: Categories | description: Business category the site belongs to. - name: primary | type: string | description: Primary site category. - name: secondary | type: array | description: Secondary site category. - name: premium | type: boolean | description: Whether the site has an active Premium subscription. - name: editorType | type: EditorType | description: Editor the site was created with. - enum: - EDITOR: Wix Editor. - ADI: Wix ADI. - EDITORX: Editor X. - STUDIO: Wix Studio. - HARMONY: Wix Harmony. - VIBE: Wix Vibe. - WIXEL: Wixel. - name: ownerEmail | type: string | description: Email address of the site owner. Returned only when `OWNER_EMAIL` is requested in the `fields` parameter and the app has the **Get Site Owner** permission. - name: accountId | type: string | description: GUID of the site owner's account. - name: planInfo | type: PlanInfo | description: Information about the plan the site owner purchased for the app. - name: planName | type: string | description: Name of the plan the site owner purchased for the app. - name: billingCycle | type: Cycle | description: Billing cycle of the purchased plan. - name: cycleType | type: CycleType | description: Type of the billing cycle. + `"UNKNOWN_UNIT"`: There is no information about the billing cycle. + `"ONE_TIME"`: The customer pays for unlimited usage of the app with a single payment. + `"RECURRING"`: The customer pays for a subscription to the app on a recurring schedule. - enum: ONE_TIME, RECURRING - name: cycleDuration | type: Duration | description: Duration of the billing cycle. Available only for `{"cycleType": "RECURRING"}`. - name: unit | type: DurationUnit | description: Unit of the billing cycle. - enum: - MONTH: Month. - YEAR: Year. - name: count | type: integer | description: Count of units that make up the billing cycle. - name: planStatus | type: PlanStatus | description: Current status of the purchased plan. - enum: - UPGRADED: The site owner upgraded the app to a paid plan. - CANCELED: The site owner upgraded the app to a paid plan and has since canceled it. - AUTO_RENEW_OFF: The plan is still active, but auto-renewal is turned off. - name: freeTrialInfo | type: FreeTrialInfo | description: Free trial details for the purchased plan, if a free trial is or was active. - name: status | type: FreeTrialStatus | description: Current free trial status. - enum: - IN_PROGRESS: The free trial is currently in progress. - ENDED: The free trial has ended. - name: endDate | type: Date | description: Date and time the free trial ended. Returned only after the free trial has ended. - name: endDate | type: Date | description: Date and time the plan expires. Returned only when auto-renewal is turned off. - name: appId | type: string | description: GUID of the installed app. - name: appVersion | type: string | description: Major version of the installed app. - name: status | type: Status | description: Current installation status of the app on the site. - enum: - INSTALLED: The app is currently installed on the site. - UNINSTALLED: The app was installed on the site and has since been removed. - name: review | type: ReviewInfo | description: Information about the review the site owner left for the app, if any. - name: _id | type: string | description: Review GUID. - name: date | type: Date | description: Date and time the review was published. - name: rating | type: integer | description: Rating the site owner left for the app, from 1 to 5. - name: title | type: string | description: Review title. - name: description | type: string | description: Review body text. - name: metadata | type: EventMetadata | description: none - name: instanceId | type: string | description: App instance GUID. - name: eventType | type: string | description: Event type. - name: identity | type: IdentificationData | description: The identification type and identity data. - ONE-OF: - name: anonymousVisitorId | type: string | description: GUID of a site visitor that has not logged in to the site. - name: memberId | type: string | description: GUID of a site visitor that has logged in to the site. - name: wixUserId | type: string | description: GUID of a Wix user (site owner, contributor, etc.). - name: appId | type: string | description: GUID of an app. - name: identityType | type: WebhookIdentityType | description: - enum: UNKNOWN, ANONYMOUS_VISITOR, MEMBER, WIX_USER, APP - name: accountInfo | type: AccountInfo | description: Details related to the account - name: accountId | type: string | description: GUID of the Wix account associated with the event. - name: parentAccountId | type: string | description: GUID of the parent Wix account. Only included when accountId belongs to a child account. - name: siteId | type: string | description: GUID of the Wix site associated with the event. Only included when the event is tied to a specific site. - name: _id | type: string | description: Event GUID. With this GUID you can easily spot duplicated events and ignore them. - name: entityFqdn | type: string | description: Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities. For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`. - name: slug | type: string | description: Event action name, placed at the top level to make it easier for users to dispatch messages. For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`. - name: entityId | type: string | description: GUID of the entity associated with the event. - name: eventTime | type: Date | description: Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. - name: triggeredByAnonymizeRequest | type: boolean | description: Whether the event was triggered as a result of a privacy regulation application (for example, GDPR). - name: originatedFrom | type: string | description: If present, indicates the action that triggered the event. - name: entityEventSequence | type: string | description: A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number. You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it. ``` ### Examples ```javascript import { appInstallations } from '@wix/app-installations'; appInstallations.onAppInstallationDeleted((event) => { // handle your event here }); ``` ```javascript import { createClient, AppStrategy } from '@wix/sdk'; import { appInstallations } from '@wix/app-installations'; const wixClient = createClient({ auth: AppStrategy({ appId: 'MY-APP-ID', publicKey: 'YOUR_APP_PUBLIC_KEY', }), modules: { appInstallations, }, }); wixClient.appInstallations.onAppInstallationDeleted((event) => { // handle your event here }); ``` ---