27
V2.0 2018-10-26 Alchemy Foundation The Alchemy Yellow Book on Payment Technology

The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

  • Upload
    others

  • View
    1

  • Download
    0

Embed Size (px)

Citation preview

Page 1: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

V2.02018-10-26Alchemy Foundation

The Alchemy Yellow Book on Payment Technology

Page 2: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

Contents

Contents1. Preface 3

2. Core Technical Advantage 3

2.1. Blockchain Network Adaptability 3

2.2. Integrated Scaling Solutions 3

2.3. PULLPAY Protocol 3

2.4. Cross-chain Payments based on Atomic Swap 3

2.5. Multi-Pronged Risk Management 3

2.6. Simple and Customizable Smart Contracts 3

3. Core Business System 4

3.1. The Account System 5

3.2. The Payment Business System 5

4. Product Architecture 6

5. Technical Architecture 8

5.1. The ALCHEMY Decentralized Payment Network 9

5.2. The Merchant Partnering Network 9

5.3. The External Service Network 9

5.4. The Technology Architecture on Blockchain-based Network 9

6. ALCHEMY Consensus Protocol 11

6.1. The Access Layer Protocol (ALCHEMY Connect) 12

6.2. The Solution Layer Protocol(ALCHEMY APP) 12

6.3. Product Layer Protocols(ALCHEMY Component) 13

6.4. The Core Layer Protocol (ALCHEMY Core) 13

6.5. The Network Layer Protocol (ALCHEMY Net) 15

7. A Typical Collection Process of ALCHEMY Consensus Protocol 16

8. Lightning Payment Network 17

8.1. The demand for Lightning Payment Network in commercial scenarios 17

8.2. The Alchemy Integrated Structure of State Channel Network 18

8.3. The Integrated Light Wallet of Alchemy Lightning Payment Network 19

8.4. Alchemy Ecosystem Hub 19

9. PULLPAY 25

9.1. PULLPAY vs. PUSHPAY 25

9.2. PULLPAY 25

10.Reference material 27

Page 3: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

1. PrefaceThis document describes the relevant technical specifications of the

Alchemy Payment Consensus Protocol for technology reference by

Alchemy Ecosystem Partners.

This document mainly describes the Alchemy product architecture, the

technical architecture, the Alchemy consensus protocol, the lightning

payment network, and the PULLPAY protocol.

2. Core Technical Advantage2.1. Blockchain Network Adaptability• Easily Deployable on Public Blockchains to allow the acceptance of a

broad range of cryptocurrencies

• Integrated network to include Lightning Network, Raiden Network and

State Channel Network

2.2. Integrated Scaling Solutions• Based on the algorithm of the risk-controlled anti-fraud engine, it will

realize zero-block confirmation of bitcoin, bitcoin cash, Litecoin and

other public chains to accelerate payment speed

• Fast routing algorithm

• Multiple tokens reuse the same channel

• Funds' intelligent balance on Lightning Network Channel

• Supporting various payment models, PULLPAY, combined payment,

split, bulk collection/payment, etc.

2.3. PULLPAY Protocol• Flexible Payment Models available to support industry needs, incl

PULLPAY and combined/split payments

2.4. Cross-chain Payments based on Atomic Swap• Cross-chain Lightning payments via Atomic Swap and Payment

Channel

• Expediting Payments for crypto that do not support Lightning Network

via Atomic Swap and Submarine Swaps

• Cross-chain combined payment for multiple blockchain currencies

2.5. Multi-Pronged Risk Management• With ML and AI to Mitigate Fraud Risk and Enhance Security of

Network

• Secure smart contract based on big data risk control

• Based on the quantitative transaction model, the cryptocurrency

collected will be converted into stable coin with strategies, and the

risk of depreciation of the currency or price fluctuation will be hedged

2.6. Simple and Customizable Smart Contracts• It provides a visual, streamlined and customized interface of the

smart contract , and describes the rules in natural language, so that

business personnel can understand and verify the smart contract

implementation logic.

• It also provides encapsulation at different levels including solution

level, product level, component level and interface level to meet

different application requirements for easier use

Page 4: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

3. Core Business System

As shown above:

ALCHEMY's core business system includes the Account System and the Payment Business System.

User

Merchant

Corporate Subsidiary

Corporate Account

Account Attachment

Account Attachment

AccountAttachment

Pull

PUSH PAY

Payment Request

PULL PA

Y

Push

PaymentRequest

Smart Contract Account

Merchant Account

Standard Account

Types of Merchant Account

Member Account

Digital Currency Account

Credit Account

Bonus Point Account

Coupon Account......

Types of Corporate Account

Multi-level Account

Corporate Credit Account

Digital Currency Account

Asset Securitization Account......

Types of Standard Account

Digital Currency Account

Credit Account

Bonus Point Account

Coupon Account

Other Digital Asset Account......

Payment Types

Crypto Currency Payment

Credit Payment

Bonus Point Payment

Combined Payment

Escrow Payment

Restricted Payment

Recurring and Subscription Payment

Bulk Collection/Payment

Document Splitting

Transfer

ross-border Payment......

ALCHEMY's Blockchain AccountSystem and Payment System

Types of Smart Contract Account

Credit Payment Contract

Decentralized Hosting Contract

Decentralized Dispute Resolution Contract

Decentralized Credit Scoring Contract

Decentralized Trading Contract

Cross-chain Trading Smart Contract

Merchant Margin Contract

Clearing Contract

Settlement Contract

Security Fund Contract

Opening/Cancellation Contract......

Information Flow

Fund Flow

Muti-level Sub Account

ALCHEMY's core business system

ALCHEMY's core business system includes the Account System and the Payment Business System.

Page 5: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

3.1. The Account SystemIt includes Standard Account, Merchant Account, Corporate Account and

Smart Contract Account.

Standard Account: mainly meets the requirements of daily use of

ordinary users. Standard Accounts can be classified into cryptocurrency

accounts, credit accounts, point accounts, coupon accounts, and other

cryptocurrency asset accounts depending on the asset type (subject).

Merchant Account: For those who primarily run online/offline services. The

merchant account is divided into: a point account issued by the merchant, a

coupon account issued by the merchant, a credit account, a cryptocurrency

