Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
1 answer
957 views

SSL Error while setting connection through rest-client

I am developing a JAVA 1.8v RestClient which is supposed to call a Rest API exposed by a external application. Below is snippet of my code for reference: import java.io.BufferedReader; import java.io....
Godfather's user avatar
-1 votes
1 answer
385 views

Send RestClient through Function Azure VS Code

I am trying to make a post request with c# through the Azure HttpTrigger function. Only that when executing it sends me thousands of errors. Can someone help me here? This is my code: using System; ...
Martin Vargas's user avatar
1 vote
1 answer
40 views

Express POST fails to recognize Strings

ok, I'm trying to build my first REST API, and have the schema set up, and try to use the rest client in VS Code to test it. Some how all the string input in my json body are not recognized instead ...
Jane's user avatar
  • 25
1 vote
1 answer
1k views

How to pass Xml file using RestClient in Post - C#?

I'm trying to pass xml file to api using RestSharp, but I'm receiving the file at the Post method as null. Here is my code: public void SendXmlToApi() { var client = new RestClient(_uri); ...
user's user avatar
  • 136
0 votes
0 answers
383 views

Ruby POST multipart/form-data results in 302 Found

I am trying to upload a csv file to my endpoint. I tried doing this and resulting in 302 Found. Tried other solution mentioned here: Multipart POST Ruby HTTPS but same results. First option using net/...
Esh Val's user avatar
0 votes
1 answer
825 views

Converting RestSharp Reqest AddParameter to JavaScript data for POST requests

Would anyone know what is the equivalent of RestSharp: request.AddParameter("text/plain", body, ParameterType.RequestBody); in Javascript? That is the only part I am missing. Here is working code ...
lucas's user avatar
  • 4,675
0 votes
1 answer
458 views

UnKnowHost Exception while consuming a web service

I am trying to consume a web service and do a POST on that api. I have tried with the postman and all works well. But, as soon as I have written a java client to consume that web service I am getting ...
Rohitesh's user avatar
  • 1,614
5 votes
3 answers
9k views

Create JAX-RS Client Post Request with JSON String as Body

I am writing a REST Client for one of the Vendor REST Service. I use jersey 2.x and JSON-P, below are dependencies I add. <dependencies> <dependency> <groupId>org.glassfish....
K Raghu's user avatar
  • 113
0 votes
1 answer
52 views

How to get webpage body using ruby after passing form data

Basically to get the body of webpage i used to do this. require "rest-client" url="example.com" test=RestClient.get(url) But now the webpage has setup an authentication step. On entering the correct ...
Rishav's user avatar
  • 4,038
0 votes
1 answer
115 views

Ruby Rest-Client for writing invoice API

I'm new to Ruby and trying to use the Ruby gem 'rest-client' to access the REST API of my accounting system, e-conomic.com. I am able to connect via tokens and e.g. fetch customer details - so far, so ...
Martin's user avatar
  • 149
1 vote
1 answer
244 views

Rails POST request to Practice Fusion API

I'm working with the Practice Fusion API to receive pending orders. I'm trying to write a POST request to acknowledge the downloaded orders that were received during the GET request. Once Practice ...
bradbajuz's user avatar
  • 185
2 votes
1 answer
4k views

Pass parameters in RestClient post request

I want to send parameters with a POST request using the RestClient gem (but I don't want to pass the params as JSON). In a GET request, I would have: url = "http://example.com?param1=foo&param2=...
Graham Slick's user avatar
  • 6,860
5 votes
1 answer
10k views

POST request to HTTPS using Net::HTTP

This POST request using Ajax works perfectly: var token = "my_token"; function sendTextMessage(sender, text) { $.post('https://graph.facebook.com/v2.6/me/messages?', { recipient: {id: sender}, ...
Graham Slick's user avatar
  • 6,860
0 votes
1 answer
260 views

Unable to Authenticate Ionic push [closed]

I try to send a request with RestClient to https://push.ionic.io/api/v1/push. I'm following all the instructions said http://docs.ionic.io/docs/push-api-examples. I change my private key to base64 ...
Nocide's user avatar
  • 1
-1 votes
1 answer
588 views

How do I use RestClient to post as URL params?

I am posting to an API which accepts CURL as follows: curl -v -X POST "https://url.com" -d 'input=frustrated&user_key=3b9ccb48e734fce6b982a9c1c2cef301' I have tried the following with an error: ...
Satchel's user avatar
  • 16.7k
1 vote
3 answers
3k views

Rest-client POST without a payload

I am trying to POST using Rest-Client gem in Ruby, and I keep getting a return from the web service as Error 414 Unsupported Media Type, because I am setting the payload argument as '' Example ...
user3486868's user avatar
0 votes
1 answer
49 views

POST request delete + symball

I have this code httpUriRequest = new HttpPost(address.toString()); ((HttpPost)httpUriRequest).setEntity(new ByteArrayEntity(restParams.postData())); httpUriRequest.setHeader("Content-Type", "...
Hayk Nahapetyan's user avatar
2 votes
2 answers
5k views

Trying to do post or put using RestClient; getting 422 error

I'm trying to write a small rake task / test script for a rails RESTful API. I'm using the rest-client gem. According to the doumentation the following should work (with app.domain obviously changed)...
hershey's user avatar
  • 475
1 vote
1 answer
1k views

Grails: POST method for JIRA basic auth - Unsupported Media Type

I am developing an application that extracts data from a JIRA database. I am using RESTClient API to do basic authentication using post method. Full code (redacted): class IssuesController { ...
Anchit Agarwal's user avatar
0 votes
0 answers
186 views

RestClient.put error in Ruby

I am trying to do a RestClient.put in Ruby for a highchart graphic but I see that this is not replicated. Also first I have a RestClient.post and works fine but the problem is then with the put. At ...
user2668530's user avatar
3 votes
1 answer
4k views

sending a post request to Rest Client in firefox

i am using Rest Client add on in firefox web browser.I want to test a web service that processes a HTTP POST request and consumes json.How do i test it using Rest Client? If i put a json in the ...
user1946152's user avatar
0 votes
2 answers
276 views

How to post body in sitebricks-client?

I am using sitebricks-client to interact with REST APIs in Java. I need to do a POST with a non-empty body. How do I do that in sitebricks?
pathikrit's user avatar
  • 33.3k
13 votes
4 answers
22k views

Ruby rest-client file upload as multipart form data with basic authenticaion

I understand how to make an http request using basic authentication with Ruby's rest-client response = RestClient::Request.new(:method => :get, :url => @base_url + path, :user => @sid, :...
Robin's user avatar
  • 686
1 vote
1 answer
3k views

How to POST binary data using Rest Client?

I am trying to read in an audio file of type wav or amr from a HTML form using Rest Client. I have the code to do this in PHP. $filename = $_FILES['f1']['name']; public function getFile($filename) { ...
user1455140's user avatar
1 vote
1 answer
1k views

RestClient Upload to Amazon fails with InvalidArgument error

I'm trying to upload an image via POST request to amazon: begin RestClient.post('http://public.domain.com/', { :transfer => { ...
Igor's user avatar
  • 2,899
1 vote
1 answer
2k views

getting internal server error using rest-client in ruby to post to HTTP POST

this is my code and I don't know how to debug it because I just get an "internal server error": I am trying to HTTP POST to an external ASPX: def upload uri = 'https://api.postalmethods.com/...
Satchel's user avatar
  • 16.7k