Spotify integration with Facebook OpenGraph - facebook-opengraph

I'm trying to reproduce some cool things of the Spotify opengraph integration but there is one thing I understand how they do :
when you go on your spotify app profile (mine : https://www.facebook.com/antonio.mendespinto/music) you can see that the musician links points to the facebook page and not the spotify web pages (http://open.spotify.com/artist/7CajNmpbOovFoOoasH2HaY). How do they do that.
Also, is it this that lets Facebook to do behind the scenes the nice box in the artists page https://www.facebook.com/ogp/464730384564/ on the top showing friends interactions with the artist and spotify friend interactions.
Everything seems to point to the facebook pages instead of the spotify pages. How do they do that?

Yes, Spotify uses Facebook Open Graph Music, a predefined set of objects and properties for music.
https://developers.facebook.com/docs/opengraph/music/
Then I guess the Spotify account is marked in a way that makes this available. It is possible that this is what makes Facebook show the nice box in the artist page.
I work at Spotify, but I am not really sure about all the details of this. I know other music streaming services also use this, but I am not sure if it still requires a special account. It did in the beginning. Spotify was one of the first users of Open Graph.

The destination of the links inside Open Graph artifacts are left to the discretion of the developer. Say you're writing an app that lets people share restaurant tips. When you post a "Tip" object to OG, you naturally would include a link to the restaurant. As the app developer, you could choose the restaurant's web page, its Yelp page, its OpenTable page, your own representation of the restaurant page on your web site or any other web page on the internets. :-)
Being faced with a similar situation, I chose to use my own application's web page representing a restaurant. I experimented with using the restaurant's Facebook page (which I had to look up using the Graph API for search) as well as a third-party provider of restaurant information, e.g. Yelp. Using the Facebook page, my app felt more tightly integrated with Facebook, but I didn't get the luxury of having my own Facebook app metadata. Because I chose to link to my own restaurant page, I was able to set and retrieve whatever metadata I wanted, which really came in handy later when I started configuring aggregations.
I don't know how Spotify data surfaces on artist pages nor do I know how they managed to shoehorn song AND album objects into each listen post on OpenGraph, e.g.: "Chris listened to Torn and Frayed on Exile on Main Street." I could only ever get ONE object linked to an action, e.g. "Chris left a tip on California Pizza Kitchen." My assumption is that since they were one of the (if not the only) Facebook Open Graph launch partner, they probably had some inside help.

Related

What framework to use for a responsive private website that has individual areas?

A group of business owners have asked me to create a responsive website just for them (public-facing page is login page). They want to be able to login and each have their own individual area which will show their business location and information about their business. They have recently tested doing a survey about their business environment, and they liked it and want each survey result presented in their private area too. Note, each owner will not see the private information of other owners. However, they also want a shared area with resources relevant for their industry (e.g. latest regulations, relevant industry PPTs) which they all can see (again, not public facing).
My question is, what is the best framework for making this website, which will also look ok on mobile? Previously I've made public facing websites with Elementor and WordPress - which meet the 'responsive website' requirements and for which I can envisage setting up the shared resource area - but what to use for login and creating individual areas?
Ideally after a business owner logs in they will have a personalized dashboard with their business information, and links to their page with survey results, location map etc. However, everyone will have the same index, e.g. Homepage (individualized dashboard), Survey Results (which will only show their results), Resources (everyone will see the same thing), Newsletter (they all see the same one).
I have used a free online form maker and made a digital version of the survey for them already, which automatically loads the data to a Google Sheet and then I split results in chart form to individual sheets with per person viewing permission. I have each owner's business location data ready in Google Maps. All these items I can easily embed into a page - once I have a framework setup for these private areas.
There are only about 18 business owners so it isn't a lot. I looked at using the WordPress inbuilt page password function to do this but it isn't working on most browsers for me, and I found many others encountered this same issue. I've looked at "WordPress client portal" plugin (uses password protected categories), WordPress Client Portal Plugin from SuiteDash (has the functionality but it is very very slow), ClientPortal (I can't find any option to try this plugin), and WP Customer Area (this seems great, but I found it too difficult to use even though it is free. I realize maybe my understanding isn't good enough - but I can't find good guides in English for it).
I also found some other "membership" type plugins, but they were relevant for providing customers with paid content at a tier level. I.e., you login and if you pay for "S" tier then you get access to that content. There is no paid content for the website that these owners want.
Appreciate any advice anyone may have on a suitable framework. I don't mind paying for something that fits these needs! Thanks for your help.

Google Play Store - web scrape top apps for every genre