account, and a membership account.

Corporate Account: An account primarily for corporate users. The

Corporate Account supports a multi-level account system to meet the

needs of the enterprises’ multi-level management system. The Corporate

Account types are divided into corporate credit account, cryptocurrency

account, and corporate asset-backed security accounts

Smart Contract Accounts: Support for complex transactions and community

governance, including decentralized dispute resolution, credit rating,

decentralized exchanges, cross-chain transactions, clearing settlements,

etc. Smart contract accounts are divided into credit contracts, escrow

contracts, decentralized dispute processing contracts, credit rating

contracts, decentralized transaction contracts, cross-chain transaction

smart contracts, merchant bond contracts, Clearing contracts, settlement

contracts, security fund contracts, network access / exit contracts, etc.

The same user can have multiple types of accounts, such as a business,

which can have standard accounts, corporate accounts, merchant accounts,

and smart-contract accounts to meet the needs of different business

scenarios.

3.2. The Payment Business System

PUSHPAY mode: The payer actively initiates a payment request and

authorizes the payment with the private key held in hand. It’s similar to the

online payment mode of online banking.

PULLPAY mode: The payer authorizes the payee to automatically debit the

designated account in advance, and the payee initiates the debit request

at the subsequent payment, and does not require the payer to re-authorize

the private key. It’s similar to the current pay-as-you-go (withholding)

model.

Based on these two models, the ALCHEMY payment business

system offers a wide range of payment types, including:

• Cryptocurrency payment

• Credit payment

• Points payment

• Combination payment

• Guarantee payment

• Directed payment

• Subscription payment (withholding)

• Bulk collection/payment

• Splitting check

• Transfer

• Trans-border payment

ALCHEMY's payment service supports the PUSHPAY mode of active payment and the PULLPAY mode of withholding.

Page 6: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

4. Product Architecture

The ALCHEMY product architecture is divided into five layers: the blockchain network layer, the core layer, the product layer, the solution layer, and the access layer.

ALCHEMY Product Infrastructure

ALCHEMY Product StructureALCHEMY Consensus Protocol

Standard product Custom product

Consensus algorithm Smart contract Cross chain payment Lightning network

APP/ Smart POS (SDK)

Building software (plug in)

Financial software (payment gateway)

IoT Infrastructure(API)

Online payment solutions Offline payment solutions Enterprise payment solutions

Payment consensus protocol engine

Transaction core Automatic clearing house

Decentralized operation

Decentralized exchange house

Member loyalty management

Smart Contract Marketplace

Risk assessment and anti fraud

Level 5 Access layer protocol

(ALCHEMY Connect)

Level 4 Solution layer protocol(ALCHEMY APP)

Level 2 Core layer protocol

(ALCHEMY Core)

Level 1 Network layer protocol(ALCHEMY Net)

Level 3 Product layer protocol(ALCHEMY Component)

Pa

ym

en

t Co

ns

en

su

s

Page 7: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

The product architecture of ALCHEMY payment network is divided

into five layers: Blockchain network layer, core layer, product layer,

solution layer and access layer.

• The Access Layer

ALCHEMY's various payment capabilities are provided in the form of

SDKs, plug-ins, payment gateways, APIs, etc., on the one hand, to meet

the individualization needs of each access platform, while reducing

access difficulty and achieving fast access.

• The Solution Layer

According to the payment scenarios and demands of different

industries, ALCHEMY’s ecosystem partners will package, customize and

combine standard products and customized products to form solutions

for different industries.

• The Product Layer

The product layer combines and encapsulates the core layer

service according to the product form of typical payment scenario

to form standardized products. It will customize products based on

standardized products.

• The Core Layer

The core layer exposes ALCHEMY capabilities in the form of the most

granular SOA services, which are encapsulated as service components

to facilitate external invocation.

• The Blockchain Network Layer

The infrastructures which hold the underlying technology of

ALCHEMY's blockchain, include the blockchain platform, the

consensus protocol, the lightning payment network, the cross-chain

and other related technologies. Refer to "Article 6.5 on Blockchain

Basic Network" for details.

Page 8: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

5. Technical Architecture The ALCHEMY technical architecture divides the entire ecosystem network into three parts: the ALCHEMY decentralized payment network, the merchant partner network and the external service network.

The ALCHEMY Technical Architecture

Partner Network forMerchant Services

External ServiceNetwork

Digital AssetPayment Network

Merchant Acquiring Gateway

Crypto CurrenciesPayment

Digital Assets Paymentsuch as Universal Bonus

Crypto Currencies Blockchain Network

Internet ofThings

Internet MobileInternet Bank Card Acquirer Network

ALCHEMY Decentralized Payments Network

Transaction Processing Engine

Payment ConsensusEngine

Cross merchantloyalty programs

Risk Management and Anti-Fraud Engine

Smart Contract Marketplace

DecentralizedExchange

Decentralized Operation

Automatic ClearingHouse

ALCHEMYConsensus

Protocol

On-Chain Payment Off-Chain Payment

Cross-chain Asset Transfer

Cross-chain RealTime Payment

Crypto Currency Networksuch as Bitcoin

Fiat CurrencyPayment Network

Wallet ServiceProvider

Exchange

Exchange

Page 9: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

In the ALCHEMY technical architecture, the whole ALCHEMY ecosystem

network is divided into three parts: the ALCHEMY Decentralized Payment

Network, the Merchant Partner Network and the External Service Network.

5.1. The ALCHEMY Decentralized Payment Network

The ALCHEMY core service network on decentralized payment

includes:

• The Payment Network: including on-chain payment network,

off-chain lightning payment network. The on-chain payment

network refers to the network of cryptocurrencies such as

Bitcoin and Ethereum, which completes the payment in the

form of on-chain. The Lightning Payment Network realizes

rapid payment in the form of off-chain, including Lightning

Network, Raiden Network and State Channel Network.

• The core payment components: including various components

and services of the ALCHEMY decentralized payment

network, including transaction processing engine, billing

engine, routing engine, ACH decentralized automatic clearing

and settlement office, credit rating, decentralized exchange,

decentralized operation, the anti-fraud engine for risk control,

payment intelligent contracts, etc.

