Create an API Key
Creating new API Keys
Often developers prefer a simple, application centric authentication method such as an API Key. Fortunately, Dreamspace makes it very easy to generate and manage API Keys.
To Generate or Manage API Keys:
-
Navigate to Dreamspace and login.
-
Click on "My Account" in the upper-right most corner (replaces "Sign in") and click on "Account Settings".
-
On the left pane, click on "API Authentication" and you will see an API Key section.
If you have no defined API Keys, the UI will display the "Create API Key" view: -
To create a new API Key, simply add a note (to remind yourself where/how the key will be used) and click "Add"
Copy and save your API Key - it will never be shown again!
If you forget your key, you will need to delete it and create a new key.
Congrats! You've just created an API Key!
Using your API Keys
Some APIs in Space and Time (SXT Chain) can use the API Key directly to perform simple operations, such as running a query. Other operations require an Access Token, which can be acquired using an API Key, or acquired directly using a more secure (but more challenging) direct network authentication.
Running a Query Directly with an API Key
Any of the MakeInfinite API Endpoints for the Space and Time Managed DB that are prefixed with "Proxy" can be operated directly using the API. For example: https://proxy.api.makeinfinite.dev/v1/sql
Try it out yourself!
Let's look at the number of bitcoin transactions over the last 3 days, including any time today. The SQL would look something like:
SELECT count(*)
FROM bitcoin.transactions
WHERE time_stamp between current_date-3 and current_Date+1
To execute this directly with an API Key:
- Copy your Space and Time API Key
- head over to: API reference for executing a proxy query
- Paste your API Key in the "apiKey" field, and type your query in the "sqlText" field (or copy/paste the example below)
- Click "Try It!

You can leave "biscuits" and "originApp" blank.
Congrats! You've run a query directly with your API Key!
Trade your API Key for an Access Token
Most API endpoints available through MakeInfinite Labs require a more-secure Access Token. Fortunately, it's easy to trade your API Key for an Access Token, allowing you API access to any feature.
To trade your API Key for an Access Token:
- Make sure you have your API Key created and ready to use.
- Call the Proxy endpoint: Authenticate with API Key
- This will return the standard Access Token output:
{
"accessToken": "eyJ0eXBlIjoiYWNjZ...",
"accessTokenExpires": 1746565427275,
}
This represents (a) your Access Token, your (b) Refresh Token, and the unix timecode expiration for each.
Try out your new Access Token:
To try out your new Access Token, head over to any non-Proxy API endpoint - below, we'll call the Table Discovery endpoint, and look to see what tables exist in Bitcoin:

- Copy your Access Token from above
- Head over to the API reference for the Table Discovery endpoint
- Paste your Access Token in the "Bearer" / "Credentials" field at the top-right
- Change Scope to "Public" (Index data is always public)
- Type into the schema "Bitcoin" (or your chain of choice)
- Click "Try It!"
The JSON response should come back with a list of all the Bitcoin tables, and their characteristics.
Congrats! You executed a standard API with your API Key generated Access Token!
Updated 1 day ago