Contents
On this page

Get View - Plugixa Testimonial

GET /plugixatestimonial/v1/views/{id}

Read one view with its full design settings.

Any signed-in user with the plugixa_testimonial_edit capability or WordPress’s edit_posts (Contributors and up, by default).

Request

GET https://your-site.example/wp-json/plugixatestimonial/v1/views/2

Path parameters

Name Type Description
id integer The view’s id

Responses

200 OK. data is the view.

{
  "success": true,
  "message": "",
  "data": {
    "id": "2",
    "name": "Homepage grid",
    "slug": "homepage-grid",
    "description": "Three columns for the home page.",
    "config": {
      "layout": {
        "style": "grid",
        "columns": {
          "desktop": 3,
          "tablet": 2,
          "mobile": 1
        }
      },
      "display": {
        "showPhoto": true,
        "showRating": true,
        "showDate": true,
        "showCompany": true,
        "showRole": true,
        "showWebsite": false,
        "excerptLength": 150
      },
      "colors": {
        "cardBg": "#ffffff",
        "textColor": "#1d2327",
        "nameColor": "#1d2327",
        "roleColor": "#646970",
        "starColor": "#f59e0b",
        "starEmptyColor": "#d1d5db",
        "borderColor": "#e5e7eb",
        "quoteBg": "#f9fafb"
      },
      "typography": {
        "nameFontSize": 16,
        "nameFontWeight": 600,
        "textFontSize": 14,
        "textFontWeight": 400,
        "roleFontSize": 13
      },
      "spacing": {
        "cardPadding": 24,
        "gap": 24,
        "photoPadding": 0
      },
      "borders": {
        "radius": 8,
        "width": 1
      },
      "shadows": {
        "enabled": true,
        "value": "0 1px 3px rgba(0,0,0,0.1)"
      },
      "categories": {
        "displayStyle": "none",
        "showCategoryDescription": true,
        "colors": {
          "backgroundColor": "#ffffff",
          "textColor": "#1d2327",
          "activeBackgroundColor": "#2271b1",
          "activeTextColor": "#ffffff",
          "borderColor": "#c3c4c7",
          "descriptionColor": "#6b7280",
          "descriptionBackgroundColor": "#f8fafc",
          "descriptionBorderColor": "#2271b1"
        },
        "typography": {
          "fontSize": 14,
          "fontWeight": 500,
          "fontFamily": "inherit"
        },
        "spacing": {
          "padding": 12,
          "gap": 8
        },
        "border": {
          "width": 1,
          "radius": 4
        }
      },
      "photo": {
        "size": 60,
        "sizeUnit": "px",
        "borderRadius": 50,
        "fallbackMode": "initials",
        "fallbackColorMode": "single",
        "fallbackBgColor": "#e5e7eb",
        "fallbackTextColor": "#6b7280",
        "borderWidth": 0,
        "borderColor": "#e5e7eb",
        "borderStyle": "none",
        "position": "inline",
        "grayscale": false,
        "hoverScale": 1.0,
        "opacity": 1.0,
        "shadowEnabled": false,
        "shadowValue": "0 2px 8px rgba(0,0,0,0.15)"
      }
    },
    "is_default": 0,
    "created_at": "2026-11-12 09:30:00",
    "created_by": "1",
    "modified_at": null,
    "modified_by": null
  }
}
Field Type Meaning
data.id string The view’s id
data.name string The name
data.slug string Unique across views. Usable as view="..." in the shortcode
data.description string|null Plain text
data.config object The design settings: layout, display, colors, typography, spacing, borders, shadows, categories, photo and more
data.is_default integer 1 for the view used when a display names none, else 0
data.created_at string|null Site-time datetime

The example shows the built-in defaults. Views edited in the admin carry more groups, such as darkMode, pagination and font families.

Errors

Status Code When
404 rest_error No view with that id.

Plus the errors every endpoint can return.

Examples

curl -s "https://your-site.example/wp-json/plugixatestimonial/v1/views/2" \
  -u "admin:$WP_APP_PASSWORD"
<?php
$ch = curl_init('https://your-site.example/wp-json/plugixatestimonial/v1/views/2');
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 response = await fetch('https://your-site.example/wp-json/plugixatestimonial/v1/views/2', {
  headers: {
    'Authorization': 'Basic ' + btoa(`admin:${process.env.WP_APP_PASSWORD}`),
  },
});
const { data } = await response.json();

Quick Links

Share