5.2. The Merchant Partnering NetworkAs an ecosphere, ALCHEMY works with the participants in the ecosphere

under the common governance system to achieve win-win results and the

benign development of the ecosphere.

ALCHEMY focuses on the construction of ecosystem governance system

and the research and development of core platforms.

Payment partners like QFPAY are closer to the market, more responsive

to industry payment demands, and better at merchant expansion and

services. Therefore, the work like merchant access gateway, intelligent POS,

industry software docking, industry solutions and so on will be completed

by these merchant partners.

ALCHEMY, together with ecosphere partners, provides merchants

access to various types of quick access toolkits including SDK, plug-ins,

API, access gateway, etc., supporting access to various terminal devices

and applications including Internet of things, Internet, mobile Internet,

Bankcard Acquiring Network. The payment with cryptocurrency assets such

as cryptocurrency payment, credit payment and points, is supported on the

form of payment.

ALCHEMY ecosystem partners can distribute their own tokens or build up

their own side chains based on ALCHEMY, depending on the needs of the

business scenario.

5.3. The External Service NetworkThe external service network is a collection of various interface services that

ALCHEMY uses to call external services.

The external service network interface includes various cryptocurrency

issuers, cryptocurrency exchanges (decentralized, centralized exchanges),

credit service providers, wallet service providers, legal currency payment

networks, software service providers and so on.

5.4. The Technology Architecture on Blockchain-based Network The ALCHEMY technology architecture on blockchain-based network is

divided into: the blockchain platform layer, the core payment layer, the

payment network layer and the payment channel layer.

Page 10: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

PaymentChannel

Bitcoin/Ethereum/Stellar/EOS etc.

Core Layerof Payment

ALCHEMY Network Core Layer

Blockchain Network Adaptor Layer

PaymentNetwork

On-ChainPayment Network

Off-ChainPayment Network

Blockchain Ethereum EOS

ALCHEMY Technology Architecture on Blockchain-based Network

The ALCHEMY technology architecture on blockchain-based network

is divided into: blockchain platform layer, core payment layer, payment

network layer and payment channel layer.

• The Blockchain Platform Layer

The underlying Blockchain platform supported by the ALCHEMY

payment network supports Ethereum, EOS, Stellar, Wanchain, Vite, etc.

• Core Payment Layer

It includes various payment business components at the core of

ALCHEMY, ALCHEMY payment consensus protocol, payment smart

contract and other business support platforms.

In order to realize that the core payment layer has no exposure of

itself against the underlying blockchain platform, ALCHEMY abstracts

the blockchain network adaptation layer to be compatible with the

underlying network of the mainstream blockchain, and can switch to

the optimal underlying network as it evolves.

• Payment Network Layer

It is used to process On-Chain and Off-Chain payment transactions,

enabling fast and secure payment of various cryptocurrencies. At the

same time, cross-chain payment is handled through the Atomic Swap

mechanism.

For On-Chain transact ions, ALCHEMY aims to be the most

comprehensive cryptocurrency aggregation payment network on the

market.

For Off-Chain, the Alchemy Lightning Payment Network supports

Lightning Network, Raiden Network, and State Channel Network

protocols at the same time. It not only supports the Payment Channel,

but also supports the State Channel. Through the Alchemy Ecosystem

Hub architecture, many issues with the Lightning Network's large-scale

commercial payment applications have been improved.

• Payment Channel Layer:

The merchant accesses the gateway.

Page 11: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

6. ALCHEMY Consensus Protocol

The ALCHEMY Consensus Protocol is divided into five layers, namely the access layer protocol (ALCHEMY Connect), the solution layer protocol (ALCHEMY APP), the product layer protocol (ALCHEMY Component), the core layer protocol (ALCHEMY Core), and the network layer protocol (ALCHEMY Net). Each layer of the protocol is through the "smart contract + consensus protocol", in the environment of de-trusting, the operation of the definition, execution, audit, arbitration and other operations in the payment process that require manual participation is automated and transparent.

To truly achieve the goal of decentralization and sustainable evolution, the

ALCHEMY payment network must ensure the scalability of the platform.

Looking at the ISO/OSI network model, the TCP/IP model, and the history

of the HTTP protocol as the cornerstone of the Internet, we can understand

that a perfect software platform will be eliminated with the changes in

business usage scenarios, but one Consensus-based scalable protocol will

be more long-lasting and own its evolutionary capabilities.

Therefore, when building the ALCHEMY platform, we pay more attention

to the construction of consensus-based protocols. It can be said that

the ALCHEMY consensus protocol is the core element of the ALCHEMY

platform and the vitality of the ALCHEMY ecosystem.

Compared with the traditional interface protocol, which focuses on the

"protocol consensus", the ALCHEMY consensus protocol fully utilizes

the power of Blockchain smart contracts. In the context of trust-free,

through the "smart contract + consensus protocol" combination method,

standardized definition of the payment network protocol, it automates

and transparentizes the operation of defining, executing, auditing, and

arbitrating which requires a large amount of manual participation in the

payment process, so as to avoid the need for a centralized organization to

interfere with the normal execution of the protocol.

Corresponding to the product architecture, the ALCHEMY Consensus

Protocol is also divided into five layers.

The ALCHEMY Consensus Protocol

Access layer protocol

(ALCHEMY Connect)

Solution layer protocol (ALCHEMY APP)

Network layer protocol(ALCHEMY Net)

Core layer protocol

(ALCHEMY Core)

Product layer protocol(ALCHEMY Component)

Level 5

Level 4

Level 3

Level 2

Level 1

Page 12: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

Based on these five levels of payment consensus protocols, ALCHEMY and

community developers will provide standardized, out-of-the-box software

implementations, all of which are open sourced. Community developers

can build their own platforms based on standardization or through a

consensus-based protocol.

6.1. The Access Layer Protocol (ALCHEMY Connect)

The Access Layer Protocol includes the access AAA protocol, the

access gateway protocol, and the transaction routing protocol.

• To Access the AAA Protocol

It includes Authentication protocol, Authorization protocol, and

Accounting protocol.

The access AAA protocol defines various types of terminals, devices,

applications, and software systems of the Internet of Things, the

Internet, the mobile Internet, and the POS acquiring network to access

