public async Task <enrichmentItem?> AddEnrichmentToAlbumAsync(string albumId, NewEnrichmentItem newEnrichmentItem, AlbumPosition albumPosition) { var tpl = await PostJson <AddEnrichmentResponse, Error>(string.Format(RequestUris.POST_albums_addEnrichment, albumId), new AddEnrichmentRequest(newEnrichmentItem, albumPosition)); if (tpl.error is object) { throw new GooglePhotosException(tpl.error); } return(tpl.result is object && tpl.result.enrichmentItem is object?tpl.result.enrichmentItem : null); }
public AddEnrichmentRequest(NewEnrichmentItem newEnrichmentItem, AlbumPosition albumPosition) { this.newEnrichmentItem = newEnrichmentItem; this.albumPosition = albumPosition; }