Alex Xu Profile picture
Co-Founder of ByteByteGo | Author of the bestselling book series: โ€˜System Design Interviewโ€™ | YouTube: https://t.co/9gPSJSrtPU

Jan 19, 2022, 6 tweets

In a payment system, itโ€™s very important to separate ๐ข๐ง๐Ÿ๐จ๐ซ๐ฆ๐š๐ญ๐ข๐จ๐ง ๐Ÿ๐ฅ๐จ๐ฐ ๐š๐ง๐ ๐Ÿ๐ฎ๐ง๐ ๐Ÿ๐ฅ๐จ๐ฐ.1/6

In the diagram below, we have three layers:
- Transaction layer: where the online purchases happen
- Payment and clearing layer: where the payment instructions and transaction netting happen
- Settlement layer: where the actual money movement happen 2/6

The first two layers are called information flow, and the settlement layer is called fund flow. 3/6

You can see the information flow and fund flow are separated. In the info flow, the money seems to be deducted from one bank account and added to another bank account, but the actual money movement happens in the settlement bank at the end of the day. 4/6

Because of the asynchronous nature of the info flow and the fund flow, reconciliation is very important for data consistency in the systems along with the flow. 5/6

It makes things even more interesting when Bob wants to buy a book in the Indian market, where Bob pays USD but the seller can only receive INR. 6/6

Share this Scrolly Tale with your friends.

A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.

Keep scrolling