I've often head this and it would probably be in my next-side project. Do you have an AJAX API bundled with D3 or are you using some custom functions ?
You can check the documentations here:
https://github.com/d3/d3/wiki/Requests
Those methods are quite powerful.