Sprinkler Util
Utility functions for use within sprinkler python tasks.
get_request_body
Use this function to get the request body if it exists.
Optionally convert it to JSON with the as_json argument.
Will return None if there is no request body.
from sprinkler_util import get_request_body
body = get_request_body(as_json=True)
if body is None:
raise Exception("NO REQUEST BODY")
...
get_secret
Use this function to get a secret value. Case insensitive.
If the secret is not set, then a SprinklerSecretNotSetException will be raised.
from sprinkler_util import get_secret
api_key = get_secret("GOOGLE_API_KEY")
...
send_response
This function is used to send a response for a call-and-response type job.
Only call this function once.
Internally this function wraps what you pass to it in json.dumps.
from sprinkler_util import send_response
send_response("hello world")
Metadata
Release files for sprinkler-util 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sprinkler_util-0.1.3.tar.gz | 2.8 kB | Without provenance | Details for sprinkler_util-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sprinkler_util-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for sprinkler_util-0.1.3-py3-none-any.whl |
Total release size: 5.9 kB
Release files / sprinkler_util-0.1.3.tar.gz
| Download URL | sprinkler_util-0.1.3.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f88191fc2e4ce4d6ae386cd071b2aa511daacc8b2dae159e0eac08378f09323b
|
|
BLAKE2b-256 checksum How to use checksums |
d21a676af162d4e96c4d18e5714a3a35225fb3fdb3c2d0f155574bd031e80a77
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.16
|
Release files / sprinkler_util-0.1.3-py3-none-any.whl
| Download URL | sprinkler_util-0.1.3-py3-none-any.whl |
|---|---|
| Size | 3.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4c0febd0e27f896552fc79b3231778f2435ee29c1b80d8dca21ffc778b9a2fec
|
|
BLAKE2b-256 checksum How to use checksums |
3e3041caced20069524cca5d0d54d91e82643501aaae17274ac693bf8ca92605
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.16
|
Security for sprinkler-util 0.1.3
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.