Getting started

Installation

To install AnonAPI, run this command in a command prompt:

$ pip install anonapi

This is the preferred method to install AnonAPI, as it will always install the most recent stable release.

If you don’t have pip installed, this Python installation guide can guide you through the process.

If you installed anonapi before and want to upgrade to the latest version:

$ pip install --upgrade anonapi

Configuration

The Command Line Interface (CLI) needs to know a few things before it can be used.

Add a server to the CLI

The CLI communicates with one or more API servers. At least one of these should be added using the following steps:

First Find the url of an IDIS anonymization web API. An overview of servers within the radboudumc can be found here.

Lets say the server address is https://anonapi.org/server1. you can now add this server as ‘server1’:

$ anon server add server1 https://anonapi.org/server1

You can now see the new server in the server list:

$ anon server list

Activate server1. All subsequent commands will use this server.

$ anon server activate server1

Configure credentials

To make calls to any IDIS web API, the CLI needs to know which credentials to use. Do the following:

Set your username. For radboudumc this is your z-number. To set z1234567 as your username:

$ anon settings user set-username z1234567

Obtain an API token. This might require your z-number password)

$ anon settings user get-token