pokemon_tcg_sdk 3.0.0 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.editorconfig +3 -0
- data/.gitignore +23 -24
- data/.travis.yml +15 -15
- data/CODE_OF_CONDUCT.md +48 -48
- data/Gemfile +4 -4
- data/LICENSE.txt +21 -21
- data/README.md +186 -159
- data/Rakefile +20 -10
- data/lib/pokemon_tcg_sdk.rb +38 -31
- data/lib/pokemon_tcg_sdk/ability.rb +14 -10
- data/lib/pokemon_tcg_sdk/ancient_trait.rb +13 -10
- data/lib/pokemon_tcg_sdk/attack.rb +16 -10
- data/lib/pokemon_tcg_sdk/card.rb +66 -42
- data/lib/pokemon_tcg_sdk/card_images.rb +13 -0
- data/lib/pokemon_tcg_sdk/configuration.rb +8 -8
- data/lib/pokemon_tcg_sdk/legalities.rb +14 -0
- data/lib/pokemon_tcg_sdk/query_builder.rb +63 -67
- data/lib/pokemon_tcg_sdk/rarity.rb +12 -0
- data/lib/pokemon_tcg_sdk/resistance.rb +14 -0
- data/lib/pokemon_tcg_sdk/rest_client.rb +43 -31
- data/lib/pokemon_tcg_sdk/set.rb +50 -40
- data/lib/pokemon_tcg_sdk/set_images.rb +13 -0
- data/lib/pokemon_tcg_sdk/subtype.rb +11 -11
- data/lib/pokemon_tcg_sdk/supertype.rb +11 -11
- data/lib/pokemon_tcg_sdk/tcgplayer.rb +44 -0
- data/lib/pokemon_tcg_sdk/type.rb +11 -11
- data/lib/pokemon_tcg_sdk/version.rb +3 -3
- data/lib/pokemon_tcg_sdk/weakness.rb +13 -0
- data/pokemon_tcg_sdk.gemspec +32 -33
- metadata +33 -47
- data/lib/pokemon_tcg_sdk/representers/ability_representer.rb +0 -11
- data/lib/pokemon_tcg_sdk/representers/ancient_trait_representer.rb +0 -10
- data/lib/pokemon_tcg_sdk/representers/attack_representer.rb +0 -13
- data/lib/pokemon_tcg_sdk/representers/card_representer.rb +0 -41
- data/lib/pokemon_tcg_sdk/representers/set_representer.rb +0 -19
- data/lib/pokemon_tcg_sdk/representers/type_value_representer.rb +0 -10
- data/lib/pokemon_tcg_sdk/type_value.rb +0 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: b9a3a1b3fc604371b4975e4dbda528bf2b6366a44e1a9930fb5e11f1712ced60
|
4
|
+
data.tar.gz: 986fc54f2c071fe2baebafb6406a239373cc43f270477550d93a0cc7c68a3412
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28f202b365875f9ab598e22ef1c079d4b767d7c22ffb362a11f456db2b80c25beb078398fbf81074b348075fa64f5f8f1c7d8552fe570aa5c1c9cb81a4da8fe7
|
7
|
+
data.tar.gz: 26d5f55ca9caad1b80733266abf265cbb49a69b94c290b4c3e6c9603e606fdfcfd35e6a66a85e29d5a17edb3e8ac14e2337116ec6e8286ff6c1f847773ac4794
|
data/.editorconfig
ADDED
data/.gitignore
CHANGED
@@ -1,25 +1,24 @@
|
|
1
|
-
*.gem
|
2
|
-
*.rbc
|
3
|
-
.bundle
|
4
|
-
.config
|
5
|
-
.yardoc
|
6
|
-
Gemfile.lock
|
7
|
-
InstalledFiles
|
8
|
-
_yardoc
|
9
|
-
coverage
|
10
|
-
doc/
|
11
|
-
lib/bundler/man
|
12
|
-
pkg
|
13
|
-
rdoc
|
14
|
-
spec/reports
|
15
|
-
test/tmp
|
16
|
-
test/version_tmp
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
*.
|
21
|
-
*.
|
22
|
-
*.
|
23
|
-
|
24
|
-
mkmf.log
|
1
|
+
*.gem
|
2
|
+
*.rbc
|
3
|
+
.bundle
|
4
|
+
.config
|
5
|
+
.yardoc
|
6
|
+
Gemfile.lock
|
7
|
+
InstalledFiles
|
8
|
+
_yardoc
|
9
|
+
coverage
|
10
|
+
doc/
|
11
|
+
lib/bundler/man
|
12
|
+
pkg
|
13
|
+
rdoc
|
14
|
+
spec/reports
|
15
|
+
test/tmp
|
16
|
+
test/version_tmp
|
17
|
+
coverage
|
18
|
+
tmp
|
19
|
+
*.bundle
|
20
|
+
*.so
|
21
|
+
*.o
|
22
|
+
*.a
|
23
|
+
mkmf.log
|
25
24
|
.vscode
|
data/.travis.yml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
-
env:
|
2
|
-
global:
|
3
|
-
- CC_TEST_REPORTER_ID=c14dfc2c8a10a029ac3706d2c2c86f63f663a1445df6213e013a42cbc9a55e74
|
4
|
-
language: ruby
|
5
|
-
rvm:
|
6
|
-
- 2.
|
7
|
-
before_install: gem install bundler -v 1.
|
8
|
-
before_script:
|
9
|
-
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
|
10
|
-
- chmod +x ./cc-test-reporter
|
11
|
-
- ./cc-test-reporter before-build
|
12
|
-
script:
|
13
|
-
- rake test
|
14
|
-
after_script:
|
15
|
-
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
|
1
|
+
env:
|
2
|
+
global:
|
3
|
+
- CC_TEST_REPORTER_ID=c14dfc2c8a10a029ac3706d2c2c86f63f663a1445df6213e013a42cbc9a55e74
|
4
|
+
language: ruby
|
5
|
+
rvm:
|
6
|
+
- 2.7.0
|
7
|
+
before_install: gem install bundler -v 2.1.4
|
8
|
+
before_script:
|
9
|
+
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
|
10
|
+
- chmod +x ./cc-test-reporter
|
11
|
+
- ./cc-test-reporter before-build
|
12
|
+
script:
|
13
|
+
- rake test
|
14
|
+
after_script:
|
15
|
+
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
|
data/CODE_OF_CONDUCT.md
CHANGED
@@ -1,49 +1,49 @@
|
|
1
|
-
# Contributor Code of Conduct
|
2
|
-
|
3
|
-
As contributors and maintainers of this project, and in the interest of
|
4
|
-
fostering an open and welcoming community, we pledge to respect all people who
|
5
|
-
contribute through reporting issues, posting feature requests, updating
|
6
|
-
documentation, submitting pull requests or patches, and other activities.
|
7
|
-
|
8
|
-
We are committed to making participation in this project a harassment-free
|
9
|
-
experience for everyone, regardless of level of experience, gender, gender
|
10
|
-
identity and expression, sexual orientation, disability, personal appearance,
|
11
|
-
body size, race, ethnicity, age, religion, or nationality.
|
12
|
-
|
13
|
-
Examples of unacceptable behavior by participants include:
|
14
|
-
|
15
|
-
* The use of sexualized language or imagery
|
16
|
-
* Personal attacks
|
17
|
-
* Trolling or insulting/derogatory comments
|
18
|
-
* Public or private harassment
|
19
|
-
* Publishing other's private information, such as physical or electronic
|
20
|
-
addresses, without explicit permission
|
21
|
-
* Other unethical or unprofessional conduct
|
22
|
-
|
23
|
-
Project maintainers have the right and responsibility to remove, edit, or
|
24
|
-
reject comments, commits, code, wiki edits, issues, and other contributions
|
25
|
-
that are not aligned to this Code of Conduct, or to ban temporarily or
|
26
|
-
permanently any contributor for other behaviors that they deem inappropriate,
|
27
|
-
threatening, offensive, or harmful.
|
28
|
-
|
29
|
-
By adopting this Code of Conduct, project maintainers commit themselves to
|
30
|
-
fairly and consistently applying these principles to every aspect of managing
|
31
|
-
this project. Project maintainers who do not follow or enforce the Code of
|
32
|
-
Conduct may be permanently removed from the project team.
|
33
|
-
|
34
|
-
This code of conduct applies both within project spaces and in public spaces
|
35
|
-
when an individual is representing the project or its community.
|
36
|
-
|
37
|
-
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
38
|
-
reported by contacting a project maintainer at backes.andrew@gmail.com. All
|
39
|
-
complaints will be reviewed and investigated and will result in a response that
|
40
|
-
is deemed necessary and appropriate to the circumstances. Maintainers are
|
41
|
-
obligated to maintain confidentiality with regard to the reporter of an
|
42
|
-
incident.
|
43
|
-
|
44
|
-
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
45
|
-
version 1.3.0, available at
|
46
|
-
[http://contributor-covenant.org/version/1/3/0/][version]
|
47
|
-
|
48
|
-
[homepage]: http://contributor-covenant.org
|
1
|
+
# Contributor Code of Conduct
|
2
|
+
|
3
|
+
As contributors and maintainers of this project, and in the interest of
|
4
|
+
fostering an open and welcoming community, we pledge to respect all people who
|
5
|
+
contribute through reporting issues, posting feature requests, updating
|
6
|
+
documentation, submitting pull requests or patches, and other activities.
|
7
|
+
|
8
|
+
We are committed to making participation in this project a harassment-free
|
9
|
+
experience for everyone, regardless of level of experience, gender, gender
|
10
|
+
identity and expression, sexual orientation, disability, personal appearance,
|
11
|
+
body size, race, ethnicity, age, religion, or nationality.
|
12
|
+
|
13
|
+
Examples of unacceptable behavior by participants include:
|
14
|
+
|
15
|
+
* The use of sexualized language or imagery
|
16
|
+
* Personal attacks
|
17
|
+
* Trolling or insulting/derogatory comments
|
18
|
+
* Public or private harassment
|
19
|
+
* Publishing other's private information, such as physical or electronic
|
20
|
+
addresses, without explicit permission
|
21
|
+
* Other unethical or unprofessional conduct
|
22
|
+
|
23
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
24
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
25
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
26
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
27
|
+
threatening, offensive, or harmful.
|
28
|
+
|
29
|
+
By adopting this Code of Conduct, project maintainers commit themselves to
|
30
|
+
fairly and consistently applying these principles to every aspect of managing
|
31
|
+
this project. Project maintainers who do not follow or enforce the Code of
|
32
|
+
Conduct may be permanently removed from the project team.
|
33
|
+
|
34
|
+
This code of conduct applies both within project spaces and in public spaces
|
35
|
+
when an individual is representing the project or its community.
|
36
|
+
|
37
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
38
|
+
reported by contacting a project maintainer at backes.andrew@gmail.com. All
|
39
|
+
complaints will be reviewed and investigated and will result in a response that
|
40
|
+
is deemed necessary and appropriate to the circumstances. Maintainers are
|
41
|
+
obligated to maintain confidentiality with regard to the reporter of an
|
42
|
+
incident.
|
43
|
+
|
44
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
45
|
+
version 1.3.0, available at
|
46
|
+
[http://contributor-covenant.org/version/1/3/0/][version]
|
47
|
+
|
48
|
+
[homepage]: http://contributor-covenant.org
|
49
49
|
[version]: http://contributor-covenant.org/version/1/3/0/
|
data/Gemfile
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
source 'https://rubygems.org'
|
2
|
-
|
3
|
-
# Specify your gem's dependencies in pokemon_tcg_sdk.gemspec
|
4
|
-
gemspec
|
1
|
+
source 'https://rubygems.org'
|
2
|
+
|
3
|
+
# Specify your gem's dependencies in pokemon_tcg_sdk.gemspec
|
4
|
+
gemspec
|
data/LICENSE.txt
CHANGED
@@ -1,21 +1,21 @@
|
|
1
|
-
The MIT License (MIT)
|
2
|
-
|
3
|
-
Copyright (c) 2016 Andrew Backes
|
4
|
-
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
7
|
-
in the Software without restriction, including without limitation the rights
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
10
|
-
furnished to do so, subject to the following conditions:
|
11
|
-
|
12
|
-
The above copyright notice and this permission notice shall be included in
|
13
|
-
all copies or substantial portions of the Software.
|
14
|
-
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
-
THE SOFTWARE.
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2016 Andrew Backes
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
CHANGED
@@ -1,159 +1,186 @@
|
|
1
|
-
# Pokémon TCG SDK
|
2
|
-
|
3
|
-
[![Gem Version](https://badge.fury.io/rb/pokemon_tcg_sdk.svg)](https://badge.fury.io/rb/pokemon_tcg_sdk)
|
4
|
-
[![Build Status](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby.svg?branch=master)](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby)
|
5
|
-
[![Dependency Status](https://gemnasium.com/badges/github.com/PokemonTCG/pokemon-tcg-sdk-ruby.svg)](https://gemnasium.com/github.com/PokemonTCG/pokemon-tcg-sdk-ruby)
|
6
|
-
[![Code Climate](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/badges/gpa.svg)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby)
|
7
|
-
[![Test Coverage](https://api.codeclimate.com/v1/badges/ee9d7d6ee5f8276729bc/test_coverage)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/test_coverage)
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
####
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
####
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
1
|
+
# Pokémon TCG SDK
|
2
|
+
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/pokemon_tcg_sdk.svg)](https://badge.fury.io/rb/pokemon_tcg_sdk)
|
4
|
+
[![Build Status](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby.svg?branch=master)](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby)
|
5
|
+
[![Dependency Status](https://gemnasium.com/badges/github.com/PokemonTCG/pokemon-tcg-sdk-ruby.svg)](https://gemnasium.com/github.com/PokemonTCG/pokemon-tcg-sdk-ruby)
|
6
|
+
[![Code Climate](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/badges/gpa.svg)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby)
|
7
|
+
[![Test Coverage](https://api.codeclimate.com/v1/badges/ee9d7d6ee5f8276729bc/test_coverage)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/test_coverage)
|
8
|
+
|
9
|
+
### Now supporting Version 2 of the Pokémon TCG API!
|
10
|
+
|
11
|
+
This is the Pokémon TCG SDK Ruby implementation. It is a wrapper around the Pokémon TCG API of [pokemontcg.io](http://pokemontcg.io/).
|
12
|
+
|
13
|
+
## Installation
|
14
|
+
|
15
|
+
Add this line to your application's Gemfile:
|
16
|
+
|
17
|
+
gem 'pokemon_tcg_sdk'
|
18
|
+
|
19
|
+
And then execute:
|
20
|
+
|
21
|
+
$ bundle
|
22
|
+
|
23
|
+
Or install it yourself as:
|
24
|
+
|
25
|
+
$ gem install pokemon_tcg_sdk
|
26
|
+
|
27
|
+
## Usage
|
28
|
+
|
29
|
+
To configure your API Key:
|
30
|
+
|
31
|
+
Pokemon.configure do |config|
|
32
|
+
config.api_key = "xxxxxxxxx"
|
33
|
+
end
|
34
|
+
|
35
|
+
### Classes
|
36
|
+
|
37
|
+
Card
|
38
|
+
Set
|
39
|
+
Type
|
40
|
+
Supertype
|
41
|
+
Subtype
|
42
|
+
Ability
|
43
|
+
AncientTrait
|
44
|
+
Attack
|
45
|
+
Resistance
|
46
|
+
Weakness
|
47
|
+
Legalities
|
48
|
+
Rarity
|
49
|
+
SetImages
|
50
|
+
CardImages
|
51
|
+
Tcgplayer
|
52
|
+
|
53
|
+
### Properties Per Class
|
54
|
+
|
55
|
+
#### Card
|
56
|
+
|
57
|
+
id
|
58
|
+
name
|
59
|
+
supertype
|
60
|
+
subtypes
|
61
|
+
level
|
62
|
+
hp
|
63
|
+
types
|
64
|
+
evolves_from
|
65
|
+
evolves_to
|
66
|
+
rules
|
67
|
+
ancient_trait
|
68
|
+
abilities
|
69
|
+
weaknesses
|
70
|
+
resistances
|
71
|
+
retreat_cost
|
72
|
+
converted_retreat_cost
|
73
|
+
set
|
74
|
+
number
|
75
|
+
artist
|
76
|
+
rarity
|
77
|
+
national_pokedex_numbers
|
78
|
+
legalities
|
79
|
+
tcgplayer
|
80
|
+
images
|
81
|
+
|
82
|
+
#### Set
|
83
|
+
|
84
|
+
id
|
85
|
+
name
|
86
|
+
series
|
87
|
+
printedTotal
|
88
|
+
total
|
89
|
+
legalities
|
90
|
+
ptcgo_code
|
91
|
+
release_date
|
92
|
+
updated_at
|
93
|
+
images
|
94
|
+
|
95
|
+
#### Ability
|
96
|
+
|
97
|
+
name
|
98
|
+
text
|
99
|
+
type
|
100
|
+
|
101
|
+
#### AncientTrait
|
102
|
+
|
103
|
+
name
|
104
|
+
text
|
105
|
+
|
106
|
+
#### Attack
|
107
|
+
|
108
|
+
cost
|
109
|
+
name
|
110
|
+
text
|
111
|
+
damage
|
112
|
+
converted_energy_cost
|
113
|
+
|
114
|
+
#### Weakness
|
115
|
+
|
116
|
+
type
|
117
|
+
value
|
118
|
+
|
119
|
+
#### Resistance
|
120
|
+
|
121
|
+
type
|
122
|
+
value
|
123
|
+
|
124
|
+
#### CardImages
|
125
|
+
|
126
|
+
small
|
127
|
+
large
|
128
|
+
|
129
|
+
#### SetImages
|
130
|
+
|
131
|
+
logo
|
132
|
+
symbol
|
133
|
+
|
134
|
+
### Functions Available
|
135
|
+
|
136
|
+
#### Find a card by id
|
137
|
+
|
138
|
+
card = Pokemon::Card.find('xy1-1')
|
139
|
+
|
140
|
+
#### Filter Cards via query parameters
|
141
|
+
|
142
|
+
cards = Pokemon::Card.where(q: 'set.name:generations subtypes:mega')
|
143
|
+
|
144
|
+
#### Find all cards (will take awhile)
|
145
|
+
|
146
|
+
cards = Pokemon::Card.all
|
147
|
+
|
148
|
+
#### Get all cards, but only a specific page of data
|
149
|
+
|
150
|
+
cards = Pokemon::Card.where(page: 5, pageSize: 100)
|
151
|
+
|
152
|
+
#### Find a set by code
|
153
|
+
|
154
|
+
set = Pokemon::Set.find('base1')
|
155
|
+
|
156
|
+
#### Filter sets via query parameters
|
157
|
+
|
158
|
+
sets = Pokemon::Set.where(q: 'legalities.standard:legal')
|
159
|
+
|
160
|
+
#### Get all Sets
|
161
|
+
|
162
|
+
sets = Pokemon::Set.all
|
163
|
+
|
164
|
+
#### Get all Types
|
165
|
+
|
166
|
+
types = Pokemon::Type.all
|
167
|
+
|
168
|
+
#### Get all Subtypes
|
169
|
+
|
170
|
+
subtypes = Pokemon::Subtype.all
|
171
|
+
|
172
|
+
#### Get all Supertypes
|
173
|
+
|
174
|
+
supertypes = Pokemon::Supertype.all
|
175
|
+
|
176
|
+
#### Get all Rarities
|
177
|
+
|
178
|
+
supertypes = Pokemon::Rarity.all
|
179
|
+
|
180
|
+
## Contributing
|
181
|
+
|
182
|
+
1. Fork it ( https://github.com/[my-github-username]/pokemon-tcg-sdk-ruby/fork )
|
183
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
184
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
185
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
186
|
+
5. Create a new Pull Request
|