25.87K viewsFeaturespetition rest api
0
0 Comments

I’m using WP Rest API to access published petitions, but I can’t found where to know the received signatures (or supporters) using its rest API. It’s possible to access this info?

Conikal Changed status to publish January 6, 2021
0

Hi,

To get signature, you need add custom endpoint (https://developer.wordpress.org/rest-api/extending-the-rest-api/adding-custom-endpoints/)

with callback function inside file campoal/inc/supporter_donor.php

You should copy function conikal_supporters_list, conikal_donors_list to children theme without function_exist and remove line:
check_ajax_referer(‘supporters_list_ajax_nonce’, ‘security’);

Conikal Answered question January 6, 2021

Question stats

  • Active
  • Views25871 times
  • Answers1 answer