borika 0.2.0 → 0.2.1

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +64 -1
  3. data/lib/borika/version.rb +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 40809c07208de603a8beb7e95bcc40d6b5b2b8ad3b3ccd570aa0581a6a4fe669
4
- data.tar.gz: 13e981e8170bbbe982e829d2ad160bd95e0d2e5f3e57643d0995484c3b8810b4
3
+ metadata.gz: ace4319a16e67d424adf9b9c8cd8e085b02272bef40dc7a7bfccef96b112eccb
4
+ data.tar.gz: dcc66bbe7919af254a132e23e0f478f6879c24ecb5c215affd897995f0f1b562
5
5
  SHA512:
6
- metadata.gz: 3ab7237e4872882b5ba294e17b35131387966ef7dd3d32f1e4bf7a835792145084807d7086e9ca5b79d755eb6dcb36440c52bdb64c3e9f738c0d6114cb5ccaa4
7
- data.tar.gz: ca000209c64368f5f35ddbf0b509c035f411863733eb3f7e2352cf3ba4b040b6906a48040e644cc44af4dfe52b3e6933238fc141b8088ad93dc7e6dafe4f4af1
6
+ metadata.gz: 6932f4a134a81ab7f817ce877af203538ad2d1e7b8bafc7f53deaeb07bb7450ac7c77c0b3e91f4b444c83737741af4189d013f5e002703bd522a2f9ff0d5bedf
7
+ data.tar.gz: 3cbe99abaca387b7a86a9d31beb605a28e3c6bf06923fe194996fd06859b957877de0eec586e8a4af31ebe233e94db88c4ea013bbe47a7c8212e249f13798992
data/README.md CHANGED
@@ -1 +1,64 @@
1
- Borika gem for ruby
1
+ [Unoffical] Borica Ruby Gem for Payments
2
+
3
+ [Visit the gem at RubyGems.org](https://rubygems.org/gems/borika)
4
+
5
+ [See Borica Bank webpage for Internet 3D Secure Payments](https://www.borica.bg/en/products-and-services/Sigurni-plashtaniya-v-Internet-3d-secure-za-kartodarjatelya)
6
+
7
+ ### Getting started
8
+
9
+ Add the following line to your Gemfile:
10
+
11
+ ```ruby
12
+ gem 'borika'
13
+ ```
14
+
15
+ or
16
+ ```cmd
17
+ gem install borika
18
+ require 'borika'
19
+ ```
20
+
21
+ Here is a possible configuration for development `config/environments/development.rb`:
22
+
23
+ ```ruby
24
+ Borika.configure do |config|
25
+ config.private_key = File.binread "testPrivateKey.key"
26
+ config.private_key_password = "Password"
27
+ config.borika_terminal_id = "11111111" # Borika KEY
28
+ config.borika_url = "https://gatet.borica.bg/boreps/"
29
+ config.request_type = "registerTransaction"
30
+ end
31
+ ```
32
+ This parameters are default but you can change it while using on the fly.
33
+
34
+ Note: You must send the signed CSR file to Borica BANK, otherwise you will get, certificate error.
35
+
36
+ ### Example Usage
37
+
38
+ Let's create a url
39
+
40
+ ```ruby
41
+ order_id = rand(1..200000) # Give your uniq order_id
42
+ amaount = rand(100..50000) # Integer with cents
43
+ Borika::Request.new(order_id, amount).url
44
+ ```
45
+
46
+ You can also give more parameters, copy the default initializer belowe and modify it.
47
+ ```ruby
48
+ Borika::Request.new(order_id, amount, order_summary: "Order #{order_id}",
49
+ time: Time.now, language: 'EN', protocol_version: '1.0', currency: 'EUR',
50
+ process_no: 10, request_type: Borika.config.request_type, terminal_id: Borika.config.borika_terminal_id,
51
+ one_time_ticket: nil).url
52
+ ```
53
+
54
+ ### Testing
55
+ Not tested. Works with default parameters. Welcome to pull request.
56
+
57
+ ### Contributors
58
+ This repository originally inspired from
59
+ [Genadi Samokovarov's Borica Gem](https://github.com/gsamokovarov/borica)
60
+
61
+
62
+ ## License
63
+
64
+ GPL Licence. Copyleft. You can copy and modify this software.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Borika
4
- VERSION = "0.2.0"
4
+ VERSION = "0.2.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: borika
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mehmet Aydoğdu