0
votes

We faced with testing problem on the side Google Pay.

  1. At the current stage, we get into the GPay only after Card registration on the side of our site, when after filling out the form user is redirected to the GPay page to create a new Card. A Card is being created : we see it with the data that is entered into the form, but the GPay doesn't send any requests to our site. A special test environment from GPay is needed?

  2. Google Pay's support service asks: "Are you receiving the POST from GPay when you attempt the enrollment flow from the app?"

    How we can apply from GPay if we can't create a Card from GP at this stage?

    The process of creating a Card is described in paragraph 1 (on the site side). How to get into the GPay for enrollment at the testing stage?

  3. Support service writes "When you submit your user details from GPay, it sends a POST request to your server so that when your page is displayed it contains the information from the user data form. "

    As we pointed, at the current stage we can't send data from the GPay. It was expected thatGoogle Pay's support service send a POST request to our site, but we don't see POST request's body. It is empty. Therefore, we asked earlier, What internet service we can see it with? They answered, as we understood, that we can see it by sending from GPay. How to send it from the GPay, if at the testing stage we can only see newly created cards and we don’t get any requests from GPay?

  4. Is testing take place from GPay app? If so, why don't we have an access?

  5. We get a request POST, but with an empty request body. The GPay has a lot of users with the Loyalty Card. Someone has already come across this. We didn't find such situations on the Internet. How anybody have handled situations like this before?

  6. How to create a new Card from GPay and see a POST request?


We do not have access to the class settings in the account. On Russian language, we do not see the callback feature, and on English technical support sends to us a screenshot - there are settings in the account. Could there be access rights issues? To accoding with your link from paragraph 5 https://developers.google.com/pay/passes/rest/v1/loyaltyclass#discoverableprogrammerchantsignupinfo - we did not find the insert barcode /manually settings. Can you tell us where to find them? At the moment, we can scan the barcode in GPay app(due to help of GPay support service ), but we do not receive a Post request after inserting bar code in GPay app. Our Russian account settings looks like: enter image description here

GPay support service see our account on English so: enter image description here We don't see these settings for barcode.

In accordance with the documentation https://developers.google.com/pay/passes/guides/overview/how-to/use-callbacks, we set up a callback feature, but we do not receive a post request in the format json (php):

$responseJson_str = file_get_contents('php://input'); 
$responseJson = '[' . $responseJson_str . ']';
$response = json_decode($responseJson, true); 
var_dump( $response);   
$file_server = "server_calback.log";
$fw = fopen($file_server, "a");
fwrite($fw, "POST " . var_export($response, true) . "\n");
fclose($fw);

What is wrong?

I show a screenshot with the request POST to our site https://itcrk.icu/testcallback.php from https://reqbin.com/ enter image description here


At the beginning of testing stage, we implemented signin / signup as you indicated in points 1-6. We did this functionality was not because we needed it, but thought that it was necessary for testing. Then we wrote in support team that we need a barcode/manually, as users of other cards are used to. We were answered that we need settings in the account, we did not find them. Support team helped us to configure the barcode in the account of the Merchant Center - Google.We insert barcode in the GPay , but we don’t get json on the site. We assume a problem with access rights in the Merchant Center - Google. How do other cardholders usually set up a barcode in their accounts? We do not have access to the settings n the Merchant Center - Google, unfortunately. Support team writes that there should be access, but it does not.


It turned out that there are two ways to work with cards in the GPay. The first method is described in the documentation here https://developers.google.com/pay/passes/guides/enrollment-signin, the second method is to scan the card(barcode/manually) and use it as a card storage, but card data is not sent to the user’s server. The Loyalty card is simply displayed in the GPay with its number(from barcode/manually) and that's all.

2
Have you tested this endpoint with normal post request?Angel
Yes, I tested and updated my post againsvil
You need to find the right loyalty program in Google Pay as per my post paragraph 3. It will not have the barcode showing- I think you are getting confused with the live version (no sign up sign in) and the test version for your discoverable program. It will only have signup and sign in options and only accessible if logged into google account with test permissions for that loyalty program.Angel
We have the test versionsvil
Do you mean sign -up / signin without barcode/manually? We used this way- all works correctly, but we need barcode/manuallysvil

2 Answers

1
votes
  1. Sign up and enrollment are triggered from the google pay app: https://developers.google.com/pay/passes/guides/enrollment-signin

  2. You will see post once a user goes into the Google Pay app and hits add pass then finds your program and hits sign up/ sign in.

  3. See 1-2.

  4. You have to use the account you provide to support team - its only visible for them for testing.

  5. It may not be from Google. Google requests have the body with the user details.

  6. Go to google pay app and sign in with user that is whitelisted by support to see the program. Hit add pass, then loyalty program then search for your program then hit sign up/ sign in and it will post to the endpoint defined here: https://developers.google.com/pay/passes/rest/v1/loyaltyclass#discoverableprogrammerchantsignupinfo

Let me also clarify enrollment and sign in. This is what a user sees, what the Google Pay app does and finally what a merchant needs to do:

  1. Google Pay user navigates to passes tab in Google Pay App, hits "+ Pass": enter image description here

  2. Google Pay chooses which type of pass to add, hits loyalty for this example: enter image description here

  3. User searches and presses on the specific program they want to sign up for (theres a testing phase before it goes public, in which only accounts which you tell support team can see the program in google pay app): enter image description here

  4. User then fills out information to share and consents to share their information with this merchant, then they press continue. k.imgur.com/7mg0J.png

  5. Google Pay Then does a POST request with user info to endpoint defined here on the loyalty class by merchant: https://developers.google.com/pay/passes/rest/v1/loyaltyclass#discoverableprogrammerchantsignupinfo enter image description here

Here is where merchant, yourself would have to be listening for POST to endpoint you defined in the setting mentioned previously and give user form to finish providing all details needed and then redirect to the JWT link to automatically save the pass.

See https://developers.google.com/pay/passes/partners/enrollment-signin for reference.

1
votes

It turned out that there are two ways to work with cards in the GPay. The first method is described in the documentation here https://developers.google.com/pay/passes/guides/enrollment-signin, the second method is to scan the card(barcode/manually) and use it as a card storage, but card data is not sent to the user’s server. The Loyalty card is simply displayed in the GPay with its number(from barcode/manually) and that's all.