@agenticprimitives/agent-naming 1.0.0-alpha.4 → 1.0.0-alpha.41

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.
Files changed (77) hide show
  1. package/AUDIT.md +15 -4
  2. package/CLAUDE.md +40 -53
  3. package/README.md +57 -54
  4. package/dist/abis.d.ts +641 -0
  5. package/dist/abis.d.ts.map +1 -1
  6. package/dist/abis.js +96 -0
  7. package/dist/abis.js.map +1 -1
  8. package/dist/claim.d.ts +71 -0
  9. package/dist/claim.d.ts.map +1 -0
  10. package/dist/claim.js +73 -0
  11. package/dist/claim.js.map +1 -0
  12. package/dist/client.d.ts +36 -1
  13. package/dist/client.d.ts.map +1 -1
  14. package/dist/client.js +197 -10
  15. package/dist/client.js.map +1 -1
  16. package/dist/constants.d.ts +55 -5
  17. package/dist/constants.d.ts.map +1 -1
  18. package/dist/constants.js +128 -4
  19. package/dist/constants.js.map +1 -1
  20. package/dist/custody.d.ts +54 -2
  21. package/dist/custody.d.ts.map +1 -1
  22. package/dist/custody.js +140 -4
  23. package/dist/custody.js.map +1 -1
  24. package/dist/dns.d.ts +91 -0
  25. package/dist/dns.d.ts.map +1 -0
  26. package/dist/dns.js +196 -0
  27. package/dist/dns.js.map +1 -0
  28. package/dist/federated.d.ts +31 -0
  29. package/dist/federated.d.ts.map +1 -0
  30. package/dist/federated.js +54 -0
  31. package/dist/federated.js.map +1 -0
  32. package/dist/grammar.d.ts +62 -0
  33. package/dist/grammar.d.ts.map +1 -0
  34. package/dist/grammar.js +165 -0
  35. package/dist/grammar.js.map +1 -0
  36. package/dist/hash.d.ts +14 -0
  37. package/dist/hash.d.ts.map +1 -0
  38. package/dist/hash.js +22 -0
  39. package/dist/hash.js.map +1 -0
  40. package/dist/index.d.ts +17 -9
  41. package/dist/index.d.ts.map +1 -1
  42. package/dist/index.js +21 -8
  43. package/dist/index.js.map +1 -1
  44. package/dist/issuance.d.ts +70 -0
  45. package/dist/issuance.d.ts.map +1 -0
  46. package/dist/issuance.js +65 -0
  47. package/dist/issuance.js.map +1 -0
  48. package/dist/label.d.ts +10 -0
  49. package/dist/label.d.ts.map +1 -0
  50. package/dist/label.js +39 -0
  51. package/dist/label.js.map +1 -0
  52. package/dist/namehash.d.ts +12 -24
  53. package/dist/namehash.d.ts.map +1 -1
  54. package/dist/namehash.js +13 -36
  55. package/dist/namehash.js.map +1 -1
  56. package/dist/normalize.d.ts +9 -17
  57. package/dist/normalize.d.ts.map +1 -1
  58. package/dist/normalize.js +11 -48
  59. package/dist/normalize.js.map +1 -1
  60. package/dist/price.d.ts +74 -0
  61. package/dist/price.d.ts.map +1 -0
  62. package/dist/price.js +58 -0
  63. package/dist/price.js.map +1 -0
  64. package/dist/records.d.ts +44 -3
  65. package/dist/records.d.ts.map +1 -1
  66. package/dist/records.js +203 -4
  67. package/dist/records.js.map +1 -1
  68. package/dist/types.d.ts +108 -3
  69. package/dist/types.d.ts.map +1 -1
  70. package/dist/vertical.d.ts +43 -0
  71. package/dist/vertical.d.ts.map +1 -0
  72. package/dist/vertical.js +40 -0
  73. package/dist/vertical.js.map +1 -0
  74. package/docs/api.md +15 -3
  75. package/docs/concepts.md +1 -1
  76. package/docs/migration.md +1 -1
  77. package/package.json +24 -15
