From 1fd4c83cf10ebcc6fa665f26f0fada7f6720f3f2 Mon Sep 17 00:00:00 2001 From: filipefurtad0 Date: Sun, 17 Mar 2024 13:22:01 +0000 Subject: [PATCH 1/3] Replaces fake with real client_it Replaces stubs on Stripe Account Controller --- .../admin/stripe_accounts_controller_spec.rb | 75 +-- .../redirects_to_unauthorized.yml | 233 +++++++++ .../redirects_to_unauthorized.yml | 235 +++++++++ .../redirects_to_unauthorized.yml | 235 +++++++++ ...turns_with_a_status_of_access_revoked_.yml | 305 ++++++++++++ .../returns_with_a_status_of_connected_.yml | 463 ++++++++++++++++++ 6 files changed, 1510 insertions(+), 36 deletions(-) create mode 100644 spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml create mode 100644 spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml create mode 100644 spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml create mode 100644 spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml create mode 100644 spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml diff --git a/spec/controllers/admin/stripe_accounts_controller_spec.rb b/spec/controllers/admin/stripe_accounts_controller_spec.rb index b5b0683c73..3fa3c09052 100644 --- a/spec/controllers/admin/stripe_accounts_controller_spec.rb +++ b/spec/controllers/admin/stripe_accounts_controller_spec.rb @@ -5,12 +5,11 @@ require 'spec_helper' describe Admin::StripeAccountsController, type: :controller do let(:enterprise) { create(:distributor_enterprise) } - before do - Stripe.client_id = "some_id" - end - describe "#connect" do + let(:client_id) { ENV.fetch('STRIPE_CLIENT_ID', nil) } + before do + Stripe.client_id = client_id allow(controller).to receive(:spree_current_user) { enterprise.owner } end @@ -21,12 +20,12 @@ describe Admin::StripeAccountsController, type: :controller do expect(response).to redirect_to("https://connect.stripe.com/oauth/authorize?" \ "state=eyJhbGciOiJIUzI1NiJ9.eyJlbnRlcnByaXNlX2lkIjoiMSJ9" \ ".jSSFGn0bLhwuiQYK5ORmHWW7aay1l030bcfGwn1JbFg&" \ - "scope=read_write&client_id=some_id&response_type=code") + "scope=read_write&client_id=#{client_id}&response_type=code") end end describe "#destroy" do - let(:params) { { format: :json, id: "some_id" } } + let(:params) { { format: :json, id: "client_id" } } context "when the specified stripe account doesn't exist" do it "raises an error?" do @@ -34,8 +33,18 @@ describe Admin::StripeAccountsController, type: :controller do end end - context "when the specified stripe account exists" do - let(:stripe_account) { create(:stripe_account, enterprise:) } + context "when the specified stripe account exists", :vcr, :stripe_version do + let(:connected_account) do + Stripe::Account.create({ + type: 'standard', + country: 'AU', + email: 'jumping.jack@example.com', + business_type: "non_profit" + }) + end + let(:stripe_account) { + create(:stripe_account, enterprise:, stripe_user_id: connected_account.id) + } before do # So that we can stub #deauthorize_and_destroy @@ -83,11 +92,6 @@ describe Admin::StripeAccountsController, type: :controller do describe "#status" do let(:params) { { format: :json, enterprise_id: enterprise.id } } - before do - Stripe.api_key = "sk_test_12345" - allow(Spree::Config).to receive(:stripe_connect_enabled).and_return(false) - end - context "when I don't manage the specified enterprise" do let(:user) { create(:user) } @@ -125,45 +129,44 @@ describe Admin::StripeAccountsController, type: :controller do end end - context "when a stripe account is associated with the specified enterprise" do + context "when a stripe account is associated with the specified enterprise", :vcr, + :stripe_version do + let(:connected_account) do + Stripe::Account.create({ + type: 'standard', + country: 'AU', + email: 'jumping.jack@example.com', + business_type: "non_profit" + }) + end let!(:account) { - create(:stripe_account, stripe_user_id: "acc_123", enterprise:) + create(:stripe_account, stripe_user_id: connected_account.id, enterprise:) } context "but access has been revoked or does not exist on stripe's servers" do + let(:message) { + "The provided key 'sk_test_******************************uCJm' " \ + "does not have access to account 'acct_fake_account' (or that account " \ + "does not exist). Application access may have been revoked." + } before do - stub_request(:get, - "https://api.stripe.com/v1/accounts/acc_123").to_return(status: 404) + account.update(stripe_user_id: "acct_fake_account") end it "returns with a status of 'access_revoked'" do - get(:status, params:) - json_response = JSON.parse(response.body) - expect(json_response["status"]).to eq "access_revoked" + expect { + response = get(:status, params:) + }.to raise_error Stripe::PermissionError, message end end context "which is connected" do - let(:stripe_account_mock) do - { - id: "acc_123", - business_name: "My Org", - charges_enabled: true, - some_other_attr: "something" - } - end - - before do - stub_request(:get, "https://api.stripe.com/v1/accounts/acc_123") - .to_return(body: JSON.generate(stripe_account_mock)) - end - it "returns with a status of 'connected'" do - get(:status, params:) + response = get(:status, params:) json_response = JSON.parse(response.body) expect(json_response["status"]).to eq "connected" # serializes required attrs - expect(json_response["business_name"]).to eq "My Org" + expect(json_response["charges_enabled"]).to eq false # ignores other attrs expect(json_response["some_other_attr"]).to be nil end diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml new file mode 100644 index 0000000000..625086f75b --- /dev/null +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml @@ -0,0 +1,233 @@ +--- +http_interactions: +- request: + method: post + uri: https://api.stripe.com/v1/accounts + body: + encoding: UTF-8 + string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:06 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Idempotency-Key: + - 153e797a-47b7-4f48-a0f8-cd8c39bf619d + Original-Request: + - req_zfQDRPw4pwuL9V + Request-Id: + - req_zfQDRPw4pwuL9V + Stripe-Should-Retry: + - 'false' + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJe8QKz09hVwk6", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681665, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJe8QKz09hVwk6/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:06 GMT +recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml new file mode 100644 index 0000000000..a05bd4b392 --- /dev/null +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml @@ -0,0 +1,235 @@ +--- +http_interactions: +- request: + method: post + uri: https://api.stripe.com/v1/accounts + body: + encoding: UTF-8 + string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_Kn4sy7JqIW8lyd","request_duration_ms":1966}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:10 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Idempotency-Key: + - 465ce517-9c88-45fc-a4ae-ec6fea3ed101 + Original-Request: + - req_a6vV2cQ3GJ5sRJ + Request-Id: + - req_a6vV2cQ3GJ5sRJ + Stripe-Should-Retry: + - 'false' + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJeD4GSYqMqmpR", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681669, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJeD4GSYqMqmpR/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:10 GMT +recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml new file mode 100644 index 0000000000..5f96625e42 --- /dev/null +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml @@ -0,0 +1,235 @@ +--- +http_interactions: +- request: + method: post + uri: https://api.stripe.com/v1/accounts + body: + encoding: UTF-8 + string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_zfQDRPw4pwuL9V","request_duration_ms":2003}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:08 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Idempotency-Key: + - b4d7d361-5bba-4806-a9bd-7eaec4dbc361 + Original-Request: + - req_Kn4sy7JqIW8lyd + Request-Id: + - req_Kn4sy7JqIW8lyd + Stripe-Should-Retry: + - 'false' + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJeA4Dl7fsDvNo", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681667, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJeA4Dl7fsDvNo/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:08 GMT +recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml new file mode 100644 index 0000000000..1463e89343 --- /dev/null +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml @@ -0,0 +1,305 @@ +--- +http_interactions: +- request: + method: post + uri: https://api.stripe.com/v1/accounts + body: + encoding: UTF-8 + string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_a6vV2cQ3GJ5sRJ","request_duration_ms":1938}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:12 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Idempotency-Key: + - ca4e3616-46a9-4695-9ff9-a64dd1bb7b00 + Original-Request: + - req_21vo6s5eLQyzPx + Request-Id: + - req_21vo6s5eLQyzPx + Stripe-Should-Retry: + - 'false' + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJeFQRrcL6OxB4", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681672, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJeFQRrcL6OxB4/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:12 GMT +- request: + method: get + uri: https://api.stripe.com/v1/accounts/acct_fake_account + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_21vo6s5eLQyzPx","request_duration_ms":1718}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 403 + message: Forbidden + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:13 GMT + Content-Type: + - application/json + Content-Length: + - '366' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Vary: + - Origin + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + { + "error": { + "message": "The provided key 'sk_test_******************************uCJm' does not have access to account 'acct_fake_account' (or that account does not exist). Application access may have been revoked.", + "type": "invalid_request_error", + "code": "account_invalid", + "doc_url": "https://stripe.com/docs/error-codes/account-invalid" + } + } + recorded_at: Sun, 17 Mar 2024 13:21:13 GMT +recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml new file mode 100644 index 0000000000..74d438448a --- /dev/null +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml @@ -0,0 +1,463 @@ +--- +http_interactions: +- request: + method: post + uri: https://api.stripe.com/v1/accounts + body: + encoding: UTF-8 + string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_21vo6s5eLQyzPx","request_duration_ms":1718}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:14 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Idempotency-Key: + - c54432df-9b07-4311-9e9d-4189cd6c9d0e + Original-Request: + - req_xTmV2oAzhyhwYD + Request-Id: + - req_xTmV2oAzhyhwYD + Stripe-Should-Retry: + - 'false' + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJeHQMadqd9TMZ", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681674, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJeHQMadqd9TMZ/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:15 GMT +- request: + method: get + uri: https://api.stripe.com/v1/accounts/acct_1OvJeHQMadqd9TMZ + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.10.0 + Authorization: + - Bearer + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_xTmV2oAzhyhwYD","request_duration_ms":1850}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux + version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 + (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) + #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Sun, 17 Mar 2024 13:21:15 GMT + Content-Type: + - application/json + Content-Length: + - '3527' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to=https://q.stripe.com/coop-report + Request-Id: + - req_jC41Ef46bi6BFZ + Stripe-Account: + - acct_1OvJeHQMadqd9TMZ + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OvJeHQMadqd9TMZ", + "object": "account", + "business_profile": { + "annual_revenue": null, + "estimated_worker_count": null, + "mcc": null, + "name": null, + "product_description": null, + "support_address": null, + "support_email": null, + "support_phone": null, + "support_url": null, + "url": null + }, + "business_type": "non_profit", + "capabilities": {}, + "charges_enabled": false, + "company": { + "address": { + "city": null, + "country": "AU", + "line1": null, + "line2": null, + "postal_code": null, + "state": null + }, + "directors_provided": false, + "executives_provided": false, + "name": null, + "owners_provided": false, + "tax_id_provided": false, + "verification": { + "document": { + "back": null, + "details": null, + "details_code": null, + "front": null + } + } + }, + "controller": { + "is_controller": true, + "type": "application" + }, + "country": "AU", + "created": 1710681674, + "default_currency": "aud", + "details_submitted": false, + "email": "jumping.jack@example.com", + "external_accounts": { + "object": "list", + "data": [], + "has_more": false, + "total_count": 0, + "url": "/v1/accounts/acct_1OvJeHQMadqd9TMZ/external_accounts" + }, + "future_requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [], + "disabled_reason": null, + "errors": [], + "eventually_due": [], + "past_due": [], + "pending_verification": [] + }, + "metadata": {}, + "payouts_enabled": false, + "requirements": { + "alternatives": [], + "current_deadline": null, + "currently_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "disabled_reason": "requirements.past_due", + "errors": [], + "eventually_due": [ + "business_profile.product_description", + "business_profile.support_phone", + "business_profile.url", + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "past_due": [ + "external_account", + "tos_acceptance.date", + "tos_acceptance.ip" + ], + "pending_verification": [] + }, + "settings": { + "bacs_debit_payments": { + "display_name": null, + "service_user_number": null + }, + "branding": { + "icon": null, + "logo": null, + "primary_color": null, + "secondary_color": null + }, + "card_issuing": { + "tos_acceptance": { + "date": null, + "ip": null + } + }, + "card_payments": { + "decline_on": { + "avs_failure": false, + "cvc_failure": false + }, + "statement_descriptor_prefix": null, + "statement_descriptor_prefix_kana": null, + "statement_descriptor_prefix_kanji": null + }, + "dashboard": { + "display_name": null, + "timezone": "Etc/UTC" + }, + "invoices": { + "default_account_tax_ids": null + }, + "payments": { + "statement_descriptor": null, + "statement_descriptor_kana": null, + "statement_descriptor_kanji": null + }, + "payouts": { + "debit_negative_balances": true, + "schedule": { + "delay_days": 2, + "interval": "daily" + }, + "statement_descriptor": null + }, + "sepa_debit_payments": {} + }, + "tos_acceptance": { + "date": null, + "ip": null, + "user_agent": null + }, + "type": "standard" + } + recorded_at: Sun, 17 Mar 2024 13:21:15 GMT +recorded_with: VCR 6.2.0 From 0b844bca8dad8d1c14657181dd2aba26a2e8ca9c Mon Sep 17 00:00:00 2001 From: filipefurtad0 Date: Wed, 27 Mar 2024 11:37:03 +0000 Subject: [PATCH 2/3] Sets VCR tag at the beginning of the spec file Rebases and re-records cassettes --- .../redirects_to_unauthorized.yml | 31 ++++----- .../redirects_to_unauthorized.yml | 33 +++++----- .../redirects_to_unauthorized.yml | 33 +++++----- ...turns_with_a_status_of_access_revoked_.yml | 48 +++++++------- .../returns_with_a_status_of_connected_.yml | 66 ++++++++++--------- 5 files changed, 107 insertions(+), 104 deletions(-) rename spec/fixtures/vcr_cassettes/{Stripe-v10.10.0 => Stripe-v10.13.0}/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml (87%) rename spec/fixtures/vcr_cassettes/{Stripe-v10.10.0 => Stripe-v10.13.0}/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml (86%) rename spec/fixtures/vcr_cassettes/{Stripe-v10.10.0 => Stripe-v10.13.0}/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml (86%) rename spec/fixtures/vcr_cassettes/{Stripe-v10.10.0 => Stripe-v10.13.0}/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml (82%) rename spec/fixtures/vcr_cassettes/{Stripe-v10.10.0 => Stripe-v10.13.0}/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml (86%) diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml similarity index 87% rename from spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml rename to spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml index 625086f75b..801de18a88 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml @@ -8,18 +8,15 @@ http_interactions: string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -32,7 +29,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:06 GMT + - Wed, 27 Mar 2024 11:34:59 GMT Content-Type: - application/json Content-Length: @@ -57,13 +54,17 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" Idempotency-Key: - - 153e797a-47b7-4f48-a0f8-cd8c39bf619d + - f8570e37-5b0d-4cc0-b8a3-b8b9df4d1ffb Original-Request: - - req_zfQDRPw4pwuL9V + - req_e2SoaA4Ghw0gaM + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_zfQDRPw4pwuL9V + - req_e2SoaA4Ghw0gaM Stripe-Should-Retry: - 'false' Stripe-Version: @@ -78,7 +79,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJe8QKz09hVwk6", + "id": "acct_1OyukwQMSSW9Jehj", "object": "account", "business_profile": { "annual_revenue": null, @@ -123,7 +124,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681665, + "created": 1711539299, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -132,7 +133,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJe8QKz09hVwk6/external_accounts" + "url": "/v1/accounts/acct_1OyukwQMSSW9Jehj/external_accounts" }, "future_requirements": { "alternatives": [], @@ -229,5 +230,5 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:06 GMT + recorded_at: Wed, 27 Mar 2024 11:34:59 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml similarity index 86% rename from spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml rename to spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml index a05bd4b392..1f95e4d53a 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml @@ -8,20 +8,17 @@ http_interactions: string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_Kn4sy7JqIW8lyd","request_duration_ms":1966}}' + - '{"last_request_metrics":{"request_id":"req_8Ak8cPKYtDzmwM","request_duration_ms":1828}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -34,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:10 GMT + - Wed, 27 Mar 2024 11:35:03 GMT Content-Type: - application/json Content-Length: @@ -59,13 +56,17 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" Idempotency-Key: - - 465ce517-9c88-45fc-a4ae-ec6fea3ed101 + - ea03a93f-8765-4d81-86da-fcfcad4ce6bc Original-Request: - - req_a6vV2cQ3GJ5sRJ + - req_9OMqL2pNI5AkPo + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_a6vV2cQ3GJ5sRJ + - req_9OMqL2pNI5AkPo Stripe-Should-Retry: - 'false' Stripe-Version: @@ -80,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJeD4GSYqMqmpR", + "id": "acct_1Oyul04D5c5UitL3", "object": "account", "business_profile": { "annual_revenue": null, @@ -125,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681669, + "created": 1711539303, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -134,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJeD4GSYqMqmpR/external_accounts" + "url": "/v1/accounts/acct_1Oyul04D5c5UitL3/external_accounts" }, "future_requirements": { "alternatives": [], @@ -231,5 +232,5 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:10 GMT + recorded_at: Wed, 27 Mar 2024 11:35:04 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml similarity index 86% rename from spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml rename to spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml index 5f96625e42..5e949466b5 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml @@ -8,20 +8,17 @@ http_interactions: string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_zfQDRPw4pwuL9V","request_duration_ms":2003}}' + - '{"last_request_metrics":{"request_id":"req_e2SoaA4Ghw0gaM","request_duration_ms":1837}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -34,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:08 GMT + - Wed, 27 Mar 2024 11:35:01 GMT Content-Type: - application/json Content-Length: @@ -59,13 +56,17 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" Idempotency-Key: - - b4d7d361-5bba-4806-a9bd-7eaec4dbc361 + - 0fd244bc-e210-4018-8f5f-f70eb42bf68b Original-Request: - - req_Kn4sy7JqIW8lyd + - req_8Ak8cPKYtDzmwM + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_Kn4sy7JqIW8lyd + - req_8Ak8cPKYtDzmwM Stripe-Should-Retry: - 'false' Stripe-Version: @@ -80,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJeA4Dl7fsDvNo", + "id": "acct_1OyukyQO5YeTxN1D", "object": "account", "business_profile": { "annual_revenue": null, @@ -125,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681667, + "created": 1711539301, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -134,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJeA4Dl7fsDvNo/external_accounts" + "url": "/v1/accounts/acct_1OyukyQO5YeTxN1D/external_accounts" }, "future_requirements": { "alternatives": [], @@ -231,5 +232,5 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:08 GMT + recorded_at: Wed, 27 Mar 2024 11:35:01 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml similarity index 82% rename from spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml rename to spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml index 1463e89343..1734fa44a7 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml @@ -8,20 +8,17 @@ http_interactions: string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_a6vV2cQ3GJ5sRJ","request_duration_ms":1938}}' + - '{"last_request_metrics":{"request_id":"req_9OMqL2pNI5AkPo","request_duration_ms":1882}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -34,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:12 GMT + - Wed, 27 Mar 2024 11:35:06 GMT Content-Type: - application/json Content-Length: @@ -59,13 +56,17 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" Idempotency-Key: - - ca4e3616-46a9-4695-9ff9-a64dd1bb7b00 + - c0512a95-e0b8-4071-91c4-7918ada106a9 Original-Request: - - req_21vo6s5eLQyzPx + - req_HEzsvVrbsxJf8Q + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_21vo6s5eLQyzPx + - req_HEzsvVrbsxJf8Q Stripe-Should-Retry: - 'false' Stripe-Version: @@ -80,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJeFQRrcL6OxB4", + "id": "acct_1Oyul2QLMfJvTM4q", "object": "account", "business_profile": { "annual_revenue": null, @@ -125,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681672, + "created": 1711539305, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -134,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJeFQRrcL6OxB4/external_accounts" + "url": "/v1/accounts/acct_1Oyul2QLMfJvTM4q/external_accounts" }, "future_requirements": { "alternatives": [], @@ -231,7 +232,7 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:12 GMT + recorded_at: Wed, 27 Mar 2024 11:35:06 GMT - request: method: get uri: https://api.stripe.com/v1/accounts/acct_fake_account @@ -240,20 +241,17 @@ http_interactions: string: '' headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_21vo6s5eLQyzPx","request_duration_ms":1718}}' + - '{"last_request_metrics":{"request_id":"req_HEzsvVrbsxJf8Q","request_duration_ms":1610}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -266,7 +264,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:13 GMT + - Wed, 27 Mar 2024 11:35:06 GMT Content-Type: - application/json Content-Length: @@ -301,5 +299,5 @@ http_interactions: "doc_url": "https://stripe.com/docs/error-codes/account-invalid" } } - recorded_at: Sun, 17 Mar 2024 13:21:13 GMT + recorded_at: Wed, 27 Mar 2024 11:35:06 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml similarity index 86% rename from spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml rename to spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml index 74d438448a..a1c362cfa0 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.10.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml @@ -8,20 +8,17 @@ http_interactions: string: type=standard&country=AU&email=jumping.jack%40example.com&business_type=non_profit headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_21vo6s5eLQyzPx","request_duration_ms":1718}}' + - '{"last_request_metrics":{"request_id":"req_HEzsvVrbsxJf8Q","request_duration_ms":1610}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -34,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:14 GMT + - Wed, 27 Mar 2024 11:35:08 GMT Content-Type: - application/json Content-Length: @@ -59,13 +56,17 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" Idempotency-Key: - - c54432df-9b07-4311-9e9d-4189cd6c9d0e + - d64085a3-eabd-4e3c-9228-4d36a77c3f5a Original-Request: - - req_xTmV2oAzhyhwYD + - req_3EnrtDDoHbYLmY + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_xTmV2oAzhyhwYD + - req_3EnrtDDoHbYLmY Stripe-Should-Retry: - 'false' Stripe-Version: @@ -80,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJeHQMadqd9TMZ", + "id": "acct_1Oyul44GbcQfB8Y3", "object": "account", "business_profile": { "annual_revenue": null, @@ -125,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681674, + "created": 1711539307, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -134,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJeHQMadqd9TMZ/external_accounts" + "url": "/v1/accounts/acct_1Oyul44GbcQfB8Y3/external_accounts" }, "future_requirements": { "alternatives": [], @@ -231,29 +232,26 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:15 GMT + recorded_at: Wed, 27 Mar 2024 11:35:08 GMT - request: method: get - uri: https://api.stripe.com/v1/accounts/acct_1OvJeHQMadqd9TMZ + uri: https://api.stripe.com/v1/accounts/acct_1Oyul44GbcQfB8Y3 body: encoding: US-ASCII string: '' headers: User-Agent: - - Stripe/v1 RubyBindings/10.10.0 + - Stripe/v1 RubyBindings/10.13.0 Authorization: - - Bearer + - "" Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_xTmV2oAzhyhwYD","request_duration_ms":1850}}' + - '{"last_request_metrics":{"request_id":"req_3EnrtDDoHbYLmY","request_duration_ms":1607}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: - - '{"bindings_version":"10.10.0","lang":"ruby","lang_version":"3.1.4 p223 (2023-03-30)","platform":"x86_64-linux","engine":"ruby","publisher":"stripe","uname":"Linux - version 6.5.0-25-generic (buildd@bos03-amd64-044) (x86_64-linux-gnu-gcc-12 - (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0, GNU ld (GNU Binutils for Ubuntu) 2.38) - #25~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Feb 20 16:09:15 UTC 2","hostname":"ff-LAT"}' + - "" Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: @@ -266,7 +264,7 @@ http_interactions: Server: - nginx Date: - - Sun, 17 Mar 2024 13:21:15 GMT + - Wed, 27 Mar 2024 11:35:08 GMT Content-Type: - application/json Content-Length: @@ -291,11 +289,15 @@ http_interactions: default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' Cross-Origin-Opener-Policy-Report-Only: - - same-origin; report-to=https://q.stripe.com/coop-report + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" Request-Id: - - req_jC41Ef46bi6BFZ + - req_XrctWcy82jeizJ Stripe-Account: - - acct_1OvJeHQMadqd9TMZ + - acct_1Oyul44GbcQfB8Y3 Stripe-Version: - '2023-10-16' Vary: @@ -308,7 +310,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OvJeHQMadqd9TMZ", + "id": "acct_1Oyul44GbcQfB8Y3", "object": "account", "business_profile": { "annual_revenue": null, @@ -353,7 +355,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1710681674, + "created": 1711539307, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -362,7 +364,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OvJeHQMadqd9TMZ/external_accounts" + "url": "/v1/accounts/acct_1Oyul44GbcQfB8Y3/external_accounts" }, "future_requirements": { "alternatives": [], @@ -459,5 +461,5 @@ http_interactions: }, "type": "standard" } - recorded_at: Sun, 17 Mar 2024 13:21:15 GMT + recorded_at: Wed, 27 Mar 2024 11:35:09 GMT recorded_with: VCR 6.2.0 From 33889f1255104f4469a99956ca84a2f87b03196c Mon Sep 17 00:00:00 2001 From: filipefurtad0 Date: Fri, 29 Mar 2024 19:02:45 +0000 Subject: [PATCH 3/3] Deletes connected account, after spec Re-records cassettes --- .../admin/stripe_accounts_controller_spec.rb | 8 ++ .../redirects_to_unauthorized.yml | 98 +++++++++++++-- .../redirects_to_unauthorized.yml | 100 +++++++++++++-- .../redirects_to_unauthorized.yml | 100 +++++++++++++-- ...turns_with_a_status_of_access_revoked_.yml | 106 ++++++++++++++-- .../returns_with_a_status_of_connected_.yml | 118 +++++++++++++++--- 6 files changed, 474 insertions(+), 56 deletions(-) diff --git a/spec/controllers/admin/stripe_accounts_controller_spec.rb b/spec/controllers/admin/stripe_accounts_controller_spec.rb index 3fa3c09052..a1b5df8d69 100644 --- a/spec/controllers/admin/stripe_accounts_controller_spec.rb +++ b/spec/controllers/admin/stripe_accounts_controller_spec.rb @@ -52,6 +52,10 @@ describe Admin::StripeAccountsController, type: :controller do params[:id] = stripe_account.id end + after do + Stripe::Account.delete(connected_account.id) + end + context "when I don't manage the enterprise linked to the stripe account" do let(:some_user) { create(:user) } @@ -143,6 +147,10 @@ describe Admin::StripeAccountsController, type: :controller do create(:stripe_account, stripe_user_id: connected_account.id, enterprise:) } + after do + Stripe::Account.delete(connected_account.id) + end + context "but access has been revoked or does not exist on stripe's servers" do let(:message) { "The provided key 'sk_test_******************************uCJm' " \ diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml index 801de18a88..ec0c95ca38 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_don_t_manage_the_enterprise_linked_to_the_stripe_account/redirects_to_unauthorized.yml @@ -29,7 +29,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:34:59 GMT + - Fri, 29 Mar 2024 18:53:02 GMT Content-Type: - application/json Content-Length: @@ -56,15 +56,15 @@ http_interactions: Cross-Origin-Opener-Policy-Report-Only: - same-origin; report-to="coop" Idempotency-Key: - - f8570e37-5b0d-4cc0-b8a3-b8b9df4d1ffb + - b963ad29-314d-4fa3-86c8-ed8d21182414 Original-Request: - - req_e2SoaA4Ghw0gaM + - req_Ph5LpkrVmGvJSp Report-To: - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_e2SoaA4Ghw0gaM + - req_Ph5LpkrVmGvJSp Stripe-Should-Retry: - 'false' Stripe-Version: @@ -79,7 +79,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OyukwQMSSW9Jehj", + "id": "acct_1OzkXwQMV2WNdfaG", "object": "account", "business_profile": { "annual_revenue": null, @@ -124,7 +124,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539299, + "created": 1711738381, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -133,7 +133,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OyukwQMSSW9Jehj/external_accounts" + "url": "/v1/accounts/acct_1OzkXwQMV2WNdfaG/external_accounts" }, "future_requirements": { "alternatives": [], @@ -230,5 +230,87 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:34:59 GMT + recorded_at: Fri, 29 Mar 2024 18:53:02 GMT +- request: + method: delete + uri: https://api.stripe.com/v1/accounts/acct_1OzkXwQMV2WNdfaG + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.13.0 + Authorization: + - "" + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_Ph5LpkrVmGvJSp","request_duration_ms":2188}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - "" + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Fri, 29 Mar 2024 18:53:03 GMT + Content-Type: + - application/json + Content-Length: + - '77' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" + Request-Id: + - req_xbUYf1jqhpZXGn + Stripe-Account: + - acct_1OzkXwQMV2WNdfaG + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OzkXwQMV2WNdfaG", + "object": "account", + "deleted": true + } + recorded_at: Fri, 29 Mar 2024 18:53:03 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml index 1f95e4d53a..f7a27dfdd2 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_fails/redirects_to_unauthorized.yml @@ -14,7 +14,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_8Ak8cPKYtDzmwM","request_duration_ms":1828}}' + - '{"last_request_metrics":{"request_id":"req_JGxjtcKW5dC7dD","request_duration_ms":910}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -31,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:03 GMT + - Fri, 29 Mar 2024 18:53:08 GMT Content-Type: - application/json Content-Length: @@ -58,15 +58,15 @@ http_interactions: Cross-Origin-Opener-Policy-Report-Only: - same-origin; report-to="coop" Idempotency-Key: - - ea03a93f-8765-4d81-86da-fcfcad4ce6bc + - 40c1e7cc-70fa-477f-afc9-5414eb47e9b7 Original-Request: - - req_9OMqL2pNI5AkPo + - req_MZwNhnG2QwlJ04 Report-To: - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_9OMqL2pNI5AkPo + - req_MZwNhnG2QwlJ04 Stripe-Should-Retry: - 'false' Stripe-Version: @@ -81,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1Oyul04D5c5UitL3", + "id": "acct_1OzkY24EZjTC8pH1", "object": "account", "business_profile": { "annual_revenue": null, @@ -126,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539303, + "created": 1711738387, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -135,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1Oyul04D5c5UitL3/external_accounts" + "url": "/v1/accounts/acct_1OzkY24EZjTC8pH1/external_accounts" }, "future_requirements": { "alternatives": [], @@ -232,5 +232,87 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:35:04 GMT + recorded_at: Fri, 29 Mar 2024 18:53:08 GMT +- request: + method: delete + uri: https://api.stripe.com/v1/accounts/acct_1OzkY24EZjTC8pH1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.13.0 + Authorization: + - "" + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_MZwNhnG2QwlJ04","request_duration_ms":1764}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - "" + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Fri, 29 Mar 2024 18:53:09 GMT + Content-Type: + - application/json + Content-Length: + - '77' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" + Request-Id: + - req_tfFx6yqOhyxOEz + Stripe-Account: + - acct_1OzkY24EZjTC8pH1 + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OzkY24EZjTC8pH1", + "object": "account", + "deleted": true + } + recorded_at: Fri, 29 Mar 2024 18:53:09 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml index 5e949466b5..b69281afc0 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_destroy/when_the_specified_stripe_account_exists/when_I_manage_the_enterprise_linked_to_the_stripe_account/and_the_attempt_to_deauthorize_and_destroy_succeeds/redirects_to_unauthorized.yml @@ -14,7 +14,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_e2SoaA4Ghw0gaM","request_duration_ms":1837}}' + - '{"last_request_metrics":{"request_id":"req_xbUYf1jqhpZXGn","request_duration_ms":1121}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -31,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:01 GMT + - Fri, 29 Mar 2024 18:53:05 GMT Content-Type: - application/json Content-Length: @@ -58,15 +58,15 @@ http_interactions: Cross-Origin-Opener-Policy-Report-Only: - same-origin; report-to="coop" Idempotency-Key: - - 0fd244bc-e210-4018-8f5f-f70eb42bf68b + - 8f3afe92-8ae2-4e51-b958-949f48e942d3 Original-Request: - - req_8Ak8cPKYtDzmwM + - req_6C0wxXNZ11Bgnz Report-To: - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_8Ak8cPKYtDzmwM + - req_6C0wxXNZ11Bgnz Stripe-Should-Retry: - 'false' Stripe-Version: @@ -81,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1OyukyQO5YeTxN1D", + "id": "acct_1OzkXzQN8gTLyS3G", "object": "account", "business_profile": { "annual_revenue": null, @@ -126,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539301, + "created": 1711738384, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -135,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1OyukyQO5YeTxN1D/external_accounts" + "url": "/v1/accounts/acct_1OzkXzQN8gTLyS3G/external_accounts" }, "future_requirements": { "alternatives": [], @@ -232,5 +232,87 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:35:01 GMT + recorded_at: Fri, 29 Mar 2024 18:53:05 GMT +- request: + method: delete + uri: https://api.stripe.com/v1/accounts/acct_1OzkXzQN8gTLyS3G + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.13.0 + Authorization: + - "" + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_6C0wxXNZ11Bgnz","request_duration_ms":1887}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - "" + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Fri, 29 Mar 2024 18:53:06 GMT + Content-Type: + - application/json + Content-Length: + - '77' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" + Request-Id: + - req_JGxjtcKW5dC7dD + Stripe-Account: + - acct_1OzkXzQN8gTLyS3G + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OzkXzQN8gTLyS3G", + "object": "account", + "deleted": true + } + recorded_at: Fri, 29 Mar 2024 18:53:06 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml index 1734fa44a7..6fb0d48c59 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/but_access_has_been_revoked_or_does_not_exist_on_stripe_s_servers/returns_with_a_status_of_access_revoked_.yml @@ -14,7 +14,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_9OMqL2pNI5AkPo","request_duration_ms":1882}}' + - '{"last_request_metrics":{"request_id":"req_tfFx6yqOhyxOEz","request_duration_ms":1044}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -31,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:06 GMT + - Fri, 29 Mar 2024 18:53:11 GMT Content-Type: - application/json Content-Length: @@ -58,15 +58,15 @@ http_interactions: Cross-Origin-Opener-Policy-Report-Only: - same-origin; report-to="coop" Idempotency-Key: - - c0512a95-e0b8-4071-91c4-7918ada106a9 + - 04c8a17e-a4e3-4013-829f-a734d08c842f Original-Request: - - req_HEzsvVrbsxJf8Q + - req_3nsCgMKYZfY3Wx Report-To: - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_HEzsvVrbsxJf8Q + - req_3nsCgMKYZfY3Wx Stripe-Should-Retry: - 'false' Stripe-Version: @@ -81,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1Oyul2QLMfJvTM4q", + "id": "acct_1OzkY6QPPCVWPRug", "object": "account", "business_profile": { "annual_revenue": null, @@ -126,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539305, + "created": 1711738391, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -135,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1Oyul2QLMfJvTM4q/external_accounts" + "url": "/v1/accounts/acct_1OzkY6QPPCVWPRug/external_accounts" }, "future_requirements": { "alternatives": [], @@ -232,7 +232,7 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:35:06 GMT + recorded_at: Fri, 29 Mar 2024 18:53:12 GMT - request: method: get uri: https://api.stripe.com/v1/accounts/acct_fake_account @@ -247,7 +247,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_HEzsvVrbsxJf8Q","request_duration_ms":1610}}' + - '{"last_request_metrics":{"request_id":"req_3nsCgMKYZfY3Wx","request_duration_ms":1860}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -264,7 +264,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:06 GMT + - Fri, 29 Mar 2024 18:53:12 GMT Content-Type: - application/json Content-Length: @@ -299,5 +299,87 @@ http_interactions: "doc_url": "https://stripe.com/docs/error-codes/account-invalid" } } - recorded_at: Wed, 27 Mar 2024 11:35:06 GMT + recorded_at: Fri, 29 Mar 2024 18:53:12 GMT +- request: + method: delete + uri: https://api.stripe.com/v1/accounts/acct_1OzkY6QPPCVWPRug + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.13.0 + Authorization: + - "" + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_3nsCgMKYZfY3Wx","request_duration_ms":1860}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - "" + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Fri, 29 Mar 2024 18:53:13 GMT + Content-Type: + - application/json + Content-Length: + - '77' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" + Request-Id: + - req_vJuorSL1DL25TZ + Stripe-Account: + - acct_1OzkY6QPPCVWPRug + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OzkY6QPPCVWPRug", + "object": "account", + "deleted": true + } + recorded_at: Fri, 29 Mar 2024 18:53:13 GMT recorded_with: VCR 6.2.0 diff --git a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml index a1c362cfa0..f6e0864aa4 100644 --- a/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml +++ b/spec/fixtures/vcr_cassettes/Stripe-v10.13.0/Admin_StripeAccountsController/_status/when_I_manage_the_specified_enterprise/when_Stripe_is_enabled/when_a_stripe_account_is_associated_with_the_specified_enterprise/which_is_connected/returns_with_a_status_of_connected_.yml @@ -14,7 +14,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_HEzsvVrbsxJf8Q","request_duration_ms":1610}}' + - '{"last_request_metrics":{"request_id":"req_vJuorSL1DL25TZ","request_duration_ms":983}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -31,7 +31,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:08 GMT + - Fri, 29 Mar 2024 18:53:15 GMT Content-Type: - application/json Content-Length: @@ -58,15 +58,15 @@ http_interactions: Cross-Origin-Opener-Policy-Report-Only: - same-origin; report-to="coop" Idempotency-Key: - - d64085a3-eabd-4e3c-9228-4d36a77c3f5a + - e53c1751-4670-4a7d-8fe1-0c0a8fb647fa Original-Request: - - req_3EnrtDDoHbYLmY + - req_uzAqOcAR3ltbmh Report-To: - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_3EnrtDDoHbYLmY + - req_uzAqOcAR3ltbmh Stripe-Should-Retry: - 'false' Stripe-Version: @@ -81,7 +81,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1Oyul44GbcQfB8Y3", + "id": "acct_1OzkY9QQsxwR3QX7", "object": "account", "business_profile": { "annual_revenue": null, @@ -126,7 +126,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539307, + "created": 1711738394, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -135,7 +135,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1Oyul44GbcQfB8Y3/external_accounts" + "url": "/v1/accounts/acct_1OzkY9QQsxwR3QX7/external_accounts" }, "future_requirements": { "alternatives": [], @@ -232,10 +232,10 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:35:08 GMT + recorded_at: Fri, 29 Mar 2024 18:53:15 GMT - request: method: get - uri: https://api.stripe.com/v1/accounts/acct_1Oyul44GbcQfB8Y3 + uri: https://api.stripe.com/v1/accounts/acct_1OzkY9QQsxwR3QX7 body: encoding: US-ASCII string: '' @@ -247,7 +247,7 @@ http_interactions: Content-Type: - application/x-www-form-urlencoded X-Stripe-Client-Telemetry: - - '{"last_request_metrics":{"request_id":"req_3EnrtDDoHbYLmY","request_duration_ms":1607}}' + - '{"last_request_metrics":{"request_id":"req_uzAqOcAR3ltbmh","request_duration_ms":1896}}' Stripe-Version: - '2023-10-16' X-Stripe-Client-User-Agent: @@ -264,7 +264,7 @@ http_interactions: Server: - nginx Date: - - Wed, 27 Mar 2024 11:35:08 GMT + - Fri, 29 Mar 2024 18:53:15 GMT Content-Type: - application/json Content-Length: @@ -295,9 +295,9 @@ http_interactions: Reporting-Endpoints: - coop="https://q.stripe.com/coop-report" Request-Id: - - req_XrctWcy82jeizJ + - req_Lc3QvEcHt0FgLw Stripe-Account: - - acct_1Oyul44GbcQfB8Y3 + - acct_1OzkY9QQsxwR3QX7 Stripe-Version: - '2023-10-16' Vary: @@ -310,7 +310,7 @@ http_interactions: encoding: UTF-8 string: |- { - "id": "acct_1Oyul44GbcQfB8Y3", + "id": "acct_1OzkY9QQsxwR3QX7", "object": "account", "business_profile": { "annual_revenue": null, @@ -355,7 +355,7 @@ http_interactions: "type": "application" }, "country": "AU", - "created": 1711539307, + "created": 1711738394, "default_currency": "aud", "details_submitted": false, "email": "jumping.jack@example.com", @@ -364,7 +364,7 @@ http_interactions: "data": [], "has_more": false, "total_count": 0, - "url": "/v1/accounts/acct_1Oyul44GbcQfB8Y3/external_accounts" + "url": "/v1/accounts/acct_1OzkY9QQsxwR3QX7/external_accounts" }, "future_requirements": { "alternatives": [], @@ -461,5 +461,87 @@ http_interactions: }, "type": "standard" } - recorded_at: Wed, 27 Mar 2024 11:35:09 GMT + recorded_at: Fri, 29 Mar 2024 18:53:15 GMT +- request: + method: delete + uri: https://api.stripe.com/v1/accounts/acct_1OzkY9QQsxwR3QX7 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Stripe/v1 RubyBindings/10.13.0 + Authorization: + - "" + Content-Type: + - application/x-www-form-urlencoded + X-Stripe-Client-Telemetry: + - '{"last_request_metrics":{"request_id":"req_Lc3QvEcHt0FgLw","request_duration_ms":400}}' + Stripe-Version: + - '2023-10-16' + X-Stripe-Client-User-Agent: + - "" + Accept-Encoding: + - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 + Accept: + - "*/*" + response: + status: + code: 200 + message: OK + headers: + Server: + - nginx + Date: + - Fri, 29 Mar 2024 18:53:16 GMT + Content-Type: + - application/json + Content-Length: + - '77' + Connection: + - keep-alive + Access-Control-Allow-Credentials: + - 'true' + Access-Control-Allow-Methods: + - GET,HEAD,PUT,PATCH,POST,DELETE + Access-Control-Allow-Origin: + - "*" + Access-Control-Expose-Headers: + - Request-Id, Stripe-Manage-Version, Stripe-Should-Retry, X-Stripe-External-Auth-Required, + X-Stripe-Privileged-Session-Required + Access-Control-Max-Age: + - '300' + Cache-Control: + - no-cache, no-store + Content-Security-Policy: + - report-uri https://q.stripe.com/csp-report?p=v1%2Faccounts%2F%3Aaccount; block-all-mixed-content; + default-src 'none'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'; + img-src 'self'; script-src 'self' 'report-sample'; style-src 'self' + Cross-Origin-Opener-Policy-Report-Only: + - same-origin; report-to="coop" + Report-To: + - '{"group":"coop","max_age":8640,"endpoints":[{"url":"https://q.stripe.com/coop-report"}],"include_subdomains":true}' + Reporting-Endpoints: + - coop="https://q.stripe.com/coop-report" + Request-Id: + - req_zHXfFMY9X0grgz + Stripe-Account: + - acct_1OzkY9QQsxwR3QX7 + Stripe-Version: + - '2023-10-16' + Vary: + - Origin + X-Stripe-Routing-Context-Priority-Tier: + - api-testmode + Strict-Transport-Security: + - max-age=63072000; includeSubDomains; preload + body: + encoding: UTF-8 + string: |- + { + "id": "acct_1OzkY9QQsxwR3QX7", + "object": "account", + "deleted": true + } + recorded_at: Fri, 29 Mar 2024 18:53:16 GMT recorded_with: VCR 6.2.0