# Modules (https://docs.salla.dev/twilight/react/api/modules)



Check here before writing your own request: the engine probably has a module for it. A module is a small object of plain async functions plus a `queries` object of TanStack Query options, built on the shared [client](https://docs.salla.dev/twilight/react/api/client). Import each from its own subpath, for example `@salla.sa/twilight-theme-engine/api/cart`.

Every module page follows the same order: what it is for with a minimal example, a table of methods, the query keys, and gotchas. For how to call a module in a loader or a component, see the [Overview](https://docs.salla.dev/twilight/react/api#make-a-request).

## Catalog [#catalog]

| Module                              | Covers                                                                           |
| ----------------------------------- | -------------------------------------------------------------------------------- |
| [`product`](https://docs.salla.dev/twilight/react/api/modules/product)   | One product, or a list from any source (latest, offers, brands, search and more) |
| [`category`](https://docs.salla.dev/twilight/react/api/modules/category) | One category, or the whole category tree                                         |
| [`brands`](https://docs.salla.dev/twilight/react/api/modules/brands)     | A page of the brands directory, or one brand                                     |
| [`home`](https://docs.salla.dev/twilight/react/api/modules/home)         | The home page components the merchant arranged                                   |
| [`page`](https://docs.salla.dev/twilight/react/api/modules/page)         | One custom store page (such as "About us") by slug                               |
| [`menu`](https://docs.salla.dev/twilight/react/api/modules/menu)         | The header and footer navigation menus                                           |
| [`blog`](https://docs.salla.dev/twilight/react/api/modules/blog)         | Articles, categories, tags and authors                                           |

## Shopping [#shopping]

| Module                              | Covers                                                                    |
| ----------------------------------- | ------------------------------------------------------------------------- |
| [`cart`](https://docs.salla.dev/twilight/react/api/modules/cart)         | One cart by id, with loyalty and gift information                         |
| [`wishlist`](https://docs.salla.dev/twilight/react/api/modules/wishlist) | The products the customer saved, paged by number                          |
| [`order`](https://docs.salla.dev/twilight/react/api/modules/order)       | Order lists, one order with shipments and ratings, and the thank-you data |

## Customer [#customer]

| Module                                      | Covers                                                  |
| ------------------------------------------- | ------------------------------------------------------- |
| [`user`](https://docs.salla.dev/twilight/react/api/modules/user)                 | The signed-in customer's profile, or `null` for a guest |
| [`profile`](https://docs.salla.dev/twilight/react/api/modules/profile)           | Deleting the account and saving a preference            |
| [`wallet`](https://docs.salla.dev/twilight/react/api/modules/wallet)             | Wallet balance and a page of transactions               |
| [`loyalty`](https://docs.salla.dev/twilight/react/api/modules/loyalty)           | The loyalty program and the customer's points balance   |
| [`notification`](https://docs.salla.dev/twilight/react/api/modules/notification) | The customer's notifications, and marking them read     |

## Store [#store]

| Module                                        | Covers                                                                               |
| --------------------------------------------- | ------------------------------------------------------------------------------------ |
| [`store`](https://docs.salla.dev/twilight/react/api/modules/store)                 | Store info, theme settings, languages, currencies and payments in one request        |
| [`translations`](https://docs.salla.dev/twilight/react/api/modules/translations)   | The platform's translation messages for one language, and the merchant's own wording |
| [`advertisement`](https://docs.salla.dev/twilight/react/api/modules/advertisement) | The merchant's announcement bars, and which ones a page shows                        |
| [`apps`](https://docs.salla.dev/twilight/react/api/modules/apps)                   | Snippets and settings of the installed apps                                          |

## Next [#next]

Missing an endpoint? [Write your own](https://docs.salla.dev/twilight/react/api/write-your-own-endpoint).