@@ -1,31 +1,19 @@
1
- import { type Hex } from 'viem';
1
+ import type { Hex } from 'viem';
2
+ import { ZERO_NODE, labelhash } from './hash.js';
3
+ export { ZERO_NODE, labelhash };
2
4
  /**
3
- * Compute the namehash of an agent name (ENS-compatible).
5
+ * Compute the recursive namehash of an agent name
6
+ * (`keccak256(parentNode || labelhash)` convention).
4
7
  *
5
- * namehash('') = 0x00…00
6
- * namehash('agent') = keccak256(namehash('') || labelhash('agent'))
7
- * namehash('alice.acme.agent')
8
- * = keccak256(namehash('acme.agent') || labelhash('alice'))
8
+ * namehash('') = 0x00…00
9
+ * namehash('agent') = keccak256(namehash('') || labelhash('agent'))
10
+ * namehash('alice.acme.agent') = keccak256(namehash('acme.agent') || labelhash('alice'))
11
+ * namehash('vault.svc@richcanvas.org') = namehash('vault.svc.richcanvas.org') (spec 346 §3.3)
9
12
  *
10
- * The hash is computed against the NORMALIZED name (see
11
- * `normalizeAgentName`). Two strings that normalize identically
12
- * produce identical namehashes.
13
+ * The hash is computed over the NORMALIZED dotted on-chain form (`onChainNameOf`), so every accepted
14
+ * rendering of the same name (`@`, path, dotted, `.ws` alias) hashes identically.
13
15
  *
14
- * Throws `InvalidNameError` (via `normalizeAgentName`) on malformed
15
- * input. Passing `''` returns `0x00…00` — the canonical "empty / root"
16
- * sentinel matching the ENS convention.
16
+ * Throws `InvalidNameError` on malformed input. Passing `''` returns `0x00…00`.
17
17
  */
18
18
  export declare function namehash(name: string): Hex;
19
- /**
20
- * Compute the labelhash of a single label.
21
- *
22
- * `labelhash(label)` = keccak256(utf8Bytes(label))
23
- *
24
- * No normalization is applied here — the caller is expected to pass a
25
- * label produced by splitting a normalized name. Pass a non-normalized
26
- * label at your own risk.
27
- */
28
- export declare function labelhash(label: string): Hex;
29
- /** The all-zeros 32-byte sentinel namehash (the root of the tree). */
30
- export declare const ZERO_NODE: Hex;
31
19
  //# sourceMappingURL=namehash.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"namehash.d.ts","sourceRoot":"","sources":["../src/namehash.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoC,KAAK,GAAG,EAAE,MAAM,MAAM,CAAC;AAGlE;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAW1C;AAED;;;;;;;;GAQG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,GAAG,CAE5C;AAED,sEAAsE;AACtE,eAAO,MAAM,SAAS,EAAE,GAA0E,CAAC"}
