Skip to content

Commit

Permalink
Fixed typo in test and readme
Browse files Browse the repository at this point in the history
  • Loading branch information
mackensiealvarezz committed Jul 11, 2020
1 parent 737bdb4 commit be61e1a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ To create a OAuth URL, you will need to use:
To refresh the token and create another access_token.

//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Refresh token
$response = $client->refreshToken();

Expand All @@ -55,7 +55,7 @@ The package is written to use every class inside of **/src/api** as a function.
This will return a list of all the accounts
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
$accounts = $client->accounts()->list();
```

Expand All @@ -64,7 +64,7 @@ $accounts = $client->accounts()->list();
This will return all the information for one account. **Requires account_id**
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
$accounts = $client->accounts()->get('account_id');
```

Expand All @@ -75,7 +75,7 @@ $accounts = $client->accounts()->get('account_id');
This will return a list of tickers based on the symbol entered
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->instruments()->search('TESLA');
```
Expand All @@ -85,7 +85,7 @@ $response = $client->instruments()->search('TESLA');
This wil return one ticker information
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$accounts = $client->instruments()->get('TSLA');
```
Expand All @@ -97,7 +97,7 @@ $accounts = $client->instruments()->get('TSLA');
This will return a list of all the different market hours
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->market()->list();
```
Expand All @@ -107,7 +107,7 @@ $response = $client->market()->list();
This wil return one market information
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->market()->get('SPY.X');
```
Expand All @@ -120,7 +120,7 @@ $response = $client->market()->get('SPY.X');
This wil return a list of symbols that are moving
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->movers()->get('SPY.X', 'up', 'percent');
```
Expand All @@ -132,17 +132,17 @@ $response = $client->movers()->get('SPY.X', 'up', 'percent');
This will return a list of quotes for the ticker
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->price()->history('TSLA', 'end_date', 'start_date');
$response = $client->price()->history('TSLA', Carbon::now(), Carbon::now());
```

### Get Quote

This wil return the quote for one ticker
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->price()->quote('TSLA');
```
Expand All @@ -152,7 +152,7 @@ $response = $client->price()->quote('TSLA');
This wil return the quote for multiple tickers
```
//Create client
$client = Tdameritrade::create($access_token, $refresh_token);
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->price()->quotes(['AAPL', 'FB']);
```
Expand Down
2 changes: 1 addition & 1 deletion tests/TdameritradeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public function testReturnsInstruments()
public function testReturnsMakert()
{
$client = new Tdameritrade('access_token', 'refresh_token');
$this->assertInstanceOf(Market::class, $client->makert());
$this->assertInstanceOf(Market::class, $client->market());
}

public function testReturnsMovers()
Expand Down

0 comments on commit be61e1a

Please sign in to comment.