bigcommerce_api 0.6.2 → 0.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +8 -2
- data/lib/bigcommerce_api/sku.rb +8 -3
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 01abb5cc7c76c570309b4e94698f1c24e4a5c59f
|
|
4
|
+
data.tar.gz: a6a7cd9349a3092e189a9642c5d71a7692409bb1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 94507ff8220f1d9785d0dbd72c38b84c6cd175c01672b883cd0cade6d3604aeddca24da80affd2a825e73c6a7e0ce19c1d604f65465c6d67e59ca7394669b706
|
|
7
|
+
data.tar.gz: 2ababf2435e4cebd995a33209b0f0dc54436afb85407d0eac6fb005810c554bb1f4fb06849283a7691579a1c61e9e99f770a388e782404da2ad76cf26d5de3b3
|
data/README.md
CHANGED
|
@@ -47,7 +47,7 @@ api = BigcommerceAPI::Base.new(
|
|
|
47
47
|
)
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
Or using the new OAuth credentials
|
|
50
|
+
Or using the new OAuth credentials:
|
|
51
51
|
```
|
|
52
52
|
api = BigcommerceAPI::Base.new(
|
|
53
53
|
:client_id => APP_CLIENT_ID,
|
|
@@ -59,11 +59,17 @@ api = BigcommerceAPI::Base.new(
|
|
|
59
59
|
You can test your connection by getting the time
|
|
60
60
|
|
|
61
61
|
```
|
|
62
|
-
|
|
62
|
+
api.time
|
|
63
63
|
```
|
|
64
64
|
|
|
65
65
|
A valid time means your connection and credentials are good.
|
|
66
66
|
|
|
67
|
+
You can also get your store info settings via the 'api' instance:
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
api.store
|
|
71
|
+
```
|
|
72
|
+
|
|
67
73
|
### Usage
|
|
68
74
|
|
|
69
75
|
The API currently gives you read/write access to MOST of your Big Commerce API V2 resources (https://developer.bigcommerce.com/docs/api/v2)
|
data/lib/bigcommerce_api/sku.rb
CHANGED
|
@@ -27,9 +27,14 @@ module BigcommerceAPI
|
|
|
27
27
|
end
|
|
28
28
|
|
|
29
29
|
def option_value
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
po = self.product_option
|
|
31
|
+
if po # we've got to have a product option for this to work
|
|
32
|
+
option_id = po.option_id
|
|
33
|
+
ov = BigcommerceAPI::Base.get '/options/' + option_id.to_s + '/values/' + self.option_value_id.to_s
|
|
34
|
+
(ov.success? and !ov.nil?) ? OptionValue.new(ov) : nil
|
|
35
|
+
else
|
|
36
|
+
return nil
|
|
37
|
+
end
|
|
33
38
|
end
|
|
34
39
|
|
|
35
40
|
def description
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: bigcommerce_api
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.6.
|
|
4
|
+
version: 0.6.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Mark Dickson
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2015-02-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|