Get an API Key
Use it to authenticate Core API requests.
Generate an API key from the Trustless Work Backoffice.
1
Authenticate API requests
Send the generated key with each authenticated request:
x-api-key: <id>.<secret>JavaScript example
Use your API key in the x-api-key header for authenticated requests:
const apiKey = "<id>.<secret>";
const response = await fetch("TW_URL", {
headers: {
"x-api-key": apiKey,
},
});
if (!response.ok) {
throw new Error(`Request failed: ${response.status}`);
}
const escrows = await response.json();
console.log(escrows);Last updated