> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.ordergroove.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.ordergroove.com/_mcp/server.

# Refreshing Data in the Subscription Manager

This guide is for developers crafting custom experiences that modify customers' subscriptions and orders. If you update a customer's subscription or order information, you will want to update the Subscription Manager display as well to reflect those changes.

***

## Requirements

This guide is intended for developers who already understand the basics of Subscription Manager advanced development and are crafting custom order and subscription changes. If your customizations do not include custom JavaScript requests to Ordergroove's APIs, you do not need this article.

***

## Refreshing Data

### Understanding Ordergroove's Updates

The Redux state holds all of the objects that the Subscription Manager uses in the templates. You can read more about viewing the current Redux state in the [Debugging with Redux](/docs/lifecycle/sm/redux-debugging) guide.

When an action is dispatched to update a customer's information or order, Ordergroove's SM backend updates the state with custom operations based on the minimum necessary changes. For example, if a customer updates their address, we update the state directly instead of re-requesting all addresses from our backend — resulting in a more responsive customer experience.

For other actions, such as skipping an order, complex calculations take place on Ordergroove's backend to optimize the customer's subscription experience (such as merging multiple subscriptions into one order). In those cases, we request all orders and order items from Ordergroove's backend to fully refresh the Subscription Manager.

### Understanding the Changes You Need

Depending on your custom experience, different parts of the state will need to refresh. You can determine what data needs to refresh by comparing the Redux state to what you expect to be shown. For example, if you sent a request to update the quantity of a customer's order item, you would expect to see an updated quantity on `order_item`.

### Refreshing State

Once you've identified your required state refreshes, you can trigger the appropriate actions in Ordergroove.

#### Refreshing Order and Order Item Information

In most cases, your custom experience will change something about your customer's order (place date, address, etc.) or order items (quantity, product, etc.). The safest approach is to refresh all orders and order items by calling `window.og.smi.api.refresh_page_state` in `script.js` once you receive a success response from Ordergroove's backend. This method re-requests all initial SM data, including orders and items, and updates the page state. If orders or items have been removed since the page was last loaded, calling this function will remove those items from the state.

#### Refreshing Subscriptions and Product

If you need to update subscription or product information, you can call `window.og.smi.api.request_subscriptions` or `window.og.smi.api.request_product` — see the [REST APIs guide](/docs/lifecycle/sm/rest-apis#request_orders) for details.

#### Refreshing Customer Information

There is not currently an externally accessible API for updating customer information in the Redux state of the Subscription Manager. If you would like to see this feature in the future, please contact us. In the meantime, triggering a full page refresh will always fully update the Subscription Manager.

***

## Additional Assistance

Please let us know if you need any more information or want to make a feature request. We are always looking for ways to improve the custom development experience.