the ALCHEMY network protocol.

Access terminals, devices, and applications include various IoT devices,

smart POS, traditional POS, APP, Web sites, HTML5 applications, and

traditional C/S software systems (such as financial software).

In order to reduce the difficulty of accessing various types of terminals,

devices and applications, and to speed up the docking process,

ALCHEMY and the ecosystem will provide SDKs, APIs, plug-ins,

gateways and other forms to encapsulate the access protocols.

For example, for website software such as WooCommerce, OpenCart,

Magento, Shopify, ZenCart, OsCommerce, Wordpress, etc., which

are commonly used on e-commerce websites, ALCHEMY and the

community will provide standardized plug-ins.

• The Protocol of Accessing Gateway

The access gateway mainly completes protocol parsing, access

management, transaction splitting, transaction routing, notification of

payment processing result, load balancing.

The protocol parsing will be done at the request of the accessing

terminal device and the application according to the access AAA

protocol.

The access management manages the access response of the accessed

terminal device and the application, including session creation

destruction, session concurrent number, validity period, request cache.

The transaction route splits the payment requests into different sub-

requests, and routes them to the corresponding node for processing.

The load balancing performs load balancing on the request packets

according to the load of each node, and ensures high availability of the

access gateway.

• The Transaction Split Protocol

For orders of complex transaction types such as combined payment,

bulk collection/batch payment, one business payment request actually

involves multiple types of accounts and multiple transaction types, and

the access gateway splits these complex transactions according to the

split protocol. It will break down into sub-orders of finer granularity.

• The Transaction Routing Protocol

Because it is a decentralized network, not all nodes support each

service type. Therefore the transaction routing protocol defines the

broadcast protocols and routing protocols that each node supports.

6.2.The Solution Layer Protocol(ALCHEMY APP)

The Solution layer protocol includes product portfolio protocol,

service protocol, service processes and rule protocol, and service

contract protocol.

Page 13: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

• The Product Portfolio Protocol

The product portfolio protocol defines the basic information such

as the information of the product portfolio, the type of product

authorization, the overview of the product tariff, the product access

conditions, and the type of product warranty.

• The Service Process and Business Rules Protocol

The service process and business specification protocol defines

the business process description specification and business rule

description specification of the solution layer product portfolio.

• The Service Protocol

The service protocol defines the solution layer product interface

definition and interface call specification.

• The Service Contract Protocol

The service contract protocol defines the business specifications of the

smart layer related to the solution layer, such as product portfolio tariff,

subscription-type combination product license protocol, escrow-type

portfolio service protocol, the service protocol of directional payment-

type product portfolio, product portfolio Clearing/settlement rule

contract, portfolio credit rating contract, etc.

6.3.Product Layer Protocols(ALCHEMY Component)

Product layer protocols include product definition protocols,

service Protocols, service processes and rule Protocols, and service

contract Protocols.

• product definition Protocols

The product definition Protocol defines basic information such

as product information, product authorization type, product tariff

overview, product access conditions, and product warranty type.

• Service Process and Business Rule Protocol

The service process and business specification protocol defines the

description norms of both the product process and business rules at

the product layer.

• The service protocol

The service protocol defines the product interface norm and the

interface invocation norm.

• Service contract protocol

The service contract Protocol defines the business specifications of

the smart contracts related to the product layer, such as product tariffs,

subscription product license Protocols, managed product service

Protocols, targeted payment product service Protocols, product

clearing/settlement rules contracts, product credit rating contracts, and

products access contracts, etc.

6.4.The Core Layer Protocol (ALCHEMY Core)

It includes the definition account of the core layer Protocol, the

core transaction Protocol, the core payment interface protocol, the

core payment component, the anti-fraud Protocol for risk control,

the credit rating Protocol, the dispute arbitration Protocol, the

escrow transaction protocol, the multi-channel routing protocol,

the core payment smart contract Protocol, and the fee charging

and clearing/settlement Protocol.

• The Account Protocol

The account protocol draws on the accounting subject definition of the

“double-entry bookkeeping method” widely used in the commercial

Page 14: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

society to classify the account, but based on the “non-modification

characteristics” of the Blockchain, the “double-entry bookkeeping

method” is not adopted in the accounting method. Instead, Blockchain

accounting is used.

As can be seen from the 6.1.1 account system, the account system

is one of the most core elements of ALCHEMY payment network. It

meets the needs of commercial payment applications through account

protocols: support for complex account systems, support for complex

payment models, and support for complex transaction types.

• The Core Transaction Protocol

The core transaction protocol defines the processing specifications

of the core transaction system. Including transaction authorization,

combined payment transaction processing, repeated payment, cross-

chain payment transactions, transaction replenishment, transaction

inquiry, transaction accounting and other related protocols.

• The Core Payment Interface Protocol

The core payment interface protocol splits the various transactions

into the finest-grained interfaces to suit the different business flow

and business rule combination definition requirements for payment

components and products.

• The Core Payment Component Protocol

The core layer system follows the SOA architecture, and the core

payment component defines the interface specifications and call

specifications for various standard payment components.

• Risk Control and Anti-fraud Protocol

The risk control and anti-fraud engine rule definition specification,

calling specification, and calling external system interface specification

are defined.

• The Credit Rating Protocol

The credit scoring engine interface specification and calling

specification are defined.

• Dispute Arbitration Protocol

It defines the interface specification of the decentralized dispute

arbitration engine and the calling specification.

• The escrow-type transaction protocol

It defines the interface specification of the escrow-type transaction

engine, invocation specification.

• The multi-channel routing protocol

It defines routing protocols of various external channels, including:

• Bitcoin, Ethereum and other cryptocurrency networks

• Centralized currency exchanges like Binance and Huobi, and

decentralized exchanges like 0x, Loopring, Kyber, plus other OTC

exchanges

• Credit service provider

• Wallet service provider, digital identity service provider

• Legal currency payment network, including Visa/MasterCard/

UnionPay card network, third-party payment network like Paypal

and Alipay, banks and other financial institution networks;

• Risk control & anti-fraud service provider

• Credit information service provider

• Smart Contract Protocol for Core Payments

The core payment smart contract protocol defines the business

specifications of the smart layer related to the core layer, such as

account opening, billing protocol, credit scoring protocol, subscription

class interface authorization protocol, managed class interface service

protocol, directed payment class interface service protocol, clearing

Page 15: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

settlement Contracts, product credit score contracts, product access

contracts, etc.

• Billing and Clearing/Settlement Protocol

It defines the smart contract protocols related to transaction billing,

clearing and settlement.

6.5. The Network Layer Protocol (ALCHEMY Net)

The network layer protocol is a consensus protocol for the

Blockchain network layer, mainly involving lightning payment

networks and cross-chain transactions.

• The Lightning payment network

The ALCHEMY Lightning Payment Network is based on the standard

lightning payment network protocol, but based on the needs of

ALCHEMY commercial payment network, the lightning payment

network has been expanded, including multi-account type, multi-

currency support, account recharge, fast routing, HTLC Atomic Swap,

large Payment, subscription payment, guarantee payment, etc.

• Cross-chain transaction

ALCHEMY cross-chain transaction is based on Atomic Swap technology

to realize cross-chain payment needs.

Page 16: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

7. A Typical Collection Process of ALCHEMY Consensus Protocol

Generate the QR codes, including collection addresses and amount (real-time generation)

On receiving the merchant's cryptocurrency principal, Alchemy will exchange it into stable currencies such as USDT/DAI in real time to reduce currency fluctuations.

Merchants input the amount of fiat currencies

Query the recommended transfer commission of each currency chain (real-time query)

Query the real-time price of fiat currencies against cryptocurrencies (real-time query)

The consumers scan the QR codes and complete the payment process for cryptocurrencies, such as BTC/ETH/TOKEN, etc.

Return information of price inquiries (real-time return)

The merchant account receives the cryptocurrency principal (return the information of transaction in real time and keep accounts; be credited according to pre-agreed settlement cycle)

Return information of recommended transfer commission (real-time return)

Consumer Merchant

Blockchain

Exchange

Page 17: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

8. Lightning Payment Network

ALCHEMY has done a lot of optimization work based on its Lightning Payment Network and other similar technology, in order to satisfy the application of large-scale commercialized payment.

Lightning Payment Network was originally proposed as a secondary

networking solution to upgrade the performance of Bitcoin, and its

research and development process has received a lot of input from

community developers of BlockStream, Lightning Labs, ACINQ, as well as

Stellar and Ethererum Raiden, which promoted the rapid development of

the lightning payment network.

The channel type of Lightning Payment Network is Payment Channel, and

State Channel is similar as Lightning Payment Network, also functioning as

a secondary network solution, but has more application scenarios than that

of Payment Channel, for instance, the RPG gaming state synchronization of

multiple players.

The Alchemy Payment Network will construct the Lightning Payment

Network (including Ethereum Raiden Network) and the State Channel

Network as one of the core infrastructures.

8.1. The demand for Lightning Payment Network in commercial scenariosAt present, Lightning Network/Raiden Network has not entered into

commercial application in large scale, thus there’re still a lot of issues lying

ahead before the required scenarios of Alchemy Payment Network are

satisfied.

• More efficient routing mechanism

• Cash clearing issue caused by the block of the capital in channel

• Multiple tokens sharing one channel, for instance various Ethereum

tokens

• To support PullPay

• More flexible strategies for recharging the channel

• To support large amount of payment

• More flexible strategy of service charge, for example, service charge

on payee, service charge on payer, or zero service charge

• To integrate Lightning Network, Raiden Network and State Channel

Network to support the seamless payment between various tokens

and various secondary networks

• To support the integrated wallet for Lightning Network, Raiden

Network and State Channel Network

• To support Light Client, and avoid the client end, the users at the

mobile end in particular, so as to synchronize the node data

• Better backup strategy for Lightning Payment Network channel

• To support payment via credit

• To support complicated payment types, such as combined payment,

bill splitting, bulk collection/payment, subscription Payment, enterprise

payment etc.

ALCHEMY expands the Lightning Payment Network for these practical

business application payment scenarios, and promotes the popularity of

lightning payment networks.

Page 18: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

8.2. The Alchemy Integrated Structure of State Channel Network

Alchemy Integrated Structure of State Channel Network

To address the need for commercialization of the Lightning Payment

Network described in Section 7.1, the Alchemy Lightning Payment Network

uses an integrated State Channel Network architecture.

Alchemy's integrated State Channel Network consists of the Alchemy

Lightning Payment Network integrated Light Wallet and the Alchemy

Ecosystem Hub.

Page 19: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

8.3. The Integrated Light Wallet of Alchemy Lightning Payment Network The Protocol of Alchemy Lightning Payment Network Integrated Light

Wallet supports Lightning Network, Raiden Network, and State Channel

Network protocols.

The Alchemy Lightning Payment Network Integrated Light Wallet includes

both a merchant APP and a user APP.

Merchants/users can use Bitcoin and Litecoin to pay through Lightning

Network in Alchemy integrated light wallet. They can also use Ethereum

and ERC20 Token to pay through Raiden Network. They can even use TNC

(Trinity Network Credit), STKtoken and other Coin/Token supporting State

Channel to pay through the State Channel Network, or to send messages,

synchronize status, etc.

Alchemy integrated wallet supports cross-network, cross-Coin/Token

payment among different Payment Channel Networks or State Channel

Networks. For example, the payer uses the Bitcoin Lightning Network to

pay the payee of the Raiden Network.

Alchemy integrated wallet supports PUSHPAY and PULLPAY.

The Alchemy integrated wallet and the Alchemy Ecosystem Hub establish

a Virtual State Channel, which supports multiple Coin/Tokens and multiple

networks to multiplex the same channel.

The Alchemy integrated wallet adheres to the Lightning Network's

decentralized, de-trusted architecture concept. It follows the standard

Lightning Network BOLT Protocol and State Channel Protocol, allowing

users to directly establish channels with Lightning Network, Raiden

Network, and State Channel Network nodes, without forcing users to only

establish channels with the Alchemy Ecosystem Hub. It gives users the

greatest choice and avoids centralization and privacy concerns caused by

Hub-and-Spoke.

In order to enhance the user experience, Alchemy integrated light wallet

