Skip to main content

Gotipy

A simple Python wrapper for Gotify

Requirements

Installation

pip install gotipy

Usage

from gotipy import Gotify

g = Gotify(host_address='https://yourdomain.com')

Create a new application

g.create_app(admin_username='admin',
             admin_password='admin',
             app_name='demo',
             desc='My first app!')
# {
#     'id': 1,
#     'token': 'xxxxxxxxxx',
#     'name': 'demo',
#     'description': 'My first app!',
#     'internal': False,
#     'image': 'static/defaultapp.png'
# }

Push messages to an application

g.push(title='My message',
       message='Hello, World!',
       priority=9,
       token='xxxxxxxxxx')
# {
#     'id': 1,
#     'appid': 1,
#     'message': 'Hello, World!',
#     'title': 'My message',
#     'priority': 9,
#     'date': '2022-05-16T05:25:29.367216435Z'
# }

Notes:

  • You can set GOTIFY_HOST_ADDRESS as an envionmnt variable instead of passing host_address to the class instance.
  • If you want to use the same app in all your push calls, you can omit token from the method, and pass fixed_token=... to the class instance or set GOTIFY_APP_TOKEN as an envionmnt variable instead.
  • If you want to set a fixed priority level for all your push calls, pass fixed_priority to the class instance.

Release files for gotipy 0.2.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gotipy 0.2.2
File Size Uploaded
gotipy-0.2.2.tar.gz 3.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for gotipy 0.2.2
File Interpreter ABI Platform
gotipy-0.2.2-py3-none-any.whl Python 3 none any Details

Total release size:7.5 kB

Release files / gotipy-0.2.2.tar.gz

Download URL gotipy-0.2.2.tar.gz
Size 3.7 kB
Tags Source
SHA-256 checksum
How to use checksums
a4bdf4db0892689044d82fa5136d0af58ead469c1ec4dd6eb75a65df247d35d3
BLAKE2b-256 checksum
How to use checksums
4198c0f980963fad84ebfb36cbfd8fdb97205359f7be459fdc16e4c8ac2cca9b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.14 CPython/3.10.5 Darwin/21.6.0

Release files / gotipy-0.2.2-py3-none-any.whl

Download URL gotipy-0.2.2-py3-none-any.whl
Size 3.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d482ca52300dcf4a55c87c85f4ff8a4eb037ab47a581ad3f731132d1ba3ab93f
BLAKE2b-256 checksum
How to use checksums
cd1da032115f42e54c12bb76a81425b79ef7ae3cda2f4b95b5974776312f5457
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.14 CPython/3.10.5 Darwin/21.6.0

Release history Release notifications | RSS feed

This release

0.2.2 This release

2 release files

0.2.1

2 release files

0.2

2 release files

0.1.1

1 release file

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page