Cannot send video in Teams Channel w Bot Framework API

Gerwin van der Lugt 5 Reputation points
2025-08-08T12:35:31.37+00:00

Hi,

I’m trying to push a video into a Teams channel (public channel, not a private channel) with the Bot Framework REST API. I tried two ways and both look broken.

First Method: plain attachment

I base-64 the mp4 and send it as a normal attachment:

curl -X POST \
  -H "Authorization: Bearer <YOUR_BEARER_TOKEN>" \
  -H "Content-Type: application/json" \
  https://smba.trafficmanager.net/teams/v3/conversations/CONVERSATION_ID/activities \
  -d '{
    "type": "message",
    "text": "Inline video test",
    "attachments": [
      {
        "name": "demo.mp4",
        "contentType": "video/mp4",
        "contentUrl": "data:video/mp4;base64,<BASE64_BYTES>"
      }
    ]
  }'

Result in the web client:

<URIObject type="Video.1/Message.1" uri="https://eu-prod.asyncgw ...">
  Video - view it at https://login.skype.com/login/sso?go=webclient.xmm&vim=...
</URIObject>

Desktop shows that XML blob. Mobile just shows a dead link.

Second Method: VideoCard

I switch to a VideoCard instead:

curl -X POST \
  -H "Authorization: Bearer <YOUR_BEARER_TOKEN>" \
  -H "Content-Type: application/json" \
  https://smba.trafficmanager.net/teams/v3/conversations/CONVERSATION_ID/activities \
  -d '{
    "type": "message",
    "text": "Video card test",
    "attachments": [
      {
        "contentType": "application/vnd.microsoft.card.video",
        "content": {
          "aspect": "16:9",
          "autoloop": true,
          "autostart": false,
          "title": "Demo video",
          "subtitle": "Just a test",
          "text": "Some text",
          "media": [
            { "url": "https://www.example.com/video.mp4" }
          ]
        }
      }
    ]
  }'

On the web client I get “Card - access it on https://go.skype.com/cards.unsupported”. On mobile the message is empty.

So neither way shows an actual playable video. What is the right trick to make a video show and play inside a Teams message?

Thanks.

Microsoft Teams | Development
{count} votes

1 answer

Sort by: Most helpful
  1. Kudos-Ng 2,885 Reputation points Microsoft External Staff Moderator
    2025-08-08T14:25:35.95+00:00

    Hi Gerwin van der Lugt

    Thank you for posting your question in the Microsoft Q&A forum. 

    I understand you're trying to send a video as a message in a public Teams channel using the Bot Framework REST API, but you're running into issues where the video doesn't appear as a playable media element. It seems you're exploring whether there's a reliable way to embed a playable video directly in the message. 

    I've done some research on this topic and would like to share a few insights that might help. 

    First, while there's no official Microsoft documentation confirming that VideoCard is unsupported in Teams channel messages, based on your experience and discussions across developer forums, it appears that VideoCard is currently not supported in Teams channel chat. This could explain why you're seeing fallback messages or empty content in both web and mobile clients. 

    Additionally, according to Limits and specifications for Microsoft Teams - Microsoft Teams | Microsoft Learn, the channel conversation post size is approximately 40 KB per post. This includes the message text, media links, mentions, reactions, etc. If your media exceeds this limit, it may not render properly or could be rejected. 

    However, I found a few workaround approaches that might be worth exploring. These involve using Adaptive Cards to create a custom video experience: 

    Note: These resources are provided for your convenience. They are not controlled by Microsoft, and Microsoft cannot guarantee the quality, safety, or suitability of the content. Please make sure you fully understand the risks before implementing any suggestions from these sources. 

    I hope this information is helpful to you. If you have any further questions or updates, feel free to get back. 

    Please understand that our initial reply may not always immediately resolve the issue. However, with your help and more detailed information, we can work together to find a solution. 


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".      

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.