cronos_explorer 0.1.1 → 0.2.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1fdd494b546057162a0b2a219bb3c4d3c6dfce2621f13dd3af7ff29b5b07835c
4
- data.tar.gz: cfe311b6ec6fdd9a05563d04d8fc69c217539bdaa687975a3e40ba83143e93c6
3
+ metadata.gz: af58d936fca6940d0ab7f209d293989e0a99d8e5075e940df9090b5be2bff42c
4
+ data.tar.gz: 5e62184416c5a778572956f39ff7e825b5e7c9e76672c52481761900bc8bfff9
5
5
  SHA512:
6
- metadata.gz: aa6106ea7635a3eef0b5eb0de642ceb62603975ed60212f3146c026def0ecc95a3451974cf243056bd2c0f393a206fbd50867c077e5b8eacf07f5c6beecf8753
7
- data.tar.gz: 32d600c443a866ef5779984d6926ed2243feb5eac5ce535616e13b4769b7ffc5dbc68bfdbbe937239ef034fab89900ff1784e51250551418fb787e669e5bf634
6
+ metadata.gz: b19362f1241f0e11808b51eb35d27a99b00524290af66da4d52210a1a7f8ddd4f7c3899f69bdf1daebab13cb0d372554c89366b835f3829d9acfd9e5a8fbb7b5
7
+ data.tar.gz: 1ec3e6b06ee16ddbdc537226d66b069f3a24269939f89ce5fd1bdeb2ccbbf86ba6b1fb663c1a4d038be6aa3348f6e53cef65fdd092448ea0b096aafe8a189c12
data/Gemfile.lock CHANGED
@@ -1,24 +1,44 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cronos_explorer (0.1.1)
5
- faraday (~> 2.0)
4
+ cronos_explorer (0.2.2)
5
+ faraday (~> 1.0)
6
6
  oj (~> 3.0)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- faraday (2.2.0)
12
- faraday-net_http (~> 2.0)
11
+ faraday (1.10.0)
12
+ faraday-em_http (~> 1.0)
13
+ faraday-em_synchrony (~> 1.0)
14
+ faraday-excon (~> 1.1)
15
+ faraday-httpclient (~> 1.0)
16
+ faraday-multipart (~> 1.0)
17
+ faraday-net_http (~> 1.0)
18
+ faraday-net_http_persistent (~> 1.0)
19
+ faraday-patron (~> 1.0)
20
+ faraday-rack (~> 1.0)
21
+ faraday-retry (~> 1.0)
13
22
  ruby2_keywords (>= 0.0.4)
14
- faraday-net_http (2.0.1)
23
+ faraday-em_http (1.0.0)
24
+ faraday-em_synchrony (1.0.0)
25
+ faraday-excon (1.1.0)
26
+ faraday-httpclient (1.0.1)
27
+ faraday-multipart (1.0.3)
28
+ multipart-post (>= 1.2, < 3)
29
+ faraday-net_http (1.0.1)
30
+ faraday-net_http_persistent (1.2.0)
31
+ faraday-patron (1.0.0)
32
+ faraday-rack (1.0.0)
33
+ faraday-retry (1.0.3)
15
34
  minitest (5.15.0)
35
+ multipart-post (2.1.1)
16
36
  oj (3.13.11)
17
37
  rake (13.0.6)
18
38
  ruby2_keywords (0.0.5)
19
39
 
20
40
  PLATFORMS
21
- x86_64-darwin-19
41
+ x86_64-darwin-20
22
42
 
23
43
  DEPENDENCIES
24
44
  bundler (~> 2.0)
@@ -27,4 +47,4 @@ DEPENDENCIES
27
47
  rake (~> 13.0)
28
48
 
29
49
  BUNDLED WITH
30
- 2.2.28
50
+ 2.2.19
data/README.md CHANGED
@@ -28,23 +28,8 @@ Or install it yourself as:
28
28
  CronosExplorer.net = 'testnet3' or CronosExplorer.net = 'main' (default)
29
29
  ```
30
30
 
31
- ```ruby
32
- CronosExplorer::Blocks.eth_block_number
33
-
34
- CronosExplorer::Contracts.listcontracts
35
-
36
- CronosExplorer::Accounts.eth_get_balance(@address)
37
- CronosExplorer::Accounts.balance(@address)
38
- CronosExplorer::Accounts.txlist(@address, starttimestamp)
39
- CronosExplorer::Accounts.tokenbalance(@contractaddress, @address)
40
-
41
- CronosExplorer::Transactions.gettxinfo(@txhash)
42
- CronosExplorer::Transactions.gettxreceiptstatus(@txhash)
43
- CronosExplorer::Transactions.getstatus(@txhash)
44
-
45
- CronosExplorer::Tokens.getToken(@contractaddress)
46
-
47
- CronosExplorer::Contracts.listcontracts
31
+ ```test
32
+ ruby test/*
48
33
  ```
49
34
 
50
35
  ## Development
