public async Task PostStorage(string id, [FromBody] StorageRequestModel model) { var orgIdGuid = new Guid(id); if (!_currentContext.OrganizationOwner(orgIdGuid)) { throw new NotFoundException(); } await _organizationService.AdjustStorageAsync(orgIdGuid, model.StorageGbAdjustment.Value); }
public async Task <PaymentResponseModel> PostStorage(string id, [FromBody] StorageRequestModel model) { var orgIdGuid = new Guid(id); if (!await _currentContext.OrganizationOwner(orgIdGuid)) { throw new NotFoundException(); } var result = await _organizationService.AdjustStorageAsync(orgIdGuid, model.StorageGbAdjustment.Value); return(new PaymentResponseModel { Success = true, PaymentIntentClientSecret = result }); }