Advanced Integration
This guide covers advanced integration features of Memberstack, including webhooks, custom authentication flows, and API endpoints. These features allow you to build sophisticated membership experiences and integrate deeply with your existing systems.
Before You Start
- Complete the Quick Start Guide
- Familiarize yourself with the Memberstack dashboard
- Have a paid Memberstack plan for production use
Webhooks
While webhooks are not directly part of the DOM package, they work seamlessly with it to help you respond to member-related events in your application. Webhooks allow you to listen for events like member creation, updates, and plan changes.
Available Events
Member Events:
- member.created - When a new member signs up
- member.updated - When member data changes
- member.deleted - When a member is removed
Plan Events:
- member.plan.created - When a member gets a new plan
- member.plan.updated - When a plan status changes
- member.plan.canceled - When a plan is canceled
Setting Up Webhooks
- Go to the Memberstack dashboard
- Navigate to DevTools
- Enable webhooks and add your endpoint URL
- Select the events you want to receive
- Copy your webhook secret for verification
Example Webhook Payload
Custom Authentication
Memberstack supports custom authentication flows through its OpenID Connect integration. This allows you to use Memberstack as an identity provider for your applications while maintaining full control over the authentication experience.
Getting Started with SSO
- Enable SSO in your Memberstack dashboard
- Create a new SSO integration
- Configure your client ID and secret
- Set up your redirect URIs
- Implement the OpenID Connect flow
OpenID Configuration
Available Packages
While Memberstack doesn't provide traditional API endpoints, it offers several packages for different environments that allow you to extend and customize your Memberstack integration.
Admin Package
For backend operations and server-side validation
- Verify JWT tokens
- Validate webhook signatures
- Manage members server-side
Other Packages
For front-end integrations and client-side operations
- DOM Package (this documentation)
- Data Attribute Package (Webflow & Wordpress)
Using the Admin Package
Package Selection Guide
- DOM Package: Client-side member management and authentication
- Admin Package: Server-side only operations and security validation
- Data Attribute Package: Wrapper around the DOM package that adds data attributes
Need Help?
Having trouble getting your login working? We're here to help!