Skip to main content

A Python wrapper around the ntfy API.

Install

$ pip install ntfy-api

Usage

This package is in its early stages, and currently only supports sending messages:

from ntfy_api import *


# create NtfyPublisher instance
ntfy_pub = NtfyPublisher("https://ntfy.example.com", basic=..., bearer=...)

# create message
msg = Message(
    topic="my-topic",
    message="**Hello World**",
    title="Super Cool Message",
    priority=Priority.urgent, # or just `5`
    tags=[Tag._100], # or just `["100"]`
    markdown=True,
    delay="10m",
    actions=[
        ViewAction(label="GOOGLE", url="https://google.com"),
        BroadcastAction(
            label="Take picture",
            extras={"cmd": "pic", "camera": "front"}
        )
    ],
    click="https://youtube.com",
    attach="https://docs.ntfy.sh/static/img/ntfy.png",
    filename="ntfy.png",
    icon="https://ntfy.sh/_next/static/media/logo.077f6a13.svg"
)

# send message
ntfy_pub.publish(msg)

# OR

ntfy_pub << msg

Metadata

Release files for ntfy-api 0.0.6

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

Source distribution (sdist)

Source distribution for ntfy-api 0.0.6
File Size Uploaded Provenance Actions
ntfy_api-0.0.6.tar.gz 28.2 kB Without provenance Details for ntfy_api-0.0.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ntfy-api 0.0.6
File Interpreter ABI Platform Actions
ntfy_api-0.0.6-py3-none-any.whl Python 3 none any Details for ntfy_api-0.0.6-py3-none-any.whl

Total release size: 56.3 kB

Release files / ntfy_api-0.0.6.tar.gz

Download URL ntfy_api-0.0.6.tar.gz
Size 28.2 kB
Tags Source
SHA-256 checksum
How to use checksums
f712b4e9ac93abf19861cd28c8ca06f21017c54749e184d1d5e4554304bf5f78
BLAKE2b-256 checksum
How to use checksums
e758bb3fc9c32fc2eadb8bbe0fc0e84d11094141d09dbeaf5c55e4195ef381ac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.7

Release files / ntfy_api-0.0.6-py3-none-any.whl

Download URL ntfy_api-0.0.6-py3-none-any.whl
Size 28.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b1d207a98c3e6bb8d7db6ccc78f3930840f6533c090d544351dccd61c08bf5c8
BLAKE2b-256 checksum
How to use checksums
b167c523ed7a8229f1967894312df3c8e435763f9e768e7ca4ccdac489d1ebb9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.7

Security for ntfy-api 0.0.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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