Hello and welcome to Module Three on payments of GSP Gen 544 at Stanford, Health Software Aid Finance. I'm Martin Chavez, I'm your lecturer. We're going to be talking about one of my favorite super-complicated topics. As we've discussed previously, to disrupt something, to transform it, to make it better, it's crucial to understand how exactly it works right now, to learn the lessons of the past. To learn what's working and what doesn't work, and so let's jump in. Let me share my screen. Okay, so let's begin with how a credit card transaction works, a Visa, or a MasterCard, credit card transaction. Looked all over the web, and all over all the records, materials I could find. And it was challenging to find a straightforward yet complex and comprehensive discussion of how all the steps in the life-cycle of the credit card transaction. Of course, we're not going to go into every detail but I wanted to convey clear understanding of the major steps. And so, here's how payments work today. The tech is 30 years old or more. It's, in my view, ineffective, labyrinthine, and slow. However, it works, its pervasive, its global, it's reliable, and it's fascinating. So, let's start off with the entities in a credit card transaction. There are more, but here are the main ones. So, off on the left we have the consumer. Off on the right we have the merchant. We have the bank that issued the consumer's credit card. And that's the card issuer. We have the merchant's bank, which for some reason is called the acquiring bank. And then, floating in the cloud we've got the Card Association, Visa, which is the largest one, closely followed by MasterCard, and, of course, there are others, American Express, Discover, and so on. And let's say, hypothetically, our consumer is paying for a good that costs $100. And so, in the first step, the consumer takes out a credit card and agrees with the merchant to pay $100 on that credit card. What actually happens? Well, the first step Is The consumer presents the credit card to the merchant, and the merchant, typically, using some kind of payment gateway will send the transaction information to the Card Association. And the transaction information will, of course, include the detail and that magnetic stripe for that chip and the credit card, as well as the amount of the transaction, and the identifier of the merchant. So, that information goes by the payment gateway to the Card Association. The Card Association then does something incredibly complex. And it orchestrates a conversation between the card issuer, the consumer's bank that issued the credit card, and the acquiring bank, which is the merchant's bank, where the merchant's bank account resides. And in that orchestration, the Card Association sends the information to the issuing bank, and the issuing bank will either approve or decline the transaction. Let's suppose that the card issuer approves the transaction. And so then, the Card Association will convey that information, namely that it's been accepted through the payment gateway and to the acquiring bank. And the consumer and the merchant will both see that approved sign flashing on the terminal or whatever device the merchant has chosen to use. Then in the next step, the card issuer keeps an interchange fee. So, it's going to deduct roughly $1.75. And these are approximate numbers. The details are actually more complex. But they're illustrative and they're in the right zip code in terms of their magnitudes. The card issuer is going to keep $1.75. That $1.75 is going to compensate the card issuer for a number of things, including fraud, including floating, or up fronting the payment amount. And we're going to see that shortly when the consumer is going to pay the bill, perhaps, as much as 30 days or maybe even slightly more, after the fact. So, there's the float in there. There's the rewards. There's many other things, and the card issuer is going to collect roughly $1.75 out of $100 to provide all of those services. Then, after keeping that $1.75, the card issuer is going to send the remainder via ACH, which we'll talk about in a moment, typically, to the acquiring bank. If it's international, there are some more details in here, but let's keep this simple. And so, $98.25 is going to go over the ACH trail to the acquiring bank. And you can see ACH clearing the payment. Then the acquiring bank is going to collect a processing fee, which is typically on the order of $0.07 for this $100 transaction. And then there's going to be an assessment fee, which is typically on the order of $0.18 for this $100 transaction. In other words, the acquiring bank's going to keep $0.07 for itself, and it's going to send $0.18 to the Card Association. And then what's left, $98, so, $2 less than the original $100, that's actually going to be credited by the acquiring bank into the merchant's account at the acquiring bank. And so, that amount will show up as soon as this processing has occurred, in the merchant's bank account. So, there's a couple of things to note. First of all, we started with $100. And there were a bunch of these taken out, the large of which is the interchange fee collected by the card issuer. And then $98 is what happens at the end. And that's what goes into the merchant's bank account. And, of course, there is another step in here. Which is, once a month, the card issuer is going to deliver the monthly statement to the consumer, and the consumer is going to pay some portion of that bill as per the terms of the credit card. You can imagine that that's pretty similar if there's a debit card involved, except this last step of the monthly statement will not occur. Here's something that I wanted to call your attention to. So I mentioned the interchange fees, and there's many kinds of risks and costs that the card issuing bank incurs. And the dollar 75 interchange fee is the compensation to the card issuing bank. There's a lot of risk involved. I also want to call your attention to this 18 cents. Now in the scale of things, it's certainly not the largest payment that's much smaller than the interchange fee. It is larger than the processing fee, but important to note that there are many acquiring banks and many card issuing banks. But there are only a small number of card associations, there's effectively a duopoly of Visa and MasterCard. And so, these four, it's crucial role in the orchestration and getting all these banks. And all of these payment gateways, all of these merchants and all of these consumers to work together. The card associations collecting this slice out of every $100. And when you scale that up, and then when you also look at the risks and capital costs incurred by the card association. Well, its costs are mostly paying its people. And then there's also a lot of machines and there's a lot of software. That's a lot of work required to deliver this global, highly resilient, highly reliable performance. The card association is not taking on the progress, and it's not handling the rewards. All of those things are handled by the card issuer. And so it is a brilliant and amazing business model, especially when you consider the vast amounts that are charged every day on credit cards. So there's an incredible convenience and valuable service that this is a toll. That is a percentage, admittedly small percentage, but on the total dollar amount of everything. And so I think it won't surprise you to know. That is the last day I checked, which was some point in early March and it's almost certainly still the case when you're watching this lecture. Interestingly of all the companies who participate in the financial ecosystem of any stripe, whether the clearing houses exchanges, market data providers, investment banks, consumer banks, retail banks, commercial banks, the entire ecosystem. The single company with the largest market capitalization is Visa. It's bigger than JP Morgan chase. It's bigger than any of the banks. And so definitively shows the value of being at the center of this complex. Well So now let's talk about some other ways that money gets transferred around. You've all almost certainly heard about the Fedwire. And when we're talking about wiring money to someone, well, I'm certainly talking about the Fedwire. Though there are other mechanisms for fought for wire transfer and we'll talk about some of those. It won't surprise you to learn that the Fedwire is operated by the Federal Reserve. Important to consider that it is a real time gross settlement funds transfer system. Gross settlement, meaning that if there's payment for a million dollars and another million dollar payment, and they're going from one place to another. And both of those transactions are those payments are going from the same destination, the same source to the same destination. Those are separate transactions, they're not combined or netted in any way. And that's what we mean by the term gross settlement fund transfer system. It is not 24 by seven, and not even remotely and we'll talk about some of its other features. Now it is important that the Fedwire be incredibly resilient since it is the core of everything. You could argue that that wire for dollar transfers and Fedwire security services for transfers of treasury securities electronically. And together with the repo market or really the deal deep, essential plumbing of the financial system that must work at all times. And especially must work in a crisis and failure and that the plumbing and the crisis is only going to exacerbate the crisis of competence. And indeed, during the recent and current COVID-19 crisis, the Fedwire continued to do its job part of why continued to do its job. Is that there are three separate data processing centers as the primary. There's the hot backup, and then there's the warm backup. The hot backup means at keeping up the transaction by transaction, the primary goes out. The hot backup seamlessly picks up, the warm backup will take a little effort but it can cover for and pick up from the hot backup if that were ever necessary. And as redundant power systems as dual network operation, it will customer service centers, it's got environmental control systems emergency control systems centers separated by hundreds of miles. So it's seriously redundant, perhaps not as redundant or definitely not as redundant as something like the Internet. Which was designed by DARPA to resist a nuclear attack and to be heavily redundant. At every level of its architecture, Fedwire for all its resilience is not quite there. The stats on Fedwire are impressive. I want you to remember this number in 2019. It handled a gross notional value of payments with $700 trillion, to put that in perspective, the entire GDP of the US is in the 20 trillion range. And so that's 700 trillion across the year. There are 167 million transactions on the Fedwire in 2019. And so just dividing those two shows us that the average transaction size is just over 4 million. Of course the distribution of those transaction sizes is quite large, and it does nevertheless suggest that Fedwire. These two kinds of things you'd expect like settlement between banks, sometimes between banks clearing houses, settlements of larger dollar transactions. For instance, the closing and funding of a home mortgage. Another system that you might have heard about, but I would say almost all of us use in some way. Is the ACH also known as the National Automated Clearing House or Nacha. This is for use these for electronic funds transfers in the US. Many if not all of us have received tax refunds from the government and they are deposited directly deposit. You've heard that, when you hear direct deposit, you're talking about ACH. Many perhaps most or all of us have received payroll amounts from our employers, and those are also typically direct deposited to. And again, that is ACH at work, insurance premiums, mortgage loans to wish on often paid this way. There's complicated nomenclature of ACH. We're not going to go through it in great depth but important to understand it conceptually. There's an Originating Depository Financial Institution, the ODFI. And then the Receiving Depository Financial Institution, the RDF. I mentioned them because it's important to note that the ACH transfers operate between depository institutions or banks. And they do not operate between a company to bank or company, another company or consumer and any one of those entities. ACH payments can take up to five business days to receive acknowledgement of success or failure. So it's a very, very long ways from real time. Large parts of the ACH still occur on FTP or internet File Transfer Protocol of batch file. They're typically comma separated values or CSV files that happened at the end of the day. If you in addition are using a service such as Stripe, Stripe says on its website that by the time all is said and done and all the dust is settled. And we're looking at holidays and other such things, it can take up to 7 days for ACH payment to be reflected in Stripe. There are roughly 25 billion ACH transactions per year, 30% of those were direct debit transactions. 15% of them were B2B payments, the various kinds to put ACH in context handle the gross notional $56 trillion in 2019. That's to be compared to $700 trillion for Fedwire. And as I mentioned, there were 25 billion transactions meaning that the average transaction size was a little over $2,000. You can imagine, an average transaction being something more like a payroll transaction or tuition payment, rather than the 4 million average transaction size of that wire. Many more transaction of much smaller size by orders of magnitude and takes an awful lot longer. That wire is is really fast, though many of us have had the experience that of asking someone on the phone. Have you gotten the wire transfer? Have you gotten the wire transfer? And sometimes the delays if you're a person working with your bank and then there's a recipient person working with her bank. By the time both people know that the Fedwire transaction has gone through, it can be a little cloudy. And it can take some time and it's not quite as crystal clear as ordering up a Domino's Pizza and looking on the website to see exactly what state your pizza is in. But it is an awful lot faster than ACH. So I'm not going to go through this in gory detail but here is a diagram. And we got the content from the diagram off of one of the natural websites. And here it shows exactly what happens at what time on each of the days as the transaction goes between the Originating Deposit Institution and the Recipient Deposit Institution. And you can see that it can start off on day one over there on the right with the ODFI. And given various cut offs and deadlines and across the way and as I mentioned the batch transfer over FTP, CSV files. By the time further, the customer account is finally credited by the receiving bank that connects that can be on day four. And there's other potential lags, that can increase the timeline all the way out to five days. And then if you've had all of this wrapped by someone else, such as Stripe given various other delays. Stripe says in the worst case it can take seven days for the transaction success or failure to be acknowledged, back to the original sender So now we're going to talk about another important payment system which you might hear less about which is called CHIPS. CHIPS stands for the Clearing House Interbank Payment System. This one is actually owned and operated by the banks. You can think of it as an alternative to Fedwire. It's super important for contingency planning. It serves the largest banks across many countries, 19 countries and here there's 270,000 payments day with a daily gross volume of 1.4 trillion. And you can see that that takes it up to a territory of less than, the Fedwire in terms of total gross amount, but much greater than ACH. It is real time, it's got payment annuity, super important property payments done can't be rescinded or retracted, no do overs. The payments contain detailed remittance information, which is super important for bank systems on both sides to further credit and process the transaction join all those database records. Hugely important features that there is, multilateral netting and a later lecture and session six. I will get into netting in some detail we will talk about bilateral and multilateral netting, and why those reduce risk and complexity and the total amount of transaction. As a consequence of this multilateral netting, so to take a trivial example, two payments going from the same source to the same destination. Within some specified window time, are most likely, I'm certainly going to be combined into one payment. And then let's imagine there were payments going the other way between those two institutions. You might have five payments going one way, and ten payments going the other way. They all happen within the same netting window that would really only be one payment which would be the arithmetic sum of adding up and then subtracting all the payments going the other way. And so, as a result of that and that's just a simple bilateral knitting example, we get even more compression when you do multilateral netting among many things. To send all those payments the gross volume of 1.4 trillion. Typically, there's only about $2.8 billion in funding transaction that needs to happen on a particular day. Among all the banks, these large banks in 19 Countries that participate in the system. I thought it was eerie and significant that the actor on the right with some of the members of that show, California Highway Patrol looks an awful lot like Professor David Dodd. So I mentioned a little bit about how CHIPS works. The details are fascinating And as I discussed, there's netting, there's individual netting. So a bunch of payments going from A to B within a particular Bank A, those will all be combined if they're happening within a certain window of time. We can net across pairs of banks and then we can step back and look at all the payments flowing across the system. And potentially collapse those systems, those payments and simplified the total transaction. So the prefunding would just make sure enough to fund that day's payments. It's a lot less than the actual payment amount, and it's calculated on a look back basis. So you look back at what's happened in the prior six weeks to estimate how much a typical bank is going to mean for prefunding. This goes through the timeline, starting at 9PM the day before, then ending at 5:15 PM. And there's multiple batches of payments and there's multiple times during the day when payments become finalized. Which is when there is an edit a multilateral netted batch is released and the banks have made the payment. Because chips have deducted the net payment amounts from the bank accounts with chips. And then chips net any of the unresolved payments and that's how we enter the next day. There is a credit limit extended by chips, and so if the bank has a spike in payments, well it can't exceed more than twice what was prefunded. And of course that spike in payments is going to factor into the calculation. So that the banks are going to end up increasing their pre funding amounts. But importantly, the banks are maintaining positive balances with chips that can handle all of the transactions through the course of the day. FedNow, so it is a proposed new 24 by 7 by 365 real time interbank gross settlement payment service that's got clearing built in we got a whole lecture to talk about clearing super important. It was announced by fed Governor Lyle Brainard in August of 2019. The intent with bed now is to process individual credit transfers at less than $25,000 within seconds. The payments will settle just as in fed wire through debits and credits to those balances in financial institutions master accounts at the various federal reserve banks. Of course, we've talked at great length about Federal Reserve deposit already. And then as part of the FedNow service, but that is going to require financial institutions to make funds available in their customer account immediately. So none of that extra waiting, have you gotten that wire transfer yet. Which is mostly as I mentioned, the awaiting for further credit once the bank has already received the amount for further credit to the customer's account. That waiting period needed to go away to come back and come comply with the FedNow back. Importantly, and this is a difference from the current setup where the Fed wire doesn't actually contain all that much remittance information. FedNow is going to comply with an International Standard ISO 20022. And two that's going to allow other bank systems of various kinds to do interesting things with that remittance information. Now, stepping back and looking at all this, this is wonderful, but it is a request for proposals, it's still early days. And to put it in perspective, the UK has had this functionality since 2007. I've lived in the UK and I still have my UK bank account, if I want to send money to someone in the UK, I just put in their bank short code and their account number. And I can do this online and it's got all kinds of encryption and authentication. And if whatsapping the recipient, every time I've ever done this within a second, the recipient will say, yeah, I see the transaction in my account. So, UK has had this around for 13 years and just for a little context 2007 was the year the Dixie Chicks won the Grammy for Best Album of the Year. So what does Google think about FedNow? Well, Google's constructive, some critics have referred to FedNow, as said yesterday, and I suppose that reference to the fact that other countries such as the UK have had the capability for a long time. But here's what Google said to the Fed, which was constructive, they're encouraging the Fed. To support low value and high value payments with the same service level agreement in very low processing costs. And to use standard messaging protocols don't invent the new ones, and have extended an arbitrary metadata. On top of that ISO standard for remittance information, and this relates to something we talked about in session one provides clear standards for an API layer, and that is incredibly important. So $1 bill, as we talked about is a bearer bonds, that's not a lot that you can do with that dollar bill. But there's two really important things that you can do with the dollar bill. Well first we talked about you can take it to Federal Reserve Bank and get another note. And the second super important thing we talked about is it it's legal tender and the tendering of it causes the extinguishment of the debt. If you're within the bounds of the jurisdiction of the sovereign as the sovereign interprets its jurisdictional bounds. And so, well, that's all super interesting and super important, but you notice that the actual dollar bill is quite a passive thing. It just gets handed around and then there are a couple of side effects of this being handed around. In one case, a side effect is you get handed back another dollar bill, and the other case, the side effect is the extinguishment of a debt. But if money is programmable, it has an API, if it has an API, you can do all things with that money, you can issue requests to the money through the API interface. And then under the hood, something complex and wonderful can happen and so, so in that important sense, the money becomes information, and it becomes alive. And depending on the API and what happened under the API hood in the implementation layer, money can grow, it can evolve, it can change its value. It can enforce anti money laundering and know your clients, it can change its shape, it can participate in smart contracts, for instance delivery versus payment in a securities transaction. Something we will cover in detail in session six, so when money becomes programmable, it becomes alive, it becomes a computer, it's not just this passive thing with side effects. And when it becomes alive, when it becomes something that can compute, it becomes something altogether different altogether wonderful. And so of course, Google is going to insist as I would insist that fed now have strong and useful APIs. Interestingly, Google also proposed that the fed model that now after the unified payments interface UPI framework used in India. Again another example of the US having developed earlier but then having this labyrinthine complex infrastructure that no one completely understand. Stuck or baked in place, whereas developing country can actually skip several levels of implementation and have something quite advanced. That can be a useful model for the nation that developed earlier. I couldn't agree more so let's talk a little bit about the launch timing of FedNow well, it's vague. Here's a quote tending engagement between the Federal Reserve and the industry to inform the final service design. The FedNow service is expected to be available in 2023 or 2024. As a software architect and engineer, I would say he can't even give a delivery date until you have precisely specified what it is you're going to deliver. And you have precisely identified your primary clients, your clients, your primary clients. As the entity for whom you will change your design to persist so that that entity proceeds itself to be satisfied is the primary client Federal Reserve probably, but it's a bit vague. It says engagement between the Federal Reserve and the industry is the industry banks. Is it card associations? Almost certainly. Who else does industry can contain or comprise and are all of those entities the primary client? You change the design to ensure that they perceive themselves to be satisfied, while they're all the primary client is not going to be done by 2024. The Fed goes on to say however, it will likely take longer for any service whether the FedNow service or private sector service. He talked about that to achieve nationwide reach regardless of when the service is initially available. Super important point on FedNow, like ACH, like fedwire, it only allows depository institutions that have master accounts contain Federal Reserve deposits at a Federal Reserve Bank to participate directly. In the system, it's quite different from the E Kroner initiative of the right spunk, which is in your reading list. Which, does preserve the role of banks in the financial system and allows, many other entities to participate. This idea that only depository institutions with master count at Federal Reserve Banks can participate and that is a huge regulatory mode. And as with any regulatory mode, there are pros and cons. So, this will happen in the long run, but as one of my favorite Role Models was known to said frequently, John Maynard Keynes, in the long run we're all dead. I'll pause there, and we'll shortly go on to the next chapter. Emerging Payments Technology. Let's continue with the discussion of Emerging Payments Technology. Commerce is transforming. We all know this as more and more e-commerce mobile commerce, especially now. As we're talking during the time of COVID-19 why shops when you can have it delivered. I know that my doorman in New York has often joked that Amazon all the just install the conveyor belt to my apartment and I buy everything on Amazon. There's also a new development, and we'll talk about some of those with our guest Max Levchin, there's installment Lending at the point of sale. There's all kinds of remarkable things that are going on. Current generation technologies reflect all of this new reality and they've created this new reality. But under the hood, they we still rely heavily on legacy systems. And we'll see a little bit about that. And we'll hear from our speakers on that, and I'm sure you already know quite a lot of this, so let's go through a few of them. PayPal, you all know about PayPal. It's a worldwide payment system. And I think of it as an alternative to paper methods. The old paper methods such as checks and money orders. The success of PayPal is amazing and inspiring $18 billion of revenue in 2019 with 22,000 employees and a market cap of $125 billion. Just to compare it to Goldman Sachs, my former employer Goldman's revenues are 36 billion so almost twice, twice PayPal. Goldman has almost twice as many employees and the market cap of 70 billion is a fraction of PayPal. Of course PayPal is has grown rapidly and is continuing to grow rapidly to frame PayPal that operate in 200 countries, support 200 currencies has 300 million active accounts. In 2019 it processed roughly a total dollar amount of $800 billion cross over 12 billion transactions. That's impressive. I think though it is important to put it in the context of the Fedwire, 700 trillion, or also in the context of ACH, 50 trillion or so. And so there's there's a lot of room to grow here, and potentially a lot of room for competitors. PayPal generate almost three fourths of its revenues from transaction fees. What are those? Well, typically the settler pays the seller sorry, pays 2% of the notional amount. And then in addition 30 cents per transaction so that 2% is on the order of the interchange fee for credit card transactions and that's probably not a surprise. The balance of PayPals revenues come from value added services such as authenticating the buyer, fraud detection, working capital loans. Which is a theme for some of the other disruptors they're going to talk about as well immensely successful. Venmo, think of it as a mobile wallet that lets users make and share payments, typically between friends. It was acquired by Braintree in 2012 for 26 million, you might ask our guest speaker more about how that occurred and then not that much later, PayPal acquired Braintree in 2013 for $800 million Venmo payments do not settle immediately. Then Venmo does offer instant I'll put that in quotes, because Einstein told us nothing is really simultaneous less than 30 minute latency which is good enough for many purposes. And it will offer that in a transfer to bank accounts between your Venmo account and a bank account for 1% fee The payment volume of Venmo was $120 billion in 2019. That's to be compared with the total of PayPal which is 800 billion, so obviously, Venmo's a significant part of PayPal's activity and one could argue a significant part of PayPal's market cap. A question on my mind is, think about WhatsApp with its amazing, its immense superior global distribution. An interesting question and a bit of a puzzle to me, why WhatsApp hasn't offered closed loop payment, something much akin to Venmo within it's much, much larger social network. Zelle, interesting, has arrived on the scene not very long ago. It's now at about a $200 billion run rate in annual transaction volume, making it bigger than Venmo, still about a fourth the size in terms of transaction processing volume, a fourth of PayPal. It's owned by Early Warning Services, which you can think of as a consortium. It's owned by a variety of banks and I've listed some of them here. Operationally, it's a lot like Venmo. You just send money to an email address or a mobile number. There are some differences. Payments are not cancelable, so therefore there's greater fraud risk. There's a limitation. Both sides of the payment must have US bank accounts that are integrated into Zelle. Unfortunately, my bank, which I love, First Republic is not today integrated into into Zelle. So I just can't use it in the way that I would like to, though apparently there is some way to use it. Nonetheless, I don't know how that works. Interestingly, bank can integrate directly to the Zelle API, though many of them prefer to buy vendor products, such as Fiserve, that have that integration built in. So I would say the features of Zelle are near-immediate and no fees. And it does work wonderfully well with the limitations I described on the left, and it's giving Venmo a serious run for the money. Now let's move on to AliPay. And remember to put all of this in context. The total payment volume of the fedwire, 700 trillion, ACH 50 some trillion. We talked about PayPal, so the trillion. And then we talked about, Zelle and Venmo, which are even smaller fractions of a trillion, on the order of $100 to $200 billion. And so now let's look at some things that are huge. So let's start with AliPay. [FOREIGN] I am learning Mandarin along with my five-year-old son, my three-year-old daughter, and a lot of help from Duolingo. So [FOREIGN] means pay or payment and [FOREIGN] means treasure. AliPay is 15 years old. It's got 320 million daily active users, an immense number in 50 markets. Interestingly, it has agreements with 170,000 North American retailers. Why does it have those agreements? Well, they're targeted at the 4 million Chinese tourists who visit North America annually. Ant Financial is the new name of Alipay. Its market cap is $150 billion, and so that's even a bit greater than PayPal. It has a bit more than a 50% share of mobile payments in China. As of late last year, tourists in China can link their foreign debit and credit cards to Alipay. That's an interesting development. But looking at the architecture of Alipay, I would say it's conceptually and functionally similar to PayPal. So there's a closed loop, easy to send money to other people who have accounts with Alipay, and then there are on ramps and off ramps to the traditional banking system. As with PayPal, one can pre-fund digital wallets from bank accounts. But because the Chinese system is quite different than the US system, while the funds do move in and out of the Alipay ecosystem into the Chinese banking system much more rapidly than is supported by the US system. Payment notification is essentially instantaneous. Settlement however, is not. So I mentioned 320 million daily active users, 1.2 billion unique users, 900 of whom live in China. WeChat Pay, the arch rival, it is the main competitor, architecturally and conceptually very similar, also about a billion users. You can see the market share here. Alipay at 53%, WeChat Pay 39% and a few others in smaller amounts, together handling $47 trillion in payments annually. So that is on the order of the the ACH system in the US, still much smaller than the Fedwire. If we were to look at other differences between WeChat and Alipay, they have different origins stories. So WeChat has origins that remind me of Facebook in P2P, as well as social media. And Alipay's roots, not surprisingly, given it was originally part of Alibaba, Alipay's roots are Amazon style digital commerce. There was an epic event, which you might have heard of. It was called the Red Envelope War [FOREIGN]. And in the Red Envelope War, well, WeChat introduced the ability to send digital envelopes rather than packages, which is a tradition in the Chinese new year, a super important holiday. And Alipay copied that functionality, essentially what goes on in other tech wars. And now we are in a state where over $100 billion gets spent on every Chinese New Year holiday. As I'm thinking about WeChat and Alipay, really an interesting question arises. When we think about payments, is that really a part of commerce or is it a part of banking? And if you ponder that question, you'll see that it matters. And based on whether you come at payments from banking, or whether you come at it from commerce, you might come up with extremely different and performance and functionality. So now let's talk about some of our other favorite tech disruptors, Stripe. Is it a payment processor or is it something more? So here's how Stripe describes itself. Stripe is a technology company that builds economic infrastructure for the Internet. Increasing the GDP of the internet is stripes mission in its own words. I love the way to think about stripe as a brilliant example of a pure, almost pure API play, meaning everything is API's from beginning to end, anything that stripe can do it. Does through an API that is the way to access its products and services. And in my view, stripe heralded a whole new era of API APIs by making the documentation Impeccable, brilliant, crystal clear, unambiguous, and that was the key to an amazing thing which is stripe, essentially selling itself. Stripe made its API's discoverable on the internet is easy to play with. And developers just ran across it and said, well, this really solves my problems and makes it almost trivial, back to the early discussion of API's at the beginning of our course, hiding incredible complexity. You make a simple call the producer, the API does it thing, you don't need to know why or how, the producer can change the way it does its thing and all kinds ends of ways. Again, you don't need to know high, why or how, it just does what it does and you get the answer back, with the side effects that you expect consistent with the answer. And so no question that in the case of stripe developers are the primary customer in other words, stripe will change its design to ensure that developers engineers perceive themselves to be satisfied. Other people are welcomed to consume stripe API's, but stripe will not change their design to ensure that those people perceive themselves to be satisfied. And so those would be the second secondary customers. Now, to put it in perspective, right now as of 2020, only 3% of global commerce happens online. No doubt that statistic is changing and the during this time of COVID-19 unlikely in the wake of the virus, even so there's still plenty of room for growth. How does stripe work, well, I could spend all day diving into stripe documentation is so beautiful and when we had Goldman Sachs began our API journey. I told Patrick Collison, who's the co founder of stripe together with his brother john that the way you document your API's is the gold standard. And we're going to document our API's and exactly the way it looks to actually to the standard that you do. And so if you just look on stripes website and you've given links in the reading materials, you can see the show how to accept credit card payments. And perform myriad other tasks but here's an example of accepting credit card payments and they show how to do it in just a few lines of code. The API, as we've discussed, abstracts away the incredible and labyrinthine complexity of the payment and credit card processing system into just a couple of simple API code they can do in any programming language. Plaid has been much in the news, it produces API's that connect customers financial institutions and developers. It's 2019 revenues aren't a matter of public information reliable estimate suggests they were between 100 and 200 million. In January of this year, the FDA announced the acquisition of plaid for a little over $5 billion so, depending on the reliability of those estimates, that's a multiple of 25 to 50 on revenues. To put that in perspective, Visa and MasterCard invested 250 million in plaid December 2018 series D valuing it just under $3 billion. That's a good building value in a year. Many use the API's that plaid produces Venmo, Amex, coin base are some examples, plaid connects 200 million consumer bank accounts across 11,000 banks. And so why did these acquire plaid? Well, I just be speculating, but I will note that the acquisition gives a piece of control over foundational infrastructure and it gives these insights into the activities of them know and other customers have plaid. So how does plaid work? Well, you can see the analogies to stripe and they also have plaid offer beautiful documentation online, there's really simple API's. I've given an example on the right, the API's categorizing, analyze retail transactions. Check balances at depository institutions remind consumers of upcoming debt payment, suggest refinancing and consolidation options analyze investments including balances and transaction. Authenticate bank accounts for HDH payments such as payroll and doing this in a modern and sophisticated way, far beyond the original HTML web scraping that used to happen to gather this data in one place. So now let's go on and talk about some emerging blockchain enabled payments technology, one of my favorite topics so let's leave aside the the peer exchanges. And we'll get to hear from a guest speaker Brian Armstrong about his exchange which is a leaving exchange which is of course, coin base. Let's just look at the crypto projects themselves and, and I mean project in a positive way, right they are experiments, they're fascinating and necessary experiments. My personal view, none of them is going to be the new digital USD, but without these experiments and in some cases their prototype and in other cases, they're software, we wouldn't get to that desired deep digital USD that programmable USD that we talked about module one. So all of these market caps are as of the beginning of March 2020 Bitcoin $161 billion, ethereum are behind that, but the number two at $25 billion. And then on the right we have Libra, obviously, this is by no means an exhaustive description of the area but just a few examples. That comes to mind so we've talked about Bitcoin, I'll just briefly mentioned something about aetherium, I find it fascinating. It is a platform for distributed applications and smart contracts that also has a currency eth or eath as most people call it. Smart contracts are interesting, that is the essence of programmable money. That means Etherege can be programmed to do things far beyond the passive US dollar which, as we've discussed, has only two side effects. And it just sits there with the theory and you can compute and you can make transactions conditional on other transactions and you can guarantee that a whole set of transaction happens or that none of them happens. So called atomic transaction. And this is all because of the smart contracts. And this would require a whole lecture on the theory of computation which we won't get into. But as soon as something becomes maximally computable, which we call turing equivalent. Well, that's a wonderful thing, but you also get some problems. Famously you get the halting problem, meaning that it's impossible to guarantee that the program works correctly. There is no program that can look at another program. And insert whether that input program runs forever or halts and gives an answer. Alan Turing showed that doesn't exist. And so you get these difficult properties that arise when you get the full generality of computation would be a segue. But it's the same reason that we can have vaccinations against viruses and treatments. Viruses, but simply preventing all viral infections. I would view as an impossibility just as determining whether a computer program, halt or run an infinite loop is an impossibility. So smart contracts fascinating, immensely powerful. Also potentially dangerous. Because proving that they're good contracts and not malicious contracts is also an impossibility. And then Libra, we talked about Libra in Module 1. Libra in its proposed form, it could go anywhere. It's an open question whether there's an alternate form that does go somewhere perhaps in the unbanked or underbanked. Markets, but again, getting letter level regulatory approval even from Switzerland is going to be tricky. However, as I've mentioned, the software is beautiful and could serve as Valuable prototype. Or some other currency, potentially including a digital USD. A number of other systems that we'll talk about briefly there's ripple. It's a real time gross settlement system is the currency exchange. It's a remittance network Ripple Labs is behind it. His claim is that securely instantly and nearly free global financial transactions of any size without chargebacks. It really is challenging the market dominance of swift. The society for worldwide interbank financial telecommunication. We'll talk more about Swift. And so why is security so important? Well, we know it's so important. Is ripple more secure than swift? Well, Swift is terribly secure. However, I'll mention an infamous event that happened in 2016. That goes to show the old adage that as the designers of the national line you learned, you're only as secure as the weakest link. So hackers exploited weaknesses in the firewall of the Central Bank of Bangladesh is called Bangladesh bank. The Witness was sent to be. This could be apocryphal, but said to be a misconfigured $20 Radio Shack router. And because of that weakness, hackers were able to gain access to the Bangladesh bank's swift credentials. For its account at the Federal Reserve Bank of New York. And with those swift credentials, stole $81 million from the Bangladesh bank account At FRB NY. Assess to secure but if you get the swift credentials because of some lack of security somewhere else but problem. Open question whether ripple can mitigate this by the way. Much of that $81 million amount was turned into chips at various casinos in Macau and elsewhere. And most of the money was never recovered. Stellar, interesting experimental project, it describes itself as an open source decentralized protocol. For money transfers that are digital to fiat Money transfers bi directionally. Fiat to digital currency as well. The stellar project also has a currency with a much smaller market cap. At the beginning of March that was a little over a billion dollars. Interestingly, the ripple co founders together with stripe CEO Patrick Collison launched ripple. And allows cross border transactions between any pair of currencies. Let's very briefly mention some emerging digital assets. This list rose in conversation with my friend Brian Armstrong. And you'll get to hear from him later on in our course of digital assets that are really worth paying attention to. In no particular order on the left, we have each to area 2.0 and East to proposes to scale at theory. By moving away from proof of work, which we've already established is computationally extremely expensive. To proof of stake. And also sharing is a technique that's been around for a while. Where you take a network of computers. And instead of having all those computers work on the same problem at the some time. You divide up the network into sub networks or shards. And those sub networks are shards work on different problems in parallel. And then later you compose the answers of the shards or sub networks into the global answer. And so that's Etherium. Plan to scale and make itself more resilient as well. Definity, fascinating. They're building a decentralized Internet Computer. Cosmos, also known by the name, atom creates a new Byzantine fault tolerant consensus engine. We talked about Byzantine fault tolerance. It has different properties than the Bitcoin Byzantine fault tolerance. Bitcoin you'll remember needs at least half of the mining nodes to be reliable. Cosmos depends on two thirds of the mining nodes being reliable. And it also uses proof of stake rather than proof of work. And Algorand is yet another Byzantine fault tolerant consensus engine. Some barriers to adoption. volatility. We all know that cryptocurrencies are extremely volatile and the fact is. After a few years of experimentation, none of them is widely accepted as a medium of exchange. There's also the regulatory uncertainty which is hugely important What is a security? Well, it can be a metaphysical question. But the answer in US law is that a securities of security of the securities exchange commission. Or sec says it is a security. That leads to the next question, what is the derivative? Well as the SEC and or the CFTC. Say it's a derivative or a swap, then it is and in our complex regulatory landscape. There is some overlap and then there's some differences. Between the SEC and the CFTC jurisdiction as it relates to derivatives, SEC derivatives over single stock swaps or equity derivatives based on single stock CFTC over other derivatives on interest rates, for instance or on indices including stock indices. Then a question is what is a public offering is a so called initial coin offering an IPO? Well again that's for the SEC to decide. There's all the usual questions that apply to the US dollar around who's got jurisdiction and when and it can be multiple and inconsistent claims of jurisdiction. And tax status is an evolving topic as well. And then there's security, while to my knowledge has been no or few hacks on Bitcoin itself for instance, that have been successful. There's been multiple and epic example of failures in exchanges in digital wallet and generally the robustness and resilience of digital wallet is unclear. And until we've got robust solution there, that is a huge barrier to adoption. Some existential questions around cryptocurrencies and blockchain and let's conclude with those. So we've talked at great length about sovereignty, fiat currency, legal tender and policy flexibility. Let's imagine the question, what is an international decentralized cryptocurrency that doesn't rely on a sovereign? One such as aetherium or Bitcoin. What if it were to replace US dollar as a primary means of control? Would the government lose control of monetary policy? That depends on the use cases of that USD. As we've discussed paper currency, M0 represents a claim on the central bank. And so if people move away from paper currency, in other words if M0 declines, do governments need to supply an alternative digital claim on the central bank and or the sovereign? Sweden clearly says yes, the US is debating that right now. And we saw a bit of that debate emerged during the fiscal stimulus negotiation in response to COVID-19. The directive to the Federal Reserve to create digital central bank money in a digital wallet didn't make it into the final bill. But certainly it was the most explicit political conversation I've seen on the topic. And so here's perhaps a teaser. When we look at programmable money or crypto projects, as I mentioned when it's programmable there's an API, you can do things to it, complicated things can happen under the hood. And money instead of being this passive thing with side effects becomes something that can grow and evolve and change and participate in transactions and contracts. Well, here's something you could do, you could remove politically driven inflation expectations. And you could just program into this programmable currency, the growth trajectory of the money supply. So you have the Fisher equations on the right and pi expected is the expected inflation rate. On top of the risk free rate, which would then become the actual rate or i programmed into the currency. And then we wouldn't need to peg it to something completely arbitrary, such as the barbarous relic of gold or silver, in my view the equally barbarous and arbitrary constraints on the growth that's built in the Bitcoin. Fascinating area of research and exploration, one of my favorites as you can tell. Let's end on the topic of financial inclusion and this is something that Libra has been very vocal about. So as of 2017 over 20 to 25% of the population remain unbanked or underbanked with limited access to financial services. And you can see, as you look at the degree of banking as it relates to income and number of households, you can see an example of inequality at work on these 129 million households. So 68.5% of them are fully banked and that's going up to 80% when the household level of income is $75,000 or greater annually, and this source is the Federal Reserve. And so when we look at alternative payment mechanisms that have ease of use, that are built into mobile phones, that are readily available, that are untethered, potentially from the bank account. You can see the relevance and the importance of digital assets for the underbanked and you can see its potential solution here, which may be the direction in which Libra pivots. But to my mind back to how we ended module one with my visit or rather programmable USD. You'd want it to be something that individuals could hold in a reliable digital wallet and use for instantaneous zero cost payment. Never also reliable and authenticated directly from one entity to another.