Is it possible to get Information about Chromecast device from receiver app - chromecast

I am developing an app for Chromecast and I need something specific about that particular device. (MAC Address, ID, something like that) in order to generate an unique deviceID.
I need to access the information from the receiver app.
If it's not possible, how can I generate the same unique deviceID at startup?

There is no API on the receiver to return the MAC address or any other unique identifier; you need to create and manage that yourself.

Related

Azure NotificationHubs how do I get the devicetoken from an iPhone

I am using Azure NotificationsHubs for iOS push notifications and want to get the deviceToken to register the device, along with the user, in a table through an api so I can send notifications to specific users/devices and keep track of badge counts. When not using Azure Notification Hubs.
func application(
_ application: UIApplication,
didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data
) {
print("DeviceToken: \(deviceToken)")
}
I see the documentation says:
By default, the SDK will swizzle methods to automatically intercept
calls to UIApplicationDelegate/NSApplicationDelegate for calls to
registering and intercepting push notifications, as well as
UNUserNotificationCenterDelegate methods. Note this is only available
for iOS, watchOS, and Mac Catalyst. This is not supported on macOS and
tvOS.
I'm not sure what swizzling means but I don't want to disable what I have working thus far. Is there another way within the standard implementation to get the deviceToken?
I also see this in the documentation:
To target a particular user on the backend, you can specify a tag such as $UserId:{VALUE} where VALUE is the user name you have specified, just as you can target an installation using the $InstallationId:{VALUE} tag.
But how do I get the InstallationId and is that different from the deviceId or value I use in xcrun simctl push? I expect somewhere I will need to store it on the server side and associate it with a user or something.
I read this post which states:
When you send a notification from the server, one of the paramters is the device ID.
I could do it by user only, but what if they want different notification preference for different devices?
I expect to send to a specific user on a specific device from the server you would use tags, for example:
Microsoft.Azure.NotificationHubs.NotificationOutcome outcome = null;
String userTag = "(UserId:xxxx)";
// substituting for iOS
var toast = "{\"aps\":{\"alert\":\"This is a test\"}}";
outcome = await Notifications.Instance.Hub.SendWindowsNativeNotificationAsync(toast, userTag);
On the client, I am setting the user id like this:
let userId = "xxxx"
MSNotificationHub.setUserId(userId);
Even without the device id part of it, I can't get the user part working. I can send a notification without any tags, but I add in the user tag and it does not work. I assumed by calling setUserId that would add a tag, based on the links above.

Spoofing messages for a Legal Company

We have application that automatically sends message through a broadband stick then We want to buy a sim or any other way (LEGALLY) that make our Sender number will be a Company name
0999xxxxxx7 into CompanyName
please give me suggestion
(Philippines)
You can use a service like http://www.clickatell.com/ and specify the sender ID when sending messages through their API. However, the sender ID capability is not supported everywhere and you might have to get multiple numbers from then to support different locations.

Chromecast Custom Receiver show different content

Is there a way for a Chromecast Customer Receiver app to differentiate which Chromecast device is connected and then show different content based on such ID or unique connector?
If you are asking whether there is an api on the receiver side to return a unique id, the answer is no, there is no such api.

Chromecast styled receiver app ID

I am unable to cast with my styled receiver from chrome browser.
I have an unpublished styled receiver chromecast app. The "preview" button works fine. My testing device is registered with status "ready for testing". The send serial number checkbox is checked from my android app (OS X app never finds chromecast, so I cannot verify with another app).
Setting the app ID to be my application ID (which seems to be an 8 digit number in the SDK developer console) throws a session error when I try to connect. Changing this back to the default app ID has success. I registered a second identical application and tried with that ID as well.
What could have gone wrong? I am unable to connect to the debugging console, but I read on SO that you need a custom receiver (not styled receiver) to connect.
I am able to connect to the custom receiver as defined in this sample receiver as well.
Is there no testing for styled receivers?
Note that there is one oddity about my setup, and that is that the chromecast is connecting to a wifi network that has been shared by my macbook, not a normal router.
You don't need a custom receiver to be able to debug, using your own Styled receiver is adequate (you basically need to have your own App Id). I would suggest you double check your serial number; take a photo and enlarge that to make sure it was read correctly.
Solution was use a router instead of sharing internet access via Wi-Fi from my macbook. Re-checked the send serial number box, restarted device and everything worked.

List of Devices Registered on GCM

I am using Google Cloud Messaging APIs.
On the server side i want to get the list of all the devices that are registered on a Project ID that is given by Google Cloud Messaging .So could i get the all list of the devices so that i can store all of them into the database.Please provide me the suggestion on this how can we do this.Thanks
You must be registering a device on client side by getting the registration ID. So, as soon the user's device gets a registration ID, send the ID to your own server. At your server, you can store all the registration ID's this way. You'll have the list of all the devices that are registered to your SENDER ID.

Resources