Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 536d576

Browse files
authored
Updating README. (#9)
1 parent e3a9bb4 commit 536d576

File tree

1 file changed

+80
-2
lines changed

1 file changed

+80
-2
lines changed

README.md

Lines changed: 80 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,81 @@
1-
# segmentcli
1+
# Segment CLI
2+
3+
The Segment CLI (segmentcli) is a command line utility used to work with Analytics
4+
Live Plugins in your Segment work space.
5+
6+
```bash
7+
Usage: segmentcli <command> [options]
8+
9+
A command line utility to interact with and drive Segment
10+
11+
Groups:
12+
profile Work with stored profiles on this device
13+
analytics Send custom crafted events to Segment
14+
liveplugins Work with and develop analytics live plugins
15+
sources View and edit workspace sources
16+
17+
Commands:
18+
auth Authenticate with Segment.com and assign a profile name
19+
import Import CSV data into Segment from
20+
scaffold Create baseline implementation of a given code artifact
21+
repl Segment virtual development environment
22+
help Prints help information
23+
version Prints the current version of this app
24+
```
25+
26+
## Getting Started
27+
28+
In order to use the segmentcli to work with your workspace you must have the
29+
Analytics Live Plugins featured enabled in your workspace and you must
30+
authenticate with that workspace.
31+
32+
### Enabling the Analytics Live Plugins feature
33+
34+
Reach out to your Customer Support Engineer (CSE) or Customer Success Manager (CSM)
35+
to have them add this feature to your account.
36+
37+
The command to authenticate is as follows:
38+
39+
```bash
40+
$ segmentcli auth <ProfileName> <AuthToken>
41+
```
42+
43+
`ProfileName` - is the name you give to this workspace so you can distinguish
44+
between various local profiles.
45+
46+
`AuthToken` - is the AuthToken associated with your workspace. You must create
47+
an Auth token in your Segment workspace.
48+
49+
### Creating an Auth Token
50+
51+
1. Log into https://app.segment.com
52+
1. Navigate to Settings > Workspace Settings > Access Management > Tokens
53+
1. Generate a new token using the "Create token" button with the Workspace Owner role.
54+
55+
## Uploading Your Analytics Live Plugins to Your Workspace
56+
57+
In order to upload your Analytics Live Plugins you'll need the following command:
58+
59+
```bash
60+
$ segmentcli upload <SourceId> <FileName>
61+
```
62+
63+
`SourceId` - This is listed next your Write Key in the Segment app.
64+
`FileName` - The name of the JavaScript file containing your code.
65+
66+
Note: It will take a few minutes for your Source's setting payload to be update
67+
with the Analytics Live Plugin file URL.
68+
69+
### Finding Your SourceID
70+
71+
1. Log into https://app.segment.com
72+
1. Navigate to Connections > Sources
73+
1. Choose the source for which we're adding Analytics Live Plugins
74+
1. Navigate to Settings > API Keys
75+
1. You'll find the "Source ID" at the top of the page.
76+
77+
78+
## References
79+
80+
Learn more about Analytics Live Plugins for [Swift](https://github.com/segment-integrations/analytics-swift-live) and [Kotlin](https://github.com/segment-integrations/analytics-swift-live).
281

3-
A description of this package.

0 commit comments

Comments
 (0)