public async Task <IHttpActionResult> CopyAsync(string uri, [FromBody] CopyPortalDto model, CancellationToken cancellationToken) { if (model == null || !ModelState.IsValid) { return(BadRequest()); } var portal = await _portalManager.FindByUriAsync(uri, cancellationToken); await ApiSecurity.AuthorizeAsync(portal, AccessPermission.CanEdit, cancellationToken); var validationResult = await _portalManager.CopyAsync(portal, model.Uri, cancellationToken); if (!validationResult.Succeeded) { return(this.ValidationContent(validationResult)); } return(Ok()); }