CipherStash Documentation

Importing Records

Typically your application will store records in your collections as they’re created by your application. For initial setup or migrations, though, it’s often useful to be able to bulk-import existing data. You can do this using the stash import command.


Records to be imported should be saved as objects in a JSON array. To get started, you can download some example movie data from Try running the following command to download so we can import it into CipherStash in the next step.

curl -Lo

After downloading, you should see that contains an array of objects that looks something like this:

    "title": "Star Trek: The Motion Picture",
    "year": 1979,
    "runningTime": 132
    "title": "Star Trek II: The Wrath of Khan",
    "year": 1982,
    "runningTime": 113
    "title": "Star Trek III: The Search for Spock",
    "year": 1984,
    "runningTime": 105
  // ... and so on

Now that we have some example data, let’s pass it to stash for import:

stash import movies --data

This will take a little while (and give your CPU some exercise), because the import process involves parsing and encrypting all the records as they get sent to CipherStash. Once the command returns, your data is imported and ready to go.