MicrosoftDocs / msteams-docs

Source for the Microsoft Teams developer platform documentation.

Home Page:https://aka.ms/teamsdev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Emoji no longer work in Webhook or Graph API

GitWatin opened this issue · comments

Steps to reproduce

Hello,

I'm using Powershell to update my teams status message via Microsoft Graph and command Set-MgUserPresenceStatusMessage

I would like to send emoji in my message and I noticed that emoji character with unicode after 1FXX doesn't work

For exemple with code ▶ it's work

image

And with code 🏠 (reffering to the house) it doesn't work

image

Anyone have the same issue ?

$Test = "🏠"

Function CreateTeamsObject {
	Param (
		[string]$message
	)
	$DayDate=Get-Date -Format "yyyy-MM-dd" | Out-String
	$EndDay="T23:59:00"
	$EndOfDay=$DayDate+$EndDay
	$params = @{
		statusMessage = @{
			message        = @{
				content     = $message
				contentType = "text"
			}
			expiryDateTime = @{
				dateTime = $EndOfDay
				timeZone = "Europe/Paris"
			}
		}
	}
	Set-MgUserPresenceStatusMessage -UserId $userId -BodyParameter $params


CreateTeamsObject -message "I am currently at Home $test  <pinnednote></pinnednote>"

Expected behavior

Image displayed as pictures, not code

Actual behavior

Emoji are displayed as number, not picture

Error details

No response

Hello @GitWatin - Thanks for raising your query.
Could you please conform if it was working previously because it may not be supported?

It is also working with other codes?

Hello @ChetanSharma-msft

Yes it work in the past. I found some topics on StackOverFlow regarding this issues.
Seems to be since 2 or 3 Teams release version.

I don't try with other code.

Regarding the emoji, I use this list : https://www.unicode.org/emoji/charts/full-emoji-list.html

Hi @GitWatin - We tried to repro this issue by sending message having unicode emoji and observed that, emoji character with unicode after 1FXX doesn't work.

For example, emoji with unicode U+2764 works.

{
  "type": "message",
  "attachments": [
    {
      "contentType": "application/vnd.microsoft.card.adaptive",
      "contentUrl": null,
      "content": {
        "type": "AdaptiveCard",
        "$schema": "[http://adaptivecards.io/schemas/adaptive-card.json"](http://adaptivecards.io/schemas/adaptive-card.json%22),
        "version": "1.4",
        "body": [
          {
            "type": "TextBlock",
            "wrap": true,
            "text": "Emoji tester: &#x2764;"
          }
        ]
      }
    }
  ]
}

image

However, emoji with unicode U+1F3E0 doesn't work.

{
  "type": "message",
  "attachments": [
    {
      "contentType": "application/vnd.microsoft.card.adaptive",
      "contentUrl": null,
      "content": {
        "type": "AdaptiveCard",
        "$schema": "[http://adaptivecards.io/schemas/adaptive-card.json"](http://adaptivecards.io/schemas/adaptive-card.json%22),
        "version": "1.4",
        "body": [
          {
            "type": "TextBlock",
            "wrap": true,
            "text": "Emoji tester: &#x1F3E0;"
          }
        ]
      }
    }
  ]
}

image

Checked with Microsoft Teams version 24116.2502.2841.3203.
The client version is 49/24050218100.

In Mobile devices (Android):
image

Hey @Prasad-MSFT

It's exactly the issues I encounter, not via webhook but microsoft graph but I assume it's the same "bug"

Thanks a lot for your help

There is my Teams version :
image

@GitWatin - We have raised a bug for the same and assigned to engineering team We will inform you once we get any further update from engineering team.

Thanks!