Skip to main content

Alloy Client

Description

A Python client and command-line tool for the Alloy digital archive. Also includes a rudimentary client for any CDMI enabled cloud storage.

After Installation, connect to an Alloy archive:

alloy init --api=https://alloy.example.com/api/cdmi

(or if authentication is required by the archive):

alloy init --api=https://alloy.example.com/api/cdmi --username=USER --password=PASS

Show current working container:

alloy pwd

List a container or object:

alloy ls [name]

Move to a new container:

alloy cd subdir
...
alloy cd ..  # back up to parent

Create a new container:

alloy mkdir new

Put a local file:

alloy put source.txt
...
alloy put source.txt destination.txt  # Put to a different name remotely

Provide the MIME type of the object (if not supplied alloy put will attempt to guess):

alloy put --mimetype "text-plain" source.txt

Fetch a data object from the archive to a local file:

alloy get source.txt

alloy get source.txt destination.txt  # Get with a different name locally

alloy get --force source.txt  # Overwrite an existing local file

Remove an object:

alloy rm file.txt

Recursively remove a container (WARNING: Dangerous!):

alloy rm -r container

Remove an already empty container (Safer!):

alloy rmdir container

Close the current session to prevent unauthorized access:

alloy exit

Advanced Use - Metadata

Set (overwrite) a metadata value for a field:

alloy meta file.txt "org.dublincore.creator=S M Body"
alloy meta . "org.dublincore.title=My Collection"

Add another value to an existing metadata field:

alloy meta file.txt "org.dublincore.creator+=A N Other"

List metadata values for all fields:

alloy meta file.txt

List metadata value(s) for a specific field:

alloy meta file.txt org.dublincore.creator

Delete a metadata field:

alloy meta file.txt "org.dublincore.creator="

Installation

Create And Activate A Virtual Environment

$ virtualenv ~/ve/alloyclient<version>
...
$ source ~/ve/alloyclient/bin/activate

Install Dependencies

pip install -r requirements.txt

Install Alloy Client

pip install -e .

Detailed OSX install commands

sudo easy_install virtualenv      # virtualenv installs pip
python -m virtualenv ~/ve/alloyclient<version>
source ~/ve/alloyclient<version>/bin/activate
pip install -r requirements.txt
pip install -e .

License

Copyright 2014 Archive Analytics Solutions

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Metadata

Release files for alloyclient 1.0.0

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

Source distribution (sdist)

Source distribution for alloyclient 1.0.0
File Size Uploaded Provenance Actions
alloyclient-1.0.0.tar.gz 19.8 kB Without provenance Details for alloyclient-1.0.0.tar.gz

Release files / alloyclient-1.0.0.tar.gz

Download URL alloyclient-1.0.0.tar.gz
Size 19.8 kB
Tags Source
SHA-256 checksum
How to use checksums
779550cf7d4f12d14741a3680dddedf2e748e096282755cd35defd3373099b86
BLAKE2b-256 checksum
How to use checksums
666bc5b16102e66ec117da020ffbfd766b743105ba2b37e3f6b3da4123135138
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for alloyclient 1.0.0

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.

Release history Release notifications | RSS feed

This release

1.0.0 This release

1 release file No provenance

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