Headless API Club Sign Up

Headless API Club Sign Up

1. Overview

Winehub provides a set of headless API endpoints that allow you to integrate Wine Club sign-up functionality, product-specific offers, and club data directly into your custom Shopify storefront (or any frontend framework). These endpoints replicate core app embed features from the Shopify theme sign up app block, enabling use in any headless or custom implementation.


2. Connecting to Winehub

All Winehub headless functions are served via:

https://api.winehub.io/headless/

You must append your Shopify store domain using the ?shop= query string. For example:

GET https://api.winehub.io/headless/clubs/basic-details?shop=winehub-demo.myshopify.com

Ensure that the store URL does not include https://.


3. Example Implementation Flow

To implement a custom headless Wine Club sign-up experience, the typical integration flow would be:

  1. Fetch Club Listings: Begin by retrieving all published clubs using the /clubs/basic-details endpoint.

  2. Display Club Details: When a customer selects a club, use the /club/{id}/details endpoint to fetch full data including variants, perks, and available selling plans.

  3. Check for Sign-Up Offer: If the selected club includes a sign-up offer, and the customer accepts it, use the /productOffer/{quantity}/{offerId} endpoint to generate a discount code for use during checkout.

  4. Apply Logic as Needed: Render all retrieved information in your frontend, allowing users to select case sizes, variants, and apply the generated discount code.

This flow enables you to recreate the same signup functionality available in the Shopify theme app block, but within a completely custom headless environment.


4. API Endpoints

/club/{id}/details

  • Method: GET

  • Returns: JSON

Fields Returned:

[id, name, description, position, shopify_id, caseType, caseSizes, sellingPlans, sellingPlanVariants, sellingPlanPerks, membersLimit, minimumOrderValue, movOnly, signUpProductOffer, isPlaylist, useSeasons]

/clubs/basic-details

  • Method: GET

  • Returns: JSON

Fields Returned:

[id, name, description, merchant_code, position, options, shopify_id, type, caseType, caseSizes, sellingPlans, sellingPlanPerks]

/productOffer/{quantity}/{offerId}

  • Method: GET

  • Returns: JSON

Fields Returned:

[message, status, errors, code]


5. Support

The Winehub headless endpoints are designed for advanced users and agencies. Winehub does not guarantee support for implementation or integration issues. Charges may apply if our assistance is required. Implementations sitting outside of our native Shopify, standard sandbox deployment are considered non-standard and not covered by our usual warranty of operation.


Additional Notes

  • Ensure clubs are published in Winehub to appear in any endpoint output.

  • All Winehub data access is scoped by the store URL passed via ?shop=....

  • Headless integration assumes your frontend handles rendering, validation, and other logic using these API responses.

    • Related Articles

    • Admin Club Sign-ups

      This method for club signups is only possible if you use the third-party Stripe integration or if the customer's card is already vaulted in Shopify. Creating Club Subscriptions Without an Initial Transaction Default Shopify behaviour means that new ...
    • Sign-up Product Offers

      Upselling with Product Offers Sign Up Product Offers provide an excellent opportunity to upsell new members at the point of club sign-up by offering exclusive deals. This not only adds value for customers but also boosts initial revenue. Here’s how ...
    • Welcome Packs & Free Sign-ups

      Adding a Sign Up Product This feature is only available for Fixed-Case Wine Clubs using 'fixed date' rebilling only When creating a new membership subscription for a 'fixed date' Wine Club, you must transact at the time of sign-up in order to vault a ...
    • Club Runs

      The Club Runs section is where you can view and manage wine club subscription orders. WineHub automatically generates grouped orders for each specified shipping date based on the club and the selected frequency (fixed date or anniversary-based). For ...
    • Club Shipping Profiles

      A club shipping profile allows you to define custom shipping rates for club members that override your standard Shopify shipping settings. Free club shipping is a common use case for this, allowing you to offer free shipping to selected clubs without ...