Hello
I want to file upload in asp.net c# using api url and key.
anyone can help me.
Thanks
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Pankil BhattPosted Jul 14, 2016, 3:34 AM
Bikesh SrivastavaPosted Jul 14, 2016, 3:33 AM
Pankil BhattPosted Jul 14, 2016, 3:30 AM
and check the files status
$key = "PUT YOUR API KEY HERE"; $settings['file_contents'] ="@/home/Downloads/emails.txt"; //path to your file $url = 'https://Testurl.com/api/verifApiFile?secret='.$key.'&filename=my_emails.txt'; $ch = curl_init($url); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $settings); $file_id = curl_exec($ch); //you need to save this FILE ID for get file status and download reports in future curl_close($ch);
for upload file
AND
$key = "PUT YOUR API KEY HERE"; $url = 'https://Testurl.com/api/getApiFileInfo?secret='.$key.'&id=10700'; $string = file_get_contents($url); list($file_id,$filename,$unique,$lines,$lines_processed,$status,$timestamp,$link1,$link2) = explode('|',$string); //parse data
to check file status
Pankil BhattPosted Jul 14, 2016, 3:27 AM
Pankil BhattPosted Jul 14, 2016, 3:24 AM
api is tired party.
Ravi PatelPosted Jul 14, 2016, 3:23 AM
Bikesh SrivastavaPosted Jul 14, 2016, 3:22 AM