Skip to content

Commit

Permalink
Specify avatar_url per MSC2765
Browse files Browse the repository at this point in the history
  • Loading branch information
turt2live committed Nov 23, 2020
1 parent cdd48e2 commit 4b6bf32
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 9 additions & 0 deletions api/widgets/definitions/shared_props.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,15 @@ properties:
from view until the ``content_loaded`` API action is sent by the widget. Defaults to
true.
example: true
avatar_url:
type: string
description: |-
An optional MXC URI to an image which can be used to identify the widget. Recommended
for use alongside the ``name`` and ``data.title``.
Images SHOULD be legible at small sizes, such as 20x20 pixels. The MXC URI here should
be the source material to allow clients to use the ``/thumbnail`` endpoint on the media.
example: "mxc://example.org/aaabbbccc"
data:
type: object
title: WidgetData
Expand Down
3 changes: 2 additions & 1 deletion api/widgets/examples/shared_props.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@
"name": "My Cool Widget",
"type": "m.custom",
"url": "https://example.org/my/widget.html?roomId=$matrix_room_id",
"waitForIframeLoad": true
"waitForIframeLoad": true,
"avatar_url": "mxc://example.org/aaabbbccc"
}

0 comments on commit 4b6bf32

Please sign in to comment.