{"_id":"58868811cc48960f002bd603","user":"578ef2353ac44e0e0095075c","version":{"_id":"582789aabe5c080f00a5a7fe","__v":10,"project":"568bdc1483d2061900d86cdc","createdAt":"2016-11-12T21:29:14.915Z","releaseDate":"2016-11-12T21:29:14.915Z","categories":["582789abbe5c080f00a5a7ff","582789abbe5c080f00a5a800","582789abbe5c080f00a5a801","582789abbe5c080f00a5a802","582789abbe5c080f00a5a803","582789abbe5c080f00a5a804","582789abbe5c080f00a5a805","582789abbe5c080f00a5a806","582789abbe5c080f00a5a807","582789abbe5c080f00a5a808","5827ea984ca29e0f00137a9e","583df597887db62f00644283","583df5d9c622791900e78da5","5845cd8763c11b250037967d","5845d13063c11b2500379681","5859e859e3306d1900126725","587aeb9a01cf3a0f008359eb","587c422af45e2d0f005e200d","587d84dc82f6f30f004ceee5"],"is_deprecated":false,"is_hidden":false,"is_beta":true,"is_stable":true,"codename":"beta2","version_clean":"0.0.0","version":"0"},"parentDoc":null,"__v":0,"category":{"_id":"582789abbe5c080f00a5a7ff","version":"582789aabe5c080f00a5a7fe","project":"568bdc1483d2061900d86cdc","__v":0,"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2016-01-05T15:07:02.028Z","from_sync":false,"order":0,"slug":"documentation","title":"Getting Started"},"project":"568bdc1483d2061900d86cdc","updates":[],"next":{"pages":[],"description":""},"createdAt":"2017-01-23T22:47:45.777Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":12,"body":"![box](https://app.box.com/shared/static/osrbwk8ulxccqankvxbrl4bhkyx41nkb.png)\n\n# Installation\n---\n\nFor information on installing the droplit CLI, see: [Install the Command Line Tools](doc:install-command-line-tools) \n\n```\nnpm install droplit-trace-cli -g\n```\n\n# Introduction\n---\n\nThe dropit.io Trace CLI is a cross platform command line tool that allows you to trace droplit.io events in real-time. It is build on the [droplit.io WebSocket SDK](https://docs.droplit.io/docs/websocket-sdk) The command line has been designed to be mostly self-documenting. If you run a command it will output any nested commands, command parameters, description and options.\n\nTo see a full list of top-level commands, simply run `droplit-trace` on the command line.\n\n![box](https://app.box.com/shared/static/0mg9kw2xjw6gq1qzm04p4cnesopb3n7y.png)\n\n# Setup\n---\n\nBefore using the CLI, you must login with your droplit.io Developer Account credentials (from [droplit.io portal](https://portal.droplit.io)) by running:\n\n```\ndroplit-trace account authenticate\n```\n\nIf you have authenticated using `droplit-cli` you do not have to authenticate again.\n\n# Using the CLI\n---\n\n## Subscribe\n\nYou can directly subscribe to resources by running:\n\n```\ndroplit-trace subscribe <resourceType> <resourceId>\n```\n![box](https://app.box.com/shared/static/ubjkht8imucf8j1xr3avqh8dnqu1ikcn.png)\n\n## Connect\n\nYou can run the trace command line in a interactive mode by running:\n\n```\ndroplit-trace connect\n```\n\n![box](https://app.box.com/shared/static/g96ryimv5yuu6e2ad53x15uefvo79d6c.png)\n\nOnce the WebSocket connection is open, you can subscribe to droplit.io resources.\n\n![box](https://app.box.com/shared/static/oezbfzwhg6dmlg3c8hyjfm3gdfrt0rfe.png)\n\nYou can close the running CLI by pressing `esc` and typing `close`.\n\n![box](https://app.box.com/shared/static/u6v5urtlxdcs4qomwrev8vstez11cifi.png)","excerpt":"Watch events happen in real-time","slug":"trace-command-line","type":"basic","title":"Trace Command Line"}

Trace Command Line

Watch events happen in real-time

![box](https://app.box.com/shared/static/osrbwk8ulxccqankvxbrl4bhkyx41nkb.png) # Installation --- For information on installing the droplit CLI, see: [Install the Command Line Tools](doc:install-command-line-tools) ``` npm install droplit-trace-cli -g ``` # Introduction --- The dropit.io Trace CLI is a cross platform command line tool that allows you to trace droplit.io events in real-time. It is build on the [droplit.io WebSocket SDK](https://docs.droplit.io/docs/websocket-sdk) The command line has been designed to be mostly self-documenting. If you run a command it will output any nested commands, command parameters, description and options. To see a full list of top-level commands, simply run `droplit-trace` on the command line. ![box](https://app.box.com/shared/static/0mg9kw2xjw6gq1qzm04p4cnesopb3n7y.png) # Setup --- Before using the CLI, you must login with your droplit.io Developer Account credentials (from [droplit.io portal](https://portal.droplit.io)) by running: ``` droplit-trace account authenticate ``` If you have authenticated using `droplit-cli` you do not have to authenticate again. # Using the CLI --- ## Subscribe You can directly subscribe to resources by running: ``` droplit-trace subscribe <resourceType> <resourceId> ``` ![box](https://app.box.com/shared/static/ubjkht8imucf8j1xr3avqh8dnqu1ikcn.png) ## Connect You can run the trace command line in a interactive mode by running: ``` droplit-trace connect ``` ![box](https://app.box.com/shared/static/g96ryimv5yuu6e2ad53x15uefvo79d6c.png) Once the WebSocket connection is open, you can subscribe to droplit.io resources. ![box](https://app.box.com/shared/static/oezbfzwhg6dmlg3c8hyjfm3gdfrt0rfe.png) You can close the running CLI by pressing `esc` and typing `close`. ![box](https://app.box.com/shared/static/u6v5urtlxdcs4qomwrev8vstez11cifi.png)