Skip to content
Open
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
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
timeout-minutes: 10
name: lint
runs-on: ${{ github.repository == 'stainless-sdks/conductor-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')
steps:
- uses: actions/checkout@v6

Expand All @@ -38,7 +38,7 @@ jobs:
run: ./scripts/lint

build:
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')
timeout-minutes: 10
name: build
permissions:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.prism.log
.stdy.log
_dev

__pycache__
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "1.75.0"
".": "1.76.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 220
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/conductor%2Fconductor-09df225c4fd3265d31ac1bc16ac2774cac8691a201954cfb010e50f06b5ab486.yml
openapi_spec_hash: 75ec4898861584506d099bec5c6f0d2a
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/conductor%2Fconductor-2e591208a875b09a6f16e02de08c8b3943ff52f87ec6decec9d89c8fea7f936d.yml
openapi_spec_hash: d082d7df064bbe33df8111ad92d0e067
config_hash: 89303a38c78d93021ba8a584462375bd
28 changes: 28 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,33 @@
# Changelog

## 1.76.0 (2026-04-11)

Full Changelog: [v1.75.0...v1.76.0](https://github.com/conductor-is/quickbooks-desktop-python/compare/v1.75.0...v1.76.0)

### Features

* **api:** api update ([f036b60](https://github.com/conductor-is/quickbooks-desktop-python/commit/f036b60dcedb8720bdc8c1975679cdd49d77261f))
* **api:** api update ([d10df35](https://github.com/conductor-is/quickbooks-desktop-python/commit/d10df3592b34e7edfbfcd1c31059645caca40e45))
* **internal:** implement indices array format for query and form serialization ([f264eeb](https://github.com/conductor-is/quickbooks-desktop-python/commit/f264eeb5bfc0eda46c966a8c29414aa160ce89b5))


### Bug Fixes

* **client:** preserve hardcoded query params when merging with user params ([a1dc57a](https://github.com/conductor-is/quickbooks-desktop-python/commit/a1dc57a7a2e84b790fe8c780cdf69b170dbf0ea4))
* ensure file data are only sent as 1 parameter ([6012229](https://github.com/conductor-is/quickbooks-desktop-python/commit/60122296e0417366b4b4bb735ff3c4918298edd2))


### Chores

* **ci:** skip lint on metadata-only changes ([c022258](https://github.com/conductor-is/quickbooks-desktop-python/commit/c022258ae83dc218cb347b2f4fa1bbe9f9c01392))
* **internal:** update gitignore ([a8b9d7f](https://github.com/conductor-is/quickbooks-desktop-python/commit/a8b9d7f1540ab7080991c8317e712b0a09aa0d3c))
* **tests:** bump steady to v0.19.4 ([d30740a](https://github.com/conductor-is/quickbooks-desktop-python/commit/d30740afab1f30f04aa9faa259ff13191c06cc78))
* **tests:** bump steady to v0.19.5 ([5f296c8](https://github.com/conductor-is/quickbooks-desktop-python/commit/5f296c83432a13bd412845f4d31a7f086a174e95))
* **tests:** bump steady to v0.19.6 ([5b0209c](https://github.com/conductor-is/quickbooks-desktop-python/commit/5b0209cbd977349465e594c67d9f331e3466786b))
* **tests:** bump steady to v0.19.7 ([7b21104](https://github.com/conductor-is/quickbooks-desktop-python/commit/7b21104b7a2c1037b48813de3641775af0ea1ba8))
* **tests:** bump steady to v0.20.1 ([0ae145c](https://github.com/conductor-is/quickbooks-desktop-python/commit/0ae145cfefe1fe2a250731711912854a76364b89))
* **tests:** bump steady to v0.20.2 ([fe9fe54](https://github.com/conductor-is/quickbooks-desktop-python/commit/fe9fe54e34704891c9463c00fbad35f50693d390))

## 1.75.0 (2026-03-20)

Full Changelog: [v1.74.0...v1.75.0](https://github.com/conductor-is/quickbooks-desktop-python/compare/v1.74.0...v1.75.0)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "conductor-py"
version = "1.75.0"
version = "1.76.0"
description = "The official Python library for the conductor API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
6 changes: 3 additions & 3 deletions scripts/mock
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ echo "==> Starting mock server with URL ${URL}"
# Run steady mock on the given spec
if [ "$1" == "--daemon" ]; then
# Pre-install the package so the download doesn't eat into the startup timeout
npm exec --package=@stdy/cli@0.19.3 -- steady --version
npm exec --package=@stdy/cli@0.20.2 -- steady --version

npm exec --package=@stdy/cli@0.19.3 -- steady --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-query-object-format=dots "$URL" &> .stdy.log &
npm exec --package=@stdy/cli@0.20.2 -- steady --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-form-array-format=repeat --validator-query-object-format=dots --validator-form-object-format=dots "$URL" &> .stdy.log &

# Wait for server to come online via health endpoint (max 30s)
echo -n "Waiting for server"
Expand All @@ -48,5 +48,5 @@ if [ "$1" == "--daemon" ]; then

echo
else
npm exec --package=@stdy/cli@0.19.3 -- steady --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-query-object-format=dots "$URL"
npm exec --package=@stdy/cli@0.20.2 -- steady --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-form-array-format=repeat --validator-query-object-format=dots --validator-form-object-format=dots "$URL"
fi
2 changes: 1 addition & 1 deletion scripts/test
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ elif ! steady_is_running ; then
echo -e "To run the server, pass in the path or url of your OpenAPI"
echo -e "spec to the steady command:"
echo
echo -e " \$ ${YELLOW}npm exec --package=@stdy/cli@0.19.3 -- steady path/to/your.openapi.yml --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-query-object-format=dots${NC}"
echo -e " \$ ${YELLOW}npm exec --package=@stdy/cli@0.20.2 -- steady path/to/your.openapi.yml --host 127.0.0.1 -p 4010 --validator-query-array-format=repeat --validator-form-array-format=repeat --validator-query-object-format=dots --validator-form-object-format=dots${NC}"
echo

exit 1
Expand Down
4 changes: 4 additions & 0 deletions src/conductor/_base_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,6 +540,10 @@ def _build_request(
files = cast(HttpxRequestFiles, ForceMultipartDict())

prepared_url = self._prepare_url(options.url)
# preserve hard-coded query params from the url
if params and prepared_url.query:
params = {**dict(prepared_url.params.items()), **params}
prepared_url = prepared_url.copy_with(raw_path=prepared_url.raw_path.split(b"?", 1)[0])
if "_" in prepared_url.host:
# work around https://github.com/encode/httpx/discussions/2880
kwargs["extensions"] = {"sni_hostname": prepared_url.host.replace("_", "-")}
Expand Down
5 changes: 4 additions & 1 deletion src/conductor/_qs.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,10 @@ def _stringify_item(
items.extend(self._stringify_item(key, item, opts))
return items
elif array_format == "indices":
raise NotImplementedError("The array indices format is not supported yet")
items = []
for i, item in enumerate(value):
items.extend(self._stringify_item(f"{key}[{i}]", item, opts))
return items
elif array_format == "brackets":
items = []
key = key + "[]"
Expand Down
5 changes: 3 additions & 2 deletions src/conductor/_utils/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,9 @@ def _extract_items(
index += 1
if is_dict(obj):
try:
# We are at the last entry in the path so we must remove the field
if (len(path)) == index:
# Remove the field if there are no more dict keys in the path,
# only "<array>" traversal markers or end.
if all(p == "<array>" for p in path[index:]):
item = obj.pop(key)
else:
item = obj[key]
Expand Down
2 changes: 1 addition & 1 deletion src/conductor/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "conductor"
__version__ = "1.75.0" # x-release-please-version
__version__ = "1.76.0" # x-release-please-version
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/credit_memo.py
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,13 @@ class LineGroup(BaseModel):
group.
"""

service_date: Optional[date] = FieldInfo(alias="serviceDate", default=None)
"""
The date on which the service for this credit memo line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

should_print_items_in_group: bool = FieldInfo(alias="shouldPrintItemsInGroup")
"""
Indicates whether the individual items in this credit memo line group and their
Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/credit_memo_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,13 @@ class LineGroup(TypedDict, total=False):
group.
"""

service_date: Annotated[Union[str, date], PropertyInfo(alias="serviceDate", format="iso8601")]
"""
The date on which the service for this credit memo line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

unit_of_measure: Annotated[str, PropertyInfo(alias="unitOfMeasure")]
"""The unit-of-measure used for the `quantity` in this credit memo line group.

Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,13 @@ class LineGroup(BaseModel):
group.
"""

service_date: Optional[date] = FieldInfo(alias="serviceDate", default=None)
"""
The date on which the service for this invoice line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

should_print_items_in_group: bool = FieldInfo(alias="shouldPrintItemsInGroup")
"""
Indicates whether the individual items in this invoice line group and their
Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/invoice_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,13 @@ class LineGroup(TypedDict, total=False):
group.
"""

service_date: Annotated[Union[str, date], PropertyInfo(alias="serviceDate", format="iso8601")]
"""
The date on which the service for this invoice line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

unit_of_measure: Annotated[str, PropertyInfo(alias="unitOfMeasure")]
"""The unit-of-measure used for the `quantity` in this invoice line group.

Expand Down
2 changes: 1 addition & 1 deletion src/conductor/types/qbd/non_inventory_item.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ class SalesAndPurchaseDetails(BaseModel):
expense_account: Optional[SalesAndPurchaseDetailsExpenseAccount] = FieldInfo(alias="expenseAccount", default=None)
"""The expense account used to track costs from purchases of this item."""

income_account: SalesAndPurchaseDetailsIncomeAccount = FieldInfo(alias="incomeAccount")
income_account: Optional[SalesAndPurchaseDetailsIncomeAccount] = FieldInfo(alias="incomeAccount", default=None)
"""The income account used to track revenue from sales of this item."""

preferred_vendor: Optional[SalesAndPurchaseDetailsPreferredVendor] = FieldInfo(
Expand Down
2 changes: 1 addition & 1 deletion src/conductor/types/qbd/other_charge_item.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ class SalesAndPurchaseDetails(BaseModel):
expense_account: Optional[SalesAndPurchaseDetailsExpenseAccount] = FieldInfo(alias="expenseAccount", default=None)
"""The expense account used to track costs from purchases of this item."""

income_account: SalesAndPurchaseDetailsIncomeAccount = FieldInfo(alias="incomeAccount")
income_account: Optional[SalesAndPurchaseDetailsIncomeAccount] = FieldInfo(alias="incomeAccount", default=None)
"""The income account used to track revenue from sales of this item."""

preferred_vendor: Optional[SalesAndPurchaseDetailsPreferredVendor] = FieldInfo(
Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/purchase_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -619,6 +619,13 @@ class LineGroup(BaseModel):
group.
"""

service_date: Optional[date] = FieldInfo(alias="serviceDate", default=None)
"""
The date on which the service for this purchase order line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

should_print_items_in_group: bool = FieldInfo(alias="shouldPrintItemsInGroup")
"""
Indicates whether the individual items in this purchase order line group and
Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/purchase_order_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,13 @@ class LineGroup(TypedDict, total=False):
group.
"""

service_date: Annotated[Union[str, date], PropertyInfo(alias="serviceDate", format="iso8601")]
"""
The date on which the service for this purchase order line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

unit_of_measure: Annotated[str, PropertyInfo(alias="unitOfMeasure")]
"""The unit-of-measure used for the `quantity` in this purchase order line group.

Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/sales_receipt.py
Original file line number Diff line number Diff line change
Expand Up @@ -1030,6 +1030,13 @@ class LineGroup(BaseModel):
group.
"""

service_date: Optional[date] = FieldInfo(alias="serviceDate", default=None)
"""
The date on which the service for this sales receipt line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

should_print_items_in_group: bool = FieldInfo(alias="shouldPrintItemsInGroup")
"""
Indicates whether the individual items in this sales receipt line group and
Expand Down
7 changes: 7 additions & 0 deletions src/conductor/types/qbd/sales_receipt_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,13 @@ class LineGroup(TypedDict, total=False):
group.
"""

service_date: Annotated[Union[str, date], PropertyInfo(alias="serviceDate", format="iso8601")]
"""
The date on which the service for this sales receipt line group was or will be
performed, in ISO 8601 format (YYYY-MM-DD). This is particularly relevant for
service items.
"""

unit_of_measure: Annotated[str, PropertyInfo(alias="unitOfMeasure")]
"""The unit-of-measure used for the `quantity` in this sales receipt line group.

Expand Down
2 changes: 1 addition & 1 deletion src/conductor/types/qbd/service_item.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ class SalesAndPurchaseDetails(BaseModel):
expense_account: Optional[SalesAndPurchaseDetailsExpenseAccount] = FieldInfo(alias="expenseAccount", default=None)
"""The expense account used to track costs from purchases of this item."""

income_account: SalesAndPurchaseDetailsIncomeAccount = FieldInfo(alias="incomeAccount")
income_account: Optional[SalesAndPurchaseDetailsIncomeAccount] = FieldInfo(alias="incomeAccount", default=None)
"""The income account used to track revenue from sales of this item."""

preferred_vendor: Optional[SalesAndPurchaseDetailsPreferredVendor] = FieldInfo(
Expand Down
2 changes: 2 additions & 0 deletions tests/api_resources/qbd/test_credit_memos.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ def test_method_create_with_all_params(self, client: Conductor) -> None:
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down Expand Up @@ -511,6 +512,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncConductor)
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down
2 changes: 2 additions & 0 deletions tests/api_resources/qbd/test_invoices.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ def test_method_create_with_all_params(self, client: Conductor) -> None:
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down Expand Up @@ -543,6 +544,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncConductor)
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down
2 changes: 2 additions & 0 deletions tests/api_resources/qbd/test_purchase_orders.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ def test_method_create_with_all_params(self, client: Conductor) -> None:
],
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down Expand Up @@ -482,6 +483,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncConductor)
],
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down
2 changes: 2 additions & 0 deletions tests/api_resources/qbd/test_sales_receipts.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ def test_method_create_with_all_params(self, client: Conductor) -> None:
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down Expand Up @@ -598,6 +599,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncConductor)
"inventory_site_id": "80000001-1234567890",
"inventory_site_location_id": "80000001-1234567890",
"quantity": 5,
"service_date": parse_date("2024-03-15"),
"unit_of_measure": "Each",
}
],
Expand Down
Loading