Skip to content

Commit 8e6c988

Browse files
author
Uğur Özyılmazel
committed
Update README
1 parent 46abbdb commit 8e6c988

File tree

1 file changed

+48
-6
lines changed

1 file changed

+48
-6
lines changed

README.md

Lines changed: 48 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,23 +17,64 @@ from your terminal?
1717
1. You need to subscribe [scraper api][scraper-api], test drive is **free!!!**
1818
1. You need to set `PROMPTAPI_TOKEN` environment variable after subscription.
1919

20-
then;
20+
If you have `golang` environment installed, you can fetch via
2121

2222
```bash
23-
$ ...
23+
$ go get -u github.com/promptapi/scraper-cli
2424
```
2525

26+
Or you can download binaries from [releases][releases] page
27+
2628
---
2729

2830
## Usage
2931

30-
@wip
32+
```bash
33+
$ scraper-cli -h
34+
35+
usage: scraper-cli [flags...]
3136

32-
---
37+
scraper-cli is a command-line interface for Prompt API's Scraper API. Details
38+
can be found:
39+
40+
https://promptapi.com/marketplace/description/scraper-api
41+
42+
you need to signup for Prompt API to get your PROMPTAPI_TOKEN. you can signup
43+
from:
44+
45+
https://promptapi.com/#signup-form
46+
47+
application looks for PROMPTAPI_TOKEN environment variable. if you pass
48+
"token" flag, this will override environment variable lookup.
3349
34-
## Development
50+
required flag(s):
3551
36-
@wip
52+
-url web url/address to scrape
53+
54+
55+
optional flags:
56+
57+
-country 2 character country code
58+
-token promptapi apikey instead of PROMPTAPI_TOKEN env-var
59+
-username for HTTP Realm auth username
60+
-password for HTTP Realm auth password
61+
-cookie URL Encoded cookie header
62+
-referer HTTP referer header
63+
-selector CSS style selector path such as: a.btn div li
64+
-version display version information
65+
-help, -h display help
66+
67+
68+
examples:
69+
70+
$ scraper-cli -help
71+
$ scraper-cli -url "https://promptapi.com"
72+
$ scraper-cli -url "https://promptapi.com" -country "EE"
73+
$ scraper-cli -url "https://promptapi.com" -country "EE" -selector "a.btn div li"
74+
75+
$ PROMPTAPI_TOKEN="your-api-key" scraper-cli -url "https://promptapi.com"
76+
$ scraper-cli -url "https://promptapi.com" -token "your-api-key"
77+
```
3778
3879
---
3980
@@ -68,3 +109,4 @@ the [code of conduct][coc].
68109
[scraper-api]: https://promptapi.com/marketplace/description/scraper-api
69110
[promptapi-signup]: https://promptapi.com/#signup-form
70111
[coc]: https://github.com/promptapi/scraper-cli/blob/main/CODE_OF_CONDUCT.md
112+
[releases]: https://github.com/promptapi/scraper-cli/releases

0 commit comments

Comments
 (0)