Need help with opentimestamps-server?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

154 Stars 63 Forks Other 487 Commits 16 Opened issues


OpenTimestamps server component

Services available


Need anything else?

Contributors list

OpenTimestamps Calendar Server

This package provides the

daemon, a calendar server which provides aggregation, Bitcoin timestamping, and remote calendar services for OpenTimestamps clients. You do not need to run a server to use the OpenTimestamps protocol - public servers exist that are free to use. That said, running a server locally can be useful for developers of OpenTimestamps protocol clients, particularly with a local Bitcoin node running in regtest mode.


You'll need a local Bitcoin node version 0.17.1 with a wallet with some funds in it; a pruned node is fine. While

is running the wallet should not be used for other purposes, as currently the Bitcoin timestamping functionality assumes that it has exclusive use of the wallet.

Install the requirements:

pip3 install -r requirements.txt

Create the calendar:

mkdir -p ~/.otsd/calendar/
echo "" > ~/.otsd/calendar/uri
dd if=/dev/random of=~/.otsd/calendar/hmac-key bs=32 count=1

The URI determines what is put into the URI field of pending attestations returned by this calendar server. For a server used for testing, the above is fine; for production usage the URI should be set to a stable URL that OpenTimestamps clients will be able to access indefinitely.

The HMAC key should be kept secret; it's meant to allow for last-ditch calendar recovery from untrusted sources, although only part of the functionality is implemented. See the source code for more details!

To actually run the server, run the

program. Proper daemonization isn't implemented yet, so
runs in the foreground. To run in testnet or regtest, use the
options. The OpenTimestamps protocol does not distinguish between mainnet, testnet, and regtest, so make sure you don't mix them up!

To use your calendar server, tell your OpenTimestamps client to connect to it:

ots stamp -c -m 1 FILE

OpenTimestamps clients have a whitelist of calendars they'll connect to automatically; you'll need to manually add your new server to that whitelist to use it when upgrading or verifying:

ots -l upgrade FILE.ots

If your server is running on testnet or regtest, make sure to tell your client what chain to use when verifying. For example, regtest:

ots --btc-regtest -l upgrade FILE.ots

Tip: with regtest you can mine blocks on demand to make your timestamp confirm with the

RPC command. For example, to mine ten blocks instantly:
bitcoin-cli generate 10

By default

binds to localhost;
is not designed to be exposed directly to the public and requires a reverse proxy for production usage. An example configuration for nginx is provided under

Bitcoin core

Bitcoin node must be version 0.17.1 and the following options are needed:


Unit tests

python3 -m unittest discover -v

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.