UNPKG

@thorium-dev-group/x402-mcp-extension

Version:
23 lines (22 loc) 986 B
import { IFacilitatorService } from "../facilitators/IFacilitatorService"; import { PaymentRequirements } from "x402/types"; import { RequestHandlerExtra } from "@modelcontextprotocol/sdk/shared/protocol.js"; import { ILoggerFactory } from "../../../shared/interfaces"; import { IPaymentOrchestrator } from "./IPaymentOrchestrator"; export interface PaymentOrchestratorOptions { payTo: string; network: string; facilitator: IFacilitatorService; loggerFactory: ILoggerFactory; } export declare class PaymentOrchestrator implements IPaymentOrchestrator { private options; private logger; constructor(options: PaymentOrchestratorOptions); validatePayment(handlerName: string, paymentRequirements: PaymentRequirements, extra: RequestHandlerExtra<any, any>): Promise<void>; settlePayment(extra: any): Promise<void>; private sendPaymentRequiredRequest; private isMethodNotFoundError; private validatePaymentProof; private executePayment; }