POST Authentication

Each API request is authenticated by a webpushrKey & webpushrAuthToken in the request header. This Key & Token is site specific and you can get this from Integration > API Keys menu in your Webpushr Web Console.

Example Request

curl -X POST \
-H "webpushrKey: <YOUR REST API KEY>" \
-H "webpushrAuthToken: <YOUR AUTHENTICATION TOKEN>" \
-H "Content-Type: application/json" \
$end_point = '';
$http_header = array( 
	"Content-Type: Application/Json", 
	"webpushrKey: <YOUR REST API KEY>", 
$ch = curl_init();
curl_setopt($ch, CURLOPT_HTTPHEADER, $http_header);
curl_setopt($ch, CURLOPT_URL, $end_point );
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
echo $response;

Result Format

   "status" : "success",
   "description" : "You are authorized", 
    "status": "failure",
    "type" : "header_invalid",
    "description": "Missing webpushrKey in header"
    "status": "failure",
    "type" : "authentication_failure",
    "description": "You are not authorized"