pier-sdk-ruby 1.0.0
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.
- data/README.md +141 -0
- data/docs/AuthToken.md +12 -0
- data/docs/BodyAccessToken.md +10 -0
- data/docs/CancelarCartaoResponse.md +11 -0
- data/docs/CartaoApi.md +252 -0
- data/docs/CartaoResponse.md +29 -0
- data/docs/ConsultarCartaoResponse.md +10 -0
- data/docs/ConsultarContaCartaoResponse.md +18 -0
- data/docs/ConsultarContaResponse.md +11 -0
- data/docs/ConsultarExtratoContaResponse.md +23 -0
- data/docs/ConsultarSaldoLimitesResponse.md +23 -0
- data/docs/ContaApi.md +238 -0
- data/docs/ContaCartaoResponse.md +21 -0
- data/docs/ContaResponse.md +41 -0
- data/docs/DesbloquearCartaoResponse.md +9 -0
- data/docs/ExtraInfo.md +8 -0
- data/docs/ExtratoResponse.md +35 -0
- data/docs/PessoaFisicaResponse.md +26 -0
- data/docs/SaldoLimiteResponse.md +39 -0
- data/docs/TokenApi.md +114 -0
- data/git_push.sh +52 -0
- data/lib/pier-sdk-ruby.rb +62 -0
- data/lib/pier-sdk-ruby/api/cartao_api.rb +355 -0
- data/lib/pier-sdk-ruby/api/conta_api.rb +324 -0
- data/lib/pier-sdk-ruby/api/token_api.rb +157 -0
- data/lib/pier-sdk-ruby/api_client.rb +368 -0
- data/lib/pier-sdk-ruby/api_error.rb +40 -0
- data/lib/pier-sdk-ruby/configuration.rb +177 -0
- data/lib/pier-sdk-ruby/models/auth_token.rb +325 -0
- data/lib/pier-sdk-ruby/models/body_access_token.rb +275 -0
- data/lib/pier-sdk-ruby/models/cancelar_cartao_response.rb +286 -0
- data/lib/pier-sdk-ruby/models/cartao_response.rb +736 -0
- data/lib/pier-sdk-ruby/models/consultar_cartao_response.rb +263 -0
- data/lib/pier-sdk-ruby/models/consultar_conta_cartao_response.rb +461 -0
- data/lib/pier-sdk-ruby/models/consultar_conta_response.rb +288 -0
- data/lib/pier-sdk-ruby/models/consultar_extrato_conta_response.rb +588 -0
- data/lib/pier-sdk-ruby/models/consultar_saldo_limites_response.rb +586 -0
- data/lib/pier-sdk-ruby/models/conta_cartao_response.rb +536 -0
- data/lib/pier-sdk-ruby/models/conta_response.rb +1036 -0
- data/lib/pier-sdk-ruby/models/desbloquear_cartao_response.rb +236 -0
- data/lib/pier-sdk-ruby/models/extra_info.rb +211 -0
- data/lib/pier-sdk-ruby/models/extrato_response.rb +886 -0
- data/lib/pier-sdk-ruby/models/pessoa_fisica_response.rb +661 -0
- data/lib/pier-sdk-ruby/models/saldo_limite_response.rb +986 -0
- data/lib/pier-sdk-ruby/version.rb +19 -0
- data/pier-sdk-ruby.gemspec +33 -0
- data/spec/api/cartao_api_spec.rb +110 -0
- data/spec/api/conta_api_spec.rb +107 -0
- data/spec/api/token_api_spec.rb +71 -0
- data/spec/models/auth_token_spec.rb +90 -0
- data/spec/models/body_access_token_spec.rb +70 -0
- data/spec/models/cancelar_cartao_response_spec.rb +80 -0
- data/spec/models/cartao_response_spec.rb +260 -0
- data/spec/models/consultar_cartao_response_spec.rb +70 -0
- data/spec/models/consultar_conta_cartao_response_spec.rb +150 -0
- data/spec/models/consultar_conta_response_spec.rb +80 -0
- data/spec/models/consultar_extrato_conta_response_spec.rb +200 -0
- data/spec/models/consultar_saldo_limites_response_spec.rb +200 -0
- data/spec/models/conta_cartao_response_spec.rb +180 -0
- data/spec/models/conta_response_spec.rb +380 -0
- data/spec/models/desbloquear_cartao_response_spec.rb +60 -0
- data/spec/models/extra_info_spec.rb +50 -0
- data/spec/models/extrato_response_spec.rb +320 -0
- data/spec/models/pessoa_fisica_response_spec.rb +230 -0
- data/spec/models/saldo_limite_response_spec.rb +360 -0
- metadata +310 -0
data/README.md
ADDED
@@ -0,0 +1,141 @@
|
|
1
|
+
# pier-sdk-ruby
|
2
|
+
|
3
|
+
Pier - the Ruby gem for the CaaS - Conductor as a Service
|
4
|
+
|
5
|
+
Gest\u00C3\u00A3o de pagamento eletr\u00C3\u00B4nicos como servi\u00C3\u00A7o
|
6
|
+
|
7
|
+
This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
|
8
|
+
|
9
|
+
- API version: 0.0.1
|
10
|
+
- Package version: 1.0.0
|
11
|
+
- Build date: 2016-05-19T15:36:51.481-03:00
|
12
|
+
- Build package: class io.swagger.codegen.languages.RubyClientCodegen
|
13
|
+
For more information, please visit [http://www.conductor.com.br](http://www.conductor.com.br)
|
14
|
+
|
15
|
+
## Installation
|
16
|
+
|
17
|
+
### Build a gem
|
18
|
+
|
19
|
+
To build the Ruby code into a gem:
|
20
|
+
|
21
|
+
```shell
|
22
|
+
gem build pier-sdk-ruby.gemspec
|
23
|
+
```
|
24
|
+
|
25
|
+
Then either install the gem locally:
|
26
|
+
|
27
|
+
```shell
|
28
|
+
gem install ./pier-sdk-ruby-1.0.0.gem
|
29
|
+
```
|
30
|
+
(for development, run `gem install --dev ./pier-sdk-ruby-1.0.0.gem` to install the development dependencies)
|
31
|
+
|
32
|
+
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
33
|
+
|
34
|
+
Finally add this to the Gemfile:
|
35
|
+
|
36
|
+
gem 'pier-sdk-ruby', '~> 1.0.0'
|
37
|
+
|
38
|
+
### Install from Git
|
39
|
+
|
40
|
+
If the Ruby gem is hosted at a git repository: https://github.com/YOUR_GIT_USERNAME/YOUR_GIT_REPO, then add the following in the Gemfile:
|
41
|
+
|
42
|
+
gem 'pier-sdk-ruby', :git => 'https://github.com/YOUR_GIT_USERNAME/YOUR_GIT_REPO.git'
|
43
|
+
|
44
|
+
### Include the Ruby code directly
|
45
|
+
|
46
|
+
Include the Ruby code directly using `-I` as follows:
|
47
|
+
|
48
|
+
```shell
|
49
|
+
ruby -Ilib script.rb
|
50
|
+
```
|
51
|
+
|
52
|
+
## Getting Started
|
53
|
+
|
54
|
+
Please follow the [installation](#installation) procedure and then run the following code:
|
55
|
+
```ruby
|
56
|
+
# Load the gem
|
57
|
+
require 'pier-sdk-ruby'
|
58
|
+
|
59
|
+
# Setup authorization
|
60
|
+
Pier.configure do |config|
|
61
|
+
# Configure API key authorization: access_token
|
62
|
+
config.api_key['access_token'] = 'YOUR API KEY'
|
63
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'BEARER' (defaults to nil)
|
64
|
+
#config.api_key_prefix['access_token'] = 'BEARER'
|
65
|
+
end
|
66
|
+
|
67
|
+
api_instance = Pier::CartaoApi.new
|
68
|
+
|
69
|
+
id_conta = 56 # Integer | ID da Conta
|
70
|
+
|
71
|
+
id_cartao = 56 # Integer | ID do Cart\u00C3\u00A3o que deseja cancelar
|
72
|
+
|
73
|
+
motivo = 56 # Integer | Motivo do bloqueio
|
74
|
+
|
75
|
+
opts = {
|
76
|
+
observacao: "observacao_example" # String | Alguma observa\u00C3\u00A7\u00C3\u00A3o para o bloqueio
|
77
|
+
}
|
78
|
+
|
79
|
+
begin
|
80
|
+
#/contas/{idConta}/cartoes/{idCartao}/bloquear
|
81
|
+
result = api_instance.bloquear_cartao_using_post(id_conta, id_cartao, motivo, opts)
|
82
|
+
p result
|
83
|
+
rescue Pier::ApiError => e
|
84
|
+
puts "Exception when calling CartaoApi->bloquear_cartao_using_post: #{e}"
|
85
|
+
end
|
86
|
+
|
87
|
+
```
|
88
|
+
|
89
|
+
## Documentation for API Endpoints
|
90
|
+
|
91
|
+
All URIs are relative to *https://localhost/*
|
92
|
+
|
93
|
+
Class | Method | HTTP request | Description
|
94
|
+
------------ | ------------- | ------------- | -------------
|
95
|
+
*Pier::CartaoApi* | [**bloquear_cartao_using_post**](docs/CartaoApi.md#bloquear_cartao_using_post) | **POST** /v1/contas/{idConta}/cartoes/{idCartao}/bloquear | /contas/{idConta}/cartoes/{idCartao}/bloquear
|
96
|
+
*Pier::CartaoApi* | [**consultar_cartao_using_get**](docs/CartaoApi.md#consultar_cartao_using_get) | **GET** /v1/contas/{idConta}/cartoes/{idCartao} | /contas/{idConta}/cartoes/{idCartao}
|
97
|
+
*Pier::CartaoApi* | [**consultar_cartoes_using_get**](docs/CartaoApi.md#consultar_cartoes_using_get) | **GET** /v1/contas/{idConta}/cartoes | /contas/{idConta}/cartoes
|
98
|
+
*Pier::CartaoApi* | [**desbloquear_cartao_using_post**](docs/CartaoApi.md#desbloquear_cartao_using_post) | **POST** /v1/contas/{idConta}/cartoes/{idCartao}/desbloquear | /contas/{idConta}/cartoes/{idCartao}/desbloquear
|
99
|
+
*Pier::ContaApi* | [**buscar_conta_using_get**](docs/ContaApi.md#buscar_conta_using_get) | **GET** /v1/contas/buscar | /contas/buscar
|
100
|
+
*Pier::ContaApi* | [**consultar_conta_using_get**](docs/ContaApi.md#consultar_conta_using_get) | **GET** /v1/contas/{idConta} | /contas/{idConta}
|
101
|
+
*Pier::ContaApi* | [**consultar_extrato_faturas_using_get**](docs/ContaApi.md#consultar_extrato_faturas_using_get) | **GET** /v1/contas/{idConta}/faturas | /contas/{idConta}/faturas
|
102
|
+
*Pier::ContaApi* | [**consultar_saldos_limites_using_get**](docs/ContaApi.md#consultar_saldos_limites_using_get) | **GET** /v1/contas/{idConta}/limites | /contas/{idConta}/limites
|
103
|
+
*Pier::TokenApi* | [**callback_using_post**](docs/TokenApi.md#callback_using_post) | **POST** /v1/tokens/callback | /tokens/callback
|
104
|
+
*Pier::TokenApi* | [**validar_using_post**](docs/TokenApi.md#validar_using_post) | **POST** /v1/tokens/validar | /tokens/validar
|
105
|
+
|
106
|
+
|
107
|
+
## Documentation for Models
|
108
|
+
|
109
|
+
- [Pier::AuthToken](docs/AuthToken.md)
|
110
|
+
- [Pier::BodyAccessToken](docs/BodyAccessToken.md)
|
111
|
+
- [Pier::CancelarCartaoResponse](docs/CancelarCartaoResponse.md)
|
112
|
+
- [Pier::CartaoResponse](docs/CartaoResponse.md)
|
113
|
+
- [Pier::ConsultarCartaoResponse](docs/ConsultarCartaoResponse.md)
|
114
|
+
- [Pier::ConsultarContaCartaoResponse](docs/ConsultarContaCartaoResponse.md)
|
115
|
+
- [Pier::ConsultarContaResponse](docs/ConsultarContaResponse.md)
|
116
|
+
- [Pier::ConsultarExtratoContaResponse](docs/ConsultarExtratoContaResponse.md)
|
117
|
+
- [Pier::ConsultarSaldoLimitesResponse](docs/ConsultarSaldoLimitesResponse.md)
|
118
|
+
- [Pier::ContaCartaoResponse](docs/ContaCartaoResponse.md)
|
119
|
+
- [Pier::ContaResponse](docs/ContaResponse.md)
|
120
|
+
- [Pier::DesbloquearCartaoResponse](docs/DesbloquearCartaoResponse.md)
|
121
|
+
- [Pier::ExtraInfo](docs/ExtraInfo.md)
|
122
|
+
- [Pier::ExtratoResponse](docs/ExtratoResponse.md)
|
123
|
+
- [Pier::PessoaFisicaResponse](docs/PessoaFisicaResponse.md)
|
124
|
+
- [Pier::SaldoLimiteResponse](docs/SaldoLimiteResponse.md)
|
125
|
+
|
126
|
+
|
127
|
+
## Documentation for Authorization
|
128
|
+
|
129
|
+
|
130
|
+
### access_token
|
131
|
+
|
132
|
+
- **Type**: API key
|
133
|
+
- **API key parameter name**: access_token
|
134
|
+
- **Location**: HTTP header
|
135
|
+
|
136
|
+
### client_id
|
137
|
+
|
138
|
+
- **Type**: API key
|
139
|
+
- **API key parameter name**: client_id
|
140
|
+
- **Location**: HTTP header
|
141
|
+
|
data/docs/AuthToken.md
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
# Pier::AuthToken
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**code** | **String** | | [optional]
|
7
|
+
**extra_info** | [**ExtraInfo**](ExtraInfo.md) | | [optional]
|
8
|
+
**id** | **Integer** | | [optional]
|
9
|
+
**owner** | **String** | | [optional]
|
10
|
+
**status** | **String** | | [optional]
|
11
|
+
|
12
|
+
|
@@ -0,0 +1,10 @@
|
|
1
|
+
# Pier::BodyAccessToken
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**auth_token** | [**AuthToken**](AuthToken.md) | | [optional]
|
7
|
+
**action** | **String** | | [optional]
|
8
|
+
**user** | **String** | | [optional]
|
9
|
+
|
10
|
+
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# Pier::CancelarCartaoResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**codigo_retorno** | **Integer** | | [optional]
|
7
|
+
**descricao_retorno** | **String** | | [optional]
|
8
|
+
**id_cartao** | **Integer** | | [optional]
|
9
|
+
**id_conta** | **Integer** | | [optional]
|
10
|
+
|
11
|
+
|
data/docs/CartaoApi.md
ADDED
@@ -0,0 +1,252 @@
|
|
1
|
+
# Pier::CartaoApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://localhost/*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**bloquear_cartao_using_post**](CartaoApi.md#bloquear_cartao_using_post) | **POST** /v1/contas/{idConta}/cartoes/{idCartao}/bloquear | /contas/{idConta}/cartoes/{idCartao}/bloquear
|
8
|
+
[**consultar_cartao_using_get**](CartaoApi.md#consultar_cartao_using_get) | **GET** /v1/contas/{idConta}/cartoes/{idCartao} | /contas/{idConta}/cartoes/{idCartao}
|
9
|
+
[**consultar_cartoes_using_get**](CartaoApi.md#consultar_cartoes_using_get) | **GET** /v1/contas/{idConta}/cartoes | /contas/{idConta}/cartoes
|
10
|
+
[**desbloquear_cartao_using_post**](CartaoApi.md#desbloquear_cartao_using_post) | **POST** /v1/contas/{idConta}/cartoes/{idCartao}/desbloquear | /contas/{idConta}/cartoes/{idCartao}/desbloquear
|
11
|
+
|
12
|
+
|
13
|
+
# **bloquear_cartao_using_post**
|
14
|
+
> CancelarCartaoResponse bloquear_cartao_using_post(id_conta, id_cartao, motivo, opts)
|
15
|
+
|
16
|
+
/contas/{idConta}/cartoes/{idCartao}/bloquear
|
17
|
+
|
18
|
+
Bloquear um determinado cart\u00C3\u00A3o
|
19
|
+
|
20
|
+
### Example
|
21
|
+
```ruby
|
22
|
+
# load the gem
|
23
|
+
require 'pier-sdk-ruby'
|
24
|
+
# setup authorization
|
25
|
+
Pier.configure do |config|
|
26
|
+
# Configure API key authorization: access_token
|
27
|
+
config.api_key['access_token'] = 'YOUR API KEY'
|
28
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'BEARER' (defaults to nil)
|
29
|
+
#config.api_key_prefix['access_token'] = 'BEARER'
|
30
|
+
end
|
31
|
+
|
32
|
+
api_instance = Pier::CartaoApi.new
|
33
|
+
|
34
|
+
id_conta = 56 # Integer | ID da Conta
|
35
|
+
|
36
|
+
id_cartao = 56 # Integer | ID do Cart\u00C3\u00A3o que deseja cancelar
|
37
|
+
|
38
|
+
motivo = 56 # Integer | Motivo do bloqueio
|
39
|
+
|
40
|
+
opts = {
|
41
|
+
observacao: "observacao_example" # String | Alguma observa\u00C3\u00A7\u00C3\u00A3o para o bloqueio
|
42
|
+
}
|
43
|
+
|
44
|
+
begin
|
45
|
+
#/contas/{idConta}/cartoes/{idCartao}/bloquear
|
46
|
+
result = api_instance.bloquear_cartao_using_post(id_conta, id_cartao, motivo, opts)
|
47
|
+
p result
|
48
|
+
rescue Pier::ApiError => e
|
49
|
+
puts "Exception when calling CartaoApi->bloquear_cartao_using_post: #{e}"
|
50
|
+
end
|
51
|
+
```
|
52
|
+
|
53
|
+
### Parameters
|
54
|
+
|
55
|
+
Name | Type | Description | Notes
|
56
|
+
------------- | ------------- | ------------- | -------------
|
57
|
+
**id_conta** | **Integer**| ID da Conta |
|
58
|
+
**id_cartao** | **Integer**| ID do Cart\u00C3\u00A3o que deseja cancelar |
|
59
|
+
**motivo** | **Integer**| Motivo do bloqueio |
|
60
|
+
**observacao** | **String**| Alguma observa\u00C3\u00A7\u00C3\u00A3o para o bloqueio | [optional]
|
61
|
+
|
62
|
+
### Return type
|
63
|
+
|
64
|
+
[**CancelarCartaoResponse**](CancelarCartaoResponse.md)
|
65
|
+
|
66
|
+
### Authorization
|
67
|
+
|
68
|
+
[access_token](../README.md#access_token)
|
69
|
+
|
70
|
+
### HTTP request headers
|
71
|
+
|
72
|
+
- **Content-Type**: application/json
|
73
|
+
- **Accept**: application/json
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
# **consultar_cartao_using_get**
|
78
|
+
> ConsultarCartaoResponse consultar_cartao_using_get(id_conta, id_cartao, opts)
|
79
|
+
|
80
|
+
/contas/{idConta}/cartoes/{idCartao}
|
81
|
+
|
82
|
+
Consultar as informa\u00C3\u00A7\u00C3\u00B5es de um determinado cart\u00C3\u00A3o de uma conta
|
83
|
+
|
84
|
+
### Example
|
85
|
+
```ruby
|
86
|
+
# load the gem
|
87
|
+
require 'pier-sdk-ruby'
|
88
|
+
# setup authorization
|
89
|
+
Pier.configure do |config|
|
90
|
+
# Configure API key authorization: access_token
|
91
|
+
config.api_key['access_token'] = 'YOUR API KEY'
|
92
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'BEARER' (defaults to nil)
|
93
|
+
#config.api_key_prefix['access_token'] = 'BEARER'
|
94
|
+
end
|
95
|
+
|
96
|
+
api_instance = Pier::CartaoApi.new
|
97
|
+
|
98
|
+
id_conta = 56 # Integer | ID da Conta que pertence o cart\u00C3\u00A3o
|
99
|
+
|
100
|
+
id_cartao = 56 # Integer | ID do Cart\u00C3\u00A3o que deseja consultar
|
101
|
+
|
102
|
+
opts = {
|
103
|
+
numero_cartao: "numero_cartao_example" # String | N\u00C3\u00BAmero do Cart\u00C3\u00A3o que deseja consultar (opcional)
|
104
|
+
}
|
105
|
+
|
106
|
+
begin
|
107
|
+
#/contas/{idConta}/cartoes/{idCartao}
|
108
|
+
result = api_instance.consultar_cartao_using_get(id_conta, id_cartao, opts)
|
109
|
+
p result
|
110
|
+
rescue Pier::ApiError => e
|
111
|
+
puts "Exception when calling CartaoApi->consultar_cartao_using_get: #{e}"
|
112
|
+
end
|
113
|
+
```
|
114
|
+
|
115
|
+
### Parameters
|
116
|
+
|
117
|
+
Name | Type | Description | Notes
|
118
|
+
------------- | ------------- | ------------- | -------------
|
119
|
+
**id_conta** | **Integer**| ID da Conta que pertence o cart\u00C3\u00A3o |
|
120
|
+
**id_cartao** | **Integer**| ID do Cart\u00C3\u00A3o que deseja consultar |
|
121
|
+
**numero_cartao** | **String**| N\u00C3\u00BAmero do Cart\u00C3\u00A3o que deseja consultar (opcional) | [optional]
|
122
|
+
|
123
|
+
### Return type
|
124
|
+
|
125
|
+
[**ConsultarCartaoResponse**](ConsultarCartaoResponse.md)
|
126
|
+
|
127
|
+
### Authorization
|
128
|
+
|
129
|
+
[access_token](../README.md#access_token)
|
130
|
+
|
131
|
+
### HTTP request headers
|
132
|
+
|
133
|
+
- **Content-Type**: application/json
|
134
|
+
- **Accept**: application/json
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
# **consultar_cartoes_using_get**
|
139
|
+
> ConsultarCartaoResponse consultar_cartoes_using_get(id_conta)
|
140
|
+
|
141
|
+
/contas/{idConta}/cartoes
|
142
|
+
|
143
|
+
Consultar todos os cart\u00C3\u00B5es de uma determinada conta
|
144
|
+
|
145
|
+
### Example
|
146
|
+
```ruby
|
147
|
+
# load the gem
|
148
|
+
require 'pier-sdk-ruby'
|
149
|
+
# setup authorization
|
150
|
+
Pier.configure do |config|
|
151
|
+
# Configure API key authorization: access_token
|
152
|
+
config.api_key['access_token'] = 'YOUR API KEY'
|
153
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'BEARER' (defaults to nil)
|
154
|
+
#config.api_key_prefix['access_token'] = 'BEARER'
|
155
|
+
end
|
156
|
+
|
157
|
+
api_instance = Pier::CartaoApi.new
|
158
|
+
|
159
|
+
id_conta = 56 # Integer | ID da Conta
|
160
|
+
|
161
|
+
|
162
|
+
begin
|
163
|
+
#/contas/{idConta}/cartoes
|
164
|
+
result = api_instance.consultar_cartoes_using_get(id_conta)
|
165
|
+
p result
|
166
|
+
rescue Pier::ApiError => e
|
167
|
+
puts "Exception when calling CartaoApi->consultar_cartoes_using_get: #{e}"
|
168
|
+
end
|
169
|
+
```
|
170
|
+
|
171
|
+
### Parameters
|
172
|
+
|
173
|
+
Name | Type | Description | Notes
|
174
|
+
------------- | ------------- | ------------- | -------------
|
175
|
+
**id_conta** | **Integer**| ID da Conta |
|
176
|
+
|
177
|
+
### Return type
|
178
|
+
|
179
|
+
[**ConsultarCartaoResponse**](ConsultarCartaoResponse.md)
|
180
|
+
|
181
|
+
### Authorization
|
182
|
+
|
183
|
+
[access_token](../README.md#access_token)
|
184
|
+
|
185
|
+
### HTTP request headers
|
186
|
+
|
187
|
+
- **Content-Type**: application/json
|
188
|
+
- **Accept**: application/json
|
189
|
+
|
190
|
+
|
191
|
+
|
192
|
+
# **desbloquear_cartao_using_post**
|
193
|
+
> DesbloquearCartaoResponse desbloquear_cartao_using_post(id_conta, id_cartao, opts)
|
194
|
+
|
195
|
+
/contas/{idConta}/cartoes/{idCartao}/desbloquear
|
196
|
+
|
197
|
+
Desbloquear cart\u00C3\u00A3o de uma determinada conta
|
198
|
+
|
199
|
+
### Example
|
200
|
+
```ruby
|
201
|
+
# load the gem
|
202
|
+
require 'pier-sdk-ruby'
|
203
|
+
# setup authorization
|
204
|
+
Pier.configure do |config|
|
205
|
+
# Configure API key authorization: access_token
|
206
|
+
config.api_key['access_token'] = 'YOUR API KEY'
|
207
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'BEARER' (defaults to nil)
|
208
|
+
#config.api_key_prefix['access_token'] = 'BEARER'
|
209
|
+
end
|
210
|
+
|
211
|
+
api_instance = Pier::CartaoApi.new
|
212
|
+
|
213
|
+
id_conta = 56 # Integer | ID da Conta
|
214
|
+
|
215
|
+
id_cartao = 56 # Integer | ID do Cart\u00C3\u00A3o que deseja consultar o saldo/limite
|
216
|
+
|
217
|
+
opts = {
|
218
|
+
codigo_segurancao: "codigo_segurancao_example" # String | C\u00C3\u00B3digo seguran\u00C3\u00A7a do cart\u00C3\u00A3o
|
219
|
+
}
|
220
|
+
|
221
|
+
begin
|
222
|
+
#/contas/{idConta}/cartoes/{idCartao}/desbloquear
|
223
|
+
result = api_instance.desbloquear_cartao_using_post(id_conta, id_cartao, opts)
|
224
|
+
p result
|
225
|
+
rescue Pier::ApiError => e
|
226
|
+
puts "Exception when calling CartaoApi->desbloquear_cartao_using_post: #{e}"
|
227
|
+
end
|
228
|
+
```
|
229
|
+
|
230
|
+
### Parameters
|
231
|
+
|
232
|
+
Name | Type | Description | Notes
|
233
|
+
------------- | ------------- | ------------- | -------------
|
234
|
+
**id_conta** | **Integer**| ID da Conta |
|
235
|
+
**id_cartao** | **Integer**| ID do Cart\u00C3\u00A3o que deseja consultar o saldo/limite |
|
236
|
+
**codigo_segurancao** | **String**| C\u00C3\u00B3digo seguran\u00C3\u00A7a do cart\u00C3\u00A3o | [optional]
|
237
|
+
|
238
|
+
### Return type
|
239
|
+
|
240
|
+
[**DesbloquearCartaoResponse**](DesbloquearCartaoResponse.md)
|
241
|
+
|
242
|
+
### Authorization
|
243
|
+
|
244
|
+
[access_token](../README.md#access_token)
|
245
|
+
|
246
|
+
### HTTP request headers
|
247
|
+
|
248
|
+
- **Content-Type**: application/json
|
249
|
+
- **Accept**: application/json
|
250
|
+
|
251
|
+
|
252
|
+
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# Pier::CartaoResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**bin** | **Integer** | | [optional]
|
7
|
+
**cod_retorno** | **Integer** | | [optional]
|
8
|
+
**codigo_desbloqueio** | **String** | | [optional]
|
9
|
+
**criptografia_hsm** | **String** | | [optional]
|
10
|
+
**data_emissao** | **DateTime** | | [optional]
|
11
|
+
**data_validade** | **DateTime** | | [optional]
|
12
|
+
**data_vencimento_padrao** | **String** | | [optional]
|
13
|
+
**descricao_retorno** | **String** | | [optional]
|
14
|
+
**estagio_cartao** | **Integer** | | [optional]
|
15
|
+
**estagio_data** | **DateTime** | | [optional]
|
16
|
+
**flag_reversao** | **BOOLEAN** | | [optional]
|
17
|
+
**flag_senha** | **BOOLEAN** | | [optional]
|
18
|
+
**id_cartao** | **Integer** | | [optional]
|
19
|
+
**id_conta** | **Integer** | | [optional]
|
20
|
+
**id_emissor** | **Integer** | | [optional]
|
21
|
+
**id_log** | **String** | | [optional]
|
22
|
+
**id_pessoa_fisica** | **Integer** | | [optional]
|
23
|
+
**id_produto** | **Integer** | | [optional]
|
24
|
+
**numero_cartao** | **String** | | [optional]
|
25
|
+
**numero_cartao_real** | **String** | | [optional]
|
26
|
+
**status_cartao** | **Integer** | | [optional]
|
27
|
+
**status_data** | **DateTime** | | [optional]
|
28
|
+
|
29
|
+
|