@adastracomputing/ink 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -8,6 +8,31 @@ here. Pre-1.0 releases follow `0.Y.Z` semantics, see
8
8
 
9
9
  No unreleased changes.
10
10
 
11
+ ## 0.1.5, expose handshake type re-exports and InkTransportSchema from the package root
12
+
13
+ Pure additive release. Re-exports the `InkChallenge`, `InkRejection`, `InkResolution`, `InkTransport` types and the `InkTransportSchema` constant from the package root. Adopters writing handshake-aware receivers can now type their state-machine without reaching into a deep path. No wire-level changes. No behavior changes inside the existing functions. Receivers on 0.1.4 work unchanged on 0.1.5.
14
+
15
+ Per the pre-1.0 policy this release publishes under the `next` dist-tag.
16
+
17
+ ## 0.1.4, expose receipts, transport-auth, discovery-gating, audit schemas and handshake schemas from the package root
18
+
19
+ Pure additive release. The implementation files have shipped in earlier releases under deep paths; this release brings them to the package root so adopters writing receivers, builders, or auditor clients can import everything they need from `@adastracomputing/ink` directly.
20
+
21
+ New root-level exports:
22
+
23
+ - **Receipts** (`./ink/receipts`): `buildReceipt`, `shouldSendReceipt`, `sendReceiptFireAndForget`. The canonical INK delivery-receipt builders, signing helpers and fire-and-forget transport. A receiver that wants to ack inbound envelopes per Auditability §6 can drop these in without rolling its own.
24
+ - **Transport-auth** (`./ink/transport-auth`): `resolveEffectiveTransports`, `checkTransportAllowed`. The token-level transport allowlist enforcement, including the "field absent vs empty array" semantics. Required for any extension token issuer.
25
+ - **Discovery-gating** (`./ink/discovery-gating`): `buildRedactedCard`, `shouldRedactOnGet`, `AgentCardQuerySchema`. Visibility-aware Agent Card responses (`public`, `network_only`, `capability_gated`, `private`).
26
+ - **Checkpoint parsing** (`./ink/checkpoint`): `parseCheckpoint`, `formatCheckpoint`, `CheckpointData`. For consumers of transparency-log signed checkpoints.
27
+ - **Audit event schemas + types** (`./models/ink-audit`): `InkAuditEventTypeSchema`, `InkAuditEventSchema`, `InkAuditInclusionSchema`, `InkReceiptSchema`, `InkAuditQuerySchema`, `InkIntroductionReceiptSchema`, plus matching types `InkAuditEventType`, `InkAuditEvent`, `InkAuditInclusion`, `InkReceipt`, `InkAuditQuery`, `InkAuditResponse`, `InkIntroductionReceiptStatus`.
28
+ - **Handshake message schemas** (`./models/ink-handshake`): `InkChallengeSchema`, `InkRejectionSchema`, `InkResolutionSchema`, type `AgentCardVisibility`.
29
+ - **Agent Card schema** (`./models/agent-card`): `AgentCardSchema` (the type was already exported).
30
+ - **Encryption key encoder** (`./crypto/keys`): `encodeEncryptionKeyMultibase` (the encoder companion to the already-exported `decodeEncryptionKeyMultibase` from 0.1.3).
31
+
32
+ No wire-level changes. No behavior changes inside the existing functions. Receivers on 0.1.3 work unchanged on 0.1.4.
33
+
34
+ Per the pre-1.0 policy this release publishes under the `next` dist-tag.
35
+
11
36
  ## 0.1.3, expose validateMessage and decodeEncryptionKeyMultibase from the package root
12
37
 
13
38
  Pure additive release that re-exports two helpers from the package root so adopters no longer have to import them through a deep internal path:
package/README.md CHANGED
@@ -48,6 +48,8 @@ npm install @adastracomputing/ink
48
48
 
49
49
  The package ships compiled ESM with bundled type definitions (`dist/index.js` + `dist/index.d.ts`). Any project with a standard JS toolchain can import it directly — no TypeScript build step on the consumer side. The build runs automatically via `prepack` before publish.
50
50
 
