<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>https://web.dev/</id>
  <title>Yuichi Araki on web.dev</title>
  <updated>2026-04-15T23:21:06Z</updated>
  <author>
    <name>Yuichi Araki</name>
  </author>
  <link href="https://web.dev/authors/yaraki/feed.xml" rel="self"/>
  <link href="https://web.dev/"/>
  <icon>https://web-dev.imgix.net/image/admin/IjxUTn7SuYE9pHLSZteN.jpg?auto=format</icon>
  <logo>https://web.dev/images/shared/rss-banner.png</logo>
  <subtitle>Developer Programs Engineer at Google</subtitle>
  
  
  <entry>
    <title>Android payment app developers guide</title>
    <link href="https://web.dev/android-payment-apps-developers-guide/"/>
    <updated>2020-05-25T00:00:00Z</updated>
    <id>https://web.dev/android-payment-apps-developers-guide/</id>
    <content type="html" mode="escaped">&lt;p&gt;The &lt;a href=&quot;https://www.w3.org/TR/payment-request/&quot; rel=&quot;noopener&quot;&gt;Payment Request API&lt;/a&gt; brings to the
web a built-in browser-based interface that allows users to enter required payment
information easier than ever before. The API can also invoke platform-specific payment
apps.&lt;/p&gt;
&lt;div class=&quot;wdi-browser-compat&quot;&gt;
  &lt;span class=&quot;wdi-browser-compat__label&quot;&gt;Browser support&lt;/span&gt;
  &lt;ul class=&quot;wdi-browser-compat__items&quot;&gt;
    &lt;li class=&quot;wdi-browser-compat__item&quot;&gt;
    &lt;span class=&quot;wdi-browser-compat__icon&quot; data-browser=&quot;chrome&quot;&gt;
      &lt;span class=&quot;visually-hidden&quot;&gt;Chrome 60, Supported&lt;/span&gt;
    &lt;/span&gt;
    &lt;span class=&quot;wdi-browser-compat__version&quot; data-compat=&quot;yes&quot; title=&quot;Supported&quot; aria-label=&quot;Supported&quot;&gt;
      60
    &lt;/span&gt;
    &lt;/li&gt;&lt;li class=&quot;wdi-browser-compat__item&quot;&gt;
    &lt;span class=&quot;wdi-browser-compat__icon&quot; data-browser=&quot;firefox&quot;&gt;
      &lt;span class=&quot;visually-hidden&quot;&gt;Firefox 55, Behind a flag&lt;/span&gt;
    &lt;/span&gt;
    &lt;span class=&quot;wdi-browser-compat__version&quot; data-compat=&quot;flag&quot; title=&quot;Behind a flag&quot; aria-label=&quot;Behind a flag&quot;&gt;
&lt;p&gt;&lt;/p&gt;&lt;/span&gt;
&lt;/li&gt;&lt;li class=&quot;wdi-browser-compat__item&quot;&gt;
&lt;span class=&quot;wdi-browser-compat__icon&quot; data-browser=&quot;edge&quot;&gt;
&lt;span class=&quot;visually-hidden&quot;&gt;Edge 15, Supported&lt;/span&gt;
&lt;/span&gt;
&lt;span class=&quot;wdi-browser-compat__version&quot; data-compat=&quot;yes&quot; title=&quot;Supported&quot; aria-label=&quot;Supported&quot;&gt;
15
&lt;/span&gt;
&lt;/li&gt;&lt;li class=&quot;wdi-browser-compat__item&quot;&gt;
&lt;span class=&quot;wdi-browser-compat__icon&quot; data-browser=&quot;safari&quot;&gt;
&lt;span class=&quot;visually-hidden&quot;&gt;Safari 11.1, Supported&lt;/span&gt;
&lt;/span&gt;
&lt;span class=&quot;wdi-browser-compat__version&quot; data-compat=&quot;yes&quot; title=&quot;Supported&quot; aria-label=&quot;Supported&quot;&gt;
11.1
&lt;/span&gt;
&lt;/li&gt;&lt;p&gt;&lt;/p&gt;
  &lt;/ul&gt;
  &lt;a class=&quot;wdi-browser-compat__link&quot; href=&quot;https://developer.mozilla.org/docs/Web/API/PaymentRequest#browser_compatibility&quot; target=&quot;_blank&quot;&gt;Source&lt;/a&gt;
