import { AccountSigner } from '../../signHelpers.js'; import { AccountAddress, SequenceNumber } from '../../types/index.js'; import type { CredentialContextLabel, GivenContext } from './types.js'; /** * JSON representation of given context information. * All context data is serialized to strings for transport and storage. */ export type GivenContextJSON = { /** The label identifying the type of context */ label: CredentialContextLabel | string; /** The context data serialized as a string */ context: string; }; /** * Comparison between two context parts * * @param a - a context part * @param b - a corresponding context part * * @returns whether `a` and `b` are equal */ export declare function contextEquals(a: GivenContext, b: GivenContext): boolean; /** * Serializes given context information to its JSON representation. * * This function handles the conversion of different context types to their * string representations for JSON serialization. Binary data is converted * to hex strings, while other data types are handled appropriately. * * @param context - The context information to serialize * @returns The JSON representation of the context */ export declare function givenContextToJSON(context: GivenContext): GivenContextJSON; /** * Deserializes given context information from its JSON representation. * * This function handles the conversion of JSON string representations back * to their proper types. Hex strings are converted back to Uint8Arrays, * and other types are handled appropriately. * * @param context - The JSON representation to deserialize * @returns The deserialized context information */ export declare function givenContextFromJSON(context: GivenContextJSON): GivenContext; export type AnchorTransactionMetadata = { /** * The sender account of the anchor transaction. */ sender: AccountAddress.Type; /** * The signer object used to sign the on-chain anchor registration. This must correspond to the `sender` account. */ signer: AccountSigner; /** * The sequence number for the sender account to use. If this is not defined it will be fetched from the node. */ sequenceNumber?: SequenceNumber.Type; };