Makes JS stubs work (still need to fix headers on some APIs).