@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.
- package/package.json +3 -2
- package/README.md +0 -130
- package/dist/agentshield-api/endpoints.d.ts +0 -21
- package/dist/agentshield-api/endpoints.js +0 -20
- package/dist/agentshield-api/index.d.ts +0 -5
- package/dist/agentshield-api/index.js +0 -27
- package/dist/agentshield-api/schemas.d.ts +0 -9846
- package/dist/agentshield-api/schemas.js +0 -92
- package/dist/agentshield-api/types.d.ts +0 -92
- package/dist/agentshield-api/types.js +0 -12
- package/dist/cli.d.ts +0 -375
- package/dist/cli.js +0 -109
- package/dist/config/base.d.ts +0 -19
- package/dist/config/base.js +0 -2
- package/dist/config/delegation.d.ts +0 -46
- package/dist/config/delegation.js +0 -2
- package/dist/config/identity.d.ts +0 -22
- package/dist/config/identity.js +0 -2
- package/dist/config/index.d.ts +0 -17
- package/dist/config/index.js +0 -2
- package/dist/config/proofing.d.ts +0 -26
- package/dist/config/proofing.js +0 -2
- package/dist/config/tool-protection.d.ts +0 -36
- package/dist/config/tool-protection.js +0 -2
- package/dist/delegation/constraints.d.ts +0 -726
- package/dist/delegation/constraints.js +0 -103
- package/dist/delegation/index.d.ts +0 -2
- package/dist/delegation/index.js +0 -18
- package/dist/delegation/schemas.d.ts +0 -8042
- package/dist/delegation/schemas.js +0 -232
- package/dist/did/index.d.ts +0 -3
- package/dist/did/index.js +0 -19
- package/dist/did/resolve-contract.d.ts +0 -53
- package/dist/did/resolve-contract.js +0 -12
- package/dist/did/schemas.d.ts +0 -33
- package/dist/did/schemas.js +0 -80
- package/dist/did/types.d.ts +0 -38
- package/dist/did/types.js +0 -37
- package/dist/env/constants.d.ts +0 -13
- package/dist/env/constants.js +0 -15
- package/dist/env/index.d.ts +0 -1
- package/dist/env/index.js +0 -17
- package/dist/handshake.d.ts +0 -138
- package/dist/handshake.js +0 -50
- package/dist/index.d.ts +0 -11
- package/dist/index.js +0 -28
- package/dist/proof/index.d.ts +0 -2
- package/dist/proof/index.js +0 -18
- package/dist/proof/proof-record.d.ts +0 -728
- package/dist/proof/proof-record.js +0 -60
- package/dist/proof/signing-spec.d.ts +0 -73
- package/dist/proof/signing-spec.js +0 -52
- package/dist/proof.d.ts +0 -378
- package/dist/proof.js +0 -59
- package/dist/registry.d.ts +0 -326
- package/dist/registry.js +0 -98
- package/dist/runtime/errors.d.ts +0 -179
- package/dist/runtime/errors.js +0 -51
- package/dist/runtime/headers.d.ts +0 -34
- package/dist/runtime/headers.js +0 -52
- package/dist/runtime/index.d.ts +0 -2
- package/dist/runtime/index.js +0 -18
- package/dist/test.d.ts +0 -215
- package/dist/test.js +0 -83
- package/dist/tlkrc/index.d.ts +0 -1
- package/dist/tlkrc/index.js +0 -17
- package/dist/tlkrc/rotation.d.ts +0 -168
- package/dist/tlkrc/rotation.js +0 -55
- package/dist/tool-protection/index.d.ts +0 -129
- package/dist/tool-protection/index.js +0 -80
- package/dist/utils/validation.d.ts +0 -14
- package/dist/utils/validation.js +0 -56
- package/dist/vc/index.d.ts +0 -2
- package/dist/vc/index.js +0 -18
- package/dist/vc/schemas.d.ts +0 -1888
- package/dist/vc/schemas.js +0 -116
- package/dist/vc/statuslist.d.ts +0 -292
- package/dist/vc/statuslist.js +0 -61
- package/dist/verifier.d.ts +0 -202
- package/dist/verifier.js +0 -76
- package/dist/well-known/index.d.ts +0 -248
- package/dist/well-known/index.js +0 -104
package/dist/config/base.js
DELETED
|
@@ -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,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
|
-
}
|
package/dist/config/identity.js
DELETED
package/dist/config/index.d.ts
DELETED
|
@@ -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
|
-
}
|
package/dist/config/index.js
DELETED
|
@@ -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
|
-
}
|
package/dist/config/proofing.js
DELETED
|
@@ -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
|
-
}
|