&lt;/div&gt;
&lt;figure&gt;
  &lt;video autoplay=&quot;&quot; loop=&quot;&quot; muted=&quot;&quot;&gt;      &lt;source src=&quot;https://storage.googleapis.com/web-dev-uploads/video/YLflGBAPWecgtKJLqCJHSzHqe2J2/hzMuAwPAGpNmgxHpaHAq.mp4&quot; type=&quot;video/mp4&quot; /&gt;    &lt;/video&gt;
  &lt;figcaption&gt;Checkout flow with platform-specific Google Pay app that uses Web Payments.
  &lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Compared to using just Android Intents, Web Payments allow better integration
with the browser, security, and user experience:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The payment app is launched as a modal, in context of the merchant website.&lt;/li&gt;
&lt;li&gt;Implementation is supplemental to your existing payment app, enabling you to
take advantage of your user base.&lt;/li&gt;
&lt;li&gt;The payment app&#39;s signature is checked to prevent
&lt;a href=&quot;https://en.wikipedia.org/wiki/Sideloading&quot; rel=&quot;noopener&quot;&gt;sideloading&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Payment apps can support multiple payment methods.&lt;/li&gt;
&lt;li&gt;Any payment method, such as cryptocurrency, bank transfers, and more, can be
integrated. Payment apps on Android devices can even integrate methods that
require access to the hardware chip on the device.&lt;/li&gt;
&lt;/ul&gt;
&lt;aside class=&quot;aside flow bg-state-info-bg color-state-info-text&quot;&gt;&lt;div class=&quot; flow&quot;&gt; To understand how merchants integrate with payment apps, check out &lt;a href=&quot;https://web.dev/life-of-a-payment-transaction/&quot;&gt;Life of a payment transaction&lt;/a&gt;. &lt;/div&gt;&lt;/aside&gt;
&lt;p&gt;It takes four steps to implement Web Payments in an Android payment app:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Let merchants discover your payment app.&lt;/li&gt;
&lt;li&gt;Let a merchant know if a customer has an enrolled instrument (such as credit
card) that is ready to pay.&lt;/li&gt;
&lt;li&gt;Let a customer make payment.&lt;/li&gt;
&lt;li&gt;Verify the caller&#39;s signing certificate.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;To see Web Payments in action, check out the
&lt;a href=&quot;https://github.com/GoogleChromeLabs/android-web-payment/&quot; rel=&quot;noopener&quot;&gt;android-web-payment&lt;/a&gt;
demo.&lt;/p&gt;
&lt;h2 id=&quot;step-1-let-merchants-discover-your-payment-app&quot;&gt;Step 1: Let merchants discover your payment app &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#step-1-let-merchants-discover-your-payment-app&quot;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;In order for a merchant to use your payment app, they need to use the &lt;a href=&quot;https://developer.mozilla.org/docs/Web/API/Payment_Request_API&quot; rel=&quot;noopener&quot;&gt;Payment
Request API&lt;/a&gt; and
specify the payment method you support using the &lt;a href=&quot;https://www.w3.org/TR/payment-method-id/&quot; rel=&quot;noopener&quot;&gt;payment method
identifier&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;If you have a payment method identifier that is unique to your payment app, you
can set up your own &lt;a href=&quot;https://w3c.github.io/payment-method-manifest/&quot; rel=&quot;noopener&quot;&gt;payment method
manifest&lt;/a&gt; so browsers can
discover your app.&lt;/p&gt;
&lt;aside class=&quot;aside flow bg-state-info-bg color-state-info-text&quot;&gt;&lt;div class=&quot; flow&quot;&gt; To learn how the discovery process works in detail and how to set up a new payment method check out &lt;a href=&quot;https://web.dev/setting-up-a-payment-method&quot;&gt;Setting up a payment method&lt;/a&gt;. &lt;/div&gt;&lt;/aside&gt;
&lt;h2 id=&quot;step-2-let-a-merchant-know-if-a-customer-has-an-enrolled-instrument-that-is-ready-to-pay&quot;&gt;Step 2: Let a merchant know if a customer has an enrolled instrument that is ready to pay &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#step-2-let-a-merchant-know-if-a-customer-has-an-enrolled-instrument-that-is-ready-to-pay&quot;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The merchant can call &lt;code&gt;hasEnrolledInstrument()&lt;/code&gt; to &lt;a href=&quot;https://web.dev/life-of-a-payment-transaction#ready-to-pay&quot;&gt;query whether the customer
is able to make a payment&lt;/a&gt;. You can
implement &lt;code&gt;IS_READY_TO_PAY&lt;/code&gt; as an Android service to answer this query.&lt;/p&gt;
&lt;h3 id=&quot;androidmanifestxml&quot;&gt;&lt;code&gt;AndroidManifest.xml&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#androidmanifestxml&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;Declare your service with an intent filter with the action
&lt;code&gt;org.chromium.intent.action.IS_READY_TO_PAY&lt;/code&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-xml&quot;&gt;&lt;code class=&quot;language-xml&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;service&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;.SampleIsReadyToPayService&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;exported&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;true&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;intent-filter&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;action&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;org.chromium.intent.action.IS_READY_TO_PAY&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;intent-filter&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;service&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;The &lt;code&gt;IS_READY_TO_PAY&lt;/code&gt; service is optional. If there&#39;s no such intent handler in
the payment app, then the web browser assumes that the app can always make
payments.&lt;/p&gt;
&lt;h3 id=&quot;aidl&quot;&gt;AIDL &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#aidl&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The API for the &lt;code&gt;IS_READY_TO_PAY&lt;/code&gt; service is defined in AIDL. Create two AIDL
files with the following content:&lt;/p&gt;
&lt;p class=&quot;label&quot;&gt;app/src/main/aidl/org/chromium/IsReadyToPayServiceCallback.aidl&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;package&lt;/span&gt; org&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;chromium&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;interface&lt;/span&gt; IsReadyToPayServiceCallback &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;    oneway void &lt;span class=&quot;token function&quot;&gt;handleIsReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;boolean isReadyToPay&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p class=&quot;label&quot;&gt;app/src/main/aidl/org/chromium/IsReadyToPayService.aidl&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;package&lt;/span&gt; org&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;chromium&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;import&lt;/span&gt; org&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;chromium&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;IsReadyToPayServiceCallback&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;interface&lt;/span&gt; IsReadyToPayService &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;    oneway void &lt;span class=&quot;token function&quot;&gt;isReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;IsReadyToPayServiceCallback callback&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;implementing-isreadytopayservice&quot;&gt;Implementing &lt;code&gt;IsReadyToPayService&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#implementing-isreadytopayservice&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The simplest implementation of &lt;code&gt;IsReadyToPayService&lt;/code&gt; is shown in the following
example:&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;class&lt;/span&gt; SampleIsReadyToPayService &lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;Service&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token keyword&quot;&gt;private&lt;/span&gt; &lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; binder &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;token keyword&quot;&gt;object&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; IsReadyToPayService&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;Stub&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token keyword&quot;&gt;override&lt;/span&gt; &lt;span class=&quot;token keyword&quot;&gt;fun&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;isReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;callback&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; IsReadyToPayServiceCallback&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;      callback&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;handleIsReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token boolean&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;  &lt;span class=&quot;token keyword&quot;&gt;override&lt;/span&gt; &lt;span class=&quot;token keyword&quot;&gt;fun&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;onBind&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;intent&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; Intent&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; IBinder&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token keyword&quot;&gt;return&lt;/span&gt; binder&lt;br /&gt;  &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;response&quot;&gt;Response &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#response&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The service can send its response via &lt;code&gt;handleIsReadyToPay(Boolean)&lt;/code&gt; method.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;callback&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;handleIsReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token boolean&quot;&gt;true&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;permission&quot;&gt;Permission &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#permission&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;You can use &lt;code&gt;Binder.getCallingUid()&lt;/code&gt; to check who the caller is. Note that you
have to do this in the &lt;code&gt;isReadyToPay&lt;/code&gt; method, not in the &lt;code&gt;onBind&lt;/code&gt; method.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;override&lt;/span&gt; &lt;span class=&quot;token keyword&quot;&gt;fun&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;isReadyToPay&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;callback&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; IsReadyToPayServiceCallback&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token keyword&quot;&gt;try&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; callingPackage &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; packageManager&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getNameForUid&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;Binder&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getCallingUid&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token comment&quot;&gt;// …&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;See &lt;a href=&quot;https://web.dev/android-payment-apps-developers-guide/#heading=h.czr8ye23zg2e&quot;&gt;Verify the caller&#39;s signing certificate&lt;/a&gt; about how
to verify that the calling package has the right signature.&lt;/p&gt;
&lt;h2 id=&quot;step-3-let-a-customer-make-payment&quot;&gt;Step 3: Let a customer make payment &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#step-3-let-a-customer-make-payment&quot;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The merchant calls &lt;code&gt;show()&lt;/code&gt; to &lt;a href=&quot;https://web.dev/life-of-a-payment-transaction#launch&quot;&gt;launch the payment
app&lt;/a&gt;
so the customer can make a payment. The payment app is invoked via an Android
intent &lt;code&gt;PAY&lt;/code&gt; with transaction information in the intent parameters.&lt;/p&gt;
&lt;p&gt;The payment app responds with &lt;code&gt;methodName&lt;/code&gt; and &lt;code&gt;details&lt;/code&gt;, which are payment app
specific and are opaque to the browser. The browser converts the &lt;code&gt;details&lt;/code&gt;
string into a JavaScript object for the merchant via JSON deserialization, but
does not enforce any validity beyond that. The browser does not modify the
&lt;code&gt;details&lt;/code&gt;; that parameter&#39;s value is passed directly to the merchant.&lt;/p&gt;
&lt;h3 id=&quot;androidmanifestxml-2&quot;&gt;&lt;code&gt;AndroidManifest.xml&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#androidmanifestxml-2&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The activity with the &lt;code&gt;PAY&lt;/code&gt; intent filter should have a &lt;code&gt;&amp;lt;meta-data&amp;gt;&lt;/code&gt; tag &lt;a href=&quot;https://web.dev/setting-up-a-payment-method&quot;&gt;that
identifies the default payment method identifier for the
app&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;To support multiple payment methods, add a &lt;code&gt;&amp;lt;meta-data&amp;gt;&lt;/code&gt; tag with a
&lt;code&gt;&amp;lt;string-array&amp;gt;&lt;/code&gt; resource.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-xml&quot;&gt;&lt;code class=&quot;language-xml&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;activity&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;.PaymentActivity&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;theme&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;@style/Theme.SamplePay.Dialog&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;intent-filter&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;action&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;org.chromium.intent.action.PAY&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;intent-filter&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;meta-data&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;org.chromium.default_payment_method_name&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;value&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;https://bobbucks.dev/pay&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;meta-data&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;org.chromium.payment_method_names&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token attr-name&quot;&gt;&lt;span class=&quot;token namespace&quot;&gt;android:&lt;/span&gt;resource&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;@array/method_names&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;/&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;activity&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;The &lt;code&gt;resource&lt;/code&gt; must be a list of strings, each of which must be a valid,
absolute URL with an HTTPS scheme as shown here.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-xml&quot;&gt;&lt;code class=&quot;language-xml&quot;&gt;&lt;span class=&quot;token prolog&quot;&gt;&amp;lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;resources&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;string-array&lt;/span&gt; &lt;span class=&quot;token attr-name&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;token attr-value&quot;&gt;&lt;span class=&quot;token punctuation attr-equals&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;method_names&lt;span class=&quot;token punctuation&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;        &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;item&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;https://alicepay.com/put/optional/path/here&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;item&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;        &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;&lt;/span&gt;item&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;https://charliepay.com/put/optional/path/here&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;item&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;    &lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;string-array&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token tag&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;&amp;lt;/&lt;/span&gt;resources&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;parameters&quot;&gt;Parameters &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#parameters&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The following parameters are passed to the activity as Intent extras:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;methodNames&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;methodData&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;topLevelOrigin&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;topLevelCertificateChain&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;paymentRequestOrigin&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;total&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;modifiers&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;paymentRequestId&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; extras&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; Bundle&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; intent&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;extras&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;methodnames&quot;&gt;methodNames &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#methodnames&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The names of the methods being used. The elements are the keys in the
&lt;code&gt;methodData&lt;/code&gt; dictionary. These are the methods that the payment app supports.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; methodNames&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; List&lt;span class=&quot;token operator&quot;&gt;&amp;lt;&lt;/span&gt;String&lt;span class=&quot;token operator&quot;&gt;&gt;&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getStringArrayList&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;methodNames&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;methoddata&quot;&gt;&lt;code&gt;methodData&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#methoddata&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;A mapping from each of the &lt;code&gt;methodNames&lt;/code&gt; to the
&lt;a href=&quot;https://w3c.github.io/payment-request/#declaring-multiple-ways-of-paying&quot; rel=&quot;noopener&quot;&gt;&lt;code&gt;methodData&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; methodData&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; Bundle&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getBundle&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;methodData&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;merchantname&quot;&gt;merchantName &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#merchantname&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The contents of the &lt;code&gt;&amp;lt;title&amp;gt;&lt;/code&gt; HTML tag of the merchant&#39;s checkout page (the
browser&#39;s top-level browsing context).&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; merchantName&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getString&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;merchantName&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;toplevelorigin&quot;&gt;&lt;code&gt;topLevelOrigin&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#toplevelorigin&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The merchant&#39;s origin without the scheme (The scheme-less origin of the
top-level browsing context). For example, &lt;code&gt;https://mystore.com/checkout&lt;/code&gt; is
passed as &lt;code&gt;mystore.com&lt;/code&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; topLevelOrigin&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getString&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;topLevelOrigin&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;toplevelcertificatechain&quot;&gt;&lt;code&gt;topLevelCertificateChain&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#toplevelcertificatechain&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The merchant&#39;s certificate chain (The certificate chain of the top-level
browsing context). Null for localhost and file on disk, which are both secure
contexts without SSL certificates. Each &lt;code&gt;Parcelable&lt;/code&gt; is a Bundle with a
&lt;code&gt;certificate&lt;/code&gt; key and a byte array value.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; topLevelCertificateChain&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; Array&lt;span class=&quot;token operator&quot;&gt;&amp;lt;&lt;/span&gt;Parcelable&lt;span class=&quot;token operator&quot;&gt;&gt;&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt;&lt;br /&gt;    extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getParcelableArray&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;topLevelCertificateChain&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; list&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; List&lt;span class=&quot;token operator&quot;&gt;&amp;lt;&lt;/span&gt;ByteArray&lt;span class=&quot;token operator&quot;&gt;&gt;&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; topLevelCertificateChain&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;mapNotNull&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt; p &lt;span class=&quot;token operator&quot;&gt;-&gt;&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;p &lt;span class=&quot;token keyword&quot;&gt;as&lt;/span&gt; Bundle&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getByteArray&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;certificate&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;paymentrequestorigin&quot;&gt;&lt;code&gt;paymentRequestOrigin&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#paymentrequestorigin&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The scheme-less origin of the iframe browsing context that invoked the &lt;code&gt;new PaymentRequest(methodData, details, options)&lt;/code&gt; constructor in JavaScript. If the
constructor was invoked from the top-level context, then the value of this
parameter equals the value of &lt;code&gt;topLevelOrigin&lt;/code&gt; parameter.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; paymentRequestOrigin&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getString&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;paymentRequestOrigin&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;total&quot;&gt;&lt;code&gt;total&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#total&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The JSON string representing the total amount of the transaction.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; total&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getString&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;total&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;Here&#39;s an example content of the string:&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;currency&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;USD&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;value&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;25.00&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h4 id=&quot;modifiers&quot;&gt;&lt;code&gt;modifiers&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#modifiers&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The output of &lt;code&gt;JSON.stringify(details.modifiers)&lt;/code&gt;, where &lt;code&gt;details.modifiers&lt;/code&gt;
contain only &lt;code&gt;supportedMethods&lt;/code&gt; and &lt;code&gt;total&lt;/code&gt;.&lt;/p&gt;
&lt;h4 id=&quot;paymentrequestid&quot;&gt;&lt;code&gt;paymentRequestId&lt;/code&gt; &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#paymentrequestid&quot;&gt;#&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;The &lt;code&gt;PaymentRequest.id&lt;/code&gt; field that &amp;quot;push-payment&amp;quot; apps should associate with the
transaction state. Merchant websites will use this field to query the
&amp;quot;push-payment&amp;quot; apps for the state of transaction out of band.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; paymentRequestId&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; extras&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getString&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;paymentRequestId&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;response-2&quot;&gt;Response &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#response-2&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The activity can send its response back through &lt;code&gt;setResult&lt;/code&gt; with &lt;code&gt;RESULT_OK&lt;/code&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token function&quot;&gt;setResult&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;Activity&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;RESULT_OK&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;Intent&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;apply&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token function&quot;&gt;putExtra&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;methodName&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;https://bobbucks.dev/pay&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;  &lt;span class=&quot;token function&quot;&gt;putExtra&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;details&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;{\&quot;token\&quot;: \&quot;put-some-data-here\&quot;}&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token function&quot;&gt;finish&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;You must specify two parameters as Intent extras:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;methodName&lt;/code&gt;: The name of the method being used.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;details&lt;/code&gt;: JSON string containing information necessary for the merchant to
complete the transaction. If success is &lt;code&gt;true&lt;/code&gt;, then &lt;code&gt;details&lt;/code&gt; must be
constructed in such a way that &lt;code&gt;JSON.parse(details)&lt;/code&gt; will succeed.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can pass &lt;code&gt;RESULT_CANCELED&lt;/code&gt; if the transaction was not completed in the
payment app, for example, if the user failed to type in the correct PIN code for
their account in the payment app. The browser may let the user choose a
different payment app.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token function&quot;&gt;setResult&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;RESULT_CANCELED&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token function&quot;&gt;finish&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;If the activity result of a payment response received from the invoked payment
app is set to &lt;code&gt;RESULT_OK&lt;/code&gt;, then Chrome will check for non-empty &lt;code&gt;methodName&lt;/code&gt; and
&lt;code&gt;details&lt;/code&gt; in its extras. If the validation fails Chrome will return a rejected
promise from &lt;code&gt;request.show()&lt;/code&gt; with one of the following developer facing error
messages:&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-js&quot;&gt;&lt;code class=&quot;language-js&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&#39;Payment app returned invalid response. Missing field &quot;details&quot;.&#39;&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token string&quot;&gt;&#39;Payment app returned invalid response. Missing field &quot;methodName&quot;.&#39;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;h3 id=&quot;permission-2&quot;&gt;Permission &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#permission-2&quot;&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;p&gt;The activity can check the caller with its &lt;code&gt;getCallingPackage()&lt;/code&gt; method.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; caller&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String&lt;span class=&quot;token operator&quot;&gt;?&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; callingPackage&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;The final step is to verify the caller&#39;s signing certificate to confirm that the
calling package has the right signature.&lt;/p&gt;
&lt;h2 id=&quot;step-4-verify-the-callers-signing-certificate&quot;&gt;Step 4: Verify the caller&#39;s signing certificate &lt;a class=&quot;headline-link&quot; href=&quot;https://web.dev/android-payment-apps-developers-guide/#step-4-verify-the-callers-signing-certificate&quot;&gt;#&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;You can check the caller&#39;s package name with &lt;code&gt;Binder.getCallingUid()&lt;/code&gt; in
&lt;code&gt;IS_READY_TO_PAY&lt;/code&gt;, and with &lt;code&gt;Activity.getCallingPackage()&lt;/code&gt; in &lt;code&gt;PAY&lt;/code&gt;. In order to
actually verify that the caller is the browser you have in mind, you should
check its signing certificate and make sure that it matches with the correct
value.&lt;/p&gt;
&lt;p&gt;If you&#39;re targeting API level 28 and above and are integrating with a browser
that has a single signing certificate, you can use
&lt;code&gt;PackageManager.hasSigningCertificate()&lt;/code&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; packageName&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; … &lt;span class=&quot;token comment&quot;&gt;// The caller&#39;s package name&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; certificate&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; ByteArray &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; … &lt;span class=&quot;token comment&quot;&gt;// The correct signing certificate.&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; verified &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; packageManager&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;hasSigningCertificate&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;br /&gt;  callingPackage&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt;&lt;br /&gt;  certificate&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt;&lt;br /&gt;  PackageManager&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;CERT_INPUT_SHA256&lt;br /&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;&lt;p&gt;&lt;code&gt;PackageManager.hasSigningCertificate()&lt;/code&gt; is preferred for single certificate
browsers, because it correctly handles certificate rotation. (Chrome has a
single signing certificate.) Apps that have multiple signing certificates cannot
rotate them.&lt;/p&gt;
&lt;p&gt;If you need to support older API levels 27 and below, or if you need to handle
browsers with multiple signing certificates, you can use
&lt;code&gt;PackageManager.GET_SIGNATURES&lt;/code&gt;.&lt;/p&gt;
&lt;div&gt;&lt;pre class=&quot;language-kotlin&quot;&gt;&lt;code class=&quot;language-kotlin&quot;&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; packageName&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; String &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; … &lt;span class=&quot;token comment&quot;&gt;// The caller&#39;s package name&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; certificates&lt;span class=&quot;token operator&quot;&gt;:&lt;/span&gt; Set&lt;span class=&quot;token operator&quot;&gt;&amp;lt;&lt;/span&gt;ByteArray&lt;span class=&quot;token operator&quot;&gt;&gt;&lt;/span&gt; &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; … &lt;span class=&quot;token comment&quot;&gt;// The correct set of signing certificates&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; packageInfo &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;token function&quot;&gt;getPackageInfo&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;packageName&lt;span class=&quot;token punctuation&quot;&gt;,&lt;/span&gt; PackageManager&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;GET_SIGNATURES&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; sha256 &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; MessageDigest&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;getInstance&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token string-literal singleline&quot;&gt;&lt;span class=&quot;token string&quot;&gt;&quot;SHA-256&quot;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; signatures &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; packageInfo&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;signatures&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;map&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt; sha256&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;digest&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;it&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;toByteArray&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class=&quot;token keyword&quot;&gt;val&lt;/span&gt; verified &lt;span class=&quot;token operator&quot;&gt;=&lt;/span&gt; signatures&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;size &lt;span class=&quot;token operator&quot;&gt;==&lt;/span&gt; certificates&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;size &lt;span class=&quot;token operator&quot;&gt;&amp;amp;&amp;amp;&lt;/span&gt;&lt;br /&gt;    signatures&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;all&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt; s &lt;span class=&quot;token operator&quot;&gt;-&gt;&lt;/span&gt; certificates&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;any&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;{&lt;/span&gt; it&lt;span class=&quot;token punctuation&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;token function&quot;&gt;contentEquals&lt;/span&gt;&lt;span class=&quot;token punctuation&quot;&gt;(&lt;/span&gt;s&lt;span class=&quot;token punctuation&quot;&gt;)&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt; &lt;span class=&quot;token punctuation&quot;&gt;}&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;</content>
    <author>
      <name>Yuichi Araki</name>
    </author><author>
      <name>Eiji Kitamura</name>
    </author>
  </entry>
</feed>
