diff --git a/src/bitpay/models/invoice/invoice.py b/src/bitpay/models/invoice/invoice.py index 7719657..2ff8554 100644 --- a/src/bitpay/models/invoice/invoice.py +++ b/src/bitpay/models/invoice/invoice.py @@ -6,7 +6,7 @@ from pydantic import Field from .buyer import Buyer from .buyer_provided_info import BuyerProvidedInfo -from .invoice_refund_addresses import InvoiceRefundAddresses +from .invoice_refund_addresses import InvoiceRefundAddress from .miner_fees import MinerFees from .refund_info import RefundInfo from .shopper import Shopper @@ -48,7 +48,7 @@ class Invoice(BitPayModel): payment_codes: Union[Dict[str, Dict[str, str]], None] = None acceptance_window: Union[int, None] = None buyer: Union[Buyer, None] = None - refund_addresses: Union[List[Dict[str, InvoiceRefundAddresses]], None] = None + refund_addresses: Union[List[Dict[str, InvoiceRefundAddress]], None] = None close_url: Union[str, None] = Field(alias="closeURL", default=None) auto_redirect: Union[bool, None] = False json_paypro_required: Union[bool, None] = False diff --git a/src/bitpay/models/invoice/invoice_refund_addresses.py b/src/bitpay/models/invoice/invoice_refund_addresses.py index 8820722..122838d 100644 --- a/src/bitpay/models/invoice/invoice_refund_addresses.py +++ b/src/bitpay/models/invoice/invoice_refund_addresses.py @@ -5,9 +5,9 @@ from bitpay.models.bitpay_model import BitPayModel -class InvoiceRefundAddresses(BitPayModel): - date: Union[datetime, None] - email: Union[str, None] +class InvoiceRefundAddress(BitPayModel): + date: Union[datetime, None] = None + email: Union[str, None] = None tag: Union[int, None] = None type: Union[str, None] = None