public async Task Post([FromBody] GraphQuery value, [FromQuery] string collectionId) { if (string.IsNullOrEmpty(value.Id)) { value.Id = Guid.NewGuid().ToString(); } var queries = await queryRepo.GetItemAsync(collectionId); if (queries == null) { queries = new List <GraphQuery>(); } queries.Add(value); await queryRepo.CreateOrUpdateItemAsync(queries, collectionId); }
public async Task Post([FromBody] GraphSettings value, [FromUri] string collectionId) { await settingsRepo.CreateOrUpdateItemAsync(value, collectionId); }