I have an app "a" and "b" and I would like that, when completing a registration in app a, app b would be opened, but I have found it difficult to understand and I would not like to send the user to the play store, I would like it to be directed directly to the app B
I tried to use:
if (await Launcher.CanOpenAsync("fb://"))
{
await Launcher.OpenAsync("fb://");
}
but I don't understand where this uri comes from
Related
Working on a Messaging Extension app for Teams that opens a Task Module in a Teams Meeting. This app is installed from the "Built for your org" section of the Teams store after being loaded into a Tenant by a Teams Admin. Any tenant user who has the app installed can select the messaging extension from the … menu in a Teams Meeting to initialize the Task Module.
Before initializing the Task Module, the app's bot must be added to the meeting chat so an "Add app" button is presented after selecting the messaging extension. This button sends through a payload with the justInTimeInstall value set to true. When a new Teams user who has never used the messaging extension before tries to tap on this Add app button on a mobile device, the button either does nothing and the user is returned to the chat (iOS) or an error page with a retry button is presented and the retry button keeps presenting the same error page (Android).
When examining a network trace of this button press, a 502 code is being returned with the following JSON:
{
"errorCode": 1008,
"message": "<BotError>Bot returned unsuccessful status code Forbidden",
"standardizedError": {
"errorCode": 1008,
"errorSubCode": 1,
"errorDescription": "<BotError>Bot returned unsuccessful status code Forbidden"
}
}
This combined with some other logging makes it seem like the response isn't even getting to the app's server. This is only a problem on mobile for a Teams user who hasn't used this messaging extension app. If the same user adds the app to the meeting from desktop/web, then they can come back on mobile and the "add app" button will work in any meeting from that point forward.
Is this a known issue or is there something that I might be missing here that's preventing the app from being added for new users on mobile?
I have a published application in the Microsoft App store.
Before heading towards the issue, explain below how it works when the app is installed in the team. So, when the bot/app is added to the team it sends a proactive welcome message inside the team. Below is the code which is responsible for this:
constructor() {
super();
this.onConversationUpdate(async (handler) => {
let activity = handler._activity;
if (activity.membersAdded) {
if (activity.membersAdded[0].id.includes(process.env.MicrosoftAppId)) {
// Send proactive welcome message
}
}
}
}
Keeping in mind when the app is installed/added to a team, definitely there should be handler data with me.
That's the case and it's working fine all over tested in different tenants as well, everything working fine.
But, in one of the tenants, there are 3-4 teams, Installing/adding the app doesn’t trigger the constructor at all. Not even a single log is getting there for me. Strangely, inside the manage team` - App section, I could see the app.
Not sure if is it a bug in MS Teams.
I'm creating my first Microsoft Teams extension. For now I'm just trying to get the basic plumbing for a messaging extension working. I'm trying to build an extension which will allow a user to search for content in my service and then return a card into their compose window in personal and Teams chats.
I've tried to follow the basic guide ( https://learn.microsoft.com/en-us/microsoftteams/platform/messaging-extensions/how-to/create-messaging-extension ) for creating a messaging extension using App Studio. I've setup a bot as it describes, and I have built a dummy echobot endpoint for the bot (using Ruby). I am able to "chat" with my bot directly in the Teams client and it is able to respond.
My messaging extension defines an action based command with a taskInfo with a web view URL to render and a fetchTask set to false. I've written a basic static HTML page for this and included the teams-js library. The web view loads and the teams-js library initialization callback is called. I have a submit button which calls microsoftTeams.tasks.submitTask which as I understand it, should be calling my bot with a "composeExtension/submitAction" message to which I would respond with the card. (Based on https://learn.microsoft.com/en-us/microsoftteams/platform/messaging-extensions/how-to/action-commands/respond-to-task-module-submit?tabs=json )
I've tried installing my extension in Teams through the "Upload a custom app" option both as a "for me and my teams" and "for " but still have the following issues.
When I open my extension in the Teams client from the compose area and click this submit button in my iframe content, the submit I get a "Unable to reach app. Please try again" error displayed. In the dev console, I can see that the response to the "invoke" http post is {"errorCode":404,"message":"V3 agent not found."}
No traffic is actually sent to my bot during any of this process.
I saw this older post - Compose extension is throwing error : V3 agent not found . The https://dev.botframework.com/bots/ it refers to seems to be outdated, but in the Azure "Bot Channels Registration" console, I have gone to Channels and added "Microsoft Teams" (which I believe is the new equivalent).
Has anyone seen this happen and figured out what was going on? Much thanks!
Here is sample code for composeExtension/submitAction for Bot SDK V3. Make sure you pass the bot id and command text in taskInfo object.
case "composeExtension/submitAction":
string commandid = JsonConvert.DeserializeObject<Models.TaskModuleSubmitData<string>>(activityValue).commandId;
taskInfo = GetTaskInfo(commandid);
taskEnvelope = new Models.TaskEnvelope
{
Task = new Models.Task()
{
Type = Models.TaskType.Continue,
TaskInfo = taskInfo
}
};
return Request.CreateResponse(HttpStatusCode.OK, taskEnvelope);
Hilton had the right answer.
I had grabbed the Subscription ID from the Bot Channels Registration page instead of the App ID from the Azure Active Directory -> Apps Registration page and used that in the messaging extension manifest as the "botId" in the composeExtensions array. After fixing that I'm now getting messages submitted to my bot backend.
I am working on an app for Android Watch that requires the mobile app to be on or in background. I tried using the MessageApi in order to communicate with the app on the phone, but even if the app is not on, i get a message back like it is on.
What would you suggest to check whether the phone app is running (doesnt matter whether it is foreground/background) before i enable the activity on the Android Watch?
Thanks for the help.
If you have registered a WearableListenerService in your mobile app, that will be invoked by the framework even if your app is not running (and will be invoked if your app is running, too). If, however, you are not using that service, then to receive messages or notification on changes in the wear network in your mobile app, you would need to register one or more callback listeners for the type of messages/data that you are interested in. In that case, that means if your app is not running, you will not be getting those callbacks on your mobile app. To use this, however, be sure to manage the lifecycle of your listeners in your mobile app according to your needs. For example, one can register for such listeners in onResume() of an activity and unregister in onPause(). The consequence of that is if your activity loses focus (but still alive), that activity will not receive the callback (even though as an instance it is still running). You may want to define an Application instance for your app and use that to listen for callbacks but, again, it depends on the exact nature of your needs and app.
You can search for nodes and parse them for needed result, or to check if you have a nearBy node
private Collection<String> getNodes() {
HashSet <String>results = new HashSet<String>();
NodeApi.GetConnectedNodesResult nodes =
Wearable.NodeApi.getConnectedNodes(mGoogleApiClient).await();
for (Node node : nodes.getNodes()) {
results.add(node.getId());
}
return results;
}
We're planning to develop a new application.
this application will use a lots of different companies but application will be unique.let me explain it : our users will download this application from app store
after login process we will be able to understand which companies are using this application and who is on the line at the moment..
so my question is if I want to send a push notification to a specific company and it's users who use our application, how can we do that ?
let me give you an example :
We assume that there are 3 companies
First is A , second is B and other one is C
A has 10 users , B has 4 users and C has 40 users.
I want to send a push notification TO C's users ( in this example..).. A , B and C are using same application but their credentials are different from each other.
is it possible with your PN infrastructure ? Can you share with me your opinions ? My best
This is a very very broad question,
but to lead you in the right direction, this is possible. It all depends on your method of implementing Apple's APN service. The push notification service is simply an API you can submit HTTPS requests to and it pushes the notification out to whatever devices you supply it.
The logic for whom receives these notifications is all up to you in your server side programming.
For example:
I am developing an app right now that uses a NodeJS server with the node-apn module installed. With this, I can connect to my Database where I store users device tokens (used to specify which device you are pushing to) then send a simple notification like so:
var device = new apn.Device("DEVICETOKEN");
var note = new apn.Notification();
note.payload = {custom:"objects", cango:"here", numval:56};
note.expiry = Math.floor(Date.now()/1000)+10; // 3 hours from now
note.badge = 3;
note.sound = "ringtone.wav";
note.alert = "This is a push notification";
apnConnection.pushNotification(note, device);
You should really do a little research before coming to SO with nothing, then expecting answers like this all the time when you haven't put any effort into it.
You will have to upload each app to the apple store, meaning that each company will have to open development account in apple.
Companies will send you a requested licence for the app and for the server.
You will have to compile our app with this licence.
of course every app will have a apple ID.
You can send message from the server to gateway.sandbox.push.apple.com, port 2195.