> For the complete documentation index, see [llms.txt](https://docs.mdintegrations.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mdintegrations.com/partner/integration-paths/woocommerce.md).

# WooCommerce

Use the MDI WooCommerce plugin to connect a storefront purchase to hosted medical intake and messaging. The plugin adds patient entry points to your store, and MDI manages the clinical workflow from the moment intake begins.

In this arrangement, your storefront owns products, checkout, payment, and shipping, while MDI hosts medical intake, creates the patient record and Encounter, and supports patient-to-physician messaging.

### Configure the plugin

{% stepper %}
{% step %}

#### Install and connect

Install the MDI WooCommerce plugin from the WordPress Plugin Directory, then add your Sandbox API credentials in the plugin settings before you begin testing.
{% endstep %}

{% step %}

#### Add the checkout intake extension

Enable the checkout extension. It displays an intake entry point after a qualifying purchase.

Run a test checkout afterward to confirm the entry point appears where patients expect it.
{% endstep %}

{% step %}

#### Map products to intake

Map every supported product or variant to its MDI [Questionnaires & Vouchers](/partner/key-concepts/questionnaires-and-vouchers.md) and [Offerings](/partner/key-concepts/offerings.md).

Start with the sample product, form, and Offering provided for testing, and confirm the saved mapping is active before you move on to mapping your production catalog.
{% endstep %}

{% step %}

#### Add a messaging entry point

Place the MDI messaging button on an order page or another authenticated patient page.

Patients with an active [Patients & Encounters](/partner/key-concepts/patients-and-encounters.md) can use it to contact their assigned physician, while patients without an Encounter are directed to complete intake first.
{% endstep %}
{% endstepper %}

### Test the full purchase flow

Test in Sandbox before mapping production products:

1. Purchase the sample product.
2. Complete the hosted intake form.
3. Confirm MDI created the Patient and Encounter.
4. Open messaging and send a test message to the assigned physician.

Repeat this test for every product mapping, and move the plugin to Live credentials only once every flow works as expected.

{% hint style="warning" %}
Use Sandbox credentials until testing is complete. Sandbox and Live data do not overlap.
{% endhint %}

See [Go-Live Checklist](/partner/get-started/go-live-checklist.md) before using Live credentials.

### Keep clinical data out of WooCommerce

Collect only commercial checkout data in WooCommerce, such as name, email, address, and payment details, and leave medical information to MDI-hosted intake exclusively.

A customer becomes a Patient only after completing the hosted intake flow — don't collect or store patient health information in your WooCommerce store.

See [PHI Separation for E-Commerce Integrations](/partner/troubleshooting/technical-concepts/phi-separation-for-e-commerce-integrations.md) for the required boundary.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.mdintegrations.com/partner/integration-paths/woocommerce.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
