Skip to main content

Python wrapper for CaltechDATA API.

Project description


Python library for using the CaltechDATA API

  • caltechdata_write write files and a DataCite 4 standard json record to CaltechDATA repository
  • caltechdata_edit edits records in CaltechDATA
  • get_metadata gets metadata from CaltechDATA records

Requires Python 3 (Recommended via Anaconda with reqests library.


There are some example python scripts in the GitHub repository.

Create a record:

python example.json -fnames logo.gif

The response will be the unique identifier for the record. You can put this at the end of a url to visit the record (e.g.

Edit a record (make changes to the example.json file to see a change)

python example.json -id pbkn6-m9y63

The response is the DOI for the record, which includes the unique identifier for the record in the default configuration.

Some groups have worked with the library to create custom DOIs. These can be passed in the metadata like:

python example_custom.json -fnames logo.gif

And then you can edit with

python example_custom.json -id m6zxz-p4j22

This returns the custom DOI of the record if it is successful.


Install by typing 'pip install caltechdata_api'


You need to acquire a personal access token from your CaltechDATA account (find it at the top right of your screen under "Applications"). Then copy the token to token.bash. Type source token.bash in the command line to load the token.

Only test your application on the test repository ( Testing the API on the public repository will generate junk records that are annoying to delete.

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

caltechdata_api-1.2.1.tar.gz (31.4 kB view hashes)

Uploaded source

Built Distribution

caltechdata_api-1.2.1-py3-none-any.whl (38.7 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page