{"id":13510224,"url":"https://github.com/aurbano/robinhood-node","last_synced_at":"2025-03-30T15:30:58.097Z","repository":{"id":31529757,"uuid":"35094286","full_name":"aurbano/robinhood-node","owner":"aurbano","description":":chart_with_upwards_trend: NodeJS client for Robinhood Trading :fire:","archived":true,"fork":false,"pushed_at":"2021-11-25T16:56:02.000Z","size":343,"stargazers_count":698,"open_issues_count":25,"forks_count":185,"subscribers_count":44,"default_branch":"master","last_synced_at":"2025-03-22T03:32:24.758Z","etag":null,"topics":["javascript","robinhood","robinhood-api","stock","trade"],"latest_commit_sha":null,"homepage":"https://aurbano.github.io/robinhood-node","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aurbano.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-05T11:02:04.000Z","updated_at":"2025-03-10T14:55:11.000Z","dependencies_parsed_at":"2022-08-07T16:30:27.846Z","dependency_job_id":null,"html_url":"https://github.com/aurbano/robinhood-node","commit_stats":null,"previous_names":[],"tags_count":36,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurbano%2Frobinhood-node","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurbano%2Frobinhood-node/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurbano%2Frobinhood-node/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aurbano%2Frobinhood-node/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aurbano","download_url":"https://codeload.github.com/aurbano/robinhood-node/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246338736,"owners_count":20761426,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["javascript","robinhood","robinhood-api","stock","trade"],"created_at":"2024-08-01T02:01:29.786Z","updated_at":"2025-03-30T15:30:53.081Z","avatar_url":"https://github.com/aurbano.png","language":"JavaScript","funding_links":[],"categories":["JavaScript","javascript"],"sub_categories":[],"readme":"\u003ch1\u003e\u003cimg src=\"https://raw.githubusercontent.com/aurbano/robinhood-node/master/.github/robinhood-node.png\"/\u003e\u003c/h1\u003e\n\nNodeJS Framework to make trades with the private [Robinhood](https://www.robinhood.com/) API. Using this API is not encouraged, since it's not officially available and it has been reverse engineered.\nSee @Sanko's [Unofficial Documentation](https://github.com/sanko/Robinhood) for more information.\n\nFYI [Robinhood's Terms and Conditions](https://brokerage-static.s3.amazonaws.com/assets/robinhood/legal/Robinhood%20Terms%20and%20Conditions.pdf)\n\n\u003c!-- toc --\u003e\n  * [Features](#features)\n  * [Installation](#installation)\n  * [Usage](#usage)\n  * [API](#api)\n    * [`auth_token()`](#auth_token)\n    * [`expire_token(callback)`](#expire_token)\n    * [`investment_profile(callback)`](#investment_profilecallback)\n    * [`instruments(symbol, callback)`](#instrumentssymbol-callback)\n    * [`quote_data(stock, callback) // Not authenticated`](#quote_datastock-callback--not-authenticated)\n    * [`accounts(callback)`](#accountscallback)\n    * [`user(callback)`](#usercallback)\n    * [`dividends(callback)`](#dividendscallback)\n    * [`earnings(option, callback)`](#earningsoption-callback)\n    * [`orders(options, callback)`](#ordersoptions-callback)\n    * [`positions(callback)`](#positionscallback)\n    * [`nonzero_positions(callback)`](#nonzero_positionscallback)\n    * [`place_buy_order(options, callback)`](#place_buy_orderoptions-callback)\n      * [`trigger`](#trigger)\n      * [`time`](#time)\n    * [`place_sell_order(options, callback)`](#place_sell_orderoptions-callback)\n      * [`trigger`](#trigger)\n      * [`time`](#time)\n    * [`fundamentals(symbol, callback)`](#fundamentalssymbol-callback)\n      * [Response](#response)\n    * [`cancel_order(order, callback)`](#cancel_orderorder-callback)\n    * [`watchlists(name, callback)`](#watchlistsname-callback)\n    * [`create_watch_list(name, callback)`](#create_watch_listname-callback)\n    * [`sp500_up(callback)`](#sp500_upcallback)\n    * [`sp500_down(callback)`](#sp500_downcallback)\n    * [`splits(instrument, callback)`](#splitsinstrument-callback)\n    * [`historicals(symbol, intv, span, callback)`](#historicalssymbol-intv-span-callback)\n    * [`url(url, callback)`](#urlurl-callback)\n    * [`news(symbol, callback)`](#newssymbol-callback)\n    * [`tag(tag, callback)`](#tagtag-callback)\n    * [`popularity(symbol, callback)`](#popularitysymbol-callback)\n    * [`options_positions`](#options_positions)\n    * [`get_currency_pairs`](#get_currency_pairs)\n    * [`get_crypto`](#get_crypto)\n    * [`options_orders`](#options_orders)\n* [Contributors](#contributors)\n\n\u003c!-- toc stop --\u003e\n## Features\n* Quote Data\n* Buy, Sell Orders\n* Daily Fundamentals\n* Daily, Weekly, Monthly Historicals\n\n\u003e Tested on the latest versions of Node 6, 7 \u0026 8.\n\n## Installation\n```bash\n$ npm install robinhood --save\n```\n\n## Usage\n\nTo authenticate, you can either use your username and password to the Robinhood app or a previously authenticated Robinhood api token:\n\n### Robinhood API Auth Token\n```js\n//A previously authenticated Robinhood API auth token\n\nvar credentials = {\n    token: ''\n};\n```\n\n```js\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n\n    //Robinhood is connected and you may begin sending commands to the api.\n\n    Robinhood.quote_data('GOOG', function(error, response, body) {\n        if (error) {\n            console.error(error);\n            process.exit(1);\n        }\n        console.log(body);\n    });\n\n});\n```\n\n### Username \u0026 Password\n\nThis type of login may have been deprecated in favor of the API Token above.\n\n```js\n//The username and password you use to sign into the robinhood app.\n\nvar credentials = {\n    username: '',\n    password: ''\n};\n```\n\n### MFA code\n\n```js\n\nvar Robinhood = robinhood({\n        username : '',\n        password : ''\n    }, (err, data) =\u003e {\n        if(err) {\n            console.log(err);\n        } else {\n            if (data \u0026\u0026 data.mfa_required) {\n            var mfa_code = '123456'; // set mfa_code here\n\n            Robinhood.set_mfa_code(mfa_code, () =\u003e {\n                console.log(Robinhood.auth_token());\n            });\n            }\n            else {\n                console.log(Robinhood.auth_token());\n            }\n        }\n    });\n```\n\n\n\n## API\n\nBefore using these methods, make sure you have initialized Robinhood using the snippet above.\n\n### `auth_token()`\nGet the current authenticated Robinhood api authentication token\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    console.log(Robinhood.auth_token());\n        //      \u003cauthenticated alphanumeric token\u003e\n}\n```\n\n### `expire_token()`\nExpire the current authenticated Robinhood api token (logout).\n\n\u003e **NOTE:** After expiring a token you will need to reinstantiate the package with username \u0026 password in order to get a new token!\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.expire_token(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"Successfully logged out of Robinhood and expired token.\");\n            // NOTE: body is undefined on the callback\n        }\n    })\n});\n```\n\n### `investment_profile(callback)`\nGet the current user's investment profile.\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.investment_profile(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"investment_profile\");\n            console.log(body);\n                //    { annual_income: '25000_39999',\n                //      investment_experience: 'no_investment_exp',\n                //      updated_at: '2015-06-24T17:14:53.593009Z',\n                //      risk_tolerance: 'low_risk_tolerance',\n                //      total_net_worth: '0_24999',\n                //      liquidity_needs: 'very_important_liq_need',\n                //      investment_objective: 'income_invest_obj',\n                //      source_of_funds: 'savings_personal_income',\n                //      user: 'https://api.robinhood.com/user/',\n                //      suitability_verified: true,\n                //      tax_bracket: '',\n                //      time_horizon: 'short_time_horizon',\n                //      liquid_net_worth: '0_24999' }\n\n        }\n    })\n});\n```\n\n\n### `instruments(symbol, callback)`\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.instruments('AAPL',function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"instruments\");\n            console.log(body);\n            //    { previous: null,\n            //      results:\n            //       [ { min_tick_size: null,\n            //           splits: 'https://api.robinhood.com/instruments/450dfc6d-5510-4d40-abfb-f633b7d9be3e/splits/',\n            //           margin_initial_ratio: '0.5000',\n            //           url: 'https://api.robinhood.com/instruments/450dfc6d-5510-4d40-abfb-f633b7d9be3e/',\n            //           quote: 'https://api.robinhood.com/quotes/AAPL/',\n            //           symbol: 'AAPL',\n            //           bloomberg_unique: 'EQ0010169500001000',\n            //           list_date: '1990-01-02',\n            //           fundamentals: 'https://api.robinhood.com/fundamentals/AAPL/',\n            //           state: 'active',\n            //           day_trade_ratio: '0.2500',\n            //           tradeable: true,\n            //           maintenance_ratio: '0.2500',\n            //           id: '450dfc6d-5510-4d40-abfb-f633b7d9be3e',\n            //           market: 'https://api.robinhood.com/markets/XNAS/',\n            //           name: 'Apple Inc. - Common Stock' } ],\n            //      next: null }\n        }\n    })\n});\n```\n\n\nGet the user's instruments for a specified stock.\n\n### `quote_data(stock, callback) // Not authenticated`\n\nGet the user's quote data for a specified stock.\n\n```js\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.quote_data('AAPL', function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"quote_data\");\n            console.log(body);\n            //{\n            //    results: [\n            //        {\n            //            ask_price: String, // Float number in a String, e.g. '735.7800'\n            //            ask_size: Number, // Integer\n            //            bid_price: String, // Float number in a String, e.g. '731.5000'\n            //            bid_size: Number, // Integer\n            //            last_trade_price: String, // Float number in a String, e.g. '726.3900'\n            //            last_extended_hours_trade_price: String, // Float number in a String, e.g. '735.7500'\n            //            previous_close: String, // Float number in a String, e.g. '743.6200'\n            //            adjusted_previous_close: String, // Float number in a String, e.g. '743.6200'\n            //            previous_close_date: String, // YYYY-MM-DD e.g. '2016-01-06'\n            //            symbol: String, // e.g. 'AAPL'\n            //            trading_halted: Boolean,\n            //            updated_at: String, // YYYY-MM-DDTHH:MM:SS e.g. '2016-01-07T21:00:00Z'\n            //        }\n            //    ]\n            //}\n        }\n    })\n});\n```\n\n### `accounts(callback)`\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.accounts(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"accounts\");\n            console.log(body);\n            //{ previous: null,\n            //  results:\n            //   [ { deactivated: false,\n            //       updated_at: '2016-03-11T20:37:15.971253Z',\n            //       margin_balances: [Object],\n            //       portfolio: 'https://api.robinhood.com/accounts/asdf/portfolio/',\n            //       cash_balances: null,\n            //       withdrawal_halted: false,\n            //       cash_available_for_withdrawal: '692006.6600',\n            //       type: 'margin',\n            //       sma: '692006.6600',\n            //       sweep_enabled: false,\n            //       deposit_halted: false,\n            //       buying_power: '692006.6600',\n            //       user: 'https://api.robinhood.com/user/',\n            //       max_ach_early_access_amount: '1000.00',\n            //       cash_held_for_orders: '0.0000',\n            //       only_position_closing_trades: false,\n            //       url: 'https://api.robinhood.com/accounts/asdf/',\n            //       positions: 'https://api.robinhood.com/accounts/asdf/positions/',\n            //       created_at: '2015-06-17T14:53:36.928233Z',\n            //       cash: '692006.6600',\n            //       sma_held_for_orders: '0.0000',\n            //       account_number: 'asdf',\n            //       uncleared_deposits: '0.0000',\n            //       unsettled_funds: '0.0000' } ],\n            //  next: null }\n        }\n    })\n});\n```\n\n\nGet the user's accounts.\n\n### `user(callback)`\nGet the user information.\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.user(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"user\");\n            console.log(body);\n        }\n    })\n});\n```\n\n### `dividends(callback)`\n\nGet the user's dividends information.\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.dividends(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"dividends\");\n            console.log(body);\n        }\n    })\n});\n```\n\n### `earnings(option, callback)`\n\nGet the earnings information. Option should be one of:\n\n```typescript\nlet option = { range: X } // X is an integer between 1 and 21. This returns all\n                          // expected earnings within a number of calendar days.\n```\nOR\n```typescript\nlet option = { instrument: URL } // URL is full instrument url.\n```\nOR\n```typescript\nlet option = { symbol: SYMBOL } // SYMBOL is a plain ol' ticker symbol.\n```\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.earnings(option, function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"earnings\");\n            console.log(body);\n        }\n    })\n});\n```\n\n\n### `orders(options, callback)`\n\nGet the user's orders information.\n\n#### Retreive a set of orders\nSend options hash (optional) to limit to specific instrument and/or earliest date of orders.\n\n```typescript\n// optional options hash.  If no hash is sent, all orders will be returned.\nlet options = {\n    updated_at: '2017-08-25',\n    instrument: 'https://api.robinhood.com/instruments/df6c09dc-bb4f-4495-8c59-f13e6eb3641f/'\n}\n```\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.orders(options, function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"orders\");\n            console.log(body);\n        }\n    })\n});\n```\n\n#### Retreive a particular order\nSend the id of the order to retreive the data for a specific order.\n```typescript\nlet order_id = \"string_identifier\"; // e.g., id: 'aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa',\n```\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.orders(order_id, function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"order\");\n            console.log(body);\n        }\n    })\n});\n```\n\n### `positions(callback)`\n\nGet the user's position information.\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.positions(function(err, response, body){\n        if (err){\n            console.error(err);\n        }else{\n            console.log(\"positions\");\n            console.log(body);\n        }\n    });\n});\n```\n\n### `nonzero_positions(callback)`\n\nGet the user's nonzero position information only.\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.nonzero_positions(function(err, response, body){\n        if (err){\n            console.error(err);\n        }else{\n            console.log(\"positions\");\n            console.log(body);\n        }\n    });\n});\n```\n\n### `place_buy_order(options, callback)`\n\nPlace a buy order on a specified stock.\n\n```js\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    var options = {\n        type: 'limit',\n        quantity: 1,\n        bid_price: 1.00,\n        instrument: {\n            url: String,\n            symbol: String\n        }\n        // // Optional:\n        // trigger: String, // Defaults to \"gfd\" (Good For Day)\n        // time: String,    // Defaults to \"immediate\"\n        // type: String     // Defaults to \"market\"\n    }\n    Robinhood.place_buy_order(options, function(error, response, body){\n        if(error){\n            console.error(error);\n        }else{\n            console.log(body);\n        }\n    })\n});\n```\n\nFor the Optional ones, the values can be:\n\n*[Disclaimer: This is an unofficial API based on reverse engineering, and the following option values have not been confirmed]*\n\n#### `trigger`\n\nA *[trade trigger](http://www.investopedia.com/terms/t/trade-trigger.asp)* is usually a market condition, such as a rise or fall in the price of an index or security.\n\nValues can be:\n\n* `gfd`: Good For Day\n* `gtc`: Good Till Cancelled\n* `oco`: Order Cancels Other\n\n#### `time`\n\nThe *[time in force](http://www.investopedia.com/terms/t/timeinforce.asp?layout=infini\u0026v=3A)* for an order defines the length of time over which an order will continue working before it is canceled.\n\nValues can be:\n\n* `immediate` : The order will be cancelled unless it is fulfilled immediately.\n* `day` : The order will be cancelled at the end of the trading day.\n\n### `place_sell_order(options, callback)`\n\nPlace a sell order on a specified stock.\n\n```js\n\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    var options = {\n        type: 'limit',\n        quantity: 1,\n        bid_price: 1.00,\n        instrument: {\n            url: String,\n            symbol: String\n        },\n        // // Optional:\n        // trigger: String, // Defaults to \"gfd\" (Good For Day)\n        // time: String,    // Defaults to \"immediate\"\n        // type: String     // Defaults to \"market\"\n    }\n    Robinhood.place_sell_order(options, function(error, response, body){\n        if(error){\n            console.error(error);\n        }else{\n            console.log(body);\n        }\n    })\n});\n\n```\n\nFor the Optional ones, the values can be:\n\n*[Disclaimer: This is an unofficial API based on reverse engineering, and the following option values have not been confirmed]*\n\n#### `trigger`\n\nA *[trade trigger](http://www.investopedia.com/terms/t/trade-trigger.asp)* is usually a market condition, such as a rise or fall in the price of an index or security.\n\nValues can be:\n\n* `gfd`: Good For Day\n* `gtc`: Good Till Cancelled\n* `oco`: Order Cancels Other\n\n#### `time`\n\nThe *[time in force](http://www.investopedia.com/terms/t/timeinforce.asp?layout=infini\u0026v=3A)* for an order defines the length of time over which an order will continue working before it is canceled.\n\nValues can be:\n\n* `immediate` : The order will be cancelled unless it is fulfilled immediately.\n* `day` : The order will be cancelled at the end of the trading day.\n\n### `fundamentals(symbol, callback)`\n\nGet fundamental data about a symbol.\n\n#### Response\n\nAn object containing information about the symbol:\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.fundamentals(\"SBPH\", function(error, response, body){\n        if(error){\n            console.error(error);\n        }else{\n            console.log(body);\n            //{                               // Example for SBPH\n            //    average_volume: string,     // \"14381.0215\"\n            //    description: string,        // \"Spring Bank Pharmaceuticals, Inc. [...]\"\n            //    dividend_yield: string,     // \"0.0000\"\n            //    high: string,               // \"12.5300\"\n            //    high_52_weeks: string,      // \"13.2500\"\n            //    instrument: string,         // \"https://api.robinhood.com/instruments/42e07e3a-ca7a-4abc-8c23-de49cb657c62/\"\n            //    low: string,                // \"11.8000\"\n            //    low_52_weeks: string,       // \"7.6160\"\n            //    market_cap: string,         // \"94799500.0000\"\n            //    open: string,               // \"12.5300\"\n            //    pe_ratio: string,           // null (price/earnings ratio)\n            //    volume: string              // \"4119.0000\"\n            //}\n        }\n    })\n});\n\n\n```\n\n### `cancel_order(order, callback)`\n\nCancel an order with the order object\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    //Get list of orders\n    Robinhood.orders(function(error, response, body){\n        if(error){\n            console.error(error);\n        }else{\n            var orderToCancel = body.results[0];\n            //Try to cancel the latest order\n            Robinhood.cancel_order(orderToCancel, function(err, response, body){\n                if(err){\n                    //Error\n\n                    console.error(err);     // { message: 'Order cannot be cancelled.', order: {Order} }\n                }else{\n                    //Success\n\n                    console.log(\"Cancel Order Successful\");\n                    console.log(body)       //{}\n                }\n            })\n        }\n    })\n})\n```\n\nCancel an order by order id\n\n```typescript\nvar order_id = 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n        Robinhood.cancel_order(order_id, function(err, response, body){\n            if(err){\n                //Error\n                console.error(err);     // { message: 'Order cannot be cancelled.', order: {Order} }\n            }else{\n                //Success\n                console.log(\"Cancel Order Successful\");\n                console.log(body)       //{}\n            }\n        })\n})\n```\n\n### `watchlists(name, callback)`\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.watchlists(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"got watchlists\");\n            console.log(body);\n\n            //{ previous: null,\n            //  results:\n            //   [ { url: 'https://api.robinhood.com/watchlists/Default/',\n            //       user: 'https://api.robinhood.com/user/',\n            //      name: 'Default' } ],\n            //  next: null }\n        }\n    })\n});\n```\n\n### `create_watch_list(name, callback)`\n```\n//Your account type must support multiple watchlists to use this endpoint otherwise will get { detail: 'Request was throttled.' } and watchlist is not created.\nRobinhood.create_watch_list('Technology', function(err, response, body){\n    if(err){\n        console.error(err);\n    }else{\n        console.log(\"created watchlist\");\n        console.log(body);\n    //    {\n    //        \"url\": \"https://api.robinhood.com/watchlists/Technology/\",\n    //        \"user\": \"https://api.robinhood.com/user/\",\n    //        \"name\": \"Technology\"\n    //    }\n\n    }\n})\n```\n\n### `sp500_up(callback)`\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.sp500_up(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"sp500_up\");\n            console.log(body);\n            //{ count: 10,\n            //  next: null,\n            //  previous: null,\n            //  results:\n            //   [ { instrument_url: 'https://api.robinhood.com/instruments/adbc3ce0-dd0d-4a7a-92e0-88c1f127cbcb/',\n            //       symbol: 'NEM',\n            //       updated_at: '2016-09-21T13:03:32.310184Z',\n            //       price_movement: [{ market_hours_last_movement_pct: '7.55', market_hours_last_price: '41.0300' }],\n            //       description: 'Newmont Mining Corp. is a gold producer, which is engaged in the acquisition, exploration and production of gold and copper properties in U.S., Australia, Peru, Indonesia, Ghana, Canada, New Zealand and Mexico. The company\\'s operating segments include North America, South America, Asia Pacific and Africa. The North America segment consists of Nevada in the United States, La Herradura in Mexico and Hope Bay in Canada. The South America segment consists of Yanacocha and Conga in Peru. The Asia Pacific segment consists of Boddington in Australia, Batu Hijau in Indonesia and other smaller operations in Australia and New Zealand. The Africa segment consists of Ahafo and Akyem in Ghana. The company was founded by William Boyce Thompson on May 2, 1921 and is headquartered in Greenwood Village, CO.' },\n            //     { instrument_url: 'https://api.robinhood.com/instruments/809adc21-ef75-4c3d-9c0e-5f9a167f235b/',\n            //       symbol: 'ADBE',\n            //       updated_at: '2016-09-21T13:01:31.748590Z',\n            //       price_movement: [{ market_hours_last_movement_pct: '7.55', market_hours_last_price: '41.0300' }],\n            //       description: 'Adobe Systems, Inc. provides digital marketing and digital media solutions. The company operates its business through three segments: Digital Media, Digital Marketing, and Print and Publishing. The Digital Media segment offers creative cloud services, which allow members to download and install the latest versions of products, such as Adobe Photoshop, Adobe Illustrator, Adobe Premiere Pro, Adobe Photoshop Lightroom and Adobe InDesign, as well as utilize other tools, such as Adobe Acrobat. This segment also offers other tools and services, including hobbyist products, such as Adobe Photoshop Elements and Adobe Premiere Elements, Adobe Digital Publishing Suite, Adobe PhoneGap, Adobe Typekit, as well as mobile apps, such as Adobe Photoshop Mix, Adobe Photoshop Sketch and Adobe Premiere Clip that run on tablets and mobile devices. The Digital Media serves professionals, including graphic designers, production artists, web designers and developers, user interface designers, videographers, motion graphic artists, prepress professionals, video game developers, mobile application developers, students and administrators. The Digital Marketing segment offers various solutions, including analytics, social marketing, targeting, media optimization, digital experience management and cross-channel campaign management, as well as premium video delivery and monetization. This segment also offers legacy enterprise software, such as Adobe Connect web conferencing platform and Adobe LiveCycle. The Print and Publishing segment offers legacy products and services for eLearning solutions, technical document publishing, web application development and high-end printing. Adobe Systems was founded by Charles M. Geschke and John E. Warnock in December 1982 and is headquartered in San Jose, CA.' }\n            //    ]\n            //}\n        }\n    })\n});\n```\n\n### `sp500_down(callback)`\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n    Robinhood.sp500_down(function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"sp500_down\");\n            console.log(body);\n            //{ count: 10,\n            //  next: null,\n            //  previous: null,\n            //  results:\n            //   [ { instrument_url: 'https://api.robinhood.com/instruments/adbc3ce0-dd0d-4a7a-92e0-88c1f127cbcb/',\n            //       symbol: 'NEM',\n            //       updated_at: '2016-09-21T13:03:32.310184Z',\n            //       price_movement: [{ market_hours_last_movement_pct: '-3.70', market_hours_last_price: '13.2800' }],\n            //      description: 'Newmont Mining Corp. is a gold producer, which is engaged in the acquisition, exploration and production of gold and copper properties in U.S., Australia, Peru, Indonesia, Ghana, Canada, New Zealand and Mexico. The company\\'s operating segments include North America, South America, Asia Pacific and Africa. The North America segment consists of Nevada in the United States, La Herradura in Mexico and Hope Bay in Canada. The South America segment consists of Yanacocha and Conga in Peru. The Asia Pacific segment consists of Boddington in Australia, Batu Hijau in Indonesia and other smaller operations in Australia and New Zealand. The Africa segment consists of Ahafo and Akyem in Ghana. The company was founded by William Boyce Thompson on May 2, 1921 and is headquartered in Greenwood Village, CO.' },\n            //     { instrument_url: 'https://api.robinhood.com/instruments/809adc21-ef75-4c3d-9c0e-5f9a167f235b/',\n            //       symbol: 'ADBE',\n            //       updated_at: '2016-09-21T13:01:31.748590Z',\n            //       price_movement: [{ market_hours_last_movement_pct: '-3.70', market_hours_last_price: '13.2800' }],\n            //       description: 'Adobe Systems, Inc. provides digital marketing and digital media solutions. The company operates its business through three segments: Digital Media, Digital Marketing, and Print and Publishing. The Digital Media segment offers creative cloud services, which allow members to download and install the latest versions of products, such as Adobe Photoshop, Adobe Illustrator, Adobe Premiere Pro, Adobe Photoshop Lightroom and Adobe InDesign, as well as utilize other tools, such as Adobe Acrobat. This segment also offers other tools and services, including hobbyist products, such as Adobe Photoshop Elements and Adobe Premiere Elements, Adobe Digital Publishing Suite, Adobe PhoneGap, Adobe Typekit, as well as mobile apps, such as Adobe Photoshop Mix, Adobe Photoshop Sketch and Adobe Premiere Clip that run on tablets and mobile devices. The Digital Media serves professionals, including graphic designers, production artists, web designers and developers, user interface designers, videographers, motion graphic artists, prepress professionals, video game developers, mobile application developers, students and administrators. The Digital Marketing segment offers various solutions, including analytics, social marketing, targeting, media optimization, digital experience management and cross-channel campaign management, as well as premium video delivery and monetization. This segment also offers legacy enterprise software, such as Adobe Connect web conferencing platform and Adobe LiveCycle. The Print and Publishing segment offers legacy products and services for eLearning solutions, technical document publishing, web application development and high-end printing. Adobe Systems was founded by Charles M. Geschke and John E. Warnock in December 1982 and is headquartered in San Jose, CA.' }\n            //    ]\n            //}\n\n        }\n    })\n});\n```\n### `splits(instrument, callback)`\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n\n    Robinhood.splits(\"7a3a677d-1664-44a0-a94b-3bb3d64f9e20\", function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"got splits\");\n            console.log(body);   //{ previous: null, results: [], next: null }\n        }\n    })\n})\n```\n\n### `historicals(symbol, intv, span, callback)`\n\n```typescript\nvar Robinhood = require('robinhood')(credentials, function(err, data){\n\n    //{interval=5minute|10minute (required) span=week|day| }\n\n    Robinhood.historicals(\"AAPL\", '5minute', 'week', function(err, response, body){\n        if(err){\n            console.error(err);\n        }else{\n            console.log(\"got historicals\");\n            console.log(body);\n            //\n            //    { quote: 'https://api.robinhood.com/quotes/AAPL/',\n            //      symbol: 'AAPL',\n            //      interval: '5minute',\n            //      span: 'week',\n            //      bounds: 'regular',\n            //      previous_close: null,\n            //      historicals:\n            //       [ { begins_at: '2016-09-15T13:30:00Z',\n            //           open_price: '113.8300',\n            //           close_price: '114.1700',\n            //           high_price: '114.3500',\n            //           low_price: '113.5600',\n            //           volume: 3828122,\n            //           session: 'reg',\n            //           interpolated: false },\n            //         { begins_at: '2016-09-15T13:35:00Z',\n            //           open_price: '114.1600',\n            //           close_price: '114.3800',\n            //           high_price: '114.7300',\n            //           low_price: '114.1600',\n            //           volume: 2166098,\n            //           session: 'reg',\n            //           interpolated: false },\n            //         ... 290 more items\n            //      ]}\n            //\n        }\n    })\n})\n```\n\n### `url(url, callback)`\n\n`url` is used to get continued or paginated data from the API. Queries with long results return a reference to the next sete. Example -\n\n```\nnext: 'https://api.robinhood.com/orders/?cursor=cD0yMD82LTA0LTAzKzkwJVNCNTclM0ExNC45MzYyKDYlMkIwoCUzqtAW' }\n```\n\nThe url returned can be passed to the `url` method to continue getting the next set of results.\n\n### `tag(tag, callback)`\n\nRetrieve Robinhood's new Tags: In 2018, Robinhood Web will expose more Social and Informational tools.\nYou'll see how popular a security is with other Robinhood users, MorningStar ratings, etc.\n\nKnown tags:\n\n* 10 Most Popular Instruments: `10-most-popular`\n* 100 Most Popular Instruments: `100-most-popular`\n\nResponse sample:\n\n```typescript\n{\n   \"slug\":\"10-most-popular\",\n   \"name\":\"10 Most Popular\",\n   \"description\":\"\",\n   \"instruments\":[\n      \"https://api.robinhood.com/instruments/6df56bd0-0bf2-44ab-8875-f94fd8526942/\",\n      \"https://api.robinhood.com/instruments/50810c35-d215-4866-9758-0ada4ac79ffa/\",\n      \"https://api.robinhood.com/instruments/450dfc6d-5510-4d40-abfb-f633b7d9be3e/\",\n      \"https://api.robinhood.com/instruments/e39ed23a-7bd1-4587-b060-71988d9ef483/\",\n      \"https://api.robinhood.com/instruments/1e513292-5926-4dc4-8c3d-4af6b5836704/\",\n      \"https://api.robinhood.com/instruments/39ff611b-84e7-425b-bfb8-6fe2a983fcf3/\",\n      \"https://api.robinhood.com/instruments/ebab2398-028d-4939-9f1d-13bf38f81c50/\",\n      \"https://api.robinhood.com/instruments/940fc3f5-1db5-4fed-b452-f3a2e4562b5f/\",\n      \"https://api.robinhood.com/instruments/c74a93bc-58f3-4ccb-b4e3-30c65e2f88c8/\",\n      \"https://api.robinhood.com/instruments/fdf46795-2a81-4506-880f-514c8010c163/\"\n   ]\n}\n```\n\n### `popularity(symbol, callback)`\n\nGet the popularity for a specified stock.\n\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.popularity('GOOG', function(error, response, body) {\n        if (error) {\n            console.error(error);\n        } else {\n            console.log(body);\n            // {\n            //    instrument: 'https://api.robinhood.com/instruments/943c5009-a0bb-4665-8cf4-a95dab5874e4/',\n            //    num_open_positions: 16319\n            // }\n        }\n    });\n});\n```\n\n### `options_positions`\n\nObtain list of options positions\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.options_positions((err, response, body) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            console.log(body);\n        }\n    });\n});\n\n// {\n//   \"created_at\": \"2018-10-12T17:05:18.195533Z\",\n//   \"direction\": \"credit\",\n//   \"intraday_quantity\": \"35.0000\",\n//   \"average_open_price\": \"56.5143\",\n//   \"chain\": \"https://api.robinhood.com/options/chains/103ce21e-4921-47ed-a263-e05d2d3d5e99/\",\n//   \"updated_at\": \"2018-10-12T19:11:02.984831Z\",\n//   \"symbol\": \"XLF\",\n//   \"trade_value_multiplier\": \"100.0000\",\n//   \"intraday_direction\": \"credit\",\n//   \"strategy\": \"short_put\",\n//   \"intraday_average_open_price\": \"56.5143\",\n//   \"legs\": [\n//     {\n//       \"strike_price\": \"26.5000\",\n//       \"option\": \"https://api.robinhood.com/options/instruments/fa512b6e-c121-4ff4-b8aa-9aa2974514b7/\",\n//       \"expiration_date\": \"2018-10-19\",\n//       \"option_type\": \"put\",\n//       \"id\": \"214e0f90-4416-427a-b119-e1a96d8e9da7\",\n//       \"position_type\": \"short\",\n//       \"position\": \"https://api.robinhood.com/options/positions/e18fda89-6ff2-443f-af71-cd780e558049/\",\n//       \"ratio_quantity\": 1\n//     }\n//   ],\n//   \"id\": \"e4e6cabe-2328-42f3-b4d9-d78da695d2ec\",\n//   \"quantity\": \"35.0000\"\n// }\n\n```\n\n### `options_orders`\n\nObtain list of history of option orders\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.options_orders((err, response, body) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            console.log(body);\n        }\n    });\n});\n```\n\n### `options_dates`\n\nObtain list of options expirations for a ticker\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.options_positions(\"MSFT\", (err, response, {tradable_chain_id, expiration_dates}) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            // Expiration dates is [\u003cDate String\u003e] ordered by asc date ([0] would be more recent than [1])\n            Robinhood.options_available(tradable_chain_id, expiration_dates[0])\n        }\n    });\n});\n```\n### `options_available`\n\nObtain list of options expirations for a ticker\n\n```typescript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.options_positions(\"MSFT\", (err, response, {tradable_chain_id, expiration_dates}) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            // Expiration dates is an array of date strings ordered by asc date ([0] would be more recent than [1])\n            // Tradable_chain_id respresents the options identifier for a ticker\n            Robinhood.options_available(tradable_chain_id, expiration_dates[0])\n        }\n    });\n});\n```\n\n### news(symbol, callback)\n\nReturn news about a symbol.\n\n### `get_currency_pairs`\n\nGet crypto - currency pairs\n\n```javascript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.get_currency_pairs((err, response, body) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            console.log(body);\n        }\n    });\n});\n```\n\n### `get_crypto`\n\nGet cryptocurrency quote information from symbol\n\n```javascript\nvar credentials = require(\"../credentials.js\")();\nvar Robinhood = require('robinhood')(credentials, function() {\n    Robinhood.get_crypto('DOGE', (err, response, body) =\u003e {\n        if (err) {\n            console.error(err);\n        } else {\n            console.log(body);\n        }\n    });\n});\n```\n\n`Documentation lacking sample response` **Feel like contributing? :)**\n\n# Contributors\n\nAlejandro U. Alvarez ([@aurbano](https://github.com/aurbano))\n------------------\n* Jesse Spencer ([@Jspenc72](https://github.com/jspenc72))\n* Justin Keller ([@nodesocket](https://github.com/nodesocket))\n* Wei-Sheng Su ([@ted7726](https://github.com/ted7726))\n* Dustin Moore ([@dustinmoorenet](https://github.com/dustinmoorenet))\n* Alex Ryan ([@ialexryan](https://github.com/ialexryan))\n* Ben Van Treese ([@vantreeseba](https://github.com/vantreeseba))\n* Zaheen ([@z123](https://github.com/z123))\n* Chris Busse ([@busse](https://github.com/busse))\n* Jason Truluck ([@jasontruluck](https://github.com/jasontruluck))\n* Matthew Herron ([@swimclan](https://github.com/swimclan))\n* Chris Dituri ([@cdituri](https://github.com/cdituri))\n* John Murphy ([@chiefsmurph](https://github.com/chiefsmurph))\n* Ryan Hendricks ([@ryanhendricks](https://github.com/ryanhendricks))\n* Patrick Michaelsen ([@prmichaelsen](https://github.com/prmichaelsen))\n* Joshua Wilborn ([@joshuajwilborn](https://github.com/joshuajwilborn))\n* Adrian Veliz ([@aveliz1999](https://github.com/aveliz1999))\n\n------------------\n\n# Related Projects\n\n* [robinhood-ruby](https://github.com/rememberlenny/robinhood-ruby) - RubyGem for interacting with Robinhood API\n* [robinhood Python](https://github.com/Jamonek/Robinhood) - Python Framework to make trades with Robinhood Private API\n\n------------------\n\n\u003eEven though this should be obvious: I am not affiliated in any way with Robinhood Financial LLC. I don't mean any harm or disruption in their service by providing this. Furthermore, I believe they are working on an amazing product, and hope that by publishing this NodeJS framework their users can benefit in even more ways from working with them.\n\n[![Analytics](https://ga-beacon.appspot.com/UA-3181088-16/robinhood/readme)](https://github.com/aurbano)\n\n\n## License\n[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Faurbano%2Frobinhood-node.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Faurbano%2Frobinhood-node?ref=badge_large)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faurbano%2Frobinhood-node","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faurbano%2Frobinhood-node","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faurbano%2Frobinhood-node/lists"}