converted services.js to funcjs arch