New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 669876 link

Starred by 5 users

Issue metadata

Status: Started
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Feature

Blocked on:
issue 661608


Participants' hotlists:
Payment-Handler


Sign in to add a comment

Implement serviceworker-based Payment Apps in Chrome for Android

Reported by tom...@opera.com, Nov 30 2016

Issue description

Now that Jinho is implementing support for the Payment Apps API in Chromium (see  issue 661608 ), we would like to extend the support into the Payment Request UI so that the implementation becomes usable in practice.

It would be really great for the Web Payments effort, if we could enable third party payment app implementers to start testing their payment apps with a real browser implementation.

Design document available here: https://docs.google.com/document/d/1sIVFWd4QROQUadpX6KiAnqR8DAGSypy9rgq3TdMm7uQ/edit?usp=sharing
 

Comment 1 by tom...@opera.com, Nov 30 2016

Description: Show this description

Comment 2 by tom...@opera.com, Nov 30 2016

Cc: zino@chromium.org rouslan@chromium.org jinho.b...@samsung.com
Components: -Blink>Payments UI>Browser>Autofill>Payments
Labels: -Type-Bug Type-Feature
Status: Started (was: Assigned)
Some design docs would be nice.
Project Member

Comment 6 by bugdroid1@chromium.org, Dec 1 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0611804b7881c52ae3637bcaaaf4831f30363adb

commit 0611804b7881c52ae3637bcaaaf4831f30363adb
Author: tommyt <tommyt@opera.com>
Date: Thu Dec 01 08:54:32 2016

PaymentApp: Allow multiple payment method names for one instrument.

This changes the name and signature of the
PaymentInstrument.getInstrumentMethodName method to:

    Set<String> getInstrumentMethodNames()

This is to match the "enabledMethods" field in the PaymentAppOption
dictionary in the Payment Apps specification, which is defined to be a
sequence of strings.

See: https://w3c.github.io/webpayments-payment-apps-api/#payment-app-options

I also change the name of PaymentInstrument.getInstrumentDetails to
"invokePayment" in order to convey better that this is where the payment
method specific stuff happens. For a Web Based Payment App, this method
is an appropriate point to launch the payment request event into the
service worker.

BUG=669876

