> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> 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`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# DeleteAction

# Package: actions

# Namespace: ActionCatalogService

# Method link: https://dev.wix.com/docs/api-reference/business-management/automations/actions/action-catalog/delete-action.md

## Introduction

Deletes an action from the specified app.

> **Note:** [Automations that include the deleted action](https://support.wix.com/en/article/wix-automations-creating-an-automation-with-the-new-builder#step-4-choose-an-action) can no longer execute it.

---

## REST API

### Schema

```
 Method: deleteAction
 Description: Deletes an action from the specified app.  > **Note:** [Automations that include the deleted action](https://support.wix.com/en/article/wix-automations-creating-an-automation-with-the-new-builder#step-4-choose-an-action) can no longer execute it.
 URL: https://www.wixapis.com/automations/actioncatalog/v1/action
 Method: DELETE
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  actionAppId, actionKey
 Method parameters: 
   query param name: actionAppId | type: actionAppId | description: GUID of the app that defines the action. | required: true | validation: format GUID
   query param name: actionKey | type: actionKey | description: Action key.  Learn about [adding an action to your app](https://dev.wix.com/docs/api-reference/business-management/automations/actions/add-an-action-to-your-app.md). | required: true | validation: minLength 1, maxLength 100
 Return type: DeleteActionResponse
  EMPTY-OBJECT {}

 Possible Errors:
   HTTP Code: 403 | Status Code: PERMISSION_DENIED | Application Code: UNAUTHORIZED_APP | Description: The caller is not authorized to manage actions for the requested app.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: ACTION_NOT_FOUND | Description: No action exists for the requested app and action key.


```

### Examples

### Delete action by app ID and key
```curl
curl -X DELETE 'https://www.wixapis.com/v1/action?actionAppId=e4c3e640-0b63-4bd9-8574-53f8c14e0236&actionKey=send-gift-card' \
    -H 'Authorization: <AUTH>'
```

---

## JavaScript SDK

### Schema

```
 Method: wixClientAdmin.automations.actionCatalog.deleteAction(actionAppId, options)
 Description: Deletes an action from the specified app.  > **Note:** [Automations that include the deleted action](https://support.wix.com/en/article/wix-automations-creating-an-automation-with-the-new-builder#step-4-choose-an-action) can no longer execute it.
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  actionAppId, options.actionKey, options
 Method parameters: 
   param name: actionAppId | type: string | description: GUID of the app that defines the action. | required: true | validation: format GUID
   param name: options | type: DeleteActionOptions  none | required: true 
        - name: actionKey | type: string | description: Action key.  Learn about [adding an action to your app](https://dev.wix.com/docs/api-reference/business-management/automations/actions/add-an-action-to-your-app.md). | required: true | validation: minLength 1, maxLength 100
 Return type: PROMISE<DeleteActionResponse>
  EMPTY-OBJECT {}

 Possible Errors:
   HTTP Code: 403 | Status Code: PERMISSION_DENIED | Application Code: UNAUTHORIZED_APP | Description: The caller is not authorized to manage actions for the requested app.
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: ACTION_NOT_FOUND | Description: No action exists for the requested app and action key.


```

### Examples

### Delete action
Deletes an action by its app ID and action key.

```javascript
import { actionCatalog } from "@wix/automations";

async function deleteAction() {
  await actionCatalog.deleteAction({
    actionAppId: "e4c3e640-0b63-4bd9-8574-53f8c14e0236",
    actionKey: "send-gift-card",
  });
}

/* Promise resolves to void */

```

### deleteAction (self-managed)
Self-managed SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md).

```javascript
import { createClient } from '@wix/sdk';
import { actionCatalog } from '@wix/automations';
// Import the auth strategy for the relevant access type
// Import the relevant host module if needed

const myWixClient = createClient ({
  modules: { actionCatalog },
  // Include the auth strategy and host as relevant
});


async function deleteAction(actionAppId,options) {
  const response = await myWixClient.actionCatalog.deleteAction(actionAppId,options);
};
```

---