I followed the official tutorials and made services for the Apis but absolute url of the Api is hardcoded in services.
I want to keep the base url of Api somewhere s
Use the environment files
If youre using the cli you should use the environment files. By configuring the angular-cli.json file you can manage all the available environments and create new ones. For example you could create an environment.dev.js file and store the values there, by making git ignore it any member in your team can have a customized one.
Said environment file will overwrite the original environment.js
See this SO answer angular-cli for angular2 how to load environment variables