Getting Started
Go from zero to a verified operation record in under five minutes.
1. Create an Account
Register your organization to get API credentials.
# Step 1: Register via Better Auth
curl -X POST https://api.elydora.com/api/auth/sign-up/email \
-H "Content-Type: application/json" \
-d '{
"email": "admin@acme.com",
"password": "your-secure-password",
"name": "Admin User"
}'
# Step 2: Issue an API token for SDK use
# (After logging in via the console or POST /api/auth/sign-in/email)
curl -X POST https://api.elydora.com/v1/auth/token \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <your-session-token>" \
-d '{"ttl_seconds": 7776000}'2. Install an SDK
Choose your language and install the Elydora client library. If you use a supported AI coding tool (Claude Code, Cursor, Gemini CLI, Kiro CLI, Kiro IDE, OpenCode, Copilot CLI, or Letta Code), you can skip ahead to the one-command install which sets everything up automatically.
# Node.js
npm install @elydora/sdk
# Python
pip install elydora
# Go
go get github.com/Elydora-Infrastructure/Elydora-Go-SDK3. Initialize the Client
Configure the client with your organization ID, agent ID, and private key.
import { ElydoraClient } from '@elydora/sdk';
const client = new ElydoraClient({
orgId: 'org_acme',
agentId: 'agent_underwriter',
privateKey: process.env.ELYDORA_KEY,
});4. Register an Agent
Before submitting operations, register the agent with its Ed25519 public key.
const agent = await client.registerAgent({
agent_id: 'agent_underwriter',
display_name: 'Loan Underwriter v2',
responsible_entity: 'Underwriting Team',
keys: [{
kid: 'agent_underwriter-key-1',
public_key: client.getPublicKey(),
algorithm: 'ed25519',
}],
});
console.log(agent.agent.status); // 'active'5. Submit an Operation
Create and submit a signed operation record. The SDK handles signing, chain-hashing, and nonce generation automatically.
const record = client.createOperation({
operationType: 'loan.approve',
subject: { id: 'borrower:BRW-2026-0042', type: 'borrower' },
action: { name: 'approve', type: 'decision' },
payload: { loanId: 'LN-2026-001', amount: 50000 },
});
const { receipt } = await client.submitOperation(record);
// receipt is the Elydora Acknowledgement Receipt (EAR)
// receipt.chain_hash → Elydora Chain Hash6. Verify the Record
Verify that a submitted operation is intact and correctly chain-linked.
const verification = await client.verifyOperation(receipt.operation_id);
console.log(verification.valid); // trueComplete Example: Logging an AI Agent Decision
This end-to-end Node.js script demonstrates the full lifecycle: creating a client, constructing an EOR with real fields, signing and submitting the operation, receiving an EAR, and verifying the record.
import { ElydoraClient } from '@elydora/sdk';
async function main() {
// 1. Create the client with your org, agent, and private key
const client = new ElydoraClient({
orgId: 'org_acme',
agentId: 'agent_underwriter',
privateKey: process.env.ELYDORA_KEY,
});
// 2. Construct an operation record for a loan approval decision
// The SDK auto-generates: operation_id, issued_at, nonce,
// payload_hash, prev_chain_hash, and signature.
const record = client.createOperation({
operationType: 'loan.approve',
subject: { id: 'borrower:BRW-2026-0042', type: 'borrower' },
action: { name: 'approve', type: 'decision' },
payload: {
loanId: 'LN-2026-001',
borrowerId: 'BRW-2026-0042',
amount: 50000,
currency: 'USD',
term: '30y',
interestRate: 6.25,
riskScore: 'A2',
approvalReason: 'Debt-to-income ratio within threshold',
},
});
// The full EOR that gets submitted contains all 15 fields:
// op_version, operation_id, org_id, agent_id, issued_at,
// ttl_ms, nonce, operation_type, subject, action, payload,
// payload_hash, prev_chain_hash, agent_pubkey_kid, signature
// 3. Submit the signed EOR to Elydora (POST /v1/operations)
const { receipt } = await client.submitOperation(record);
console.log('Operation submitted successfully');
console.log(' operation_id:', receipt.operation_id);
console.log(' receipt_id: ', receipt.receipt_id);
console.log(' seq_no: ', receipt.seq_no);
console.log(' chain_hash: ', receipt.chain_hash);
// 4. Verify the operation (POST /v1/operations/:id/verify)
const verification = await client.verifyOperation(receipt.operation_id);
console.log('Verification result:', verification.valid);
console.log(' signature:', verification.checks.signature);
console.log(' chain: ', verification.checks.chain);
console.log(' receipt: ', verification.checks.receipt);
}
main().catch(console.error);What Gets Sent to the API
The SDK constructs the following EOR and sends it to POST https://api.elydora.com/v1/operations:
{
"op_version": 1,
"operation_id": "550e8400-e29b-41d4-a716-446655440000",
"org_id": "org_acme",
"agent_id": "agent_underwriter",
"issued_at": "2026-02-28T14:00:00Z",
"ttl_ms": 30000,
"nonce": "a1b2c3d4e5f6",
"operation_type": "loan.approve",
"subject": { "id": "borrower:BRW-2026-0042", "type": "borrower" },
"action": { "name": "approve", "type": "decision" },
"payload": {
"loanId": "LN-2026-001",
"borrowerId": "BRW-2026-0042",
"amount": 50000,
"currency": "USD",
"term": "30y",
"interestRate": 6.25,
"riskScore": "A2",
"approvalReason": "Debt-to-income ratio within threshold"
},
"payload_hash": "sha256:e3b0c44298fc1c149afbf4c8996fb924...",
"prev_chain_hash": "sha256:d7a8fbb307d7809469ca9abcb0082e4f...",
"agent_pubkey_kid": "kid_abc123",
"signature": "base64:ed25519-signature-bytes..."
}The EAR Response
Elydora responds with an Elydora Acknowledgement Receipt confirming the operation was received and sequenced:
{
"receipt_id": "rcpt_xyz789",
"operation_id": "550e8400-e29b-41d4-a716-446655440000",
"seq_no": 42,
"chain_hash": "sha256:ghi789...",
"server_received_at": "2026-02-28T14:00:01Z",
"elydora_signature": "base64-elydora-sig..."
}Next Steps
- Read the API Reference for the full endpoint documentation
- Understand the Elydora Responsibility Protocol and its cryptographic guarantees
- Configure RBAC roles for your team
- Review the Security page for key management best practices
- See the AI Agent Integration guide for framework-specific patterns
- Explore the Dashboard Guide to manage agents and operations through the console