web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Posting to Teams a ran...
Power Automate
Unanswered

Posting to Teams a randomly selected GIF from document library

(0) ShareShare
ReportReport
Posted on by 40

I would like to include a randomly selected gif to a TEAMS message. The downloaded gifs are currently stored in a Sharepoint document library (but open to suggestions). The resources I have found previously use links to websites but those do not display correctly on my teams message. Thank you for your assistance! 

Categories:
I have the same question (0)
  • Lparadis23 Profile Picture
    40 on at

    In case anyone stumbles on this thread and has similar issue this is how I got it to work using Adaptive Cards. 

     

    Lparadis23_0-1701907416834.png

    *Make sure the gif size is small from the web 

    Lparadis23_1-1701907464752.png

     

    Adaptive Card format- 

     

    {
    "type": "AdaptiveCard",
    "body": [
    {
    "type": "TextBlock",
    "size": "Medium",
    "weight": "Bolder",
    "text": "Happy Birthday <at>@{outputs('Employee_Email')}</at>!",
    "style": "heading",
    "wrap": true
    },
    {
    "type": "TextBlock",
    "text": "@{variables('message')[rand(0, length(variables('message')))]}",
    "wrap": true
    },
    {
    "type": "Image",
    "url": "@{variables('randomgif')[rand(0, length(variables('randomgif')))]}"
    }
    ],
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "version": "1.5"
    }

     

    Which is an animated random gif and saying in teams = 

    Lparadis23_2-1701907712128.png

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 523 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 406 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard