Files
papers/hanzo-checkout/sections/02-system-model-and-definitions.tex

41 lines
1.2 KiB
TeX

\section{System Model and Definitions}
\subsection{Payment Transaction Model}
\begin{definition}[Payment Transaction]
A payment transaction $T$ is a tuple $(m, c, a, p, \sigma)$ where:
\begin{itemize}
\item $m \in \mathcal{M}$: merchant identifier
\item $c \in \mathcal{C}$: customer identifier
\item $a \in \mathbb{R}^+$: transaction amount
\item $p \in \mathcal{P}$: payment method token
\item $\sigma$: cryptographic signature binding the transaction
\end{itemize}
\end{definition}
\begin{definition}[Checkout State]
The checkout state $S$ is an element of the state space:
\[
S \in \{INIT, CUSTOMER\_IDENTIFIED, PAYMENT\_SELECTED, AUTHORIZED, CAPTURED, COMPLETED, FAILED\}
\]
\end{definition}
\subsection{State Transition Function}
The checkout process is governed by a deterministic state transition function:
\begin{equation}
\delta: S \times \Sigma \rightarrow S \times \Gamma
\end{equation}
where $\Sigma$ is the set of input events and $\Gamma$ is the set of output actions.
\begin{definition}[One-Click Eligibility]
A customer $c$ is one-click eligible for merchant $m$ if:
\begin{equation}
eligible(c, m) \iff \exists p \in tokens(c) : valid(p) \land authorized(p, m)
\end{equation}
\end{definition}