Unknown (undocumented) SONOS display type used in Spotify music-service on mobile devices - sonos

Even though there are already 2 other questions on the subject (this and this), no documentation have yet been provided by somebody from Sonos developer team.
The problem still remains: how one can attain a similar customised Spotify-like display type on Sonos mobile controller app. I'm talking about the root container of the Spotify music-service. It looks like this.
whereas the documentation clearly only talks about the grid, list, hero and editorial display types, none of which being the one used in Spotify music-service integration. Take a look:
grid
list
hero
editorial
The above 2 other questions I mentioned indicate that, as of April '18, Sonos developer team was working on enabling this experience, but, after almost 2 years, there is nothing AFAIK.
Thanks for help!

Sonos seem to have given up on developer support here. Spotify uses non-public features of SMAPI to customize its home screen, based on json instead of SOAP.

It seems like Spotify uses a different capability flag for this. In the music services discovery you can fetch from the player. You see they provide a json manifest.
As explained here, I suspect the capabilities field is a bitmask, where you can store one or more booleans in a single integer. You just have to figure out which one says, extended metadata (and send a PR on the documentation).
{
"Name": "Spotify",
"Version": "1.1",
"Uri": "https://spotify-v5.ws.sonos.com/smapi",
"SecureUri": "https://spotify-v5.ws.sonos.com/smapi",
"ContainerType": "MService",
"Capabilities": "5310995",
"Manifest": {
"Version": "12",
"Uri": "https://mnfts.ws.sonos.com/p/spotify-manifest.5.json"
},
"Id": 9,
"Policy": {
"Auth": "AppLink",
"PollInterval": 300
}
},
Other services should be able to provide a similar experience.
I’m not connected to Sonos, I just written a extensive documentation page about local control off Sonos speakers.

Related

Can I use Orange Authentication France to connect to Live Object?