1
+ {"version":3,"file":"namehash.d.ts","sourceRoot":"","sources":["../src/namehash.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEhC,OAAO,EAAE,SAAS,EAAE,SAAS,EAAgB,MAAM,WAAW,CAAC;AAE/D,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;AAEhC;;;;;;;;;;;;;GAaG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAG1C"}
package/dist/namehash.js CHANGED
@@ -1,46 +1,23 @@
1
- import { keccak256, encodePacked, toBytes } from 'viem';
2
- import { normalizeAgentName } from './normalize';
1
+ import { onChainNameOf } from './grammar.js';
2
+ import { ZERO_NODE, labelhash, nodeOfLabels } from './hash.js';
3
+ export { ZERO_NODE, labelhash };
3
4
  /**
4
- * Compute the namehash of an agent name (ENS-compatible).
5
+ * Compute the recursive namehash of an agent name
6
+ * (`keccak256(parentNode || labelhash)` convention).
5
7
  *
6
- * namehash('') = 0x00…00
7
- * namehash('agent') = keccak256(namehash('') || labelhash('agent'))
8
- * namehash('alice.acme.agent')
9
- * = keccak256(namehash('acme.agent') || labelhash('alice'))
8
+ * namehash('') = 0x00…00
9
+ * namehash('agent') = keccak256(namehash('') || labelhash('agent'))
10
+ * namehash('alice.acme.agent') = keccak256(namehash('acme.agent') || labelhash('alice'))
11
+ * namehash('vault.svc@richcanvas.org') = namehash('vault.svc.richcanvas.org') (spec 346 §3.3)
10
12
  *
11
- * The hash is computed against the NORMALIZED name (see
12
- * `normalizeAgentName`). Two strings that normalize identically
13
- * produce identical namehashes.
13
+ * The hash is computed over the NORMALIZED dotted on-chain form (`onChainNameOf`), so every accepted
14
+ * rendering of the same name (`@`, path, dotted, `.ws` alias) hashes identically.
14
15
  *
15
- * Throws `InvalidNameError` (via `normalizeAgentName`) on malformed
16
- * input. Passing `''` returns `0x00…00` — the canonical "empty / root"
17
- * sentinel matching the ENS convention.
16
+ * Throws `InvalidNameError` on malformed input. Passing `''` returns `0x00…00`.
18
17
  */
19
18
  export function namehash(name) {
20
19
  if (name === '')
21
20
  return ZERO_NODE;
22
- const labels = normalizeAgentName(name).split('.');
23
- let node = ZERO_NODE;
24
- // Walk from rightmost (TLD-side) label inward so the root anchors
25
- // the recursion — same as ENS reference impl.
26
- for (let i = labels.length - 1; i >= 0; i--) {
27
- const lh = labelhash(labels[i]);
28
- node = keccak256(encodePacked(['bytes32', 'bytes32'], [node, lh]));
29
- }
30
- return node;
21
+ return nodeOfLabels(onChainNameOf(name).split('.'));
31
22
  }
32
- /**
33
- * Compute the labelhash of a single label.
34
- *
35
- * `labelhash(label)` = keccak256(utf8Bytes(label))
36
- *
37
- * No normalization is applied here — the caller is expected to pass a
38
- * label produced by splitting a normalized name. Pass a non-normalized
39
- * label at your own risk.
40
- */
41
- export function labelhash(label) {
42
- return keccak256(toBytes(label));
43
- }
44
- /** The all-zeros 32-byte sentinel namehash (the root of the tree). */
45
- export const ZERO_NODE = '0x0000000000000000000000000000000000000000000000000000000000000000';
46
23
  //# sourceMappingURL=namehash.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"namehash.js","sourceRoot":"","sources":["../src/namehash.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,OAAO,EAAY,MAAM,MAAM,CAAC;AAClE,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEjD;;;;;;;;;;;;;;;GAeG;AACH,MAAM,UAAU,QAAQ,CAAC,IAAY;IACnC,IAAI,IAAI,KAAK,EAAE;QAAE,OAAO,SAAS,CAAC;IAClC,MAAM,MAAM,GAAG,kBAAkB,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACnD,IAAI,IAAI,GAAQ,SAAS,CAAC;IAC1B,kEAAkE;IAClE,8CAA8C;IAC9C,KAAK,IAAI,CAAC,GAAG,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC;QAC5C,MAAM,EAAE,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,CAAE,CAAC,CAAC;QACjC,IAAI,GAAG,SAAS,CAAC,YAAY,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;IACrE,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,UAAU,SAAS,CAAC,KAAa;IACrC,OAAO,SAAS,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;AACnC,CAAC;AAED,sEAAsE;AACtE,MAAM,CAAC,MAAM,SAAS,GAAQ,oEAAoE,CAAC"}
1
+ {"version":3,"file":"namehash.js","sourceRoot":"","sources":["../src/namehash.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAE/D,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;AAEhC;;;;;;;;;;;;;GAaG;AACH,MAAM,UAAU,QAAQ,CAAC,IAAY;IACnC,IAAI,IAAI,KAAK,EAAE;QAAE,OAAO,SAAS,CAAC;IAClC,OAAO,YAAY,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;AACtD,CAAC"}
@@ -1,23 +1,15 @@
1
+ export { normalizeLabel } from './label.js';
1
2
  /**
2
- * Normalize an agent name to canonical form.
3
+ * Normalize an agent name to canonical display form (spec 346 §3.1):
3
4
  *
4
- * Phase 1 normalization (US-ASCII subset; spec § 4 normalization
5
- * rules; matches `smart-agent/packages/sdk/src/naming.ts:normalize`
6
- * with stricter label validation):
5
+ * - NFC, trim, lowercase; every label validated (`[a-z0-9-]`, no edge hyphens, ≤ 63).
6
+ * - `.ws` rewritten to `.workspace`.
7
+ * - Scoped / contextual names return the `@` form (`vault.svc@richcanvas.org`), whichever accepted
8
+ * rendering was given (`@`, `c.u/x.t`, or dotted `x.t.c.u`).
9
+ * - Root, type-node and legacy (`.impact` / `.agent`) names return their dotted form.
7
10
  *
8
- * 1. NFC normalize the input.
9
- * 2. Trim outer whitespace.
10
- * 3. Lowercase (`String.prototype.toLowerCase` — note Turkish-i
11
- * edge case; acceptable in Phase 1 since labels are ASCII-only).
12
- * 4. Split on `.`. For each label:
13
- * - Reject empty.
14
- * - Reject leading or trailing `-`.
15
- * - Reject characters outside `[a-z 0-9 -]`.
16
- * - Reject length > 63.
17
- * 5. Return joined.
18
- *
19
- * Throws `InvalidNameError` on any rule violation. Use this BEFORE
20
- * `namehash` so the namehash is computed against the canonical form.
11
+ * Throws `InvalidNameError` on any rule violation. `namehash` hashes the on-chain form of the same
12
+ * parse, so two inputs that normalize identically hash identically.
21
13
  */
22
14
  export declare function normalizeAgentName(name: string): string;
23
15
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"normalize.d.ts","sourceRoot":"","sources":["../src/normalize.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAavD;AAyBD;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAOtD"}
1
+ {"version":3,"file":"normalize.d.ts","sourceRoot":"","sources":["../src/normalize.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE5C;;;;;;;;;;;GAWG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEvD;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAOtD"}
package/dist/normalize.js CHANGED
@@ -1,56 +1,19 @@
1
- import { InvalidNameError } from './errors';
1
+ import { parseAgentName } from './grammar.js';
2
+ export { normalizeLabel } from './label.js';
2
3
  /**
3
- * Normalize an agent name to canonical form.
4
+ * Normalize an agent name to canonical display form (spec 346 §3.1):
4
5
  *
5
- * Phase 1 normalization (US-ASCII subset; spec § 4 normalization
6
- * rules; matches `smart-agent/packages/sdk/src/naming.ts:normalize`
7
- * with stricter label validation):
6
+ * - NFC, trim, lowercase; every label validated (`[a-z0-9-]`, no edge hyphens, ≤ 63).
7
+ * - `.ws` rewritten to `.workspace`.
8
+ * - Scoped / contextual names return the `@` form (`vault.svc@richcanvas.org`), whichever accepted
9
+ * rendering was given (`@`, `c.u/x.t`, or dotted `x.t.c.u`).
10
+ * - Root, type-node and legacy (`.impact` / `.agent`) names return their dotted form.
8
11
  *
9
- * 1. NFC normalize the input.
10
- * 2. Trim outer whitespace.
11
- * 3. Lowercase (`String.prototype.toLowerCase` — note Turkish-i
12
- * edge case; acceptable in Phase 1 since labels are ASCII-only).
13
- * 4. Split on `.`. For each label:
14
- * - Reject empty.
15
- * - Reject leading or trailing `-`.
16
- * - Reject characters outside `[a-z 0-9 -]`.
17
- * - Reject length > 63.
18
- * 5. Return joined.
19
- *
20
- * Throws `InvalidNameError` on any rule violation. Use this BEFORE
21
- * `namehash` so the namehash is computed against the canonical form.
12
+ * Throws `InvalidNameError` on any rule violation. `namehash` hashes the on-chain form of the same
13
+ * parse, so two inputs that normalize identically hash identically.
22
14
  */
23
15
  export function normalizeAgentName(name) {
24
- if (typeof name !== 'string') {
25
- throw new InvalidNameError(String(name), 'must be a string');
26
- }
27
- const trimmed = name.normalize('NFC').trim().toLowerCase();
28
- if (trimmed.length === 0) {
29
- throw new InvalidNameError(name, 'empty');
30
- }
31
- const labels = trimmed.split('.');
32
- for (const label of labels) {
33
- validateLabel(name, label);
34
- }
35
- return labels.join('.');
36
- }
37
- const LABEL_RE = /^[a-z0-9-]+$/;
38
- function validateLabel(fullName, label) {
39
- if (label.length === 0) {
40
- throw new InvalidNameError(fullName, 'empty label (consecutive dots or leading/trailing dot)');
41
- }
42
- if (label.length > 63) {
43
- throw new InvalidNameError(fullName, `label "${label}" exceeds 63 chars`);
44
- }
45
- if (label.startsWith('-')) {
46
- throw new InvalidNameError(fullName, `label "${label}" starts with hyphen`);
47
- }
48
- if (label.endsWith('-')) {
49
- throw new InvalidNameError(fullName, `label "${label}" ends with hyphen`);
50
- }
51
- if (!LABEL_RE.test(label)) {
52
- throw new InvalidNameError(fullName, `label "${label}" contains characters outside [a-z 0-9 -]`);
53
- }
16
+ return parseAgentName(name).normalized;
54
17
  }
55
18
  /**
56
19
  * Predicate variant — returns true / false instead of throwing.
@@ -1 +1 @@
1
- {"version":3,"file":"normalize.js","sourceRoot":"","sources":["../src/normalize.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,UAAU,kBAAkB,CAAC,IAAY;IAC7C,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;QAC7B,MAAM,IAAI,gBAAgB,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,kBAAkB,CAAC,CAAC;IAC/D,CAAC;IACD,MAAM,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;IAC3D,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACzB,MAAM,IAAI,gBAAgB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC5C,CAAC;IACD,MAAM,MAAM,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAClC,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC3B,aAAa,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IAC7B,CAAC;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC1B,CAAC;AAED,MAAM,QAAQ,GAAG,cAAc,CAAC;AAEhC,SAAS,aAAa,CAAC,QAAgB,EAAE,KAAa;IACpD,IAAI,KAAK,CAAC,MAAM,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AACH,MAAM,UAAU,gBAAgB,CAAC,IAAY;IAC3C,IAAI,CAAC;QACH,kBAAkB,CAAC,IAAI,CAAC,CAAC;QACzB,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC"}
@@ -0,0 +1,74 @@
1
+ import { type Address, type Hex } from 'viem';
2
+ import type { ContractCall } from './custody.js';
3
+ /** Base price by ending, in whole coins. The ending names the type; a person's and an organization's cost the most. */
4
+ export declare const NAME_PRICE_BASE: Readonly<Record<string, number>>;
5
+ /** Multiplier by label length (×10, as the contract stores it): 3 → ×4, 4 → ×3, 5 → ×2, 6–7 → ×1.5, 8+ → ×1. */
6
+ export declare const NAME_PRICE_MULTIPLIERS_X10: readonly [number, number, number, number, number];
7
+ /** Nothing costs this much or more. */
8
+ export declare const NAME_PRICE_CAP = 49;
9
+ export declare const NAME_PRICE_MIN_LABEL = 3;
10
+ /** What `label.tld` costs, in whole coins, or `null` for an ending that is not priced (a legacy root, a scoped name). */
11
+ export declare function priceOf(label: string, tld: string): number | null;
12
+ /** Whole coins → the coin's base units (Sheqel has six decimals). */
13
+ export declare const toCoinUnits: (coins: number, decimals?: number) => bigint;
14
+ /**
15
+ * A claim ticket (spec 431 §4): what an estate's naming GATE signs so the priced subregistry will take a claim.
16
+ * `domain` is the keccak of the domain the gate vouched for (`ibm.com`), or the zero hash for an unprotected label.
17
+ * The gate never puts an email on the chain — only the domain, as a hash.
18
+ */
19
+ export interface ClaimTicketV1 {
20
+ parentNode: Hex;
21
+ label: string;
22
+ owner: Address;
23
+ payer: Address;
24
+ /** In the coin's base units. */
25
+ price: bigint;
26
+ domain: Hex;
27
+ expiry: bigint;
28
+ nonce: Hex;
29
+ }
30
+ export declare const CLAIM_TICKET_TYPES: {
31
+ readonly ClaimTicket: readonly [{
32
+ readonly name: "parentNode";
33
+ readonly type: "bytes32";
34
+ }, {
35
+ readonly name: "label";
36
+ readonly type: "string";
37
+ }, {
38
+ readonly name: "owner";
39
+ readonly type: "address";
40
+ }, {
41
+ readonly name: "payer";
42
+ readonly type: "address";
43
+ }, {
44
+ readonly name: "price";
45
+ readonly type: "uint256";
46
+ }, {
47
+ readonly name: "domain";
48
+ readonly type: "bytes32";
49
+ }, {
50
+ readonly name: "expiry";
51
+ readonly type: "uint256";
52
+ }, {
53
+ readonly name: "nonce";
54
+ readonly type: "bytes32";
55
+ }];
56
+ };
57
+ /** The EIP-712 domain of a `PricedSubregistry` instance — what the gate signs the ticket under. */
58
+ export declare function claimTicketDomain(chainId: number, subregistry: Address): {
59
+ name: 'PricedSubregistry';
60
+ version: '1';
61
+ chainId: number;
62
+ verifyingContract: Address;
63
+ };
64
+ /**
65
+ * The two calls the PAYER (the person's treasury agent) makes in one user operation: approve the fee, then claim.
66
+ * The treasury signs the operation through its own custody; the name is registered to `ticket.owner` (spec 431 §4 step 5).
67
+ */
68
+ export declare function buildPricedClaimCalls(input: {
69
+ subregistry: Address;
70
+ coin: Address;
71
+ ticket: ClaimTicketV1;
72
+ gateSignature: Hex;
73
+ }): ContractCall[];
74
+ //# sourceMappingURL=price.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"price.d.ts","sourceRoot":"","sources":["../src/price.ts"],"names":[],"mappings":"AAKA,OAAO,EAAsB,KAAK,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,MAAM,CAAC;AAElE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAEjD,uHAAuH;AACvH,eAAO,MAAM,eAAe,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAE5D,CAAC;AAEF,gHAAgH;AAChH,eAAO,MAAM,0BAA0B,EAAE,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAwB,CAAC;AAElH,uCAAuC;AACvC,eAAO,MAAM,cAAc,KAAK,CAAC;AAEjC,eAAO,MAAM,oBAAoB,IAAI,CAAC;AAEtC,yHAAyH;AACzH,wBAAgB,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAOjE;AAED,qEAAqE;AACrE,eAAO,MAAM,WAAW,UAAW,MAAM,wBAAiB,MAAiD,CAAC;AAE5G;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,GAAG,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,OAAO,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;IACf,gCAAgC;IAChC,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,GAAG,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,GAAG,CAAC;CACZ;AAED,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;CAWrB,CAAC;AAEX,mGAAmG;AACnG,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,GAAG;IAAE,IAAI,EAAE,mBAAmB,CAAC;IAAC,OAAO,EAAE,GAAG,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,iBAAiB,EAAE,OAAO,CAAA;CAAE,CAEjK;AAID;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE;IAAE,WAAW,EAAE,OAAO,CAAC;IAAC,IAAI,EAAE,OAAO,CAAC;IAAC,MAAM,EAAE,aAAa,CAAC;IAAC,aAAa,EAAE,GAAG,CAAA;CAAE,GAAG,YAAY,EAAE,CAM/I"}
package/dist/price.js ADDED
@@ -0,0 +1,58 @@
1
+ // The price of a name (spec 431 §2) — one pure function, the same numbers as `PricedSubregistry.priceOf` on chain,
2
+ // so the Home, the naming service and the contract never disagree. Prices are whole coins; the chain holds them in
3
+ // the coin's base units (`toCoinUnits`).
4
+ //
5
+ // A price is a product mechanism on a test coin, not a market: no rent, no expiry, no resale (spec 431 D6).
6
+ import { encodeFunctionData } from 'viem';
7
+ import { pricedSubregistryAbi } from './abis.js';
8
+ /** Base price by ending, in whole coins. The ending names the type; a person's and an organization's cost the most. */
9
+ export const NAME_PRICE_BASE = {
10
+ me: 8, org: 12, church: 6, team: 6, svc: 10, registry: 20, workspace: 4, treasury: 4, circle: 4, household: 4,
11
+ };
12
+ /** Multiplier by label length (×10, as the contract stores it): 3 → ×4, 4 → ×3, 5 → ×2, 6–7 → ×1.5, 8+ → ×1. */
13
+ export const NAME_PRICE_MULTIPLIERS_X10 = [40, 30, 20, 15, 15];
14
+ /** Nothing costs this much or more. */
15
+ export const NAME_PRICE_CAP = 49;
16
+ export const NAME_PRICE_MIN_LABEL = 3;
17
+ /** What `label.tld` costs, in whole coins, or `null` for an ending that is not priced (a legacy root, a scoped name). */
18
+ export function priceOf(label, tld) {
19
+ const base = NAME_PRICE_BASE[tld];
20
+ if (base === undefined)
21
+ return null;
22
+ const len = label.length;
23
+ if (len < NAME_PRICE_MIN_LABEL)
24
+ throw new Error(`a label needs ${NAME_PRICE_MIN_LABEL} characters or more`);
25
+ const x10 = len >= 8 ? 10 : NAME_PRICE_MULTIPLIERS_X10[len - 3];
26
+ return Math.min(NAME_PRICE_CAP, Math.floor((base * x10) / 10));
27
+ }
28
+ /** Whole coins → the coin's base units (Sheqel has six decimals). */
29
+ export const toCoinUnits = (coins, decimals = 6) => BigInt(coins) * 10n ** BigInt(decimals);
30
+ export const CLAIM_TICKET_TYPES = {
31
+ ClaimTicket: [
32
+ { name: 'parentNode', type: 'bytes32' },
33
+ { name: 'label', type: 'string' },
34
+ { name: 'owner', type: 'address' },
35
+ { name: 'payer', type: 'address' },
36
+ { name: 'price', type: 'uint256' },
37
+ { name: 'domain', type: 'bytes32' },
38
+ { name: 'expiry', type: 'uint256' },
39
+ { name: 'nonce', type: 'bytes32' },
40
+ ],
41
+ };
42
+ /** The EIP-712 domain of a `PricedSubregistry` instance — what the gate signs the ticket under. */
43
+ export function claimTicketDomain(chainId, subregistry) {
44
+ return { name: 'PricedSubregistry', version: '1', chainId, verifyingContract: subregistry };
45
+ }
46
+ const ERC20_APPROVE_ABI = [{ type: 'function', name: 'approve', stateMutability: 'nonpayable', inputs: [{ name: 'spender', type: 'address' }, { name: 'amount', type: 'uint256' }], outputs: [{ name: '', type: 'bool' }] }];
47
+ /**
48
+ * The two calls the PAYER (the person's treasury agent) makes in one user operation: approve the fee, then claim.
49
+ * The treasury signs the operation through its own custody; the name is registered to `ticket.owner` (spec 431 §4 step 5).
50
+ */
51
+ export function buildPricedClaimCalls(input) {
52
+ const { subregistry, coin, ticket, gateSignature } = input;
53
+ return [
54
+ { to: coin, value: 0n, data: encodeFunctionData({ abi: ERC20_APPROVE_ABI, functionName: 'approve', args: [subregistry, ticket.price] }) },
55
+ { to: subregistry, value: 0n, data: encodeFunctionData({ abi: pricedSubregistryAbi, functionName: 'claim', args: [ticket, gateSignature] }) },
56
+ ];
57
+ }
58
+ //# sourceMappingURL=price.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"price.js","sourceRoot":"","sources":["../src/price.ts"],"names":[],"mappings":"AAAA,mHAAmH;AACnH,mHAAmH;AACnH,yCAAyC;AACzC,EAAE;AACF,4GAA4G;AAC5G,OAAO,EAAE,kBAAkB,EAA0B,MAAM,MAAM,CAAC;AAClE,OAAO,EAAE,oBAAoB,EAAE,MAAM,WAAW,CAAC;AAGjD,uHAAuH;AACvH,MAAM,CAAC,MAAM,eAAe,GAAqC;IAC/D,EAAE,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,SAAS,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC;CAC9G,CAAC;AAEF,gHAAgH;AAChH,MAAM,CAAC,MAAM,0BAA0B,GAAsD,CAAC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K,EAAE,EAAE,EAAE,IAAI,EAAE,kBAAkB,CAAC,EAAE,GAAG,EAAE,oBAAoB,EAAE,YAAY,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,MAAM,EAAE,aAAa,CAAC,EAAE,CAAC,EAAE;KAC9I,CAAC;AACJ,CAAC"}
package/dist/records.d.ts CHANGED
@@ -16,8 +16,9 @@
16
16
  * - `agentKind`, `metadataHash`,
17
17
  * `passkeyCredentialDigest` → on-chain `bytes32`
18
18
  * - `displayName`, `a2aEndpoint`,
19
- * `mcpEndpoint`, `metadataUri`,
20
- * `nativeId` → on-chain `string`
19
+ * `mcpEndpoint`, `appContext`, `orgRole`,
20
+ * `serviceUrl`, `siteUrl`, `description`,
21
+ * `metadataUri`, `nativeId` → on-chain `string`
21
22
  *
22
23
  * The encoder routes each predicate to its typed setter; the decoder
23
24
  * routes each predicate to its typed getter. Unknown predicates are
@@ -25,25 +26,48 @@
25
26
  * predicates (fail-loud on write).
26
27
  */
27
28
  import { type Hex } from 'viem';
28
- import type { AgentKind, AgentNameRecords } from './types';
29
+ import type { DerivedAgentType } from '@agenticprimitives/types';
30
+ import type { AgentKind, AgentNameRecords, ConnectionKind } from './types.js';
29
31
  export declare const PREDICATE_ID: {
30
32
  readonly addr: `0x${string}`;
31
33
  readonly agentKind: `0x${string}`;
32
34
  readonly displayName: `0x${string}`;
33
35
  readonly a2aEndpoint: `0x${string}`;
34
36
  readonly mcpEndpoint: `0x${string}`;
37
+ readonly appContext: `0x${string}`;
38
+ readonly orgRole: `0x${string}`;
39
+ readonly serviceUrl: `0x${string}`;
40
+ readonly siteUrl: `0x${string}`;
41
+ readonly description: `0x${string}`;
35
42
  readonly metadataUri: `0x${string}`;
36
43
  readonly metadataHash: `0x${string}`;
37
44
  readonly passkeyCredentialDigest: `0x${string}`;
38
45
  readonly custodyPolicy: `0x${string}`;
39
46
  readonly nativeId: `0x${string}`;
47
+ readonly connectionKind: `0x${string}`;
48
+ readonly connectionAddress: `0x${string}`;
49
+ readonly agentType: `0x${string}`;
50
+ readonly serviceRole: `0x${string}`;
51
+ readonly agentSubtype: `0x${string}`;
52
+ readonly cardDigest: `0x${string}`;
53
+ readonly cardUri: `0x${string}`;
54
+ readonly accounts: `0x${string}`;
55
+ readonly clientKeys: `0x${string}`;
40
56
  };
41
57
  export type PredicateName = keyof typeof PREDICATE_ID;
42
58
  export declare const AGENT_KIND_ID: Record<AgentKind, Hex>;
59
+ export declare const AGENT_TYPE_ID: Record<DerivedAgentType, Hex>;
60
+ export declare function encodeAgentType(value: DerivedAgentType): Hex;
61
+ export declare function decodeAgentType(id: Hex): DerivedAgentType | undefined;
62
+ export declare const CONNECTION_KIND_ID: Record<ConnectionKind, Hex>;
43
63
  /** `keccak256("atl:AgentName")` — the ShapeRegistry class id. */
44
64
  export declare const CLASS_AGENT_NAME: Hex;
45
65
  /** `keccak256("atl:AgentKindEnum")` — the enum-set id bound to `atl:agentKind`. */
46
66
  export declare const AGENT_KIND_ENUM: Hex;
67
+ /** `keccak256("atl:ConnectionKindEnum")` — the enum-set id bound to `atl:connectionKind`. */
68
+ export declare const CONNECTION_KIND_ENUM: Hex;
69
+ /** `keccak256("atl:AgentTypeEnum")` — the enum-set id bound to `atl:agentType` (spec 346). */
70
+ export declare const AGENT_TYPE_ENUM: Hex;
47
71
  /**
48
72
  * Phase 1 CAIP-10 namespace allowlist for `nativeId`. Strict on
49
73
  * encode (validate-at-write), permissive on decode (forward-compat).
@@ -58,6 +82,10 @@ export type EncodedRecord = {
58
82
  predicate: Hex;
59
83
  datatype: 'string';
60
84
  value: string;
85
+ } | {
86
+ predicate: Hex;
87
+ datatype: 'string[]';
88
+ value: string[];
61
89
  } | {
62
90
  predicate: Hex;
63
91
  datatype: 'address';
@@ -83,6 +111,19 @@ export interface DecodeInput {
83
111
  strings: Partial<Record<Hex, string>>;
84
112
  addresses: Partial<Record<Hex, `0x${string}`>>;
85
113
  bytes32s: Partial<Record<Hex, Hex>>;
114
+ /** `string[]` predicates (`getStringArr`); optional so older readers decode unchanged. */
115
+ stringArrs?: Partial<Record<Hex, string[]>>;
86
116
  }
87
117
  export declare function decodeRecords(input: DecodeInput): AgentNameRecords;
118
+ export declare function decodeAgentKind(id: Hex): AgentKind | undefined;
119
+ /**
120
+ * Validate-at-write for `atl:accounts`: every entry a CAIP-10 id under the allowlist (ADR-0008), at most ONE
121
+ * per CAIP-2 chain (a name has one account per chain, as ENSIP-9 has one address per coin type), eip155
122
+ * addresses lower-cased, the list sorted by chain so two owners writing the same set write the same bytes.
123
+ */
124
+ export declare function encodeAccounts(accounts: readonly string[]): string[];
125
+ /** Permissive on decode (forward-compat): keep well-formed entries, drop the rest. */
126
+ export declare function decodeAccounts(values: readonly string[]): string[];
127
+ /** The account a name resolves to on one chain (`eip155:8453`), or null when the name has none there. */
128
+ export declare function accountForChain(records: Pick<AgentNameRecords, 'accounts' | 'nativeId'>, chain: string): string | null;
88
129
  //# sourceMappingURL=records.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"records.d.ts","sourceRoot":"","sources":["../src/records.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AAEH,OAAO,EAAoB,KAAK,GAAG,EAAE,MAAM,MAAM,CAAC;AAClD,OAAO,KAAK,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAa3D,eAAO,MAAM,YAAY;;;;;;;;;;;CAWf,CAAC;AAEX,MAAM,MAAM,aAAa,GAAG,MAAM,OAAO,YAAY,CAAC;AAItD,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,SAAS,EAAE,GAAG,CAIhD,CAAC;AAUF,iEAAiE;AACjE,eAAO,MAAM,gBAAgB,EAAE,GAA8B,CAAC;AAC9D,mFAAmF;AACnF,eAAO,MAAM,eAAe,EAAE,GAAkC,CAAC;AAIjE;;;GAGG;AACH,eAAO,MAAM,0BAA0B,EAAE,WAAW,CAAC,MAAM,CAIzD,CAAC;AAMH;;;;GAIG;AACH,M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