# Bulk Processing

Processing many timestamps? Do it right!

Many business cases require the submission of loads of hashes via the OriginStamp API. Our bulk interface supports this requirement in an efficient, easy way.

This saves you and us both throughput and also eases the processing on your side. On top, you get our ❤️ !

# Submit multiple hashes

Regarding the payload you send, submitting multiple hashes is aligned with the submission of a single hash. You just can hand in multiple at a time.

King of hashes

You can send up to 100 hashes simultaneously at a time!

# Request

POST /v4/timestamp/bulk/create (opens new window)

curl -X POST "http://api.originstamp.com/v4/timestamp/bulk/create"\
     -H "Authorization: YOUR_API_KEY"\
     -H "Content-Type: application/json"\
     -d 'YOUR_PAYLOAD'

# Payload

{
  timestamps: [
    {
      "comment": "first hash",
      "hash": "ff25ec15cc4fde9a20649ca8818c5a866d3661272f19b7e114bdb096325be1d5",
      "notifications": [
        {
          "currency": 0,
          "notification_type": 1,
          "target": "https://webhook-notification.url"
        }
      ]
    },
    {
      "comment": "second hash",
      "hash": "2726d67a4dfe3492afd83abb8519261a8c4c15437c9fb237b22ca4d66c0f127c",
    }
  ]
}

# comment (optional)

You can add a short comment (max. 256 characters) which can be used for indexing and searching (privacy-preserving).

Example

test

# hash (required)

Hash in HEX representation. We suggest to use SHA-256. This hash will be aggregated and included into the blockchain.

Example

2c5d36be542f8f0e7345d77753a5d7ea61a443ba6a9a86bb060332ad56dba38e

# notifications (optional)

Add a list of notifications to your submission. Our system will notify each specified target with the corresponding timestamp information when the status is verified in a Blockchain.

Example for a mail notification on Bitcoin

[{
  "currency": 0,
  "notification_type": 0,
  "target": "no-reply@originstamp.com"
}]

Example for a URL webhook notification on Ethereum

[{
  "currency": 1,
  "notification_type": 1,
  "target": "https://no-reply.originstamp.com/callback"
}]
# currency
  • 0: Bitcoin
  • 1: Ethereum
  • 100: Südkurier
# notification_type
  • 0: Mail
  • 1: Webhook
# target

Mail address or URL to which the notification should be sent.

# Response

The response contains a separate response object for each hash submitted. They are in the same order as the hashes specified in the request. Any error conditions can thus be identified directly.

To later query the status of one of the submitted hashes, you can use the provided seed_id field of its inner timestamp structure. This field can be used to query the timestamping status of the seed corresponding to the submitted hash.

[
  {
    "data": {
      "comment": "first hash",
      "created": true,
      "date_created": 0,
      "hash_string": "ff25ec15cc4fde9a20649ca8818c5a866d3661272f19b7e114bdb096325be1d5",
      "timestamps": [
        {
          "seed_id": "string",
          "currency_id": 0,
          "transaction": "string",
          "private_key": "string",
          "submit_status": 0,
          "timestamp": 0
        }
      ]
    },
    "error_code": 0,
    "error_message": null
  },
  {
    "data": {
      "comment": "second hash",
      "created": true,
      "date_created": 0,
      "hash_string": "2726d67a4dfe3492afd83abb8519261a8c4c15437c9fb237b22ca4d66c0f127c",
      "timestamps": [
        {
          "seed_id": "string",
          "currency_id": 0,
          "transaction": "string",
          "private_key": null,
          "submit_status": 0,
          "timestamp": 0         
        }
      ]
    },
    "error_code": 0,
    "error_message": null
  }
]

# comment

The timestamp's comment, if any.

# created

Field is true if it is a novel hash. If the flag is false, the hash was already submitted before.

# date_created

The time when your hash was submitted to OriginStamp. The date is returned in milliseconds since 1.1.1970 (unix epoch), timezone: UTC. This is not considered as a tamper-proof timestamp.

# hash_string

The hash string that you check for. Redundant with the {hash_string} route parameter.

# timestamps

Timestamps that exist for this hash, no matter whether they are tamper-proof yet. Can contain zero (no timestamp yet) to an arbitrary number of items.

The structure of the timestamps is the same as in other interfaces. An explanation of the individual fields can be found below.

# Check the seed status

Why Seed Polling?

We submit to a certain blockchain in a certain interval. For Bitcoin, e.g., once a day. All hashes submitted to OriginStamp are collected and aggregated in a seed and later share the same blockchain timestamp.

If you submit a large number of hashes at once, they likely share the same seed. Hence, you can check the status for several hashes at once by checking the seed status. When caching the seed status on your end, you save a lot of HTTP connection overhead and needless requests.

# Request

GET /v4/timestamp/status/seed/{seed_id} (opens new window)

curl -X GET "http://api.originstamp.com/v4/timestamp/status/seed/f98a61e8-22bd-4ea5-ab9e-02723ff78c40"\
     -H "Authorization: YOUR_API_KEY"

# Response

The default timestamp object is returned that contains all necessary timestamp information.

{
  "data": {
    {
      "seed_id": "string",
      "currency_id": 0,
      "private_key": "string",
      "submit_status": 0,
      "timestamp": 0,
      "transaction": "string"
    }
  },
  "error_code": 0,
  "error_message": "string"
}

# seed_id

The seed ID you queried. Redudant with the {seed_id} route parameter.

# currency_id

  • 0: Bitcoin
  • 1: Ethereum
  • 100: Südkurier

# private_key

The private key represents the top hash in the Merkle Tree. Synonyms: root hash, private key, top hash, seed hash.

# submit_status

  • 0: Hashes contained in this seed were only submitted to OriginStamp and added to the timestamping queue. They will be timestamped with the next timestamp submission.
  • 1: Hashes contained in this seed were submitted to the blockchain network, but are not yet included.
  • 2: Hashes contained in this seed are included in the latest block.
  • 3: Hashes contained in this seed have a tamper-proof timestamp.

# timestamp

The tamper-proof timestamp of all hashes contained in this seed. It is formatted as follows:

[ms] since 1.1.1970 (unix epoch), timezone: UTC

# transaction

The transaction ID of the timestamp, e.g., a transaction hash in Bitcoin. Only available if seed has a submit_status >= 2.