Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9212713
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T01:35:16+00:00 2026-06-18T01:35:16+00:00

I am using Requests to communicate with a simple api. The code looks like

  • 0

I am using Requests to communicate with a simple api.

The code looks like this:

payload = {'text': reply, 'name': varname, 'avatar': varavatar}
r = requests.get('http://example.de/create.json', params=payload)

However, the result looks like this:

{"result": "error", "error": "error_no_direct_connection"}

This might be a problem with the api but I’m not sure.
So I printed out the URL that Requests created (print r.url).
It looks like this: http://url.com/create.json?text=Test&name=myname&avatar=http%3A%2F%2Fa0.url.com%2Fnormal.png

To make sure it’s not a problem oft the api I tried it with curl. The command works!

curl --data-urlencode "text=Test" -d "name=myname" -d "avatar=http://url.com/normal.png" http://url.com/create.json
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T01:35:17+00:00Added an answer on June 18, 2026 at 1:35 am

    The curl option --data causes curl to submit a POST request, not a GET request. Try request.post(..., data=...).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How do I send GET requests using the Jersey Client API to a server
I'm creating multiple asynchronous web requests using IObservables and reactive extensions. So this creates
I am trying to create a simple NSURLConnection to communicate with a server using
This seems like a simple question, but I can't find a simple explanation anywhere.
I'm creating a simple drag-file-and-upload-automatically-to-ftp windows application and I'm using the MSDN code to
I'm using requests (as adviced by Daniel Roseman) to post on a webform: url
I'm using Requests to scrape a website. The content of the html gets successfully
I'm using ajax requests to populate modal popup windows with data that users have
I'm making http requests using winsock and I need to parse the response. The
I have asp:GridView displaying client requests using asp:SqlDataSource . I want to limit displayed

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.