Yes, you have to deal with whatever mechanism you decide to use in order to obtain the data you want to put on the diagram. At 10.1, because schematics itself is a server object extension, you simple use REST and call generatediagram. In that call you pass in your xml stream inside the json tag for "xmlSource". Really fairly straight forward and simple.
We don't have any sample code for Flex. There is sample code for both javascript and silverlight. Those should give you the understanding of what you would need to do on the Flex side.