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
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.4.0"
".": "1.5.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: 7
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-2df861cbe235900388f93a2e603090b713f6c5029e4daf2220bddface7882032.yml
openapi_spec_hash: d5a5643aea6c45631d7df49692cf9328
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-a960d67a89f2e62fcb3fb61f13e0cba71a803ff00b378730cf72a8209ae8e36a.yml
openapi_spec_hash: a2c7aa9e4b1e5265d502d3f005ffb5f9
config_hash: bb3f3ba0dca413263e40968648f9a1a6
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 1.5.0 (2025-06-08)

Full Changelog: [v1.4.0...v1.5.0](https://github.com/brand-dot-dev/python-sdk/compare/v1.4.0...v1.5.0)

### Features

* **api:** manual updates ([8f3190c](https://github.com/brand-dot-dev/python-sdk/commit/8f3190c847269b9537c2000feadff81762171295))

## 1.4.0 (2025-06-06)

Full Changelog: [v1.3.0...v1.4.0](https://github.com/brand-dot-dev/python-sdk/compare/v1.3.0...v1.4.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 = "brand.dev"
version = "1.4.0"
version = "1.5.0"
description = "The official Python library for the brand.dev API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/brand/dev/_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__ = "brand.dev"
__version__ = "1.4.0" # x-release-please-version
__version__ = "1.5.0" # x-release-please-version
144 changes: 134 additions & 10 deletions src/brand/dev/resources/brand.py

Large diffs are not rendered by default.

11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_ai_query_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
from __future__ import annotations

from typing import Iterable
from typing_extensions import Literal, Required, TypedDict
from typing_extensions import Literal, Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandAIQueryParams", "DataToExtract", "SpecificPages"]

Expand All @@ -18,6 +20,13 @@ class BrandAIQueryParams(TypedDict, total=False):
specific_pages: SpecificPages
"""Optional object specifying which pages to analyze"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""


class DataToExtract(TypedDict, total=False):
datapoint_description: Required[str]
Expand Down
11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_identify_from_transaction_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@

from __future__ import annotations

from typing_extensions import Required, TypedDict
from typing_extensions import Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandIdentifyFromTransactionParams"]


class BrandIdentifyFromTransactionParams(TypedDict, total=False):
transaction_info: Required[str]
"""Transaction information to identify the brand"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_prefetch_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@

from __future__ import annotations

from typing_extensions import Required, TypedDict
from typing_extensions import Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandPrefetchParams"]


class BrandPrefetchParams(TypedDict, total=False):
domain: Required[str]
"""Domain name to prefetch brand data for"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_retrieve_by_ticker_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@

from __future__ import annotations

from typing_extensions import Required, TypedDict
from typing_extensions import Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandRetrieveByTickerParams"]


class BrandRetrieveByTickerParams(TypedDict, total=False):
ticker: Required[str]
"""Stock ticker symbol to retrieve brand data for (e.g. AAPL, TSLA, etc.)"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_retrieve_naics_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

from __future__ import annotations

from typing_extensions import Required, TypedDict
from typing_extensions import Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandRetrieveNaicsParams"]

Expand All @@ -14,3 +16,10 @@ class BrandRetrieveNaicsParams(TypedDict, total=False):
If a valid domain is provided in `input`, it will be used for classification,
otherwise, we will search for the brand using the provided title.
"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
7 changes: 7 additions & 0 deletions src/brand/dev/types/brand_retrieve_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,10 @@ class BrandRetrieveParams(TypedDict, total=False):
When set to true, the API will skip time-consuming operations for faster
response at the cost of less comprehensive data.
"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
11 changes: 10 additions & 1 deletion src/brand/dev/types/brand_search_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@

from __future__ import annotations

from typing_extensions import Required, TypedDict
from typing_extensions import Required, Annotated, TypedDict

from .._utils import PropertyInfo

__all__ = ["BrandSearchParams"]


class BrandSearchParams(TypedDict, total=False):
query: Required[str]
"""Query string to search brands"""

timeout_ms: Annotated[int, PropertyInfo(alias="timeoutMS")]
"""Optional timeout in milliseconds for the request.

If the request takes longer than this value, it will be aborted with a 408
status code. Maximum allowed value is 300000ms (5 minutes).
"""
94 changes: 94 additions & 0 deletions tests/api_resources/test_brand.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ def test_method_retrieve_with_all_params(self, client: BrandDev) -> None:
domain="domain",
force_language="albanian",
max_speed=True,
timeout_ms=1,
)
assert_matches_type(BrandRetrieveResponse, brand, path=["response"])

Expand Down Expand Up @@ -108,6 +109,7 @@ def test_method_ai_query_with_all_params(self, client: BrandDev) -> None:
"privacy_policy": True,
"terms_and_conditions": True,
},
timeout_ms=1,
)
assert_matches_type(BrandAIQueryResponse, brand, path=["response"])

Expand Down Expand Up @@ -161,6 +163,15 @@ def test_method_identify_from_transaction(self, client: BrandDev) -> None:
)
assert_matches_type(BrandIdentifyFromTransactionResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_method_identify_from_transaction_with_all_params(self, client: BrandDev) -> None:
brand = client.brand.identify_from_transaction(
transaction_info="transaction_info",
timeout_ms=1,
)
assert_matches_type(BrandIdentifyFromTransactionResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_raw_response_identify_from_transaction(self, client: BrandDev) -> None:
Expand Down Expand Up @@ -195,6 +206,15 @@ def test_method_prefetch(self, client: BrandDev) -> None:
)
assert_matches_type(BrandPrefetchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_method_prefetch_with_all_params(self, client: BrandDev) -> None:
brand = client.brand.prefetch(
domain="domain",
timeout_ms=1,
)
assert_matches_type(BrandPrefetchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_raw_response_prefetch(self, client: BrandDev) -> None:
Expand Down Expand Up @@ -229,6 +249,15 @@ def test_method_retrieve_by_ticker(self, client: BrandDev) -> None:
)
assert_matches_type(BrandRetrieveByTickerResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_method_retrieve_by_ticker_with_all_params(self, client: BrandDev) -> None:
brand = client.brand.retrieve_by_ticker(
ticker="ticker",
timeout_ms=1,
)
assert_matches_type(BrandRetrieveByTickerResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_raw_response_retrieve_by_ticker(self, client: BrandDev) -> None:
Expand Down Expand Up @@ -263,6 +292,15 @@ def test_method_retrieve_naics(self, client: BrandDev) -> None:
)
assert_matches_type(BrandRetrieveNaicsResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_method_retrieve_naics_with_all_params(self, client: BrandDev) -> None:
brand = client.brand.retrieve_naics(
input="input",
timeout_ms=1,
)
assert_matches_type(BrandRetrieveNaicsResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_raw_response_retrieve_naics(self, client: BrandDev) -> None:
Expand Down Expand Up @@ -297,6 +335,15 @@ def test_method_search(self, client: BrandDev) -> None:
)
assert_matches_type(BrandSearchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_method_search_with_all_params(self, client: BrandDev) -> None:
brand = client.brand.search(
query="query",
timeout_ms=1,
)
assert_matches_type(BrandSearchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
def test_raw_response_search(self, client: BrandDev) -> None:
Expand Down Expand Up @@ -342,6 +389,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncBrandDev
domain="domain",
force_language="albanian",
max_speed=True,
timeout_ms=1,
)
assert_matches_type(BrandRetrieveResponse, brand, path=["response"])

Expand Down Expand Up @@ -410,6 +458,7 @@ async def test_method_ai_query_with_all_params(self, async_client: AsyncBrandDev
"privacy_policy": True,
"terms_and_conditions": True,
},
timeout_ms=1,
)
assert_matches_type(BrandAIQueryResponse, brand, path=["response"])

Expand Down Expand Up @@ -463,6 +512,15 @@ async def test_method_identify_from_transaction(self, async_client: AsyncBrandDe
)
assert_matches_type(BrandIdentifyFromTransactionResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_method_identify_from_transaction_with_all_params(self, async_client: AsyncBrandDev) -> None:
brand = await async_client.brand.identify_from_transaction(
transaction_info="transaction_info",
timeout_ms=1,
)
assert_matches_type(BrandIdentifyFromTransactionResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_raw_response_identify_from_transaction(self, async_client: AsyncBrandDev) -> None:
Expand Down Expand Up @@ -497,6 +555,15 @@ async def test_method_prefetch(self, async_client: AsyncBrandDev) -> None:
)
assert_matches_type(BrandPrefetchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_method_prefetch_with_all_params(self, async_client: AsyncBrandDev) -> None:
brand = await async_client.brand.prefetch(
domain="domain",
timeout_ms=1,
)
assert_matches_type(BrandPrefetchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_raw_response_prefetch(self, async_client: AsyncBrandDev) -> None:
Expand Down Expand Up @@ -531,6 +598,15 @@ async def test_method_retrieve_by_ticker(self, async_client: AsyncBrandDev) -> N
)
assert_matches_type(BrandRetrieveByTickerResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_method_retrieve_by_ticker_with_all_params(self, async_client: AsyncBrandDev) -> None:
brand = await async_client.brand.retrieve_by_ticker(
ticker="ticker",
timeout_ms=1,
)
assert_matches_type(BrandRetrieveByTickerResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_raw_response_retrieve_by_ticker(self, async_client: AsyncBrandDev) -> None:
Expand Down Expand Up @@ -565,6 +641,15 @@ async def test_method_retrieve_naics(self, async_client: AsyncBrandDev) -> None:
)
assert_matches_type(BrandRetrieveNaicsResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_method_retrieve_naics_with_all_params(self, async_client: AsyncBrandDev) -> None:
brand = await async_client.brand.retrieve_naics(
input="input",
timeout_ms=1,
)
assert_matches_type(BrandRetrieveNaicsResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_raw_response_retrieve_naics(self, async_client: AsyncBrandDev) -> None:
Expand Down Expand Up @@ -599,6 +684,15 @@ async def test_method_search(self, async_client: AsyncBrandDev) -> None:
)
assert_matches_type(BrandSearchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_method_search_with_all_params(self, async_client: AsyncBrandDev) -> None:
brand = await async_client.brand.search(
query="query",
timeout_ms=1,
)
assert_matches_type(BrandSearchResponse, brand, path=["response"])

@pytest.mark.skip()
@parametrize
async def test_raw_response_search(self, async_client: AsyncBrandDev) -> None:
Expand Down