Skip to main content

Send tweets (with optional images) through the Twitter v2 API (OAuth 2.0) - authentication included

Project description

Tweeter Basic

Send tweets (with optional images) and authenticate through the Twitter v2 API (OAuth 2.0) using Python.

Quick Start

Send a test tweet with the following steps:

  • generate and set the following environment variables:
    • TWITTER_CONSUMER_API_KEY
    • TWITTER_CONSUMER_API_KEY_SECRET
    • TWITTER_ACCESS_TOKEN
    • TWITTER_ACCESS_TOKEN_SECRET
    • TWITTER_CLIENT_ID
    • TWITTER_CLIENT_SECRET
    • TWITTER_CALLBACK_URI <- must end in /callback (ie. http://localhost/callback)
  • authorize the application (1 time only) to generate the seed token.json with the following:
    • build & run the token generation server by executing Authenticate/authenticate.sh
    • navigate with a browser to your http://localhost/auth
  • send a test tweet by executing test/test.sh

Prerequisites

  • Docker engine
  • Twitter project with:
    • v1.1 API read & write access
    • v2 API access

2do

  • create PyPI entry
  • give a more verbose explanation of the steps

future

related projects

resources used

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tweeter-basic-0.1.0.tar.gz (4.9 kB view details)

Uploaded Source

Built Distribution

tweeter_basic-0.1.0-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file tweeter-basic-0.1.0.tar.gz.

File metadata

  • Download URL: tweeter-basic-0.1.0.tar.gz
  • Upload date:
  • Size: 4.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.10

File hashes

Hashes for tweeter-basic-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d0b8ae619e3535ee1a5ef8605cb57aeef3f926c65c5e9f43b4f5ebf48ebb8886
MD5 5a04c0d79e6dabeeee1161bf8045129f
BLAKE2b-256 414c789632365e84bb35630d491a81d8aa7c9fd3f4934cb1d5493d810b9d9bbd

See more details on using hashes here.

File details

Details for the file tweeter_basic-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: tweeter_basic-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.10

File hashes

Hashes for tweeter_basic-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 efce555162ed7c682d2c5388715b3a757854c735b72b04c50410690a0d06ccae
MD5 07d02c44803f6c1d02c3358c07e37303
BLAKE2b-256 325ca02c3242bc3f3d06cacc3814448ad45c2e63e5cded3a5dc3e2032f22793f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page