Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lago_python_client/models/credit_note.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class CreditNoteResponse(BaseResponseModel):
number: Optional[str]
lago_invoice_id: Optional[str]
invoice_number: Optional[str]
purchase_order_number: Optional[str]
credit_status: Optional[str]
refund_status: Optional[str]
reason: Optional[str]
Expand Down
2 changes: 2 additions & 0 deletions lago_python_client/models/invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ class OneOffInvoice(BaseModel):
payment_method: Optional[PaymentMethod]
invoice_custom_section: Optional[InvoiceCustomSectionInput]
billing_entity_code: Optional[str]
purchase_order_number: Optional[str]


class InvoicePreview(BaseModel):
Expand Down Expand Up @@ -115,6 +116,7 @@ class InvoiceResponse(BaseResponseModel):
lago_id: str
sequential_id: Optional[int]
number: str
purchase_order_number: Optional[str]
issuing_date: Optional[str]
payment_dispute_lost_at: Optional[str]
payment_due_date: Optional[str]
Expand Down
1 change: 1 addition & 0 deletions tests/fixtures/invoice.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"billing_entity_code": "test-company",
"sequential_id": 15,
"number": "LAG-1234-001-002",
"purchase_order_number": "PO-123",
"issuing_date": "2022-06-02",
"payment_due_date": "2022-06-02",
"payment_overdue": false,
Expand Down
1 change: 1 addition & 0 deletions tests/test_invoice_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ def test_valid_find_invoice_request(httpx_mock: HTTPXMock):
response = client.invoices.find(identifier)

assert response.lago_id == identifier
assert response.purchase_order_number == "PO-123"


def test_invalid_find_invoice_request(httpx_mock: HTTPXMock):
Expand Down
Loading