Pinterest API to pull video pin stats - pinterest

Does Pinterest have any Public API to pull stats from video pins? I have gone through API docs and did not find anything.
Thanks,
Sourav

No it doesn't, but you can use the unofficial py3-pinterest client.
Python code:
import json
pin_data = load_pin_by_id(pin_id='148900331419819774')
print(json.dumps(pin_data))
JSON response

Related

Uploading a video through youtube official library through php cli request but resulting in (Undefined Index: HTTP_HOST). Any idea to solve this?

I'm getting an error of Undefined Index: HTTP_HOST while trying to send a video to Youtube API using the Official Youtube Google API PHP Library.
The request is happening under laravel scheduler to run cli request to do the task.
I have tried and find a way of adding Host Header Parameter to the request but couldn't get it done.
I also tried specifying the rootUrl param when iniatializing the Google Youtube Service like so;
$service = new GoogleServiceYoutube($client, 'https://youtube.googleapi.com');
What can I do to solve this error?

Upload vimeo video with Laravel 8.x

I am testing vimeo with vimeo basic account and Laravel 8.x / guzzle in order to pay for a pro licence.
I am trying to implement a form-based video upload approch. According to the documents available to vimeo website, the first step consists in sending a post request to /me/videos then i will receive a response that will contain an HTML form in the upload.form field. Yet, the request status code is correct (201 : created).
My issue is that i don't see this field (upload.form) in the api server response (i have made a dd($response)).
Here is the code in my controller:
$response = Http::withToken('xxxxxxx')->withHeaders([
'Content-Type'=>'application/json',
'Accept'=>'application/vnd.vimeo.*+json;version=3.4'
])->post('https://api.vimeo.com/me/videos', [
'upload'=>[
'size'=>$request->file->getsize(),
'approch'=>'post',
]
]);
Can a person help me solve this problem?
The link of the documentation i have read is: Working with Video Uploads and other API references.
I really need your help please
Thank you for all.
I have tried the same request with postman and it has allowed me to understand that the instruction dd($response) does not give me all the informations contained in the server's response but just some informations in the headers.
To see what i wanted i have used one of these instructions:
dd($response->body());
// or
dd($response->json())
For example to obtain the HTML form provided by vimeo API, i have to use this instruction:
$response->json()['upload']['form'];
So i consider closed, this ticket.

Shopify webhook verification in parse

I am trying to get a shopify webhook to fill my customer class in parse.com, however something must go wrong. I don't know how to verify the parse response since Shopify sends this webhook out from it's ruby backend. I used requestbin to catch the webhook and I replicated a post request using postman to my parse url and everything works fine. Does anyone know how to debug requests like these? Is there a console in Parse where I can see all the incoming requests and the responses Parse.com sent back?
Try using Runscope for debugging webhooks. Full guide here: https://www.runscope.com/provider-guide/troubleshooting-webhooks - this is more than just a request bin. It's a full transparent proxy that will, like a bin, record the webhook notification, but will also pass it along to the intended destination (your webhook receiver) and record that response as well.

what is the facebook ajax request which get the posts?

I am trying using facebook from Scrapy.
I can log in successfully. However, I can't get the posts on facebook because the posts comes from ajax calls.
I tried using firebug and check the XHR. I got this:
I tried to check the response of all those request but none of them contains the actual data of the posts.
What is the ajax request that get the posts on facebook?
Thanks in advance
Don't use the AJAX calls from your browser. Those are encrypted since Facebook uses HTTPS connections. Focus on using their API to make the calls you need to get the data you want. That's the entire purpose of their Graph API.

Google Checkout handling URL Callback for order completion?

I'm developing an application that fully implements google checkout and I'm trying to figure out how to access the data sent to the API Callback URL (Specified in Integration settings) when an order has been completed?
Is the data for the completed order being sent via POST data? XML? GET? How do I go about accessing the data sent back to my web application for a completed order?
Any documentation or pointers in the right direction would be greatly appreciated!
Google Checkout will send notification callbacks to your specified callback url as an HTTP POST.
The data is in XML format in the body of the POST.
Some useful links below:
How to configure the web service to respond to callbacks: http://support.google.com/checkout/sell/bin/answer.py?hl=en-GB&answer=70647
PHP library - look at basicapiresponsehandlerdemo.php responsehandlerdemo.php which shows how to parse and respond to callbacks:
http://code.google.com/p/google-checkout-php-sample-code/

Resources