PHP code example of mackensiealvarezz / tdameritrade-laravel
1. Go to this page and download the library: Download mackensiealvarezz/tdameritrade-laravel library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mackensiealvarezz / tdameritrade-laravel example snippets
php artisan vendor:publish
//Create client
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->instruments()->search('TESLA');
//Create client
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->market()->list();
//Create client
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->market()->get('SPY.X');
//Create client
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->price()->quote('TSLA');
//Create client
$client = new Tdameritrade('access_token', 'refresh_token');
//Response
$response = $client->price()->quotes(['AAPL', 'FB']);