Configuring Stripe
After creating a Stripe account, you can use the Stripe Dashboard to configure your account settings, manage payments, and set up integration details for your MSWR Stripe Checkout implementation. This page covers the essential setup steps required for using the MSWR plugin.
To access the Stripe Dashboard, simply create an account and log in to Stripe with your credentials.
To integrate Stripe Checkout with the MSWR plugin, you’ll need to complete these tasks:
Locate your API Keys
To connect your website to Stripe, you need API keys, which authenticate requests between your site and Stripe’s servers. Stripe provides two sets of keys:
- Test Mode API Keys – Used for development and testing transactions without real payments.
- Live Mode API Keys – Used for real transactions when your site is live.
How to Find Your API Keys
- Navigate to the API Keys Section
In the left-hand menu, click Developers → API Keys. - View Your API Keys
You will see both Publishable Key and Secret Key listed.- Publishable Key (pk_live_… or pk_test_…): Used in frontend code to identify your account.
- Secret Key (sk_live_… or sk_test_…): Used in backend requests; keep this secure and do not share it.
- Switch Between Test and Live Mode
- Toggle the View Test Data switch (top-right of the page) to see either test or live keys.
- Use Test Mode keys while developing and switch to Live Mode keys when ready to process real transactions.
- Copy and Store Your Keys Securely
- Copy your keys and paste them directly into the appropriate settings in the MSWR plugin.
- The live secret key can only be read from Stripe once. It must be regenerated every time it is read.
- Using best practice implies copying each key directly to the MSWR plugin without storing anywhere else.
- Never expose secret keys or share them via email.
Additional Resources
Set up Webhooks
Webhooks allow Stripe to notify your site when a payment is processed. Setting up webhooks is essential for tracking successful payments and handling any failed transactions.
MSWR requires that you set up webhooks for both Test Mode and Live Mode (Stripe requires separate configuration for each).
Create webhooks for live and test modes by using these links:
Enter the Webhook Endpoint URL
https://your-site.com/wp-json/minimal-stripe-wrapper/v1/stripe-webhook
(replace https://your-site.com/ with your actual site home URL)
Select Webhook Events
Press “Select Events” and ensure that the following events are selected:
- checkout.session.completed
- checkout.session.expired
- checkout.session.async_payment_failed
- checkout.session.async_payment_suceeded
- payment_intent.succeeded
- payment_intent.payment_failed
- payment_intent.canceled
Click Save to finalize the webhook settings.
Copy Your Webhook Signing Secret
Once the webhook is created, click on it in the Stripe Dashboard.
Reveal and copy the Signing secret (starts with whsec_…).
Paste this into the appropriate field in MSWR plugin settings.
By following these steps, your site will be able to track transactions in both Live Mode and Test Mode.