Skip to content

Commit 410d257

Browse files
authored
feat: more trading infos by parsing more from trading summary endpoint (#57)
1 parent 093a22a commit 410d257

4 files changed

Lines changed: 13 additions & 10 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bourso-cli"
3-
version = "0.3.2"
3+
version = "0.4.0"
44
edition = "2021"
55
repository = "https://github.com/azerpas/bourso-api"
66

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,14 @@ Choose the right binary for your OS between:
3939

4040
#### Approve the app (MacOS)
4141

42-
If you then get a `"bourso-cli" cannot be opened because the developer cannot be verified` error, go to `System Preferences > Security & Privacy > General` and click `Open Anyway`
42+
On MacOS, you may need to allow the app to run.
4343

44-
If the above doesn't help you, make sure the file is executable:
45-
```sh
46-
chmod +x bourso-cli
47-
# if it still says `Permission denied`, try
48-
chown 777 bourso-cli
49-
```
44+
Make sure you move the app to your Applications folder before running it.
5045

51-
⚠️ Signing in with a different IP address than the ones you usually use will trigger a security check from Bourso. You'll have to validate the connection from your phone. A [GitHub pull request](https://github.com/azerpas/bourso-api/pull/10) is open to handle this case.
46+
Then run the following command in your terminal:
47+
```
48+
xattr -r -d com.apple.quarantine /path/to/bourso-cli
49+
```
5250

5351
#### Verify your installation
5452
Bourso CLI embeds [SLSA](https://slsa.dev/) standard to verify the integrity of the binary. You can verify the signature of the binary by:
@@ -82,6 +80,8 @@ Save your client ID with this config command:
8280
```
8381
The password will be asked each time you run the app to avoid storing it in a file.
8482

83+
⚠️ Signing in with a different IP address than the ones you usually use will trigger a security check from Bourso. You'll have to complete the MFA (Multi-Factor Authentication) process to log in successfully.
84+
8585
### Get your accounts
8686
```
8787
./bourso-cli accounts

src/bourso_api/src/client/trade/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,9 @@ fn get_trading_summary_url(config: &Config, account: Account) -> Result<String>
6666
pub struct TradingSummaryItem {
6767
/// Either "account" or "positions"
6868
pub id: String,
69+
/// Will be Some if TradingSummaryItem is of id "account"
70+
pub account: Option<AccountSummary>,
71+
/// Will be Some if TradingSummaryItem is of id "positions"
6972
pub positions: Option<Vec<PositionSummary>>,
7073
}
7174

0 commit comments

Comments
 (0)