Note that there are some explanatory texts on larger screens.

plurals
  1. POAccessing task management API with PHP using cURL
    primarykey
    data
    text
    <p>I'm attempting to access an API for a task management system (Nozbe to be exact) that is outlined here: <a href="http://www.nozbe.com/api" rel="nofollow">http://www.nozbe.com/api</a></p> <p>If I go in my browser and access the URL it returns the correct json response: {"response":"644a40436"}</p> <p>However, when I attempt to access this URL with cURL in PHP, it doesn't create the note like it would if I accessed it manually in my browser.</p> <p>The normal method is outlined below: <a href="http://www.nozbe.com/api/newnote/name-test/body-test/project_id-c4ca1/context_id-c4ca1/key-1a2b3c4d5e6f7g8h9i0j1k2l3m4n5o6" rel="nofollow">http://www.nozbe.com/api/newnote/name-test/body-test/project_id-c4ca1/context_id-c4ca1/key-1a2b3c4d5e6f7g8h9i0j1k2l3m4n5o6</a></p> <pre><code>$api_key = "INSERTAPIKEYHERE"; $project_id = "73d173457"; $eventtitle = "Testing"; $descrip = "This is a test"; $url = "http://www.nozbe.com/api/newnote/name-$eventtitle/body-$descrip/project_id-$project_id/key-$api_key"; echo "$url&lt;br/&gt;&lt;br/&gt;"; // create a new cURL resource $ch = curl_init(); // set URL and other appropriate options curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); // grab URL and pass it to the browser $response = curl_exec($ch); // close cURL resource, and free up system resources curl_close($ch); </code></pre> <p>Does anyone have any advice or pointers as to why this isn't working? I know it's probably a pretty obscure API I'm attempting to access.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload