I'm trying to access multiple client contexts (not at the same time) of different lists. Each list is hosted on a separate site collection than the rest, and I need the context in order to access its host web, the list itself, and subsequently the list items. Basically, the add-in will pull in list data from different sites and aggregate into a single view.
Technically, I'm able to get a context by using the web URL of a particular list. But the user isn't being authenticated outside of this add-in and that's where the problems start. I'm getting access errors due to this.
Is there some kind of access token or a way to transfer the current user's credentials while I'm generating the contexts?
Edit: Also this add-in has permissions to read the whole site collection. It's installed at the root site collection and the lists are all in the subsite collections of the root. I'm confused why that alone isn't giving me read access to those lists?