#rnavagamuwa-event
1 messages · Page 1 of 1 (latest)
declaration: package: com.stripe.model, class: EventDataObjectDeserializer
this one
I did event = Webhook.constructEvent(payload, signatureHeader, secret) to get the event
Okie looks correct, also aligns to https://stripe.com/docs/webhooks/signatures#verify-official-libraries
if (dataObjectDeserializer.getObject().isPresent()) {
stripeObject = dataObjectDeserializer.getObject().get();
} else {
// Deserialization failed, probably due to an API version mismatch.
// Refer to the Javadoc documentation on `EventDataObjectDeserializer` for
// instructions on how to handle this case, or return an error here.
}
Can you try the example code in the Doc?
Yes, above is what I did exactly. dataObjectDeserializer.getObject() is empty. That's the issue
Signature verification is done, and the returned Event also has data.
But the object field is null
What is your Java SDK version and what's your event API version?
sdk version: 21.0.0
event api version: 2020-08-27
21.0.0 is compatible with 2022-08-01
So you need to either upgrade your API version, or downgrade the Java SDK
Can you point me to steps to upgrade the API version?
Hi, I am stepping down for the day. If you need further help please ask in the channel!