I'm not a Unity dev - so I might be wrong. But it's a fairly simple operation with JavaScript so I assume that it should be possible with Unity too. And from a cursory Google search it seems that it is.
Good luck!