santander_chile-api_client 0.0.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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 4181a35bfe455c8109971d8b3e0e17b8708336c2eea5bb5ce5e8c3c99d6ad425
4
+ data.tar.gz: 2c322570559efe7d938431962a572554e4b942e2bebf1463575965d757e8fa1a
5
+ SHA512:
6
+ metadata.gz: c7b564818a9c5b5ee9fec659f425e7f505a2d2ad40d883b6f9483272724eda5738cf2e036d316f7839dab4b9417bca6d1cfd04f30fab782ade51292780a8a5c8
7
+ data.tar.gz: 11a6c3f3efa1ed715c8a9f34b86243ef5494ec80bd6b41eb262f0c99267103d2276591456170bc01931835d31d036f4ad70b18e1d348e978502904a4f7979c7d
data/.gitignore ADDED
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /pkg/
7
+ /spec/reports/
8
+ /tmp/
9
+
10
+ # rspec failure tracking
11
+ .rspec_status
12
+ .env
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --format documentation
2
+ --color
3
+ --require spec_helper
data/.travis.yml ADDED
@@ -0,0 +1,6 @@
1
+ ---
2
+ language: ruby
3
+ cache: bundler
4
+ rvm:
5
+ - 2.7.2
6
+ before_install: gem install bundler -v 2.1.4
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at jamendoza@uc.cl. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [https://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: https://contributor-covenant.org
74
+ [version]: https://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,10 @@
1
+ source "https://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in santander_chile-api_client.gemspec
4
+ gemspec
5
+
6
+ gem "rake", "~> 12.0"
7
+ gem "rspec", "~> 3.0"
8
+ gem "faraday", "~> 1.7"
9
+ gem "faraday_middleware", "~> 1.1"
10
+ gem "dotenv", "~> 2.1"
data/Gemfile.lock ADDED
@@ -0,0 +1,63 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ santander_chile-api_client (0.0.2)
5
+ faraday (~> 1.7)
6
+ faraday_middleware (~> 1.1)
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ diff-lcs (1.4.4)
12
+ dotenv (2.7.6)
13
+ faraday (1.7.1)
14
+ faraday-em_http (~> 1.0)
15
+ faraday-em_synchrony (~> 1.0)
16
+ faraday-excon (~> 1.1)
17
+ faraday-httpclient (~> 1.0.1)
18
+ faraday-net_http (~> 1.0)
19
+ faraday-net_http_persistent (~> 1.1)
20
+ faraday-patron (~> 1.0)
21
+ faraday-rack (~> 1.0)
22
+ multipart-post (>= 1.2, < 3)
23
+ ruby2_keywords (>= 0.0.4)
24
+ faraday-em_http (1.0.0)
25
+ faraday-em_synchrony (1.0.0)
26
+ faraday-excon (1.1.0)
27
+ faraday-httpclient (1.0.1)
28
+ faraday-net_http (1.0.1)
29
+ faraday-net_http_persistent (1.2.0)
30
+ faraday-patron (1.0.0)
31
+ faraday-rack (1.0.0)
32
+ faraday_middleware (1.1.0)
33
+ faraday (~> 1.0)
34
+ multipart-post (2.1.1)
35
+ rake (12.3.3)
36
+ rspec (3.10.0)
37
+ rspec-core (~> 3.10.0)
38
+ rspec-expectations (~> 3.10.0)
39
+ rspec-mocks (~> 3.10.0)
40
+ rspec-core (3.10.1)
41
+ rspec-support (~> 3.10.0)
42
+ rspec-expectations (3.10.1)
43
+ diff-lcs (>= 1.2.0, < 2.0)
44
+ rspec-support (~> 3.10.0)
45
+ rspec-mocks (3.10.2)
46
+ diff-lcs (>= 1.2.0, < 2.0)
47
+ rspec-support (~> 3.10.0)
48
+ rspec-support (3.10.2)
49
+ ruby2_keywords (0.0.5)
50
+
51
+ PLATFORMS
52
+ ruby
53
+
54
+ DEPENDENCIES
55
+ dotenv (~> 2.1)
56
+ faraday (~> 1.7)
57
+ faraday_middleware (~> 1.1)
58
+ rake (~> 12.0)
59
+ rspec (~> 3.0)
60
+ santander_chile-api_client!
61
+
62
+ BUNDLED WITH
63
+ 2.1.4
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2021 Jerry Mendoza
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 ADDED
@@ -0,0 +1,71 @@
1
+ # Santander Chile Ruby API Client
2
+
3
+ Unofficial Client for Santander Bank Chile API.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'santander_chile-api_client'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle install
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install santander_chile-api_client
20
+
21
+ ## Usage
22
+ ### Configuration
23
+ ```rb
24
+ client = SantanderChile::ApiClient::Client.new do |config|
25
+ config.client_id = '<CLIENT_ID>'
26
+ end
27
+ ```
28
+
29
+ ### Login
30
+ ```rb
31
+ client.login(
32
+ username: "00123456781", #12.345.678-1
33
+ password: "XXXX",
34
+ )
35
+ ```
36
+
37
+ ### Resources
38
+
39
+ #### Products (accounts)
40
+ ```rb
41
+ results = client.products.list
42
+ #=> SantanderChile::ApiClient::Collection
43
+
44
+ results.data
45
+ #=> [#<SantanderChile::ApiClient::Account>, #<SantanderChile::ApiClient::Account:>]
46
+ ```
47
+ ### Todo
48
+ - [x] ~~Products (accounts)~~
49
+ - [ ] Balance
50
+ - [ ] Transactions
51
+ - [ ] Transfers
52
+ - [ ] Payments
53
+
54
+ ## Development
55
+
56
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
57
+
58
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
59
+
60
+ ## Contributing
61
+
62
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/santander_chile-api_client. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/[USERNAME]/santander_chile-api_client/blob/master/CODE_OF_CONDUCT.md).
63
+
64
+
65
+ ## License
66
+
67
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
68
+
69
+ ## Code of Conduct
70
+
71
+ Everyone interacting in the SantanderChile::ApiClient project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/santander_chile-api_client/blob/master/CODE_OF_CONDUCT.md).
data/Rakefile ADDED
@@ -0,0 +1,6 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "santander_chile/api_client"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,41 @@
1
+ require "ostruct"
2
+
3
+ module SantanderChile
4
+ module ApiClient
5
+ class Client
6
+ module Authentication
7
+ attr_accessor :token, :username
8
+ HEADERS = {
9
+ "app" => "007",
10
+ "canal" => "003",
11
+ "nro_ser" => "",
12
+ }
13
+
14
+ def login(username:, password:, grant_type: "password")
15
+ self.username = username
16
+ self.token = oauth_token(
17
+ grant_type: grant_type,
18
+ client_id: config.client_id,
19
+ scope: "Completa",
20
+ username: username,
21
+ password: password,
22
+ )
23
+ self.token
24
+ end
25
+
26
+ private
27
+
28
+ def oauth_token(**body)
29
+ response = connection(host: AUTH_BASE_URL).post(
30
+ "oauth2/token",
31
+ body: body,
32
+ headers: HEADERS,
33
+ login: true,
34
+ )
35
+
36
+ return Token.new(response.body)
37
+ end
38
+ end
39
+ end
40
+ end
41
+ end
@@ -0,0 +1,23 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Client
4
+ class Configuration
5
+ ATTRIBUTES = %i[
6
+ client_id
7
+ faraday
8
+ ].freeze
9
+ attr_accessor(*ATTRIBUTES)
10
+
11
+ def initialize
12
+ self.faraday = ->(faraday) { }
13
+ end
14
+
15
+ def validate!
16
+ ATTRIBUTES.each do |key|
17
+ raise "Missing config value for `#{key}`!" if instance_variable_get("@#{key}").nil?
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,34 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Client
4
+ class Connection
5
+ def initialize(client:, host:)
6
+ @client = client
7
+ @host = host
8
+ end
9
+
10
+ attr_accessor :client, :host
11
+
12
+ def post(path, body:, headers: {}, login: false)
13
+ response = faraday(login: login).post(path, body, headers) do |request|
14
+ if !login
15
+ request.headers = { "access-token" => @client.token.tokenJWT }.merge(headers)
16
+ end
17
+ end
18
+ end
19
+
20
+ def faraday(login)
21
+ Faraday.new(url: host) do |config|
22
+ config.request :url_encoded if login
23
+ config.request :oauth2, client.token.access_token, token_type: :bearer if client.token # TODO check token timeout
24
+ config.request :json if !login
25
+ config.response :raise_error
26
+ config.response :json, content_type: "application/json"
27
+ client.config.faraday.call(config)
28
+ config.adapter Faraday.default_adapter
29
+ end
30
+ end
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,21 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Collection
4
+ attr_reader :data
5
+
6
+ def initialize(data:)
7
+ @data = data
8
+ end
9
+
10
+ def self.from_response(response, keys_to:, type:)
11
+ body = response.body
12
+ new(
13
+ data: body.dig(*keys_to).map {
14
+ |attrs|
15
+ type.new(attrs)
16
+ },
17
+ )
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,18 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ AUTH_BASE_URL = "https://apideveloper.santander.cl/sancl/privado/Cliente/v1/"
4
+ BASE_URL = "https://apiper.santander.cl/appper/facade/"
5
+ PRODUCTS = {
6
+ "PATH": "CruceProductoOnline",
7
+ "KEYS_TO": ["DATA", "OUTPUT", "MATRICES", "MATRIZCAPTACIONES", "e1"],
8
+ }
9
+ BALANCE = {
10
+ "PATH": "ConsultaSaldo",
11
+ "KEYS_TO": ["DATA", "AS_TIB_Consulta_Saldo_Response", "OUTPUT", "ESCALARES"],
12
+ }
13
+ TRANSACTIONS = {
14
+ "PATH": "MvtosYDeposiDocCtas",
15
+ "KEYS_TO": [],
16
+ }
17
+ end
18
+ end
@@ -0,0 +1 @@
1
+ class Error < StandardError; end
@@ -0,0 +1,13 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Account < Object
4
+ ATTRIBUTES = { "account_number" => "NUMEROCONTRATO",
5
+ "product" => "PRODUCTO",
6
+ "subproduct" => "SUBPRODUCTO",
7
+ "balance" => "CUPO",
8
+ "balance_available" => "MONTODISPONIBLE" }
9
+
10
+ attr_accessor(*ATTRIBUTES.keys.map { |x| x.to_sym })
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,11 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Object
4
+ def initialize(attrs)
5
+ self.class::ATTRIBUTES.each { |key, value|
6
+ instance_variable_set("@#{key}", attrs[value])
7
+ }
8
+ end
9
+ end
10
+ end
11
+ end
@@ -0,0 +1,18 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class ProductsResource < Resource
4
+ ## PATHS on santander_chile/api_client/endpoints.rb
5
+ def products_params(username)
6
+ {
7
+ "cabecera" => { "RutUsuario" => username },
8
+ "INPUT" => { "NUMERODOCUMENTO" => username },
9
+ }
10
+ end
11
+
12
+ def list(**params)
13
+ response = post_request(PRODUCTS[:PATH], body: products_params(@client.username).to_json)
14
+ Collection.from_response(response, keys_to: PRODUCTS[:KEYS_TO], type: Account)
15
+ end
16
+ end
17
+ end
18
+ end
@@ -0,0 +1,38 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Resource
4
+ attr_reader :client
5
+
6
+ def initialize(client)
7
+ @client = client
8
+ end
9
+
10
+ private
11
+
12
+ def post_request(url, body: {}, headers: { "Content-Type" => "application/json" })
13
+ handle_response client.connection.post(url, body: body, headers: headers)
14
+ end
15
+
16
+ def handle_response(response)
17
+ case response.status
18
+ when 400
19
+ raise Error, "Your request was malformed. #{response.body["error"]}"
20
+ when 401
21
+ raise Error, "You did not supply valid authentication credentials. #{response.body["error"]}"
22
+ when 403
23
+ raise Error, "You are not allowed to perform that action. #{response.body["error"]}"
24
+ when 404
25
+ raise Error, "No results were found for your request. #{response.body["error"]}"
26
+ #when 429
27
+ # raise Error, "Your request exceeded the API rate limit. #{response.body["error"]}"
28
+ when 500
29
+ raise Error, "We were unable to perform the request due to server-side problems. #{response.body["error"]}"
30
+ #when 503
31
+ # raise Error, "You have been rate limited for sending more than X requests per second. #{response.body["error"]}"
32
+ end
33
+
34
+ response
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,28 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ class Token
4
+ ATTRIBUTES = %i[
5
+ access_token
6
+ expires_in
7
+ token_type
8
+ refresh_token
9
+ refresh_token_expires_in
10
+ tokenJWT
11
+ ].freeze
12
+
13
+ attr_accessor(*ATTRIBUTES)
14
+
15
+ def initialize(args = {})
16
+ args.to_h.each do |key, value|
17
+ next unless ATTRIBUTES.include?(key.to_sym)
18
+
19
+ instance_variable_set("@#{key}", value)
20
+ end
21
+ end
22
+
23
+ def to_h
24
+ Hash[ATTRIBUTES.map { |key| [key, instance_variable_get("@#{key}")] }]
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,5 @@
1
+ module SantanderChile
2
+ module ApiClient
3
+ VERSION = "0.0.2"
4
+ end
5
+ end
@@ -0,0 +1,41 @@
1
+ require "faraday"
2
+ require "faraday_middleware"
3
+ require "santander_chile/api_client/version"
4
+ require "santander_chile/api_client/endpoints"
5
+
6
+ module SantanderChile
7
+ module ApiClient
8
+ autoload :Error, "santander_chile/api_client/error"
9
+ autoload :Token, "santander_chile/api_client/token"
10
+
11
+ autoload :Object, "santander_chile/api_client/models/object"
12
+ autoload :Account, "santander_chile/api_client/models/account"
13
+ autoload :Collection, "santander_chile/api_client/collection"
14
+
15
+ autoload :Resource, "santander_chile/api_client/resources/resource"
16
+ autoload :ProductsResource, "santander_chile/api_client/resources/products"
17
+
18
+ class Client
19
+ autoload :Configuration, "santander_chile/api_client/client/configuration"
20
+ autoload :Connection, "santander_chile/api_client/client/connection"
21
+ autoload :Authentication, "santander_chile/api_client/client/authentication"
22
+
23
+ include Authentication
24
+ attr_accessor :config
25
+
26
+ def initialize
27
+ self.config = Configuration.new
28
+ yield(config) if block_given?
29
+ config.validate!
30
+ end
31
+
32
+ def connection(host: BASE_URL)
33
+ Connection.new(client: self, host: host)
34
+ end
35
+
36
+ def products
37
+ ProductsResource.new(self)
38
+ end
39
+ end
40
+ end
41
+ end
@@ -0,0 +1,31 @@
1
+ require_relative "lib/santander_chile/api_client/version"
2
+
3
+ Gem::Specification.new do |spec|
4
+ spec.name = "santander_chile-api_client"
5
+ spec.version = SantanderChile::ApiClient::VERSION
6
+ spec.authors = ["Jerry Mendoza"]
7
+ spec.email = ["jamendoza@uc.cl"]
8
+
9
+ spec.summary = %q{Unofficial Client for Santander Bank Chile API.}
10
+ spec.description = spec.summary
11
+ spec.homepage = "https://github.com/jerrymendoza/santander_chile-api_client-ruby"
12
+ spec.license = "MIT"
13
+ spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
14
+
15
+ spec.metadata["homepage_uri"] = spec.homepage
16
+ spec.metadata["source_code_uri"] = "https://github.com/jerrymendoza/santander_chile-api_client-ruby"
17
+ spec.metadata["github_repo"] = "https://github.com/jerrymendoza/santander_chile-api_client-ruby"
18
+ spec.metadata["changelog_uri"] = "https://github.com/jerrymendoza/santander_chile-api_client-ruby"
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("..", __FILE__)) do
23
+ `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
24
+ end
25
+ spec.bindir = "exe"
26
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
27
+ spec.require_paths = ["lib"]
28
+
29
+ spec.add_dependency "faraday", "~> 1.7"
30
+ spec.add_dependency "faraday_middleware", "~> 1.1"
31
+ end
metadata ADDED
@@ -0,0 +1,100 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: santander_chile-api_client
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.2
5
+ platform: ruby
6
+ authors:
7
+ - Jerry Mendoza
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2021-10-05 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: faraday
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.7'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.7'
27
+ - !ruby/object:Gem::Dependency
28
+ name: faraday_middleware
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.1'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.1'
41
+ description: Unofficial Client for Santander Bank Chile API.
42
+ email:
43
+ - jamendoza@uc.cl
44
+ executables: []
45
+ extensions: []
46
+ extra_rdoc_files: []
47
+ files:
48
+ - ".gitignore"
49
+ - ".rspec"
50
+ - ".travis.yml"
51
+ - CODE_OF_CONDUCT.md
52
+ - Gemfile
53
+ - Gemfile.lock
54
+ - LICENSE.txt
55
+ - README.md
56
+ - Rakefile
57
+ - bin/console
58
+ - bin/setup
59
+ - lib/santander_chile/api_client.rb
60
+ - lib/santander_chile/api_client/client/authentication.rb
61
+ - lib/santander_chile/api_client/client/configuration.rb
62
+ - lib/santander_chile/api_client/client/connection.rb
63
+ - lib/santander_chile/api_client/collection.rb
64
+ - lib/santander_chile/api_client/endpoints.rb
65
+ - lib/santander_chile/api_client/error.rb
66
+ - lib/santander_chile/api_client/models/account.rb
67
+ - lib/santander_chile/api_client/models/object.rb
68
+ - lib/santander_chile/api_client/resources/products.rb
69
+ - lib/santander_chile/api_client/resources/resource.rb
70
+ - lib/santander_chile/api_client/token.rb
71
+ - lib/santander_chile/api_client/version.rb
72
+ - santander_chile-api_client.gemspec
73
+ homepage: https://github.com/jerrymendoza/santander_chile-api_client-ruby
74
+ licenses:
75
+ - MIT
76
+ metadata:
77
+ homepage_uri: https://github.com/jerrymendoza/santander_chile-api_client-ruby
78
+ source_code_uri: https://github.com/jerrymendoza/santander_chile-api_client-ruby
79
+ github_repo: https://github.com/jerrymendoza/santander_chile-api_client-ruby
80
+ changelog_uri: https://github.com/jerrymendoza/santander_chile-api_client-ruby
81
+ post_install_message:
82
+ rdoc_options: []
83
+ require_paths:
84
+ - lib
85
+ required_ruby_version: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: 2.3.0
90
+ required_rubygems_version: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - ">="
93
+ - !ruby/object:Gem::Version
94
+ version: '0'
95
+ requirements: []
96
+ rubygems_version: 3.1.4
97
+ signing_key:
98
+ specification_version: 4
99
+ summary: Unofficial Client for Santander Bank Chile API.
100
+ test_files: []