From 8c01f8f07d0b3e567fb37c72adcaa95ddb70ed24 Mon Sep 17 00:00:00 2001 From: Robot Date: Tue, 13 Aug 2024 10:12:15 +0000 Subject: [PATCH] Changes generated by 742ceefbabd0182b0c6a043eb59a9613b6b3651b --- gocardless_pro/resources/billing_request.py | 4 ++++ tests/fixtures/bank_authorisations.json | 4 ++-- tests/fixtures/billing_request_flows.json | 4 ++-- tests/fixtures/billing_request_templates.json | 2 +- tests/fixtures/billing_requests.json | 24 +++++++++---------- tests/fixtures/blocks.json | 12 +++++----- tests/fixtures/creditor_bank_accounts.json | 2 +- tests/fixtures/creditors.json | 8 +++---- tests/fixtures/currency_exchange_rates.json | 2 +- tests/fixtures/customer_bank_accounts.json | 10 ++++---- tests/fixtures/customer_notifications.json | 2 +- tests/fixtures/customers.json | 2 +- tests/fixtures/events.json | 4 ++-- tests/fixtures/exports.json | 4 ++-- tests/fixtures/instalment_schedules.json | 2 +- tests/fixtures/institutions.json | 4 ++-- tests/fixtures/mandate_import_entries.json | 2 +- tests/fixtures/mandates.json | 12 +++++----- tests/fixtures/negative_balance_limits.json | 2 +- tests/fixtures/payer_authorisations.json | 10 ++++---- tests/fixtures/payments.json | 10 ++++---- tests/fixtures/payout_items.json | 2 +- tests/fixtures/payouts.json | 2 +- tests/fixtures/redirect_flows.json | 6 ++--- tests/fixtures/refunds.json | 2 +- tests/fixtures/scheme_identifiers.json | 6 ++--- tests/fixtures/subscriptions.json | 12 +++++----- tests/fixtures/tax_rates.json | 2 +- tests/fixtures/transferred_mandates.json | 2 +- tests/fixtures/verification_details.json | 4 ++-- tests/fixtures/webhooks.json | 6 ++--- .../billing_requests_integration_test.py | 11 +++++++++ 32 files changed, 98 insertions(+), 83 deletions(-) diff --git a/gocardless_pro/resources/billing_request.py b/gocardless_pro/resources/billing_request.py index de9d476c..ad6f2bfb 100644 --- a/gocardless_pro/resources/billing_request.py +++ b/gocardless_pro/resources/billing_request.py @@ -144,6 +144,10 @@ def __init__(self, attributes): def authorisation_source(self): return self.attributes.get('authorisation_source') + @property + def consent_type(self): + return self.attributes.get('consent_type') + @property def constraints(self): return self.attributes.get('constraints') diff --git a/tests/fixtures/bank_authorisations.json b/tests/fixtures/bank_authorisations.json index d88ad83f..e1953c7a 100644 --- a/tests/fixtures/bank_authorisations.json +++ b/tests/fixtures/bank_authorisations.json @@ -3,12 +3,12 @@ "method": "POST", "path_template": "/bank_authorisations", "url_params": [], - "body": {"bank_authorisations":{"authorisation_type":"example authorisation_type 8081","authorised_at":"2020-01-01T12:00:00.000Z","created_at":"2024-08-09T14:41:32.414Z","expires_at":"2024-08-09T14:41:32.414Z","id":"BAU123","last_visited_at":"2020-01-01T12:00:00.000Z","links":{"billing_request":"BRQ123","institution":"monzo"},"qr_code_url":"https://pay.gocardless.com/obauth/BAU123/qr_code","redirect_uri":"https://my-website.com/abc/callback","url":"https://pay.gocardless.com/obauth/BAU123"}} + "body": {"bank_authorisations":{"authorisation_type":"example authorisation_type 8081","authorised_at":"2020-01-01T12:00:00.000Z","created_at":"2024-08-13T10:09:22.468Z","expires_at":"2024-08-13T10:09:22.468Z","id":"BAU123","last_visited_at":"2020-01-01T12:00:00.000Z","links":{"billing_request":"BRQ123","institution":"monzo"},"qr_code_url":"https://pay.gocardless.com/obauth/BAU123/qr_code","redirect_uri":"https://my-website.com/abc/callback","url":"https://pay.gocardless.com/obauth/BAU123"}} }, "get": { "method": "GET", "path_template": "/bank_authorisations/:identity", "url_params": ["BAU123"], - "body": {"bank_authorisations":{"authorisation_type":"example authorisation_type 7887","authorised_at":"2020-01-01T12:00:00.000Z","created_at":"2024-08-09T14:41:32.414Z","expires_at":"2024-08-09T14:41:32.414Z","id":"BAU123","last_visited_at":"2020-01-01T12:00:00.000Z","links":{"billing_request":"BRQ123","institution":"monzo"},"qr_code_url":"https://pay.gocardless.com/obauth/BAU123/qr_code","redirect_uri":"https://my-website.com/abc/callback","url":"https://pay.gocardless.com/obauth/BAU123"}} + "body": {"bank_authorisations":{"authorisation_type":"example authorisation_type 7887","authorised_at":"2020-01-01T12:00:00.000Z","created_at":"2024-08-13T10:09:22.468Z","expires_at":"2024-08-13T10:09:22.468Z","id":"BAU123","last_visited_at":"2020-01-01T12:00:00.000Z","links":{"billing_request":"BRQ123","institution":"monzo"},"qr_code_url":"https://pay.gocardless.com/obauth/BAU123/qr_code","redirect_uri":"https://my-website.com/abc/callback","url":"https://pay.gocardless.com/obauth/BAU123"}} } } diff --git a/tests/fixtures/billing_request_flows.json b/tests/fixtures/billing_request_flows.json index 7c7b2425..d68ebe72 100644 --- a/tests/fixtures/billing_request_flows.json +++ b/tests/fixtures/billing_request_flows.json @@ -3,12 +3,12 @@ "method": "POST", "path_template": "/billing_request_flows", "url_params": [], - "body": {"billing_request_flows":{"authorisation_url":"https://monzo.com/abc-123-things","auto_fulfil":false,"created_at":"2024-08-09T14:41:32.419Z","customer_details_captured":false,"exit_uri":"https://my-website.com/abc/callback","expires_at":"2024-08-09T14:41:32.419Z","id":"BRF123","language":"en","links":{"billing_request":"BRQ123"},"lock_bank_account":true,"lock_currency":true,"lock_customer_details":true,"prefilled_bank_account":{"account_type":"savings"},"prefilled_customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"redirect_uri":"https://my-website.com/abc/callback","session_token":"sesh_123","show_redirect_buttons":true,"show_success_redirect_button":false}} + "body": {"billing_request_flows":{"authorisation_url":"https://monzo.com/abc-123-things","auto_fulfil":true,"created_at":"2024-08-13T10:09:22.472Z","customer_details_captured":false,"exit_uri":"https://my-website.com/abc/callback","expires_at":"2024-08-13T10:09:22.472Z","id":"BRF123","language":"en","links":{"billing_request":"BRQ123"},"lock_bank_account":true,"lock_currency":true,"lock_customer_details":false,"prefilled_bank_account":{"account_type":"savings"},"prefilled_customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"redirect_uri":"https://my-website.com/abc/callback","session_token":"sesh_123","show_redirect_buttons":true,"show_success_redirect_button":false}} }, "initialise": { "method": "POST", "path_template": "/billing_request_flows/:identity/actions/initialise", "url_params": ["BRF123"], - "body": {"billing_request_flows":{"authorisation_url":"https://monzo.com/abc-123-things","auto_fulfil":true,"created_at":"2024-08-09T14:41:32.419Z","customer_details_captured":true,"exit_uri":"https://my-website.com/abc/callback","expires_at":"2024-08-09T14:41:32.419Z","id":"BRF123","language":"en","links":{"billing_request":"BRQ123"},"lock_bank_account":true,"lock_currency":true,"lock_customer_details":false,"prefilled_bank_account":{"account_type":"savings"},"prefilled_customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"redirect_uri":"https://my-website.com/abc/callback","session_token":"sesh_123","show_redirect_buttons":true,"show_success_redirect_button":true}} + "body": {"billing_request_flows":{"authorisation_url":"https://monzo.com/abc-123-things","auto_fulfil":false,"created_at":"2024-08-13T10:09:22.472Z","customer_details_captured":true,"exit_uri":"https://my-website.com/abc/callback","expires_at":"2024-08-13T10:09:22.472Z","id":"BRF123","language":"en","links":{"billing_request":"BRQ123"},"lock_bank_account":true,"lock_currency":false,"lock_customer_details":false,"prefilled_bank_account":{"account_type":"savings"},"prefilled_customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"redirect_uri":"https://my-website.com/abc/callback","session_token":"sesh_123","show_redirect_buttons":false,"show_success_redirect_button":false}} } } diff --git a/tests/fixtures/billing_request_templates.json b/tests/fixtures/billing_request_templates.json index aab8db28..3793c53d 100644 --- a/tests/fixtures/billing_request_templates.json +++ b/tests/fixtures/billing_request_templates.json @@ -3,7 +3,7 @@ "method": "GET", "path_template": "/billing_request_templates", "url_params": [], - "body": {"billing_request_templates":[{"authorisation_url":"https://pay.gocardless.com/BRT123","created_at":"2021-01-01T12:00:00.000Z","id":"BRT123","mandate_request_currency":"GBP","mandate_request_description":"Top-up Payment","mandate_request_metadata":{},"mandate_request_scheme":"bacs","mandate_request_verify":null,"metadata":{},"name":"12 Month Gold Plan","payment_request_amount":1000,"payment_request_currency":"GBP","payment_request_description":"Top-up Payment","payment_request_metadata":{},"payment_request_scheme":"faster_payments","redirect_uri":"https://my-website.com/abc/callback","updated_at":"2021-01-01T12:00:00.000Z"},{"authorisation_url":"https://pay.gocardless.com/BRT123","created_at":"2021-01-01T12:00:00.000Z","id":"BRT123","mandate_request_currency":"GBP","mandate_request_description":"Top-up Payment","mandate_request_metadata":{},"mandate_request_scheme":"bacs","mandate_request_verify":null,"metadata":{},"name":"12 Month Gold Plan","payment_request_amount":1000,"payment_request_currency":"GBP","payment_request_description":"Top-up Payment","payment_request_metadata":{},"payment_request_scheme":"faster_payments","redirect_uri":"https://my-website.com/abc/callback","updated_at":"2021-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 4983","before":"example before 8146"},"limit":50}} + "body": {"billing_request_templates":[{"authorisation_url":"https://pay.gocardless.com/BRT123","created_at":"2021-01-01T12:00:00.000Z","id":"BRT123","mandate_request_currency":"GBP","mandate_request_description":"Top-up Payment","mandate_request_metadata":{},"mandate_request_scheme":"bacs","mandate_request_verify":null,"metadata":{},"name":"12 Month Gold Plan","payment_request_amount":1000,"payment_request_currency":"GBP","payment_request_description":"Top-up Payment","payment_request_metadata":{},"payment_request_scheme":"faster_payments","redirect_uri":"https://my-website.com/abc/callback","updated_at":"2021-01-01T12:00:00.000Z"},{"authorisation_url":"https://pay.gocardless.com/BRT123","created_at":"2021-01-01T12:00:00.000Z","id":"BRT123","mandate_request_currency":"GBP","mandate_request_description":"Top-up Payment","mandate_request_metadata":{},"mandate_request_scheme":"bacs","mandate_request_verify":null,"metadata":{},"name":"12 Month Gold Plan","payment_request_amount":1000,"payment_request_currency":"GBP","payment_request_description":"Top-up Payment","payment_request_metadata":{},"payment_request_scheme":"faster_payments","redirect_uri":"https://my-website.com/abc/callback","updated_at":"2021-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 9430","before":"example before 2887"},"limit":50}} }, "get": { "method": "GET", diff --git a/tests/fixtures/billing_requests.json b/tests/fixtures/billing_requests.json index 0378c88d..ed42b0fc 100644 --- a/tests/fixtures/billing_requests.json +++ b/tests/fixtures/billing_requests.json @@ -3,72 +3,72 @@ "method": "POST", "path_template": "/billing_requests", "url_params": [], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 9947"],"bank_authorisation":{"adapter":"example adapter 495","authorisation_type":"example authorisation_type 5466"},"collect_customer_details":{"default_country_code":"example default_country_code 8047","incomplete_fields":{"customer":["example customer 1528"],"customer_billing_detail":["example customer_billing_detail 6258"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 1211","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 3274","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","constraints":{"end_date":"example end_date 456","max_amount_per_payment":3300,"periodic_limits":[{"alignment":"creation_date","max_payments":4059,"max_total_amount":4425,"period":"year"}],"start_date":"example start_date 2540"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1847"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 3237"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"personal","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 4728"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 5089"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 1528"],"bank_authorisation":{"adapter":"example adapter 8287","authorisation_type":"example authorisation_type 2888"},"collect_customer_details":{"default_country_code":"example default_country_code 9947","incomplete_fields":{"customer":["example customer 6258"],"customer_billing_detail":["example customer_billing_detail 8047"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3237","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 1445","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 4059","constraints":{"end_date":"example end_date 3300","max_amount_per_payment":694,"periodic_limits":[{"alignment":"calendar","max_payments":2081,"max_total_amount":2540,"period":"day"}],"start_date":"example start_date 456"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 5089"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 9106"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"dependant_support","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3274"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 4728"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "collect_customer_details": { "method": "POST", "path_template": "/billing_requests/:identity/actions/collect_customer_details", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 4324"],"bank_authorisation":{"adapter":"example adapter 5194","authorisation_type":"example authorisation_type 563"},"collect_customer_details":{"default_country_code":"example default_country_code 2433","incomplete_fields":{"customer":["example customer 4147"],"customer_billing_detail":["example customer_billing_detail 4078"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 2888","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 2790","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","constraints":{"end_date":"example end_date 5541","max_amount_per_payment":408,"periodic_limits":[{"alignment":"creation_date","max_payments":6831,"max_total_amount":7387,"period":"week"}],"start_date":"example start_date 3015"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 631"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 3090"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"utility","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 1353"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 6159"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 5541"],"bank_authorisation":{"adapter":"example adapter 408","authorisation_type":"example authorisation_type 7387"},"collect_customer_details":{"default_country_code":"example default_country_code 6831","incomplete_fields":{"customer":["example customer 5429"],"customer_billing_detail":["example customer_billing_detail 5356"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 631","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 1737","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 6413","constraints":{"end_date":"example end_date 3090","max_amount_per_payment":5194,"periodic_limits":[{"alignment":"calendar","max_payments":4147,"max_total_amount":2433,"period":"year"}],"start_date":"example start_date 4324"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1957"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 1485"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"pension","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3015"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 2790"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "collect_bank_account": { "method": "POST", "path_template": "/billing_requests/:identity/actions/collect_bank_account", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 9703"],"bank_authorisation":{"adapter":"example adapter 2888","authorisation_type":"example authorisation_type 4538"},"collect_customer_details":{"default_country_code":"example default_country_code 9355","incomplete_fields":{"customer":["example customer 8510"],"customer_billing_detail":["example customer_billing_detail 2451"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 5447","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 9718","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 5746","max_amount_per_payment":1563,"periodic_limits":[{"alignment":"calendar","max_payments":5561,"max_total_amount":9828,"period":"week"}],"start_date":"example start_date 4783"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 2605"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"minimum"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 8705"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"utility","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 2199"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 7189"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 1577"],"bank_authorisation":{"adapter":"example adapter 4376","authorisation_type":"example authorisation_type 9002"},"collect_customer_details":{"default_country_code":"example default_country_code 9718","incomplete_fields":{"customer":["example customer 5447"],"customer_billing_detail":["example customer_billing_detail 5094"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 7463","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 7996","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","consent_type":"example consent_type 8266","constraints":{"end_date":"example end_date 9703","max_amount_per_payment":9355,"periodic_limits":[{"alignment":"creation_date","max_payments":8510,"max_total_amount":2451,"period":"week"}],"start_date":"example start_date 4538"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 9828"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 5561"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"government","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 5746"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 4783"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "confirm_payer_details": { "method": "POST", "path_template": "/billing_requests/:identity/actions/confirm_payer_details", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 59"],"bank_authorisation":{"adapter":"example adapter 3133","authorisation_type":"example authorisation_type 9241"},"collect_customer_details":{"default_country_code":"example default_country_code 3891","incomplete_fields":{"customer":["example customer 3033"],"customer_billing_detail":["example customer_billing_detail 8643"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 1351","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 7425","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 9843","max_amount_per_payment":9336,"periodic_limits":[{"alignment":"creation_date","max_payments":2546,"max_total_amount":6503,"period":"day"}],"start_date":"example start_date 552"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 8878"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"when_available"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 1137"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"dependant_support","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 7996"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 7463"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 59"],"bank_authorisation":{"adapter":"example adapter 3133","authorisation_type":"example authorisation_type 9241"},"collect_customer_details":{"default_country_code":"example default_country_code 8623","incomplete_fields":{"customer":["example customer 953"],"customer_billing_detail":["example customer_billing_detail 1137"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 2002","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 8878","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","consent_type":"example consent_type 1515","constraints":{"end_date":"example end_date 9107","max_amount_per_payment":7940,"periodic_limits":[{"alignment":"creation_date","max_payments":9843,"max_total_amount":552,"period":"year"}],"start_date":"example start_date 2546"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1351"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 3033"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"other","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3687"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 9757"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "fulfil": { "method": "POST", "path_template": "/billing_requests/:identity/actions/fulfil", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 1270"],"bank_authorisation":{"adapter":"example adapter 2079","authorisation_type":"example authorisation_type 2066"},"collect_customer_details":{"default_country_code":"example default_country_code 7726","incomplete_fields":{"customer":["example customer 3981"],"customer_billing_detail":["example customer_billing_detail 5802"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 6137","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 9267","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 5285","max_amount_per_payment":8590,"periodic_limits":[{"alignment":"creation_date","max_payments":3098,"max_total_amount":3632,"period":"week"}],"start_date":"example start_date 3410"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 3687"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"when_available"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 5894"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"dependant_support","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 1297"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 5384"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 8981"],"bank_authorisation":{"adapter":"example adapter 7175","authorisation_type":"example authorisation_type 6052"},"collect_customer_details":{"default_country_code":"example default_country_code 493","incomplete_fields":{"customer":["example customer 9819"],"customer_billing_detail":["example customer_billing_detail 3086"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3410","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 5285","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 6137","constraints":{"end_date":"example end_date 5894","max_amount_per_payment":7726,"periodic_limits":[{"alignment":"calendar","max_payments":2079,"max_total_amount":3981,"period":"month"}],"start_date":"example start_date 9271"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 5384"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 8590"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"loan","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 8553"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 3098"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "cancel": { "method": "POST", "path_template": "/billing_requests/:identity/actions/cancel", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 7051"],"bank_authorisation":{"adapter":"example adapter 540","authorisation_type":"example authorisation_type 5786"},"collect_customer_details":{"default_country_code":"example default_country_code 8076","incomplete_fields":{"customer":["example customer 3640"],"customer_billing_detail":["example customer_billing_detail 7351"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 1532","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 3612","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","constraints":{"end_date":"example end_date 7175","max_amount_per_payment":4885,"periodic_limits":[{"alignment":"creation_date","max_payments":5710,"max_total_amount":1528,"period":"flexible"}],"start_date":"example start_date 2818"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 9819"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"when_available"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 1224"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"other","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 7903"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 4384"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 2818"],"bank_authorisation":{"adapter":"example adapter 3749","authorisation_type":"example authorisation_type 1528"},"collect_customer_details":{"default_country_code":"example default_country_code 4885","incomplete_fields":{"customer":["example customer 5710"],"customer_billing_detail":["example customer_billing_detail 1387"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 7903","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 4384","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 4547","constraints":{"end_date":"example end_date 8076","max_amount_per_payment":3640,"periodic_limits":[{"alignment":"calendar","max_payments":7839,"max_total_amount":3616,"period":"week"}],"start_date":"example start_date 7051"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1532"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 9183"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"gambling","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 90"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 4801"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "list": { "method": "GET", "path_template": "/billing_requests", "url_params": [], - "body": {"billing_requests":[{"created_at":"2015-01-01T12:00:00.000Z","id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 1223","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 7342","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","constraints":{"end_date":"example end_date 2258","max_amount_per_payment":3767,"periodic_limits":[{"alignment":"creation_date","max_payments":2305,"max_total_amount":90,"period":"week"}],"start_date":"example start_date 1602"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 7578"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 7822"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"status":"pending"},{"created_at":"2015-01-01T12:00:00.000Z","id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3430","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 9513","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","constraints":{"end_date":"example end_date 440","max_amount_per_payment":4208,"periodic_limits":[{"alignment":"creation_date","max_payments":3710,"max_total_amount":1166,"period":"year"}],"start_date":"example start_date 4535"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 4904"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 9371"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"status":"pending"}],"meta":{"cursors":{"after":"example after 1359","before":"example before 9700"},"limit":50}} + "body": {"billing_requests":[{"created_at":"2015-01-01T12:00:00.000Z","id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 440","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 4535","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 2258","constraints":{"end_date":"example end_date 3231","max_amount_per_payment":7578,"periodic_limits":[{"alignment":"calendar","max_payments":1223,"max_total_amount":7822,"period":"flexible"}],"start_date":"example start_date 3767"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1968"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 1166"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"status":"pending"},{"created_at":"2015-01-01T12:00:00.000Z","id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3162","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 4904","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","consent_type":"example consent_type 9371","constraints":{"end_date":"example end_date 3430","max_amount_per_payment":9513,"periodic_limits":[{"alignment":"creation_date","max_payments":6720,"max_total_amount":1359,"period":"day"}],"start_date":"example start_date 3039"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 2984"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"when_available"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 8247"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"status":"pending"}],"meta":{"cursors":{"after":"example after 565","before":"example before 4162"},"limit":50}} }, "get": { "method": "GET", "path_template": "/billing_requests/:identity", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 8010"],"bank_authorisation":{"adapter":"example adapter 2984","authorisation_type":"example authorisation_type 8247"},"collect_customer_details":{"default_country_code":"example default_country_code 565","incomplete_fields":{"customer":["example customer 4162"],"customer_billing_detail":["example customer_billing_detail 6829"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3447","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 1162","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","constraints":{"end_date":"example end_date 6756","max_amount_per_payment":5695,"periodic_limits":[{"alignment":"calendar","max_payments":6629,"max_total_amount":9456,"period":"day"}],"start_date":"example start_date 2048"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 7577"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 5320"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"government","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 783"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 870"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 5695"],"bank_authorisation":{"adapter":"example adapter 8666","authorisation_type":"example authorisation_type 6200"},"collect_customer_details":{"default_country_code":"example default_country_code 9456","incomplete_fields":{"customer":["example customer 6629"],"customer_billing_detail":["example customer_billing_detail 1092"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3756","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 2019","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","consent_type":"example consent_type 6611","constraints":{"end_date":"example end_date 7577","max_amount_per_payment":7886,"periodic_limits":[{"alignment":"calendar","max_payments":5399,"max_total_amount":5320,"period":"month"}],"start_date":"example start_date 8831"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 1888"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"minimum"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 7920"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"tax","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 6756"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 2048"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "notify": { "method": "POST", "path_template": "/billing_requests/:identity/actions/notify", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 1393"],"bank_authorisation":{"adapter":"example adapter 8470","authorisation_type":"example authorisation_type 8996"},"collect_customer_details":{"default_country_code":"example default_country_code 9386","incomplete_fields":{"customer":["example customer 2632"],"customer_billing_detail":["example customer_billing_detail 2520"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 292","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 1888","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","constraints":{"end_date":"example end_date 9888","max_amount_per_payment":8318,"periodic_limits":[{"alignment":"creation_date","max_payments":3756,"max_total_amount":6157,"period":"month"}],"start_date":"example start_date 9103"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 8652"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 7029"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"government","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 417"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 8795"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 2632"],"bank_authorisation":{"adapter":"example adapter 417","authorisation_type":"example authorisation_type 1393"},"collect_customer_details":{"default_country_code":"example default_country_code 8470","incomplete_fields":{"customer":["example customer 8996"],"customer_billing_detail":["example customer_billing_detail 9386"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 2520","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 260","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","consent_type":"example consent_type 1181","constraints":{"end_date":"example end_date 7029","max_amount_per_payment":1661,"periodic_limits":[{"alignment":"calendar","max_payments":1079,"max_total_amount":2420,"period":"day"}],"start_date":"example start_date 3922"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 9551"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"minimum"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 2181"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"utility","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 8795"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 1853"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "fallback": { "method": "POST", "path_template": "/billing_requests/:identity/actions/fallback", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 1719"],"bank_authorisation":{"adapter":"example adapter 5014","authorisation_type":"example authorisation_type 1040"},"collect_customer_details":{"default_country_code":"example default_country_code 6685","incomplete_fields":{"customer":["example customer 1509"],"customer_billing_detail":["example customer_billing_detail 1215"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 1533","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 4637","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 1464","max_amount_per_payment":2060,"periodic_limits":[{"alignment":"creation_date","max_payments":1181,"max_total_amount":9551,"period":"week"}],"start_date":"example start_date 2954"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 60"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 8662"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"gambling","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 7039"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 600"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 235"],"bank_authorisation":{"adapter":"example adapter 6443","authorisation_type":"example authorisation_type 421"},"collect_customer_details":{"default_country_code":"example default_country_code 3173","incomplete_fields":{"customer":["example customer 6000"],"customer_billing_detail":["example customer_billing_detail 9284"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 9516","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 600","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","consent_type":"example consent_type 4637","constraints":{"end_date":"example end_date 1533","max_amount_per_payment":5561,"periodic_limits":[{"alignment":"creation_date","max_payments":1509,"max_total_amount":6685,"period":"flexible"}],"start_date":"example start_date 1719"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 8662"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"minimum"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 6336"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"other","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 574"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 2390"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "choose_currency": { "method": "POST", "path_template": "/billing_requests/:identity/actions/choose_currency", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 2174"],"bank_authorisation":{"adapter":"example adapter 1544","authorisation_type":"example authorisation_type 2395"},"collect_customer_details":{"default_country_code":"example default_country_code 1237","incomplete_fields":{"customer":["example customer 3524"],"customer_billing_detail":["example customer_billing_detail 7293"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3352","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 9648","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 6443","max_amount_per_payment":421,"periodic_limits":[{"alignment":"creation_date","max_payments":574,"max_total_amount":2390,"period":"day"}],"start_date":"example start_date 6336"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 6000"},"metadata":{},"payer_requested_dual_signature":true,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 8622"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"salary","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3472"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 3338"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 8721"],"bank_authorisation":{"adapter":"example adapter 4231","authorisation_type":"example authorisation_type 129"},"collect_customer_details":{"default_country_code":"example default_country_code 855","incomplete_fields":{"customer":["example customer 4511"],"customer_billing_detail":["example customer_billing_detail 5343"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":false,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 3479","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 8682","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"web","consent_type":"example consent_type 2174","constraints":{"end_date":"example end_date 3524","max_amount_per_payment":7293,"periodic_limits":[{"alignment":"calendar","max_payments":9648,"max_total_amount":1606,"period":"day"}],"start_date":"example start_date 1237"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 6117"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"always"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 8151"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"government","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3338"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 3472"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} }, "select_institution": { "method": "POST", "path_template": "/billing_requests/:identity/actions/select_institution", "url_params": ["BRQ123"], - "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 4231"],"bank_authorisation":{"adapter":"example adapter 8721","authorisation_type":"example authorisation_type 855"},"collect_customer_details":{"default_country_code":"example default_country_code 3479","incomplete_fields":{"customer":["example customer 6592"],"customer_billing_detail":["example customer_billing_detail 129"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 106","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 1874","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"paper","constraints":{"end_date":"example end_date 6774","max_amount_per_payment":9859,"periodic_limits":[{"alignment":"calendar","max_payments":7008,"max_total_amount":8408,"period":"month"}],"start_date":"example start_date 3653"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 4511"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"when_available"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"direct","links":{"payment":"example payment 8682"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"personal","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 2375"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 8284"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} + "body": {"billing_requests":{"actions":[{"available_currencies":["example available_currencies 3374"],"bank_authorisation":{"adapter":"example adapter 7587","authorisation_type":"example authorisation_type 1657"},"collect_customer_details":{"default_country_code":"example default_country_code 3546","incomplete_fields":{"customer":["example customer 6724"],"customer_billing_detail":["example customer_billing_detail 9723"]}},"completes_actions":["collect_bank_account"],"institution_guess_status":"pending","required":true,"requires_actions":["collect_bank_account"],"status":"pending","type":"collect_bank_details"}],"created_at":"2015-01-01T12:00:00.000Z","fallback_enabled":true,"id":"BRQ123","links":{"bank_authorisation":"example bank_authorisation 9867","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","customer_billing_detail":"example customer_billing_detail 9859","mandate_request":"MRQ123","mandate_request_mandate":"MD123","organisation":"OR123","payment_provider":"PP123","payment_request":"PRQ123","payment_request_payment":"PM123"},"mandate_request":{"authorisation_source":"telephone","consent_type":"example consent_type 4467","constraints":{"end_date":"example end_date 7008","max_amount_per_payment":5528,"periodic_limits":[{"alignment":"creation_date","max_payments":2375,"max_total_amount":8284,"period":"flexible"}],"start_date":"example start_date 8408"},"currency":"GBP","description":"Top-up Payment","links":{"mandate":"example mandate 2286"},"metadata":{},"payer_requested_dual_signature":false,"scheme":"bacs","verify":"recommended"},"metadata":{},"payment_request":{"amount":1000,"app_fee":100,"currency":"GBP","description":"Top-up Payment","funds_settlement":"managed","links":{"payment":"example payment 6114"},"metadata":{},"reference":"some-custom-ref","scheme":"faster_payments"},"purpose_code":"dependant_support","resources":{"customer":{"company_name":"Hamilton Trading Ltd.","created_at":"2014-01-01T12:00:00.000Z","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999"},"customer_bank_account":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 5166"},"metadata":{}},"customer_billing_detail":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","id":"CU123","ip_address":"127.0.0.1","postal_code":"NW1 6XE","region":"Greater London","schemes":["example schemes 1053"],"swedish_identity_number":"556564-5404"}},"status":"pending"}} } } diff --git a/tests/fixtures/blocks.json b/tests/fixtures/blocks.json index 7b0201a2..3f4c5d16 100644 --- a/tests/fixtures/blocks.json +++ b/tests/fixtures/blocks.json @@ -3,36 +3,36 @@ "method": "POST", "path_template": "/blocks", "url_params": [], - "body": {"blocks":{"active":true,"block_type":"example block_type 928","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 4926","reason_type":"example reason_type 5516","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} + "body": {"blocks":{"active":true,"block_type":"example block_type 9159","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 1128","reason_type":"example reason_type 2409","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} }, "get": { "method": "GET", "path_template": "/blocks/:identity", "url_params": ["BLC123"], - "body": {"blocks":{"active":true,"block_type":"example block_type 7477","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 5036","reason_type":"example reason_type 7412","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} + "body": {"blocks":{"active":true,"block_type":"example block_type 6861","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 7418","reason_type":"example reason_type 8602","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} }, "list": { "method": "GET", "path_template": "/blocks", "url_params": [], - "body": {"blocks":[{"active":true,"block_type":"example block_type 6051","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 7762","reason_type":"example reason_type 9105","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"},{"active":true,"block_type":"example block_type 6789","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 2887","reason_type":"example reason_type 4698","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 2409","before":"example before 9430"},"limit":50}} + "body": {"blocks":[{"active":true,"block_type":"example block_type 8345","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 7653","reason_type":"example reason_type 7871","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"},{"active":true,"block_type":"example block_type 8240","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 9081","reason_type":"example reason_type 2120","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 7276","before":"example before 4405"},"limit":50}} }, "disable": { "method": "POST", "path_template": "/blocks/:identity/actions/disable", "url_params": ["BLC123"], - "body": {"blocks":{"active":true,"block_type":"example block_type 1128","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 6861","reason_type":"example reason_type 9159","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} + "body": {"blocks":{"active":true,"block_type":"example block_type 1509","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 556","reason_type":"example reason_type 1466","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} }, "enable": { "method": "POST", "path_template": "/blocks/:identity/actions/enable", "url_params": ["BLC123"], - "body": {"blocks":{"active":true,"block_type":"example block_type 7418","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 8602","reason_type":"example reason_type 8345","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} + "body": {"blocks":{"active":true,"block_type":"example block_type 7695","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 4834","reason_type":"example reason_type 580","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}} }, "block_by_ref": { "method": "POST", "path_template": "/blocks/block_by_ref", "url_params": [], - "body": {"blocks":[{"active":true,"block_type":"example block_type 7871","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 8240","reason_type":"example reason_type 7653","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"},{"active":true,"block_type":"example block_type 2120","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 4405","reason_type":"example reason_type 9081","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 7276","before":"example before 1509"},"limit":50}} + "body": {"blocks":[{"active":true,"block_type":"example block_type 4267","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 8477","reason_type":"example reason_type 1478","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"},{"active":true,"block_type":"example block_type 3380","created_at":"2014-01-01T12:00:00.000Z","id":"BLC123","reason_description":"example reason_description 4993","reason_type":"example reason_type 2175","resource_reference":"example@example.com","updated_at":"2014-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 2631","before":"example before 3808"},"limit":50}} } } diff --git a/tests/fixtures/creditor_bank_accounts.json b/tests/fixtures/creditor_bank_accounts.json index 41c6fe13..d22dfbd4 100644 --- a/tests/fixtures/creditor_bank_accounts.json +++ b/tests/fixtures/creditor_bank_accounts.json @@ -9,7 +9,7 @@ "method": "GET", "path_template": "/creditor_bank_accounts", "url_params": [], - "body": {"creditor_bank_accounts":[{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"creditor":"CR123"},"metadata":{},"verification_status":"successful"},{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"creditor":"CR123"},"metadata":{},"verification_status":"successful"}],"meta":{"cursors":{"after":"example after 9158","before":"example before 5527"},"limit":50}} + "body": {"creditor_bank_accounts":[{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"creditor":"CR123"},"metadata":{},"verification_status":"successful"},{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"creditor":"CR123"},"metadata":{},"verification_status":"successful"}],"meta":{"cursors":{"after":"example after 3483","before":"example before 3654"},"limit":50}} }, "get": { "method": "GET", diff --git a/tests/fixtures/creditors.json b/tests/fixtures/creditors.json index 50ff3062..d3302a9d 100644 --- a/tests/fixtures/creditors.json +++ b/tests/fixtures/creditors.json @@ -3,24 +3,24 @@ "method": "POST", "path_template": "/creditors", "url_params": [], - "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 580","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 1466","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 7695","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 556","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} + "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 442","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 2884","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 8265","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 8558","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} }, "list": { "method": "GET", "path_template": "/creditors", "url_params": [], - "body": {"creditors":[{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 4834","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 8477","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 4267","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 1478","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"},{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 3380","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 3808","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 4993","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 2175","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}],"meta":{"cursors":{"after":"example after 8265","before":"example before 2631"},"limit":50}} + "body": {"creditors":[{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 9158","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 9253","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 9673","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 6972","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"},{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 5527","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 5513","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 5048","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 496","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}],"meta":{"cursors":{"after":"example after 9023","before":"example before 3162"},"limit":50}} }, "get": { "method": "GET", "path_template": "/creditors/:identity", "url_params": ["CR123"], - "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 9023","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 8558","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 442","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 2884","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} + "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 3740","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 9731","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 2574","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 1306","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} }, "update": { "method": "PUT", "path_template": "/creditors/:identity", "url_params": ["CR123"], - "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 9253","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 3162","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 6972","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 9673","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} + "body": {"creditors":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 2677","bank_reference_prefix":"ACME","can_create_refunds":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","creditor_type":"company","custom_payment_pages_enabled":true,"fx_payout_currency":"EUR","id":"CR123","links":{"default_aud_payout_account":"BA234","default_cad_payout_account":"BA792","default_dkk_payout_account":"BA790","default_eur_payout_account":"BA456","default_gbp_payout_account":"BA123","default_nzd_payout_account":"BA791","default_sek_payout_account":"BA789","default_usd_payout_account":"BA792"},"logo_url":"https://uploads.gocardless.com/logo.png","mandate_imports_enabled":true,"merchant_responsible_for_notifications":true,"name":"Acme","postal_code":"EC1V 7LQ","region":"example region 5402","scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 2332","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 8531","region":"Greater London","scheme":"bacs","status":"pending"}],"verification_status":"action_required"}} } } diff --git a/tests/fixtures/currency_exchange_rates.json b/tests/fixtures/currency_exchange_rates.json index 58d44d99..0a0b2064 100644 --- a/tests/fixtures/currency_exchange_rates.json +++ b/tests/fixtures/currency_exchange_rates.json @@ -3,6 +3,6 @@ "method": "GET", "path_template": "/currency_exchange_rates", "url_params": [], - "body": {"currency_exchange_rates":[{"rate":"1.1234567890","source":"GBP","target":"EUR","time":"2014-01-01T12:00:00Z"},{"rate":"1.1234567890","source":"GBP","target":"EUR","time":"2014-01-01T12:00:00Z"}],"meta":{"cursors":{"after":"example after 5048","before":"example before 496"},"limit":50}} + "body": {"currency_exchange_rates":[{"rate":"1.1234567890","source":"GBP","target":"EUR","time":"2014-01-01T12:00:00Z"},{"rate":"1.1234567890","source":"GBP","target":"EUR","time":"2014-01-01T12:00:00Z"}],"meta":{"cursors":{"after":"example after 2686","before":"example before 4330"},"limit":50}} } } diff --git a/tests/fixtures/customer_bank_accounts.json b/tests/fixtures/customer_bank_accounts.json index bb840a4b..a0f54b34 100644 --- a/tests/fixtures/customer_bank_accounts.json +++ b/tests/fixtures/customer_bank_accounts.json @@ -3,30 +3,30 @@ "method": "POST", "path_template": "/customer_bank_accounts", "url_params": [], - "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 2574"},"metadata":{}}} + "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 604"},"metadata":{}}} }, "list": { "method": "GET", "path_template": "/customer_bank_accounts", "url_params": [], - "body": {"customer_bank_accounts":[{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 1306"},"metadata":{}},{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3740"},"metadata":{}}],"meta":{"cursors":{"after":"example after 2332","before":"example before 8531"},"limit":50}} + "body": {"customer_bank_accounts":[{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3421"},"metadata":{}},{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 8193"},"metadata":{}}],"meta":{"cursors":{"after":"example after 8956","before":"example before 8398"},"limit":50}} }, "get": { "method": "GET", "path_template": "/customer_bank_accounts/:identity", "url_params": ["BA123"], - "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 2677"},"metadata":{}}} + "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 6765"},"metadata":{}}} }, "update": { "method": "PUT", "path_template": "/customer_bank_accounts/:identity", "url_params": ["BA123"], - "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 5402"},"metadata":{}}} + "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 922"},"metadata":{}}} }, "disable": { "method": "POST", "path_template": "/customer_bank_accounts/:identity/actions/disable", "url_params": ["BA123"], - "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 3654"},"metadata":{}}} + "body": {"customer_bank_accounts":{"account_holder_name":"Billie Jean","account_number_ending":"1234","account_type":"savings","bank_name":"BARCLAYS BANK PLC","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","enabled":true,"id":"BA123","links":{"customer":"example customer 45"},"metadata":{}}} } } diff --git a/tests/fixtures/customer_notifications.json b/tests/fixtures/customer_notifications.json index d59c8b18..8dd73f83 100644 --- a/tests/fixtures/customer_notifications.json +++ b/tests/fixtures/customer_notifications.json @@ -3,6 +3,6 @@ "method": "POST", "path_template": "/customer_notifications/:identity/actions/handle", "url_params": ["PCN123"], - "body": {"customer_notifications":{"action_taken":"example action_taken 4330","action_taken_at":"2024-08-09T14:41:32.435Z","action_taken_by":"example action_taken_by 3483","id":"PCN123","links":{"customer":"CU123","event":"EV123","mandate":"MD123","payment":"PM123","refund":"RF123","subscription":"SB123"},"type":"payment_created"}} + "body": {"customer_notifications":{"action_taken":"example action_taken 4806","action_taken_at":"2024-08-13T10:09:22.480Z","action_taken_by":"example action_taken_by 6494","id":"PCN123","links":{"customer":"CU123","event":"EV123","mandate":"MD123","payment":"PM123","refund":"RF123","subscription":"SB123"},"type":"payment_created"}} } } diff --git a/tests/fixtures/customers.json b/tests/fixtures/customers.json index 2b214d27..6e5681ef 100644 --- a/tests/fixtures/customers.json +++ b/tests/fixtures/customers.json @@ -9,7 +9,7 @@ "method": "GET", "path_template": "/customers", "url_params": [], - "body": {"customers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"}],"meta":{"cursors":{"after":"example after 5513","before":"example before 9731"},"limit":50}} + "body": {"customers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","id":"CU123","language":"en","metadata":{},"phone_number":"+64 4 817 9999","postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"}],"meta":{"cursors":{"after":"example after 1462","before":"example before 4187"},"limit":50}} }, "get": { "method": "GET", diff --git a/tests/fixtures/events.json b/tests/fixtures/events.json index 017017f5..59a346dc 100644 --- a/tests/fixtures/events.json +++ b/tests/fixtures/events.json @@ -3,12 +3,12 @@ "method": "GET", "path_template": "/events", "url_params": [], - "body": {"events":[{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-09T14:41:32.437Z","id":"PCN123","mandatory":true,"type":"example type 2686"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"},{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-09T14:41:32.437Z","id":"PCN123","mandatory":true,"type":"example type 1462"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"}],"meta":{"cursors":{"after":"example after 3421","before":"example before 8193"},"limit":50}} + "body": {"events":[{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-13T10:09:22.480Z","id":"PCN123","mandatory":true,"type":"example type 1420"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"},{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-13T10:09:22.480Z","id":"PCN123","mandatory":true,"type":"example type 7759"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"}],"meta":{"cursors":{"after":"example after 4024","before":"example before 8999"},"limit":50}} }, "get": { "method": "GET", "path_template": "/events/:identity", "url_params": ["EV123"], - "body": {"events":{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-09T14:41:32.437Z","id":"PCN123","mandatory":false,"type":"example type 8398"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"}} + "body": {"events":{"action":"cancelled","created_at":"2014-01-01T12:00:00.000Z","customer_notifications":[{"deadline":"2024-08-13T10:09:22.480Z","id":"PCN123","mandatory":true,"type":"example type 7124"}],"details":{"bank_account_id":"BA123","cause":"bank_account_disabled","currency":"GBP","description":"Customer's bank account closed","item_count":10,"not_retried_reason":"failure_filter_applied","origin":"bank","property":"fx_payout_currency","reason_code":"ADDACS-B","scheme":"bacs","will_attempt_retry":true},"id":"EV123","links":{"bank_authorisation":"BAU123","billing_request":"BRQ123","billing_request_flow":"BRF123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","instalment_schedule":"IS123","mandate":"MD123","mandate_request_mandate":"MD123","new_customer_bank_account":"BA123","new_mandate":"MD123","organisation":"OR123","parent_event":"EV123","payer_authorisation":"PAU123","payment":"PM123","payment_request_payment":"PM123","payout":"PO123","previous_customer_bank_account":"BA123","refund":"RF123","scheme_identifier":"SU123","subscription":"SB123"},"metadata":{},"resource_metadata":{},"resource_type":"mandates"}} } } diff --git a/tests/fixtures/exports.json b/tests/fixtures/exports.json index 8fec63aa..2b34720f 100644 --- a/tests/fixtures/exports.json +++ b/tests/fixtures/exports.json @@ -3,12 +3,12 @@ "method": "GET", "path_template": "/exports/:identity", "url_params": ["EX123"], - "body": {"exports":{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","download_url":"example download_url 6765","export_type":"payments_index","id":"EX123"}} + "body": {"exports":{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","download_url":"example download_url 8853","export_type":"payments_index","id":"EX123"}} }, "list": { "method": "GET", "path_template": "/exports", "url_params": [], - "body": {"exports":[{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","export_type":"payments_index","id":"EX123"},{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","export_type":"payments_index","id":"EX123"}],"meta":{"cursors":{"after":"example after 45","before":"example before 922"},"limit":50}} + "body": {"exports":[{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","export_type":"payments_index","id":"EX123"},{"created_at":"2014-01-01T12:00:00.000Z","currency":"GBP","export_type":"payments_index","id":"EX123"}],"meta":{"cursors":{"after":"example after 8475","before":"example before 7774"},"limit":50}} } } diff --git a/tests/fixtures/instalment_schedules.json b/tests/fixtures/instalment_schedules.json index a4753098..bb5e6981 100644 --- a/tests/fixtures/instalment_schedules.json +++ b/tests/fixtures/instalment_schedules.json @@ -15,7 +15,7 @@ "method": "GET", "path_template": "/instalment_schedules", "url_params": [], - "body": {"instalment_schedules":[{"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"IS123","links":{"customer":"CU123","mandate":"MD123","payments":["PM123","PM456"]},"metadata":{},"name":"Invoice 4404","payment_errors":{"0":[{"field":"charge_date","message":"must be on or after mandate's next_possible_customer_charge_date"}]},"status":"active","total_amount":1000},{"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"IS123","links":{"customer":"CU123","mandate":"MD123","payments":["PM123","PM456"]},"metadata":{},"name":"Invoice 4404","payment_errors":{"0":[{"field":"charge_date","message":"must be on or after mandate's next_possible_customer_charge_date"}]},"status":"active","total_amount":1000}],"meta":{"cursors":{"after":"example after 4806","before":"example before 6494"},"limit":50}} + "body": {"instalment_schedules":[{"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"IS123","links":{"customer":"CU123","mandate":"MD123","payments":["PM123","PM456"]},"metadata":{},"name":"Invoice 4404","payment_errors":{"0":[{"field":"charge_date","message":"must be on or after mandate's next_possible_customer_charge_date"}]},"status":"active","total_amount":1000},{"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"IS123","links":{"customer":"CU123","mandate":"MD123","payments":["PM123","PM456"]},"metadata":{},"name":"Invoice 4404","payment_errors":{"0":[{"field":"charge_date","message":"must be on or after mandate's next_possible_customer_charge_date"}]},"status":"active","total_amount":1000}],"meta":{"cursors":{"after":"example after 8089","before":"example before 5740"},"limit":50}} }, "get": { "method": "GET", diff --git a/tests/fixtures/institutions.json b/tests/fixtures/institutions.json index b5f99f45..9ea3fdba 100644 --- a/tests/fixtures/institutions.json +++ b/tests/fixtures/institutions.json @@ -3,12 +3,12 @@ "method": "GET", "path_template": "/institutions", "url_params": [], - "body": {"institutions":[{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"},{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"}],"meta":{"cursors":{"after":"example after 8999","before":"example before 4024"},"limit":50}} + "body": {"institutions":[{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"},{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"}],"meta":{"cursors":{"after":"example after 545","before":"example before 5814"},"limit":50}} }, "list_for_billing_request": { "method": "GET", "path_template": "/billing_requests/:identity/institutions", "url_params": ["BRQ123"], - "body": {"institutions":[{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"},{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"}],"meta":{"cursors":{"after":"example after 2044","before":"example before 1420"},"limit":50}} + "body": {"institutions":[{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"},{"autocompletes_collect_bank_account":true,"country_code":"GB","icon_url":"https://gocardless/assets/icons/monzo","id":"monzo","logo_url":"https://gocardless/assets/logos/monzo","name":"VAT"}],"meta":{"cursors":{"after":"example after 1581","before":"example before 8339"},"limit":50}} } } diff --git a/tests/fixtures/mandate_import_entries.json b/tests/fixtures/mandate_import_entries.json index 38eb8f0e..e83cd3cb 100644 --- a/tests/fixtures/mandate_import_entries.json +++ b/tests/fixtures/mandate_import_entries.json @@ -9,6 +9,6 @@ "method": "GET", "path_template": "/mandate_import_entries", "url_params": [], - "body": {"mandate_import_entries":[{"created_at":"2014-01-01T12:00:00.000Z","links":{"customer":"CU123","customer_bank_account":"BA123","mandate":"MD123","mandate_import":"IM0000AAAAAAA"},"record_identifier":"bank-file.xml/line-1"},{"created_at":"2014-01-01T12:00:00.000Z","links":{"customer":"CU123","customer_bank_account":"BA123","mandate":"MD123","mandate_import":"IM0000AAAAAAA"},"record_identifier":"bank-file.xml/line-1"}],"meta":{"cursors":{"after":"example after 9301","before":"example before 1267"},"limit":50}} + "body": {"mandate_import_entries":[{"created_at":"2014-01-01T12:00:00.000Z","links":{"customer":"CU123","customer_bank_account":"BA123","mandate":"MD123","mandate_import":"IM0000AAAAAAA"},"record_identifier":"bank-file.xml/line-1"},{"created_at":"2014-01-01T12:00:00.000Z","links":{"customer":"CU123","customer_bank_account":"BA123","mandate":"MD123","mandate_import":"IM0000AAAAAAA"},"record_identifier":"bank-file.xml/line-1"}],"meta":{"cursors":{"after":"example after 7913","before":"example before 6872"},"limit":50}} } } diff --git a/tests/fixtures/mandates.json b/tests/fixtures/mandates.json index ed091e4a..33efa8db 100644 --- a/tests/fixtures/mandates.json +++ b/tests/fixtures/mandates.json @@ -3,36 +3,36 @@ "method": "POST", "path_template": "/mandates", "url_params": [], - "body": {"mandates":{"authorisation_source":"telephone","consent_parameters":{"end_date":"example end_date 5740","max_amount_per_payment":7124,"periods":[{"max_amount_per_period":8853,"max_payments_per_period":7774,"period":"month"}],"start_date":"example start_date 8475"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} + "body": {"mandates":{"authorisation_source":"telephone","consent_parameters":{"end_date":"example end_date 1695","max_amount_per_payment":3131,"periods":[{"max_amount_per_period":5629,"max_payments_per_period":7051,"period":"day"}],"start_date":"example start_date 4203"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} }, "list": { "method": "GET", "path_template": "/mandates", "url_params": [], - "body": {"mandates":[{"authorisation_source":"telephone","consent_parameters":{"end_date":"example end_date 7051","max_amount_per_payment":6985,"periods":[{"max_amount_per_period":8339,"max_payments_per_period":1581,"period":"day"}],"start_date":"example start_date 3131"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"},{"authorisation_source":"paper","consent_parameters":{"end_date":"example end_date 1262","max_amount_per_payment":973,"periods":[{"max_amount_per_period":8372,"max_payments_per_period":5275,"period":"month"}],"start_date":"example start_date 4377"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 5814","before":"example before 8089"},"limit":50}} + "body": {"mandates":[{"authorisation_source":"web","consent_parameters":{"end_date":"example end_date 973","max_amount_per_payment":3017,"periods":[{"max_amount_per_period":7807,"max_payments_per_period":3780,"period":"flexible"}],"start_date":"example start_date 2205"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"},{"authorisation_source":"telephone","consent_parameters":{"end_date":"example end_date 8033","max_amount_per_payment":2474,"periods":[{"max_amount_per_period":1723,"max_payments_per_period":894,"period":"flexible"}],"start_date":"example start_date 3922"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}],"meta":{"cursors":{"after":"example after 4377","before":"example before 5275"},"limit":50}} }, "get": { "method": "GET", "path_template": "/mandates/:identity", "url_params": ["MD123"], - "body": {"mandates":{"authorisation_source":"web","consent_parameters":{"end_date":"example end_date 9759","max_amount_per_payment":7807,"periods":[{"max_amount_per_period":3780,"max_payments_per_period":2205,"period":"week"}],"start_date":"example start_date 2474"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} + "body": {"mandates":{"authorisation_source":"paper","consent_parameters":{"end_date":"example end_date 909","max_amount_per_payment":9277,"periods":[{"max_amount_per_period":5395,"max_payments_per_period":9914,"period":"year"}],"start_date":"example start_date 7650"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} }, "update": { "method": "PUT", "path_template": "/mandates/:identity", "url_params": ["MD123"], - "body": {"mandates":{"authorisation_source":"web","consent_parameters":{"end_date":"example end_date 7574","max_amount_per_payment":8610,"periods":[{"max_amount_per_period":5395,"max_payments_per_period":9914,"period":"day"}],"start_date":"example start_date 8033"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} + "body": {"mandates":{"authorisation_source":"paper","consent_parameters":{"end_date":"example end_date 3354","max_amount_per_payment":4721,"periods":[{"max_amount_per_period":8198,"max_payments_per_period":2734,"period":"year"}],"start_date":"example start_date 8879"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} }, "cancel": { "method": "POST", "path_template": "/mandates/:identity/actions/cancel", "url_params": ["MD123"], - "body": {"mandates":{"authorisation_source":"paper","consent_parameters":{"end_date":"example end_date 7650","max_amount_per_payment":909,"periods":[{"max_amount_per_period":671,"max_payments_per_period":9277,"period":"day"}],"start_date":"example start_date 2523"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} + "body": {"mandates":{"authorisation_source":"paper","consent_parameters":{"end_date":"example end_date 9301","max_amount_per_payment":8849,"periods":[{"max_amount_per_period":9326,"max_payments_per_period":10,"period":"week"}],"start_date":"example start_date 1267"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} }, "reinstate": { "method": "POST", "path_template": "/mandates/:identity/actions/reinstate", "url_params": ["MD123"], - "body": {"mandates":{"authorisation_source":"web","consent_parameters":{"end_date":"example end_date 10","max_amount_per_payment":8879,"periods":[{"max_amount_per_period":4721,"max_payments_per_period":7587,"period":"flexible"}],"start_date":"example start_date 9326"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"direct","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} + "body": {"mandates":{"authorisation_source":"web","consent_parameters":{"end_date":"example end_date 4401","max_amount_per_payment":8140,"periods":[{"max_amount_per_period":5596,"max_payments_per_period":9466,"period":"year"}],"start_date":"example start_date 8374"},"created_at":"2014-01-01T12:00:00.000Z","funds_settlement":"managed","id":"MD123","links":{"creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","new_mandate":"MD123"},"metadata":{},"next_possible_charge_date":"2014-10-27","next_possible_standard_ach_charge_date":"2014-10-27","payments_require_approval":false,"reference":"REF-123","scheme":"bacs","status":"pending_submission","verified_at":"2021-01-01T12:00:00.000Z"}} } } diff --git a/tests/fixtures/negative_balance_limits.json b/tests/fixtures/negative_balance_limits.json index 77afa8c7..769f0905 100644 --- a/tests/fixtures/negative_balance_limits.json +++ b/tests/fixtures/negative_balance_limits.json @@ -3,7 +3,7 @@ "method": "GET", "path_template": "/negative_balance_limits", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 9488","before":"example before 8849"},"limit":50},"negative_balance_limits":[{"balance_limit":10000,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"NBL123","links":{"creator_user":"US123","creditor":"CR123"}},{"balance_limit":10000,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"NBL123","links":{"creator_user":"US123","creditor":"CR123"}}]} + "body": {"meta":{"cursors":{"after":"example after 9959","before":"example before 5214"},"limit":50},"negative_balance_limits":[{"balance_limit":10000,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"NBL123","links":{"creator_user":"US123","creditor":"CR123"}},{"balance_limit":10000,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","id":"NBL123","links":{"creator_user":"US123","creditor":"CR123"}}]} }, "create": { "method": "POST", diff --git a/tests/fixtures/payer_authorisations.json b/tests/fixtures/payer_authorisations.json index c18e60e1..80e6924c 100644 --- a/tests/fixtures/payer_authorisations.json +++ b/tests/fixtures/payer_authorisations.json @@ -3,30 +3,30 @@ "method": "GET", "path_template": "/payer_authorisations/:identity", "url_params": ["PA123"], - "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 3920","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 8374","message":"example message 4401","request_pointer":"example request_pointer 8140"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} + "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 325","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 1446","message":"example message 9921","request_pointer":"example request_pointer 6244"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} }, "create": { "method": "POST", "path_template": "/payer_authorisations", "url_params": [], - "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 3973","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 9466","message":"example message 75","request_pointer":"example request_pointer 5596"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} + "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 1488","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 6487","message":"example message 7063","request_pointer":"example request_pointer 1436"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} }, "update": { "method": "PUT", "path_template": "/payer_authorisations/:identity", "url_params": ["PA123"], - "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 6110","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 7913","message":"example message 5214","request_pointer":"example request_pointer 6872"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} + "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 8223","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 1925","message":"example message 9026","request_pointer":"example request_pointer 9219"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} }, "submit": { "method": "POST", "path_template": "/payer_authorisations/:identity/actions/submit", "url_params": ["PA123"], - "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 9959","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 1446","message":"example message 9921","request_pointer":"example request_pointer 325"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} + "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 9200","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 3114","message":"example message 8730","request_pointer":"example request_pointer 3176"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} }, "confirm": { "method": "POST", "path_template": "/payer_authorisations/:identity/actions/confirm", "url_params": ["PA123"], - "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 6244","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 7063","message":"example message 1436","request_pointer":"example request_pointer 6487"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} + "body": {"payer_authorisations":{"bank_account":{"account_holder_name":"Billie Jean","account_number":"55779911","account_number_ending":"1234","account_number_suffix":"00","account_type":"savings","bank_code":"example bank_code 1300","branch_code":"20-00-00","country_code":"GB","currency":"EUR","iban":"GB60BARC20000055779911","metadata":{}},"created_at":"2020-01-01T12:00:00.000Z","customer":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","city":"London","company_name":"Hamilton Trading Ltd.","country_code":"GB","danish_identity_number":"220550-6218","email":"user@example.com","family_name":"Osborne","given_name":"Frank","locale":"en-GB","metadata":{},"postal_code":"NW1 6XE","region":"Greater London","swedish_identity_number":"556564-5404"},"id":"PA123","incomplete_fields":[{"field":"example field 8051","message":"example message 9434","request_pointer":"example request_pointer 8619"}],"links":{"bank_account":"BA123","customer":"CU123","mandate":"MD123"},"mandate":{"metadata":{},"payer_ip_address":"127.0.0.1","reference":"REF-123","scheme":"bacs"},"status":"created"}} } } diff --git a/tests/fixtures/payments.json b/tests/fixtures/payments.json index d669426a..c159592a 100644 --- a/tests/fixtures/payments.json +++ b/tests/fixtures/payments.json @@ -3,13 +3,13 @@ "method": "POST", "path_template": "/payments", "url_params": [], - "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}} + "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":true,"status":"submitted"}} }, "list": { "method": "GET", "path_template": "/payments", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 8730","before":"example before 3114"},"limit":50},"payments":[{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":true,"status":"submitted"},{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":true,"status":"submitted"}]} + "body": {"meta":{"cursors":{"after":"example after 7694","before":"example before 7221"},"limit":50},"payments":[{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":true,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"},{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}]} }, "get": { "method": "GET", @@ -21,18 +21,18 @@ "method": "PUT", "path_template": "/payments/:identity", "url_params": ["PM123"], - "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":true,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}} + "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":true,"status":"submitted"}} }, "cancel": { "method": "POST", "path_template": "/payments/:identity/actions/cancel", "url_params": ["PM123"], - "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":true,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":true,"status":"submitted"}} + "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":true,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}} }, "retry": { "method": "POST", "path_template": "/payments/:identity/actions/retry", "url_params": ["PM123"], - "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":true,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}} + "body": {"payments":{"amount":1000,"amount_refunded":150,"charge_date":"2014-05-21","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","description":"One-off upgrade fee","faster_ach":false,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PM123","links":{"creditor":"CR123","instalment_schedule":"IS123","mandate":"MD123","payout":"PO123","subscription":"SU123"},"metadata":{},"reference":"WINEBOX001","retry_if_possible":false,"status":"submitted"}} } } diff --git a/tests/fixtures/payout_items.json b/tests/fixtures/payout_items.json index 07a0e267..7b46336f 100644 --- a/tests/fixtures/payout_items.json +++ b/tests/fixtures/payout_items.json @@ -3,6 +3,6 @@ "method": "GET", "path_template": "/payout_items", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 7694","before":"example before 2239"},"limit":50},"payout_items":[{"amount":"45.0","links":{"mandate":"MD123","payment":"PM123","refund":"RF123"},"taxes":[{"amount":"1.1","currency":"EUR","destination_amount":"1.1","destination_currency":"EUR","exchange_rate":"1.11205","tax_rate_id":"GB_VAT_1"}],"type":"payment_paid_out"},{"amount":"45.0","links":{"mandate":"MD123","payment":"PM123","refund":"RF123"},"taxes":[{"amount":"1.1","currency":"EUR","destination_amount":"1.1","destination_currency":"EUR","exchange_rate":"1.11205","tax_rate_id":"GB_VAT_1"}],"type":"payment_paid_out"}]} + "body": {"meta":{"cursors":{"after":"example after 6813","before":"example before 6316"},"limit":50},"payout_items":[{"amount":"45.0","links":{"mandate":"MD123","payment":"PM123","refund":"RF123"},"taxes":[{"amount":"1.1","currency":"EUR","destination_amount":"1.1","destination_currency":"EUR","exchange_rate":"1.11205","tax_rate_id":"GB_VAT_1"}],"type":"payment_paid_out"},{"amount":"45.0","links":{"mandate":"MD123","payment":"PM123","refund":"RF123"},"taxes":[{"amount":"1.1","currency":"EUR","destination_amount":"1.1","destination_currency":"EUR","exchange_rate":"1.11205","tax_rate_id":"GB_VAT_1"}],"type":"payment_paid_out"}]} } } diff --git a/tests/fixtures/payouts.json b/tests/fixtures/payouts.json index 94f37de6..774a3256 100644 --- a/tests/fixtures/payouts.json +++ b/tests/fixtures/payouts.json @@ -3,7 +3,7 @@ "method": "GET", "path_template": "/payouts", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 5642","before":"example before 541"},"limit":50},"payouts":[{"amount":1000,"arrival_date":"2014-01-01","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","deducted_fees":20,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PO123","links":{"creditor":"CR123","creditor_bank_account":"BA123"},"metadata":{"salesforce_id":"ABCD1234"},"payout_type":"merchant","reference":"ref-1","status":"pending","tax_currency":"EUR"},{"amount":1000,"arrival_date":"2014-01-01","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","deducted_fees":20,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PO123","links":{"creditor":"CR123","creditor_bank_account":"BA123"},"metadata":{"salesforce_id":"ABCD1234"},"payout_type":"merchant","reference":"ref-1","status":"pending","tax_currency":"EUR"}]} + "body": {"meta":{"cursors":{"after":"example after 1582","before":"example before 9719"},"limit":50},"payouts":[{"amount":1000,"arrival_date":"2014-01-01","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","deducted_fees":20,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PO123","links":{"creditor":"CR123","creditor_bank_account":"BA123"},"metadata":{"salesforce_id":"ABCD1234"},"payout_type":"merchant","reference":"ref-1","status":"pending","tax_currency":"EUR"},{"amount":1000,"arrival_date":"2014-01-01","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","deducted_fees":20,"fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"PO123","links":{"creditor":"CR123","creditor_bank_account":"BA123"},"metadata":{"salesforce_id":"ABCD1234"},"payout_type":"merchant","reference":"ref-1","status":"pending","tax_currency":"EUR"}]} }, "get": { "method": "GET", diff --git a/tests/fixtures/redirect_flows.json b/tests/fixtures/redirect_flows.json index 570e2f7b..6468be80 100644 --- a/tests/fixtures/redirect_flows.json +++ b/tests/fixtures/redirect_flows.json @@ -3,18 +3,18 @@ "method": "POST", "path_template": "/redirect_flows", "url_params": [], - "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 7221","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} + "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 2516","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} }, "get": { "method": "GET", "path_template": "/redirect_flows/:identity", "url_params": ["RE123456"], - "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 6574","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} + "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 3322","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} }, "complete": { "method": "POST", "path_template": "/redirect_flows/:identity/actions/complete", "url_params": ["RE123456"], - "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 701","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} + "body": {"redirect_flows":{"confirmation_url":"https://pay.gocardless.com/flow/RE123/success","created_at":"2014-01-01T12:00:00.000Z","description":"Standard subscription","id":"RE123456","links":{"billing_request":"BR123","creditor":"CR123","customer":"CU123","customer_bank_account":"BA123","mandate":"MD123"},"mandate_reference":"example mandate_reference 6301","metadata":{"salesforce_id":"ABCD1234"},"redirect_url":"http://pay.gocardless.com/flow/RE123","scheme":"bacs","session_token":"SESS_wSs0uGYMISxzqOBq","success_redirect_url":"https://example.com/pay/confirm"}} } } diff --git a/tests/fixtures/refunds.json b/tests/fixtures/refunds.json index 2eb86e66..cfab467e 100644 --- a/tests/fixtures/refunds.json +++ b/tests/fixtures/refunds.json @@ -9,7 +9,7 @@ "method": "GET", "path_template": "/refunds", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 9485","before":"example before 9750"},"limit":50},"refunds":[{"amount":150,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"RF123","links":{"mandate":"MD123","payment":"PM123"},"metadata":{},"reference":"WINEBOX001","status":"submitted"},{"amount":150,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"RF123","links":{"mandate":"MD123","payment":"PM123"},"metadata":{},"reference":"WINEBOX001","status":"submitted"}]} + "body": {"meta":{"cursors":{"after":"example after 9277","before":"example before 9555"},"limit":50},"refunds":[{"amount":150,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"RF123","links":{"mandate":"MD123","payment":"PM123"},"metadata":{},"reference":"WINEBOX001","status":"submitted"},{"amount":150,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","fx":{"estimated_exchange_rate":"1.1234567890","exchange_rate":"1.1234567890","fx_amount":1150,"fx_currency":"EUR"},"id":"RF123","links":{"mandate":"MD123","payment":"PM123"},"metadata":{},"reference":"WINEBOX001","status":"submitted"}]} }, "get": { "method": "GET", diff --git a/tests/fixtures/scheme_identifiers.json b/tests/fixtures/scheme_identifiers.json index b944052d..f112ba40 100644 --- a/tests/fixtures/scheme_identifiers.json +++ b/tests/fixtures/scheme_identifiers.json @@ -3,18 +3,18 @@ "method": "POST", "path_template": "/scheme_identifiers", "url_params": [], - "body": {"scheme_identifiers":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 864","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 2088","region":"Greater London","scheme":"bacs","status":"pending"}} + "body": {"scheme_identifiers":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 6217","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 3963","region":"Greater London","scheme":"bacs","status":"pending"}} }, "list": { "method": "GET", "path_template": "/scheme_identifiers", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 6316","before":"example before 6813"},"limit":50},"scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 6216","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 4560","region":"Greater London","scheme":"bacs","status":"pending"},{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 9719","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 1582","region":"Greater London","scheme":"bacs","status":"pending"}]} + "body": {"meta":{"cursors":{"after":"example after 3740","before":"example before 3333"},"limit":50},"scheme_identifiers":[{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 758","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 2232","region":"Greater London","scheme":"bacs","status":"pending"},{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 7179","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 3875","region":"Greater London","scheme":"bacs","status":"pending"}]} }, "get": { "method": "GET", "path_template": "/scheme_identifiers/:identity", "url_params": ["SU123"], - "body": {"scheme_identifiers":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 2516","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 3322","region":"Greater London","scheme":"bacs","status":"pending"}} + "body": {"scheme_identifiers":{"address_line1":"221B Baker Street","address_line2":"Marylebone","address_line3":"City of Westminster","can_specify_mandate_reference":false,"city":"London","country_code":"GB","created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","email":"user@example.com","id":"SU123","minimum_advance_notice":3,"name":"example name 7627","phone_number":"+44 20 1234 1234","postal_code":"NW1 6XE","reference":"example reference 4534","region":"Greater London","scheme":"bacs","status":"pending"}} } } diff --git a/tests/fixtures/subscriptions.json b/tests/fixtures/subscriptions.json index 625a2eed..a95f3705 100644 --- a/tests/fixtures/subscriptions.json +++ b/tests/fixtures/subscriptions.json @@ -3,13 +3,13 @@ "method": "POST", "path_template": "/subscriptions", "url_params": [], - "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":true,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} + "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} }, "list": { "method": "GET", "path_template": "/subscriptions", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 2232","before":"example before 7179"},"limit":50},"subscriptions":[{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":true,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]},{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":true,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}]} + "body": {"meta":{"cursors":{"after":"example after 6346","before":"example before 1009"},"limit":50},"subscriptions":[{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":true,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]},{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}]} }, "get": { "method": "GET", @@ -21,24 +21,24 @@ "method": "PUT", "path_template": "/subscriptions/:identity", "url_params": ["SB123"], - "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":true,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} + "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} }, "pause": { "method": "POST", "path_template": "/subscriptions/:identity/actions/pause", "url_params": ["SB123"], - "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":true,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} + "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":true,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} }, "resume": { "method": "POST", "path_template": "/subscriptions/:identity/actions/resume", "url_params": ["SB123"], - "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} + "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":true,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} }, "cancel": { "method": "POST", "path_template": "/subscriptions/:identity/actions/cancel", "url_params": ["SB123"], - "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":true,"payment_reference":"GOLDPLAN","retry_if_possible":false,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} + "body": {"subscriptions":{"amount":1000,"app_fee":100,"count":5,"created_at":"2014-01-01T12:00:00.000Z","currency":"EUR","day_of_month":28,"earliest_charge_date_after_resume":"2014-11-03","end_date":"2015-10-21","id":"SB123","interval":1,"interval_unit":"monthly","links":{"mandate":"MD123"},"metadata":{},"month":"january","name":"12 month subscription","parent_plan_paused":false,"payment_reference":"GOLDPLAN","retry_if_possible":true,"start_date":"2014-10-21","status":"active","upcoming_payments":[{"amount":2500,"charge_date":"2014-11-03"}]}} } } diff --git a/tests/fixtures/tax_rates.json b/tests/fixtures/tax_rates.json index 1ea00aaa..7f276e15 100644 --- a/tests/fixtures/tax_rates.json +++ b/tests/fixtures/tax_rates.json @@ -3,7 +3,7 @@ "method": "GET", "path_template": "/tax_rates", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 712","before":"example before 6346"},"limit":50},"tax_rates":[{"end_date":"2014-01-01","id":"GB_VAT_1","jurisdiction":"GBP","percentage":"20.0","start_date":"2014-01-01","type":"VAT"},{"end_date":"2014-01-01","id":"GB_VAT_1","jurisdiction":"GBP","percentage":"20.0","start_date":"2014-01-01","type":"VAT"}]} + "body": {"meta":{"cursors":{"after":"example after 3360","before":"example before 9953"},"limit":50},"tax_rates":[{"end_date":"2014-01-01","id":"GB_VAT_1","jurisdiction":"GBP","percentage":"20.0","start_date":"2014-01-01","type":"VAT"},{"end_date":"2014-01-01","id":"GB_VAT_1","jurisdiction":"GBP","percentage":"20.0","start_date":"2014-01-01","type":"VAT"}]} }, "get": { "method": "GET", diff --git a/tests/fixtures/transferred_mandates.json b/tests/fixtures/transferred_mandates.json index 493e2374..dbf85bfa 100644 --- a/tests/fixtures/transferred_mandates.json +++ b/tests/fixtures/transferred_mandates.json @@ -3,6 +3,6 @@ "method": "GET", "path_template": "/transferred_mandates/:identity", "url_params": ["MD123"], - "body": {"transferred_mandates":{"encrypted_customer_bank_details":"example encrypted_customer_bank_details 9356","encrypted_decryption_key":"example encrypted_decryption_key 1009","links":{"customer_bank_account":"BA123","mandate":"MD123"},"public_key_id":"example public_key_id 104"}} + "body": {"transferred_mandates":{"encrypted_customer_bank_details":"example encrypted_customer_bank_details 894","encrypted_decryption_key":"example encrypted_decryption_key 5985","links":{"customer_bank_account":"BA123","mandate":"MD123"},"public_key_id":"example public_key_id 5721"}} } } diff --git a/tests/fixtures/verification_details.json b/tests/fixtures/verification_details.json index 00a52154..37764511 100644 --- a/tests/fixtures/verification_details.json +++ b/tests/fixtures/verification_details.json @@ -3,12 +3,12 @@ "method": "POST", "path_template": "/verification_details", "url_params": [], - "body": {"verification_details":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 3589","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 6314"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"}} + "body": {"verification_details":{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 6213","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 9401"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"}} }, "list": { "method": "GET", "path_template": "/verification_details", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 2442","before":"example before 7223"},"limit":50},"verification_details":[{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 7764","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 5339"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"},{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 1730","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 5619"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"}]} + "body": {"meta":{"cursors":{"after":"example after 4721","before":"example before 4283"},"limit":50},"verification_details":[{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 7328","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 1757"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"},{"address_line1":"338-346 Goswell Road","address_line2":"Islington","address_line3":"example address_line3 6262","city":"London","company_number":"07495895","description":"Wine and cheese seller","directors":[{"city":"London","country_code":"GB","date_of_birth":"1986-02-19","family_name":"Jones","given_name":"Tom","postal_code":"EC1V 7LQ","street":"example street 6184"}],"links":{"creditor":"CR123"},"name":"Acme Limited","postal_code":"EC1V 7LQ"}]} } } diff --git a/tests/fixtures/webhooks.json b/tests/fixtures/webhooks.json index 5fe52dc2..89f9e801 100644 --- a/tests/fixtures/webhooks.json +++ b/tests/fixtures/webhooks.json @@ -3,18 +3,18 @@ "method": "GET", "path_template": "/webhooks", "url_params": [], - "body": {"meta":{"cursors":{"after":"example after 3360","before":"example before 9953"},"limit":50},"webhooks":[{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":false,"request_body":"example request_body 7328","request_headers":{},"response_body":"example response_body 5985","response_body_truncated":false,"response_code":1757,"response_headers":{},"response_headers_content_truncated":false,"response_headers_count_truncated":false,"successful":true,"url":"https://example.com/webhooks"},{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":false,"request_body":"example request_body 4283","request_headers":{},"response_body":"example response_body 4721","response_body_truncated":false,"response_code":342,"response_headers":{},"response_headers_content_truncated":true,"response_headers_count_truncated":false,"successful":true,"url":"https://example.com/webhooks"}]} + "body": {"meta":{"cursors":{"after":"example after 7694","before":"example before 4740"},"limit":50},"webhooks":[{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":false,"request_body":"example request_body 5540","request_headers":{},"response_body":"example response_body 1350","response_body_truncated":true,"response_code":342,"response_headers":{},"response_headers_content_truncated":true,"response_headers_count_truncated":true,"successful":false,"url":"https://example.com/webhooks"},{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":false,"request_body":"example request_body 6452","request_headers":{},"response_body":"example response_body 6516","response_body_truncated":false,"response_code":4769,"response_headers":{},"response_headers_content_truncated":false,"response_headers_count_truncated":true,"successful":false,"url":"https://example.com/webhooks"}]} }, "get": { "method": "GET", "path_template": "/webhooks/:identity", "url_params": ["WB123"], - "body": {"webhooks":{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":true,"request_body":"example request_body 1898","request_headers":{},"response_body":"example response_body 6591","response_body_truncated":false,"response_code":5707,"response_headers":{},"response_headers_content_truncated":false,"response_headers_count_truncated":false,"successful":true,"url":"https://example.com/webhooks"}} + "body": {"webhooks":{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":true,"request_body":"example request_body 1590","request_headers":{},"response_body":"example response_body 7417","response_body_truncated":false,"response_code":2370,"response_headers":{},"response_headers_content_truncated":true,"response_headers_count_truncated":true,"successful":false,"url":"https://example.com/webhooks"}} }, "retry": { "method": "POST", "path_template": "/webhooks/:identity/actions/retry", "url_params": ["WB123"], - "body": {"webhooks":{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":false,"request_body":"example request_body 7694","request_headers":{},"response_body":"example response_body 2283","response_body_truncated":true,"response_code":8098,"response_headers":{},"response_headers_content_truncated":true,"response_headers_count_truncated":false,"successful":false,"url":"https://example.com/webhooks"}} + "body": {"webhooks":{"created_at":"2014-01-01T12:00:00.000Z","id":"WB123","is_test":true,"request_body":"example request_body 5768","request_headers":{},"response_body":"example response_body 2762","response_body_truncated":true,"response_code":7251,"response_headers":{},"response_headers_content_truncated":true,"response_headers_count_truncated":false,"successful":false,"url":"https://example.com/webhooks"}} } } diff --git a/tests/integration/billing_requests_integration_test.py b/tests/integration/billing_requests_integration_test.py index e570d936..7a5d80be 100644 --- a/tests/integration/billing_requests_integration_test.py +++ b/tests/integration/billing_requests_integration_test.py @@ -44,6 +44,7 @@ def test_billing_requests_create(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -132,6 +133,7 @@ def test_billing_requests_collect_customer_details(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -196,6 +198,7 @@ def test_billing_requests_collect_bank_account(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -260,6 +263,7 @@ def test_billing_requests_confirm_payer_details(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -324,6 +328,7 @@ def test_billing_requests_fulfil(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -388,6 +393,7 @@ def test_billing_requests_cancel(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -523,6 +529,7 @@ def test_billing_requests_get(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -594,6 +601,7 @@ def test_billing_requests_notify(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -658,6 +666,7 @@ def test_billing_requests_fallback(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -722,6 +731,7 @@ def test_billing_requests_choose_currency(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description'] @@ -786,6 +796,7 @@ def test_billing_requests_select_institution(): assert response.links.payment_request == body.get('links')['payment_request'] assert response.links.payment_request_payment == body.get('links')['payment_request_payment'] assert response.mandate_request.authorisation_source == body.get('mandate_request')['authorisation_source'] + assert response.mandate_request.consent_type == body.get('mandate_request')['consent_type'] assert response.mandate_request.constraints == body.get('mandate_request')['constraints'] assert response.mandate_request.currency == body.get('mandate_request')['currency'] assert response.mandate_request.description == body.get('mandate_request')['description']