boarddata 4.1.3__tar.gz → 4.2.2__tar.gz

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.
Files changed (59) hide show
  1. {boarddata-4.1.3 → boarddata-4.2.2}/PKG-INFO +1 -1
  2. {boarddata-4.1.3 → boarddata-4.2.2}/__init__.py +1 -1
  3. {boarddata-4.1.3 → boarddata-4.2.2}/_companies.py +48 -1
  4. {boarddata-4.1.3 → boarddata-4.2.2}/boarddata.egg-info/PKG-INFO +1 -1
  5. {boarddata-4.1.3 → boarddata-4.2.2}/pyproject.toml +1 -1
  6. {boarddata-4.1.3 → boarddata-4.2.2}/types/companies.py +9 -0
  7. {boarddata-4.1.3 → boarddata-4.2.2}/CLAUDE.md +0 -0
  8. {boarddata-4.1.3 → boarddata-4.2.2}/README.md +0 -0
  9. {boarddata-4.1.3 → boarddata-4.2.2}/_assemblies.py +0 -0
  10. {boarddata-4.1.3 → boarddata-4.2.2}/_auditors.py +0 -0
  11. {boarddata-4.1.3 → boarddata-4.2.2}/_base.py +0 -0
  12. {boarddata-4.1.3 → boarddata-4.2.2}/_comex.py +0 -0
  13. {boarddata-4.1.3 → boarddata-4.2.2}/_criteria.py +0 -0
  14. {boarddata-4.1.3 → boarddata-4.2.2}/_directors.py +0 -0
  15. {boarddata-4.1.3 → boarddata-4.2.2}/_documents.py +0 -0
  16. {boarddata-4.1.3 → boarddata-4.2.2}/_esg.py +0 -0
  17. {boarddata-4.1.3 → boarddata-4.2.2}/_indexes.py +0 -0
  18. {boarddata-4.1.3 → boarddata-4.2.2}/_persons.py +0 -0
  19. {boarddata-4.1.3 → boarddata-4.2.2}/_sentinel.py +0 -0
  20. {boarddata-4.1.3 → boarddata-4.2.2}/_utilities.py +0 -0
  21. {boarddata-4.1.3 → boarddata-4.2.2}/boarddata.egg-info/SOURCES.txt +0 -0
  22. {boarddata-4.1.3 → boarddata-4.2.2}/boarddata.egg-info/dependency_links.txt +0 -0
  23. {boarddata-4.1.3 → boarddata-4.2.2}/boarddata.egg-info/requires.txt +0 -0
  24. {boarddata-4.1.3 → boarddata-4.2.2}/boarddata.egg-info/top_level.txt +0 -0
  25. {boarddata-4.1.3 → boarddata-4.2.2}/cache.py +0 -0
  26. {boarddata-4.1.3 → boarddata-4.2.2}/client.py +0 -0
  27. {boarddata-4.1.3 → boarddata-4.2.2}/errors.py +0 -0
  28. {boarddata-4.1.3 → boarddata-4.2.2}/py.typed +0 -0
  29. {boarddata-4.1.3 → boarddata-4.2.2}/setup.cfg +0 -0
  30. {boarddata-4.1.3 → boarddata-4.2.2}/tests/__init__.py +0 -0
  31. {boarddata-4.1.3 → boarddata-4.2.2}/tests/conftest.py +0 -0
  32. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_assemblies.py +0 -0
  33. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_auditors.py +0 -0
  34. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_base.py +0 -0
  35. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_build_payload.py +0 -0
  36. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_cache.py +0 -0
  37. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_comex.py +0 -0
  38. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_companies.py +0 -0
  39. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_config.py +0 -0
  40. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_criteria.py +0 -0
  41. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_directors.py +0 -0
  42. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_documents.py +0 -0
  43. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_esg.py +0 -0
  44. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_indexes.py +0 -0
  45. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_persons.py +0 -0
  46. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_sentinel.py +0 -0
  47. {boarddata-4.1.3 → boarddata-4.2.2}/tests/test_utilities.py +0 -0
  48. {boarddata-4.1.3 → boarddata-4.2.2}/types/__init__.py +0 -0
  49. {boarddata-4.1.3 → boarddata-4.2.2}/types/assemblies.py +0 -0
  50. {boarddata-4.1.3 → boarddata-4.2.2}/types/auditors.py +0 -0
  51. {boarddata-4.1.3 → boarddata-4.2.2}/types/comex.py +0 -0
  52. {boarddata-4.1.3 → boarddata-4.2.2}/types/core.py +0 -0
  53. {boarddata-4.1.3 → boarddata-4.2.2}/types/criteria.py +0 -0
  54. {boarddata-4.1.3 → boarddata-4.2.2}/types/directors.py +0 -0
  55. {boarddata-4.1.3 → boarddata-4.2.2}/types/documents.py +0 -0
  56. {boarddata-4.1.3 → boarddata-4.2.2}/types/esg.py +0 -0
  57. {boarddata-4.1.3 → boarddata-4.2.2}/types/indexes.py +0 -0
  58. {boarddata-4.1.3 → boarddata-4.2.2}/types/persons.py +0 -0
  59. {boarddata-4.1.3 → boarddata-4.2.2}/types/sentinel.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: boarddata
