Salla Docs
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
  • Report Builder
  • App Onboarding
  • Communication Apps
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Component Bundle
  • Change Log
Salla CLI
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
  • Report Builder
  • App Onboarding
  • Communication Apps
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Component Bundle
  • Change Log
Salla CLI
Salla - Opensource
Salla - Developers Community
  1. Checkout Module
  • Embedded SDK
    • Overview
    • Getting Started
    • Installation
    • Authentication
    • App Design Guidelines
    • Create an Embedded App
    • Playground
  • Auth Module
    • Get Token
    • Client Introspect
    • Refresh Token
  • Page Module
    • Iframe Resizing
    • External Redirects
    • Navigation
    • Set Page Title
  • Nav Module
    • Create Navbar Action
    • Listen for Nav Actions
    • Clearing Nav Actions
  • UI Module
    • Confirm Dialogs
    • Toast Notifications
    • Loading States
  • Checkout Module
    • Create Checkout
    • Subscribe for Payment Result
    • Get App Add-ons
  • Endpoints
    • Token Introspect
  • Resources
    • Support
  1. Checkout Module

Get App Add-ons

The getAddons method fetches the list of available addons for your app. Use this to display addon options, verify slugs, and show accurate pricing before initiating a checkout.
About Addons
Addons can be added to your App from the Pricing Step inside the App Publish form in the Partners Portal.

Usage#

API Reference#

embedded.checkout.getAddons()#

Takes no parameters. Returns a Promise that resolves with the addon list or error details.

Return Value#

Resolves to a GetAddonsResult object:
PropertyTypeDescription
successbooleantrue if addons were fetched successfully.
addonsAddonInfo[] | undefinedList of available addons. Present when success is true.
errorobject | undefinedError details with code and message. Present when success is false.

AddonInfo#

Each addon in the addons array contains:
PropertyTypeDescription
slugstringUnique identifier used in create().
namestringDisplay name of the addon.
pricenumberPrice amount.
product_idnumberInternal product ID.
product_price_idnumberInternal price ID.

Complete Example#

Fetch addons and present them to the merchant, then initiate checkout on selection:
💡
Best Practices
Cache Aware: Results are cached on the host side for 30 minutes. Calling getAddons() multiple times is inexpensive within that window.
Loading State: Show a loading indicator while fetching to avoid a blank UI. Use embedded.ui.loading.show() and .hide().
Graceful Errors: Always handle the success: false case. Network issues or timeouts will resolve with an error rather than throwing.
Modified at 2026-03-05 09:04:03
Previous
Subscribe for Payment Result
Next
Token Introspect