Deriving Structure Metadata from API Widget

  • 9 June 2020
  • 7 replies

If i use the API to query a widget on a Kanban board, I get an X and Y co-ordinate, but I don’t seem to see any reference to the structure of the board itself eg Swimlane/Bucket name or indeed the fact that the widget is contained within a particular swimlane/column.

Am I missing something.  Is there some API call that allows me to further discover the structure and relationship between widgets?


Best answer by Ahmed El Gabri 13 July 2020, 16:49

View original

7 replies

Hi @Gerald Dunn,


You are right, the API doesn’t expose any relationship information right now. We are aware of this & might change this in the future.

May I ask what is your use case for this?



Hi Ahmed,


We want to use changes in the miro cards to drive changes in our task database (Dynamics).  I have a call into Miro support to explore development on this, but if you have any comments they would be very welcome.

Userlevel 2
Badge +2

@Ahmed El Gabri, there are a lot of automation tasks that can benefit from knowing some concept of containment of objects.  We would really like to be able to do Agile PI planning directly in Miro where we could drag stories between sprints and have the backing data get updated.  This is something that one of your competitors (Stormboard) does really well.  We almost went with them instead of Miro.

Userlevel 7
Badge +5

If you take the approach of a web plugin via Miro SDK - you will be able to access all the information and events (*I believe) you’d need to write the logic and flow to accomplish this. 

  • Event: Widget moved over another widget:  Event-Listener: WIDGETS_TRANSFORMATION_UPDATED
  • Property: Widget bounds, x, y, width, height
  • Property / structure: What widgets are lines connected to? (not sure you need this): line start widget ID, end widget ID

At this point, to my knowledge, you’d have to implement the ‘is object A within the bounds of object B’ test from the ground up (like, is card #3 in swimlane A or B, or list all cards in swimlane A). 

It would be great if Miro produced a method for testing ‘is widget A within the bounds of widget B’. Otherwise its not a rocket science helper function to build from ground up on our own.  Also a related method, ‘is object a overlapping any objects’


There is an ‘experimental feature’ method listed in the typings file with no documentation called “__getIntersectedObjects()     I thought for a while that this was ‘get all the widgets within the bounds of object B’.   --- but my experiments with it failed to produce anything understandable…I’m not sure its working properly - or if i’m using it incorrectly. 

	 * Requires scope: BOARDS:READ
* [Experimental feature] Find all widgets intersected with passed area
__getIntersectedObjects(pointOrRect: IPoint | IRect): Promise<IWidget[]>


I’m looking for this information as well, for a slightly different use case.

We like to use Kanban boards to track work on a particular project. Our executives like to see dashboards of this progress. I’m pulling the object data across but I really want to be able to see what tasks are in what column and which row to be able to effectively build a (python) data viz out of the board data.

Has the Miro team given this any more thought?

Userlevel 1

Same as @Chris Saunders . We love the Kanban feature! But it would be so much easier/reliable to get an info of a card’s parent column via API, instead of messing with things like x and y coordinates (this is so prone to error).


bump <3