reportify-sdk 0.3.1__tar.gz → 0.3.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 (24) hide show
  1. {reportify_sdk-0.3.1/reportify_sdk.egg-info → reportify_sdk-0.3.2}/PKG-INFO +1 -1
  2. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/pyproject.toml +1 -1
  3. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/__init__.py +1 -1
  4. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/client.py +1 -1
  5. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/quant.py +0 -57
  6. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2/reportify_sdk.egg-info}/PKG-INFO +1 -1
  7. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/LICENSE +0 -0
  8. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/README.md +0 -0
  9. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/agent.py +0 -0
  10. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/channels.py +0 -0
  11. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/chat.py +0 -0
  12. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/concepts.py +0 -0
  13. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/docs.py +0 -0
  14. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/exceptions.py +0 -0
  15. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/kb.py +0 -0
  16. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/search.py +0 -0
  17. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/stock.py +0 -0
  18. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/timeline.py +0 -0
  19. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk/user.py +0 -0
  20. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk.egg-info/SOURCES.txt +0 -0
  21. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk.egg-info/dependency_links.txt +0 -0
  22. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk.egg-info/requires.txt +0 -0
  23. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/reportify_sdk.egg-info/top_level.txt +0 -0
  24. {reportify_sdk-0.3.1 → reportify_sdk-0.3.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: reportify-sdk
3
- Version: 0.3.1
3
+ Version: 0.3.2
4
4
  Summary: Python SDK for Reportify API - Financial data and document search
5
5
  Author-email: Reportify <support@reportify.cn>
6
6
  License-Expression: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "reportify-sdk"
7
- version = "0.3.1"
7
+ version = "0.3.2"
8
8
  description = "Python SDK for Reportify API - Financial data and document search"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -20,7 +20,7 @@ from reportify_sdk.exceptions import (
20
20
  APIError,
21
21
  )
22
22
 
23
- __version__ = "0.3.1"
23
+ __version__ = "0.3.2"
24
24
  __all__ = [
25
25
  "Reportify",
26
26
  "ReportifyError",
@@ -74,7 +74,7 @@ class Reportify:
74
74
  return {
75
75
  "Authorization": f"Bearer {self.api_key}",
76
76
  "Content-Type": "application/json",
77
- "User-Agent": "reportify-sdk-python/0.3.1",
77
+ "User-Agent": "reportify-sdk-python/0.3.2",
78
78
  }
79
79
 
80
80
  def _request(
@@ -315,63 +315,6 @@ class QuantModule:
315
315
  response = self._client._post("/v1/quant/quotes/ohlcv/batch", json=data)
316
316
  return self._to_dataframe(response.get("datas", []))
317
317
 
318
- # -------------------------------------------------------------------------
319
- # Financials
320
- # -------------------------------------------------------------------------
321
-
322
- def financials(
323
- self,
324
- financial_type: Literal["income", "cashflow", "balancesheet", "equity"],
325
- symbol: str,
326
- *,
327
- market: StockMarket = "cn",
328
- start_year: int | None = None,
329
- end_year: int | None = None,
330
- ) -> pd.DataFrame:
331
- """
332
- Get historical financial statement data for a single symbol
333
-
334
- Args:
335
- financial_type: Type of financial statement
336
- - "income": Income statement (利润表)
337
- - "cashflow": Cash flow statement (现金流量表)
338
- - "balancesheet": Balance sheet (资产负债表)
339
- - "equity": Equity statement (股东权益变动表)
340
- symbol: Stock code
341
- market: Stock market ("cn", "hk", "us"), default "cn"
342
- start_year: Start year (default: 3 years ago)
343
- end_year: End year (default: current year)
344
-
345
- Returns:
346
- DataFrame with financial data sorted by report period
347
-
348
- Example:
349
- >>> # Get income statement
350
- >>> df = client.quant.financials("income", "000001")
351
- >>> print(df[["report_period", "revenue", "net_profit"]])
352
-
353
- >>> # Get balance sheet for specific years
354
- >>> df = client.quant.financials(
355
- ... "balancesheet", "600519",
356
- ... start_year=2020,
357
- ... end_year=2024
358
- ... )
359
-
360
- >>> # Get cash flow statement for HK stock
361
- >>> df = client.quant.financials("cashflow", "00700", market="hk")
362
- """
363
- params: dict[str, Any] = {
364
- "symbol": symbol,
365
- "market": market,
366
- }
367
- if start_year:
368
- params["start_year"] = start_year
369
- if end_year:
370
- params["end_year"] = end_year
371
-
372
- response = self._client._get(f"/v1/quant/financials/{financial_type}", params=params)
373
- return self._to_dataframe(response.get("datas", []))
374
-
375
318
  # -------------------------------------------------------------------------
376
319
  # Backtest
377
320
  # -------------------------------------------------------------------------
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: reportify-sdk
3
- Version: 0.3.1
3
+ Version: 0.3.2
4
4
  Summary: Python SDK for Reportify API - Financial data and document search
5
5
  Author-email: Reportify <support@reportify.cn>
6
6
  License-Expression: MIT
File without changes
File without changes
File without changes