Contents
On this page

Get Follow Buttons - Plugixa Easy Social Share Buttons

GET /plugixa-social-share/v1/follow

The site’s follow profiles, the look of the follow row, and every service a profile can be on.

An account with the plugixa_social_share_view capability. Administrators hold it; no other role does until you grant it.

Request

GET https://your-site.example/wp-json/plugixa-social-share/v1/follow

Responses

200 OK.

services is shortened to one entry; a real answer lists all 25.

{
  "success": true,
  "data": {
    "profiles": [
      {
        "service": "instagram",
        "url": "https://www.instagram.com/yourname/"
      },
      {
        "service": "x",
        "url": "https://x.com/yourname"
      }
    ],
    "look": {
      "template": "default",
      "layout": "icon",
      "align": "start",
      "label": "",
      "vertical": false,
      "size": "medium",
      "size_mobile": "inherit",
      "color": "",
      "ink": ""
    },
    "services": [
      {
        "slug": "x",
        "label": "X",
        "color": "#000000",
        "accessibleColor": "#000000",
        "example": "@yourname"
      }
    ],
    "feed": "https://your-site.example/feed/"
  }
}
Field Type Meaning
data.profiles array The profiles in the order they are drawn, each { service, url }
data.look object The row’s look: the same fields as a share set’s instance, without networks, counts or the “+” button
data.services array Every service a profile can be on. example shows what it accepts
data.feed string The site’s own feed address, offered as the RSS profile

Errors

Status Code When
404 rest_no_route Follow buttons are switched off.

Plus the errors every endpoint can return.

Examples

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

Quick Links

Share