From cdd6143e2a2bc30725369e29cf64e932d2f4ec1c Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 22:18:05 +0000 Subject: [PATCH] Update generated code for v1441 --- OPENAPI_VERSION | 2 +- .../stripe/functional/GeneratedExamples.java | 44 +++++++++++++++++++ 2 files changed, 45 insertions(+), 1 deletion(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index bf0daa66a74..9aa5de96746 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1412 \ No newline at end of file +v1441 \ No newline at end of file diff --git a/src/test/java/com/stripe/functional/GeneratedExamples.java b/src/test/java/com/stripe/functional/GeneratedExamples.java index 1901347e306..9a7629fb569 100644 --- a/src/test/java/com/stripe/functional/GeneratedExamples.java +++ b/src/test/java/com/stripe/functional/GeneratedExamples.java @@ -11906,6 +11906,50 @@ public void testTerminalReadersProcessPaymentIntentPostServices() throws StripeE null); } + @Test + public void testTerminalReadersProcessSetupIntentPost() throws StripeException { + com.stripe.model.terminal.Reader resource = + com.stripe.model.terminal.Reader.retrieve("tmr_xxxxxxxxxxxxx"); + + com.stripe.param.terminal.ReaderProcessSetupIntentParams params = + com.stripe.param.terminal.ReaderProcessSetupIntentParams.builder() + .setSetupIntent("seti_xxxxxxxxxxxxx") + .setAllowRedisplay( + com.stripe.param.terminal.ReaderProcessSetupIntentParams.AllowRedisplay.ALWAYS) + .build(); + + com.stripe.model.terminal.Reader reader = resource.processSetupIntent(params); + assertNotNull(reader); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v1/terminal/readers/tmr_xxxxxxxxxxxxx/process_setup_intent", + params.toMap(), + null); + } + + @Test + public void testTerminalReadersProcessSetupIntentPostServices() throws StripeException { + StripeClient client = new StripeClient(networkSpy); + + com.stripe.param.terminal.ReaderProcessSetupIntentParams params = + com.stripe.param.terminal.ReaderProcessSetupIntentParams.builder() + .setSetupIntent("seti_xxxxxxxxxxxxx") + .setAllowRedisplay( + com.stripe.param.terminal.ReaderProcessSetupIntentParams.AllowRedisplay.ALWAYS) + .build(); + + com.stripe.model.terminal.Reader reader = + client.terminal().readers().processSetupIntent("tmr_xxxxxxxxxxxxx", params); + assertNotNull(reader); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v1/terminal/readers/tmr_xxxxxxxxxxxxx/process_setup_intent", + params.toMap(), + null); + } + @Test public void testTestHelpersCustomersFundCashBalancePost() throws StripeException { Customer resource = Customer.retrieve("cus_123");