public string Post(string path, string jsonPayload, string sessionId) { support.LogRequest("POST", path, jsonPayload); headerGen = new SessionIdAuthHeaderGenerator(sessionId); byte[] payloadBytes = null; if (jsonPayload != null) { payloadBytes = Converter.ToBytes(jsonPayload); } else { payloadBytes = new byte[0]; } if (proxyConfiguration != null) { HttpMethods.proxyConfiguration = proxyConfiguration; } byte[] responseBytes = HttpMethods.PostHttp(headerGen, path, payloadBytes, additionalHeaders); String response = Converter.ToString(responseBytes); support.LogResponse(response); return(response); }
public string PostMultipartPackage(string path, byte[] content, string boundary, string json) { support.LogRequest("POST", path, json); headerGen = new ApiTokenAuthHeaderGenerator(apiToken); byte[] responseBytes = HttpMethods.MultipartPostHttp(apiToken, path, content, boundary, headerGen); string response = Converter.ToString(responseBytes); support.LogResponse(response); return response; }
public string PostMultipartFile(string path, byte[] fileBytes, string boundary, string sessionId, string json) { support.LogRequest("POST", path, json); headerGen = new SessionIdAuthHeaderGenerator(sessionId); byte[] responseBytes = HttpMethods.MultipartPostHttp(apiToken, path, fileBytes, boundary, headerGen); string response = Converter.ToString(responseBytes); support.LogResponse(response); return response; }
public string PostMultipartPackage(string path, byte[] content, string boundary, string json) { support.LogRequest("POST", path, json); headerGen = new ApiTokenAuthHeaderGenerator(apiToken); byte[] responseBytes = HttpMethods.MultipartPostHttp(apiToken, path, content, boundary, headerGen); string response = Converter.ToString(responseBytes); support.LogResponse(response); return(response); }
public string PostMultipartFile(string path, byte[] fileBytes, string boundary, string sessionId, string json) { support.LogRequest("POST", path, json); headerGen = new SessionIdAuthHeaderGenerator(sessionId); byte[] responseBytes = HttpMethods.MultipartPostHttp(apiToken, path, fileBytes, boundary, headerGen); string response = Converter.ToString(responseBytes); support.LogResponse(response); return(response); }
public string PostMultipartPackage(string path, byte[] content, string boundary, string json) { support.LogRequest("POST", path, json); headerGen = new ApiTokenAuthHeaderGenerator(apiToken); if (proxyConfiguration != null) { HttpMethods.proxyConfiguration = proxyConfiguration; } string response = HttpMethods.MultipartPostHttp(apiToken, path, content, boundary, headerGen, additionalHeaders); support.LogResponse(response); return(response); }
public string PostMultipartFile(string path, byte[] fileBytes, string boundary, string sessionId, string json) { support.LogRequest("POST", path, json); headerGen = new SessionIdAuthHeaderGenerator(sessionId); if (proxyConfiguration != null) { HttpMethods.proxyConfiguration = proxyConfiguration; } string response = HttpMethods.MultipartPostHttp(apiToken, path, fileBytes, boundary, headerGen, additionalHeaders); support.LogResponse(response); return(response); }
public string PostMultipartFile(string path, byte[] fileBytes, string boundary, string json) { support.LogRequest("POST", path, json); headerGen = new ApiTokenAuthHeaderGenerator(apiToken); if (proxyConfiguration != null) { HttpMethods.proxyConfiguration = proxyConfiguration; } byte[] responseBytes = HttpMethods.MultipartPostHttp(apiToken, path, fileBytes, boundary, headerGen); string response = Converter.ToString(responseBytes); support.LogResponse(response); return(response); }