@mikeargento/bitgraph-mcp 0.6.0 → 0.7.0
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/dist/__tests__/carrier.test.js +2 -2
- package/dist/__tests__/carrier.test.js.map +1 -1
- package/dist/__tests__/format.test.js +1 -1
- package/dist/__tests__/format.test.js.map +1 -1
- package/dist/__tests__/proof-beside.test.js +1 -1
- package/dist/__tests__/proof-beside.test.js.map +1 -1
- package/dist/__tests__/tools.test.js +1 -1
- package/dist/__tests__/tools.test.js.map +1 -1
- package/dist/format.d.ts +11 -2
- package/dist/format.d.ts.map +1 -1
- package/dist/format.js +1 -2
- package/dist/format.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/instructions.d.ts +2 -0
- package/dist/instructions.d.ts.map +1 -0
- package/dist/instructions.js +9 -0
- package/dist/instructions.js.map +1 -0
- package/dist/server.d.ts +3 -38
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +8 -99
- package/dist/server.js.map +1 -1
- package/package.json +2 -1
- package/src/__tests__/carrier.test.ts +2 -2
- package/src/__tests__/format.test.ts +2 -2
- package/src/__tests__/proof-beside.test.ts +1 -1
- package/src/__tests__/tools.test.ts +1 -1
- package/src/format.ts +1 -3
- package/src/index.ts +1 -1
- package/src/instructions.ts +11 -0
- package/src/server.ts +18 -179
- package/src/__tests__/encoding.test.ts +0 -64
- package/src/__tests__/scan.test.ts +0 -80
- package/src/api.ts +0 -170
- package/src/carrier-io.ts +0 -120
- package/src/encoding.ts +0 -72
- package/src/scan.ts +0 -220
- package/src/task.ts +0 -187
- package/src/types.ts +0 -96
package/src/types.ts
DELETED
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
// Copyright (c) 2024-2026 Argento Computing Inc. Licensed under the MIT License. See LICENSE.
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* @mikeargento/bitgraph-mcp: wire types.
|
|
5
|
-
*
|
|
6
|
-
* Minimal views of the bitgraph/1 schema and the bitgraph.ing API responses.
|
|
7
|
-
* The canonical, fully documented schema lives in @mikeargento/bitgraph-verify.
|
|
8
|
-
* Fields not needed for display are kept as unknown; proofs are passed through
|
|
9
|
-
* verbatim when the caller asks for JSON.
|
|
10
|
-
*/
|
|
11
|
-
|
|
12
|
-
export interface ProofCommit {
|
|
13
|
-
counter?: string;
|
|
14
|
-
epochId?: string;
|
|
15
|
-
time?: number;
|
|
16
|
-
slotCounter?: string;
|
|
17
|
-
[k: string]: unknown;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export interface BitGraphProof {
|
|
21
|
-
version?: string;
|
|
22
|
-
artifact?: { hashAlg?: string; digestB64?: string };
|
|
23
|
-
commit?: ProofCommit;
|
|
24
|
-
signer?: { publicKeyB64?: string; signatureB64?: string };
|
|
25
|
-
environment?: {
|
|
26
|
-
enforcement?: string;
|
|
27
|
-
measurement?: string;
|
|
28
|
-
attestation?: { format?: string; reportB64?: string };
|
|
29
|
-
};
|
|
30
|
-
attribution?: { name?: string; title?: string; message?: string };
|
|
31
|
-
metadata?: unknown;
|
|
32
|
-
proofHash?: string;
|
|
33
|
-
[k: string]: unknown;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/** A set member's row as the site reports it: which row of N these bytes are, and whether as the original or the new file. */
|
|
37
|
-
export interface SetMemberView {
|
|
38
|
-
index: number;
|
|
39
|
-
count: number;
|
|
40
|
-
role?: "origin" | "fused";
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
/** POST /api/proofs/batch response. Keyed by the digest exactly as sent (URL-safe). */
|
|
44
|
-
export interface BatchCheckResponse {
|
|
45
|
-
results: Record<
|
|
46
|
-
string,
|
|
47
|
-
{ proofs: Array<{ proof: BitGraphProof; kind?: "recorded" | "fused"; member?: SetMemberView; setDigest?: string }> }
|
|
48
|
-
>;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
/** POST /api/fuse/set-index response: how many members' evidence the site wrote. */
|
|
52
|
-
export interface SetIndexResponse {
|
|
53
|
-
count?: number;
|
|
54
|
-
written: number;
|
|
55
|
-
failed: number;
|
|
56
|
-
rejected: number;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface AnchorView {
|
|
60
|
-
counter?: string;
|
|
61
|
-
attrName?: string;
|
|
62
|
-
blockNumber?: number | null;
|
|
63
|
-
blockHash?: string | null;
|
|
64
|
-
etherscanUrl?: string | null;
|
|
65
|
-
blockTime?: string | null;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export interface PositionView {
|
|
69
|
-
counter: string | null;
|
|
70
|
-
epoch: string | null;
|
|
71
|
-
lowerTime: string | null;
|
|
72
|
-
upperTime: string | null;
|
|
73
|
-
kind?: "recorded" | "fused";
|
|
74
|
-
placement?: string | null;
|
|
75
|
-
member?: SetMemberView;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
/**
|
|
79
|
-
* GET /api/proofs/digest/{digest} response.
|
|
80
|
-
* causalWindow naming note: anchorBefore is the EARLIER Ethereum block (the
|
|
81
|
-
* proof was BitGraphed after it, the lower time bound); anchorAfter is the
|
|
82
|
-
* LATER block (the upper bound). Present time as "between lower and upper".
|
|
83
|
-
*/
|
|
84
|
-
export interface ProofDetailResponse {
|
|
85
|
-
proofs: Array<{ proof: BitGraphProof }>;
|
|
86
|
-
positions?: PositionView[];
|
|
87
|
-
causalWindow?: { anchorBefore: AnchorView | null; anchorAfter: AnchorView | null } | null;
|
|
88
|
-
anchorBlock?: AnchorView | null;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/** GET /api/search response. */
|
|
92
|
-
export interface SearchResponse {
|
|
93
|
-
found: boolean;
|
|
94
|
-
digest?: string;
|
|
95
|
-
counter?: string | null;
|
|
96
|
-
}
|