When I look to APIs doc, it seems that there is a distinct mechanism to authentify user on Live Object :
Live Object API and Orange API
What should I use to develop a Live Object based LORA web application where user identify themself with their LiveObject credentials ?
No it's totally different APIs. Live Objects APIs are not exposed within "Orange Developper".
Moreover the Live Objects "Partners API", you are pointing are reserved for special integrations with partners.
To build an application on top of Live Objects, you just need:
* a Live Objects account (https://liveobjects.orange-business.com/#/request_account)
* use MQTT API: for real time message consumption (bridge mode)
* use REST API: For all other usages (provisioning, data search, device management..)
Both API rely on API key not on oauth2. To create your API Key you have to log into your Live Objects account.
You could find a lot of resources here https://liveobjects.orange-business.com/#/faq that may help you.
You can also get in touch with Orange to expose your needs and get support for your project at liveobjects.contact#orange.com
best regards
F.

Does the Shopify API have a way to get a list of all installed apps?

Does the Shopify API have a way to get a list of all installed apps?
I want to keep a history of all apps installed on my stores. The only relevant thing I can find in the API docs is about a Webhook to get notified of an 'app/uninstalled' event.
EDIT
An 'app/installed' event would be ideal, if it existed. It would enhance the security of my stores if I could fetch the list of apps that are installed, or be notified when an app is installed or uninstalled.
To address security concerns, I believe that access to this data should be restricted in the same ways that other API endpoints and webhooks are restricted. The store owner would grant permission to an app to allow it access. This would make it as secure as, for example, customer names.
I'm looking for something roughly equivalent to WordPress's get_plugins function, but for Shopify.
Hey you can use this endpoint to fetch all the installed apps https://shopify.dev/api/admin-graphql/2022-01/objects/queryroot#connections
##example request##
appInstallations (first: 5) {
edges {
node {
id,
launchUrl,
app{
title
},
}
}
}
No. You cannot use the API to query a shop about what Apps it has installed. Imagine that. You get to know all those little shop details and do what with them? Would be like giving you permission to uninstall Apps too. You see why that is a problem? Bad enough Apps can perform cross-talk with metafields... Apps would be another level of wrong.

Workaround for new Instagram API restriction for tagged content

I built a module for my company's marketing team to fetch all the photos based on a hashtag. Such as #nofilter.
I was using the URL https://api.instagram.com/v1/tags/nofilter/media/recent with no problems until Instagram decided to change their API authentication to OAuth.
I followed the new guidelines but my client is still in sandbox mode and the API call doesn't return anything anymore. All it returns is:
{"pagination": {"deprecation_warning": "next_max_id and min_id are deprecated for this endpoint; use min_tag_id and max_tag_id instead"}, "meta": {"code": 200}, "data": []}
It seems like I need to submit my application to be reviewed before going live. But this doesn't seem possible, based on what i found from their submission guideline below. Is there any workaround for this?
====== UPDATE July 8th, 2016
I have found one of those 3rd parties that instagram mentioned, but the pricing is awful https://www.dialogfeed.com/pricing/
189 euros per month seem a bit steep
I had to deal with this. Their documentation is pretty unhelpful and doesn't seem to offer any solution for someone just wanting to collect relevant links, which should be no prob.
Fortunately, the script on an Instagram page provides easy access to their structured data. In my rails app I create a headless browser and just hit their url. I provided my solution as an answer to another question:
https://stackoverflow.com/a/38572893/4888422

Clarify the meaning of APIs

An application-programming interface (API) is a set of programming instructions and standards for accessing a Web-based software application. Could someone explain to me in case of Google maps or Youtube which is the API and which is the software application? Are both visible to us and how? I know there are tons of articles out there, however I cannot clarify the above. APIs are like the waiters that transfer data among different machines. Okay, which exactly is the Google maps API and how do we call/use it? And which is the Google maps software application which is accessed by the API? When we write for example http://maps.google.co.uk/ do we call the API? My query may seem silly but I cannot find a good answer for that.
An application-programming interface (API) is a set of programming
instructions and standards for accessing a Web-based software
application.
Firstly, an API is not just for web-based software. Even your computer's OS provides APIs for hardware and software installed in the box.
For your question, an API is a method (code instructions) to connect your application to the features of another system. Allowing your application to use thay system's features as provided via the API.
Could someone explain to me in case of Google maps or Youtube which is
the API and which is the software application?
In the case of Youtube... Let's say you are making some Android video player app that you also want to be able to playback Youtube videos within that app. The software application is your own Android player code and to access the Youtube data you would use Youtube's Android API.
An example of using the API is this module : YouTubePlayer which as you can see provide API commands like loadVideo(String videoId, int timeMillis). Where videoId is the Youtube ID and timeMillis is the desired start time within the video).
When we write for example http://maps.google.co.uk/ how do we call the
API?
That's not how you would call the API. You must first visit the documentation of the API to see how it's expected to call features within your own app.
Google Maps : https://developers.google.com/maps/documentation/
Let's assume now you're coding a Javascript app, you can see the commands here as a startng point. There is also an example page showing code & result.
Simple terms:
API = the waiter
Application Software = the chef
You order from the waiter. The waiter brings it to the chef. The chef prepares the food. The waiter then brings you your food. Then you figure out what to do with the food; eat it, take it home, throw it on the floor, let your dog eat it, give it the homeless, etc...
A website, app, etc... would send an API request (your order with the waiter) to Google Maps (the chef). If your API request is valid, Google Maps will send back an response (your cooked food with the waiter). Then the website or app takes the returned data and displays it in their custom way to you.
In the case of Google Maps, apps like Yelp and others use Google Maps' API to request specific data; routes, addresses, etc… and then they display it on their app.
To make an API request/call you have access to use the API, format it correctly, and figure out what to do when Google sends a response back : https://developers.google.com/maps/documentation/
API is a set of functions and procedures that allow the creation of applications which access the features or data of an operating system, application, or other service.
An API is like building block for your application. Multiple API's can exchange data without knowing the other's implementation. In a good design pattern , we should design API's for different independent tasks and then merge them.
Google Maps API
This is the google maps API which a developer can use to develop his own piece of software.
Whenever we use any software and it's different features, we might be using their API's without generally knowing of them.
A software application is always visible to us, but an API is visible only if the developer wants to expose it for community use.
EDIT
Using Google maps API
This link has the documentation and examples on how to use the google maps API using javascript.
Hope it helps!
When you use software, web applications included, you are in most cases using a wrapped API. Software developers took the time to take a raw back end API which executes commands on the system, and made these endpoints easy to use for a specific user in an intended universe of discourse, or domain. End users do not have direct access to everything the API has to offer all at once, so it is not "available" in the same sense that it is available to the developers, but it is available in another sense because they are using the API to execute commands on the system by virtue of the Application that was Programmed with that Interface existing and working.
The Google Maps API is used to integrate the power of Google Maps into almost any application. It provides facilities for customization and much more. When you use the Google Maps webapp, it is, to my knowledge, built using many components of the Google Maps API, as are the Google Maps apps for any other platform, such as Android. Does this mean you as a user are using the API? Only through the application; the application talks to the API for you.
“An application programming interface (API) is a set of routines, protocols, and tools for building software applications. An API expresses a software component in terms of its operations, inputs, outputs, and underlying types. An API defines functionalities that are independent of their respective implementations, which allows definitions and implementations to vary without compromising each other. A good API makes it easier to develop a program by providing all the building blocks.
APIs often come in the form of a library that includes specifications for routines, data structures, object classes, and variables. In other cases, notably SOAP and REST services, an API is simply a specification of remote calls exposed to the API consumers.
An API specification can take many forms, including an International Standard, such as POSIX, vendor documentation, such as the Microsoft Windows API, or the libraries of a programming language, e.g., the Standard Template Library in C++ or the Java APIs.
An API differs from an application binary interface (ABI) in that an API is source code-based while an ABI is a binary interface. For instance POSIX is an API, while the Linux Standard Base provides an ABI”.
To speak plainly, an API is the messenger that runs and delivers your request to the provider you’re requesting it from, and then delivers the response back to you.
To give you a familiar example, think of an API as a waiter in a restaurant.
Imagine you’re sitting at the table with a menu of choices to order from, and the kitchen is the provider who will fulfill your order.
What’s missing is the critical link to communicate your order to the kitchen and deliver your food back to your table.
That’s where the waiter (or API) comes in. ”AHEM”
The waiter takes your order, delivers it to the kitchen, and then delivers the food (or response) back to you. (Hopefully without letting your order crash if designed correctly)
Now that we’ve whetted your appetite, let’s apply this to a real API example. In keeping with our theme, let’s book a flight to a culinary capital – Paris.
You’re probably familiar with the process of searching for airline flights online. Just like at a restaurant, you have a menu of options to choose from ( a dropdown menu in this case). You choose a departure city and date, a return city and date, cabin class, and other variables (like meal or seating, baggage or pet requests)
In order to book your flight, you interact with the airline’s website to access the airline’s database to see if any seats are available on those dates, and what the cost might be based on certain variables.
But, what if you are not using the airline’s website, which has direct access to the information? What if you are using online travel service that aggregates information from many different airlines? Just like a human interacts with the airline’s website to get that information, an application interacts with the airline’s API.
The API is the interface that, like your helpful waiter, runs and and delivers the data from that online travel service to the airline’s systems over the Internet.
It also then takes the airline’s response to your request and delivers right back to the online travel service .
And through each step of the process it facilitates that interaction between the travel service and the airline’s systems - from seat selection to payment and booking.
So now you can see that it’s APIs that make it possible for us all to use travel sites. They interface with with airlines’ APIs to gather information in order to present options back to us
The same goes for all interactions between applications, data and devices - they all have API’s that allow computers to operate them, and that's what ultimately creates connectivity.
API’s provide a standard way of accessing any application, data or device whether it is shopping from your phone, or accessing cloud applications at work.
So, whenever you think of an API, just think of it as your waiter running back and forth between applications, databases and devices to deliver data and create the connectivity that puts the world at our fingertips. And whenever you think of creating an API,
--MuleSoft

