Skip to main content

Custom Baskets

Working with custom domains

In the following article, links will be referenced as originating from system.spektrix.com. If you have implemented a custom domain for your Integration, please replace system.spektrix.com with your chosen subdomain.

Although providing a robust basket solution in the iframe purchase path, there may be times where you would like to escape this journey and display your own custom basket page.

Using the Custom Basket field inside of Website Admin, combined with the Spektrix API you can fully control your own basket page, offering opportunities for richer upselling based on basket content and customer eligibility.

Below we'll look at adding your custom basket page into the iframe flow, how to return the current basket contents and some thoughts of what you could achieve.

When using a Custom Basket
  • Ensure you have a custom domain setup for use with your client.
  • All basket API calls can use Web/Public Mode and should be made client side.
  • Ensure you explicitly include cookies as part of your call, by setting xhr.withCredentials = true.
  • We return the IDs of all items in the current basket so we advise caching a list of events, instances, ticket types and other items as needed.

The Custom Basket Page

The joy of the custom basket page is that you are in full control of what is displayed. Using our API you can return the current state of the Basket and make decisions based on the contents.

Returning the Basket Contents via the API

To return the current contents of the end-users basket, you can use the following;

GET
https://system.spektrix.com/{{clientname}}/api/v3/basket

The above will give you a full breakdown of the current status of the basket.

We also have more guidance about viewing, removing items and clearing the basket in our Adding items to the basket guide.

If you use:
  • Fixed Series Subscriptions
  • Memberships with Donation
  • Ticket Donations
  • Gift Memberships
  • Faciliated Booking

the Basket response will be lacking information about the relationship between items. Get in touch to discuss whether / how these limitations may affect you.

Adding the Custom Basket URL

Inside the client's system, in Website Admin and under a named domain config you have the option to add a Custom Basket Link. This field should be set to the page on the client's site where you have built your custom basket. The custom basket replaces the standard basket Iframe in the standard Iframe flow.

Example Applications

Promoting Membership Discounts

There may be times where you would like to promote a specific membership to a customer. Memberships in Spektrix can be used to power discounts and if a membership is currently in the basket, the discounts will automatically apply. Of course, if the Membership is then removed, any discounted items will revert back to the original price.

For an upselling opportunity, using the Potential Discount Endpoint will allow you to query the current basket contents with a Membership ID to see what the discount would be and promote this to the customer.

Dynamic Donations

Once the customer lands in the basket you may want to make an ask to give to a specific fund. Using a custom basket you could determine the fund you promote on factors such as basket contents or even on Customer Information if they are logged in by this point.

Secondary Spend

The custom basket is also a great place to upsell other items such as Merchandise or Gift Vouchers. A custom basket can also work hand in hand with our Web Components, giving you even more creative ways to prompt customers and add items to the basket.

https://webcomponents.spektrix.com