gerencianet 1.0.2 → 1.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. metadata +32 -119
  3. data/.codeclimate.yml +0 -10
  4. data/.gitignore +0 -21
  5. data/.rubocop.yml +0 -18
  6. data/.travis.yml +0 -4
  7. data/CHANGELOG.md +0 -78
  8. data/Gemfile +0 -9
  9. data/Guardfile +0 -5
  10. data/LICENSE +0 -21
  11. data/README.md +0 -96
  12. data/Rakefile +0 -6
  13. data/bin/console +0 -14
  14. data/bin/setup +0 -7
  15. data/examples/.gitignore +0 -1
  16. data/examples/certs/developmentCertificate.pem +0 -0
  17. data/examples/certs/productionCertificate.pem +0 -0
  18. data/examples/credentials.rb +0 -7
  19. data/examples/default/carnet/cancel_carnet.rb +0 -15
  20. data/examples/default/carnet/cancel_parcel.rb +0 -16
  21. data/examples/default/carnet/create_carnet.rb +0 -32
  22. data/examples/default/carnet/create_carnet_history.rb +0 -19
  23. data/examples/default/carnet/detail_carnet.rb +0 -15
  24. data/examples/default/carnet/resend_carnet.rb +0 -19
  25. data/examples/default/carnet/resend_parcel.rb +0 -20
  26. data/examples/default/carnet/settle_carnet_parcel.rb +0 -16
  27. data/examples/default/carnet/update_carnet_metadata.rb +0 -20
  28. data/examples/default/carnet/update_parcel.rb +0 -20
  29. data/examples/default/charge/all_in_one.rb +0 -57
  30. data/examples/default/charge/cancel_charge.rb +0 -15
  31. data/examples/default/charge/charge_link.rb +0 -27
  32. data/examples/default/charge/create_billet_payment.rb +0 -33
  33. data/examples/default/charge/create_card_payment.rb +0 -39
  34. data/examples/default/charge/create_charge.rb +0 -24
  35. data/examples/default/charge/create_charge_balance_sheet.rb +0 -80
  36. data/examples/default/charge/create_charge_history.rb +0 -19
  37. data/examples/default/charge/create_charge_onestep.rb +0 -36
  38. data/examples/default/charge/create_charge_onestep_creditcard.rb +0 -45
  39. data/examples/default/charge/detail_charge.rb +0 -15
  40. data/examples/default/charge/resend_billet.rb +0 -19
  41. data/examples/default/charge/settle_charge.rb +0 -15
  42. data/examples/default/charge/update_billet.rb +0 -19
  43. data/examples/default/charge/update_charge_link.rb +0 -27
  44. data/examples/default/charge/update_charge_metadata.rb +0 -20
  45. data/examples/default/marketplace/create_charge_onestep_billet_marketplace.rb +0 -45
  46. data/examples/default/marketplace/create_charge_onestep_creditcard_marketplace.rb +0 -54
  47. data/examples/default/notification/get_notification.rb +0 -15
  48. data/examples/default/others/get_installments.rb +0 -16
  49. data/examples/default/subscriptions/cancel_subscription.rb +0 -15
  50. data/examples/default/subscriptions/create_plan.rb +0 -17
  51. data/examples/default/subscriptions/create_subscription.rb +0 -31
  52. data/examples/default/subscriptions/create_subscription_history.rb +0 -19
  53. data/examples/default/subscriptions/create_subscription_payment.rb +0 -38
  54. data/examples/default/subscriptions/delete_plan.rb +0 -15
  55. data/examples/default/subscriptions/detail_subscription.rb +0 -15
  56. data/examples/default/subscriptions/get_plans.rb +0 -17
  57. data/examples/default/subscriptions/update_plan.rb +0 -19
  58. data/examples/default/subscriptions/update_subscription_metadata.rb +0 -20
  59. data/examples/gn/account/pix_detail_balance.rb +0 -16
  60. data/examples/gn/account/pix_detail_settings.rb +0 -17
  61. data/examples/gn/account/pix_update_settings.rb +0 -33
  62. data/examples/gn/key/pix_create_evp.rb +0 -17
  63. data/examples/gn/key/pix_delete_evp.rb +0 -20
  64. data/examples/gn/key/pix_list_evp.rb +0 -16
  65. data/examples/pix/charge/pix_create_charge.rb +0 -35
  66. data/examples/pix/charge/pix_create_immediate_charge.rb +0 -31
  67. data/examples/pix/charge/pix_detail_charge.rb +0 -21
  68. data/examples/pix/charge/pix_list_charges.rb +0 -21
  69. data/examples/pix/charge/pix_update_charge.rb +0 -26
  70. data/examples/pix/location/pix_create_location.rb +0 -20
  71. data/examples/pix/location/pix_detail_location.rb +0 -20
  72. data/examples/pix/location/pix_generate_qrcode.rb +0 -26
  73. data/examples/pix/location/pix_list_location.rb +0 -21
  74. data/examples/pix/location/pix_unset_txid.rb +0 -21
  75. data/examples/pix/pix/pix_detail.rb +0 -20
  76. data/examples/pix/pix/pix_detail_devolution.rb +0 -22
  77. data/examples/pix/pix/pix_devolution.rb +0 -27
  78. data/examples/pix/pix/pix_list_received.rb +0 -21
  79. data/examples/pix/pix/pix_send.rb +0 -27
  80. data/examples/pix/webhooks/pix_config_webhook.rb +0 -28
  81. data/examples/pix/webhooks/pix_delete_webhook.rb +0 -22
  82. data/examples/pix/webhooks/pix_detail_webhook.rb +0 -21
  83. data/examples/pix/webhooks/pix_list_webhook.rb +0 -22
  84. data/gerencianet.gemspec +0 -37
  85. data/lib/gerencianet/constants.rb +0 -274
  86. data/lib/gerencianet/endpoints.rb +0 -196
  87. data/lib/gerencianet/status.rb +0 -7
  88. data/lib/gerencianet/version.rb +0 -4
  89. data/lib/gerencianet.rb +0 -9
