reportify-sdk 0.1.0__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.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Reportify
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,166 @@
1
+ Metadata-Version: 2.4
2
+ Name: reportify-sdk
3
+ Version: 0.1.0
4
+ Summary: Python SDK for Reportify API - Financial data and document search
5
+ Author-email: Reportify <support@reportify.cn>
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://reportify.cn
8
+ Project-URL: Documentation, https://docs.reportify.cn
9
+ Project-URL: Repository, https://github.com/reportify/reportify-sdk-python
10
+ Keywords: reportify,finance,stock,api,sdk
11
+ Classifier: Development Status :: 4 - Beta
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.9
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
20
+ Requires-Python: >=3.9
21
+ Description-Content-Type: text/markdown
22
+ License-File: LICENSE
23
+ Requires-Dist: httpx>=0.25.0
24
+ Requires-Dist: pandas>=2.0.0
25
+ Provides-Extra: dev
26
+ Requires-Dist: pytest>=7.0.0; extra == "dev"
27
+ Requires-Dist: pytest-asyncio>=0.21.0; extra == "dev"
28
+ Dynamic: license-file
29
+
30
+ # Reportify SDK for Python
31
+
32
+ Python SDK for Reportify API - Financial data and document search.
33
+
34
+ ## Installation
35
+
36
+ ```bash
37
+ pip install reportify-sdk
38
+ ```
39
+
40
+ ## Quick Start
41
+
42
+ ```python
43
+ from reportify_sdk import Reportify
44
+
45
+ # Initialize client
46
+ client = Reportify(api_key="your-api-key")
47
+
48
+ # Search documents
49
+ docs = client.search("Tesla earnings", num=10)
50
+ for doc in docs:
51
+ print(doc["title"])
52
+ ```
53
+
54
+ ## Features
55
+
56
+ ### Document Search
57
+
58
+ ```python
59
+ # General search across all categories
60
+ docs = client.search("revenue growth", num=10)
61
+
62
+ # Search specific document types
63
+ news = client.search_news("Apple iPhone", num=10)
64
+ reports = client.search_reports("semiconductor analysis", num=10)
65
+ filings = client.search_filings("10-K annual report", symbols=["US:AAPL"])
66
+ transcripts = client.search_transcripts("guidance", symbols=["US:TSLA"])
67
+ ```
68
+
69
+ ### Stock Data (returns pandas DataFrame)
70
+
71
+ ```python
72
+ # Financial statements
73
+ income = client.stock.income_statement("US:AAPL", period="quarterly")
74
+ balance = client.stock.balance_sheet("US:AAPL")
75
+ cashflow = client.stock.cashflow_statement("US:AAPL")
76
+
77
+ # Price data
78
+ prices = client.stock.prices("US:AAPL", limit=30)
79
+ kline = client.stock.kline("US:TSLA", interval="1d", limit=100)
80
+
81
+ # Real-time quotes
82
+ quotes = client.stock.quote(["US:AAPL", "US:MSFT"])
83
+
84
+ # Company info
85
+ overview = client.stock.overview("US:AAPL")
86
+ shareholders = client.stock.shareholders("US:AAPL")
87
+
88
+ # Screening and calendar
89
+ stocks = client.stock.screener(market="US", min_market_cap=1e10)
90
+ earnings = client.stock.earnings_calendar(area="us", start_date="2024-01-01")
91
+ ```
92
+
93
+ ### Timeline
94
+
95
+ ```python
96
+ # Get timeline for followed entities
97
+ companies = client.timeline.companies(num=20)
98
+ topics = client.timeline.topics(num=20)
99
+ institutes = client.timeline.institutes(num=20)
100
+ public_media = client.timeline.public_media(num=20)
101
+ social_media = client.timeline.social_media(num=20)
102
+ ```
103
+
104
+ ### Knowledge Base
105
+
106
+ ```python
107
+ # Search user's uploaded documents
108
+ chunks = client.kb.search("quarterly revenue", folder_ids=["folder_id"])
109
+ ```
110
+
111
+ ### Documents
112
+
113
+ ```python
114
+ # Get document content
115
+ doc = client.docs.get("doc_id")
116
+ summary = client.docs.summary("doc_id")
117
+
118
+ # List and search documents
119
+ docs = client.docs.list(symbols=["US:AAPL"], page_size=10)
120
+ chunks = client.docs.search_chunks("revenue breakdown", num=5)
121
+ ```
122
+
123
+ ## Error Handling
124
+
125
+ ```python
126
+ from reportify_sdk import (
127
+ Reportify,
128
+ AuthenticationError,
129
+ RateLimitError,
130
+ NotFoundError,
131
+ APIError,
132
+ )
133
+
134
+ try:
135
+ docs = client.search("Tesla")
136
+ except AuthenticationError:
137
+ print("Invalid API key")
138
+ except RateLimitError:
139
+ print("Rate limit exceeded, please wait")
140
+ except NotFoundError:
141
+ print("Resource not found")
142
+ except APIError as e:
143
+ print(f"API error: {e.message}")
144
+ ```
145
+
146
+ ## Configuration
147
+
148
+ ```python
149
+ client = Reportify(
150
+ api_key="your-api-key",
151
+ base_url="https://api.reportify.cn", # Optional: custom API URL
152
+ timeout=30.0, # Optional: request timeout in seconds
153
+ )
154
+ ```
155
+
156
+ ## Context Manager
157
+
158
+ ```python
159
+ with Reportify(api_key="your-api-key") as client:
160
+ docs = client.search("Tesla")
161
+ # Client will be closed automatically
162
+ ```
163
+
164
+ ## License
165
+
166
+ MIT License - see [LICENSE](LICENSE) for details.
@@ -0,0 +1,137 @@
1
+ # Reportify SDK for Python
2
+
3
+ Python SDK for Reportify API - Financial data and document search.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ pip install reportify-sdk
9
+ ```
10
+
11
+ ## Quick Start
12
+
13
+ ```python
14
+ from reportify_sdk import Reportify
15
+
16
+ # Initialize client
17
+ client = Reportify(api_key="your-api-key")
18
+
19
+ # Search documents
20
+ docs = client.search("Tesla earnings", num=10)
21
+ for doc in docs:
22
+ print(doc["title"])
23
+ ```
24
+
25
+ ## Features
26
+
27
+ ### Document Search
28
+
29
+ ```python
30
+ # General search across all categories
31
+ docs = client.search("revenue growth", num=10)
32
+
33
+ # Search specific document types
34
+ news = client.search_news("Apple iPhone", num=10)
35
+ reports = client.search_reports("semiconductor analysis", num=10)
36
+ filings = client.search_filings("10-K annual report", symbols=["US:AAPL"])
37
+ transcripts = client.search_transcripts("guidance", symbols=["US:TSLA"])
38
+ ```
39
+
40
+ ### Stock Data (returns pandas DataFrame)
41
+
42
+ ```python
43
+ # Financial statements
44
+ income = client.stock.income_statement("US:AAPL", period="quarterly")
45
+ balance = client.stock.balance_sheet("US:AAPL")
46
+ cashflow = client.stock.cashflow_statement("US:AAPL")
47
+
48
+ # Price data
49
+ prices = client.stock.prices("US:AAPL", limit=30)
50
+ kline = client.stock.kline("US:TSLA", interval="1d", limit=100)
51
+
52
+ # Real-time quotes
53
+ quotes = client.stock.quote(["US:AAPL", "US:MSFT"])
54
+
55
+ # Company info
56
+ overview = client.stock.overview("US:AAPL")
57
+ shareholders = client.stock.shareholders("US:AAPL")
58
+
59
+ # Screening and calendar
60
+ stocks = client.stock.screener(market="US", min_market_cap=1e10)
61
+ earnings = client.stock.earnings_calendar(area="us", start_date="2024-01-01")
62
+ ```
63
+
64
+ ### Timeline
65
+
66
+ ```python
67
+ # Get timeline for followed entities
68
+ companies = client.timeline.companies(num=20)
69
+ topics = client.timeline.topics(num=20)
70
+ institutes = client.timeline.institutes(num=20)
71
+ public_media = client.timeline.public_media(num=20)
72
+ social_media = client.timeline.social_media(num=20)
73
+ ```
74
+
75
+ ### Knowledge Base
76
+
77
+ ```python
78
+ # Search user's uploaded documents
79
+ chunks = client.kb.search("quarterly revenue", folder_ids=["folder_id"])
80
+ ```
81
+
82
+ ### Documents
83
+
84
+ ```python
85
+ # Get document content
86
+ doc = client.docs.get("doc_id")
87
+ summary = client.docs.summary("doc_id")
88
+
89
+ # List and search documents
90
+ docs = client.docs.list(symbols=["US:AAPL"], page_size=10)
91
+ chunks = client.docs.search_chunks("revenue breakdown", num=5)
92
+ ```
93
+
94
+ ## Error Handling
95
+
96
+ ```python
97
+ from reportify_sdk import (
98
+ Reportify,
99
+ AuthenticationError,
100
+ RateLimitError,
101
+ NotFoundError,
102
+ APIError,
103
+ )
104
+
105
+ try:
106
+ docs = client.search("Tesla")
107
+ except AuthenticationError:
108
+ print("Invalid API key")
109
+ except RateLimitError:
110
+ print("Rate limit exceeded, please wait")
111
+ except NotFoundError:
112
+ print("Resource not found")
113
+ except APIError as e:
114
+ print(f"API error: {e.message}")
115
+ ```
116
+
117
+ ## Configuration
118
+
119
+ ```python
120
+ client = Reportify(
121
+ api_key="your-api-key",
122
+ base_url="https://api.reportify.cn", # Optional: custom API URL
123
+ timeout=30.0, # Optional: request timeout in seconds
124
+ )
125
+ ```
126
+
127
+ ## Context Manager
128
+
129
+ ```python
130
+ with Reportify(api_key="your-api-key") as client:
131
+ docs = client.search("Tesla")
132
+ # Client will be closed automatically
133
+ ```
134
+
135
+ ## License
136
+
137
+ MIT License - see [LICENSE](LICENSE) for details.
@@ -0,0 +1,45 @@
1
+ [build-system]
2
+ requires = ["setuptools>=61.0", "wheel"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "reportify-sdk"
7
+ version = "0.1.0"
8
+ description = "Python SDK for Reportify API - Financial data and document search"
9
+ readme = "README.md"
10
+ license = "MIT"
11
+ authors = [
12
+ {name = "Reportify", email = "support@reportify.cn"}
13
+ ]
14
+ keywords = ["reportify", "finance", "stock", "api", "sdk"]
15
+ classifiers = [
16
+ "Development Status :: 4 - Beta",
17
+ "Intended Audience :: Developers",
18
+ "Operating System :: OS Independent",
19
+ "Programming Language :: Python :: 3",
20
+ "Programming Language :: Python :: 3.9",
21
+ "Programming Language :: Python :: 3.10",
22
+ "Programming Language :: Python :: 3.11",
23
+ "Programming Language :: Python :: 3.12",
24
+ "Topic :: Software Development :: Libraries :: Python Modules",
25
+ ]
26
+ requires-python = ">=3.9"
27
+ dependencies = [
28
+ "httpx>=0.25.0",
29
+ "pandas>=2.0.0",
30
+ ]
31
+
32
+ [project.optional-dependencies]
33
+ dev = [
34
+ "pytest>=7.0.0",
35
+ "pytest-asyncio>=0.21.0",
36
+ ]
37
+
38
+ [project.urls]
39
+ Homepage = "https://reportify.cn"
40
+ Documentation = "https://docs.reportify.cn"
41
+ Repository = "https://github.com/reportify/reportify-sdk-python"
42
+
43
+ [tool.setuptools.packages.find]
44
+ where = ["."]
45
+ include = ["reportify_sdk*"]
@@ -0,0 +1,31 @@
1
+ """
2
+ Reportify SDK - Python client for Reportify API
3
+
4
+ A user-friendly SDK for accessing financial data, document search,
5
+ and knowledge base through the Reportify API.
6
+
7
+ Usage:
8
+ from reportify_sdk import Reportify
9
+
10
+ client = Reportify(api_key="your-api-key")
11
+ docs = client.search("Tesla earnings", num=10)
12
+ """
13
+
14
+ from reportify_sdk.client import Reportify
15
+ from reportify_sdk.exceptions import (
16
+ ReportifyError,
17
+ AuthenticationError,
18
+ RateLimitError,
19
+ NotFoundError,
20
+ APIError,
21
+ )
22
+
23
+ __version__ = "0.1.0"
24
+ __all__ = [
25
+ "Reportify",
26
+ "ReportifyError",
27
+ "AuthenticationError",
28
+ "RateLimitError",
29
+ "NotFoundError",
30
+ "APIError",
31
+ ]