@@ -55,4 +40,4 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
55
40
 
56
41
  ## Contributing
57
42
 
58
- Bug reports and pull requests are welcome on GitHub at https://github.com/menghuanwd/cronos_explorer.
43
+ Bug reports and pull requests are welcome on GitHub at https://github.com/gu-dave/cronos_explorer.
@@ -35,8 +35,8 @@ module CronosExplorer
35
35
  end
36
36
 
37
37
  # Get token transfer events by address. Up to a maximum of 10,000 token transfer events. Also available through a GraphQL 'token_transfers' query.
38
- def tokentx(address)
39
- hash = DEFAULT_HASH.merge(action: 'tokentx', address: address)
38
+ def tokentx(address, startblock, sort='desc')
39
+ hash = DEFAULT_HASH.merge(action: 'tokentx', address: address, startblock: startblock, sort: sort)
40
40
 
41
41
  Request.get hash
42
42
  end
@@ -1,6 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CronosExplorer
4
- VERSION = "0.1.1"
4
+ VERSION = "0.2.2"
5
5
  end
6
-
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cronos_explorer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
- - menghuanwd
7
+ - dave
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-04-09 00:00:00.000000000 Z
11
+ date: 2022-04-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.0'
19
+ version: '1.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '2.0'
26
+ version: '1.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: oj
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -80,9 +80,9 @@ dependencies:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
82
  version: '5.0'
83
- description: An unofficial simple gem For Cronos Chain API
83
+ description: An unofficial simple gem For Cronos Chain Explorer API
84
84
  email:
85
- - 651019063@qq.com
85
+ - dave.gu@crypto.com
86
86
  executables: []
87
87
  extensions: []
88
88
  extra_rdoc_files: []
@@ -93,7 +93,6 @@ files:
93
93
  - Rakefile
94
94
  - bin/console
95
95
  - bin/setup
96
- - cronos_explorer.gemspec
97
96
  - lib/cronos_explorer.rb
98
97
  - lib/cronos_explorer/accounts.rb
99
98
  - lib/cronos_explorer/blocks.rb
@@ -102,11 +101,11 @@ files:
102
101
  - lib/cronos_explorer/tokens.rb
103
102
  - lib/cronos_explorer/transactions.rb
104
103
  - lib/cronos_explorer/version.rb
105
- homepage: https://github.com/menghuanwd/cronos_explorer
104
+ homepage: https://github.com/gu-dave/cronos_explorer
106
105
  licenses: []
107
106
  metadata:
108
107
  allowed_push_host: https://rubygems.org
109
- homepage_uri: https://github.com/menghuanwd/cronos_explorer
108
+ homepage_uri: https://github.com/gu-dave/cronos_explorer
110
109
  post_install_message:
111
110
  rdoc_options: []
112
111
  require_paths:
@@ -122,7 +121,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
122
121
  - !ruby/object:Gem::Version
123
122
  version: '0'
124
123
  requirements: []
125
- rubygems_version: 3.0.6
124
+ rubygems_version: 3.0.3
126
125
  signing_key:
127
126
  specification_version: 4
128
127
  summary: A Ruby Gem For Cronos Chain
@@ -1,43 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative "lib/cronos_explorer/version"
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = "cronos_explorer"
7
- spec.version = CronosExplorer::VERSION
8
- spec.authors = ["menghuanwd"]
9
- spec.email = ["651019063@qq.com"]
10
-
11
- spec.summary = "A Ruby Gem For Cronos Chain"
12
- spec.description = "An unofficial simple gem For Cronos Chain API"
13
- spec.homepage = 'https://github.com/menghuanwd/cronos_explorer'
14
- spec.required_ruby_version = ">= 2.4.0"
15
-
16
- spec.metadata["allowed_push_host"] = 'https://rubygems.org'
17
-
18
- spec.metadata["homepage_uri"] = 'https://github.com/menghuanwd/cronos_explorer'
19
-
20
- # Specify which files should be added to the gem when it is released.
21
- # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
22
- spec.files = Dir.chdir(File.expand_path(__dir__)) do
23
- `git ls-files -z`.split("\x0").reject do |f|
24
- (f == __FILE__) || f.match(%r{\A(?:(?:test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
25
- end
26
- end
27
- spec.bindir = "exe"
28
- spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
29
- spec.require_paths = ["lib"]
30
-
31
- spec.add_dependency "faraday", "~> 2.0"
32
- spec.add_dependency "oj", "~> 3.0"
33
-
34
- spec.add_development_dependency "bundler", "~> 2.0"
35
- spec.add_development_dependency "rake", "~> 10.0"
36
- spec.add_development_dependency "minitest", "~> 5.0"
37
-
38
- # Uncomment to register a new dependency of your gem
39
- # spec.add_dependency "example-gem", "~> 1.0"
40
-
41
- # For more information and examples about making a new gem, checkout our
42
- # guide at: https://bundler.io/guides/creating_gem.html
43
- end