Hey @D_ng_Nguy_n, good question!
In a classic Liquid theme you can display discounts that are already affecting the cart, but there isn’t a native way to list all “available” discounts just through Liquid itself. To surface what’s applied within the cart itself, you can use the cart and line item discount objects shown in this tutorial: Discounts.
Specifically, cart-level discounts are available via cart.cart_level_discount_applications and line-level discounts via line_item.line_level_discount_allocations, and Dawn shows a reference implementation in its cart sections: GitHub - Shopify/dawn: Shopify's first source available reference theme, with Online Store 2.0 features and performance built-in..
Manual discount codes can only be applied at checkout, so the common theme pattern is to provide “apply” links that prefill a code using cart permalinks, for example, /discount/CODE?redirect=/cart or {{ routes.cart_url }}?discount=CODE
as described here: Create cart permalinks.
There isn’t a Storefront API or Liquid object that lists all shop discounts, so if you really need to list them you’d have to build a small app that queries the Admin GraphQL API (read_discounts) via codeDiscountNodes/discountNodes and expose a curated list to the theme through an app proxy. API docs here: codeDiscountNodes - GraphQL Admin and discountNodes - GraphQL Admin.
One thing to keep in mind is that for some shops, some discounts are segment‑specific or conditional, so showing every code publicly can reveal promotions that may not be intended for all shoppers. Automatic discounts don’t require an “apply” action and will reflect in pricing; you can still message them in the cart by reading their discount applications as noted above, but it’s not necessary.
If you only need a simple UX, many merchants maintain a short, hand‑curated list of active codes via theme settings or metafields and render “Apply” links that use the discount URL parameter. That approach can keep the storefront simple while leaving the heavy lifting of eligibility to checkout it self. If you share more about whether you’re on Liquid vs. Hydrogen and whether you need a dynamic list, I’m happy to point you to a concrete pattern.
Hope this helps, let me know if I can help out any further at all 