Contents
Get Report - Plugixa PDF Vouchers for WooCommerce
GET /plugixa-pdf-vouchers/v1/reports
The figures of Reports and exports for a period of your store’s calendar days.
Needs a user with the plugixa_pdfv_export capability (signed in with an Application Password, or the login cookie with an X-WP-Nonce header). Administrators and shop managers get it when the plugin is activated; see Staff access.
Note. Pro only: on the free plugin this route answers
404rest_no_route.
Request
GET https://your-store.example/wp-json/plugixa-pdf-vouchers/v1/reports?from=2026-11-01&to=2026-11-07
Query parameters
| Field | Type | Required | Description |
|---|---|---|---|
from |
string |
No | YYYY-MM-DD, your store’s calendar day. Defaults to 29 days before to. |
to |
string |
No | YYYY-MM-DD, included. Defaults to today. |
A from after to is swapped. The daily series stops after 367 days.
Responses
200 OK.
{
"success": true,
"data": {
"from": "2026-11-01",
"to": "2026-11-07",
"issued": 695,
"issued_count": 6,
"redeemed": 305,
"redemptions": 9,
"expired": 0,
"voided": 0,
"liability": 3787,
"breakage_rate": 0,
"series": [
{
"date": "2026-11-01",
"issued": 190,
"redeemed": 0
},
{
"date": "2026-11-07",
"issued": 30,
"redeemed": 110
}
],
"products": [
{
"product_id": 540,
"name": "Spa Day for Two",
"vouchers": 2,
"sold": 380,
"used": 0
},
{
"product_id": 534,
"name": "€100 Gift Card",
"vouchers": 2,
"sold": 200,
"used": 182
}
]
}
}
| Field | Type | Meaning |
|---|---|---|
data.issued |
number |
Value issued in the period, new vouchers and top-ups |
data.issued_count |
integer |
Vouchers issued |
data.redeemed |
number |
Spent, minus refunds back onto vouchers |
data.redemptions |
integer |
Number of redemptions |
data.expired |
number |
Written off at expiry |
data.voided |
number |
Written off by voids |
data.liability |
number |
Balances of all active vouchers today, whatever the period |
data.breakage_rate |
number |
expired as a percentage of issued |
data.series |
object[] |
One row per day: date, issued, redeemed. Shortened here |
data.products |
object[] |
The ten voucher products with the most value sold in the period: product_id, name, vouchers, sold, used |
Amounts of every currency are added together.
Errors
| Status | Code | When |
|---|---|---|
401 / 403 |
plugixa_pdfv_forbidden |
The caller lacks the capability. |
400 |
rest_invalid_param |
A date is not written YYYY-MM-DD. |
Plus the errors every endpoint can return.
Examples
curl -s "https://your-store.example/wp-json/plugixa-pdf-vouchers/v1/reports?from=2026-11-01&to=2026-11-07" \
-u "$WP_USER:$WP_APP_PASSWORD"
<?php
$ch = curl_init('https://your-store.example/wp-json/plugixa-pdf-vouchers/v1/reports?from=2026-11-01&to=2026-11-07');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_USERPWD => getenv('WP_USER') . ':' . getenv('WP_APP_PASSWORD'),
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
const response = await fetch('https://your-store.example/wp-json/plugixa-pdf-vouchers/v1/reports?from=2026-11-01&to=2026-11-07', {
headers: {
'Authorization': `Basic ${btoa(`${process.env.WP_USER}:${process.env.WP_APP_PASSWORD}`)}`,
},
});
const { data } = await response.json();
Quick Links
Share