npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

alpaca-terminal

v2.0.2

Published

a command line terminal for trading with the Alpaca API

Downloads

17

Readme

alpaca-terminal

version code build prettier

a command line terminal for trading with the Alpaca API

Contents

Features

  • [x] View account information.
  • [x] Buy and sell stocks.
  • [x] Close positions with optional wildcards.
  • [x] Cancel orders with optional wildcards.
  • [x] View recent orders.
  • [x] View positions.

Install

From NPM:

$ npm i -g alpaca-terminal

Usage

Contents

Launching

Open the terminal with the alpaca or alpaca-terminal command.

alpaca-terminal 2.0.0
type help or ? to view commands
> help
help      [command]
config    [key] [value]
account   [field]
buy       <symbol> <qty> [tif] [limit_price]
sell      <symbol> <qty> [tif] [limit_price]
cancel    <symbol|order_id|*>
close     <symbol|*>
orders    [status]
positions
quit
>

Config

To view all options type config.

> config
credentials.key    xxxxxxxxxxxx
credentials.secret xxxxxxxxxxxxxxxxxxxxxxxx

To view a specific option type config <key>.

> config credentials.key
credentials.key xxxxxxxxxxxx

To set an option type config <key> <value>.

> config credentials.key mykey
credentials.key mykey

Buy

To buy a stock simply provide the symbol and amount.

> buy SPY 1
placed with ID 1184e1b7-2aa9-471e-8ec0-0981d1c35e4e

Sell

To sell a stock simply provide the symbol and amount.

> sell TSLA 1
placed with ID 1184e1b7-2aa9-471e-8ec0-0981d1c35e4e

Orders

To view your recent orders type orders, optionally you can type orders [status] to see specific order types.

symbol side qty price status   id
TSLA   buy  1   -     accepted a92af801-2c27-4f07-b55f-4861c29333d2

Aliases

Below are the command aliases available.

| Command | Aliases | | :---------- | :----------- | | help | h ? | | config | conf cfg | | account | acc a | | buy | b | | sell | s | | orders | o | | close | c | | cancel | ca | | positions | pos p | | quit | q |

To Do

More is coming! This project is early in development.

Contributing

Pull requests are encouraged. 🙂