adopts Light Client architecture, which avoids the long wait caused by

mobile end users to synchronize node data.

8.4. Alchemy Ecosystem Hub8.4.1. The Hub-and-Spoke Architecture of Alchemy Lightning Payment Network

Alchemy Lightning Payment Network Hub-and-Spoke Architecture

Page 20: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

The Alchemy Lightning Payment Network Hub-and-Spoke architecture has

the following features:

• Alchemy ecosystem partners build Hub nodes, and their extended

merchants and users use the APPs and Hubs which follow the

Integrated Light Wallet protocol to establish channels. The channel

type between the Hub and the Light Wallet is Virtual Channel, that is,

the open/close operation of the channel cannot interact with the block

chain.

• Each Hub node integrates Lightning Network, Raiden Network, and

State Channel Network nodes by default. That is to say, a Hub can

support different types of State Channel networks. The Hub can

intelligently route according to the target node network type of Light

Wallet's request message.

• The Lightning Network, Raiden Network, and State Channel Network

nodes integrated by the Hub node implement cross-chain/cross-

network payment between different networks through atomic swap.

• The channel type between the Hub node and other Lightning Network

nodes and the Raiden Network node is Payment Channel. The channel

type with the State Channel Network node is State Channel.

• Each Alchemy Ecosystem Hub node automatically establishes

a channel with other Alchemy Ecosystem Hub nodes, and the

established channel is a virtual channel.

• In addition to supporting the creation of channels with the Hub, the

Light Client can also directly establish a Payment Channel with other

Lightning Network nodes and Raiden Network nodes. It can also

establish a State Channel with the State Channel Network node.

• User funds are stored in smart contracts, thus Hub and others can

only use the funds when they are authorized by the user. They are not

centrally hosted on the Hub node.

The channel of the Alchemy Lightning Payment Network Hub-and-

Spoke includes the following types:

Channel Type Functionality

Lightning Network Payment Channel

Payment Channel

The Lightning Payment Network channel by which Bitcoin, LiteCoin, etc. follow the BOLT protocol.

The channel's open/close needs to interact with the Blockchain.

Raiden Network Payment Channel

Payment Channel

Abide by the BOLT protocol, but mainly for the ERC20 Token channel. The channel's open/close needs to interact with the Blockchain.

Ledger Channel Payment Channel

An alias for the Payment Channel that supports the Coin/Token of the State Channel. The channel's open/close needs to interact with the Blockchain.

Virtual Channel State Channel

The difference with the Ledger Channel is that Virtual Channel's open/close/update operations do not need to interact with the Blockchain.

8.4.2. The necessity of Alchemy Ecosystem HubIn order to achieve the goal of large-scale commercial operation, the

lightning payment network and related solutions must provide a less

costly, more flexible and more open solution than the existing mature

legal currency. The requirements described in Section 7.1 are typical

requirements in real-world payment scenarios, and existing lightning

Page 21: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

payment networks and related solutions are difficult to meet these needs.

The reason is that the goal of the lightning payment network design is a

general-purpose network, so it must be balanced among decentralization,

de-trust, efficiency and network security, as well as privacy.

There is a certain degree of trust between merchants/users and partners

expanded by Alchemy ecosystem partners. The Alchemy ecosystem

partners have business relationships with merchants, and the partnerships

are governed by commercial contracts, and ecosystem partners provide

payment services to merchants. The user's willingness to use the merchant

service means that the user has a certain trust relationship with the

merchant, and therefore uses the merchant-end integrated payment

service.

Therefore, in such a commercial application scenario, the use of Alchemy

Ecosystem Hub does not harm the decentralization, network security, user

privacy, etc. of the lightning payment network, and can greatly simplify the

mechanism of lightning payment network’s routing, recharging, watch-

tower, etc. At the same time, it can optimize the problems of clearing and

channel reuse caused by channel capital lock.

8.4.3. Why Alchemy Ecosystem Hub is not a centralized designFor the Hub-and-Spoke design, it is easy to cause "centralization" concerns.

Identify the characteristics of a "centralized" platform or network

like Visa or Bank:

• Who really owns the funds, and who controls the funds?

• Is there a centralized management agency?

• Is the governance rule of the network open and transparent?

• Does the user have the freedom of choice? Or can users establish a

connection with other nodes without going through a certain node?

The Hub-and-Spoke design is not a centralized design for the

following reasons:

• The funds of the channel established by the merchant/user and

Alchemy Ecosystem Hub are stored in the smart contract. The

ownership of the funds belongs to the merchant/user. The merchant/

user can actively close the channel at any time to retrieve the funds.

Hub cannot directly use the merchant’s/user’s channel funds.

• The Alchemy Ecosystem Hub is built on the Lightning Network, Raiden

Network, and State Channel Network and adheres to the standard

specifications for the Off-Chain network. The core function of every

Alchemy Ecosystem Hub is the standard Lightning Network/Raiden

Network/State Channel Network node.

• Alchemy Ecosystem Hub does not have a centralized management

organization. Network governance rules are based on smart contracts

and blockchain consensus protocols, open and transparent.

• Merchants/users can create channels with Hub to enjoy the

optimizations brought by Alchemy Ecosystem Hub. At the same time,

the merchant/user can establish channels with other Hub or Lightning

Network, Raiden Network, and State Channel Network nodes.

8.4.4. Alchemy Ecosystem Hub's focus on the Optimization of the Lightning Payment Networks8.4.4.1.More efficient routing mechanismThe channel between the similar network nodes such as Lightning Network

is a 2-party channel. Through the routing mechanism between nodes, two

nodes without establishing a channel can complete the payment. This is

extremely important to ensure that the Lightning Network is decentralized

and de-trusted. However, the routing mechanism is complicated and the

Page 22: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

routing efficiency is low.

The Alchemy Ecosystem Hub is an N-Party channel between the Light client

nodes. Nodes belonging to the same Hub only need to route through the

Hub, and do not involve complex routes. Nodes belonging to different

Hubs can be routed to the target node through the channels between

the two Hubs. The Hub node should establish contact with the Lightning

Network, the Raiden Network, and the State Channel Network node, and

meanwhile proxy the local node through the corresponding network

integrated by the Hub node.

