Parse's REST API and PHP Curl requests - how to
===

I am using the excellent [Parse][1] as a data store, but need to access it through PHP (as a perhaps irrelevant bit of detail - I am having to access it through PHP in order for Facebook scrapers to recognise dynaically generated <meta> tags on my page).

Parse have a Rest API, and basic instructions on how to use them. For example, to retrieve an object:

>  curl -X GET \   
> -H "X-Parse-Application-Id: [My application ID]" \   
> -H "X-Parse-REST-API-Key: [My Parse Rest API key]" \  
>  https://api.parse.com/1/classes/moods/

Unfortunately, I have no idea how to integrate this with PHP Curl examples I've seen online. I gather:

> curl_setopt($ch, CURLOPT_USERPWD,

..might be involved. As might:

>curl_setopt($ch, CURLOPT_URL, $Url);

but I could be way off. I am really sorry to not be able to figure this out myself - but I think this is still a valid question as it is very confusing to those who haven't used Curl/PHP before. Basically - I'm looking for information as basic as where to put the quoted example from the Parse docs...

Thanks in advance


  [1]: https://parse.com/