Skip to main content

makePay

Function Type: internal

The makePay function facilitates payment processing through the EVVM contract, directing transactions to either synchronous or asynchronous processing paths based on specified parameters.

Parameters

ParameterTypeDescription
useraddressUser address for the payment transaction
amountuint256Amount of tokens involved in the transaction
priorityFeeuint256EVVM priority fee for transaction processing
priorityFlagboolEVVM execution mode (true = async, false = sync)
nonceuint256EVVM payment operation nonce for replay protection
signaturebytesEVVM payment authorization signature

Workflow

  1. Processing Mode Selection: Evaluates the priorityFlag parameter:
    • If true: Initiates payStaker_async for asynchronous processing
    • If false: Initiates payStaker_sync for synchronous processing
  2. Payment Execution: Forwards parameters to the appropriate EVVM contract function for payment processing and staking management
    • Both functions receive: user address, contract address, empty string, PRINCIPAL_TOKEN_ADDRESS, amount, priorityFee, nonce, contract address, and signature

Description

This internal function serves as a router for EVVM payment operations, ensuring that payment requests are processed through the appropriate execution path based on the priority flag setting. It standardizes the interface between the staking contract and the EVVM payment system.

note

The EVVM payment signature follows the Single Payment Signature Structure.