Skip to main content

Wrapper for the airgram api

Project description

A python wrapper for making calls to the Airgram API, which enables you to send push notifications to your mobile devices.

Since it is a very shallow wrapper, you can refer to the official api reference for details on the functions.

Examples

At the time of writing (2015-08-20) airgram is using wrong certificates (see), which are intended for herokuapp.com. Because of this cert verification needs to be turned off.

Using as a guest

from airgram import Airgram

ag = Airgram(verify_certs=False)

# Send a message to a user
ag.send_as_guest("your@email.com", "Test message from Airgram API", "http://example.com")

Using with an authenticated airgram service

from airgram import Airgram

ag = Airgram(key="MY_SERVICE_KEY", secret="MY_SERVICE_SECRET", verify_certs=False)

# Subscribe an email to the service
ag.subscribe("your@email.com")

# Send a message to a subscriber
ag.send("your@email.com", "Hello, how are you?")

# Send a message to ALL subscribers
ag.broadcast("Airgram for python is awesome", url="https://github.com/the01/python-airgram")

History

0.1.1 (2015-08-21)

  • Add module logger

  • Add class logger

  • Functions throw AirgramException on failure

0.1.0 (2015-07-30)

  • First release on PyPI.

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

airgram-0.1.1.tar.gz (3.3 kB view details)

Uploaded Source

File details

Details for the file airgram-0.1.1.tar.gz.

File metadata

  • Download URL: airgram-0.1.1.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for airgram-0.1.1.tar.gz
Algorithm Hash digest
SHA256 d4ca8cedc8ba8d7e81451206495e920a42004ae8065f3ab14d1c0fa534ef1678
MD5 03145883d73d2d741e1db6e1e3c3a8ea
BLAKE2b-256 dae2611bfd5d5be5dfb3600ed24d69d22b44154851305fb3cddbd747fcc6b3e8

See more details on using hashes here.

Supported by

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