@gorbchain-xyz/chaindecode
Version:
GorbchainSDK V1.3+ - Complete Solana development toolkit with advanced cryptography, messaging, and collaboration features. Build secure applications with blockchain, DeFi, and end-to-end encryption.
26 lines (25 loc) • 1.3 kB
TypeScript
/**
* Group encryption for multiple recipients
* Static groups with fixed membership
*/
import { EncryptionResult, GroupEncryptionMetadata, EncryptionOptions } from './types.js';
/**
* Create a static encryption group
*/
export declare function createGroup(groupName: string, memberPublicKeys: string[], creatorPrivateKey: string | Uint8Array): Promise<GroupEncryptionMetadata>;
/**
* Encrypt data for a group
*/
export declare function encryptGroup(data: string | Uint8Array, groupMetadata: GroupEncryptionMetadata, options?: EncryptionOptions): Promise<EncryptionResult>;
/**
* Decrypt group encrypted data
*/
export declare function decryptGroup(encryptionResult: EncryptionResult, memberPrivateKey: string | Uint8Array, memberPublicKey: string): Promise<Uint8Array>;
/**
* Decrypt group encrypted data and return as string
*/
export declare function decryptGroupString(encryptionResult: EncryptionResult, memberPrivateKey: string | Uint8Array, memberPublicKey: string): Promise<string>;
/**
* Add a member to an existing group (creates new metadata)
*/
export declare function addGroupMember(groupMetadata: GroupEncryptionMetadata, newMemberPublicKey: string, authorizedMemberPrivateKey: string | Uint8Array, authorizedMemberPublicKey: string): Promise<GroupEncryptionMetadata>;