Implemented diagram API