Skip to content

Commit 6fc893d

Browse files
committed
ADD: Implement remaining historical APIs for Rust
1 parent db76377 commit 6fc893d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ int main() {
109109
return 0;
110110
}
111111
```
112-
To run this program, replace `$YOUR_API_KEY` with an actual API key.
112+
To run this program, set the `DATABENTO_API_KEY` environment variable with an actual API key.
113113

114114
### Historical
115115

@@ -123,7 +123,7 @@ Here is a simple program that fetches 10 minutes worth of historical trades for
123123
using namespace databento;
124124

125125
int main() {
126-
auto client = HistoricalBuilder{}.SetKey("$YOUR_API_KEY").Build();
126+
auto client = HistoricalBuilder{}.SetKeyFromEnv().Build();
127127
auto print_trades = [](const Record& record) {
128128
const auto& trade_msg = record.Get<TradeMsg>();
129129
std::cout << trade_msg << '\n';
@@ -136,7 +136,7 @@ int main() {
136136
}
137137
```
138138

139-
To run this program, replace `$YOUR_API_KEY` with an actual API key.
139+
To run this program, set the `DATABENTO_API_KEY` environment variable with an actual API key.
140140

141141
Additional example standalone executables are provided in the [examples](./examples) directory.
142142
These examples can be compiled by enabling the cmake option `DATABENTO_ENABLE_EXAMPLES` with `-DDATABENTO_ENABLE_EXAMPLES=1` during the configure step.

0 commit comments

Comments
 (0)