<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/fetchcampaignList";
$postfields = array(
'username' => 'root',
'password' => 'root',
'start' => '0',
'noofrecord' => '10'
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
$response = json_decode($response);
?>
{
"status":"1",
"message":[ {
"camp_name": "ROOT_22_10_2018_15_27_10", "content": "To unsubsribe click here [UNSUBSCRIBE]", "fromname": "China Homelife and China Machinex India 2018", "fromemail": "newsletter@foxprp.com", "replyto": "newsletter@foxprp.com", "email_subject": "The latest styles in Textile and Garments at China Homelife'2018!", "email_count": "4", "request_code": "1022152825-NDI4MjA=-ROOT", "type": "n", "is_schedule": "0", "schedule_date": "0", "approve": "1", "is_completed": "0", "created_at": "2018-10-22 15:28:25", "credits_used": null
}
]
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/fetchIndividualcontact";
$postfields = array(
'username' => 'root',
'password' => 'root',
'request_code' => '0914130643-MjUwOTA=-ROOT',
'start' => '0',
'noofrecord' => '10'
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message":[ {
"email": "arnikshah@yahoo.com", "subscriber": "1", "request_code": "0915141522-MzYzMTU=-ROOT", "created_at": "2018-09-15 14:16:02"
}
]
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/fetchreportlist";
$postfields = array(
'username' => 'root',
'password' => 'root',
'fromdate' => '2018-11-01',
'todate' => '2018-12-15',
'start' => '0',
'noofrecord' => '10'
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message":[ {
"request_code": "0914184050-NjA3MzY=-ROOT", "camp_name": "Personalise Testing", "totalcount": "5", "opens": "1", "clicks": "0", "subscribers": "4", "unsubscribers": "1", "softbounce": "0", "hardbounce": "0", "is_completed": "5", "created_at": "2018-11-14 18:40:50"
}
,
{
"request_code": "0914181533-OTAwMTQ=-ROOT", "camp_name": "Normal Campaign_14_09_2018", "totalcount": "4", "opens": "1", "clicks": "0", "subscribers": "4", "unsubscribers": "0", "softbounce": "0", "hardbounce": "0", "is_completed": "5", "created_at": "2018-11-14 18:15:33"
}
,
{
"request_code": "0914133744-Njk2ODQ=-ROOT", "camp_name": "Normal Campaign", "totalcount": "4", "opens": "1", "clicks": "0", "subscribers": "4", "unsubscribers": "0", "softbounce": "0", "hardbounce": "0", "is_completed": "5", "created_at": "2018-11-14 13:37:44"
}
,
{
"request_code": "0914132924-NDcyMQ==-ROOT", "camp_name": "Normal Campaign", "totalcount": "5", "opens": "1", "clicks": "0", "subscribers": "4", "unsubscribers": "1", "softbounce": "0", "hardbounce": "0", "is_completed": "5", "created_at": "2018-11-14 13:29:24"
}
,
{
"request_code": "0914130959-NDAwMQ==-ROOT", "camp_name": "Normal Campaign", "totalcount": "4", "opens": "1", "clicks": "0", "subscribers": "4", "unsubscribers": "0", "softbounce": "0", "hardbounce": "0", "is_completed": "5", "created_at": "2018-11-14 13:09:59"
}
]
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/fetchIndividualreport";
$postfields = array(
'username' => 'root',
'password' => 'root',
'request_code' => '0914184050-NjA3MzY=-ROOT',
'start' => '0',
'noofrecord' => '10'
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message":[ {
"email": "it@insigntechnology.com", "open": "1", "click": "0", "subscribe": "1", "unsubscribe": "0", "soft_bounce": "0", "hard_bounce": "0", "bounce_desc": "0", "diagnostic_code": null, "request_code": "0914184050-NjA3MzY=-ROOT", "created_at": "2018-09-14 18:41:17", "updated_at": "2018-09-14 18:41:29"
}
,
{
"email": "bhorgagaram77740@gmail.com", "open": "0", "click": "0", "subscribe": "1", "unsubscribe": "0", "soft_bounce": "0", "hard_bounce": "0", "bounce_desc": "0", "diagnostic_code": null, "request_code": "0914184050-NjA3MzY=-ROOT", "created_at": "2018-09-14 18:41:17", "updated_at": "2018-09-14 18:41:29"
}
,
{
"email": "test10@gmail.com", "open": "0", "click": "0", "subscribe": "1", "unsubscribe": "0", "soft_bounce": "0", "hard_bounce": "0", "bounce_desc": "0", "diagnostic_code": null, "request_code": "0914184050-NjA3MzY=-ROOT", "created_at": "2018-09-14 18:41:17", "updated_at": "2018-09-14 18:41:29"
}
,
{
"email": "support@insigntechnology.com", "open": "0", "click": "0", "subscribe": "0", "unsubscribe": "1", "soft_bounce": "0", "hard_bounce": "0", "bounce_desc": "0", "diagnostic_code": null, "request_code": "0914184050-NjA3MzY=-ROOT", "created_at": "2018-09-14 18:41:17", "updated_at": "2018-09-14 18:41:17"
}
,
{
"email": "ravindra@insigntechnology.com", "open": "0", "click": "0", "subscribe": "1", "unsubscribe": "0", "soft_bounce": "0", "hard_bounce": "0", "bounce_desc": "0", "diagnostic_code": null, "request_code": "0914184050-NjA3MzY=-ROOT", "created_at": "2018-09-14 18:41:17", "updated_at": "2018-09-14 18:41:29"
}
]
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/startCampaign";
$postfields = array(
'username' => 'root',
'password' => 'root',
'request_code' => '1024121938-NzE5NjI=-ROOT',
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status": "1", "message": "Campaign Started successfully"
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/uploadcontact";
$postfields = array(
'username' => 'root',
'password' => 'root',
'contactname' => 'list1',
'emailfile' => '@'.$_FILES['file']['tmp_name'] // pass file object // CSV file
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message": {
"contactid": 133
}
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/createCampaign";
$postfields = array(
'username' => 'root',
'password' => 'root',
'campname' => 'test',
'fromname' => 'No Reply',
'fromemail' => 'newsletter@xyz.com',
'replyto' => 'newsletter@xyz.com',
'emailsubject' => 'testEmail',
'contactfileid' => '5',
'type' => 'n',
'htmlfile' => '@'.$_FILES['file']['tmp_name'], // pass file object // HTML file
'unsubscribecontent' => 'To unsubscribe click here [UNSUBSCRIBE]'
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message": {
"campid": 812
}
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/createPersonaliseCampaignfirstpart";
$postfields = array(
'username' => 'root',
'password' => 'root',
'campname' => 'test',
'fromname' => 'No Reply',
'fromemail' => 'newsletter@xyz.com',
'replyto' => 'newsletter@xyz.com',
'emailsubject' => 'testEmail',
'type' => 'p',
'unsubscribecontent' => 'To unsubscribe click here [UNSUBSCRIBE]',
'personalisefile' => '@'.$_FILES['file']['tmp_name'], // pass file object // CSV file
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message": {
"request_code": "1024123939-OTQxMTQ=-ROOT"
}
}
<?php
$ch = curl_init();
$url = "https://cp.pigeonmails.com/api/createPersonaliseCampaignsecondpart";
$postfields = array(
'username' => 'root',
'password' => 'root',
'request_code' => '1024123939-OTQxMTQ=-ROOT',
'contactheaderindex' => '1',
'htmlfile' => '@'.$_FILES['file']['tmp_name'], // pass file object // CSV file
);
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($ch,CURLOPT_POST, 1); //0 for a get request
curl_setopt($ch,CURLOPT_POSTFIELDS,$postfields);
curl_setopt($ch,CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch,CURLOPT_CONNECTTIMEOUT ,3);
curl_setopt($ch,CURLOPT_TIMEOUT, 20);
$response = curl_exec($ch);
curl_close ($ch);
echo $response;
$response = json_decode($response);
?>
{
"status":"1",
"message": {
"campid": "813"
}
}