At the same time, since the channel funds of Alchemy Ecosystem Hub do

not need to be locked in a specific channel, when routing, the funds of

each node can be utilized to the maximum, and the routing complexity

caused by the payment amount is effectively reduced.

8.4.4.2. Clearing problems caused by channel funding lockoutIn the Lightning Network, Raiden Network, and State Channel Network

design, when sharing the payment channel with the peer node, both

parties need to deposit a certain amount of Coins/Tokens to the channel.

When the same user and different nodes open multiple channels, the funds

of these channels cannot be reused. This kind of design is not the most

optimal solution economically.

Alchemy Ecosystem Hub uses the Revive [7] protocol to achieve dynamic

balance of funds under the off-chain channel, thus solving the clearing

problem caused by channel capital lock-in. A more flexible channel refill

strategy can also be supported based on the Revive protocol.

Inter-node routing mechanism belonging to the same Hub

Routing mechanism between Hub node and lightning payment network node

Routing mechanism between different Hub nodes

Page 23: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

Rebalancing Protocol of Revive

Leader

Signal Rebalancing

Rebalancing Init Req

Participation Confirmation

Channel Freeze Request

Full Rebalancing Transaction Set

Signed Commitment

Full Signed Commitment Set

Dispute

Frozen Channels ConfirmationRebalance Objectives

Blockchain Participant

8.4.4.3. Multiple Tokens sharing one channelSimilar to the Raiden Network and State Channel Network design, the

Ethereum ERC20 Token is used to establish a channel with the peer node.

For each type of token, a separate open channel is required, which results

in the situation that use of multiple ERC20-based Tokens for the same

user in the Raiden Network, while all tokens need to establish a bunch of

channels. This will lead to a poor user experience, and will also increase the

cost of opening channel/closing channels and channel routing.

Alchemy Ecosystem Hub uses Multiple-tokens-Smart Contracts to

implement different Tokens (eg ERC20) based on the same blockchain.

8.4.4.4. Support for PULLPAY

For the Subscription and Recurring Payment scenarios, Alchemy Ecosystem

Hub extends the ERC20 standard protocol and Raiden Network to support

the PULLPAY protocol.

Alchemy PULLPAY is divided into two categories: PULLAY based on

Ethereum Blockchain; PULLPAY based on Raiden Network.

For PULLPAY support, refer to Section 8.PULLPAY for details.

8.4.4.5. To Integrate Lightning Network, Raiden Network, State Channel NetworkEach Alchemy Ecosystem Hub’s default installation integrates mainstream

Off-Chain solutions, including Lightning Network, Raiden Network, and

State Channel Network.

Alchemy Ecosystem Hub's Off-Chain integration solution has the

following features:

• Transparent to the Light Client protocol

The channel type established by the Light Client and the Hub is Virtual

Channel. The Virtual Channel supports both the Lightning Network

BOLT protocol (including the Bitcoin Lightning Network and the Raiden

Network) and the mainstream State Channel Network.

The channel management and payment routing of the Light Client and

various types of Off-Chain networks are handled intelligently by the

Hub, which reduces the difficulty of the Light Client.

• Compliance with standard rules

Hub integrated Lightning Network, Raiden Network, and State Channel

Network can be regarded as corresponding network standard nodes.

• Different Off-Chain, On-Chain networks can be payable across

Page 24: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

networks and cross-chains

With Atomic Swap, Alchemy Ecosystem Hub supports payments

between users of different Off-Chains. For example, the user pays

to the merchant of the Raiden Network using the Bitcoin Lightning

Network.

At the same time, Submarine Swaps enables cross-chain payment

between On-Chain and Alchemy Ecosystem Hub's Off-Chain network.

• Support both Payment Channel and State Channel

By supporting the State Channel, you can better meet the non-

payment interaction requirements in the payment scenario, such as

state synchronization, real-time location sharing, instant messaging,

and message push.

Typical application scenario: Buyers and sellers need to communicate

through established channels before generating a transaction.

8.4.4.6. More Flexible Surcharge Collection StrategyFor platforms like Ethereum, every transaction requires the payer to pay the

gas fee. There are many problems in this realistic payment scenario, such

as:

A. Conflict with the inherent habits of consumers

According to the existing electronic payment habits, the payment fee is

paid by the merchant in most scenarios. Paying the gas fee by the payer

can cause a lot of problems.

A typical example: merchants receive 1 ETH, customers pay according to

1 ETH, because the gas fee is paid by the payer, and most wallets use the

internal deduction method (automatically deduct the handling fee from the

payment), the merchant receives less than 1 ETH .

B. Consumers want to use Token, there must be enough ETH in the wallet

to pay the gas fee

A typical example: A consumer must establish a channel with the Alchemy

Ecosystem Hub, and there must be a sufficient number of ETHs in the

wallet.

C. Need to be able to support the "parent account - sub-account" mode,

as the sub-account does not hold funds, and the parent account holds

funds, therefore the fees are paid by the parent account.

Typical application scenarios include corporate/personal credit card sub-

accounts.

Alchemy Ecosystem Hub is implemented through a smart contract

with DAPP/Light Client:

• A unified identity authentication system between DAPP/Light Client

and the Hub

• The Hub will represent DAPP/Light Client to pay gas fees. This allows

the DAPP/Light Client to interact with the Hub without owning the

ETH, for example, to set up a Channel with the Hub.

• DAPP/ Light Client can authorize multiple Ethereum addresses or

multiple devices to use the funds and authorized funding limits hosted

in smart contracts.

• It supports flexible fee-collection strategies, including payment by the

payer, payment by the payee, and the payee/payer sharing a certain

percentage, no fee-charge.

Page 25: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

9. PULLPAY9.1. PULLPAY vs. PUSHPAY

9.2. PULLPAY

Information flow Cash flow

The user actively initiates the transfer (push mode)

Consumer’s wallet > merchant’s wallet

Consumer’s wallet Merchant’s wallet

PULLPAY mode 1: Pre-authorization mode

Alchemy

The consumer need to authorize Alchemy automatic deduction for the first time they use PULLPAY

Gets the authorized list

Send payment request regularly

Check authorization list and cancel authorization

Regular deductions(Pull Mode))

