/// <summary> /// Sends an Password reset mail to the given MailAddress. Sends an Password reset mail to the given MailAddress /// </summary> /// <exception cref="Com.Madana.APIClient.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="body">- the MaiAddress under which the user has signed up (optional)</param> /// <param name="cancellationToken">Cancellation Token to cancel request (optional) </param> /// <returns>Task of ApiResponse (System.IO.Stream)</returns> public async System.Threading.Tasks.Task <ApiResponse <System.IO.Stream> > CreatePasswordResetWithHttpInfoAsync(JsonMDNMailAddress body = default(JsonMDNMailAddress), CancellationToken cancellationToken = default(CancellationToken)) { var localVarPath = "/account/password"; var localVarPathParams = new Dictionary <String, String>(); var localVarQueryParams = new List <KeyValuePair <String, String> >(); var localVarHeaderParams = new Dictionary <String, String>(this.Configuration.DefaultHeader); var localVarFormParams = new Dictionary <String, String>(); var localVarFileParams = new Dictionary <String, FileParameter>(); Object localVarPostBody = null; // to determine the Content-Type header String[] localVarHttpContentTypes = new String[] { "application/json" }; String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes); // to determine the Accept header String[] localVarHttpHeaderAccepts = new String[] { "application/json", "application/xml" }; String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts); if (localVarHttpHeaderAccept != null) { localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept); } if (body != null && body.GetType() != typeof(byte[])) { localVarPostBody = this.Configuration.ApiClient.Serialize(body); // http body (model) parameter } else { localVarPostBody = body; // byte array } // make the HTTP request IRestResponse localVarResponse = (IRestResponse)await this.Configuration.ApiClient.CallApiAsync(localVarPath, Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams, localVarPathParams, localVarHttpContentType, cancellationToken); int localVarStatusCode = (int)localVarResponse.StatusCode; if (ExceptionFactory != null) { Exception exception = ExceptionFactory("CreatePasswordReset", localVarResponse); if (exception != null) { throw exception; } } return(new ApiResponse <System.IO.Stream>(localVarStatusCode, localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)), (System.IO.Stream) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(System.IO.Stream)))); }
/// <summary> /// Sends an Password reset mail to the given MailAddress. Sends an Password reset mail to the given MailAddress /// </summary> /// <exception cref="Com.Madana.APIClient.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="body">- the MaiAddress under which the user has signed up (optional)</param> /// <returns>System.IO.Stream</returns> public System.IO.Stream CreatePasswordReset(JsonMDNMailAddress body = default(JsonMDNMailAddress)) { ApiResponse <System.IO.Stream> localVarResponse = CreatePasswordResetWithHttpInfo(body); return(localVarResponse.Data); }
/// <summary> /// Sends an Password reset mail to the given MailAddress. Sends an Password reset mail to the given MailAddress /// </summary> /// <exception cref="Com.Madana.APIClient.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="body">- the MaiAddress under which the user has signed up (optional)</param> /// <param name="cancellationToken">Cancellation Token to cancel request (optional) </param> /// <returns>Task of System.IO.Stream</returns> public async System.Threading.Tasks.Task <System.IO.Stream> CreatePasswordResetAsync(JsonMDNMailAddress body = default(JsonMDNMailAddress), CancellationToken cancellationToken = default(CancellationToken)) { ApiResponse <System.IO.Stream> localVarResponse = await CreatePasswordResetWithHttpInfoAsync(body, cancellationToken); return(localVarResponse.Data); }
/// <summary> /// Sends an Password reset mail to the given MailAddress. Sends an Password reset mail to the given MailAddress /// </summary> /// <exception cref="Com.MadanaSampleclient.Client.ApiException">Thrown when fails to make API call</exception> /// <param name="body">- the MaiAddress under which the user has signed up (optional)</param> /// <returns>Task of System.IO.Stream</returns> public async System.Threading.Tasks.Task <System.IO.Stream> CreateObjectAsync(JsonMDNMailAddress body = default(JsonMDNMailAddress)) { ApiResponse <System.IO.Stream> localVarResponse = await CreateObjectAsyncWithHttpInfo(body); return(localVarResponse.Data); }