/// <summary> /// Get Time Window by Id /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='id'> /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <object> GetTimeWindowByIdAsync(this IFeatureManagementAppTierAPI operations, System.Guid id, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetTimeWindowByIdWithHttpMessagesAsync(id, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
public async Task <IActionResult> Get(Guid id) { if (id == Guid.Empty) { return(BadRequest("Invalid Id")); } using IFeatureManagementAppTierAPI api = CreateFeatureManagementApi(); HttpOperationResponse <object> result = await api.GetTimeWindowByIdWithHttpMessagesAsync(id); return(CreateResponse <TimeWindow>(result)); }