when I call Tuya Smart API, how to resolve it if the calling interface has an error code: 1106, permission deny? - api

I checked the device is paired with Tuya Smart App, and then use the device Id in Tuya Smart APP for control; I confirm the Id of the device to be controlled is correct.

I tried it a few times with the engineer,there are several situations:
The device to be controlled is not an OEM App created by the developer on the Tuya Open Platform; or the Tuya Smart APP is used to pair the device and then control the device through an interface call.
solution:
First check if the device is paired with Tuya Smart APP, and then use the device Id in Tuya Smart APP for control;
Then check whether the Id of the device to be controlled is correct and whether it is from an OEM APP created by its own developer account or an APP developed based on the SDK;
In the end, you need to make sure that the device and product created by the OEM APP created under your developer account can be controlled through the cloud-cloud docking API call.
The device requested to be controlled has been removed, restored to factory settings, or re-configured to the network.
solution:
If the device has been removed, please re-configure the network and add it in the APP;
Re-obtain the device list and refresh the device ids to be controlled.
Interface parameter passing error.
solution:
Check if the following parameters are correct:
The device id is wrong. Note that the device id is not uuid.
The area url is wrong. Pay attention to the area where the device is paired. At the same time, call the interface address of the corresponding area.

there are 3 different api explorer calls to retrieve the status, only one works for me: https://openapi.tuyaeu.com/v1.1/iot-03/ (General Device Management -> Get Device Information)

Related

In auth0, are client ids unique to a given app, or to a given instance of an app running on a device?

I'm reading a tutorial on Auth0 at this link: https://auth0.com/docs/getting-started/the-basics
It says "Each application is assigned a Client ID upon creation". When it says "application" does it mean the app in general, or an instance of the app running on a given device? In other words, if my friend and I are running the same app on out respective devices, is the app given a client id when it's created, say "id123", and the client id is "id123" for the instances of the app running on both of our devices, or would my instance be given one client id, and my friend's another?
It says "Each application is assigned a Client ID upon creation". When it says "application" does it mean the app in general, or an instance of the app running on a given device?
It means under the Application tab, the client ID associated with each app in there, not on any given device. I hope this clarifies things!

How to autodetect internal number of sip/ip phone

I need to do some actions with sip phone from desktop application. The sip service provide api to handle events and send commands to manage calls. To control calls from specific phone device I need to know internal number.
The question is about how to automatically get the internal number attached to users sip device?
Users can change locations and when they logging in I need to detect internal phone number of device that used at this moment.

Save data on iOS device permenatly

I want to save data on device itself that would be persistent even after deleting the app and installing it again (data can even be one int/date).
According to my knowledge it is impossible because each app can store data only on it's sandbox (I know I can use iCloud etc. but I don't want any services user can not have or give the app specific permissions).
As to my understanding the only option to do that is to store it on my server.
But, Apple doesn't allow to send UDID or any other specific device ID and I can't get the iTunes ID. I know I can use any other ID like Facebook ID but the app doesn't have it and that would make a really bad user experience.
I've download apps that does just that successfully (saving data specifically to my device that been recovered even after deletion and without the need to enter any ID or login process). How do they do it? Do they send UDID to some server and apple miss that or there is a way to save data outside the app sandbox?
Well there is the KeyChain, which can store data the would kept even if you delete the app.
We do that too in our app:
Basiclly we create an UDID of our own and store that on the device (in the keychain).
Combined with user id that gives us all we need on the server side to identify the user and his device. We don't store any other app data on the device, all is server managed.
You could pack your data up, store it in the documents folder for your app, and back up your device to the cloud or iTunes. you can then do a restore to get it back. You just can't do anything on your phone between the backup and the restore. Just saying.

Apple ID retrievable from App download within Cocoa Touch

Hi
I'm working on an iphone app that needs to be maintain a somewhat unique identifier per download. Is there a way to retrieve either the Apple ID used to download the App or another identifier I can use to link all devices with that download to a remote database/service?
Basically I want a single instance of my custom-generated data sitting on whatever device is linked to a certain Apple ID. If iTunes signs any App that you download, using that checksum would also be an option.
Any thoughts?
If you use IAP(In App Purchase), you can tie a users purchase to a single receipt, and verify that receipt against Apple's servers.
For App store purchases, as opposed to IAP, Apple allows, and pretty much forces a developer to allow their App store apps to run identically on as many devices as a customer can put their iTunes account on, with no information available to the app about whether this was the customer's first install or their Nth. If that business model doesn't work for you, don't put the app for sale in the App store.
As far as I am aware, there is absolutely no way to get access to the current signed-in Apple ID on the device. Your only real option is to maintain your own username/login combo that the user has to enter on each device they own.
I don't believe you can get the Apple ID, but you can however get the current device's ID via the UIDevice uniqueIdentifier method.
For example:
UIDevice *ourDevice = [UIDevice currentDevice];
NSString *uniqueIdentifier = [ourDevice uniqueIdentifier];
However, you should note the following (emphasis mine) from the above linked document:
A device’s unique identifier
(sometimes abbreviated as UDID for
Unique Device Identifier) is a hash
value composed from various hardware
identifiers such as the device serial
number. It is guaranteed to be unique
for each device. The UDID is
independent of the device name. For
devices that use a SIM (subscriber
identity module) card, the UDID is
independent of the SIM card.
For user security and privacy, you
must not publicly associate a device’s
unique identifier with a user account.
You may use the UDID, in conjunction
with an application-specific user ID,
for identifying application-specific
data on your server.

Allow user to create account on one device and use that account on others

I want to make an application that has some views for information display. If I install my app on my iPhone then it should display the info. If I then install that app on my iPad then the app should recognize the device and display the info related to my account.
Is there any way to find the single user of two devices without the user's iTunes credentials, or is it possible to generate a key that can identify the common user of both devices?
No, currently there is no way to associate multiple devices to a single user owning those devices given the information you've provided.
However, if you added, "the information I want to display in the views, pertains to the same user account in Game Center for both devices", then you could use the player's identifier from Game Kit API.
https://developer.apple.com/game-center/
This is being added well after the fact, but:
You could use iCloud APIs to accomplish this. These are distinct from iTunes credentials, but obviously the same type of prerequisite in that the user must have an account and it's not under your control.