MACS
SDKs
Rust, TypeScript and HTTP for MACS.
Every operation on MACS is reachable from every shipped SDK plus the raw HTTP wire.
Rust
use map_sdk::Client;
use serde_json::json;
let client = Client::from_env()?;
let resp = client
.dispatch(
"MACS",
"v1.0.0",
"auth_negotiation",
json!({
"profile": "DidAuth",
"challenge_kind": "Nonce"
}),
)
.await?;
println!("{:#?}", resp);TypeScript
import { MapClient } from '@l1fe/map';
const map = new MapClient({
apiKey: process.env.MAP_API_KEY!,
agentDid: process.env.MAP_AGENT_DID!,
tenantId: 'org_acme'
});
const resp = await map.dispatch({
protocol: 'MACS',
version: 'v1.0.0',
operation: 'auth_negotiation',
input: {
"profile": "DidAuth",
"challenge_kind": "Nonce"
}
});HTTP wire
POST /v1/dispatch HTTP/2
Host: api.multiagentic.dev
Authorization: Bearer $MAP_API_KEY
X-Agent-Did: $MAP_AGENT_DID
X-Tenant-Id: org_acme
Content-Type: application/json
{
"protocol": "MACS",
"version": "v1.0.0",
"operation": "auth_negotiation",
"input": {
"profile": "DidAuth",
"challenge_kind": "Nonce"
},
"tenant_id": "org_acme"
}All operations
map.dispatch(...)with operation"auth_negotiation"— Negotiate an auth profile (DidAuth, Loopy, Zkp, OAuth2, BioagenticProfile) and produce a session descriptor.map.dispatch(...)with operation"generate_challenge"— Emit a nonce, ZK challenge, or signature challenge bound to a session and profile.map.dispatch(...)with operation"verify_response"— Verify a challenge response. Returns a stamped MAP envelope on success; structured refusal on failure.map.dispatch(...)with operation"authorization_request"— Evaluate a capability request against the policy bound to the verified identity.map.dispatch(...)with operation"credential_verification"— Verify presented claims (credential or attestation) against issuer signatures and revocation lists.
See SDKs for client construction, retry, trace propagation.