Getting dailymotion videos exact same order with Dailymotion itself using API - get

I'm trying to make an aplication using Dailymotion API. I use video search and want to get them ordered like when you search on dailymotion itself but I think I couldn't find proper parameters.
I tried these get requests:
https://api.dailymotion.com/videos?search=Masterchef+(UK)+S15E11
https://api.dailymotion.com/videos?search=Masterchef+(UK)+S15E11&sort=recent
https://api.dailymotion.com/videos?search=Masterchef+(UK)+S15E11&sort=relevance
When I try to search in dailymotion.com, result:
Search Masterchef (UK) S15E11

Unfortunately it's not possible today to get the same search result with our public API.
The website uses our new API engine which is not available publicly yet but we are working on it.

Related

Is it possible to use google DLP to create a bad words filter

Working on nodejs backend with google products, I am trying to make use of google DLP to filter out bad words, so that after users send a message request, the backend can send response to the frontend if the message contains bad words. But the DLP seems only scan source from within BigQuery, Google cloud storage or Cloud datastore. Is there an api that can scan the bad words within DLP?
You can use the content methods for that.
https://cloud.google.com/dlp/docs/concepts-method-types#content-methods
Found the answer from google doc

Pardot Visit query API - generic query not available

I am trying to extract/sync data through Pardot API v4 into a local DB. Most APIs were fine, just used the query method with created_after search criteria. But the Visit API does not seem to support neither a generic query of all visit data, nor a created_after search criteria to retrieve new items.
As far as I can see I can only query Visits in the context of a Visitor or a Prospect.
Any ideas why, and how could I implement synchronisation? (sorry, no access to Pardot DB...)
I have been using pypardot4 python wrapper for convenience but would be happy to use the API natively if it makes any difference.
I managed to get a response from Pardot support, and they have confirmed that such response filtering is not available on the Visits API. I asked for a feature request, but hardly any chance to get enough up-votes to be considered :(

Google Image Search API, does anyone have an example that works?

Trying to find out how to do Google image searches via an API / REST call. Apparently the image search API is deprecated and directs us to the Custom Search API.
But my first experiments with the Custom Search API, return results from my own website !!&*%%%$##!, which is not helpful in the slightest.
I need image results from Google images. Anyone have an example query that works?
You will basically want to generate a URL like this. Note the search type parameter at the end.
https://www.googleapis.com/customsearch/v1?key=YOUR API KEY&cx=YOUR CUSTOM SEARCH ENGINE IDENTIFIER&q=your query&searchType=image
You can read more here https://developers.google.com/custom-search/json-api/v1/using_rest
edit: changed searchType to lowercase based on comment below

Grab instagram photo based on hashtags

I am new to instagram and i am tasked to program an application to grab instagram photo uploads based on a certain hashtag. Meaning if the application is started and searching for the hashtag "#awesomeevent" any one that uploads a photo with that hashtags it will automatically be stored into our database.
The application should work something similar to http://statigr.am/tag/ but instead displaying the photos it should store the photos into the database.
What is the process of doing this. Any tutorials that has this from start to end. Even covering how to start creating a instagram app from scratch. any help would be greatly appreciated.
Thanks
Things we developers often overlook are the API Terms and Conditions. I've been there myself.
API TERMS OF USE
Before you start using the API, we have a few guidelines that we'd like to tell you about. Please make sure to read the full API Terms of Use
Terms of Use. Here's what you'll read about:
Instagram users own their images. It's your responsibility to make sure that you respect that right.
You cannot use the Instagram name in your application.
You cannot use the Instagram API to crawl or store users' images without their express consent.
You cannot replicate the core user experience of Instagram.com
Do not abuse the API. Too many requests too quickly will get your access turned off
However, a part in the terms also states that:
You shall not cache or store any Instagram user photos other than for reasonable periods in order to provide the service you are
providing to Instagram users.
Hope that's a start before you actually get coding and storing images.
API Terms of Use: http://instagram.com/about/legal/terms/api/
API: http://instagram.com/developer/
For starter, you should consult to instagram api.
As for the specific api you will need is:
/tags/tag-name/media/recent
For example, if you want to look for images from tag #awesomeevent, you will do an api query to:
https://api.instagram.com/v1/tags/awesomeevent/media/recent?access_token=ACCESS-TOKEN
I would have a look at the two libraries Instagram provides. The ruby library is at https://github.com/Instagram/instagram-ruby-gem and the python library is at https://github.com/Instagram/python-instagram
They both seem to have examples to get you started if you're programming with either libraries.
As far as the storing issue goes, could you instead store the URL address of the images instead of the actual images themselves? The API returns JSON information of which the URL of the images are returned.
Hope that helps.
You can use the below ruby script to retrieve the images and save them to a file. You can then either reference the file within the database or replace the last block with code for your particular database implementation. Without knowing your database type and schema, no one can tell you how to add something to it.
require "instagram"
require "restclient"
Instagram.configure do |config|
config.client_id = INSTAGRAM_CLIENT_ID
config.client_secret = INSTAGRAM_CLIENT_SECRET
end
instagram_client = Instagram.client(:access_token => INSTAGRAM_ACCESS_TOKEN)
tags = instagram_client.tag_search('cat')
urls = Array.new
for media_item in instagram_client.tag_recent_media(tags[0].name)
urls << media_item.images.standard_resolution.url
end
urls.each_with_index do |url, idx|
image = RestClient.get(url)
path = Dir.pwd + "/#{idx}.jpg"
File.open(path, 'w') {|f| f.write(image) }
end

Where can i get Google Location based api or url from where i get xml with data?

I want to make some searching related operation like pub searching from my native application using google api and also get the complete address of that pub with latitude and Longitude so anybody have idea regarding this? From where i should get data in xml format so i can parse and display it.
You should not use google-maps-api for this. Instead, use Google Places API to load the pub/restaurant locations. Google Places API link.

Resources