> 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

## Resource: About Wix CLI Backend Extensions

## Article: About Wix CLI Backend Extensions

## Article Link: https://dev.wix.com/docs/build-apps/develop-your-app/develop-an-app-with-the-cli/supported-extensions/backend/about-wix-cli-backend-extensions.md

## Article Content:

# About Wix CLI Backend Extensions

The Wix CLI allows you to add [backend extensions](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/about-backend-extensions.md) to your project.

The following backend extensions are available in the CLI:

- [Service plugin extensions](#service-plugin-extensions)
- [Event extensions](#event-extensions)
- [Data collections extensions](#data-collections-extensions)

You can add these extensions using the [generate](https://dev.wix.com/docs/wix-cli/command-reference/project-commands/generate.md) command.

You can also expose server-side logic to your frontend extensions through [backend APIs](#backend-apis), which you build using HTTP endpoints. Unlike the extensions above, HTTP endpoints aren't created with the `generate` command and aren't traditional extensions.

Backend extensions built with the CLI have execution limits, rate limits, and a time limit for backend functionality in previews. Read more about [limits](#limits).

<!-- not currently supported
- **Logging functionality for app projects:** You can use the CLI to view logs from the backend of any version of your project. Read more about [logging](#logging).
- **Limits:** Backend extensions have execution limits, rate limits, and a time limit for backend functionality in previews. Read more about [limits](#limits). -->

## Service plugin extensions

Service plugin extensions are a set of APIs defined by Wix that you can use to enable your project to inject custom logic into existing flows or to introduce entirely new flows.

For example, you can add an [Additional Fees Service Plugin](https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/extensions/additional-fees/additional-fees-service-plugin/introduction?apiView=SDK.md) to add custom charges and fees to carts and checkouts based on business-specific calculations and logic.

You can implement service plugin extensions in your project using the CLI. Read more about [service plugin extensions](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/service-plugins/add-service-plugin-extensions-with-the-wix-cli.md).

## Event extensions

Events are triggered when specific conditions on your project are met. These are conditions on a Wix user's site.

For example, an event might be triggered when a [booking is confirmed](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/booking-confirmed?apiView=SDK.md).

Your project can respond to these events using event extensions created in the CLI. Events in the CLI are built on JavaScript SDK webhooks, and event extensions subscribe your project to these webhooks behind the scenes. Read more about [event extensions](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/events/add-event-extensions-with-the-wix-cli.md).

## Data collections extensions

Data collections extensions let your app automatically create CMS data collections when it's installed on a site. You define each collection's schema, permissions, and optional initial data in your project files. When a Wix user installs your app, the collections are created in the site's CMS with the configuration you specified.

Read more about [data collections extensions](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/data-collections/add-a-data-collections-extension-with-the-wix-cli.md).

<!-- not currently supported
## Logging
You can view [logs](https://dev.wix.com/docs/wix-cli/legacy-clis/legacy-wix-cli-for-apps/app-development/command-reference.md) from the backend of any [version](invalid-url) in app projects using the `wix app logs` command. -->

## Limits

Backend extensions built with the CLI have execution limits, rate limits, and a time limit for backend functionality in previews.

<blockquote class="important">

**Important:**
Limits are subject to change. We'll notify you of any upcoming changes through the CLI and [Discord](https://discord.gg/aN9ubnrs2D), and note them here in the documentation.

</blockquote> 

### Execution rate limits

- **1000 CPU MS per request:** Backend requests taking longer than 1000 CPU MS to complete are terminated.
- **20 sub-requests:** Sub-requests are requests made from your backend extensions, such as calls to Wix APIs, in response to a request. Your project can make up to 20 sub-requests in response to each request. Sub-requests beyond the 20th will not be made.

### Request rate limit

- **1000 requests per second:** This is the limit for the total number of backend requests from your project. Requests beyond this are ignored.

### Backend functionality for previews

Previews generated by `npm run preview` last indefinitely. However, any backend extensions in these previews stop functioning after 3 days.

## Backend APIs

In the legacy Wix CLI for Apps, backend APIs were built with HTTP functions and web methods. In the current Wix CLI, backend APIs use [HTTP endpoints](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/http-endpoints/about-http-endpoints.md) instead. Learn how to [add HTTP endpoints to your project](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/http-endpoints/add-http-endpoints-to-your-project.md), or migrate existing [HTTP functions](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/http-endpoints/migrate/migrate-from-http-functions-to-http-endpoints.md) or [web methods](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/backend/http-endpoints/migrate/migrate-from-web-methods-to-http-endpoints.md) to HTTP endpoints.

## See also

- [About Extensions in the Wix CLI](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/about-extensions-in-the-wix-cli.md)
- [About the extensions.ts File](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/wix-cli/supported-extensions/about-the-extensions-ts-file.md)