NAV
ruby shell php python

Remr Key-Value API

Welcome to the Remr API! You can use our API to store any key-value data. These endpoints allow you to interact with any and all key-value data stored by us, including listing all keys, storing new key-values, retriving values, and more.

Learn more at remr.io, or sign up for your own free account at app.remr.io.

Regions

Remr uses regions to segregate data geographically. Where possible, use the region nearest to you or your customers for the best possible performance. Data stored in one region is not accessible in another region. All these examples use our London region, https://london.remr.io.

Storage

Each API key stores data in an isolated location. If you have two API keys, key-values stored against one key are not accessible to another one, even if both keys live in the same account. This lets you isolate the data of different applications all under one common account. You can rotate API keys with no impact on stored key-values.

Authentication

Remr uses API keys to allow access to the API. You can register for a new API key at our developer portal.

Remr expects the API key to be included in all API requests to the server in a header called x-api-key:

x-api-key: <api-key>

Response Objects

All endpoints return metadata alongside your results.

{
    "data": "banana",
    "message": null,
    "count": 1,
    "last_modified_utc": "2021-04-25T15:04:30+0000"
}

Key-Values

Set a Key-Value pair

This endpoint takes a single key and value in the request body, and stores them in your account. Provide your key and value as JSON in the request body.

This command returns a HTTP 200 response code for successful requests, or an error code and message in the response body for all non-successful requests.

import requests

requests.post('https://london.remr.io/v1/keys/', headers={'x-api-key': '<api-key>'}, data={"key": "apple", "value": "banana"})

curl -i -H 'x-api-key: <api-key>' -d '{"key": "apple", "value": "banana"}' -X POST https://london.remr.io/v1/keys/
require 'httparty'
@url = 'https://london.remr.io/v1/keys/'
@headers = { 'x-api-key': '<api-key>' }

HTTParty.post(@url.to_str, :body => { :key => "apple", :value => "banana" }.to_json, :headers => headers )
$client = new \GuzzleHttp\Client(['headers' => ['x-api-key' => '<api-key>']]);

$response = $client->request('POST', 'https://london.remr.io/v1/keys/', [GuzzleHttp\RequestOptions::JSON => ["key" => "apple", "value" => "banana"]]);

HTTP Request

POST https://london.remr.io/v1/keys

Get a Key-Value pair

This endpoint takes a key in the url, and returns the value for that item.

This command returns a HTTP 200 response code for successful requests, or an error code and message in the response body for all non-successful requests.

import requests

requests.get('https://london.remr.io/v1/keys/<key-name>', headers={'x-api-key': '<api-key>'})

curl -i -H 'x-api-key: <api-key>' -X GET https://london.remr.io/v1/keys/<key-name>
require 'httparty'
@url = 'https://london.remr.io/v1/keys/<key-name>'
@headers = { 'x-api-key': '<api-key>' }

HTTParty.get(@url.to_str, :headers => headers )
$client = new \GuzzleHttp\Client(['headers' => ['x-api-key' => '<api-key>']]);

$response = $client->request('GET', 'https://london.remr.io/v1/keys/<key-name>');

HTTP Request

GET https://london.remr.io/v1/keys/<key-name>

List all Key-Value pairs

This endpoint returns all the keys stored. No values are returned

This command returns a HTTP 200 response code for successful requests, or an error code and message in the response body for all non-successful requests.

import requests

requests.get('https://london.remr.io/v1/keys/', headers={'x-api-key': '<api-key>'})

curl -i -H 'x-api-key: <api-key>' -X GET https://london.remr.io/v1/keys/
require 'httparty'
@url = 'https://london.remr.io/v1/keys/'
@headers = { 'x-api-key': '<api-key>' }

HTTParty.get(@url.to_str, :headers => headers )
$client = new \GuzzleHttp\Client(['headers' => ['x-api-key' => '<api-key>']]);

$response = $client->request('GET', 'https://london.remr.io/v1/keys/');

HTTP Request

GET https://london.remr.io/v1/keys

Limits

Our very generous API limits are designed to keep the system fast for everyone:

In addition, a limited number of API keys can be created - this varies per plan. Each API key us only valid for one region.

Each account is limited as to the number of requests possible per month. There are no limits on the type of requests you can make - you're free to use all your quota on reads, writes, or any combination across all endpoints in your plan. Learn more about the different plans at remr.io.

Errors

The Remr API uses the following error codes:

Error Code Meaning
400 Bad Request -- Your request is invalid.
401 Unauthorized -- Your API key is wrong or supplied in the wrong format.
403 Forbidden -- you plan does not allow requests to this endpoint.
404 Not Found -- The specified resource could not be found.
405 Method Not Allowed -- You tried to access a resource with an invalid method.
429 Too Many Requests -- You're requesting too many resources - slow down.
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We had a problem with our server. Try again later.