Consumer’s wallet Merchant’s wallet

Alchemy PUSHPAY (The user actively initiates the transfer)

PULLPAY mode 2: Lightning Network mode

Lighting network node

Establish two-way channels with lightning network nodes

Establish channels withlightning network nodes

Send payment requestactivitely

Check the channel list and close the channel

Check the channel list and close the channel

Deductions actively(pull mode)

Consumer’s wallet Merchant’s wallet

Alchemy PULLPAY System Architecture

The Alchemy PULLPAY Protocol is mainly composed of PULLPAY smart

contract and application and service of DAPP and Off-Chain.

9.2.1. PULLPAY Smart Contract and DAPP

PULLPAY Smart Contracts and DAPP provide the PULLPAY

infrastructure, including:

• Merchant Product, Plan, Promotion Management

It provides merchants with management tools over product, marketing

plan and promotion.

Page 26: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

Product is a description of the product attribute that the merchant

subscribes to, and the product does not contain price-related

information.

The marketing plan is a description of the rules such as the price,

expiration date, and subscription conditions of the subscribing

product.

A promotion plan is a business-to-product subscription discount,

discount, and other related information.

• User subscription management

The user manages the subscription information of the merchant

Product and Plan.

User subscription management includes several types of Batch

PULLPAY, Recurring PULLPAY, and Usage Based PULLPAY.

Batch PULLPAY is mainly used for the management of batch user

subscription information, such as group subscriptions for group users.

Recurring PULLPAY is also known as the Subscription/Recurring

subscription. Each deduction is fixed. For example, a one-year

subscription to a video service is deducted monthly.

Based on the usage-based subscription (Usage Based PULLPAY),

the amount of deduction is not fixed, and the amount is deducted

according to the specific usage. For example, Uber charges after the

service.

• Authorization Registry

To support Alchemy PULLPAY, users need to actively authorize the

Alchemy platform's address to initiate a debit to their wallet and add

the Alchemy platform to the trust list. The underlying technology

relies on the platform's smart contract mechanism, such as approve/

allowance/transferFrom/transfer in ERC20.

The Authorization Registry is used to store user authorization

information, including merchant identification, Alchemy transaction

proxy address, authorization type, total authorized amount, start time,

end time, debit period, debit amount, subscription type, subscription

ID, and so on.

• Scheduler

A task timing scheduler based on a block chain. It’s used to schedule

DAPP/smart contract execution timing tasks such as Job processor.

• PULLPAY Job processor

The Scheduler periodically schedules the PULLPAY Job Processor to

require the user subscription information to generate the invoice and

debit schedule tasks for the next period. The PULLPAY Job Execution

Engine is used to perform the debit task for invoices and tasks that

match the current period.

The Usage Based PULLPAY proceeds as follows: the merchant platform

calling the API to initiate a debit request, the PULLPAY Job Processor

generating the current debit invoice and mobilizing the Job Execution

Engine to perform the debit task.

• PULLPAY Job Execution Engine

It’s divided into two categories: Batch Execution Engine and Execution

Engine. The Batch Execution Engine is used to perform the debit

operations for bulk subscription task. The Execution Engine is used to

perform the debit operation for a single subscription task.

• Transaction Proxy

Transaction Proxy is a unified proxy service initiated by the Alchemy

PULLPAY protocol for blockchain/Layer 2 blockchain deduction/

authorization operations.

When the user initiates an authorization operation (including a

blockchain, a Layer 2 network such as a lightning payment network),

Page 27: The Alchemy Yellow Book on Payment TechnologyThe ALCHEMY Decentralized Payment Network 9 5.2. The Merchant Partnering Network 9 5.3. The External Service Network 9 5.4. The Technology

01. Preface

02. Core Technical Advantage

03. Core Business System

04. Product Architecture

05. Technical Architecture

06. Alchemy Consensus Protocol

07. A Typical Collection Process Of Alchemy Consensus Protocol

08. Lightning Payment Network

09. PULLPAY

10. Reference Material

the authorized address is the Transaction Proxy address.

The PULLPAY Job Execution Engine initiates the actual debit operation

via the Transaction Proxy.

• Oracle

It provides interactive services for blockchains and external data and

services for PULLPAY calls. For example, to get the result of the quiz,

then initiate a deduction.

9.2.2.Off-Chain applications and servicesOff-Chain applications and services include anti-fraud for risk control and

application interface (API).

The anti-fraud for risk control mainly conducts risk control and anti-fraud on

the merchant's subscription request and deduction request, and eliminates

the malicious deduction and illegal subscription of the merchant.

The application interface encapsulates the PULLPAY protocol and related

product functions in the form of API, SDK, Plugin, etc., to reduce the

difficulty of merchant access. They include product management, product

planning management, promotion plan management, subscription

management and other interfaces.

10.Reference material

[1] Joseph Poon and Thaddeus Dryja. The bitcoin lightning network:

Scalable off-chain instant payments, 2015.

[2] Raiden network. http://raiden.network/.

[3] Stefan Dziembowski, Lisa Eckey, Sebastian Faust and Daniel Malinowski.

Perun: Virtual Payment Hubs over Cryptocurrencies

[4] Satoshi Nakamoto. Bitcoin: A peer-to-peer electronic cash system, 2008.

[5] Vitalik Buterin. Ethereum: A next-generation smart contract and

decentralized application platform.

[6] Gavin Wood. Ethereum: A secure decentralised generalised transaction

ledger. Ethereum Project Yellow Paper, 2014.

[7] Rami Khalil, Arthur Gervais. Revive: Rebalancing Off-Blockchain Payment

Networks

[8] R. Khalil and A. Gervais. Revive poc implementation on ethereum.

https://github.com/rami-khalil/revive .

[9] Andrew Miller, Iddo Bentov, Ranjit Kumaresan, and Patrick McCorry.

Sprites:Payment channels that go faster than lightning.

[10] Christian Decker and Roger Wattenhofer. A fast and scalable payment

network with bitcoin duplex micropayment channels.

[11] Kevin Owocki . EIP-948 : Recurring Subscription Models are a Good

Thing and should be viable on Ethereum (Merit + Architecture ERC) . URL

https://github.com/ethereum/EIPs/issues/948