3
- Version: 4.1.3
3
+ Version: 4.2.2
4
4
  Summary: Python SDK for the BoardData V2 REST API
5
5
  License: MIT
6
6
  Classifier: Development Status :: 4 - Beta
@@ -7,7 +7,7 @@ from .errors import BoardDataError
7
7
 
8
8
  from . import types as types # noqa: F401 — makes types accessible as boarddata.types
9
9
 
10
- __version__ = "4.1.3"
10
+ __version__ = "4.2.2"
11
11
  __all__ = [
12
12
  "Base",
13
13
  "BoardDataClient",
@@ -5,7 +5,12 @@ from __future__ import annotations
5
5
  import logging
6
6
  from typing import Any
7
7
 
8
- from .types.companies import CompanyDetail, CompanyListItem, TemporalAttributePayload
8
+ from .types.companies import (
9
+ CompanyDetail,
10
+ CompanyListItem,
11
+ CompanyResolveResult,
12
+ TemporalAttributePayload,
13
+ )
9
14
  from .types.core import AddressPayload, FieldSourcePayload, PaginatedResponse, UpsertResult
10
15
 
11
16
  logger = logging.getLogger("boarddata")
@@ -253,6 +258,48 @@ class CompanyMixin:
253
258
  results = resp.get("results", []) if isinstance(resp, dict) else resp
254
259
  return results[0] if results else None
255
260
 
261
+ def resolve_company(
262
+ self,
263
+ *,
264
+ ticker: str | None = None,
265
+ isin: str | None = None,
266
+ exchange: str | None = None,
267
+ ) -> CompanyResolveResult | None:
268
+ """Resolve a company by ticker and/or ISIN.
269
+
270
+ Cascading resolution: DB → OpenFIGI → Perplexity.
271
+ At least one of ticker or isin is required.
272
+
273
+ Args:
274
+ ticker: Stock ticker symbol (e.g. ``"TTE"``).
275
+ isin: ISIN identifier (e.g. ``"FR0000120271"``).
276
+ exchange: Optional OpenFIGI exchange code (e.g. ``"FP"`` for
277
+ Euronext Paris) to disambiguate short tickers.
278
+
279
+ Returns:
280
+ CompanyResolveResult if found, or ``None`` if not found.
281
+
282
+ Raises:
283
+ BoardDataError: On non-2xx API response (except 404).
284
+ ValueError: If neither ticker nor isin is provided.
285
+ """
286
+ if not ticker and not isin:
287
+ raise ValueError("Provide at least one of: ticker, isin")
288
+
289
+ from .errors import BoardDataError
290
+
291
+ try:
292
+ return self._get( # type: ignore[attr-defined]
293
+ "companies/resolve/",
294
+ ticker=ticker,
295
+ isin=isin,
296
+ exchange=exchange,
297
+ )
298
+ except BoardDataError as exc:
299
+ if exc.status_code == 404:
300
+ return None
301
+ raise
302
+
256
303
  def upsert_company(
257
304
  self,
258
305
  isin: str,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: boarddata
3
- Version: 4.1.3
3
+ Version: 4.2.2
4
4
  Summary: Python SDK for the BoardData V2 REST API
5
5
  License: MIT
6
6
  Classifier: Development Status :: 4 - Beta
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "boarddata"
7
- version = "4.1.3"
7
+ version = "4.2.2"
8
8
  description = "Python SDK for the BoardData V2 REST API"
9
9
  readme = "README.md"
10
10
  license = {text = "MIT"}
@@ -68,6 +68,15 @@ class UpdateCompanyPayload(TypedDict, total=False):
68
68
  field_sources: list[FieldSourcePayload]
69
69
 
70
70
 
71
+ class CompanyResolveResult(TypedDict):
72
+ id: str
73
+ name: str
74
+ isin: str
75
+ ticker: str
76
+ country: str
77
+ logo: str
78
+
79
+
71
80
  class CompanyListItem(TypedDict):
72
81
  id: str
73
82
  name: str
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes