1. Documentation /
  2. Bookings Use Case: Gym Membership Activities

Bookings Use Case: Gym Membership Activities

This scenario will walk through how to leverage WooCommerceWooCommerce Bookings, Groups, Groups for WooCommerce, and WooCommerce Subscriptions to facilitate seamless bookings for gym membership classes. In this scenario, classes (bookable products) are restricted to group members only.

Scenario

↑ Back to top

You own a gym that requires membership, and there are several activities at the gym including a Spin Class. The activity is only available to those who have an active membership and must be booked in advance.

Products Used

↑ Back to top

Setup and Configuration

↑ Back to top

Create a Group

↑ Back to top

First, we’ll need to create a group to be used for those that subscribe to your product/class. Those subscribed to your product/class will be added to the group and given access to additional products that are otherwise hidden from the public. To create a group, follow these steps:

  1. In the sidebar of your WordPress Admin, click on Groups > Capabilities.
  2. Click on the New Capability button on the top.
  3. Under Capability, type gym_membership, then press Add.
  4. In the sidebar of your WordPress Admin, click on Groups > Groups.
  5. Click on the New Group button on top.
  6. Fill out the Name field. An example name is: Gym Membership Activities.
  7. Click on the Capabilities dropdown and select the newly created capability. Then click Add.

You’re set! You’ve created a group that we’re going to assign users to.

Create a Subscription

↑ Back to top

We need to set up a Subscription Product to sell to our customers and assign it to a new group we created earlier. To set up a Subscription Product, follow these steps:

  1. In the sidebar of your WordPress Admin, click on Products > Add New.
  2. Give your product a name like Gym Membership.
  3. We’ll now want to set up the product data. In the Product data box, set the Product Type to Simple subscription. In the General tab, set the subscription price. In this example, we’ll set the price to $75 per month.



  4. Select the Groups tab. Click on the Add to Groups field box. You should now have the option to choose the selected group you created earlier. Add the group and press Publish to save your product.

Whenever someone purchases this product, it will automatically add them to the Gym Membership group. If a user cancels, it will automatically remove them from that group. Only active subscribers will be in the group.

Create a Bookable Product

↑ Back to top

Now we want users to be able to book activities based on the membership they purchased previously. We want to ensure, however, that only active members of the subscription have access to view this product. To create your bookable product for the class, follow these steps:

  1. In the sidebar of your WordPress Admin, click on Products > Add New.
  2. Give your product a name like Spin Class.
  3. In the Product data box, set the Product Type to Bookable product.
  4. We’ll set up some basic rules for the bookable product. The event/class is free, has a fixed block of 1 hour, and is only available for limited time on Saturday and Sunday.




  5. In the top right column of the Product Edit page, find the “Groups” box. Click on the field for Read. Select the new group that we created earlier.



  6. Publish the product and you’re set! Only those that have access to that group will be able to view this product. It is also hidden from your shop pages.

Questions and Support

↑ Back to top

Something missing from this documentation? Do you still have questions and need assistance?

  • Have a question before you buy this extension? Please fill out this pre-sales form – please include the name of this extension in your query.
  • Already purchased and need some assistance? Get in touch with a Happiness Engineer via the WooCommerce.com Support page and choose this extension name from the “I need help with” dropdown