#benk6763
1 messages · Page 1 of 1 (latest)
Why you don't want to use the newer API?
we are not interested in the Elements or Checkout flow of integrating ApplePay payments, since we also have other Stripe features implemented with the older APi
Coming back to your question, it is still supported. Is anything not working for you?
as I described above we are not submitting the ApplePay token through the Stripe /charges API but rather posting the token to our API, from where we wish to pass the token to Stripe
I cannot find any Stripe docs describing if that's possible or what the API request field is called when submitting the token. We are using the Stripe Java SDK
Why don't you want to submit the token on the frontend?
and what's wrong with the document? it seems it refers to "{ token: result.token.id }" but looking at the ApplePay ApplePayPaymentAuthorizedEvent, there is no such JSON structure where it passes back the token.id
we are a platform connecting Salesforce clients to payments through different PSPs and we do need to have the ability to manage these transactions. So using the front-end Stripe API is not possible
the result object is not the Apple event, but an object containing Stripe Token.
do you have other APIs which processes the ApplePay token directly?
There's an undocumented API parameters for the /v1/tokens:
curl -u sk_test_123: https://api.stripe.com/v1/tokens \
-d pk_token=<PKPaymentToken.paymentData decoded as JSON> \
-d pk_token_instrument_name=<PKPaymentToken.paymentInstrumentName> \
-d pk_token_payment_network=<PKPaymentToken.paymentNetwork> \
-d pk_token_transaction_id=<PKPaymentToken.transactionIdentifier>
thanks!
what is the PKPaymentToken.paymentInstrumentName field? I can relate the others to the ApplePayPaymentAuthorizedEvent fields but not this one
is it perhaps the ApplePayPaymentAuthorizedEvent.payment.token.paymentMethod.type?
If you're working with ApplePayPaymentToken, you need to use ApplePayPaymentToken.paymentMethod.displayName for pk_token_instrument_name and ApplePayPaymentToken.paymentMethod.network for pk_token_payment_network.
Sorry for confusion
ah ok that makes sense now. there was really just 2 options, that it's either: displayName or type in token.paymentMethod