> 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

## Resource: Introduction

## Article: Introduction

## Article Link: https://dev.wix.com/docs/sdk/frontend-modules/pay/introduction.md

## Article Content:

# Introduction
To process payments on your site, first set up your site to accept payments
 as described in [About Accepting Payments](https://support.wix.com/en/article/about-accepting-payments).
 When setting up your site to accept payments, be sure to select the payment
 methods you want to offer and [set your payment currency](https://support.wix.com/en/article/setting-your-currency-for-accepting-payments). 
You can also set up a list of alternative currencies to display your prices in. Use the [currency objects](https://dev.wix.com/docs/sdk/frontend-modules/pay/currencies/introduction.md) and the [currency conversion dropdown element](https://support.wix.com/en/article/adding-and-setting-up-a-currency-converter-in-wix-stores) to set up and display product prices in different currencies.

 ### Typical Payment Lifecycle

> **Note:** The SDK frontend module contains only the [Currencies](https://dev.wix.com/docs/velo/apis/wix-pay-frontend/currencies/introduction.md) submodule of the `wix-pay-frontend` Velo API. The `wix-pay-backend` Velo API has no equivalent module in the SDK.
>
> Use this module's functionality, in conjunctions with the `wix-pay-frontend` and `wix-pay-backend` Velo APIs. 

 The following list outlines the steps taken in a typical payment lifecycle:

 1. A site visitor clicks a button to start the payment process.
 1. The button's event handler calls a backend function.
 1. A `PaymentInfo` object containing information about
    the payment, such as the payment amount, is created in the backend function.
 1. The backend function calls [`createPayment()`](https://dev.wix.com/docs/velo/apis/wix-pay-backend/create-payment.md) from the `wix-pay-backend` Velo API using the
    `PaymentInfo` object and returns the generated
    `Payment` object to the calling client-side event handler.
 1. The event handler then calls the [`startPayment()`](https://dev.wix.com/docs/velo/apis/wix-pay-frontend/start-payment.md) from the `wix-pay-frontend` Velo API
    with the id from the `Payment` object, which opens
    the payment popup on your site.
 1. The site visitor enters the payment information.
 1. The event handler optionally handles the returned `PaymentResult`.
 1. Handle additional status updates to the payment transaction using the
    [`onPaymentUpdate()`](https://dev.wix.com/docs/velo/apis/wix-pay-backend/events/on-payment-update.md) event.

 To use the Pay API, import `* as wixSitePay` from the `@wix/site-pay` module:

   ```javascript
   import * as wixSitePay from '@wix/site-pay';
   ```

> **Note:**
 To work with the Pay API, you need to save and publish your site.