is it possible to identify telecom provider by mobile or phone number?

There are ulimited online bulk sms provider supporting Restful API. Mainly I look into Nexmo, Tropo, Twilio pricing in different countries.
Let take an example sms to Brazil.
[ TROPO ]
2¢ / msg
[ Nexmo ]
3.63¢ / msg
[ Twilio ]
Twilo offers based on providers. see the pricing.
Vivo 8.3¢ / msg
Claro 8.6¢ / msg
TIM 1.2¢ / msg
Oi 8.3¢ / msg
So, What I want is before sending SMS, I want to identify the Provider. See the example sending sms to TIM is cheaper in Twilio but others Tropo and Nexmo are cheaper. If there is a way to identify the telecom provider then I can program which API to use before sending sms. I don't know this question should be posted here or not. Is there a way or api available to identify this? Thank you.
I didn't see ready solutions, except databases in billings (in most cases they are detailed as needed for concrete needs)
The "number one" source is ITU. Link to docs - http://www.itu.int/oth/T0202.aspx?parent=T0202
It's official source, but it isn't ready to consume database. You must spend much time to manually create database.
There are some preparsed databases, as http://en.allworldsms.com/html/phone_codes.php ...
it's ugly, but it contains logos. And it's not downloadable in one file, but it's still easy to consume.
http://www.data24-7.com/git.php offers a free look up service if you want to use the web based panel they have. If you want API access they charge a sub-penny rate per look up. When I was using it the rate was something like .006 cents. Also the data was only about 90% correct. They may have improved it since then.
You can get more then just the provider, you can also tell if the phone number supports SMS, if it's wireless and what the greeting interrupt tone is (the number that by-passes the voice mail greeting).