Contents
On this page
List Custom Fields - Plugixa Testimonial
GET /plugixatestimonial/v1/custom-fields
List the custom field definitions one page at a time. See Custom fields.
Administrators only: the user needs WordPress’s manage_options capability. No plugin capability opens this route.
Request
GET https://your-site.example/wp-json/plugixatestimonial/v1/custom-fields?orderby=menu_order&order=ASC
Query parameters
| Name | Type | Default | Description |
|---|---|---|---|
search |
string |
Text found in the label or the key. Same as filter[search]. |
|
status |
string |
publish, draft or trash. Without it, every field except trash is listed. |
Plus the list parameters every paged list accepts. orderby accepts id, field_label, field_key, field_type, menu_order and created_at; anything else falls back to menu_order.
Responses
200 OK. data.items is one page of fields.
{
"success": true,
"message": "",
"data": {
"items": [
{
"id": "5",
"language_code": null,
"translation_group": null,
"field_key": "project_type",
"field_label": "Project type",
"field_type": "select",
"field_options": [
"Website redesign",
"Branding",
"SEO"
],
"placeholder": "",
"is_required": false,
"show_in_frontend": true,
"menu_order": "0",
"created_at": "2026-11-12 09:30:00",
"modified_at": "2026-11-12 09:30:00",
"status": "publish",
"value_count": "18"
}
],
"total": 1,
"state": {
"filter": {},
"limit": 20,
"offset": 0,
"orderby": "menu_order",
"order": "ASC"
}
}
}
| Field | Type | Meaning |
|---|---|---|
data.items[].id |
string |
The field’s id |
data.items[].field_key |
string |
The key values are stored under in a testimonial’s custom_fields |
data.items[].field_label |
string |
The label |
data.items[].field_type |
string |
text, textarea, url, number, date, select, checkbox or color |
data.items[].field_options |
string[]|null |
The choices of a select field |
data.items[].is_required |
boolean |
Required on the submission form |
data.items[].show_in_frontend |
boolean |
Shown on the front end |
data.items[].menu_order |
string |
Position in the manual order |
data.items[].status |
string |
publish, draft or trash. Only publish fields reach the front end |
data.items[].value_count |
string |
Stored values under this key, across all testimonials |
data.total |
integer |
Fields matching the filters, before paging |
With WPML or Polylang active, each row also has translations: { id, language_code } for every row in its translation group.
Errors
Plus the errors every endpoint can return.
Examples
curl -s "https://your-site.example/wp-json/plugixatestimonial/v1/custom-fields?orderby=menu_order&order=ASC" \
-u "admin:$WP_APP_PASSWORD"
<?php
$query = http_build_query([
'orderby' => 'menu_order',
'order' => 'ASC',
]);
$ch = curl_init('https://your-site.example/wp-json/plugixatestimonial/v1/custom-fields?' . $query);
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_USERPWD => 'admin:' . getenv('WP_APP_PASSWORD'),
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
const query = new URLSearchParams({ orderby: 'menu_order', order: 'ASC' });
const response = await fetch(`https://your-site.example/wp-json/plugixatestimonial/v1/custom-fields?${query}`, {
headers: {
'Authorization': 'Basic ' + btoa(`admin:${process.env.WP_APP_PASSWORD}`),
},
});
const { data } = await response.json();
Quick Links
Share