seo-keywords-generator-ruby 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +201 -0
- metadata +7 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c38ecba7df954f7912942b486e3108d0e6e5ce0c53cde20613948157c7ff8b3c
|
4
|
+
data.tar.gz: 6748a07aedb60d5c7b984ef4fc6817ff49f544a2efcaf33c6aa9b5ade68fcb95
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 55e4dba009d080c7836b983a39dd8721c771692de6622737c49b4dfa1daa1173384ef68fc32330a5600d330bd192e2444a62557b5abbffc2eb75011bdeb83c33
|
7
|
+
data.tar.gz: 99e557bae5bec18e308359a4da06e97a6f3498cb358677938809322dad951ab4ceaee53e0beb61debe2e54edbbc6fd3e7558e483769f77105314061b79dbd7fa
|
data/README.md
ADDED
@@ -0,0 +1,201 @@
|
|
1
|
+
<div align="center">
|
2
|
+
<p>Sponsor of the project:</p>
|
3
|
+
<div>
|
4
|
+
<img src="https://user-images.githubusercontent.com/78694043/231375638-5bbf2989-fc7b-482a-b6fe-603d1d6d613f.svg" width="90" alt="SerpApi">
|
5
|
+
</div>
|
6
|
+
<a href="https://serpapi.com">
|
7
|
+
<b>API to get search engine results with ease.</b>
|
8
|
+
</a>
|
9
|
+
</div>
|
10
|
+
|
11
|
+
<h2 align="center">
|
12
|
+
Ruby SEO Keywords Generator
|
13
|
+
</h2>
|
14
|
+
|
15
|
+
<p align="center">
|
16
|
+
Pull keyword ideas using Google Autocomplete, People Also Ask and Related Searches.
|
17
|
+
</p>
|
18
|
+
|
19
|
+
<div align="center">
|
20
|
+
<img src="https://user-images.githubusercontent.com/78694043/233605838-0e325f18-78d2-44eb-b937-d24d5a051ce1.svg" width="600" alt="seo-keywords-generator-ruby-logo">
|
21
|
+
</div>
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
This tool uses [SerpApi](https://serpapi.com/) as a tool to parse data from Google search results.
|
26
|
+
|
27
|
+
You can use provided API key that will be available after installation, however, it's purely for testing purposes to see if the tool fits your needs. If you'll be using it for your own purpose (personal or commercial), you have to use [your own SerpApi key](https://serpapi.com/manage-api-key).
|
28
|
+
|
29
|
+
|
30
|
+
## ⚙️Installation
|
31
|
+
|
32
|
+
```bash
|
33
|
+
$ gem install seo-keywords-generator-ruby
|
34
|
+
```
|
35
|
+
|
36
|
+
|
37
|
+
## 🤹♂️Usage
|
38
|
+
|
39
|
+
#### Available CLI arugments:
|
40
|
+
|
41
|
+
```bash
|
42
|
+
$ seo -h
|
43
|
+
```
|
44
|
+
|
45
|
+
```lang-none
|
46
|
+
Usage: seo [options]
|
47
|
+
-q, --query QUERY Search query (required)
|
48
|
+
-e, --engines ENGINES Choices of engines to extract: Autocomplete (ac), Related Searches (rs), People Also Ask (rq). You can select multiple engines by separating them with a comma: ac,rs. All engines are selected by default.
|
49
|
+
-d, --depth-limit LIMIT Depth limit for People Also Ask. Default is 0, first 2-4 results.
|
50
|
+
-s, --save-to SAVE Saves the results in the current directory in the selected format (CSV, JSON, TXT). Default CSV.
|
51
|
+
-k, --api-key KEY Your SerpApi API key: https://serpapi.com/manage-api-key. Default is a test API key to test CLI.
|
52
|
+
-g, --domain DOMAIN Google domain: https://serpapi.com/google-domains. Default google.com.
|
53
|
+
-c, --country COUNTRY Country of the search: https://serpapi.com/google-countries. Default us.
|
54
|
+
-l, --language LANGUAGE Language of the search: https://serpapi.com/google-languages. Default en.
|
55
|
+
```
|
56
|
+
|
57
|
+
The `--depth-limit` argument for People Also Ask can be set from `0` to `4`. For each depth limit value, the number of results returned grows exponentially. Below is a table showing how the depth limit argument is affected:
|
58
|
+
|
59
|
+
| Depth limit | Number of results | Explanation |
|
60
|
+
|-------------|-------------------|-------------|
|
61
|
+
| 0 | 4 | Standard results |
|
62
|
+
| 1 | 12 | 4*2 = 8 + 4 = 12 |
|
63
|
+
| 2 | 36 | 8*3 = 24 + 12 = 36 |
|
64
|
+
| 3 | 108 | 24*3 = 72 + 36 = 108 |
|
65
|
+
| 4 | 324 | 72*3 = 216 + 108 = 324 |
|
66
|
+
|
67
|
+
📌Note: This is how the logic works for the `google.com` domain, on other domains the results may differ.
|
68
|
+
|
69
|
+
#### Simple example:
|
70
|
+
|
71
|
+
```bash
|
72
|
+
$ seo -q "starbucks coffee"
|
73
|
+
```
|
74
|
+
|
75
|
+
```json
|
76
|
+
{
|
77
|
+
"auto_complete": [
|
78
|
+
"starbucks coffee menu",
|
79
|
+
"starbucks coffee sizes",
|
80
|
+
"starbucks coffee cups",
|
81
|
+
"starbucks coffee gear",
|
82
|
+
"starbucks coffee beans",
|
83
|
+
"starbucks coffee near me",
|
84
|
+
"starbucks coffee drinks",
|
85
|
+
"starbucks coffee mugs",
|
86
|
+
"starbucks coffee traveler",
|
87
|
+
"starbucks coffee price",
|
88
|
+
"starbucks coffee machine",
|
89
|
+
"starbucks coffee creamer",
|
90
|
+
"starbucks coffee pods",
|
91
|
+
"starbucks coffee recall",
|
92
|
+
"starbucks coffee flavors"
|
93
|
+
],
|
94
|
+
"related_searches": [
|
95
|
+
"starbucks near me",
|
96
|
+
"starbucks products",
|
97
|
+
"amazon starbucks coffee instant",
|
98
|
+
"starbucks logo",
|
99
|
+
"starbucks drinks",
|
100
|
+
"starbucks twitter",
|
101
|
+
"starbucks cups",
|
102
|
+
"starbucks facebook"
|
103
|
+
],
|
104
|
+
"related_questions": [
|
105
|
+
"What is best coffee in Starbucks?",
|
106
|
+
"What is the Starbucks drink for St Patrick's Day?",
|
107
|
+
"How do I order a regular coffee at Starbucks?",
|
108
|
+
"What kind of coffee does Starbucks make?"
|
109
|
+
]
|
110
|
+
}
|
111
|
+
```
|
112
|
+
|
113
|
+
#### Advanced example:
|
114
|
+
|
115
|
+
This example will use [related questions API](https://serpapi.com/related-questions) engine with a depth limit value of 2, and saves data to JSON:
|
116
|
+
|
117
|
+
```bash
|
118
|
+
$ seo --api-key "<your_serpapi_api_key>" \
|
119
|
+
> -q "starbucks coffee" \
|
120
|
+
> -e rq \
|
121
|
+
> -d 2 \
|
122
|
+
> -g google.co.uk \
|
123
|
+
> -c uk \
|
124
|
+
> -l en \
|
125
|
+
> -s json \
|
126
|
+
```
|
127
|
+
|
128
|
+
```json
|
129
|
+
{
|
130
|
+
"related_questions": [
|
131
|
+
"What is best coffee in Starbucks?",
|
132
|
+
"What is Starbucks coffee called?",
|
133
|
+
"Why is Starbucks famous for?",
|
134
|
+
"Is Starbucks coffee good quality coffee?",
|
135
|
+
"What is the most ordered drink at Starbucks?",
|
136
|
+
"Which Starbucks coffee is best for beginners?",
|
137
|
+
"What is the best choice in Starbucks?",
|
138
|
+
"What is a good thing to order at Starbucks?",
|
139
|
+
"What is Starbucks strongest coffee flavor?",
|
140
|
+
"What is the most basic Starbucks coffee?",
|
141
|
+
"Which Starbucks coffee is the least bitter?",
|
142
|
+
"What should I order for my first coffee?",
|
143
|
+
"Why is it called Starbuck?",
|
144
|
+
"Is Starbucks Italian or Spanish?",
|
145
|
+
"Why is Starbucks so expensive?",
|
146
|
+
"Who is the woman on the Starbucks logo?",
|
147
|
+
"Why is Starbucks called Grande?",
|
148
|
+
"What does Grande and Venti mean?",
|
149
|
+
"Why is a small Starbucks called tall?",
|
150
|
+
"What country is Starbucks most popular?",
|
151
|
+
"Why is Starbucks so expensive?",
|
152
|
+
"What is the most famous drink at Starbucks?",
|
153
|
+
"What is the most expensive thing in Starbucks?",
|
154
|
+
"What's cheaper Dunkin or Starbucks?",
|
155
|
+
"What are the weaknesses of Starbucks?",
|
156
|
+
"What is the most ordered drink in the world?",
|
157
|
+
"What is the most expensive Starbucks drink ever ordered?",
|
158
|
+
"What is the most ordered drink?",
|
159
|
+
"Which is the best quality coffee?",
|
160
|
+
"Is Starbucks and McDonald's coffee the same?",
|
161
|
+
"What is the number 1 coffee brand in the world?",
|
162
|
+
"What is the most popular coffee in the world?",
|
163
|
+
"What is the healthiest coffee to drink?",
|
164
|
+
"Is Starbucks coffee arabica or robusta?",
|
165
|
+
"Why is Starbucks coffee different?",
|
166
|
+
"What country owns Starbucks coffee?"
|
167
|
+
]
|
168
|
+
}
|
169
|
+
```
|
170
|
+
|
171
|
+
#### Example of manual data extraction (without CLI):
|
172
|
+
|
173
|
+
```ruby
|
174
|
+
require 'seo-keywords-generator-ruby'
|
175
|
+
|
176
|
+
keyword_research = SeoKeywordsGenerator.new(
|
177
|
+
query='starbucks coffee',
|
178
|
+
api_key='<your_serpapi_api_key>',
|
179
|
+
lang='en',
|
180
|
+
country='us',
|
181
|
+
domain='google.com'
|
182
|
+
)
|
183
|
+
|
184
|
+
auto_complete_results = keyword_research.get_auto_complete
|
185
|
+
related_searches_results = keyword_research.get_related_searches
|
186
|
+
related_questions_results = keyword_research.get_related_questions
|
187
|
+
|
188
|
+
data = {
|
189
|
+
auto_complete: auto_complete_results,
|
190
|
+
related_searches: related_searches_results,
|
191
|
+
related_questions: related_questions_results
|
192
|
+
}
|
193
|
+
|
194
|
+
keyword_research.save_to_csv(data)
|
195
|
+
keyword_research.print_data(data)
|
196
|
+
```
|
197
|
+
|
198
|
+
|
199
|
+
### ✍Contributing
|
200
|
+
|
201
|
+
Feel free to open bug issue, something isn't working, what feature to add, or anything else related to Google autocomplete, related searches or people also ask.
|
metadata
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: seo-keywords-generator-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Artur Chukhrai
|
8
8
|
- Dmitiry Zub
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-05-
|
12
|
+
date: 2023-05-03 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: google_search_results
|
@@ -34,13 +34,14 @@ executables: []
|
|
34
34
|
extensions: []
|
35
35
|
extra_rdoc_files: []
|
36
36
|
files:
|
37
|
+
- README.md
|
37
38
|
- bin/seo
|
38
39
|
- lib/seo-keywords-generator-ruby.rb
|
39
40
|
homepage: https://github.com/chukhraiartur/seo-keywords-generator-ruby
|
40
41
|
licenses:
|
41
42
|
- MIT
|
42
43
|
metadata: {}
|
43
|
-
post_install_message:
|
44
|
+
post_install_message:
|
44
45
|
rdoc_options: []
|
45
46
|
require_paths:
|
46
47
|
- lib
|
@@ -55,8 +56,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
55
56
|
- !ruby/object:Gem::Version
|
56
57
|
version: '0'
|
57
58
|
requirements: []
|
58
|
-
rubygems_version: 3.
|
59
|
-
signing_key:
|
59
|
+
rubygems_version: 3.3.26
|
60
|
+
signing_key:
|
60
61
|
specification_version: 4
|
61
62
|
summary: Ruby SEO Keywords Generator
|
62
63
|
test_files: []
|