import { ContractTransaction } from 'ethers'; import { BaseAPI } from './baseAPI'; /** * Represents a class for handling pool operations related to the voidnode server and the pool contracts. * * @class OptionPSAPI * @extends {BaseAPI} */ export declare class OptionPSAPI extends BaseAPI { /** * get the amount of exerciseToken to pay to exercise the given amount of contracts * * @param {string} optionAddress - The address of the option. * @param {bigint} strike - The strike price of the option. * @param {bigint} contractSize - The size of the option. * @returns {Promise<[bigint, bigint] & { totalExerciseCost: bigint; fee: bigint }>} The amount of exerciseToken to pay to exercise the given amount of contracts */ getExerciseCost(optionAddress: string, strike: bigint, contractSize: bigint): Promise<[bigint, bigint] & { totalExerciseCost: bigint; fee: bigint; }>; /** * get the amount of collateral that would be received for a given amount of long tokens * * @param {string} optionAddress - The address of the option. * @param {bigint} strike - The strike price of the option. * @param {bigint} contractSize - The size of the option. * @returns {Promise} The amount of collateral that would be received for a given amount of long tokens */ getExerciseValue(optionAddress: string, strike: bigint, contractSize: bigint): Promise; /** * Returns a promise containing a populated transaction to exercise an option. Allows the user to use the SDK without providing a signer. * @param optionPSAddress {string} Contract address of the option. * @param strike {bigint} strike price of the option. * @param maturity {bigint} maturity of the option * @param contractSize {bigint} size of the option to exercise. * @returns {Promise} Promise containing the contract transaction. */ encodeExercise(optionPSAddress: string, strike: bigint, maturity: bigint, contractSize: bigint): Promise; /** * Returns a promise containing a populated transaction to cancel option exercise before maturity. Allows the user to use the SDK without providing a signer. * @param optionPSAddress {string} Contract address of the option. * @param strike {bigint} strike price of the option. * @param maturity {bigint} maturity of the option * @param contractSize {bigint} size of the option to exercise. * @returns {Promise} Promise containing the contract transaction. */ encodeCancelExercise(optionPSAddress: string, strike: bigint, maturity: bigint, contractSize: bigint): Promise; /** * Returns a promise containing a populated transaction to settle the exercised long options held by the caller. Allows the user to use the SDK without providing a signer. * @param optionPSAddress {string} Contract address of the option. * @param strike {bigint} strike price of the option. * @param maturity {bigint} maturity of the option * @param contractSize {bigint} size of the option to settle. * @returns {Promise} Promise containing the contract transaction. */ encodeSettleLong(optionPSAddress: string, strike: bigint, maturity: bigint, contractSize: bigint): Promise; /** * Returns a promise containing a populated transaction to settle the short options held by the caller. Allows the user to use the SDK without providing a signer. * @param optionPSAddress {string} Contract address of the option. * @param strike {bigint} strike price of the option. * @param maturity {bigint} maturity of the option * @param contractSize {bigint} size of the option to settle. * @returns {Promise} Promise containing the contract transaction. */ encodeSettleShort(optionPSAddress: string, strike: bigint, maturity: bigint, contractSize: bigint): Promise; }