Updates from: 04/07/2023 01:36:57
Service Microsoft Docs article Related commit history on GitHub Change details
platform Conversation Messages https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/bots/how-to/conversations/conversation-messages.md
To get an edit or undelete message event notification in a bot, you can override
* For edit: `OnTeamsMessageEditAsync` * For undelete: `OnTeamsMessageUndeleteAsync`
+> [!NOTE]
+>
+>The `OnTeamsMessageEditAsync` and `OnTeamsMessageUndeleteAsync` handlers arenΓÇÖt supported in group chat and Teams channel scopes.
+ The following is an example of an edit message event notification when a sent message is edited: # [C#](#tab/dotnet3)
When you soft delete a message in a chat, the bot gets a notification of the sof
To get a soft delete message event notification in a bot, you can override the `OnTeamsMessageSoftDeleteAsync` handler.
+> [!NOTE]
+>
+>The `OnTeamsMessageSoftDeleteAsync` handler isnΓÇÖt supported in group chat and Teams channel scopes.
+ The following is an example of a soft delete message event notification when a message is soft deleted: # [C#](#tab/dotnet5)
platform App Fundamentals Overview https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/concepts/app-fundamentals-overview.md
The following table includes Teams features and availability for GCC, GCC-High,
| **Apps** |   |   |   | | Microsoft apps | Γ£ö∩╕Å Microsoft apps compliant with GCC. | Γ£ö∩╕Å Microsoft apps compliant with GCC-High. | Γ£ö∩╕Å Microsoft apps compliant with DOD. | | 3P or third-party apps | Γ£ö∩╕Å Third-party apps are available. Disabled by default and tenant admin use their own discretion to enable it. | Γ¥î | Γ¥î |
-|Line-of-business apps| ✔️ | ✔️ | ✔️ |
+|Line-of-business apps| ✔️ | ❌ | ❌ |
|Custom apps| Γ£ö∩╕Å | Γ£ö∩╕Å | Γ£ö∩╕Å | |Sideloading apps | Γ£ö∩╕Å | Γ¥î | Γ¥î | | **Capabilities** |   |   |   |
platform End User Purchase Experience https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/concepts/deploy-and-publish/appsource/prepare/end-user-purchase-experience.md
+
+ Title: Purchase and manage app subscriptions and licenses
+description: Learn how to purchase, assign, and manage licenses for third-party apps in Teams.
+++
+ms.localizationpriority: high
++
+# Purchase and manage app subscriptions and licenses
+
+Add functionality to your Teams experience by subscribing and managing licenses for apps made just for Teams. When you add an app to Teams, check if additional features are available through subscription. You can purchase subscriptions and manage licenses for yourself, your team, or your organization directly from the Teams store.
+
+## Subscription experience
+
+The following example shows how users can purchase subscription plans for a fictional Teams app called *Recloud*:
+
+1. In the Teams store, find and select the *Recloud* app.
+
+1. In the app details dialog, select **Buy a subscription**.
+
+ :::image type="content" source="~/assets/images/saas-offer/buysubscriptionplan.png" alt-text="Buying the subscription for the selected app.":::
+
+1. Select your country to see subscription plans for your location.
+
+1. In the **Choose a subscription plan** dialog, choose the plan you want and select **Checkout**. (Note: Private plans are visible only to users in orgs you're providing the offer to. These plans are indicated with a **Special offer** :::image type="icon" source="~/assets/icons/special-icon.png"::: icon.)
+
+ :::image type="content" source="~/assets/images/saas-offer/choosingsubscriptionplan.png" alt-text="Selecting the appropriate subscription plan.":::
+
+1. In the **Checkout** dialog, provide any required information and select **Place order**.
+
+ :::image type="content" source="~/assets/images/saas-offer/placesubscriptionorder.png" alt-text="Placing the subscription order.":::
+
+1. When prompted, select **Set up now** to set up your subscription.
+
+ :::image type="content" source="~/assets/images/saas-offer/saas-offer-set-up.png" alt-text="Setting up the subscription.":::
+
+1. Manage your subscription plan through the *Recloud* website (also known as a [landing page](include-saas-offer.md#build-a-landing-page-for-subscription-management)).
+
+ :::image type="content" source="~/assets/images/saas-offer/subscriptionlicenses.png" alt-text="Configuring user licenses.":::
+
+When a new user launches the app for the first time, they're requested to provide consent to the app. Following is an example of the consent screen shown when calling for user profile data with minimum User.Read permission.
+
+Consent dialog is part of the flow to get the users license information and may vary based on ISVΓÇÖs integration approach.
++
+## License management experience
+
+The following example shows how users can manage licenses for third-party apps from the Teams store:
+
+1. Go to **Microsoft Teams**.
+
+1. Select **Apps** > **Manage your apps**.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/client-experience-1.png" alt-text="Screenshot showing the existing subscription.":::
+
+1. Select **Subscriptions**. A tab appears with a list of purchases made in the tenant.
+1. Choose an existing subscription from the list and select **Assign licenses**.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/client-experience-2.png" alt-text="Screenshot showing the assigned licenses highlighted in red":::
+
+1. To view license utilization and assign licenses, select **Assign licenses**.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/view-license.png" alt-text="Screenshot showing the selected assigned licenses highlighted in red.":::
+
+1. Search for the users or a team in the search box and select **Assign**. The license is assigned to the users or a team.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/assign-licenses.png" alt-text="Screenshot showing the example of assigning license to a Team with a single click highlighted in red.":::
+
+ You can view the list of assigned users or teams for the subscription and also check the status of the assignment.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/list-of-assigned-users.png" alt-text="Screenshot showing the list of assigned users with assign licenses highlighted in red.":::
+
+1. If you want to unassign a license for a user or a team, select the users or a team from the list and select **Unassign**.
+
+ :::image type="content" source="../../../../assets/images/saas-offer/unassign-button.png" alt-text="Screenshot showing the selection of unassign button highlighted in red to unassign the users.":::
+
+## Admin purchasing experience
+
+Admins can manage the app subscriptions and licenses in the Teams admin center. For more information, see [Purchase third-party Teams apps and manage subscriptions](/microsoftteams/purchase-third-party-apps).
+
+## See also
+
+* [Monetize your app](monetize-overview.md)
+* [Set up Microsoft license management for third-party apps](manage-third-party-apps-license.md)
platform Include Saas Offer https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/concepts/deploy-and-publish/appsource/prepare/include-saas-offer.md
For complete instructions, see [build the landing page for your SaaS offer](/azu
### Best practices for landing pages
-Consider the following approaches when building a landing page for the Teams app youΓÇÖre monetizing. See an example landing page in the [end-user purchasing experience](#end-user-purchasing-experience).
+Consider the following approaches when building a landing page for the Teams app youΓÇÖre monetizing. See an example landing page in the [End-user purchase experience](end-user-purchase-experience.md).
* Users must be able to sign in to your landing page with the same Azure AD credentials they used to buy the subscription. For more information, see [Azure AD and transactable SaaS offers in the commercial marketplace](/azure/marketplace/azure-ad-saas). * Allow users to take the following actions on your landing page. DonΓÇÖt forget to consider whatΓÇÖs appropriate for a userΓÇÖs role and permissions. For example, you may want to allow only subscription admins to search for users):
YouΓÇÖve created your SaaS offer and linked it to your Teams appΓÇönow it's time
Once published, users will see a **Buy a subscription** option in the app details dialog when they try to add your app to Teams.
-## End-user purchasing experience
-
-The following example shows how users can purchase subscription plans for a fictional Teams app called *Contoso Tasks for Teams*.
-
-1. In the Teams store, find and select the *Contoso Tasks for Teams* app.
-
-1. In the app details dialog, select **Buy a subscription**.
-
- :::image type="content" source="~/assets/images/saas-offer/buysubscriptionplancontoso.png" alt-text="Buying the subscription for the selected app.":::
-
-1. Select your country to see subscription plans for your location.
-
-1. In the **Choose a subscription plan** dialog, choose the plan you want and select **Checkout**.
-
- > [!NOTE]
- > Private plans are visible only to users in orgs you're providing the offer to. These plans are indicated with a **Special offer** :::image type="icon" source="~/assets/icons/special-icon.png"::: icon.
-
- :::image type="content" source="~/assets/images/saas-offer/choosingsubscriptionplancontoso.png" alt-text="Selecting the appropriate subscription plan." lightbox="../../../../assets/images/saas-offer/choosingsubscriptionplancontoso.png":::
-
-1. In the **Checkout** dialog, provide any required information and select **Place order**.
-
- :::image type="content" source="~/assets/images/saas-offer/placesubscriptionorder.png" alt-text="Placing the subscription order.":::
-
-1. When prompted, select **Set up now** to set up your subscription.
-
- :::image type="content" source="~/assets/images/saas-offer/saas-offer-set-up.png" alt-text="Setting up the subscription.":::
-
-1. Manage your subscription plan through the *Recloud* website (also known as a [landing page](#build-a-landing-page-for-subscription-management)).
-
-## Admin purchasing experience
-
-Admins can purchase app subscription plans in the [Teams admin center](/microsoftteams/purchase-third-party-apps).
- ## Remove a SaaS offer from your app If you unlink a SaaS offer included in your Teams store listing, you must republish your app to see the change in the store.
platform Manage Third Party Apps License https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/concepts/deploy-and-publish/appsource/prepare/manage-third-party-apps-license.md
+
+ Title: Set up Microsoft license management
+description: Learn to manage SaaS licenses for third-party apps purchased from Teams storefront.
+++
+ms.localizationpriority: high
++
+# Set up Microsoft license management
+
+Independent software vendors (ISVs) can configure Microsoft license management for third-party SaaS apps in Partner Center as part of the offer publishing. This allows Teams admins or users to easily assign, unassign, use, and track SaaS licenses for their third-party app subscriptions within Teams.
+
+To enable license management for a third-party app in Teams, follow the steps:
+
+1. [Create an offer in Partner Center](#create-an-offer-in-partner-center)
+1. [Update your Teams app](#update-your-teams-app)
+1. [Post purchase](#post-purchase)
+1. [Integrate with Graph usageRights API](#integrate-with-graph-usagerights-api)
+
+## Create an offer in Partner Center
+
+1. Sign in to [Partner Center](https://partner.microsoft.com/) and select **Partner Center**.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/partner-center-home-page.png" alt-text="The screenshots shows how to login to the Partner Center account.":::
+
+1. In the **Home** page, select **Marketplace offers** tab to define commercial marketplace offers.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/home-page.png" alt-text="The screenshots shows the home page and Marketplace offer tab in the Partner Center.":::
+
+1. Select **Overview** from the left pane.
+
+1. Select **New Offer** > **Software as a Service**.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/commercial-marketplace.png" alt-text="The screenshots shows the marketplace offer page where you can select new offer.":::
+
+1. Enter **Offer ID** and **Offer alias** and select **Create**.
+
+ > [!NOTE]
+ > If you're creating an offer for testing purpose, add the text **-ISVPILOT** to the end of your offer alias. This indicates the certification team that the offer is for testing purposes. Microsoft delete offers with **-ISVPILOT** periodically. So, don't use this tag for reasons other than testing the license management capability.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/saas.png" alt-text="The screenshots shows how to enter Offer ID and Offer alias in the Partner Center.":::
+
+1. In the Offer setup page, under setup details, select the checkbox **Yes, I would like Microsoft to manage customer licenses on my behalf**.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/saas-isvpilot.png" alt-text="The screenshots shows the offer setup page to setup license to manage for your app within Teams.":::
+
+ > [!NOTE]
+ >
+ > * This is a one-time setting and you can't change it once your offer is published. This allows the customer to manage licenses for your app within Teams.
+ > * The App manifest supports only one offer for an app. Choose an appropriate license management solution for all the plans available in your offer and you can't change this option after the offer is pushed to live.
+
+1. Select **Save draft**.
+
+1. Select **Plan overview** from the left pane, and then select **Create new plan**.
+
+ > [!NOTE]
+ > You need to add at least one plan.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/plan-overview.png" alt-text="The screenshots shows plan overview to create a new plan for your apps in the Partner Center.":::
+
+1. Enter Plan ID and Plan name, and then select **Create**.
+
+1. Enter the **Plan name** and **Plan description**.
+
+ > [!NOTE]
+ > The plan information displays on Teams marketplace and [AppSource](https://appsource.microsoft.com/) under offer listing (plans section).
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/plan-listing.png" alt-text="The screenshots shows plan page to add plan name and plan description for your app.":::
+
+1. Select **Save draft**.
+
+1. Select **Pricing and availability** from the left pane.
+
+1. Add pricing and availability details.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/pricing-availability.png" alt-text="The screenshots shows pricing and availability page to add SaaS offer for your app.":::
+
+1. Select **Save draft**.
+
+1. Select **Plan overview** at the top of the page to go to the listing page that shows all the plans you've created for this offer.
+
+ :::image type="content" source="~/assets/images/first-party-license-mgt/list-of-plans-created.png" alt-text="The screenshots shows plan listing page with service ID, pricing model, availability, status and action.":::
+
+1. Copy the service ID of the plan you created to integrate with Microsoft Graph usageRights API.
+
+## Update your Teams app
+
+Update your Teams app to map to the paid functionality and [Map your Teams app](https://aka.ms/TMTG) to your offer and publish.
+
+## Post purchase
+
+1. After activation, customer is redirected from landing page to Teams License Management.
+
+1. Upon successful completion of subscription purchase, the customer is redirected to the app landing page for subscription activation. This is the existing experience for user purchasing [Monetized apps in Teams](https://aka.ms/TMTG).
+
+1. After the customer activates the subscription purchase on landing page, customer is redirected to subscriptions page in Teams via a [redirect URL](https://teams.microsoft.com/_#/subscriptionManagement) link or button that the customer selects on the publisher landing page.
+
+## Integrate with Graph usageRights API
+
+Integrate with Graph usageRights API to manage user permissions at the time of app launch by a customer who has a purchase license. You're required to determine the userΓÇÖs permissions for the app with a Graph call to the usageRights API.
+
+You can call Graph APIs to determine if the currently logged in user with a valid subscription of the plan has access to your app. To call Graph usageRights API to check user permissions, follow the steps:
+
+1. Get user OBO token: [Get access on behalf of a user](/graph/auth-v2-user).
+
+1. Call Graph to get userΓÇÖs object ID: [Use the Microsoft Graph API](/graph/use-the-api).
+
+1. Call usageRights API to determine the user has License to the plan: [List user usageRights API](/graph/api/user-list-usagerights?view=graph-rest-beta&tabs=http&preserve-view=true).
+
+ > [!NOTE]
+ >
+ > * You need to have minimum `User.Read` permissions to call usageRights.
+ > The usageRights API is currently in beta version. After the version is updated to V1, users must upgrade from beta to V1 version.
+ > * If the Azure AD app is used for both SaaS Fulfillment APIs and usageRights API, ensure that the tenant under which the Azure AD app is created is either the publishing tenant or the associated tenant in the Partner Center.
+
+To determine if the tenant for the Azure AD app is part of the Partner Center setup, follow these steps:
+
+1. Sign in to [Microsoft Partner Center](https://partner.microsoft.com/) with the publisher account that is used to publish the SaaS offer.
+1. On the upper-right corner, select the **Settings** icon.
+1. Select **Account Settings**.
+1. On the left pane, select **Tenants**.
+ You can see all tenants associated with the Microsoft Partner Network (MPN) account. The tenant, who is the owner of the Azure AD app, must be available in the list. If the tenant isnΓÇÖt on the list, you can use the **Associate Azure ID** button to link the tenant.
+
+## Check license usage in Partner Center analytics
+
+1. Sign in to [Partner Center](https://partner.microsoft.com/).
+1. In the left pane, go to **Commercial Marketplace > Analyze > Licensing**.
+1. Select **Plan and Tenant** in the reporting widget to see the month wise usage.
+
+## See also
+
+[Monetize your app](monetize-overview.md)
platform Monetize Overview https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/concepts/deploy-and-publish/appsource/prepare/monetize-overview.md
You can offer a free trial version of your app to get more customers to try it.
Whether you charge a price for your app or offer it for free, you can use in-app purchases in your app to provide an ongoing revenue stream. Use in-app purchases to let customers upgrade from a free to a paid version of your app. [Use in-app purchases](~/concepts/deploy-and-publish/appsource/prepare/in-app-purchase-flow.md)+ :::column-end::: :::row-end::: :::row:::
With a transactable Software as a Service (SaaS) offer, you can test the end-to-
:::column-end::: :::row-end:::
+ :::column:::
+ :::image type="content" source="../../../../assets/images/apps-in-meetings/test-preview-monetize-app-image.png" alt-text="Manage license for third party apps":::
+ :::column-end:::
+ :::column span="2":::
+
+**Set up Microsoft license management**
+
+If you choose to use Microsoft license management to manage a SaaS license purchased in Teams, you can easily assign, unassign, use, and track SaaS licenses from the Teams store.
+
+[Set up Microsoft license management](manage-third-party-apps-license.md).
++ ## Next step * [Include a SaaS offer with your Microsoft Teams app](~/concepts/deploy-and-publish/appsource/prepare/include-saas-offer.md)
platform Tab Sso Graph Api https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/tabs/how-to/authentication/tab-sso-graph-api.md
If you need to access Microsoft Graph data, configure your server-side code to:
1. Use token cache serialization in MSAL.NET to cache the new access token for multiple, if required. > [!IMPORTANT]
-> As a best practice for security, always use the server-side code to make Microsoft Graph calls, or other calls that require passing an access token. Never return the OBO token to the client to enable the client to make direct calls to Microsoft Graph. This helps protect the token from being intercepted or leaked.
+> * As a best practice for security, always use the [server-side code to make Microsoft Graph calls](/azure/active-directory/develop/v2-oauth2-on-behalf-of-flow#middle-tier-access-token-request) or other calls that require passing an access token. You must not return the OBO token to the client because it enables the client to make direct calls to Microsoft Graph. This helps protect the token from being intercepted or leaked.
+>
+> * DonΓÇÖt use `notifySuccess` result to return the token information to the parent page. Use `localStorage` to save the token and pass the item key via `notifySuccess`.
## Known limitations
platform Add Incoming Webhook https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/webhooks-and-connectors/how-to/add-incoming-webhook.md
You can create and send actionable messages through Incoming Webhook or connecto
[Sample code reference](https://github.com/OfficeDev/Microsoft-Teams-Samples/blob/main/samples/incoming-webhook/csharp/IncomingWebhook/Controllers/CardController.cs#L28) ```csharp
-url = {{Webhook_URL}};
-HttpClient client = new HttpClient();
+var adaptiveCardJson = @"{
+ ""type"": ""message"",
+ ""attachments"": [
+ {
+ ""contentType"": ""application/vnd.microsoft.card.adaptive"",
+ ""content"": {
+ ""type"": ""AdaptiveCard"",
+ ""body"": [
+ {
+ ""type"": ""TextBlock"",
+ ""text"": ""Message Text""
+ }
+ ],
+ ""$schema"": ""http://adaptivecards.io/schemas/adaptive-card.json"",
+ ""version"": ""1.0""
+ }
+ }
+ ]
+}";
+
+var webhookUrl = "https://xxxxx.webhook.office.com/xxxxxxxxx";
+
+var client = new HttpClient();
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
-var content = new StringContent({{formatted_Card_Payload}}(Adaptive_Card_Json), System.Text.Encoding.UTF8, "application/json");
-var response = await client.PostAsync({{WebhookUrl}}, content);
+
+var content = new StringContent(adaptiveCardJson, System.Text.Encoding.UTF8, "application/json");
+var response = await client.PostAsync(webhookUrl, content);
``` # [JavaScript](#tab/javascript)
platform Whats New https://github.com/MicrosoftDocs/msteams-docs/commits/main/msteams-platform/whats-new.md
Teams platform features that are available to all app developers.
**2023 April**
+* ***April 6, 2023***: [Set up Microsoft license management](concepts/deploy-and-publish/appsource/prepare/manage-third-party-apps-license.md)
+ * ***April 4, 2023***: [Tab apps in shared channels are available in DOD](~/concepts/build-and-test/shared-channels.md) :::column-end:::