Contents
Get Settings - Plugixa Extra Product Options
GET /plugixa-epo/v1/settings
The plugin’s settings, as Plugixa Product Options > Settings shows them. See Settings.
Needs a user with the plugixa_epo_manage capability (signed in with an Application Password, or the login cookie with an X-WP-Nonce header). Administrators and shop managers hold it; see Permissions.
Request
GET https://your-store.example/wp-json/plugixa-epo/v1/settings
Responses
200 OK.
{
"success": true,
"data": {
"show_totals": true,
"totals_label": "Your price",
"options_label": "Personalise your order",
"price_suffix": "plus",
"erase_on_uninstall": false
}
}
| Field | Type | Meaning |
|---|---|---|
show_totals |
boolean |
Show a live total under the options |
totals_label |
string |
Total label: the name of the total’s last line. Empty: Total |
options_label |
string |
Title above the options. Empty: no title |
price_suffix |
string |
Prices beside options: plus shows them, none hides them |
erase_on_uninstall |
boolean |
Delete all option groups when the plugin is uninstalled |
Errors
| Status | Code | When |
|---|---|---|
401 / 403 |
plugixa_epo_forbidden |
The caller lacks the capability: You are not allowed to do that. |
Plus the errors every endpoint can return.
Examples
curl -s "https://your-store.example/wp-json/plugixa-epo/v1/settings" \
-u "$WP_USER:$WP_APP_PASSWORD"
<?php
$ch = curl_init('https://your-store.example/wp-json/plugixa-epo/v1/settings');
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-epo/v1/settings', {
headers: {
'Authorization': `Basic ${btoa(`${process.env.WP_USER}:${process.env.WP_APP_PASSWORD}`)}`,
},
});
const { data } = await response.json();
Quick Links
Share