In the following JSON, I make a payment in the ChefChili game to purchase virtual currency with my credit card (I am not in the payment testers list). This is showing as FRAUD, whereas it was a genuine payment made by me.
https://graph.facebook.com/382606235186483?access_token=193512574007560|75d4646925b860ec194c69d6cd717ad0
The output of JSON code :
{
id: "382606235186483",
user: {
name: "Abhishek Srivastava",
id: "100001441415841"
},
application: {
name: "ChefChili",
namespace: "chefchili",
id: "193512574007560"
},
actions: [
{
type: "charge",
status: "completed",
currency: "USD",
amount: "1.00",
time_created: "2013-07-26T11:36:49+0000",
time_updated: "2013-07-26T11:36:51+0000"
}
],
refundable_amount: {
currency: "USD",
amount: "1.00"
},
items: [
{
type: "IN_APP_PURCHASE",
product: "https://chefchili.mediaagility.com/product_desc.html",
quantity: 10
}
],
country: "IN",
created_time: "2013-07-26T11:36:49+0000",
fraud_status: "UNKNOWN",
payout_foreign_exchange_rate: 1
}
Also can any one tell me that what is this "fraud_status:UNKNOWN"? and why it is showing "refundable_amount" ?
Related
We are building boot using action on builder SDK. In bot we have transaction related feature so we want to implement reservation feature to make appointment reservation. In our Bot we just need reservation. user can't cancel/delete reservation (As our member can contact the user for next 3 4 days, we are just asking user free time so we can contact user). (We did't have reservation feature yet but google team force us to do so). My Question is while implementing reservation we have https://developers.google.com/assistant/transactions/physical/dev-guide-physical-reservations#validate_transaction_requirements_optional this feature optional we are not implementing this, for second step we have to build Order like this https://developers.google.com/assistant/transactions/physical/dev-guide-physical-reservations#build_the_order
const order = {
createTime: '2019-09-24T18:00:00.877Z',
lastUpdateTime: '2019-09-24T18:00:00.877Z',
merchantOrderId: orderId, // A unique ID String for the order
userVisibleOrderId: orderId,
transactionMerchant: {
id: 'http://www.example.com',
name: 'Example Merchant',
},
contents: {
lineItems: [
{
id: 'LINE_ITEM_ID',
name: 'Dinner reservation',
description: 'A world of flavors all in one destination.',
reservation: {
status: 'PENDING',
userVisibleStatusLabel: 'Reservation is pending.',
type: 'RESTAURANT',
reservationTime: {
timeIso8601: '2020-01-16T01:30:15.01Z',
},
userAcceptableTimeRange: {
timeIso8601: '2020-01-15/2020-01-17',
},
partySize: 6,
staffFacilitators: [
{
name: 'John Smith',
},
],
location: {
zipCode: '94086',
city: 'Sunnyvale',
postalAddress: {
regionCode: 'US',
postalCode: '94086',
administrativeArea: 'CA',
locality: 'Sunnyvale',
addressLines: [
'222, Some other Street',
],
},
},
},
},
],
},
buyerInfo: {
email: 'janedoe#gmail.com',
firstName: 'Jane',
lastName: 'Doe',
displayName: 'Jane Doe',
},
followUpActions: [
{
type: 'VIEW_DETAILS',
title: 'View details',
openUrlAction: {
url: 'http://example.com',
},
},
{
type: 'CALL',
title: 'Call us',
openUrlAction: {
url: 'tel:+16501112222',
},
},
{
type: 'EMAIL',
title: 'Email us',
openUrlAction: {
url: 'mailto:person#example.com',
},
},
],
termsOfServiceUrl: 'http://www.example.com'
};
According to doc we have to create order object like above, but we are unable to find any doc what are optional filed in above object and what value to pass for reservationTime and userAcceptableTimeRange.
reservationTime: {
timeIso8601: '2020-01-16T01:30:15.01Z',
},
userAcceptableTimeRange: {
timeIso8601: '2020-01-15/2020-01-17',
}
Further more do we need to implement Set up asynchronous requests to the Orders API (https://developers.google.com/assistant/transactions/physical/dev-guide-physical-reservations#set_up_asynchronous_requests_to_the_orders_api) as we don't need to update user appoint time and user can't cancel appointment.
Is there any other way we can avoid reservation? please guide me, thanks in advance.
I am a new paypal merchant and am trying to display some information on the checkout pop-up after the client clicks the PAY WITH PAYPAL button. I am using the JavaScript SDK in Sandbox mode
It is a digital purchase, so no shipping is needed -- which works in the code below
The only thing it shows on the Checkout pop-up is the total, "Hi John", Pay With options, and the PAY NOW button.
I want it to show what the client is purchasing, and our company info (name, phone number).
<script src="https://www.paypal.com/sdk/js?client-id=...">
createOrder: function(data, actions) {
// This function sets up the details of the transaction, including the amount and line item details.
var orderDescription = "ITEM YOU PURCHASED" // shows on payment history but not on payment pop-up
return actions.order.create({
intent: "CAPTURE",
purchase_units: [{
description: orderDescription,
amount: {
value: '0.26',
currency_code: "CAD"
}
}],
payee: {
email_address: "email"
},
payee_display_metadata: {
brand_name: "Company Name"
},
application_context: {
shipping_preference: "NO_SHIPPING",
business_name:"My Business Name",
},
note_to_payer: "Contact us at ... for any questions on your order.",
});
},
onApprove: function(data, actions) { .........
Argg..Why is it I always find the answer after I post a question...
I need a item breakdown then I get the down-arrow to expand the cart
changed purchase_units to
purchase_units: [{
amount: {
currency_code: "CAD",
value: "150.00",
breakdown: {
item_total: {
currency_code: "CAD",
value: "150.00"
}
}
},
items: [
{
name: "Tuition",
description: "The best item ever",
sku: "xyz-2654",
unit_amount: {
currency_code: "CAD",
value: "50.00"
},
quantity: "3"
},
]
}],
==== SOLVED ====
Problem is solved. Adyen wants you to send the whole string as an object. JSON.parse(token). Make sure Google pay is enabled in the Adyen platform.
================
I'm working on transactions with Actions on Google and integration Google Pay. I followed all steps according to the documentation of Actions on Google.
To propose an order I send the following snippet seen below.
Notes:
gateway value is replaced for security reasons.
gatewayMerchantId value is replaced for security reasons.
I'm using a registered gateway.
I have not yet registered as Google partner though the business console so I have no access to the production API.
// Handle order with Google Pay.
conv.ask(new TransactionDecision({
orderOptions: {
requestDeliveryAddress: true,
userInfoOptions: {
userInfoProperties: [
'EMAIL',
],
},
},
paymentParameters: {
googlePaymentOption: {
facilitationSpec: JSON.stringify({
apiVersion: 2,
apiVersionMinor: 0,
environment: 'TEST',
merchantInfo: {
merchantName: 'Example Merchant',
merchantId: '12345678901234567890',
},
allowedPaymentMethods: [
{
type: 'CARD',
parameters: {
allowedAuthMethods: ['PAN_ONLY', 'CRYPTOGRAM_3DS'],
allowedCardNetworks: [
'AMEX', 'DISCOVER', 'JCB', 'MASTERCARD', 'VISA',
],
},
tokenizationSpecification: {
type: 'PAYMENT_GATEWAY',
parameters: {
'gateway': 'my_gateway',
'gatewayMerchantId': 'my_gateway_id',
},
},
},
],
transactionInfo: {
totalPriceStatus: 'FINAL',
totalPrice: prodPriceInclBtwInMicros.toString(),
currencyCode: 'EUR',
},
}),
},
},
presentationOptions: {
actionDisplayName: 'PLACE_ORDER',
},
order: order,
}));
The intent that handles the transaction decision value obtains the following arg value:
const arg = conv.arguments.get('TRANSACTION_DECISION_VALUE');
{
'#type': 'type.googleapis.com/google.actions.transactions.v3.TransactionDecisionValue',
transactionDecision: 'ORDER_ACCEPTED',
order: {
googleOrderId: '02458320178127324049',
merchantOrderId: 'example',
userVisibleOrderId: 'example',
buyerInfo: {
email: 'example#example.com',
firstName: 'example',
lastName: 'example',
displayName: 'example example'
},
createTime: '2020-07-21T10:59:16.624Z',
lastUpdateTime: '2020-07-21T10:59:16.624Z',
transactionMerchant: { name: 'Example Merchant' },
contents: { lineItems: [Array] },
priceAttributes: [ [Object], [Object], [Object] ],
paymentData: { paymentResult: [Object], paymentInfo: [Object] },
purchase: {
status: 'CREATED',
type: 'RETAIL',
userVisibleStatusLabel: 'CREATED'
},
vertical: {
'#type': 'type.googleapis.com/google.actions.orders.v3.verticals.purchase.PurchaseOrderExtension',
status: 'CREATED',
type: 'RETAIL',
userVisibleStatusLabel: 'CREATED'
}
}
}
According to [Adyen][1] I should provide the payment token: 'Get the token from PaymentData response from the Google Pay API.' [Google][2] states that the token will be returned in a response object after the user approves the payment. This is certainly not the case as can be seen in the `arg` object.
By digging deeper into the paymentData, we get the following values:
{
paymentResult: {
googlePaymentData: '{"signature":"MEYCIQDS8Tiu9bprWqamQ24oNx+Wa43Wg6Vi3sP5PArDeOtOEAIhAOBqe4sQvN5tD390qWzDn9DIgwA8gjS8ajynrusOix6O","protocolVersion":"ECv1","signedMessage":"{\\"encryptedMessage\\":\\"Some_tokens_IUHASIDHUSAGFUAHS\\",\\"ephemeralPublicKey\\":\\"SOMEKEYSASD\\\\u003d\\",\\"tag\\":\\"SOMETAG_OIASJDJSOIJ\\\\u003d\\"}"}'
},
paymentInfo: {
paymentMethodDisplayInfo: {
paymentType: 'PAYMENT_CARD',
paymentMethodDisplayName: 'Visa •••• 1234'
},
paymentMethodProvenance: 'PAYMENT_METHOD_PROVENANCE_GOOGLE'
}
}
Still no token returned in the response... This will be necessary for the gateway.
Does anyone know how to resolve this? Or does this have to with the production Transaction API?
Any help is appreciated.
[1]: https://docs.adyen.com/payment-methods/google-pay/api-only
[2]: https://developers.google.com/pay/api/web/reference/response-objects#PaymentData
I'm trying to default the billing country to the UK, but no matter what i try it always defaults to the US.
Any ideas?
Note, that we do not require the customer to enter a shipping address so this has been hidden as per the json but have tried setting this to see if it makes a difference with no joy.
I've tried the following:
json_patch_request: [
{
op: 'replace',
path: '/payer/payer_info/billing_address',
value: {
country_code: 'GB',
}
}
],
payer: {
payer_info: {
country_code: 'GB',
billing_address: {
country_code: 'GB',
},
shipping_address: {
country_code: 'GB',
}
}
},
payment: {
transactions: [
{
amount: {
total: 10,
currency: 'GBP'
},
custom: 'x',
},
],
},
experience: {
input_fields: {
no_shipping: 1
},
flow_config: {
landing_page_type: "billing",
},
presentation: {
locale_code: "GB",
},
}
You need to set that in your seller profile:
Log in to your PayPal account
Click Money at the top of the page
Click Manage Currency
Choose the currency to make Primary
Click Make Primary
See https://www.paypal-community.com/t5/About-Payments-Archive/How-to-change-Paypal-default-currency-to-USD/td-p/616528
I use Paypal Express checkout with checkout.js
with the standard javascript code provided by paypal.
Everything works fine and the payment popup looks like this:
Now my question: Is it possible to add more details about the product to this popup?
Like for example, the name and description for the product?
(This code is not working).
return paypal.rest.payment.create(this.props.env, this.props.client, {
transactions: [
{
amount: { total: '{{ entry.itemPreis }}', currency: 'CHF' },
description: 'this is some description',
// description: works and shows up in the paypal backend
// but is not visible to the customer
title: 'this would be the title' // doesn't work
}
],
});
I find the paypal docs to be quite messy.
This works for me
transactions: [
{
amount: { total: '100', currency: 'CHF' },
item_list: {
items: [
{
name: 'Whateveryoufancy',
description: 'Lorem ipsum',
quantity: '1',
price: '100',
currency: 'CHF'
}
]
}
}
]