bwcli 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +96 -0
- data/lib/bwcli/version.rb +1 -1
- metadata +1 -2
- data/lib/bwcli/.DS_Store +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9e15631f5cdedfa5c88e9af176bda6b7194663b0
|
4
|
+
data.tar.gz: c27fdb56c9a3f429df0ba250ffc5090dcc973a51
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c97aaf895b4ffd8e10cea2e971235764d286259ff8310d2f2b67cdd1a4b1a6313630efb3e11b3cf490390749d692819921e400c714b5ddc1138cbbc573b805e8
|
7
|
+
data.tar.gz: 17c7f4491173aa6d7322e1b4b9f5d2bf997fc728142ff5c406b69cca76645109a89bab42646c8c366fd7cc88f4940b55bf10c2ec521442cc26a32e85a56e4041
|
data/README.md
CHANGED
@@ -9,3 +9,99 @@ __PLEASE NOTE THAT THIS PROJECT IS NOT OFFICIALLY SUPPORTED BY BRANDWATCH__
|
|
9
9
|
A command line interface to interact with the Brandwatch API
|
10
10
|
|
11
11
|
|
12
|
+
## Documentation
|
13
|
+
http://rubydoc.info/gems/bwcli/
|
14
|
+
|
15
|
+
## Getting Started
|
16
|
+
|
17
|
+
In order to interact with the `BWAPI` from the command line we first need to setup a current user in the `.bwcli` config file. Please note that the config file enables us to hold multiple users which we can easily switch between.
|
18
|
+
|
19
|
+
### Add new user to config
|
20
|
+
|
21
|
+
In order to use `bwcli` you need to have a `.bwcli` file in your root directory, don't worry I've got your back. When you create a new user the file will be created automatically. So, to get the show on the road add a user to your config file:
|
22
|
+
|
23
|
+
```ruby
|
24
|
+
bwcli config add -u username@domain.com -p your_password -e enviroment
|
25
|
+
```
|
26
|
+
|
27
|
+
When you create a user for the first time `bwcli` will automatically set this user as your `current user`. When you add new users to your config, `bwcli` will ask whether you want to set this user as your current user.
|
28
|
+
|
29
|
+
### View user config
|
30
|
+
|
31
|
+
Returns the users currently stored in the config file along with the current user if set.
|
32
|
+
|
33
|
+
```ruby
|
34
|
+
bwcli config list
|
35
|
+
```
|
36
|
+
|
37
|
+
### Set current user
|
38
|
+
|
39
|
+
Sets the user as the current user. The `set` or `switch` command can be used.
|
40
|
+
|
41
|
+
```ruby
|
42
|
+
bwcli config set -u anotheruser@domain -e environment
|
43
|
+
```
|
44
|
+
|
45
|
+
### Remove user
|
46
|
+
|
47
|
+
Removes the specific user from the config file, no warning is given.
|
48
|
+
|
49
|
+
```ruby
|
50
|
+
bwcli config remove -u anotheruser@domain -e environment
|
51
|
+
```
|
52
|
+
|
53
|
+
### View current user
|
54
|
+
|
55
|
+
Returns the current user set in the config file.
|
56
|
+
|
57
|
+
```ruby
|
58
|
+
bwcli config user
|
59
|
+
```
|
60
|
+
|
61
|
+
### Authenticate current user
|
62
|
+
|
63
|
+
Please note that when ever you make a request to an endpoint `bwcli` will ensure you are authenticated with brandwatch so the login command doesn't need to run everytime.
|
64
|
+
|
65
|
+
```ruby
|
66
|
+
bwcli config login
|
67
|
+
```
|
68
|
+
|
69
|
+
### Reset user config
|
70
|
+
|
71
|
+
Wipe your config file and restart, warning is given and the user must respond with a `yes` or `y` to confirm.
|
72
|
+
|
73
|
+
```ruby
|
74
|
+
bwcli config reset
|
75
|
+
```
|
76
|
+
|
77
|
+
## Next Steps
|
78
|
+
|
79
|
+
Once you have your current user setup you can make API requests to Brandwatch. Currently at present only the `me` and `projects` endpoint are implemented.
|
80
|
+
|
81
|
+
### Me Endpoint
|
82
|
+
|
83
|
+
Returns user information.
|
84
|
+
|
85
|
+
```ruby
|
86
|
+
bwcli me
|
87
|
+
```
|
88
|
+
|
89
|
+
### All Projects
|
90
|
+
|
91
|
+
Returns all projects the user currently has shared.
|
92
|
+
|
93
|
+
|
94
|
+
```ruby
|
95
|
+
bwcli projects
|
96
|
+
```
|
97
|
+
|
98
|
+
### Specific Projects
|
99
|
+
|
100
|
+
Returns the specific project specified, user must pass option for `-i` parameter.
|
101
|
+
|
102
|
+
```ruby
|
103
|
+
bwcli projects -i 12345678
|
104
|
+
```
|
105
|
+
|
106
|
+
## Feedback
|
107
|
+
I would be more than happy to recieve feedback, please email me at: jonathan.chrisp@gmail.com or jonathan@brandwatch.com
|
data/lib/bwcli/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bwcli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonathan Chrisp
|
@@ -108,7 +108,6 @@ files:
|
|
108
108
|
- bin/bwcli
|
109
109
|
- bwcli.gemspec
|
110
110
|
- lib/bwcli.rb
|
111
|
-
- lib/bwcli/.DS_Store
|
112
111
|
- lib/bwcli/config.rb
|
113
112
|
- lib/bwcli/configuration.rb
|
114
113
|
- lib/bwcli/me.rb
|
data/lib/bwcli/.DS_Store
DELETED
Binary file
|