Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

  1. ,
    Expert tip

    Check if you didn't set RequestProperty Content-Type to the wrong type or if you're trying to send the wrong file to the server.

  2. ,

    401 means "Unauthorized", so there must be something with your credentials. You need to pass the authentication to let the server know its a valid user. Check whether the authentication details are provided.

Solutions on the web

via Stack Overflow by celik
, 1 year ago
Server returned HTTP response code: 400 for URL: https://api.example.com/api-token-auth/
via Stack Overflow by ThatGuy343
, 2 years ago
Server returned HTTP response code: 400 for URL: https://www.googleapis.com/urlshortener/v1/url
via GitHub by raghzz
, 1 year ago
Server returned HTTP response code: 400 for URL: https://americas.universal-api.pp.travelport.com/B2BGateway/connect/uAPI/HotelService
via GitHub by raghzz
, 1 year ago
Server returned HTTP response code: 400 for URL: https://americas.universal-api.travelport.com/B2BGateway/connect/uAPI/SystemService
via Stack Overflow by Eddy
, 2 years ago
Server returned HTTP response code: 400 for URL: https://api.parse.com/1/classes/Cars?where={Active:1}
via Stack Overflow by Meriem.ZJ
, 3 months ago
Server returned HTTP response code: 400 for URL: https://www.googleapis.com/customsearch/v1?key=XXXX&cx=013036536707430787589:_pqjad5hr1a&q=the best universities&alt=json&num=10&start=1
java.io.IOException: Server returned HTTP response code: 400 for URL: https://api.example.com/api-token-auth/	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1839)	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1440)	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:254)