Azure Blob
Installation
pip install blob-az
Authorization
The required connection string can be obtained from the Azure Portal, within the Storage account, "Access keys" tab
Environment (.env)
For convenience, you can set os.environ["BLOB_CONN_STR"]. If you do, you can skip specifying it on every call.
E.g., create a .env file:
BLOB_CONN_STR="<BLOB_CONN_STR>"
Then load it before importing
from dotenv import load_dotenv
load_dotenv()
import blob_az as bz
bz.client() # just works!
API
- Asynchronous (everything is a coroutine)
- Single calls or multiple using a same client:
# single call await bz.list.containers(conn_str=CONN_STR) # ain't necessary with a .env file # multiple calls async with bz.client() as client: # idem. await bz.container.create("<container-name>", client=client) cs = await bz.list.containers(client=client)
Functions
blob_az
def client(...) -> BlobServiceClient
list
async def containers(...) -> list[dict]
async def blobs(...) -> list[dict]
container
async def create(...)
async def delete(...)
blob
async def upload(...)
async def download(...) -> bytes
def url(...) -> str # generate SAS url for blob
Metadata
Release files for blob-az 0.2.4
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 |
|---|---|---|---|---|
| blob-az-0.2.4.tar.gz | 4.9 kB | Without provenance | Details for blob-az-0.2.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| blob_az-0.2.4-py3-none-any.whl | Python 3 | none | any | Details for blob_az-0.2.4-py3-none-any.whl |
Total release size: 11.0 kB
Release files / blob-az-0.2.4.tar.gz
| Download URL | blob-az-0.2.4.tar.gz |
|---|---|
| Size | 4.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fb02cd40d95a5d212b40fdca33b358bef81752e3c1d8f5592797c40680103158
|
|
BLAKE2b-256 checksum How to use checksums |
6fde2dfb203dc5f6f78835c1b952b1e8f5c5e581bf0451b4d755af25a987ece9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.11.6
|
Release files / blob_az-0.2.4-py3-none-any.whl
| Download URL | blob_az-0.2.4-py3-none-any.whl |
|---|---|
| Size | 6.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9c2e3f94cd6a8f6d3c18cc2e4f5034e79a86c8badcfa3afb292ebd8e67e06295
|
|
BLAKE2b-256 checksum How to use checksums |
4babf0fef6a1149b4441752e31e5ce24e3c9de19d589f78c7de9e60f9f0a9eee
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.11.6
|
Security for blob-az 0.2.4
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.