I am looking for a tool where user can log in to arcgis online and be able to add his/her private services and layers to the base map. Is such a tool available in ArcGIS JS api?
If the user is logging in to AGOL, is there any reason they couldn't use the built in tools to add data to the basemap? AGOL is built for users being able to add their own services.
if you are wanting to control this in a custom way, you may want to lol at using the developers editing o the
Wbe AppBuilder. There is a custom widget that can help either add a shape, or add a service. I have not tried either yet, but you can find this and other community custom widgets list in Web AppBuilder Developer Edition - Resource List (updated 5/13/2018)
Thanks for your reply. I have used the Add a Shapefile tool and it is great. I am actually building a web app, in which I want to give user an option of logging in to their agol account and select services and layers from there to display on the basemap. Kind of like a "Local Layer Widget" tool but more interactive in the sense that user can add layers while using the app though their arcgis online account.
Retrieving data ...