Chancellor / api-contract.md
VoidBreach's picture
Upload 62 files
35b8b9c verified
|
Raw History Blame Contribute Delete
1.17 kB

The Protocol of Computation: API Contract

Overview

This document defines the exchange format between the Sovereign Scholastic Academy (Hub) and contributing Virtual Nodes.

Security Constraints

  • All transport MUST use TLS 1.3.
  • All tasks MUST be delivered encrypted; keys are derived per-session using ephemeral Diffie-Hellman exchanges.
  • Final outputs MUST be signed by the node's private identity key.

Endpoints

1. Node Registration

POST /api/nodes/register Allows a node to authenticate and join the compute pool.

  • Request: { "nodeId": string, "publicKey": string, "capabilities": object }
  • Response: { "nodeToken": string, "expiresAt": string }

2. Task Acquisition

GET /api/nodes/tasks Fetches an encrypted vulnerability enrichment task.

  • Headers: Authorization: Bearer <nodeToken>
  • Response: { "taskId": string, "payload": encrypted_blob, "checksum": string }

3. Result Submission

POST /api/nodes/tasks/:taskId/result Submits the encrypted, signed result of a computation.

  • Request: { "result": encrypted_blob, "signature": string }
  • Response: { "status": "acknowledged" | "verified" }