Review-Url: https://codereview.chromium.org/2530793002
Cr-Commit-Position: refs/heads/master@{#435587}

[modify] https://crrev.com/0611804b7881c52ae3637bcaaaf4831f30363adb/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentInstrument.java
[modify] https://crrev.com/0611804b7881c52ae3637bcaaaf4831f30363adb/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentInstrument.java
[modify] https://crrev.com/0611804b7881c52ae3637bcaaaf4831f30363adb/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java
[modify] https://crrev.com/0611804b7881c52ae3637bcaaaf4831f30363adb/chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestTestBase.java

Comment 7 by tom...@opera.com, Dec 1 2016

> Some design docs would be nice.

Will do! I'm working on the design document now.
Project Member

Comment 8 by bugdroid1@chromium.org, Dec 1 2016

The following revision refers to this bug:
  https://chrome-internal.googlesource.com/clank/internal/apps/+/93d1d64b8497374964024708e4deae1ae85149db

commit 93d1d64b8497374964024708e4deae1ae85149db
Author: Rouslan Solomakhin <rouslan@google.com>
Date: Thu Dec 01 15:27:06 2016

Comment 9 by tom...@opera.com, Dec 5 2016

Description: Show this description
Please make the design document world-readable.

Comment 11 by tom...@opera.com, Dec 5 2016

Description: Show this description
Project Member

Comment 12 by bugdroid1@chromium.org, Dec 5 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/857f8a9174628615f9775f9383e0a64846d29d55

commit 857f8a9174628615f9775f9383e0a64846d29d55
Author: tommyt <tommyt@opera.com>
Date: Mon Dec 05 13:16:35 2016

PaymentApp: Add classes for supporting Web Based Payment Apps

This adds an application class, an instrument class and a skeleton
bridging class which can later be implemented to communicate with the
service worker class in C++.

The app factory class has been extended to create instances of the new
web based payment apps in addition to the existing autofill payment app.

BUG=669876

Review-Url: https://codereview.chromium.org/2526293003
Cr-Commit-Position: refs/heads/master@{#436274}

[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/ChromeFeatureList.java
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentAppFactory.java
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java
[add] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentApp.java
[add] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentAppBridge.java
[add] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentInstrument.java
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/java_sources.gni
[add] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestServiceWorkerPaymentAppTest.java
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/chrome/browser/android/chrome_feature_list.cc
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/content/public/common/content_features.cc
[modify] https://crrev.com/857f8a9174628615f9775f9383e0a64846d29d55/content/public/common/content_features.h

Project Member

Comment 13 by bugdroid1@chromium.org, Jan 22 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/dfd9bf1edeca16610876ba4e33150401143b1924

commit dfd9bf1edeca16610876ba4e33150401143b1924
Author: tommyt <tommyt@opera.com>
Date: Sun Jan 22 09:07:43 2017

PaymentApp: Implement invokePaymentApp for Android

This change implements the
ServiceWorkerPaymentAppBridge.invokePaymentApp() function along with the
corresponding native InvokePaymentApp() function.

The signature of PaymentInstrument.invokePaymentApp() has also been
changed to add the payment details modifiers field, and to align the
ordering and naming of the arguments with the definition of the
PaymentAppRequest dictionary in the specification:

    https://w3c.github.io/webpayments-payment-apps-api/#sec-app-request

BUG=669876

Review-Url: https://codereview.chromium.org/2640743005
Cr-Commit-Position: refs/heads/master@{#445301}

[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/AndroidPaymentApp.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/AutofillPaymentInstrument.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentInstrument.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentAppBridge.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/java/src/org/chromium/chrome/browser/payments/ServiceWorkerPaymentInstrument.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestTestBase.java
[modify] https://crrev.com/dfd9bf1edeca16610876ba4e33150401143b1924/chrome/browser/android/payments/service_worker_payment_app_bridge.cc

Project Member

Comment 14 by bugdroid1@chromium.org, Jan 23 2017

The following revision refers to this bug:
  https://chrome-internal.googlesource.com/clank/internal/apps/+/28af8d0e88520637523ea62ecbfd9abf7fbb88c4

commit 28af8d0e88520637523ea62ecbfd9abf7fbb88c4
Author: John Mellor <johnme@google.com>
Date: Mon Jan 23 13:38:09 2017

Project Member

Comment 15 by bugdroid1@chromium.org, Mar 30 2017

Project Member

Comment 16 by bugdroid1@chromium.org, Mar 30 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/bbb00c3bef1374d4590acaa8ed59f5838103acc2

commit bbb00c3bef1374d4590acaa8ed59f5838103acc2
Author: jinho.bang <jinho.bang@samsung.com>
Date: Thu Mar 30 15:09:09 2017

PaymentHandler: Rename PaymentAppManager to PaymentManager.

Related spec link:
  https://w3c.github.io/webpayments-payment-apps-api/#idl-def-paymentmanager
  https://github.com/w3c/webpayments-payment-apps-api/issues/109

BUG=669876

Review-Url: https://codereview.chromium.org/2785523003
Cr-Commit-Position: refs/heads/master@{#460755}

[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/components/payments/content/payment_app.mojom
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/BUILD.gn
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_app_content_unittest_base.cc
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_app_content_unittest_base.h
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_app_context_impl.cc
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_app_context_impl.h
[delete] https://crrev.com/9b0f213ebc01011ec377f4bfd19566e97bfedff8/content/browser/payments/payment_app_manager.h
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_app_provider_impl_unittest.cc
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_manager.cc
[add] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_manager.h
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/payments/payment_manager_unittest.cc
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/browser/renderer_host/render_process_host_impl.cc
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/public/app/mojo/content_browser_manifest.json
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/test/BUILD.gn
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/content/test/data/payments/payment_app_invocation.html
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/http/tests/payments/payment-app-interfaces.html
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/http/tests/payments/payment-manager.html
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/http/tests/payments/resources/payment-app.js
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/http/tests/serviceworker/chromium/navigation-preload-origin-trial-interfaces-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/http/tests/serviceworker/webexposed/global-interface-listing-service-worker-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/virtual/service-worker-navigation-preload-disabled/http/tests/serviceworker/chromium/navigation-preload-origin-trial-interfaces-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/virtual/service-worker-navigation-preload/http/tests/serviceworker/chromium/navigation-preload-origin-trial-interfaces-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/virtual/service-worker-navigation-preload/http/tests/serviceworker/webexposed/global-interface-listing-service-worker-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-dedicated-worker-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-shared-worker-expected.txt
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/modules_idl_files.gni
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/BUILD.gn
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentAppServiceWorkerRegistration.cpp
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentAppServiceWorkerRegistration.h
[modify] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentAppServiceWorkerRegistration.idl
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentManager.cpp
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentManager.h
[rename] https://crrev.com/bbb00c3bef1374d4590acaa8ed59f5838103acc2/third_party/WebKit/Source/modules/payments/PaymentManager.idl

Components: -UI>Browser>Autofill>Payments UI>Browser>Payments
Cc: tom...@opera.com
Owner: gogerald@chromium.org

Sign in to add a comment