Skip to content

Commit

Permalink
README corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
dmoss18 committed Sep 18, 2024
1 parent 103d865 commit a166b38
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ yarn:

## Quickstart
```js
import TastytradeApi from "@tastytrade/api"
import TastytradeClient from "@tastytrade/api"

const tastytradeApi = new TastytradeApi(baseUrl, accountStreamerUrl)
const tastytradeApi = new TastytradeClient({ baseUrl, accountStreamerUrl })
const loginResponse = await tastytradeApi.sessionService.login(usernameOrEmail, password)
const accounts = await tastytradeApi.accountsAndCustomersService.getCustomerAccounts()
const accountPositions = await tastytradeApi.balancesAndPositionsService.getPositionsList(accounts[0].account['account-number'])
Expand Down Expand Up @@ -78,7 +78,7 @@ To subscribe to equities quotes, the `symbol` is just the ticker symbol, like `A

### Account Streamer
```js
import TastytradeApi from "@tastytrade/api"
import TastytradeClient from "@tastytrade/api"
import _ from 'lodash'

function handleStreamerMessage(json) {
Expand All @@ -89,7 +89,7 @@ function handleStreamerStateChange(streamerState) {
console.log('streamer state changed: ', streamerState)
}

const tastytradeClient = new TastytradeApi(baseUlr, accountStreamerUrl)
const tastytradeClient = new TastytradeClient({ baseUrl, accountStreamerUrl })
const accountStreamer = tastytradeClient.accountStreamer
const loginResponse = await tastytradeClient.sessionService.login(usernameOrEmail, password)
const accounts = await tastytradeClient.accountsAndCustomersService.getCustomerAccounts()
Expand Down

0 comments on commit a166b38

Please sign in to comment.