Home /  API Reference / 

Stash

Stash API specification.

For more information, read the Getting Started Guide.

All API endpoints are POST operations and any parameters must be fully contained in the request body.

Download OpenAPI

Create Keyspace

POST/CreateKeyspace
Create a new Keyspace. Keyspace names are unique to a Stedi account.
Request body

application/json

Requiredstring
The name that identifies the Keyspace

Example

POST
https://stash.us.stedi.com/2022-04-20/CreateKeyspace

Delete Keyspace

POST/DeleteKeyspace
Delete a Keyspace.
Request body

application/json

Requiredstring
The name that identifies the Keyspace

Example

POST
https://stash.us.stedi.com/2022-04-20/DeleteKeyspace

Delete Value

POST/DeleteValue

Delete a value in a table. This operation also returns the value as it existed in the moment before it was deleted.

Request body

application/json

Requiredstring
The name that identifies the Keyspace
Requiredstring
The Key to set or get a Value with

Example

POST
https://stash.us.stedi.com/2022-04-20/DeleteValue

List Keyspaces

POST/ListKeyspaces
List all the Keyspaces.
Request body

application/json

Optionalint32
The number of results to return. Default is 100. The value can range between 1 and 100.
Optionalstring
The pagination token

Example

POST
https://stash.us.stedi.com/2022-04-20/ListKeyspaces

Get Keyspace

POST/GetKeyspace
Get a Keyspace.
Request body

application/json

Requiredstring
The name that identifies the Keyspace

Example

POST
https://stash.us.stedi.com/2022-04-20/GetKeyspace

Increment Value

POST/IncrementValue

Increment a value.

Increment treats the initial value as 0 if no value exists for the key. Increment adds the given amount to the value. An error is thrown if the value exists and is not a number.

Request body

application/json

Requiredstring
The name that identifies the Keyspace
RequiredAny
The amount to increment by. Must be a number.
Requiredstring
The Key to set or get a Value with

Example

POST
https://stash.us.stedi.com/2022-04-20/IncrementValue

Set Value

POST/SetValue

Set a Value in a Keyspace.

This operation will overwrite any previous Values that have been stored in the same Key.

Request body

application/json

Requiredstring
The name that identifies the Keyspace
RequiredAny

The value associated with the key.

Can be any one of:

  • string
  • number
  • boolean
  • array
  • object
Requiredstring
The Key to set or get a Value with

Example

POST
https://stash.us.stedi.com/2022-04-20/SetValue

Get Value

POST/GetValue

Get a Value from a Keyspace. Always returns the latest Value that has been stored. Empty object is returned when the given key does not exist.

Request body

application/json

Requiredstring
The name that identifies the Keyspace
Requiredstring
The Key to set or get a Value with

Example

POST
https://stash.us.stedi.com/2022-04-20/GetValue

List Values

POST/ListValues
List all the Values in a Keyspace.
Request body

application/json

Requiredstring
The keyspace name
Optionalint32

The number of results to return. If 1MB of results are processed before the pageSize is reached then the results fetched up to that point are returned. Default is to return up to 1MB of results. The value has a minimum of 1.

Optionalstring
The pagination token

Example

POST
https://stash.us.stedi.com/2022-04-20/ListValues