import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf"; import { Message, proto3 } from "@bufbuild/protobuf"; /** * EncryptionMetadata contains metadata for consensus-based encryption * * @generated from message dwn.v1.EncryptionMetadata */ export declare class EncryptionMetadata extends Message { /** * Encryption algorithm used (e.g., "AES-256-GCM") * * @generated from field: string algorithm = 1; */ algorithm: string; /** * Input used for VRF consensus key derivation * * @generated from field: bytes consensus_input = 2; */ consensusInput: Uint8Array; /** * Nonce used for encryption * * @generated from field: bytes nonce = 3; */ nonce: Uint8Array; /** * Authentication tag from AES-GCM * * @generated from field: bytes auth_tag = 4; */ authTag: Uint8Array; /** * Block height when encryption was performed * * @generated from field: int64 encryption_height = 5; */ encryptionHeight: bigint; /** * Validator set participating in consensus * * @generated from field: repeated string validator_set = 6; */ validatorSet: string[]; /** * Key rotation version * * @generated from field: uint64 key_version = 7; */ keyVersion: bigint; /** * Single node development mode flag * * @generated from field: bool single_node_mode = 8; */ singleNodeMode: boolean; /** * HMAC-SHA256 authentication tag for data integrity * * @generated from field: bytes data_hmac = 9; */ dataHmac: Uint8Array; /** * Salt used for key derivation * * @generated from field: bytes key_derivation_salt = 10; */ keyDerivationSalt: Uint8Array; /** * Additional authenticated data (AAD) for AES-GCM * * @generated from field: bytes additional_data = 11; */ additionalData: Uint8Array; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.EncryptionMetadata"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): EncryptionMetadata; static fromJson(jsonValue: JsonValue, options?: Partial): EncryptionMetadata; static fromJsonString(jsonString: string, options?: Partial): EncryptionMetadata; static equals(a: EncryptionMetadata | PlainMessage | undefined, b: EncryptionMetadata | PlainMessage | undefined): boolean; } /** * EncryptionKeyState contains the current key and contributions for a given key version * * @generated from message dwn.v1.EncryptionKeyState */ export declare class EncryptionKeyState extends Message { /** * Current encryption key (stored encrypted or as reference) * * @generated from field: bytes current_key = 1; */ currentKey: Uint8Array; /** * Key version/epoch identifier * * @generated from field: uint64 key_version = 2; */ keyVersion: bigint; /** * Validator set participating in consensus * * @generated from field: repeated string validator_set = 3; */ validatorSet: string[]; /** * VRF contributions for this key generation round * * @generated from field: repeated dwn.v1.VRFContribution contributions = 4; */ contributions: VRFContribution[]; /** * Last rotation timestamp (Unix timestamp) * * @generated from field: int64 last_rotation = 5; */ lastRotation: bigint; /** * Next scheduled rotation timestamp (Unix timestamp) * * @generated from field: int64 next_rotation = 6; */ nextRotation: bigint; /** * Single node development mode flag * * @generated from field: bool single_node_mode = 7; */ singleNodeMode: boolean; /** * Usage count for this key (for usage-based rotation) * * @generated from field: uint64 usage_count = 8; */ usageCount: bigint; /** * Maximum usage count before rotation * * @generated from field: uint64 max_usage_count = 9; */ maxUsageCount: bigint; /** * Rotation interval in seconds (for time-based rotation) * * @generated from field: int64 rotation_interval = 10; */ rotationInterval: bigint; /** * Key creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 11; */ createdAt: bigint; /** * Previous key version for migration support * * @generated from field: uint64 previous_key_version = 12; */ previousKeyVersion: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.EncryptionKeyState"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): EncryptionKeyState; static fromJson(jsonValue: JsonValue, options?: Partial): EncryptionKeyState; static fromJsonString(jsonString: string, options?: Partial): EncryptionKeyState; static equals(a: EncryptionKeyState | PlainMessage | undefined, b: EncryptionKeyState | PlainMessage | undefined): boolean; } /** * VRFConsensusRound tracks a specific consensus round for key generation * * @generated from message dwn.v1.VRFConsensusRound */ export declare class VRFConsensusRound extends Message { /** * Round number for this consensus round * * @generated from field: uint64 round_number = 1; */ roundNumber: bigint; /** * Key version this round is generating * * @generated from field: uint64 key_version = 2; */ keyVersion: bigint; /** * Number of contributions required for consensus * * @generated from field: uint32 required_contributions = 3; */ requiredContributions: number; /** * Number of contributions received so far * * @generated from field: uint32 received_contributions = 4; */ receivedContributions: number; /** * Current status: "waiting_for_contributions", "complete", "expired", "single_node_mode" * * @generated from field: string status = 5; */ status: string; /** * Block height when this round expires * * @generated from field: int64 expiry_height = 6; */ expiryHeight: bigint; /** * Block height when round was initiated * * @generated from field: int64 initiated_height = 7; */ initiatedHeight: bigint; /** * Consensus input used for this round * * @generated from field: bytes consensus_input = 8; */ consensusInput: Uint8Array; /** * Whether this round completed successfully * * @generated from field: bool completed = 9; */ completed: boolean; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.VRFConsensusRound"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): VRFConsensusRound; static fromJson(jsonValue: JsonValue, options?: Partial): VRFConsensusRound; static fromJsonString(jsonString: string, options?: Partial): VRFConsensusRound; static equals(a: VRFConsensusRound | PlainMessage | undefined, b: VRFConsensusRound | PlainMessage | undefined): boolean; } /** * EncryptionStats contains encryption statistics for monitoring * * @generated from message dwn.v1.EncryptionStats */ export declare class EncryptionStats extends Message { /** * Total number of encrypted records * * @generated from field: int64 total_encrypted_records = 1; */ totalEncryptedRecords: bigint; /** * Total number of decryption errors * * @generated from field: int64 total_decryption_errors = 2; */ totalDecryptionErrors: bigint; /** * Last encryption height * * @generated from field: int64 last_encryption_height = 3; */ lastEncryptionHeight: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.EncryptionStats"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): EncryptionStats; static fromJson(jsonValue: JsonValue, options?: Partial): EncryptionStats; static fromJsonString(jsonString: string, options?: Partial): EncryptionStats; static equals(a: EncryptionStats | PlainMessage | undefined, b: EncryptionStats | PlainMessage | undefined): boolean; } /** * SaltStore contains salt management for encryption operations * * @generated from message dwn.v1.SaltStore */ export declare class SaltStore extends Message { /** * Unique identifier for the encrypted record * * @generated from field: string record_id = 1; */ recordId: string; /** * Salt value used for key derivation * * @generated from field: bytes salt_value = 2; */ saltValue: Uint8Array; /** * Creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 3; */ createdAt: bigint; /** * Key version associated with this salt * * @generated from field: uint64 key_version = 4; */ keyVersion: bigint; /** * Algorithm used with this salt (e.g., "PBKDF2-SHA256") * * @generated from field: string algorithm = 5; */ algorithm: string; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.SaltStore"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): SaltStore; static fromJson(jsonValue: JsonValue, options?: Partial): SaltStore; static fromJsonString(jsonString: string, options?: Partial): SaltStore; static equals(a: SaltStore | PlainMessage | undefined, b: SaltStore | PlainMessage | undefined): boolean; } /** * VRFContribution contains a VRF contribution for a given validator * * @generated from message dwn.v1.VRFContribution */ export declare class VRFContribution extends Message { /** * Validator address * * @generated from field: string validator_address = 1; */ validatorAddress: string; /** * VRF randomness output * * @generated from field: bytes randomness = 2; */ randomness: Uint8Array; /** * VRF proof for verification * * @generated from field: bytes proof = 3; */ proof: Uint8Array; /** * Block height when contribution was made * * @generated from field: int64 block_height = 4; */ blockHeight: bigint; /** * Unix timestamp when contribution was submitted * * @generated from field: int64 timestamp = 5; */ timestamp: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.VRFContribution"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): VRFContribution; static fromJson(jsonValue: JsonValue, options?: Partial): VRFContribution; static fromJsonString(jsonString: string, options?: Partial): VRFContribution; static equals(a: VRFContribution | PlainMessage | undefined, b: VRFContribution | PlainMessage | undefined): boolean; } /** * EncryptedDWNRecord contains an encrypted DWN record * * @generated from message dwn.v1.EncryptedDWNRecord */ export declare class EncryptedDWNRecord extends Message { /** * Unique identifier for the record * * @generated from field: string record_id = 1; */ recordId: string; /** * Encrypted data * * @generated from field: bytes encrypted_data = 2; */ encryptedData: Uint8Array; /** * Nonce used for encryption * * @generated from field: bytes nonce = 3; */ nonce: Uint8Array; /** * Key version * * @generated from field: uint64 key_version = 4; */ keyVersion: bigint; /** * IPFS hash of the record data * * @generated from field: string ipfs_hash = 5; */ ipfsHash: string; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.EncryptedDWNRecord"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): EncryptedDWNRecord; static fromJson(jsonValue: JsonValue, options?: Partial): EncryptedDWNRecord; static fromJsonString(jsonString: string, options?: Partial): EncryptedDWNRecord; static equals(a: EncryptedDWNRecord | PlainMessage | undefined, b: EncryptedDWNRecord | PlainMessage | undefined): boolean; } /** * EnclaveData represents encrypted private key material within a secure enclave * * @generated from message dwn.v1.EnclaveData */ export declare class EnclaveData extends Message { /** * Encrypted private key material from the WASM enclave * * @generated from field: bytes private_data = 1; */ privateData: Uint8Array; /** * Public key corresponding to the private key * * @generated from field: bytes public_key = 2; */ publicKey: Uint8Array; /** * Unique identifier for the enclave instance * * @generated from field: string enclave_id = 3; */ enclaveId: string; /** * Version number for refresh tracking * * @generated from field: int64 version = 4; */ version: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.EnclaveData"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveData; static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveData; static fromJsonString(jsonString: string, options?: Partial): EnclaveData; static equals(a: EnclaveData | PlainMessage | undefined, b: EnclaveData | PlainMessage | undefined): boolean; } /** * DWNMessageDescriptor contains metadata about a DWN message * * @generated from message dwn.v1.DWNMessageDescriptor */ export declare class DWNMessageDescriptor extends Message { /** * Interface type (e.g., "Records", "Protocols", "Permissions") * * @generated from field: string interface_name = 1; */ interfaceName: string; /** * Method name (e.g., "Write", "Query", "Configure") * * @generated from field: string method = 2; */ method: string; /** * ISO 8601 timestamp of when the message was created * * @generated from field: string message_timestamp = 3; */ messageTimestamp: string; /** * CID of the message data * * @generated from field: string data_cid = 4; */ dataCid: string; /** * Size of the data in bytes * * @generated from field: int64 data_size = 5; */ dataSize: bigint; /** * MIME type of the data * * @generated from field: string data_format = 6; */ dataFormat: string; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.DWNMessageDescriptor"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): DWNMessageDescriptor; static fromJson(jsonValue: JsonValue, options?: Partial): DWNMessageDescriptor; static fromJsonString(jsonString: string, options?: Partial): DWNMessageDescriptor; static equals(a: DWNMessageDescriptor | PlainMessage | undefined, b: DWNMessageDescriptor | PlainMessage | undefined): boolean; } /** * DWNRecord represents a record stored in a Decentralized Web Node * * @generated from message dwn.v1.DWNRecord */ export declare class DWNRecord extends Message { /** * Unique identifier for the record * * @generated from field: string record_id = 1; */ recordId: string; /** * DID of the DWN target * * @generated from field: string target = 2; */ target: string; /** * Message descriptor * * @generated from field: dwn.v1.DWNMessageDescriptor descriptor = 3; */ descriptor?: DWNMessageDescriptor; /** * Authorization JWT or signature * * @generated from field: string authorization = 4; */ authorization: string; /** * Record data payload * * @generated from field: bytes data = 5; */ data: Uint8Array; /** * Optional protocol URI this record conforms to * * @generated from field: string protocol = 6; */ protocol: string; /** * Optional protocol path * * @generated from field: string protocol_path = 7; */ protocolPath: string; /** * Optional schema URI for data validation * * @generated from field: string schema = 8; */ schema: string; /** * Optional parent record ID for threading * * @generated from field: string parent_id = 9; */ parentId: string; /** * Published flag for public visibility * * @generated from field: bool published = 10; */ published: boolean; /** * Attestation signature * * @generated from field: string attestation = 11; */ attestation: string; /** * Encryption details (legacy field) * * @generated from field: string encryption = 12; */ encryption: string; /** * Key derivation scheme (legacy field) * * @generated from field: string key_derivation_scheme = 13; */ keyDerivationScheme: string; /** * Creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 14; */ createdAt: bigint; /** * Last update timestamp (Unix timestamp) * * @generated from field: int64 updated_at = 15; */ updatedAt: bigint; /** * Block height when created * * @generated from field: int64 created_height = 16; */ createdHeight: bigint; /** * Encryption metadata for consensus-based encryption * * @generated from field: dwn.v1.EncryptionMetadata encryption_metadata = 17; */ encryptionMetadata?: EncryptionMetadata; /** * Flag indicating if the record is encrypted * * @generated from field: bool is_encrypted = 18; */ isEncrypted: boolean; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.DWNRecord"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): DWNRecord; static fromJson(jsonValue: JsonValue, options?: Partial): DWNRecord; static fromJsonString(jsonString: string, options?: Partial): DWNRecord; static equals(a: DWNRecord | PlainMessage | undefined, b: DWNRecord | PlainMessage | undefined): boolean; } /** * DWNProtocol represents a configured protocol in a DWN * * @generated from message dwn.v1.DWNProtocol */ export declare class DWNProtocol extends Message { /** * DID of the DWN target * * @generated from field: string target = 1; */ target: string; /** * Protocol URI identifier * * @generated from field: string protocol_uri = 2; */ protocolUri: string; /** * Protocol definition JSON * * @generated from field: bytes definition = 3; */ definition: Uint8Array; /** * Published flag for discoverability * * @generated from field: bool published = 4; */ published: boolean; /** * Creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 5; */ createdAt: bigint; /** * Block height when created * * @generated from field: int64 created_height = 6; */ createdHeight: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.DWNProtocol"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): DWNProtocol; static fromJson(jsonValue: JsonValue, options?: Partial): DWNProtocol; static fromJsonString(jsonString: string, options?: Partial): DWNProtocol; static equals(a: DWNProtocol | PlainMessage | undefined, b: DWNProtocol | PlainMessage | undefined): boolean; } /** * DWNPermission represents a permission grant in a DWN * * @generated from message dwn.v1.DWNPermission */ export declare class DWNPermission extends Message { /** * Unique identifier for the permission * * @generated from field: string permission_id = 1; */ permissionId: string; /** * DID of the permission grantor * * @generated from field: string grantor = 2; */ grantor: string; /** * DID of the permission grantee * * @generated from field: string grantee = 3; */ grantee: string; /** * DID of the DWN target * * @generated from field: string target = 4; */ target: string; /** * Interface scope (e.g., "Records", "Protocols") * * @generated from field: string interface_name = 5; */ interfaceName: string; /** * Method scope (e.g., "Write", "Query") * * @generated from field: string method = 6; */ method: string; /** * Optional protocol scope * * @generated from field: string protocol = 7; */ protocol: string; /** * Optional record scope * * @generated from field: string record_id = 8; */ recordId: string; /** * Permission conditions JSON * * @generated from field: bytes conditions = 9; */ conditions: Uint8Array; /** * Expiration timestamp (Unix timestamp) * * @generated from field: int64 expires_at = 10; */ expiresAt: bigint; /** * Creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 11; */ createdAt: bigint; /** * Revoked flag * * @generated from field: bool revoked = 12; */ revoked: boolean; /** * Block height when created * * @generated from field: int64 created_height = 13; */ createdHeight: bigint; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.DWNPermission"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): DWNPermission; static fromJson(jsonValue: JsonValue, options?: Partial): DWNPermission; static fromJsonString(jsonString: string, options?: Partial): DWNPermission; static equals(a: DWNPermission | PlainMessage | undefined, b: DWNPermission | PlainMessage | undefined): boolean; } /** * VaultState represents a vault instance for enclave-based operations * * @generated from message dwn.v1.VaultState */ export declare class VaultState extends Message { /** * Unique identifier for the vault * * @generated from field: string vault_id = 1; */ vaultId: string; /** * Owner DID or address * * @generated from field: string owner = 2; */ owner: string; /** * Enclave data containing encrypted keys * * @generated from field: dwn.v1.EnclaveData enclave_data = 3; */ enclaveData?: EnclaveData; /** * Public key for verification * * @generated from field: bytes public_key = 4; */ publicKey: Uint8Array; /** * Creation timestamp (Unix timestamp) * * @generated from field: int64 created_at = 5; */ createdAt: bigint; /** * Last refresh timestamp (Unix timestamp) * * @generated from field: int64 last_refreshed = 6; */ lastRefreshed: bigint; /** * Block height when created * * @generated from field: int64 created_height = 7; */ createdHeight: bigint; /** * Encryption metadata for consensus-based encryption * * @generated from field: dwn.v1.EncryptionMetadata encryption_metadata = 8; */ encryptionMetadata?: EncryptionMetadata; constructor(data?: PartialMessage); static readonly runtime: typeof proto3; static readonly typeName = "dwn.v1.VaultState"; static readonly fields: FieldList; static fromBinary(bytes: Uint8Array, options?: Partial): VaultState; static fromJson(jsonValue: JsonValue, options?: Partial): VaultState; static fromJsonString(jsonString: string, options?: Partial): VaultState; static equals(a: VaultState | PlainMessage | undefined, b: VaultState | PlainMessage | undefined): boolean; } //# sourceMappingURL=state_pb.d.ts.map