Skip to main content

Python package to interface with Snip Lab Notebook

Project description

Snip

PyPI - Version Documentation Status

Python Package of quality of life and helper functions to interface with the Snip Lab Book. Allows to create and upload snippets with relative ease. Store and retrieve api tokens, and more.

Features

  • Token management: Store and retrieve api tokens in a secure keyring or in a configuration files.
  • Python API: Python API to create and upload snippets to your lab books.
  • CLI: Command line interface to interact with the Snip API.

Quickstart

Snip-Lab is distributed on PyPI. To use the package:

  1. Install the package using pip:
pip install snip-python
  1. Use the snip command line interface (CLI) to interact with your lab books. For example, you can use the snip token command to store and retrieve your API tokens.
snip token --help
  1. Create and upload snippets to your lab books programmatically using the Python API.
from snip import ImageSnip

snip = ImageSnip("path/to/image.png", book_id="[YOUR_BOOK_ID]")

# show a preview of the snippet
snip.preview()
# upload the snippet
snip.upload()

The upload will automatically search your tokens in the keyring or in the configuration file and use the correct token to upload the snippet.

For more information, visit documentation.

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

snip_python-0.0.5.tar.gz (1.2 MB view details)

Uploaded Source

Built Distribution

snip_python-0.0.5-py3-none-any.whl (40.5 kB view details)

Uploaded Python 3

File details

Details for the file snip_python-0.0.5.tar.gz.

File metadata

  • Download URL: snip_python-0.0.5.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.10

File hashes

Hashes for snip_python-0.0.5.tar.gz
Algorithm Hash digest
SHA256 9e87099646d7c5fa9a605537efc6450da9362f780b78a3f8a00012b255646683
MD5 705193261e3bb947f1ad2ca51130e6f4
BLAKE2b-256 0c884b0909b2f299ecf9b242bfb96aae51a9adda1d0c0fb18034122a9df0b312

See more details on using hashes here.

File details

Details for the file snip_python-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: snip_python-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 40.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.10

File hashes

Hashes for snip_python-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 cc6ea95e573f521513e63d69f30788e3d2459db74075382b7d6aac44346fa193
MD5 93b08f1bc0822351127e85537f540efa
BLAKE2b-256 c00f74a206e2985e08303f506ddc083b6b42c06d119cfdd94853575d83303b89

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