gr4vy 1.10.12__py3-none-any.whl → 1.10.14__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- gr4vy/_version.py +3 -3
- gr4vy/basesdk.py +20 -6
- gr4vy/models/__init__.py +132 -0
- gr4vy/models/accountsreceivablesreportspec.py +18 -1
- gr4vy/models/accountupdaterinquirysummary.py +18 -1
- gr4vy/models/accountupdaterjob.py +18 -1
- gr4vy/models/accountupdateroptions.py +30 -31
- gr4vy/models/add_buyer_shipping_detailsop.py +34 -1
- gr4vy/models/add_buyerop.py +34 -1
- gr4vy/models/add_payment_linkop.py +34 -1
- gr4vy/models/add_reportop.py +34 -1
- gr4vy/models/address.py +38 -39
- gr4vy/models/adyencardoptions.py +32 -33
- gr4vy/models/adyenoptions.py +14 -19
- gr4vy/models/adyensepaoptions.py +30 -31
- gr4vy/models/adyensplitsoptions.py +14 -19
- gr4vy/models/affirmitineraryoptions.py +34 -35
- gr4vy/models/affirmoptions.py +14 -19
- gr4vy/models/airline.py +58 -59
- gr4vy/models/airlineleg.py +66 -67
- gr4vy/models/airlinepassenger.py +42 -43
- gr4vy/models/applepaypaymentmethodcreate.py +34 -35
- gr4vy/models/auditlogentries.py +14 -19
- gr4vy/models/auditlogentry.py +14 -19
- gr4vy/models/auditlogentryuser.py +14 -19
- gr4vy/models/billingdetails.py +32 -33
- gr4vy/models/braintreedynamicdatafieldsoptions.py +26 -27
- gr4vy/models/braintreeoptions.py +18 -19
- gr4vy/models/browserinfo.py +14 -19
- gr4vy/models/buyer.py +31 -32
- gr4vy/models/buyercreate.py +18 -29
- gr4vy/models/buyers.py +14 -19
- gr4vy/models/buyerupdate.py +18 -29
- gr4vy/models/cancel_transactionop.py +34 -1
- gr4vy/models/capture_transactionop.py +30 -19
- gr4vy/models/cardpaymentmethodcreate.py +31 -32
- gr4vy/models/cardschemedefinition.py +18 -1
- gr4vy/models/cardwithurlpaymentmethodcreate.py +33 -34
- gr4vy/models/cartitem.py +52 -53
- gr4vy/models/chaseoptions.py +14 -19
- gr4vy/models/checkoutsession.py +37 -38
- gr4vy/models/checkoutsessioncreate.py +35 -36
- gr4vy/models/checkoutsessionpaymentmethod.py +16 -27
- gr4vy/models/checkoutsessionpaymentmethodcreate.py +18 -28
- gr4vy/models/checkoutsessionpaymentmethoddetails.py +14 -19
- gr4vy/models/checkoutsessionwithurlpaymentmethodcreate.py +29 -30
- gr4vy/models/clicktopayfpanpaymentmethodcreate.py +32 -33
- gr4vy/models/clicktopaypaymentmethodcreate.py +28 -29
- gr4vy/models/configure_digital_walletop.py +34 -1
- gr4vy/models/create_account_updater_jobop.py +34 -1
- gr4vy/models/create_apple_pay_digital_wallet_sessionop.py +34 -1
- gr4vy/models/create_checkout_sessionop.py +34 -1
- gr4vy/models/create_full_transaction_refundop.py +30 -19
- gr4vy/models/create_gift_cardop.py +34 -1
- gr4vy/models/create_google_pay_digital_wallet_sessionop.py +34 -1
- gr4vy/models/create_payment_method_network_token_cryptogramop.py +34 -1
- gr4vy/models/create_payment_method_network_tokenop.py +34 -1
- gr4vy/models/create_payment_method_payment_service_tokenop.py +34 -1
- gr4vy/models/create_payment_methodop.py +34 -1
- gr4vy/models/create_payment_service_sessionop.py +34 -1
- gr4vy/models/create_payment_serviceop.py +34 -1
- gr4vy/models/create_payoutop.py +34 -1
- gr4vy/models/create_report_execution_urlop.py +34 -1
- gr4vy/models/create_three_ds_scenarioop.py +79 -0
- gr4vy/models/create_transaction_refundop.py +34 -1
- gr4vy/models/create_transactionop.py +32 -19
- gr4vy/models/createsession.py +14 -19
- gr4vy/models/cryptogram.py +18 -1
- gr4vy/models/cybersourceantifraudoptions.py +18 -27
- gr4vy/models/cybersourceoptions.py +27 -28
- gr4vy/models/delete_buyer_shipping_detailsop.py +34 -1
- gr4vy/models/delete_buyerop.py +34 -1
- gr4vy/models/delete_checkout_sessionop.py +34 -1
- gr4vy/models/delete_digital_walletop.py +34 -1
- gr4vy/models/delete_gift_cardop.py +34 -1
- gr4vy/models/delete_payment_method_network_tokenop.py +34 -1
- gr4vy/models/delete_payment_method_payment_service_tokenop.py +34 -1
- gr4vy/models/delete_payment_methodop.py +34 -1
- gr4vy/models/delete_payment_serviceop.py +34 -1
- gr4vy/models/delete_three_ds_scenarioop.py +76 -0
- gr4vy/models/detailedsettlementreportspec.py +18 -1
- gr4vy/models/digitalwallet.py +27 -33
- gr4vy/models/digitalwalletcreate.py +23 -28
- gr4vy/models/digitalwalletupdate.py +30 -31
- gr4vy/models/dlocaloptions.py +14 -19
- gr4vy/models/dlocalupioptions.py +14 -19
- gr4vy/models/dlocalupiwalletoptions.py +18 -33
- gr4vy/models/dlocalwalletoptions.py +14 -19
- gr4vy/models/expire_payment_linkop.py +34 -1
- gr4vy/models/fiservinstallmentoptions.py +27 -28
- gr4vy/models/fiservoptions.py +14 -19
- gr4vy/models/forterantifraudoptions.py +30 -31
- gr4vy/models/forterantifraudoptionscartitem.py +13 -18
- gr4vy/models/forterantifraudoptionscartitembasicitemdata.py +14 -19
- gr4vy/models/forterantifraudoptionscartitembeneficiary.py +13 -18
- gr4vy/models/forterantifraudoptionscartitembeneficiaryaddress.py +18 -19
- gr4vy/models/forterantifraudoptionscartitembeneficiarycomments.py +18 -27
- gr4vy/models/forterantifraudoptionscartitembeneficiarypersonaldetails.py +14 -19
- gr4vy/models/forterantifraudoptionscartitemdeliverydetails.py +13 -18
- gr4vy/models/forterantifraudoptionsdiscount.py +13 -18
- gr4vy/models/forterantifraudoptionsdiscountcoupondiscountamount.py +14 -19
- gr4vy/models/get_buyer_shipping_detailsop.py +34 -1
- gr4vy/models/get_buyerop.py +34 -1
- gr4vy/models/get_checkout_sessionop.py +34 -1
- gr4vy/models/get_digital_walletop.py +34 -1
- gr4vy/models/get_gift_cardop.py +34 -1
- gr4vy/models/get_payment_linkop.py +34 -1
- gr4vy/models/get_payment_methodop.py +34 -1
- gr4vy/models/get_payment_serviceop.py +34 -1
- gr4vy/models/get_payoutop.py +34 -1
- gr4vy/models/get_refundop.py +34 -1
- gr4vy/models/get_report_executionop.py +34 -1
- gr4vy/models/get_reportop.py +34 -1
- gr4vy/models/get_three_ds_scenarioop.py +105 -0
- gr4vy/models/get_transaction_refundop.py +34 -1
- gr4vy/models/get_transaction_settlementop.py +34 -1
- gr4vy/models/get_transactionop.py +34 -1
- gr4vy/models/giftcard.py +14 -19
- gr4vy/models/giftcardcreate.py +14 -19
- gr4vy/models/giftcardredemption.py +29 -30
- gr4vy/models/giftcards.py +14 -19
- gr4vy/models/giftcardservice.py +18 -1
- gr4vy/models/giftcardsummary.py +35 -36
- gr4vy/models/givingblockoptions.py +14 -19
- gr4vy/models/googlepayassurancedetails.py +14 -19
- gr4vy/models/googlepayfpanpaymentmethodcreate.py +32 -33
- gr4vy/models/googlepaypaymentmethodcreate.py +36 -37
- gr4vy/models/guestbuyer.py +30 -31
- gr4vy/models/internal/globals.py +18 -1
- gr4vy/models/latitudeoptions.py +14 -19
- gr4vy/models/list_all_report_executionsop.py +50 -35
- gr4vy/models/list_audit_logsop.py +39 -26
- gr4vy/models/list_buyer_gift_cardsop.py +32 -23
- gr4vy/models/list_buyer_payment_methodsop.py +42 -33
- gr4vy/models/list_buyer_shipping_detailsop.py +34 -1
- gr4vy/models/list_buyersop.py +32 -25
- gr4vy/models/list_card_scheme_definitionsop.py +34 -1
- gr4vy/models/list_digital_walletsop.py +34 -1
- gr4vy/models/list_gift_card_balancesop.py +34 -1
- gr4vy/models/list_gift_cardsop.py +38 -25
- gr4vy/models/list_merchant_accountsop.py +14 -19
- gr4vy/models/list_payment_linksop.py +32 -19
- gr4vy/models/list_payment_method_network_tokensop.py +34 -1
- gr4vy/models/list_payment_method_payment_service_tokensop.py +30 -19
- gr4vy/models/list_payment_methodsop.py +48 -33
- gr4vy/models/list_payment_optionsop.py +34 -1
- gr4vy/models/list_payment_service_definitionsop.py +14 -19
- gr4vy/models/list_payment_servicesop.py +32 -25
- gr4vy/models/list_payoutsop.py +30 -19
- gr4vy/models/list_report_executionsop.py +30 -19
- gr4vy/models/list_reportsop.py +39 -26
- gr4vy/models/list_transaction_actionsop.py +34 -1
- gr4vy/models/list_transaction_eventsop.py +30 -19
- gr4vy/models/list_transaction_refundsop.py +34 -1
- gr4vy/models/list_transaction_settlementsop.py +34 -1
- gr4vy/models/list_transactionsop.py +124 -109
- gr4vy/models/mattildatapioptions.py +14 -19
- gr4vy/models/merchantaccount.py +52 -53
- gr4vy/models/merchantaccountcreate.py +52 -53
- gr4vy/models/merchantaccounts.py +14 -19
- gr4vy/models/merchantaccountupdate.py +54 -55
- gr4vy/models/mockcardmerchantadvicecodeoptions.py +14 -19
- gr4vy/models/mockcardoptions.py +14 -19
- gr4vy/models/networktoken.py +18 -1
- gr4vy/models/networktokencreate.py +14 -19
- gr4vy/models/networktokenpaymentmethodcreate.py +34 -35
- gr4vy/models/nuveiairlinedataoptions.py +14 -19
- gr4vy/models/nuveiidealoptions.py +14 -19
- gr4vy/models/nuveioptions.py +14 -19
- gr4vy/models/nuveipseoptions.py +13 -18
- gr4vy/models/oxxooptions.py +14 -19
- gr4vy/models/paymentlink.py +59 -60
- gr4vy/models/paymentlinkcreate.py +59 -60
- gr4vy/models/paymentlinks.py +14 -19
- gr4vy/models/paymentmethod.py +51 -52
- gr4vy/models/paymentmethodcard.py +14 -19
- gr4vy/models/paymentmethoddetailscard.py +14 -19
- gr4vy/models/paymentmethods.py +14 -19
- gr4vy/models/paymentmethodstoredcard.py +18 -1
- gr4vy/models/paymentmethodsummary.py +47 -48
- gr4vy/models/paymentoption.py +14 -19
- gr4vy/models/paymentoptioncontext.py +14 -19
- gr4vy/models/paymentoptioncontextapprovalui.py +14 -19
- gr4vy/models/paymentoptionrequest.py +18 -26
- gr4vy/models/paymentservice.py +35 -36
- gr4vy/models/paymentservicecreate.py +36 -37
- gr4vy/models/paymentservicedefinition.py +14 -19
- gr4vy/models/paymentservicedefinitions.py +14 -19
- gr4vy/models/paymentservices.py +14 -19
- gr4vy/models/paymentservicetoken.py +14 -19
- gr4vy/models/paymentservicetokencreate.py +14 -19
- gr4vy/models/paymentserviceupdate.py +45 -46
- gr4vy/models/payoutconnectionoptions.py +14 -19
- gr4vy/models/payoutcreate.py +34 -35
- gr4vy/models/payoutmerchant.py +14 -19
- gr4vy/models/payoutmerchantsummary.py +14 -19
- gr4vy/models/payoutpaymentservice.py +14 -19
- gr4vy/models/payoutsummaries.py +14 -19
- gr4vy/models/payoutsummary.py +35 -36
- gr4vy/models/paypaloptions.py +14 -19
- gr4vy/models/paypalshippingoptions.py +14 -19
- gr4vy/models/paypalshippingoptionsitem.py +14 -19
- gr4vy/models/plaidpaymentmethodcreate.py +31 -32
- gr4vy/models/powertranzoptions.py +14 -19
- gr4vy/models/recipient.py +14 -19
- gr4vy/models/redirectpaymentmethodcreate.py +18 -27
- gr4vy/models/refund.py +39 -40
- gr4vy/models/refunds.py +14 -19
- gr4vy/models/register_digital_wallet_domainop.py +34 -1
- gr4vy/models/report.py +33 -34
- gr4vy/models/reportcreate.py +14 -19
- gr4vy/models/reportexecution.py +18 -1
- gr4vy/models/reportexecutions.py +14 -19
- gr4vy/models/reportexecutionsummary.py +18 -1
- gr4vy/models/reportexecutionurlgenerate.py +18 -1
- gr4vy/models/reports.py +14 -19
- gr4vy/models/reportsummary.py +16 -19
- gr4vy/models/reportupdate.py +14 -19
- gr4vy/models/requiredcheckoutfields.py +14 -19
- gr4vy/models/resume_payment_method_network_tokenop.py +34 -1
- gr4vy/models/security.py +18 -1
- gr4vy/models/settlement.py +16 -25
- gr4vy/models/shippingdetails.py +35 -36
- gr4vy/models/shippingdetailscreate.py +18 -31
- gr4vy/models/shippingdetailsupdate.py +18 -31
- gr4vy/models/statementdescriptor.py +34 -35
- gr4vy/models/stripeconnectoptions.py +30 -31
- gr4vy/models/stripeoptions.py +14 -19
- gr4vy/models/suspend_payment_method_network_tokenop.py +34 -1
- gr4vy/models/sync_transactionop.py +34 -1
- gr4vy/models/threedsecure.py +14 -19
- gr4vy/models/threedsecuredatav1.py +14 -19
- gr4vy/models/threedsecuredatav2.py +14 -19
- gr4vy/models/threedsecureerror.py +14 -19
- gr4vy/models/threedsecurescenario.py +77 -0
- gr4vy/models/threedsecurescenarioconditions.py +84 -0
- gr4vy/models/threedsecurescenariocreate.py +24 -0
- gr4vy/models/threedsecurescenariooutcome.py +57 -0
- gr4vy/models/threedsecurescenariooutcomeauthentication.py +31 -0
- gr4vy/models/threedsecurescenariooutcomeresult.py +27 -0
- gr4vy/models/threedsecurescenarios.py +58 -0
- gr4vy/models/threedsecurescenarioupdate.py +54 -0
- gr4vy/models/threedsecurev2.py +34 -35
- gr4vy/models/tokenpaymentmethodcreate.py +14 -19
- gr4vy/models/transaction.py +111 -112
- gr4vy/models/transactionaction.py +18 -1
- gr4vy/models/transactionbuyer.py +31 -32
- gr4vy/models/transactioncancel.py +14 -19
- gr4vy/models/transactioncapture.py +14 -19
- gr4vy/models/transactioncapturecreate.py +14 -19
- gr4vy/models/transactionconnectionoptions.py +104 -105
- gr4vy/models/transactioncreate.py +88 -89
- gr4vy/models/transactionevent.py +18 -1
- gr4vy/models/transactionevents.py +14 -19
- gr4vy/models/transactiongiftcard.py +14 -19
- gr4vy/models/transactionpaymentmethod.py +49 -50
- gr4vy/models/transactionpaymentservice.py +18 -1
- gr4vy/models/transactionrefundallcreate.py +14 -19
- gr4vy/models/transactionrefundcreate.py +16 -25
- gr4vy/models/transactionretriesreportspec.py +18 -1
- gr4vy/models/transactionsreportspec.py +18 -1
- gr4vy/models/transactionsummaries.py +14 -19
- gr4vy/models/transactionsummary.py +50 -51
- gr4vy/models/transactionthreedsecuresummary.py +18 -33
- gr4vy/models/transactionupdate.py +14 -19
- gr4vy/models/transactionvoid.py +14 -19
- gr4vy/models/travelhubcustomdata.py +14 -19
- gr4vy/models/travelhuboptions.py +14 -19
- gr4vy/models/trustlyoptions.py +14 -19
- gr4vy/models/unregister_digital_wallet_domainop.py +34 -1
- gr4vy/models/update_buyer_shipping_detailsop.py +34 -1
- gr4vy/models/update_buyerop.py +34 -1
- gr4vy/models/update_checkout_sessionop.py +34 -1
- gr4vy/models/update_digital_walletop.py +34 -1
- gr4vy/models/update_payment_serviceop.py +34 -1
- gr4vy/models/update_reportop.py +34 -1
- gr4vy/models/update_three_ds_scenarioop.py +91 -0
- gr4vy/models/update_transactionop.py +34 -1
- gr4vy/models/verify_payment_service_credentialsop.py +34 -1
- gr4vy/models/verifycredentials.py +14 -19
- gr4vy/models/void_transactionop.py +30 -19
- gr4vy/models/wpayeverdaypayoptions.py +30 -31
- gr4vy/models/wpaypaytooptions.py +14 -19
- gr4vy/models/wpaypaytoresourceoptions.py +14 -19
- gr4vy/models/wpaypaytosimulationoptions.py +14 -19
- gr4vy/sdk.py +3 -0
- gr4vy/three_ds_scenarios.py +1322 -0
- gr4vy/utils/__init__.py +13 -1
- {gr4vy-1.10.12.dist-info → gr4vy-1.10.14.dist-info}/METADATA +8 -1
- gr4vy-1.10.14.dist-info/RECORD +464 -0
- gr4vy-1.10.12.dist-info/RECORD +0 -451
- {gr4vy-1.10.12.dist-info → gr4vy-1.10.14.dist-info}/WHEEL +0 -0
|
@@ -38,42 +38,29 @@ class ShippingDetailsUpdate(BaseModel):
|
|
|
38
38
|
|
|
39
39
|
@model_serializer(mode="wrap")
|
|
40
40
|
def serialize_model(self, handler):
|
|
41
|
-
optional_fields =
|
|
42
|
-
"first_name",
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
"phone_number",
|
|
46
|
-
|
|
47
|
-
]
|
|
48
|
-
nullable_fields = [
|
|
49
|
-
"first_name",
|
|
50
|
-
"last_name",
|
|
51
|
-
"email_address",
|
|
52
|
-
"phone_number",
|
|
53
|
-
"address",
|
|
54
|
-
]
|
|
55
|
-
null_default_fields = []
|
|
56
|
-
|
|
41
|
+
optional_fields = set(
|
|
42
|
+
["first_name", "last_name", "email_address", "phone_number", "address"]
|
|
43
|
+
)
|
|
44
|
+
nullable_fields = set(
|
|
45
|
+
["first_name", "last_name", "email_address", "phone_number", "address"]
|
|
46
|
+
)
|
|
57
47
|
serialized = handler(self)
|
|
58
|
-
|
|
59
48
|
m = {}
|
|
60
49
|
|
|
61
50
|
for n, f in type(self).model_fields.items():
|
|
62
51
|
k = f.alias or n
|
|
63
52
|
val = serialized.get(k)
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
):
|
|
77
|
-
m[k] = val
|
|
53
|
+
is_nullable_and_explicitly_set = (
|
|
54
|
+
k in nullable_fields
|
|
55
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
56
|
+
)
|
|
57
|
+
|
|
58
|
+
if val != UNSET_SENTINEL:
|
|
59
|
+
if (
|
|
60
|
+
val is not None
|
|
61
|
+
or k not in optional_fields
|
|
62
|
+
or is_nullable_and_explicitly_set
|
|
63
|
+
):
|
|
64
|
+
m[k] = val
|
|
78
65
|
|
|
79
66
|
return m
|
|
@@ -51,46 +51,45 @@ class StatementDescriptor(BaseModel):
|
|
|
51
51
|
|
|
52
52
|
@model_serializer(mode="wrap")
|
|
53
53
|
def serialize_model(self, handler):
|
|
54
|
-
optional_fields =
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
54
|
+
optional_fields = set(
|
|
55
|
+
[
|
|
56
|
+
"name",
|
|
57
|
+
"description",
|
|
58
|
+
"city",
|
|
59
|
+
"country",
|
|
60
|
+
"phone_number",
|
|
61
|
+
"url",
|
|
62
|
+
"postal_code",
|
|
63
|
+
]
|
|
64
|
+
)
|
|
65
|
+
nullable_fields = set(
|
|
66
|
+
[
|
|
67
|
+
"name",
|
|
68
|
+
"description",
|
|
69
|
+
"city",
|
|
70
|
+
"country",
|
|
71
|
+
"phone_number",
|
|
72
|
+
"url",
|
|
73
|
+
"postal_code",
|
|
74
|
+
]
|
|
75
|
+
)
|
|
74
76
|
serialized = handler(self)
|
|
75
|
-
|
|
76
77
|
m = {}
|
|
77
78
|
|
|
78
79
|
for n, f in type(self).model_fields.items():
|
|
79
80
|
k = f.alias or n
|
|
80
81
|
val = serialized.get(k)
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
):
|
|
94
|
-
m[k] = val
|
|
82
|
+
is_nullable_and_explicitly_set = (
|
|
83
|
+
k in nullable_fields
|
|
84
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
85
|
+
)
|
|
86
|
+
|
|
87
|
+
if val != UNSET_SENTINEL:
|
|
88
|
+
if (
|
|
89
|
+
val is not None
|
|
90
|
+
or k not in optional_fields
|
|
91
|
+
or is_nullable_and_explicitly_set
|
|
92
|
+
):
|
|
93
|
+
m[k] = val
|
|
95
94
|
|
|
96
95
|
return m
|
|
@@ -37,42 +37,41 @@ class StripeConnectOptions(BaseModel):
|
|
|
37
37
|
|
|
38
38
|
@model_serializer(mode="wrap")
|
|
39
39
|
def serialize_model(self, handler):
|
|
40
|
-
optional_fields =
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
40
|
+
optional_fields = set(
|
|
41
|
+
[
|
|
42
|
+
"stripe_account",
|
|
43
|
+
"application_fee_amount",
|
|
44
|
+
"on_behalf_of",
|
|
45
|
+
"transfer_data_destination",
|
|
46
|
+
"transfer_group",
|
|
47
|
+
]
|
|
48
|
+
)
|
|
49
|
+
nullable_fields = set(
|
|
50
|
+
[
|
|
51
|
+
"stripe_account",
|
|
52
|
+
"application_fee_amount",
|
|
53
|
+
"on_behalf_of",
|
|
54
|
+
"transfer_data_destination",
|
|
55
|
+
"transfer_group",
|
|
56
|
+
]
|
|
57
|
+
)
|
|
56
58
|
serialized = handler(self)
|
|
57
|
-
|
|
58
59
|
m = {}
|
|
59
60
|
|
|
60
61
|
for n, f in type(self).model_fields.items():
|
|
61
62
|
k = f.alias or n
|
|
62
63
|
val = serialized.get(k)
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
):
|
|
76
|
-
m[k] = val
|
|
64
|
+
is_nullable_and_explicitly_set = (
|
|
65
|
+
k in nullable_fields
|
|
66
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
if val != UNSET_SENTINEL:
|
|
70
|
+
if (
|
|
71
|
+
val is not None
|
|
72
|
+
or k not in optional_fields
|
|
73
|
+
or is_nullable_and_explicitly_set
|
|
74
|
+
):
|
|
75
|
+
m[k] = val
|
|
77
76
|
|
|
78
77
|
return m
|
gr4vy/models/stripeoptions.py
CHANGED
|
@@ -23,30 +23,25 @@ class StripeOptions(BaseModel):
|
|
|
23
23
|
|
|
24
24
|
@model_serializer(mode="wrap")
|
|
25
25
|
def serialize_model(self, handler):
|
|
26
|
-
optional_fields = ["error_on_requires_action", "stripe_connect"]
|
|
27
|
-
nullable_fields = ["error_on_requires_action", "stripe_connect"]
|
|
28
|
-
null_default_fields = []
|
|
29
|
-
|
|
26
|
+
optional_fields = set(["error_on_requires_action", "stripe_connect"])
|
|
27
|
+
nullable_fields = set(["error_on_requires_action", "stripe_connect"])
|
|
30
28
|
serialized = handler(self)
|
|
31
|
-
|
|
32
29
|
m = {}
|
|
33
30
|
|
|
34
31
|
for n, f in type(self).model_fields.items():
|
|
35
32
|
k = f.alias or n
|
|
36
33
|
val = serialized.get(k)
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
):
|
|
50
|
-
m[k] = val
|
|
34
|
+
is_nullable_and_explicitly_set = (
|
|
35
|
+
k in nullable_fields
|
|
36
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
if val != UNSET_SENTINEL:
|
|
40
|
+
if (
|
|
41
|
+
val is not None
|
|
42
|
+
or k not in optional_fields
|
|
43
|
+
or is_nullable_and_explicitly_set
|
|
44
|
+
):
|
|
45
|
+
m[k] = val
|
|
51
46
|
|
|
52
47
|
return m
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
from gr4vy.types import BaseModel
|
|
4
|
+
from gr4vy.types import BaseModel, UNSET_SENTINEL
|
|
5
5
|
from gr4vy.utils import FieldMetadata, HeaderMetadata, PathParamMetadata
|
|
6
6
|
import pydantic
|
|
7
|
+
from pydantic import model_serializer
|
|
7
8
|
from typing import Optional
|
|
8
9
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
9
10
|
|
|
@@ -21,6 +22,22 @@ class SuspendPaymentMethodNetworkTokenGlobals(BaseModel):
|
|
|
21
22
|
] = None
|
|
22
23
|
r"""The ID of the merchant account to use for this request."""
|
|
23
24
|
|
|
25
|
+
@model_serializer(mode="wrap")
|
|
26
|
+
def serialize_model(self, handler):
|
|
27
|
+
optional_fields = set(["merchant_account_id"])
|
|
28
|
+
serialized = handler(self)
|
|
29
|
+
m = {}
|
|
30
|
+
|
|
31
|
+
for n, f in type(self).model_fields.items():
|
|
32
|
+
k = f.alias or n
|
|
33
|
+
val = serialized.get(k)
|
|
34
|
+
|
|
35
|
+
if val != UNSET_SENTINEL:
|
|
36
|
+
if val is not None or k not in optional_fields:
|
|
37
|
+
m[k] = val
|
|
38
|
+
|
|
39
|
+
return m
|
|
40
|
+
|
|
24
41
|
|
|
25
42
|
class SuspendPaymentMethodNetworkTokenRequestTypedDict(TypedDict):
|
|
26
43
|
payment_method_id: str
|
|
@@ -48,3 +65,19 @@ class SuspendPaymentMethodNetworkTokenRequest(BaseModel):
|
|
|
48
65
|
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
|
49
66
|
] = None
|
|
50
67
|
r"""The ID of the merchant account to use for this request."""
|
|
68
|
+
|
|
69
|
+
@model_serializer(mode="wrap")
|
|
70
|
+
def serialize_model(self, handler):
|
|
71
|
+
optional_fields = set(["merchant_account_id"])
|
|
72
|
+
serialized = handler(self)
|
|
73
|
+
m = {}
|
|
74
|
+
|
|
75
|
+
for n, f in type(self).model_fields.items():
|
|
76
|
+
k = f.alias or n
|
|
77
|
+
val = serialized.get(k)
|
|
78
|
+
|
|
79
|
+
if val != UNSET_SENTINEL:
|
|
80
|
+
if val is not None or k not in optional_fields:
|
|
81
|
+
m[k] = val
|
|
82
|
+
|
|
83
|
+
return m
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
from gr4vy.types import BaseModel
|
|
4
|
+
from gr4vy.types import BaseModel, UNSET_SENTINEL
|
|
5
5
|
from gr4vy.utils import FieldMetadata, HeaderMetadata, PathParamMetadata
|
|
6
6
|
import pydantic
|
|
7
|
+
from pydantic import model_serializer
|
|
7
8
|
from typing import Optional
|
|
8
9
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
9
10
|
|
|
@@ -21,6 +22,22 @@ class SyncTransactionGlobals(BaseModel):
|
|
|
21
22
|
] = None
|
|
22
23
|
r"""The ID of the merchant account to use for this request."""
|
|
23
24
|
|
|
25
|
+
@model_serializer(mode="wrap")
|
|
26
|
+
def serialize_model(self, handler):
|
|
27
|
+
optional_fields = set(["merchant_account_id"])
|
|
28
|
+
serialized = handler(self)
|
|
29
|
+
m = {}
|
|
30
|
+
|
|
31
|
+
for n, f in type(self).model_fields.items():
|
|
32
|
+
k = f.alias or n
|
|
33
|
+
val = serialized.get(k)
|
|
34
|
+
|
|
35
|
+
if val != UNSET_SENTINEL:
|
|
36
|
+
if val is not None or k not in optional_fields:
|
|
37
|
+
m[k] = val
|
|
38
|
+
|
|
39
|
+
return m
|
|
40
|
+
|
|
24
41
|
|
|
25
42
|
class SyncTransactionRequestTypedDict(TypedDict):
|
|
26
43
|
transaction_id: str
|
|
@@ -39,3 +56,19 @@ class SyncTransactionRequest(BaseModel):
|
|
|
39
56
|
FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
|
|
40
57
|
] = None
|
|
41
58
|
r"""The ID of the merchant account to use for this request."""
|
|
59
|
+
|
|
60
|
+
@model_serializer(mode="wrap")
|
|
61
|
+
def serialize_model(self, handler):
|
|
62
|
+
optional_fields = set(["merchant_account_id"])
|
|
63
|
+
serialized = handler(self)
|
|
64
|
+
m = {}
|
|
65
|
+
|
|
66
|
+
for n, f in type(self).model_fields.items():
|
|
67
|
+
k = f.alias or n
|
|
68
|
+
val = serialized.get(k)
|
|
69
|
+
|
|
70
|
+
if val != UNSET_SENTINEL:
|
|
71
|
+
if val is not None or k not in optional_fields:
|
|
72
|
+
m[k] = val
|
|
73
|
+
|
|
74
|
+
return m
|
gr4vy/models/threedsecure.py
CHANGED
|
@@ -17,30 +17,25 @@ class ThreeDSecure(BaseModel):
|
|
|
17
17
|
|
|
18
18
|
@model_serializer(mode="wrap")
|
|
19
19
|
def serialize_model(self, handler):
|
|
20
|
-
optional_fields = ["amount"]
|
|
21
|
-
nullable_fields = ["amount"]
|
|
22
|
-
null_default_fields = []
|
|
23
|
-
|
|
20
|
+
optional_fields = set(["amount"])
|
|
21
|
+
nullable_fields = set(["amount"])
|
|
24
22
|
serialized = handler(self)
|
|
25
|
-
|
|
26
23
|
m = {}
|
|
27
24
|
|
|
28
25
|
for n, f in type(self).model_fields.items():
|
|
29
26
|
k = f.alias or n
|
|
30
27
|
val = serialized.get(k)
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
):
|
|
44
|
-
m[k] = val
|
|
28
|
+
is_nullable_and_explicitly_set = (
|
|
29
|
+
k in nullable_fields
|
|
30
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
31
|
+
)
|
|
32
|
+
|
|
33
|
+
if val != UNSET_SENTINEL:
|
|
34
|
+
if (
|
|
35
|
+
val is not None
|
|
36
|
+
or k not in optional_fields
|
|
37
|
+
or is_nullable_and_explicitly_set
|
|
38
|
+
):
|
|
39
|
+
m[k] = val
|
|
45
40
|
|
|
46
41
|
return m
|
|
@@ -53,30 +53,25 @@ class ThreeDSecureDataV1(BaseModel):
|
|
|
53
53
|
|
|
54
54
|
@model_serializer(mode="wrap")
|
|
55
55
|
def serialize_model(self, handler):
|
|
56
|
-
optional_fields = ["scheme"]
|
|
57
|
-
nullable_fields = ["scheme"]
|
|
58
|
-
null_default_fields = []
|
|
59
|
-
|
|
56
|
+
optional_fields = set(["scheme"])
|
|
57
|
+
nullable_fields = set(["scheme"])
|
|
60
58
|
serialized = handler(self)
|
|
61
|
-
|
|
62
59
|
m = {}
|
|
63
60
|
|
|
64
61
|
for n, f in type(self).model_fields.items():
|
|
65
62
|
k = f.alias or n
|
|
66
63
|
val = serialized.get(k)
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
):
|
|
80
|
-
m[k] = val
|
|
64
|
+
is_nullable_and_explicitly_set = (
|
|
65
|
+
k in nullable_fields
|
|
66
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
if val != UNSET_SENTINEL:
|
|
70
|
+
if (
|
|
71
|
+
val is not None
|
|
72
|
+
or k not in optional_fields
|
|
73
|
+
or is_nullable_and_explicitly_set
|
|
74
|
+
):
|
|
75
|
+
m[k] = val
|
|
81
76
|
|
|
82
77
|
return m
|
|
@@ -48,30 +48,25 @@ class ThreeDSecureDataV2(BaseModel):
|
|
|
48
48
|
|
|
49
49
|
@model_serializer(mode="wrap")
|
|
50
50
|
def serialize_model(self, handler):
|
|
51
|
-
optional_fields = ["scheme", "authentication_response"]
|
|
52
|
-
nullable_fields = ["scheme", "authentication_response"]
|
|
53
|
-
null_default_fields = []
|
|
54
|
-
|
|
51
|
+
optional_fields = set(["scheme", "authentication_response"])
|
|
52
|
+
nullable_fields = set(["scheme", "authentication_response"])
|
|
55
53
|
serialized = handler(self)
|
|
56
|
-
|
|
57
54
|
m = {}
|
|
58
55
|
|
|
59
56
|
for n, f in type(self).model_fields.items():
|
|
60
57
|
k = f.alias or n
|
|
61
58
|
val = serialized.get(k)
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
):
|
|
75
|
-
m[k] = val
|
|
59
|
+
is_nullable_and_explicitly_set = (
|
|
60
|
+
k in nullable_fields
|
|
61
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
if val != UNSET_SENTINEL:
|
|
65
|
+
if (
|
|
66
|
+
val is not None
|
|
67
|
+
or k not in optional_fields
|
|
68
|
+
or is_nullable_and_explicitly_set
|
|
69
|
+
):
|
|
70
|
+
m[k] = val
|
|
76
71
|
|
|
77
72
|
return m
|
|
@@ -32,30 +32,25 @@ class ThreeDSecureError(BaseModel):
|
|
|
32
32
|
|
|
33
33
|
@model_serializer(mode="wrap")
|
|
34
34
|
def serialize_model(self, handler):
|
|
35
|
-
optional_fields = ["code", "description", "detail", "component"]
|
|
36
|
-
nullable_fields = ["code", "description", "detail", "component"]
|
|
37
|
-
null_default_fields = []
|
|
38
|
-
|
|
35
|
+
optional_fields = set(["code", "description", "detail", "component"])
|
|
36
|
+
nullable_fields = set(["code", "description", "detail", "component"])
|
|
39
37
|
serialized = handler(self)
|
|
40
|
-
|
|
41
38
|
m = {}
|
|
42
39
|
|
|
43
40
|
for n, f in type(self).model_fields.items():
|
|
44
41
|
k = f.alias or n
|
|
45
42
|
val = serialized.get(k)
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
):
|
|
59
|
-
m[k] = val
|
|
43
|
+
is_nullable_and_explicitly_set = (
|
|
44
|
+
k in nullable_fields
|
|
45
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
46
|
+
)
|
|
47
|
+
|
|
48
|
+
if val != UNSET_SENTINEL:
|
|
49
|
+
if (
|
|
50
|
+
val is not None
|
|
51
|
+
or k not in optional_fields
|
|
52
|
+
or is_nullable_and_explicitly_set
|
|
53
|
+
):
|
|
54
|
+
m[k] = val
|
|
60
55
|
|
|
61
56
|
return m
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .threedsecurescenarioconditions import (
|
|
5
|
+
ThreeDSecureScenarioConditions,
|
|
6
|
+
ThreeDSecureScenarioConditionsTypedDict,
|
|
7
|
+
)
|
|
8
|
+
from .threedsecurescenariooutcome import (
|
|
9
|
+
ThreeDSecureScenarioOutcome,
|
|
10
|
+
ThreeDSecureScenarioOutcomeTypedDict,
|
|
11
|
+
)
|
|
12
|
+
from datetime import datetime
|
|
13
|
+
from gr4vy.types import BaseModel, UNSET_SENTINEL
|
|
14
|
+
from gr4vy.utils import validate_const
|
|
15
|
+
import pydantic
|
|
16
|
+
from pydantic import model_serializer
|
|
17
|
+
from pydantic.functional_validators import AfterValidator
|
|
18
|
+
from typing import Literal, Optional
|
|
19
|
+
from typing_extensions import Annotated, TypedDict
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class ThreeDSecureScenarioTypedDict(TypedDict):
|
|
23
|
+
id: str
|
|
24
|
+
r"""Unique identifier for the 3DS scenario"""
|
|
25
|
+
merchant_account_id: str
|
|
26
|
+
r"""ID of the associated merchant account"""
|
|
27
|
+
created_at: datetime
|
|
28
|
+
r"""The date and time when this 3DS scenario was first created in our system."""
|
|
29
|
+
updated_at: datetime
|
|
30
|
+
r"""The date and time when this 3DS scenario was last updated in our system."""
|
|
31
|
+
conditions: ThreeDSecureScenarioConditionsTypedDict
|
|
32
|
+
outcome: ThreeDSecureScenarioOutcomeTypedDict
|
|
33
|
+
type: Literal["three-d-secure-scenario"]
|
|
34
|
+
r"""Always `three-d-secure-scenario`."""
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
class ThreeDSecureScenario(BaseModel):
|
|
38
|
+
id: str
|
|
39
|
+
r"""Unique identifier for the 3DS scenario"""
|
|
40
|
+
|
|
41
|
+
merchant_account_id: str
|
|
42
|
+
r"""ID of the associated merchant account"""
|
|
43
|
+
|
|
44
|
+
created_at: datetime
|
|
45
|
+
r"""The date and time when this 3DS scenario was first created in our system."""
|
|
46
|
+
|
|
47
|
+
updated_at: datetime
|
|
48
|
+
r"""The date and time when this 3DS scenario was last updated in our system."""
|
|
49
|
+
|
|
50
|
+
conditions: ThreeDSecureScenarioConditions
|
|
51
|
+
|
|
52
|
+
outcome: ThreeDSecureScenarioOutcome
|
|
53
|
+
|
|
54
|
+
TYPE: Annotated[
|
|
55
|
+
Annotated[
|
|
56
|
+
Optional[Literal["three-d-secure-scenario"]],
|
|
57
|
+
AfterValidator(validate_const("three-d-secure-scenario")),
|
|
58
|
+
],
|
|
59
|
+
pydantic.Field(alias="type"),
|
|
60
|
+
] = "three-d-secure-scenario"
|
|
61
|
+
r"""Always `three-d-secure-scenario`."""
|
|
62
|
+
|
|
63
|
+
@model_serializer(mode="wrap")
|
|
64
|
+
def serialize_model(self, handler):
|
|
65
|
+
optional_fields = set(["type"])
|
|
66
|
+
serialized = handler(self)
|
|
67
|
+
m = {}
|
|
68
|
+
|
|
69
|
+
for n, f in type(self).model_fields.items():
|
|
70
|
+
k = f.alias or n
|
|
71
|
+
val = serialized.get(k)
|
|
72
|
+
|
|
73
|
+
if val != UNSET_SENTINEL:
|
|
74
|
+
if val is not None or k not in optional_fields:
|
|
75
|
+
m[k] = val
|
|
76
|
+
|
|
77
|
+
return m
|