Currently when I access the Google Play store from a browser (https://play.google.com/store/apps/top?hl=en), I can only see:
Top Apps, Top Selling Apps, Top Grossing Apps, Top Games, Top Selling Games, Top Grossing games.
I am trying to scrape data to get the top selling/grossing apps on the Play Store for EVERY GENRE of apps (i.e. Education, Health, Social, etc). I would've thought this data would be available on the browser Play Store because apparently it is available on the Android App Play Store. When selecting a category on the web browser Play Store, there are no options to view the top selling/grossing apps.
There are many (commercial) API's that give information on top Google Play apps for each genre so surely this information is able to be scraped from somewhere? For example Applyzer, https://www.applyzer.com/?mmenu=worldcharts shows top apps for every genre on the Play store. I would web scrape from here but I want to do this directly from Google.
Any insights would be greatly appreciated.
SOLVED: see my own post below
SOLVED: I just managed to solve this myself. Turns out the Google Play Store does display this information, but you must manually enter the URL yourself. For example: https://play.google.com/store/apps/category/BUSINESS/collection/topselling_paid BUSINESS can be replaced by any category, and topselling_paid can be interchanged with topselling_free or topgrossing

Google Maps query businesses Near Me Search

Objective
Client wants a map on the search results page that shows a Google Map with all business listings, matching the users search parameters, that are near that user.
Background
I have a client who is building a business directory website.
This client is currently using a WordPress plugin called GeoDirectory and would like to have a map on the search results page that shows a Google Map with all business listings, matching the users search parameters, that are near that user.
These would not be the businesses on the website they would be the businesses that you would get if you did a search on Google say "restaurants near me" and it would show those businesses.
The client wants it to look exactly like the google map that results from that search so it would take the query created by the GeoDirectory plugin and show a list of businesses from the clients site that match a specific category and also a google map of other businesses in the area that are listed on Google.
Question
Is this possible?
I don't really have a link to show an example but if you type in "restaurants near me" in the google search bar and click on the map that pops up in the search results you will see what I mean.
Is it possible?
I don't know WordPress, but coming from a Google Maps background, I can definitely tell you that yes, it is possible.
What can I use?
Depending where you make your request from, you can either use the Places API Web Service (server side) or the JavaScript API with the Places Library (for client side).
For more information about the Places API and related products you can visit https://developers.google.com/places/documentation/
How can the Places API help me?
The Places API Web Service and its library for the JavaScript API have a functionality that you can use called PlacesSearch, which is exactly what you need.
Examples and Docs
To use this functionality, lets say, using the Web API, you need to make a GET request like the following:
https://maps.googleapis.com/maps/api/place/nearbysearch/output?parameters
Using the JavaScript API, you would send a request like this:
https://developers.google.com/maps/documentation/javascript/places#place_search_requests
With this information, you can include a map, and quickly get the information you need by having the user type in a text box.
The example below demonstrates how this concept works
https://developers.google.com/maps/documentation/javascript/examples/place-search

How to add a bespoke social sharing message to a specific page

I've used services like 'Add This' for a while but now I need to add a couple of specific bits of functionality to an ecommerce order completion page. It's to work like Amazon's order thank you page where it allows you to post a message to Facebook saying something like 'I just bought a widget on Amazon'.
Equally I'm looking for the equivalent in Twitter.
I've added a bunch of OG tags and share buttons but can't get it to do what I need. From further reading it sounds like I might need to create a Facebook app of some sort and use FB ui to create the link to post to the user's wall. I was hoping to do this without getting tangled up in that level of permissions etc but maybe that's not possible any more?
This is being developed on asp.net C#, in case there's a library that I haven't found in my searching.
Can anyone familiar with this type of development point me in the right direction?
For Twitter, the simplest way is to use Web Intents.
For example, if you want to share the text
I love http://example.com
URL encode the text to I%20love%20http%3A%2F%2Fexample.com and use the Twitter Web Intent URI. E.g.
https://twitter.com/intent/tweet?text=I%20love%20http%3A%2F%2Fexample.com
When the user clicks on that link (try it!) or is directed there by your service, they'll be prompted to share that text.

Adopt another site's Open Graph properties

I'm implementing the Open Graph protocol on my site, and I'm curious if it is possible to "adopt" another site's Open Graph properties within my site's web pages.
For example, suppose a user makes a post to my site that contains a link to an article (such as the New York Times). They then share that post on platforms such as Facebook and Twitter, and I want the preview image on those platforms to contain the Open Graph image from the New York Times article web page.
Is this possible?
It's possible, when the user validates the post, you have to check the links inside to target the link of NYT. Then you have to parse yourself the page of the NYT to return the content you want. And finally you use the informations of the OG Tags of the NYT's page.
I think it's a heavy process, and keep in mind that Google penalize heavily the duplicate content from the others websites.

Resources