Note that the Diagram widget is in the community technology preview (CTP) development stage.
This demo shows the Diagram widget loading data from a Web API service.