51
+ From 0.1.3 onward, receivers can also import `validateMessage` (canonical envelope + payload-schema parse, throws on drift) and `decodeEncryptionKeyMultibase` (X25519 multibase → 32 bytes, the companion to `decodePublicKeyMultibase` for Ed25519). These let an implementer drop the inline schema guard and key-decode helpers the previous guides asked them to write. `MessageEnvelope` (type) and `MessageEnvelopeSchema` (Zod constant) are also re-exported for adopters who want to type their parser surface against the canonical schema.
52
+
51
53
  ```ts
52
54
  import {
53
55
  generateKeypair,
package/dist/index.d.ts CHANGED
@@ -1,11 +1,21 @@
1
1
  export { signInkMessage, verifyInkSignature, buildSignatureBase, buildAuthHeader, computeMessageHash, computeEventHash, computeAuditMerkleLeafHash, signAuditEvent, verifyAuditEventSignature, signAuditResponse, verifyAuditResponseSignature, verifyAuditEventChain, signAuditQueryResponse, verifyAuditQueryResponseSignature, encryptInkPayload, decryptInkPayload, checkReplay, base64urlEncode, base64urlDecode, hexToBytes, bytesToHex, jcsCanonicalize, MAX_TIMESTAMP_AGE_MS, MAX_FUTURE_TIMESTAMP_MS, } from "./crypto/ink.js";
2
2
  export { signMessage, verifyMessage } from "./crypto/sign.js";
3
3
  export { verifyInkSignatureWithKeys } from "./crypto/multi-key-verify.js";
4
- export { generateKeypair, generateEncryptionKeypair, deriveAgentId, encodePublicKeyMultibase, decodePublicKeyMultibase, decodeEncryptionKeyMultibase, extractPublicKeyFromAgentId, } from "./crypto/keys.js";
4
+ export { generateKeypair, generateEncryptionKeypair, deriveAgentId, encodePublicKeyMultibase, encodeEncryptionKeyMultibase, decodePublicKeyMultibase, decodeEncryptionKeyMultibase, extractPublicKeyFromAgentId, } from "./crypto/keys.js";
5
5
  export { fetchAgentCard, extractCandidateKeys, resolveBaseUrl, } from "./discovery/agent-card.js";
6
6
  export { verifyInkAuth, type NonceStore } from "./middleware/ink-auth.js";
7
7
  export { verifyInclusionReceipt, verifyAuditQueryResponse, type InclusionReceipt, type InclusionReceiptVerifyResult, type AuditQueryResponse, type AuditQueryResponseVerifyResult, type VerifyStep, } from "./audit/inclusion-receipt.js";
8
8
  export { HandshakeBudgetTracker } from "./ink/handshake-budget.js";
9
+ export { buildReceipt, shouldSendReceipt, sendReceiptFireAndForget, } from "./ink/receipts.js";
10
+ export { resolveEffectiveTransports, checkTransportAllowed, } from "./ink/transport-auth.js";
11
+ export { buildRedactedCard, shouldRedactOnGet, AgentCardQuerySchema, } from "./ink/discovery-gating.js";
12
+ export { parseCheckpoint, formatCheckpoint, } from "./ink/checkpoint.js";
13
+ export type { CheckpointData } from "./ink/checkpoint.js";
14
+ export { InkAuditEventTypeSchema, InkAuditEventSchema, InkAuditInclusionSchema, InkReceiptSchema, InkAuditQuerySchema, InkIntroductionReceiptSchema, } from "./models/ink-audit.js";
15
+ export type { InkAuditEventType, InkAuditEvent, InkAuditInclusion, InkReceipt, InkAuditQuery, InkAuditResponse, InkIntroductionReceiptStatus, } from "./models/ink-audit.js";
16
+ export { InkChallengeSchema, InkRejectionSchema, InkResolutionSchema, InkTransportSchema, } from "./models/ink-handshake.js";
17
+ export type { AgentCardVisibility, InkChallenge, InkRejection, InkResolution, InkTransport, } from "./models/ink-handshake.js";
18
+ export { AgentCardSchema } from "./models/agent-card.js";
9
19
  export { validateMessage, MessageEnvelopeSchema } from "./models/intent.js";
10
20
  export type { MessageEnvelope } from "./models/intent.js";
11
21
  export type { InkSignInput } from "./crypto/ink.js";
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@
4
4
  export { signInkMessage, verifyInkSignature, buildSignatureBase, buildAuthHeader, computeMessageHash, computeEventHash, computeAuditMerkleLeafHash, signAuditEvent, verifyAuditEventSignature, signAuditResponse, verifyAuditResponseSignature, verifyAuditEventChain, signAuditQueryResponse, verifyAuditQueryResponseSignature, encryptInkPayload, decryptInkPayload, checkReplay, base64urlEncode, base64urlDecode, hexToBytes, bytesToHex, jcsCanonicalize, MAX_TIMESTAMP_AGE_MS, MAX_FUTURE_TIMESTAMP_MS, } from "./crypto/ink.js";
5
5
  export { signMessage, verifyMessage } from "./crypto/sign.js";
6
6
  export { verifyInkSignatureWithKeys } from "./crypto/multi-key-verify.js";
7
- export { generateKeypair, generateEncryptionKeypair, deriveAgentId, encodePublicKeyMultibase, decodePublicKeyMultibase, decodeEncryptionKeyMultibase, extractPublicKeyFromAgentId, } from "./crypto/keys.js";
7
+ export { generateKeypair, generateEncryptionKeypair, deriveAgentId, encodePublicKeyMultibase, encodeEncryptionKeyMultibase, decodePublicKeyMultibase, decodeEncryptionKeyMultibase, extractPublicKeyFromAgentId, } from "./crypto/keys.js";
8
8
  // Discovery: Agent Card fetch + candidate-key extraction
9
9
  export { fetchAgentCard, extractCandidateKeys, resolveBaseUrl, } from "./discovery/agent-card.js";
10
10
  // Middleware: transport-level INK auth
@@ -13,6 +13,20 @@ export { verifyInkAuth } from "./middleware/ink-auth.js";
13
13
  export { verifyInclusionReceipt, verifyAuditQueryResponse, } from "./audit/inclusion-receipt.js";
14
14
  // Optional containment / governance primitives
15
15
  export { HandshakeBudgetTracker } from "./ink/handshake-budget.js";
16
+ // Receipts: build and send INK delivery receipts
17
+ export { buildReceipt, shouldSendReceipt, sendReceiptFireAndForget, } from "./ink/receipts.js";
18
+ // Transport-auth: token-level transport allowlist for extension tokens
19
+ export { resolveEffectiveTransports, checkTransportAllowed, } from "./ink/transport-auth.js";
20
+ // Discovery-gating: visibility-aware Agent Card redaction
21
+ export { buildRedactedCard, shouldRedactOnGet, AgentCardQuerySchema, } from "./ink/discovery-gating.js";
22
+ // Checkpoint parsing for transparency-log signed checkpoints
23
+ export { parseCheckpoint, formatCheckpoint, } from "./ink/checkpoint.js";
24
+ // Audit event schemas + types for receipts, query, inclusion proofs
25
+ export { InkAuditEventTypeSchema, InkAuditEventSchema, InkAuditInclusionSchema, InkReceiptSchema, InkAuditQuerySchema, InkIntroductionReceiptSchema, } from "./models/ink-audit.js";
26
+ // Handshake message schemas
27
+ export { InkChallengeSchema, InkRejectionSchema, InkResolutionSchema, InkTransportSchema, } from "./models/ink-handshake.js";
28
+ // Agent Card schema (the canonical .well-known/ink/agent.json document)
29
+ export { AgentCardSchema } from "./models/agent-card.js";
16
30
  // Envelope validation: full Zod-backed parse of the canonical
17
31
  // MessageEnvelope shape. Adopters building receivers need this to
18
32
  // reject malformed envelopes before signature verification; without
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adastracomputing/ink",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "Library and specification for the INK (Inter-agent Networking Kernel) protocol",
5
5
  "license": "MIT OR Apache-2.0",
6
6
  "author": "Ad Astra Computing Inc.",