Skip to content

Latest commit

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

Send POST Requests in Python

simple python code to send http POST requests to an API endpoint.

How it works:

Upon calling python3 main.py:

  1. constructs a dictionary for the data payload.
  2. converts dictionary into a JSON object[1].
  3. sends the payload to the specified API via POST request, using the python requests package[2].
  4. prints out the result of the POST request.

Futher readings:

[1] Python JSON encoder and decoder documentation

[2] Python Requests - Quickstart

About

simple python code to send http POST requests.

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages