@kya-os/contracts 1.3.3 → 1.3.4

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 (82) hide show
  1. package/package.json +3 -2
  2. package/README.md +0 -130
  3. package/dist/agentshield-api/endpoints.d.ts +0 -21
  4. package/dist/agentshield-api/endpoints.js +0 -20
  5. package/dist/agentshield-api/index.d.ts +0 -5
  6. package/dist/agentshield-api/index.js +0 -27
  7. package/dist/agentshield-api/schemas.d.ts +0 -9846
  8. package/dist/agentshield-api/schemas.js +0 -92
  9. package/dist/agentshield-api/types.d.ts +0 -92
  10. package/dist/agentshield-api/types.js +0 -12
  11. package/dist/cli.d.ts +0 -375
  12. package/dist/cli.js +0 -109
  13. package/dist/config/base.d.ts +0 -19
  14. package/dist/config/base.js +0 -2
  15. package/dist/config/delegation.d.ts +0 -46
  16. package/dist/config/delegation.js +0 -2
  17. package/dist/config/identity.d.ts +0 -22
  18. package/dist/config/identity.js +0 -2
  19. package/dist/config/index.d.ts +0 -17
  20. package/dist/config/index.js +0 -2
  21. package/dist/config/proofing.d.ts +0 -26
  22. package/dist/config/proofing.js +0 -2
  23. package/dist/config/tool-protection.d.ts +0 -36
  24. package/dist/config/tool-protection.js +0 -2
  25. package/dist/delegation/constraints.d.ts +0 -726
  26. package/dist/delegation/constraints.js +0 -103
  27. package/dist/delegation/index.d.ts +0 -2
  28. package/dist/delegation/index.js +0 -18
  29. package/dist/delegation/schemas.d.ts +0 -8042
  30. package/dist/delegation/schemas.js +0 -232
  31. package/dist/did/index.d.ts +0 -3
  32. package/dist/did/index.js +0 -19
  33. package/dist/did/resolve-contract.d.ts +0 -53
  34. package/dist/did/resolve-contract.js +0 -12
  35. package/dist/did/schemas.d.ts +0 -33
  36. package/dist/did/schemas.js +0 -80
  37. package/dist/did/types.d.ts +0 -38
  38. package/dist/did/types.js +0 -37
  39. package/dist/env/constants.d.ts +0 -13
  40. package/dist/env/constants.js +0 -15
  41. package/dist/env/index.d.ts +0 -1
  42. package/dist/env/index.js +0 -17
  43. package/dist/handshake.d.ts +0 -138
  44. package/dist/handshake.js +0 -50
  45. package/dist/index.d.ts +0 -11
  46. package/dist/index.js +0 -28
  47. package/dist/proof/index.d.ts +0 -2
  48. package/dist/proof/index.js +0 -18
  49. package/dist/proof/proof-record.d.ts +0 -728
  50. package/dist/proof/proof-record.js +0 -60
  51. package/dist/proof/signing-spec.d.ts +0 -73
  52. package/dist/proof/signing-spec.js +0 -52
  53. package/dist/proof.d.ts +0 -378
  54. package/dist/proof.js +0 -59
  55. package/dist/registry.d.ts +0 -326
  56. package/dist/registry.js +0 -98
  57. package/dist/runtime/errors.d.ts +0 -179
  58. package/dist/runtime/errors.js +0 -51
  59. package/dist/runtime/headers.d.ts +0 -34
  60. package/dist/runtime/headers.js +0 -52
  61. package/dist/runtime/index.d.ts +0 -2
  62. package/dist/runtime/index.js +0 -18
  63. package/dist/test.d.ts +0 -215
  64. package/dist/test.js +0 -83
  65. package/dist/tlkrc/index.d.ts +0 -1
  66. package/dist/tlkrc/index.js +0 -17
  67. package/dist/tlkrc/rotation.d.ts +0 -168
  68. package/dist/tlkrc/rotation.js +0 -55
  69. package/dist/tool-protection/index.d.ts +0 -129
  70. package/dist/tool-protection/index.js +0 -80
  71. package/dist/utils/validation.d.ts +0 -14
  72. package/dist/utils/validation.js +0 -56
  73. package/dist/vc/index.d.ts +0 -2
  74. package/dist/vc/index.js +0 -18
  75. package/dist/vc/schemas.d.ts +0 -1888
  76. package/dist/vc/schemas.js +0 -116
  77. package/dist/vc/statuslist.d.ts +0 -292
  78. package/dist/vc/statuslist.js +0 -61
  79. package/dist/verifier.d.ts +0 -202
  80. package/dist/verifier.js +0 -76
  81. package/dist/well-known/index.d.ts +0 -248
  82. package/dist/well-known/index.js +0 -104
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,46 +0,0 @@
1
- export type DelegationVerifierType = 'agentshield' | 'kta' | 'memory' | 'cloudflare-kv' | 'redis' | 'dynamodb' | 'custom';
2
- export interface DelegationVerifierConfig {
3
- type: DelegationVerifierType;
4
- apiUrl?: string;
5
- apiKey?: string;
6
- cacheTtl?: number;
7
- customVerifier?: {
8
- verify: (agentDid: string, scopes: string[]) => Promise<boolean>;
9
- invalidate?: (agentDid: string) => Promise<void>;
10
- };
11
- options?: Record<string, unknown>;
12
- }
13
- export interface AuthorizationConfig {
14
- authorizationUrl?: string;
15
- kta?: {
16
- apiUrl: string;
17
- apiKey?: string;
18
- };
19
- minReputationScore?: number;
20
- resumeTokenTtl?: number;
21
- requireAuthForUnknown?: boolean;
22
- buildAuthUrl?: (toolName: string, scopes: string[], context: any) => string;
23
- }
24
- export interface DelegationConfig {
25
- enabled: boolean;
26
- enforceDelegations?: boolean;
27
- verifier: DelegationVerifierConfig;
28
- authorization?: AuthorizationConfig;
29
- debug?: boolean;
30
- }
31
- export interface DelegationRecord {
32
- id: string;
33
- userId: string;
34
- agentDid: string;
35
- scopes: string[];
36
- createdAt: string;
37
- expiresAt?: string;
38
- revoked?: boolean;
39
- constraints?: {
40
- allowedIps?: string[];
41
- allowedOrigins?: string[];
42
- maxUses?: number;
43
- currentUses?: number;
44
- [key: string]: unknown;
45
- };
46
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,22 +0,0 @@
1
- export interface RuntimeIdentityConfig {
2
- enabled: boolean;
3
- environment: 'development' | 'production';
4
- production?: {
5
- privateKeyEnv?: string;
6
- publicKeyEnv?: string;
7
- didEnv?: string;
8
- };
9
- privacyMode?: boolean;
10
- debug?: boolean;
11
- }
12
- export interface AgentIdentity {
13
- did: string;
14
- publicKey: string;
15
- privateKey: string;
16
- createdAt: string;
17
- metadata?: {
18
- name?: string;
19
- version?: string;
20
- [key: string]: unknown;
21
- };
22
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,17 +0,0 @@
1
- import type { MCPIBaseConfig } from './base.js';
2
- import type { RuntimeIdentityConfig } from './identity.js';
3
- import type { ProofingConfig } from './proofing.js';
4
- import type { DelegationConfig } from './delegation.js';
5
- import type { ToolProtectionSourceConfig } from './tool-protection.js';
6
- export { MCPIBaseConfig } from './base.js';
7
- export { RuntimeIdentityConfig, AgentIdentity } from './identity.js';
8
- export type IdentityConfig = RuntimeIdentityConfig;
9
- export { ProofingConfig, ProofBatchQueueConfig, ProofDestination, ProofDestinationType } from './proofing.js';
10
- export { DelegationConfig, DelegationVerifierConfig, DelegationVerifierType, AuthorizationConfig, DelegationRecord } from './delegation.js';
11
- export { ToolProtection, ToolProtectionMap, ToolProtectionSourceConfig, ToolProtectionSourceType, ToolProtectionServiceConfig, DelegationRequiredErrorData, ToolProtectionResponse } from './tool-protection.js';
12
- export interface MCPIConfig extends MCPIBaseConfig {
13
- identity?: RuntimeIdentityConfig;
14
- proofing?: ProofingConfig;
15
- delegation?: DelegationConfig;
16
- toolProtection?: ToolProtectionSourceConfig;
17
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,26 +0,0 @@
1
- export type ProofDestinationType = 'agentshield' | 'kta' | 'custom';
2
- export interface ProofDestination {
3
- type: ProofDestinationType;
4
- apiUrl?: string;
5
- apiKey?: string;
6
- submit?: (proofs: any[]) => Promise<void>;
7
- options?: Record<string, unknown>;
8
- }
9
- export interface ProofBatchQueueConfig {
10
- destinations: ProofDestination[];
11
- maxBatchSize?: number;
12
- flushIntervalMs?: number;
13
- maxRetries?: number;
14
- retryBackoff?: number;
15
- debug?: boolean;
16
- }
17
- export interface ProofingConfig {
18
- enabled: boolean;
19
- batchQueue?: ProofBatchQueueConfig;
20
- includeMetadata?: boolean;
21
- options?: {
22
- includeTimestamp?: boolean;
23
- includeSession?: boolean;
24
- customFields?: Record<string, unknown>;
25
- };
26
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,36 +0,0 @@
1
- import type { ToolProtection as BaseToolProtection, ToolProtectionMap as BaseToolProtectionMap, DelegationRequiredErrorData as BaseDelegationRequiredErrorData, ToolProtectionResponse as BaseToolProtectionResponse } from '../tool-protection/index.js';
2
- export type ToolProtection = BaseToolProtection;
3
- export type ToolProtectionMap = BaseToolProtectionMap;
4
- export type DelegationRequiredErrorData = BaseDelegationRequiredErrorData;
5
- export type ToolProtectionResponse = BaseToolProtectionResponse;
6
- export type ToolProtectionSourceType = 'inline' | 'local' | 'agentshield' | 'kta' | 'multi';
7
- export interface ToolProtectionSourceConfig {
8
- source: ToolProtectionSourceType;
9
- inline?: BaseToolProtectionMap;
10
- localFile?: string;
11
- agentShield?: {
12
- apiUrl: string;
13
- apiKey?: string;
14
- projectId?: string;
15
- cacheTtl?: number;
16
- };
17
- kta?: {
18
- apiUrl: string;
19
- apiKey?: string;
20
- };
21
- sources?: Array<{
22
- config: Omit<ToolProtectionSourceConfig, 'source' | 'sources'>;
23
- priority?: number;
24
- exclusive?: boolean;
25
- }>;
26
- fallback?: BaseToolProtectionMap;
27
- debug?: boolean;
28
- }
29
- export interface ToolProtectionServiceConfig {
30
- apiUrl: string;
31
- apiKey: string;
32
- projectId?: string;
33
- cacheTtl?: number;
34
- fallbackConfig?: BaseToolProtectionMap;
35
- debug?: boolean;
36
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });