Would there be a difference in using the 'older' SharePoint ClientContext/CSOM based API against a site in SharePoint Online versus one that is a part of a Team?
I have a bit of code that works just fine when talking to a general SPO site.
using (var cc = new AuthenticationManager().GetACSAppOnlyContext(instance.url, instance.apiKey, instance.apiSecret))
{
Web web = cc.Web;
var spTimezone = web.RegionalSettings.TimeZone;
List eventsList = web.Lists.GetByTitle(instance.calendarTitle);
CamlQuery query = CamlQuery.CreateAllItemsQuery();
var list = web.Lists;
ListItemCollection eventsItems = eventsList.GetItems(query);
cc.Load(eventsItems);
cc.ExecuteQuery();
Logger.Info("Found " + eventsItems.Count + " items in " + instance.name);
}
But, if I run this against a site I am working on now, I get nozero results. The API knowsIf I run against several sites I developed this code against (not tied to a Team) it works as expected and returns me a collection of list items.
I feel that my auth is working, as if I spell the Calendar TitleCalendarTitle wrong, but if it is right, I still get zero results. There arean exception that List does not exist at least 3 items in this calendarURL.
I also can not seem to be able to see a list of all lists in the site, etc.
Is this due to a difference in this particular site? Why would I not be able to get any results, when it works fine on all of my other, non-Teams based sites?