/// <summary> /// Edit the user This method edits the Vimeo account of the authenticated user. /// </summary> /// <exception cref="VimeoOpenApi.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="userId">The ID of the user.</param> /// <param name="inlineObject37"> (optional)</param> /// <returns>Task of User</returns> public async System.Threading.Tasks.Task <User> EditUserAsync(decimal userId, InlineObject37 inlineObject37 = default(InlineObject37)) { VimeoOpenApi.Client.ApiResponse <User> localVarResponse = await EditUserAsyncWithHttpInfo(userId, inlineObject37); return(localVarResponse.Data); }
/// <summary> /// Edit the user This method edits the Vimeo account of the authenticated user. /// </summary> /// <exception cref="VimeoOpenApi.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="userId">The ID of the user.</param> /// <param name="inlineObject37"> (optional)</param> /// <returns>Task of ApiResponse (User)</returns> public async System.Threading.Tasks.Task <VimeoOpenApi.Client.ApiResponse <User> > EditUserAsyncWithHttpInfo(decimal userId, InlineObject37 inlineObject37 = default(InlineObject37)) { VimeoOpenApi.Client.RequestOptions localVarRequestOptions = new VimeoOpenApi.Client.RequestOptions(); String[] _contentTypes = new String[] { "application/vnd.vimeo.user+json" }; // to determine the Accept header String[] _accepts = new String[] { "application/vnd.vimeo.user+json" }; foreach (var _contentType in _contentTypes) { localVarRequestOptions.HeaderParameters.Add("Content-Type", _contentType); } foreach (var _accept in _accepts) { localVarRequestOptions.HeaderParameters.Add("Accept", _accept); } localVarRequestOptions.PathParameters.Add("user_id", VimeoOpenApi.Client.ClientUtils.ParameterToString(userId)); // path parameter localVarRequestOptions.Data = inlineObject37; // authentication (oauth2) required // oauth required if (!String.IsNullOrEmpty(this.Configuration.AccessToken)) { localVarRequestOptions.HeaderParameters.Add("Authorization", "Bearer " + this.Configuration.AccessToken); } // make the HTTP request var localVarResponse = await this.AsynchronousClient.PatchAsync <User>("/users/{user_id}", localVarRequestOptions, this.Configuration); if (this.ExceptionFactory != null) { Exception _exception = this.ExceptionFactory("EditUser", localVarResponse); if (_exception != null) { throw _exception; } } return(localVarResponse); }
/// <summary> /// Edit the user This method edits the Vimeo account of the authenticated user. /// </summary> /// <exception cref="VimeoOpenApi.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="userId">The ID of the user.</param> /// <param name="inlineObject37"> (optional)</param> /// <returns>User</returns> public User EditUser(decimal userId, InlineObject37 inlineObject37 = default(InlineObject37)) { VimeoOpenApi.Client.ApiResponse <User> localVarResponse = EditUserWithHttpInfo(userId, inlineObject37); return(localVarResponse.Data); }