@silvana-one/nft
Version:
Mina NFT library
783 lines (782 loc) • 32.2 kB
TypeScript
import { AccountUpdate, DeployArgs, PublicKey, State, UInt64, SmartContract, Bool, UInt32, Field } from "o1js";
import { TransferEvent, NFTCollectionContractConstructor, NFTCollectionBase, TransferExtendedParams, TransferByProofParams } from "../interfaces/index.js";
declare const AuctionPacked_base: (new (value: {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) & {
_isStruct: true;
} & Omit<import("node_modules/o1js/dist/node/lib/provable/types/provable-intf.js").Provable<{
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}, {
ownerX: bigint;
collectionX: bigint;
nftX: bigint;
auctioneerX: bigint;
bidderX: bigint;
data: bigint;
}>, "fromFields"> & {
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[]) => {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
} & {
fromValue: (value: {
ownerX: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: string | number | bigint | import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
toInput: (x: {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
fields?: Field[] | undefined;
packed?: [Field, number][] | undefined;
};
toJSON: (x: {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
ownerX: string;
collectionX: string;
nftX: string;
auctioneerX: string;
bidderX: string;
data: string;
};
fromJSON: (x: {
ownerX: string;
collectionX: string;
nftX: string;
auctioneerX: string;
bidderX: string;
data: string;
}) => {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
empty: () => {
ownerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
collectionX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
nftX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
auctioneerX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
bidderX: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
data: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
};
export declare class AuctionPacked extends AuctionPacked_base {
}
declare const Auction_base: (new (value: {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) & {
_isStruct: true;
} & Omit<import("node_modules/o1js/dist/node/lib/provable/types/provable-intf.js").Provable<{
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}, {
owner: {
x: bigint;
isOdd: boolean;
};
collection: {
x: bigint;
isOdd: boolean;
};
nft: {
x: bigint;
isOdd: boolean;
};
auctioneer: {
x: bigint;
isOdd: boolean;
};
bidder: {
x: bigint;
isOdd: boolean;
};
minimumPrice: bigint;
transferFee: bigint;
saleFee: bigint;
auctionEndTime: bigint;
withdrawPeriod: bigint;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
}>, "fromFields"> & {
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[]) => {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
} & {
fromValue: (value: {
owner: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
collection: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
nft: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
auctioneer: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
bidder: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
minimumPrice: number | bigint | UInt64;
transferFee: number | bigint | UInt64;
saleFee: number | bigint | UInt32;
auctionEndTime: number | bigint | UInt32;
withdrawPeriod: number | bigint | UInt32;
isOwnerPaid: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
toInput: (x: {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
fields?: Field[] | undefined;
packed?: [Field, number][] | undefined;
};
toJSON: (x: {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
owner: string;
collection: string;
nft: string;
auctioneer: string;
bidder: string;
minimumPrice: string;
transferFee: string;
saleFee: string;
auctionEndTime: string;
withdrawPeriod: string;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
};
fromJSON: (x: {
owner: string;
collection: string;
nft: string;
auctioneer: string;
bidder: string;
minimumPrice: string;
transferFee: string;
saleFee: string;
auctionEndTime: string;
withdrawPeriod: string;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
}) => {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
empty: () => {
owner: PublicKey;
collection: PublicKey;
nft: PublicKey;
auctioneer: PublicKey;
bidder: PublicKey;
minimumPrice: UInt64;
transferFee: UInt64;
saleFee: UInt32;
auctionEndTime: UInt32;
withdrawPeriod: UInt32;
isOwnerPaid: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
};
export declare class Auction extends Auction_base {
pack(): AuctionPacked;
static unpack(packed: AuctionPacked): Auction;
}
declare const AuctionState_base: (new (value: {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) & {
_isStruct: true;
} & Omit<import("node_modules/o1js/dist/node/lib/provable/types/provable-intf.js").Provable<{
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}, {
bidAmount: bigint;
auction: {
owner: {
x: bigint;
isOdd: boolean;
};
collection: {
x: bigint;
isOdd: boolean;
};
nft: {
x: bigint;
isOdd: boolean;
};
auctioneer: {
x: bigint;
isOdd: boolean;
};
bidder: {
x: bigint;
isOdd: boolean;
};
minimumPrice: bigint;
transferFee: bigint;
saleFee: bigint;
auctionEndTime: bigint;
withdrawPeriod: bigint;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
};
settled: boolean;
}>, "fromFields"> & {
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[]) => {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
} & {
fromValue: (value: {
bidAmount: number | bigint | UInt64;
auction: Auction | {
owner: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
collection: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
nft: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
auctioneer: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
bidder: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
minimumPrice: number | bigint | UInt64;
transferFee: number | bigint | UInt64;
saleFee: number | bigint | UInt32;
auctionEndTime: number | bigint | UInt32;
withdrawPeriod: number | bigint | UInt32;
isOwnerPaid: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTtransferred: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
isNFTwithdrawn: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
settled: boolean | import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
toInput: (x: {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
fields?: Field[] | undefined;
packed?: [Field, number][] | undefined;
};
toJSON: (x: {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
}) => {
bidAmount: string;
auction: {
owner: string;
collection: string;
nft: string;
auctioneer: string;
bidder: string;
minimumPrice: string;
transferFee: string;
saleFee: string;
auctionEndTime: string;
withdrawPeriod: string;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
};
settled: boolean;
};
fromJSON: (x: {
bidAmount: string;
auction: {
owner: string;
collection: string;
nft: string;
auctioneer: string;
bidder: string;
minimumPrice: string;
transferFee: string;
saleFee: string;
auctionEndTime: string;
withdrawPeriod: string;
isOwnerPaid: boolean;
isNFTtransferred: boolean;
isNFTwithdrawn: boolean;
};
settled: boolean;
}) => {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
empty: () => {
bidAmount: UInt64;
auction: Auction;
settled: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
};
};
export declare class AuctionState extends AuctionState_base {
}
export interface NonFungibleTokenAuctionContractDeployProps extends Exclude<DeployArgs, undefined> {
/** The minimum price. */
minimumPrice: UInt64;
/** The auction end time. */
auctionEndTime: UInt32;
/** The collection of the NFT. */
collection: PublicKey;
/** The address of the NFT. */
nft: PublicKey;
/** The owner of the NFT. */
owner: PublicKey;
/** The auctioneer of the NFT. */
auctioneer: PublicKey;
/** The transfer fee. */
transferFee: UInt64;
/** The sale fee. */
saleFee: UInt32;
/** The withdraw period. */
withdrawPeriod: UInt32;
}
declare const AuctionBidEvent_base: (new (value: {
bidder: PublicKey;
price: UInt64;
}) => {
bidder: PublicKey;
price: UInt64;
}) & {
_isStruct: true;
} & Omit<import("node_modules/o1js/dist/node/lib/provable/types/provable-intf.js").Provable<{
bidder: PublicKey;
price: UInt64;
}, {
bidder: {
x: bigint;
isOdd: boolean;
};
price: bigint;
}>, "fromFields"> & {
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[]) => {
bidder: PublicKey;
price: UInt64;
};
} & {
fromValue: (value: {
bidder: PublicKey | {
x: Field | bigint;
isOdd: Bool | boolean;
};
price: number | bigint | UInt64;
}) => {
bidder: PublicKey;
price: UInt64;
};
toInput: (x: {
bidder: PublicKey;
price: UInt64;
}) => {
fields?: Field[] | undefined;
packed?: [Field, number][] | undefined;
};
toJSON: (x: {
bidder: PublicKey;
price: UInt64;
}) => {
bidder: string;
price: string;
};
fromJSON: (x: {
bidder: string;
price: string;
}) => {
bidder: PublicKey;
price: UInt64;
};
empty: () => {
bidder: PublicKey;
price: UInt64;
};
};
export declare class AuctionBidEvent extends AuctionBidEvent_base {
}
/**
* Creates a new NFT Collection Contract class.
*
* @param params - Constructor parameters including admin and upgrade contracts, and network ID.
* @returns The Collection class extending TokenContract and implementing required interfaces.
*/
export declare function AuctionFactory(params: {
collectionContract: () => NFTCollectionContractConstructor;
}): {
new (address: PublicKey, tokenId?: Field): {
auctionData: State<AuctionPacked>;
bidAmount: State<UInt64>;
settled: State<import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool>;
deploy(args: NonFungibleTokenAuctionContractDeployProps): Promise<void>;
events: {
bid: typeof AuctionBidEvent;
settleAuction: typeof TransferByProofParams;
canTransfer: typeof TransferEvent;
settlePayment: typeof UInt64;
settleAuctioneerPayment: typeof UInt64;
withdraw: typeof UInt64;
};
getCollectionContract(address: PublicKey): NFTCollectionBase;
calculateSaleFee(params: {
price: UInt64;
saleFee: UInt32;
transferFee: UInt64;
}): UInt64;
bid(price: UInt64, bidder: PublicKey): Promise<Auction>;
getAuctionState(): Promise<AuctionState>;
settleAuction(): Promise<void>;
withdrawNFT(): Promise<void>;
canTransfer(params: TransferExtendedParams): Promise<Bool>;
settlePayment(): Promise<void>;
settleAuctioneerPayment(amount: UInt64): Promise<void>;
/**
* Withdraw the deposit from the auction
* in case the auction is not settled during the WITHDRAW_PERIOD
* for any reason
* Anybody can call this method to allow the use of bots by the auctioneer or bidder
*/
withdraw(): Promise<void>;
"__#4@#private": any;
address: PublicKey;
tokenId: Field;
init(): void;
requireSignature(): void;
skipAuthorization(): void;
readonly self: AccountUpdate;
newSelf(methodName?: string): AccountUpdate;
sender: {
self: SmartContract;
getUnconstrained(): PublicKey;
getAndRequireSignature(): PublicKey;
};
readonly account: import("node_modules/o1js/dist/node/lib/mina/v1/precondition.js").Account;
readonly network: import("node_modules/o1js/dist/node/lib/mina/v1/precondition.js").Network;
readonly currentSlot: import("node_modules/o1js/dist/node/lib/mina/v1/precondition.js").CurrentSlot;
approve(update: AccountUpdate | import("o1js").AccountUpdateTree | import("o1js").AccountUpdateForest): void;
send(args: {
to: PublicKey | AccountUpdate | SmartContract;
amount: number | bigint | UInt64;
}): AccountUpdate;
readonly balance: {
addInPlace(x: string | number | bigint | UInt64 | UInt32 | import("o1js").Int64): void;
subInPlace(x: string | number | bigint | UInt64 | UInt32 | import("o1js").Int64): void;
};
emitEventIf<K extends "canTransfer" | "withdraw" | "bid" | "settleAuction" | "settlePayment" | "settleAuctioneerPayment">(condition: Bool, type: K, event: any): void;
emitEvent<K extends "canTransfer" | "withdraw" | "bid" | "settleAuction" | "settlePayment" | "settleAuctioneerPayment">(type: K, event: any): void;
fetchEvents(start?: UInt32, end?: UInt32): Promise<{
type: string;
event: {
data: import("o1js").ProvablePure<any>;
transactionInfo: {
transactionHash: string;
transactionStatus: string;
transactionMemo: string;
};
};
blockHeight: UInt32;
blockHash: string;
parentBlockHash: string;
globalSlot: UInt32;
chainStatus: string;
}[]>;
};
_methods?: import("node_modules/o1js/dist/node/lib/proof-system/zkprogram.js").MethodInterface[];
_methodMetadata?: Record<string, {
actions: number;
rows: number;
digest: string;
gates: import("node_modules/o1js/dist/node/bindings.js").Gate[];
proofs: import("node_modules/o1js/dist/node/lib/proof-system/proof.js").ProofClass[];
}>;
_provers?: import("node_modules/o1js/dist/node/bindings.js").Pickles.Prover[];
_verificationKey?: {
data: string;
hash: Field;
};
Proof(): {
new ({ proof, publicInput, publicOutput, maxProofsVerified, }: {
proof: unknown;
publicInput: import("o1js").ZkappPublicInput;
publicOutput: undefined;
maxProofsVerified: 0 | 2 | 1;
}): {
verify(): void;
verifyIf(condition: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool): void;
publicInput: import("o1js").ZkappPublicInput;
publicOutput: undefined;
proof: unknown;
maxProofsVerified: 0 | 2 | 1;
shouldVerify: import("node_modules/o1js/dist/node/lib/provable/bool.js").Bool;
declare(): boolean;
toJSON(): import("o1js").JsonProof;
publicFields(): {
input: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[];
output: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[];
};
};
publicInputType: Omit<import("node_modules/o1js/dist/node/lib/provable/types/provable-intf.js").Provable<{
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}, {
accountUpdate: bigint;
calls: bigint;
}>, "fromFields"> & {
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[]) => {
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
} & {
toInput: (x: {
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
fields?: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[] | undefined;
packed?: [import("node_modules/o1js/dist/node/lib/provable/field.js").Field, number][] | undefined;
};
toJSON: (x: {
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
}) => {
accountUpdate: string;
calls: string;
};
fromJSON: (x: {
accountUpdate: string;
calls: string;
}) => {
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
empty: () => {
accountUpdate: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
calls: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
};
publicOutputType: import("o1js").ProvablePureExtended<undefined, undefined, null>;
tag: () => typeof SmartContract;
fromJSON<S extends import("node_modules/o1js/dist/node/lib/util/types.js").Subclass<typeof import("o1js").Proof>>(this: S, { maxProofsVerified, proof: proofString, publicInput: publicInputJson, publicOutput: publicOutputJson, }: import("o1js").JsonProof): Promise<import("o1js").Proof<import("o1js").InferProvable<S["publicInputType"]>, import("o1js").InferProvable<S["publicOutputType"]>>>;
dummy<Input, OutPut>(publicInput: Input, publicOutput: OutPut, maxProofsVerified: 0 | 2 | 1, domainLog2?: number): Promise<import("o1js").Proof<Input, OutPut>>;
readonly provable: {
toFields: (value: import("o1js").Proof<any, any>) => import("node_modules/o1js/dist/node/lib/provable/field.js").Field[];
toAuxiliary: (value?: import("o1js").Proof<any, any> | undefined) => any[];
fromFields: (fields: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[], aux: any[]) => import("o1js").Proof<any, any>;
sizeInFields(): number;
check: (value: import("o1js").Proof<any, any>) => void;
toValue: (x: import("o1js").Proof<any, any>) => import("node_modules/o1js/dist/node/lib/proof-system/proof.js").ProofValue<any, any>;
fromValue: (x: import("o1js").Proof<any, any> | import("node_modules/o1js/dist/node/lib/proof-system/proof.js").ProofValue<any, any>) => import("o1js").Proof<any, any>;
toCanonical?: ((x: import("o1js").Proof<any, any>) => import("o1js").Proof<any, any>) | undefined;
};
publicFields(value: import("o1js").ProofBase<any, any>): {
input: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[];
output: import("node_modules/o1js/dist/node/lib/provable/field.js").Field[];
};
_proofFromBase64(proofString: string, maxProofsVerified: 0 | 2 | 1): unknown;
_proofToBase64(proof: unknown, maxProofsVerified: 0 | 2 | 1): string;
};
compile({ cache, forceRecompile }?: {
cache?: import("o1js").Cache | undefined;
forceRecompile?: boolean | undefined;
}): Promise<{
verificationKey: {
data: string;
hash: import("node_modules/o1js/dist/node/lib/provable/field.js").Field;
};
provers: import("node_modules/o1js/dist/node/bindings.js").Pickles.Prover[];
verify: (statement: import("node_modules/o1js/dist/node/bindings.js").Pickles.Statement<import("node_modules/o1js/dist/node/lib/provable/core/fieldvar.js").FieldConst>, proof: unknown) => Promise<boolean>;
}>;
digest(): Promise<string>;
getMaxProofsVerified(): Promise<0 | 2 | 1>;
setVerificationKeyUnsafe(verificationKey: {
data: string;
hash: Field | string;
}): void;
runOutsideCircuit(run: () => void): void;
analyzeMethods({ printSummary }?: {
printSummary?: boolean | undefined;
}): Promise<Record<string, {
actions: number;
rows: number;
digest: string;
gates: import("node_modules/o1js/dist/node/bindings.js").Gate[];
proofs: import("node_modules/o1js/dist/node/lib/proof-system/proof.js").ProofClass[];
}>>;
};
export {};