Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Making an API post
#3
(Apr-08-2021, 08:09 AM)python_moron Wrote: I have been trying to learn Python formatted as Json.
python formatted as JSON?

(Apr-08-2021, 08:09 AM)python_moron Wrote: Making a simple API request.
There are two possible options - either there is some package/wrapper already available for your particular IoT device(s) (e.g. provided by the manufacturer and/or enthusiasts) or you need to work with native/general package like requests and simply make the post request.
In both cases we can little to help (mostly general advice like use requests), given that we don't have any information on device or the API.

(Apr-08-2021, 08:09 AM)python_moron Wrote: For example I downloaded something called "requests" it was supposed to be a download for making HTTP requests. Then I go to use it and my pycharm doesn't recognize it. I get an error saying that it is for an older version of pycharm.
This indicates that you have trouble installing requests and more importantly - you are confused about how to install packages in general. I don't think the error says that requests is for older version of pycharm. pycharm is IDE and requests does not care what IDE you use. Most likely the error says you downloaded a version for different bersion of python. BUT you don't have to download it, but install it via pip. So let's start form here - provide more information on the error you get (i.e. the full error message/traceback) you get. Also - what OS, what version of python, etc.
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply


Messages In This Thread
Making an API post - by python_moron - Apr-08-2021, 08:09 AM
RE: Making an API post - by kashcode - Apr-08-2021, 08:25 AM
RE: Making an API post - by buran - Apr-08-2021, 08:31 AM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020