@@ -1,32 +0,0 @@
1
- require "gerencianet"
2
- require "date"
3
- require_relative "../../credentials"
4
-
5
- options = {
6
- client_id: CREDENTIALS::CLIENT_ID,
7
- client_secret: CREDENTIALS::CLIENT_SECRET,
8
- sandbox: CREDENTIALS::SANDBOX
9
- }
10
-
11
- tomorrow = Date.today + 1
12
-
13
- body = {
14
- expire_at: tomorrow.strftime,
15
- items: [{
16
- name: "Carnet Item 1",
17
- value: 1000,
18
- amount: 2
19
- }],
20
- customer: {
21
- name: "Gorbadoc Oldbuck",
22
- email: "oldbuck@gerencianet.com.br",
23
- cpf: "94271564656",
24
- birth: "1977-01-15",
25
- phone_number: "5144916523"
26
- },
27
- repeats: 12,
28
- split_items: false
29
- }
30
-
31
- gerencianet = Gerencianet.new(options)
32
- puts gerencianet.create_carnet(body: body)
@@ -1,19 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- body = {
15
- description: "This carnet is about a service"
16
- }
17
-
18
- gerencianet = Gerencianet.new(options)
19
- puts gerencianet.create_carnet_history(params: params, body: body)
@@ -1,15 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- gerencianet = Gerencianet.new(options)
15
- puts gerencianet.detail_carnet(params: params)
@@ -1,19 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- body = {
15
- email: 'oldbuck@gerencianet.com.br'
16
- }
17
-
18
- gerencianet = Gerencianet.new(options)
19
- puts gerencianet.resend_carnet(params: params, body: body)
@@ -1,20 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000,
12
- parcel: 1
13
- }
14
-
15
- body = {
16
- email: 'oldbuck@gerencianet.com.br'
17
- }
18
-
19
- gerencianet = Gerencianet.new(options)
20
- puts gerencianet.resend_parcel(params: params, body: body)
@@ -1,16 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 2363,
12
- parcel: 1
13
- }
14
-
15
- gerencianet = Gerencianet.new(options)
16
- puts gerencianet.settle_carnet_parcel(params: params)
@@ -1,20 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1004
12
- }
13
-
14
- body = {
15
- notification_url: "http://yourdomain.com",
16
- custom_id: "my_new_id"
17
- }
18
-
19
- gerencianet = Gerencianet.new(options)
20
- puts gerencianet.update_carnet_metadata(params: params, body: body)
@@ -1,20 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1008,
12
- parcel: 1
13
- }
14
-
15
- body = {
16
- expire_at: "2020-12-12"
17
- }
18
-
19
- gerencianet = Gerencianet.new(options)
20
- puts gerencianet.update_parcel(params: params, body: body)
@@ -1,57 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- charge = {
11
- items: [{
12
- name: "Product 1",
13
- value: 1000,
14
- amount: 2
15
- }],
16
- shippings: [{
17
- name: "Default Shipping Cost",
18
- value: 100
19
- }, {
20
- name: "Adicional Shipping Cost",
21
- value: 150
22
- }]
23
- }
24
-
25
- payment = {
26
- payment: {
27
- credit_card: {
28
- installments: 1,
29
- payment_token: "88faabaa35f9d9ff29c315e03255c5644554a771",
30
- billing_address: {
31
- street: "Av. JK",
32
- number: 909,
33
- neighborhood: "Bauxita",
34
- zipcode: "35400000",
35
- city: "Ouro Preto",
36
- state: "MG"
37
- },
38
- customer: {
39
- name: "Gorbadoc Oldbuck",
40
- email: "oldbuck@gerencianet.com.br",
41
- cpf: "94271564656",
42
- birth: "1977-01-15",
43
- phone_number: "5144916523"
44
- }
45
- }
46
- }
47
- }
48
-
49
- gerencianet = Gerencianet.new(options)
50
-
51
- charge = gerencianet.create_charge(body: charge)
52
-
53
- params = {
54
- id: charge["data"]["charge_id"]
55
- }
56
-
57
- puts gerencianet.pay_charge(params: params, body: payment)
@@ -1,15 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 2363
12
- }
13
-
14
- gerencianet = Gerencianet.new(options)
15
- puts gerencianet.cancel_charge(params: params)
@@ -1,27 +0,0 @@
1
- require "gerencianet"
2
- require "date"
3
- require_relative "../../credentials"
4
-
5
- options = {
6
- client_id: CREDENTIALS::CLIENT_ID,
7
- client_secret: CREDENTIALS::CLIENT_SECRET,
8
- sandbox: CREDENTIALS::SANDBOX
9
- }
10
-
11
- expireAt = Date.today + 3
12
-
13
- params = {
14
- id: 1000
15
- }
16
-
17
- body = {
18
- billet_discount: 0,
19
- card_discount: 0,
20
- message: "",
21
- expire_at: expireAt.strftime,
22
- request_delivery_address: false,
23
- payment_method: "all"
24
- }
25
-
26
- gerencianet = Gerencianet.new(options)
27
- puts gerencianet.charge_link(params: params, body: body)
@@ -1,33 +0,0 @@
1
- require "gerencianet"
2
- require "date"
3
- require_relative "../../credentials"
4
-
5
- options = {
6
- client_id: CREDENTIALS::CLIENT_ID,
7
- client_secret: CREDENTIALS::CLIENT_SECRET,
8
- sandbox: CREDENTIALS::SANDBOX
9
- }
10
-
11
- tomorrow = Date.today + 1
12
-
13
- params = {
14
- id: 553880
15
- }
16
-
17
- body = {
18
- payment: {
19
- banking_billet: {
20
- expire_at: tomorrow.strftime,
21
- customer: {
22
- name: "Gorbadoc Oldbuck",
23
- email: "oldbuck@gerencianet.com.br",
24
- cpf: "94271564656",
25
- birth: "1977-01-15",
26
- phone_number: "5144916523"
27
- }
28
- }
29
- }
30
- }
31
-
32
- gerencianet = Gerencianet.new(options)
33
- puts gerencianet.pay_charge(params: params, body: body)
@@ -1,39 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- body = {
11
- payment: {
12
- credit_card: {
13
- installments: 1,
14
- payment_token: "5739b06925244dd1ab8e0afa62389d5fb4ea2945",
15
- billing_address: {
16
- street: "Av. JK",
17
- number: 909,
18
- neighborhood: "Bauxita",
19
- zipcode: "35400000",
20
- city: "Ouro Preto",
21
- state: "MG"
22
- },
23
- customer: {
24
- name: "Gorbadoc Oldbuck",
25
- email: "oldbuck@gerencianet.com.br",
26
- cpf: "94271564656",
27
- birth: "1977-01-15",
28
- phone_number: "5144916523"
29
- }
30
- }
31
- }
32
- }
33
-
34
- params = {
35
- id: 2366
36
- }
37
-
38
- gerencianet = Gerencianet.new(options)
39
- puts gerencianet.pay_charge(params: params, body: body)
@@ -1,24 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- body = {
11
- items: [{
12
- name: "Product 1",
13
- value: 1000,
14
- amount: 2
15
- }],
16
- shippings: [{
17
- name: "Default Shipping Cost",
18
- value: 100
19
- }]
20
- }
21
-
22
- gerencianet = Gerencianet.new(options)
23
- puts gerencianet.create_charge(body: body)
24
-
@@ -1,80 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- body = {
15
- title: "Balancete Demonstrativo",
16
- body: [
17
- {
18
- header: "Demonstrativo de Consumo",
19
- tables: [
20
- {
21
- rows: [
22
- [
23
- {
24
- align: "left",
25
- color: "#000000",
26
- style: "bold",
27
- text: "Exemplo de despesa",
28
- colspan: 2
29
- },
30
- {
31
- align: "left",
32
- color: "#000000",
33
- style: "bold",
34
- text: "Total lançado",
35
- colspan: 2
36
- }
37
- ],
38
- [
39
- {
40
- align: "left",
41
- color: "#000000",
42
- style: "normal",
43
- text: "Instalação",
44
- colspan: 2
45
- },
46
- {
47
- align: "left",
48
- color: "#000000",
49
- style: "normal",
50
- text: "R$ 100,00",
51
- colspan: 2
52
- }
53
- ]
54
- ]
55
- }
56
- ]
57
- },
58
- {
59
- header: "Balancete Geral",
60
- tables: [
61
- {
62
- rows: [
63
- [
64
- {
65
- align: "left",
66
- color: "#000000",
67
- style: "normal",
68
- text: "Confira na documentação da Gerencianet todas as configurações possíveis de um boleto balancete.",
69
- colspan: 4
70
- }
71
- ]
72
- ]
73
- }
74
- ]
75
- }
76
- ]
77
- }
78
-
79
- gerencianet = Gerencianet.new(options)
80
- puts gerencianet.create_charge_balance_sheet(params: params, body: body)
@@ -1,19 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- body = {
15
- description: "This charge was not fully paid"
16
- }
17
-
18
- gerencianet = Gerencianet.new(options)
19
- puts gerencianet.create_charge_history(params: params, body: body)
@@ -1,36 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- body = {
11
- items: [{
12
- name: "Product 1",
13
- value: 1000,
14
- amount: 2
15
- }],
16
- shippings: [{
17
- name: "Default Shipping Cost",
18
- value: 100
19
- }],
20
- payment: {
21
- banking_billet: {
22
- expire_at: tomorrow.strftime,
23
- customer: {
24
- name: "Gorbadoc Oldbuck",
25
- email: "oldbuck@gerencianet.com.br",
26
- cpf: "94271564656",
27
- birth: "1977-01-15",
28
- phone_number: "5144916523"
29
- }
30
- }
31
- }
32
- }
33
-
34
- gerencianet = Gerencianet.new(options)
35
- puts gerencianet.create_charge_onestep(body: body)
36
-
@@ -1,45 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- body = {
11
- items: [{
12
- name: "Product 1",
13
- value: 1000,
14
- amount: 2
15
- }],
16
- shippings: [{
17
- name: "Default Shipping Cost",
18
- value: 100
19
- }],
20
- payment: {
21
- credit_card: {
22
- installments: 1,
23
- payment_token: "6426f3abd8688639c6772963669bbb8e0eb3c319",
24
- billing_address: {
25
- street: "Av. JK",
26
- number: 909,
27
- neighborhood: "Bauxita",
28
- zipcode: "35400000",
29
- city: "Ouro Preto",
30
- state: "MG"
31
- },
32
- customer: {
33
- name: "Gorbadoc Oldbuck",
34
- email: "oldbuck@gerencianet.com.br",
35
- cpf: "94271564656",
36
- birth: "1977-01-15",
37
- phone_number: "5144916523"
38
- }
39
- }
40
- }
41
- }
42
-
43
- gerencianet = Gerencianet.new(options)
44
- puts gerencianet.create_charge_onestep(body: body)
45
-
@@ -1,15 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- gerencianet = Gerencianet.new(options)
15
- puts gerencianet.detail_charge(params: params)
@@ -1,19 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1000
12
- }
13
-
14
- body = {
15
- email: 'oldbuck@gerencianet.com.br'
16
- }
17
-
18
- gerencianet = Gerencianet.new(options)
19
- puts gerencianet.resend_billet(params: params, body: body)
@@ -1,15 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 553880
12
- }
13
-
14
- gerencianet = Gerencianet.new(options)
15
- puts gerencianet.settle_charge(params: params)
@@ -1,19 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1008
12
- }
13
-
14
- body = {
15
- expire_at: "2020-12-12"
16
- }
17
-
18
- gerencianet = Gerencianet.new(options)
19
- puts gerencianet.update_billet(params: params, body: body)
@@ -1,27 +0,0 @@
1
- require "gerencianet"
2
- require "date"
3
- require_relative "../../credentials"
4
-
5
- options = {
6
- client_id: CREDENTIALS::CLIENT_ID,
7
- client_secret: CREDENTIALS::CLIENT_SECRET,
8
- sandbox: CREDENTIALS::SANDBOX
9
- }
10
-
11
- expireAt = Date.today + 3
12
-
13
- params = {
14
- id: 1000
15
- }
16
-
17
- body = {
18
- billet_discount: 0,
19
- card_discount: 0,
20
- message: "",
21
- expire_at: expireAt.strftime,
22
- request_delivery_address: false,
23
- payment_method: "all"
24
- }
25
-
26
- gerencianet = Gerencianet.new(options)
27
- puts gerencianet.update_charge_link(params: params, body: body)
@@ -1,20 +0,0 @@
1
- require "gerencianet"
2
- require_relative "../../credentials"
3
-
4
- options = {
5
- client_id: CREDENTIALS::CLIENT_ID,
6
- client_secret: CREDENTIALS::CLIENT_SECRET,
7
- sandbox: CREDENTIALS::SANDBOX
8
- }
9
-
10
- params = {
11
- id: 1008
12
- }
13
-
14
- body = {
15
- notification_url: "http://yourdomain.com",
16
- custom_id: "my_new_id"
17
- }
18
-
19
- gerencianet = Gerencianet.new(options)
20
- puts gerencianet.update_charge_metadata(params: params, body: body)