GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - sendgrid/python-http-client: Twilio SendGrid's Python HTTP Client for calling APIs

BranchesTags
Open more actions menu

Latest commit

 

History

415 Commits
415 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
examples
examples
 
 
python_http_client
python_http_client
 
 
static/img
static/img
 
 
tests
tests
 
 
.dockerignore
.dockerignore
 
 
.env_sample
.env_sample
 
 
.gitignore
.gitignore
 
 
CHANGELOG.md
CHANGELOG.md
 
 
CODE_OF_CONDUCT.md
CODE_OF_CONDUCT.md
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
Dockerfile
Dockerfile
 
 
FIRST_TIMERS.md
FIRST_TIMERS.md
 
 
LICENSE
LICENSE
 
 
MANIFEST.in
MANIFEST.in
 
 
Makefile
Makefile
 
 
PULL_REQUEST_TEMPLATE.md
PULL_REQUEST_TEMPLATE.md
 
 
README.rst
README.rst
 
 
TROUBLESHOOTING.md
TROUBLESHOOTING.md
 
 
USAGE.md
USAGE.md
 
 
USE_CASES.md
USE_CASES.md
 
 
VERSION.txt
VERSION.txt
 
 
auto_generate_release_notes.sh
auto_generate_release_notes.sh
 
 
cleanup.sh
cleanup.sh
 
 
docker-compose.yml
docker-compose.yml
 
 
requirements.txt
requirements.txt
 
 
run.sh
run.sh
 
 
setup.py
setup.py
 
 
tox.ini
tox.ini
 
 
twilio_sendgrid_logo.png
twilio_sendgrid_logo.png
 
 

Repository files navigation

https://github.com/sendgrid/sendgrid-python/raw/HEAD/twilio_sendgrid_logo.png

Test and Deploy Badge Twitter Follow Codecov branch Code Climate Python Versions PyPI Version GitHub contributors MIT licensed

Quickly and easily access any RESTful or RESTful-like API.

If you are looking for the Twilio SendGrid API client library, please see this repo.

Table of Contents

  • Installation
  • Quick Start
  • Usage
  • How to Contribute
  • Local Setup of the Project
  • Troubleshooting
  • Announcements
  • Thanks
  • About
  • License

Installation

Prerequisites

  • Python version 2.7 or 3.4+

Install Package

pip install python_http_client

or

easy_install python_http_client

API Key

Store your Twilio SendGrid API key in a .env file.

cp .env_sample .env

Edit the .env file and add your API key.

Quick Start

Here is a quick example:

GET /your/api/{param}/call

import python_http_client

global_headers = {"Authorization": "Bearer XXXXXXX"}
client = Client(host='base_url', request_headers=global_headers)
client.your.api._(param).call.get()
print(response.status_code)
print(response.headers)
print(response.body)

POST /your/api/{param}/call with headers, query parameters and a request body with versioning.

import python_http_client

global_headers = {"Authorization": "Bearer XXXXXXX"}
client = Client(host='base_url', request_headers=global_headers)
query_params = {"hello":0, "world":1}
request_headers = {"X-Test": "test"}
data = {"some": 1, "awesome": 2, "data": 3}
response = client.your.api._(param).call.post(request_body=data,
                                              query_params=query_params,
                                              request_headers=request_headers)
print(response.status_code)
print(response.headers)
print(response.body)

Usage

  • Example Code

How to Contribute

We encourage contribution to our projects, please see our CONTRIBUTING guide for details.

Quick links:

  • Improvements to the Codebase
  • Review Pull Requests

Local Setup of the Project

The simplest local development workflow is by using docker.

  1. Install Docker
  2. Run docker-compose build (this builds the container)
  3. Run docker-compose up (this runs tests by default)

Troubleshooting

Please see our troubleshooting guide for any issues.

Announcements

All updates to this project is documented in our CHANGELOG.

Thanks

We were inspired by the work done on birdy and universalclient.

About

python-http-client is maintained and funded by Twilio SendGrid, Inc. The names and logos for python-http-client are trademarks of Twilio SendGrid, Inc.

License

The MIT License (MIT)

About

Twilio SendGrid's Python HTTP Client for calling APIs

sendgrid.com

Resources

Readme
MIT license

Code of conduct

Code of conduct

Contributing

Contributing
Activity
Custom properties

Stars

126 stars

Watchers

155 watching

Forks

103 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.