Skip to content

Commit a9f23a4

Browse files
committed
DOC: Standardize API reference pt3
1 parent 2897008 commit a9f23a4

File tree

4 files changed

+32
-19
lines changed

4 files changed

+32
-19
lines changed

databento/historical/api/batch.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def timeseries_submit(
4848
limit: Optional[int] = None,
4949
) -> Dict[str, Any]:
5050
"""
51-
Submit a time series batch data job to the Databento backend.
51+
Request a new time series batch data job from Databento.
5252
5353
Makes a `POST /batch.timeseries_submit` HTTP request.
5454
@@ -93,6 +93,10 @@ def timeseries_submit(
9393
Dict[str, Any]
9494
The job info for submitted batch data request.
9595
96+
Warnings
97+
--------
98+
Calling this method will incur a cost.
99+
96100
"""
97101
if compression is None:
98102
compression = Compression.NONE
@@ -146,7 +150,7 @@ def list_jobs(
146150
since: Optional[Union[pd.Timestamp, date, str, int]] = None,
147151
) -> List[Dict[str, Any]]:
148152
"""
149-
List batch job details for the user account.
153+
Request all batch data job details for the user account.
150154
151155
The job details will be sorted in order of `ts_received`.
152156

databento/historical/api/metadata.py

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def list_datasets(
3232
end_date: Optional[Union[date, str]] = None,
3333
) -> List[str]:
3434
"""
35-
List all available datasets from Databento.
35+
Request all available datasets from Databento.
3636
3737
Makes a `GET /metadata.list_datasets` HTTP request.
3838
@@ -81,7 +81,7 @@ def list_schemas(
8181
end_date: Optional[Union[date, str]] = None,
8282
) -> List[str]:
8383
"""
84-
List all available data schemas from Databento.
84+
Request all available data schemas from Databento.
8585
8686
Makes a `GET /metadata.list_schemas` HTTP request.
8787
@@ -123,7 +123,7 @@ def list_fields(
123123
encoding: Optional[Union[Encoding, str]] = None,
124124
) -> Dict[str, Dict]:
125125
"""
126-
List all fields for a dataset, schema and encoding from Databento.
126+
Request all fields for a dataset, schema and encoding from Databento.
127127
128128
Makes a `GET /metadata.list_fields` HTTP request.
129129
@@ -167,7 +167,7 @@ def list_fields(
167167

168168
def list_encodings(self) -> List[str]:
169169
"""
170-
List all available data encodings from Databento.
170+
Request all available data encodings from Databento.
171171
172172
Makes a `GET /metadata.list_encodings` HTTP request.
173173
@@ -184,7 +184,7 @@ def list_encodings(self) -> List[str]:
184184

185185
def list_compressions(self) -> List[str]:
186186
"""
187-
List all available data compression modes from Databento.
187+
Request all available data compression modes from Databento.
188188
189189
Makes a `GET /metadata.list_compressions` HTTP request.
190190
@@ -206,7 +206,7 @@ def list_unit_prices(
206206
schema: Optional[Union[Schema, str]] = None,
207207
) -> Dict[str, Any]:
208208
"""
209-
List data schema prices per GB unit from Databento.
209+
Request data schema prices per GB unit from Databento.
210210
211211
Makes a `GET /metadata.list_unit_prices` HTTP request.
212212
@@ -257,7 +257,7 @@ def get_shape(
257257
limit: Optional[int] = None,
258258
) -> Tuple:
259259
"""
260-
Get the shape of the time series data query.
260+
Request the shape of the time series data from Databento.
261261
262262
Makes a GET `/metadata.get_shape` HTTP request.
263263
@@ -335,8 +335,8 @@ def get_billable_size(
335335
limit: Optional[int] = None,
336336
) -> int:
337337
"""
338-
Get the raw uncompressed binary size of a historical streaming or batch
339-
data request, which would be used for billing.
338+
Request the billable uncompressed raw binary size for historical
339+
streaming or batched files from Databento.
340340
341341
Makes a GET `/metadata.get_billable_size` HTTP request.
342342
@@ -404,7 +404,8 @@ def get_cost(
404404
limit: Optional[int] = None,
405405
) -> float:
406406
"""
407-
Get cost in US Dollars for a historical streaming or batch data request.
407+
Request the cost in US Dollars for historical streaming or batched files
408+
from Databento.
408409
409410
Makes a `GET /metadata.get_cost` HTTP request.
410411
@@ -472,7 +473,8 @@ def get_license_fee(
472473
purposes: Union[List[str], str],
473474
) -> int:
474475
"""
475-
Get the license fee in US Dollars for a dataset and access purposes.
476+
Request the license fee in US Dollars for a dataset and access purposes
477+
from Databento.
476478
477479
Makes a `GET /metadata.get_license_fee` HTTP request.
478480

databento/historical/api/symbology.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def resolve(
2929
default_value: Optional[str] = "",
3030
):
3131
"""
32-
Request symbology resolution.
32+
Request symbology mappings resolution from Databento.
3333
3434
Makes a `GET /symbology.resolve` HTTP request.
3535

databento/historical/api/timeseries.py

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def stream(
3737
path: Optional[str] = None,
3838
) -> Bento:
3939
"""
40-
Request a historical time series stream from the Databento API servers.
40+
Request a historical time series stream from Databento.
4141
4242
Makes a `GET /timeseries.stream` HTTP request.
4343
@@ -68,12 +68,16 @@ def stream(
6868
Returns
6969
-------
7070
Bento
71-
If `path` provided then FileBento, otherwise MemoryBento.
71+
If `path` provided then `FileBento`, otherwise `MemoryBento`.
7272
7373
Notes
7474
-----
7575
The Databento Binary Encoding + Zstd Compression (DBZ) will be streamed.
7676
77+
Warnings
78+
--------
79+
Calling this method will incur a cost.
80+
7781
"""
7882
validate_enum(schema, Schema, "schema")
7983
validate_enum(stype_in, SType, "stype_in")
@@ -130,8 +134,7 @@ async def stream_async(
130134
path: str = None,
131135
) -> Bento:
132136
"""
133-
Request a historical time series stream from the Databento API servers
134-
asynchronously.
137+
Request a historical time series stream from Databento asynchronously.
135138
136139
Makes a `GET /timeseries.stream` HTTP request.
137140
@@ -162,12 +165,16 @@ async def stream_async(
162165
Returns
163166
-------
164167
Bento
165-
If `path` provided then FileBento, otherwise MemoryBento.
168+
If `path` provided then `FileBento`, otherwise `MemoryBento`.
166169
167170
Notes
168171
-----
169172
The Databento Binary Encoding + Zstd Compression (DBZ) will be streamed.
170173
174+
Warnings
175+
--------
176+
Calling this method will incur a cost.
177+
171178
"""
172179
validate_enum(schema, Schema, "schema")
173180
validate_enum(stype_in, SType, "stype_in")

0 commit comments

Comments
 (0)