nfse-carioca 0.2.6 → 0.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/lib/nfse_carioca.rb +4 -0
- data/lib/nfse_carioca/gerar_nfse.rb +4 -0
- data/lib/nfse_carioca/gerar_nfse_xml.rb +121 -85
- data/lib/nfse_carioca/version.rb +1 -1
- data/nfse_carioca.gemspec +3 -2
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_CancelarNFSe/_execute_/when_NFSeCarioca_rps_number_does_not_exist/returns_error_message.yml +4 -4
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_CancelarNFSe/_execute_/when_NFSeCarioca_rps_number_does_not_exist/returns_false.yml +4 -4
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_CancelarNFSe/_execute_/when_NFSeCarioca_rps_number_exist/returns_false.yml +8 -8
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NFSeCarioca_rps_number_already_exist/responds_with_error.yml +14 -66
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NFSeCarioca_rps_number_already_exist/responds_with_error_code_E10_.yml +248 -0
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NFSeCarioca_rps_number_already_exist/responds_with_error_message_E10_.yml +248 -0
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NFSeCarioca_rps_number_already_exist/responds_with_message_error_E10_.yml +14 -66
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NFSeCarioca_rps_number_does_not_exist_yet/generates_NFSeCarioca.yml +22 -74
- data/spec/fixtures/vcr_cassettes/NFSeCarioca_GerarNFSe/_call/when_NfseCarioca_has_only_the_minimum_values/generates_NfseCarioca.yml +20 -59
- data/spec/lib/nfse_carioca/cancelar_nfse_spec.rb +1 -9
- data/spec/lib/nfse_carioca/gerar_nfse_spec.rb +58 -52
- data/spec/spec_helper.rb +17 -0
- metadata +23 -8
- data/spec/support/helpers.rb +0 -21
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6282479d661761e2fe03193f119ad2566db6b95b
|
4
|
+
data.tar.gz: 63b0cef1b5d02b174b4173039a4d8838133acd8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ab2714d18995c0600253b61301e69ff52446b535d3814f32b374ff3e009c8db5caf89ed62059dfa0a2d74c1270deb1684ffc3293a5f78c9a91f1def502e24023
|
7
|
+
data.tar.gz: cb1492eb526f16c7826e2dfc3e725a75659a43a92c57b098f2105c391544de2f8a3d819a94e7b38e3c633ad802e0f3ac260b3512730f7e0cac9d7514dd779fae
|
data/.gitignore
CHANGED
data/lib/nfse_carioca.rb
CHANGED
@@ -1,4 +1,6 @@
|
|
1
1
|
require "ostruct"
|
2
|
+
require "active_model"
|
3
|
+
|
2
4
|
require "nfse_carioca/version"
|
3
5
|
require "nfse_carioca/configuration"
|
4
6
|
require "nfse_carioca/client"
|
@@ -6,6 +8,8 @@ require "nfse_carioca/response"
|
|
6
8
|
require "nfse_carioca/gerar_nfse"
|
7
9
|
require "nfse_carioca/cancelar_nfse"
|
8
10
|
|
11
|
+
HTTPI.adapter = :net_http
|
12
|
+
|
9
13
|
module NfseCarioca
|
10
14
|
def self.configure(&block)
|
11
15
|
yield configuration
|
@@ -5,93 +5,129 @@ module NfseCarioca
|
|
5
5
|
end
|
6
6
|
|
7
7
|
def to_xml
|
8
|
-
xml
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
8
|
+
Gyoku.xml(
|
9
|
+
"GerarNfseEnvio" => {
|
10
|
+
"@xmlns" => "http://notacarioca.rio.gov.br/WSNacional/XSD/1/nfse_pcrj_v01.xsd",
|
11
|
+
"Rps" => {
|
12
|
+
"InfRps" => {
|
13
|
+
"@xmlns" => "http://www.abrasf.org.br/ABRASF/arquivos/nfse.xsd",
|
14
|
+
"@Id" => @invoice[:identification_number],
|
15
|
+
"IdentificacaoRps" => {
|
16
|
+
"Numero" => @invoice[:identification_number],
|
17
|
+
"Serie" => NfseCarioca.configuration.rps_serie,
|
18
|
+
"Tipo" => NfseCarioca.configuration.rps_tipo
|
19
|
+
},
|
20
|
+
|
21
|
+
"DataEmissao" => Time.now.strftime("%Y-%m-%dT%H:%M:%S"),
|
22
|
+
"NaturezaOperacao" => NfseCarioca.configuration.rps_natureza_operacao,
|
23
|
+
"OptanteSimplesNacional" => NfseCarioca.configuration.rps_optante_simples_nacional,
|
24
|
+
"IncentivadorCultural" => NfseCarioca.configuration.rps_incentivador_cultural,
|
25
|
+
"Status" => 1,
|
26
|
+
|
27
|
+
"Servico" => {
|
28
|
+
"Valores" => {
|
29
|
+
"ValorServicos" => @invoice[:total],
|
30
|
+
"ValorPis" => NfseCarioca.configuration.valor_pis,
|
31
|
+
"ValorCofins" => NfseCarioca.configuration.valor_cofins,
|
32
|
+
"ValorInss" => NfseCarioca.configuration.valor_inss,
|
33
|
+
"ValorIr" => NfseCarioca.configuration.valor_ir,
|
34
|
+
"ValorCsll" => NfseCarioca.configuration.valor_csll,
|
35
|
+
"IssRetido" => NfseCarioca.configuration.iss_retido,
|
36
|
+
"ValorIss" => NfseCarioca.configuration.valor_iss,
|
37
|
+
"Aliquota" => NfseCarioca.configuration.valor_aliquota
|
38
|
+
},
|
39
|
+
|
40
|
+
"ItemListaServico" => NfseCarioca.configuration.item_lista_servico,
|
41
|
+
|
42
|
+
"CodigoTributacaoMunicipio" => tributacao,
|
43
|
+
"Discriminacao" => @invoice[:description],
|
44
|
+
"CodigoMunicipio" => NfseCarioca.configuration.codigo_municipio
|
45
|
+
},
|
46
|
+
|
47
|
+
"Prestador" => {
|
48
|
+
"Cnpj" => NfseCarioca.configuration.cnpj,
|
49
|
+
"InscricaoMunicipal" => NfseCarioca.configuration.inscricao_municipal
|
50
|
+
},
|
51
|
+
|
52
|
+
"Tomador" => tomador
|
53
|
+
}
|
54
|
+
}
|
55
|
+
}
|
56
|
+
)
|
57
|
+
end
|
58
|
+
|
59
|
+
def tributacao
|
60
|
+
tributacao = NfseCarioca.configuration.codigo_tributacao_municipio
|
61
|
+
|
62
|
+
if @invoice[:tax_benefit]
|
63
|
+
"#{@invoice[:tax_benefit]}#{tributacao}"
|
64
|
+
else
|
65
|
+
tributacao
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
def phone_number
|
70
|
+
number = @invoice[:customer][:phone_number].to_s.scan(/\d/).join.to_i.to_s
|
71
|
+
|
72
|
+
if number.size > 11
|
73
|
+
limit = number.size - 10
|
74
|
+
number[limit..11]
|
75
|
+
else
|
76
|
+
number
|
77
|
+
end
|
78
|
+
end
|
79
|
+
|
80
|
+
def complement
|
81
|
+
|
82
|
+
end
|
83
|
+
|
84
|
+
def document_type
|
85
|
+
@invoice[:customer][:document_type]
|
86
|
+
end
|
87
|
+
|
88
|
+
def document_number
|
89
|
+
@invoice[:customer][:document_number]
|
90
|
+
end
|
91
|
+
|
92
|
+
def tomador
|
93
|
+
xml = {}
|
94
|
+
|
95
|
+
if document_type.present?
|
96
|
+
xml["IdentificacaoTomador"] = {
|
97
|
+
"CpfCnpj" => { document_type => document_number }
|
98
|
+
}
|
99
|
+
end
|
100
|
+
|
101
|
+
if @invoice[:customer][:name].present?
|
102
|
+
xml["RazaoSocial"] = @invoice[:customer][:name]
|
103
|
+
end
|
104
|
+
|
105
|
+
if @invoice[:customer][:address].present?
|
106
|
+
xml["Endereco"] = {
|
107
|
+
"Endereco" => @invoice[:customer][:address][:street],
|
108
|
+
"Numero" => @invoice[:customer][:address][:number]
|
109
|
+
}
|
110
|
+
|
111
|
+
if @invoice[:customer][:address][:complement].present?
|
112
|
+
xml["Endereco"]["Complemento"] = @invoice[:customer][:address][:complement]
|
93
113
|
end
|
114
|
+
|
115
|
+
xml["Endereco"]["Bairro"] = @invoice[:customer][:address][:neighborhood]
|
116
|
+
xml["Endereco"]["CodigoMunicipio"] = @invoice[:customer][:address][:city_ibge_code]
|
117
|
+
xml["Endereco"]["Uf"] = @invoice[:customer][:address][:state_code]
|
118
|
+
xml["Endereco"]["Cep"] = @invoice[:customer][:address][:zipcode].scan(/\d/).join
|
119
|
+
end
|
120
|
+
|
121
|
+
if phone_number.present?
|
122
|
+
xml["Contato"] = {
|
123
|
+
"Telefone" => phone_number,
|
124
|
+
"Email" => @invoice[:customer][:email]
|
125
|
+
}
|
126
|
+
else
|
127
|
+
xml["Contato"] = { "Email" => @invoice[:customer][:email] }
|
94
128
|
end
|
129
|
+
|
130
|
+
xml
|
95
131
|
end
|
96
132
|
end
|
97
133
|
end
|
data/lib/nfse_carioca/version.rb
CHANGED
data/nfse_carioca.gemspec
CHANGED
@@ -16,8 +16,8 @@ Gem::Specification.new do |s|
|
|
16
16
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
17
17
|
s.require_paths = ["lib"]
|
18
18
|
|
19
|
-
s.add_dependency "savon", "~> 2.9
|
20
|
-
s.add_dependency "
|
19
|
+
s.add_dependency "savon", "~> 2.9"
|
20
|
+
s.add_dependency "activemodel", "~> 4.0"
|
21
21
|
|
22
22
|
s.add_development_dependency "bundler", "~> 1.7"
|
23
23
|
s.add_development_dependency "rake", "~> 10.0"
|
@@ -25,4 +25,5 @@ Gem::Specification.new do |s|
|
|
25
25
|
s.add_development_dependency "pry"
|
26
26
|
s.add_development_dependency "vcr"
|
27
27
|
s.add_development_dependency "webmock"
|
28
|
+
s.add_development_dependency "dotenv"
|
28
29
|
end
|
@@ -31,7 +31,7 @@ http_interactions:
|
|
31
31
|
X-Powered-By:
|
32
32
|
- ASP.NET
|
33
33
|
Date:
|
34
|
-
-
|
34
|
+
- Mon, 13 Apr 2015 20:45:52 GMT
|
35
35
|
Content-Length:
|
36
36
|
- '1338'
|
37
37
|
body:
|
@@ -169,7 +169,7 @@ http_interactions:
|
|
169
169
|
\ <soap:address location=\"https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx\"
|
170
170
|
/>\r\n </wsdl:port>\r\n </wsdl:service>\r\n</wsdl:definitions>"
|
171
171
|
http_version:
|
172
|
-
recorded_at:
|
172
|
+
recorded_at: Mon, 13 Apr 2015 20:45:51 GMT
|
173
173
|
- request:
|
174
174
|
method: post
|
175
175
|
uri: https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx
|
@@ -222,7 +222,7 @@ http_interactions:
|
|
222
222
|
X-Powered-By:
|
223
223
|
- ASP.NET
|
224
224
|
Date:
|
225
|
-
-
|
225
|
+
- Mon, 13 Apr 2015 20:45:54 GMT
|
226
226
|
Content-Length:
|
227
227
|
- '530'
|
228
228
|
body:
|
@@ -249,5 +249,5 @@ http_interactions:
|
|
249
249
|
c2VSZXNwb3N0YSZndDs8L291dHB1dFhNTD48L0NhbmNlbGFyTmZzZVJlc3Bv
|
250
250
|
bnNlPjwvc29hcDpCb2R5Pjwvc29hcDpFbnZlbG9wZT4=
|
251
251
|
http_version:
|
252
|
-
recorded_at:
|
252
|
+
recorded_at: Mon, 13 Apr 2015 20:45:52 GMT
|
253
253
|
recorded_with: VCR 2.9.3
|
@@ -31,7 +31,7 @@ http_interactions:
|
|
31
31
|
X-Powered-By:
|
32
32
|
- ASP.NET
|
33
33
|
Date:
|
34
|
-
-
|
34
|
+
- Mon, 13 Apr 2015 20:45:54 GMT
|
35
35
|
Content-Length:
|
36
36
|
- '1338'
|
37
37
|
body:
|
@@ -169,7 +169,7 @@ http_interactions:
|
|
169
169
|
\ <soap:address location=\"https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx\"
|
170
170
|
/>\r\n </wsdl:port>\r\n </wsdl:service>\r\n</wsdl:definitions>"
|
171
171
|
http_version:
|
172
|
-
recorded_at:
|
172
|
+
recorded_at: Mon, 13 Apr 2015 20:45:53 GMT
|
173
173
|
- request:
|
174
174
|
method: post
|
175
175
|
uri: https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx
|
@@ -222,7 +222,7 @@ http_interactions:
|
|
222
222
|
X-Powered-By:
|
223
223
|
- ASP.NET
|
224
224
|
Date:
|
225
|
-
-
|
225
|
+
- Mon, 13 Apr 2015 20:45:56 GMT
|
226
226
|
Content-Length:
|
227
227
|
- '530'
|
228
228
|
body:
|
@@ -249,5 +249,5 @@ http_interactions:
|
|
249
249
|
c2VSZXNwb3N0YSZndDs8L291dHB1dFhNTD48L0NhbmNlbGFyTmZzZVJlc3Bv
|
250
250
|
bnNlPjwvc29hcDpCb2R5Pjwvc29hcDpFbnZlbG9wZT4=
|
251
251
|
http_version:
|
252
|
-
recorded_at:
|
252
|
+
recorded_at: Mon, 13 Apr 2015 20:45:55 GMT
|
253
253
|
recorded_with: VCR 2.9.3
|
@@ -31,7 +31,7 @@ http_interactions:
|
|
31
31
|
X-Powered-By:
|
32
32
|
- ASP.NET
|
33
33
|
Date:
|
34
|
-
-
|
34
|
+
- Mon, 13 Apr 2015 20:46:46 GMT
|
35
35
|
Content-Length:
|
36
36
|
- '1338'
|
37
37
|
body:
|
@@ -169,7 +169,7 @@ http_interactions:
|
|
169
169
|
\ <soap:address location=\"https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx\"
|
170
170
|
/>\r\n </wsdl:port>\r\n </wsdl:service>\r\n</wsdl:definitions>"
|
171
171
|
http_version:
|
172
|
-
recorded_at:
|
172
|
+
recorded_at: Mon, 13 Apr 2015 20:46:45 GMT
|
173
173
|
- request:
|
174
174
|
method: post
|
175
175
|
uri: https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx
|
@@ -179,9 +179,9 @@ http_interactions:
|
|
179
179
|
<?xml version="1.0" encoding="UTF-8"?><soap:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://notacarioca.rio.gov.br/" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><CancelarNfseRequest><inputXML><?xml version="1.0" encoding="UTF-8"?>
|
180
180
|
<CancelarNfseEnvio xmlns="http://www.abrasf.org.br/ABRASF/arquivos/nfse.xsd">
|
181
181
|
<Pedido xmlns="http://www.abrasf.org.br/ABRASF/arquivos/nfse.xsd">
|
182
|
-
<InfPedidoCancelamento Id="
|
182
|
+
<InfPedidoCancelamento Id="Cancelamento_NF70">
|
183
183
|
<IdentificacaoNfse>
|
184
|
-
<Numero>
|
184
|
+
<Numero>70</Numero>
|
185
185
|
<Cnpj>12390095000186</Cnpj>
|
186
186
|
<InscricaoMunicipal>04807995</InscricaoMunicipal>
|
187
187
|
<CodigoMunicipio>3304557</CodigoMunicipio>
|
@@ -222,9 +222,9 @@ http_interactions:
|
|
222
222
|
X-Powered-By:
|
223
223
|
- ASP.NET
|
224
224
|
Date:
|
225
|
-
-
|
225
|
+
- Mon, 13 Apr 2015 20:46:47 GMT
|
226
226
|
Content-Length:
|
227
|
-
- '
|
227
|
+
- '588'
|
228
228
|
body:
|
229
229
|
encoding: ASCII-8BIT
|
230
230
|
string: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
|
@@ -232,7 +232,7 @@ http_interactions:
|
|
232
232
|
xmlns="http://notacarioca.rio.gov.br/"><outputXML><CancelarNfseResposta
|
233
233
|
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
234
234
|
xmlns="http://www.abrasf.org.br/ABRASF/arquivos/nfse.xsd"><Cancelamento><Confirmacao
|
235
|
-
Id="
|
235
|
+
Id="35903"><Pedido><InfPedidoCancelamento Id="35903"><IdentificacaoNfse><Numero>70</Numero><Cnpj>12390095000186</Cnpj><InscricaoMunicipal>4807995</InscricaoMunicipal><CodigoMunicipio>3304557</CodigoMunicipio></IdentificacaoNfse><CodigoCancelamento>9</CodigoCancelamento></InfPedidoCancelamento></Pedido><DataHoraCancelamento>2015-04-13T17:46:46</DataHoraCancelamento></Confirmacao></Cancelamento></CancelarNfseResposta></outputXML></CancelarNfseResponse></soap:Body></soap:Envelope>
|
236
236
|
http_version:
|
237
|
-
recorded_at:
|
237
|
+
recorded_at: Mon, 13 Apr 2015 20:46:46 GMT
|
238
238
|
recorded_with: VCR 2.9.3
|
@@ -31,7 +31,7 @@ http_interactions:
|
|
31
31
|
X-Powered-By:
|
32
32
|
- ASP.NET
|
33
33
|
Date:
|
34
|
-
-
|
34
|
+
- Mon, 13 Apr 2015 20:45:45 GMT
|
35
35
|
Content-Length:
|
36
36
|
- '1338'
|
37
37
|
body:
|
@@ -169,80 +169,28 @@ http_interactions:
|
|
169
169
|
\ <soap:address location=\"https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx\"
|
170
170
|
/>\r\n </wsdl:port>\r\n </wsdl:service>\r\n</wsdl:definitions>"
|
171
171
|
http_version:
|
172
|
-
recorded_at:
|
172
|
+
recorded_at: Mon, 13 Apr 2015 20:45:44 GMT
|
173
173
|
- request:
|
174
174
|
method: post
|
175
175
|
uri: https://homologacao.notacarioca.rio.gov.br/WSNacional/nfse.asmx
|
176
176
|
body:
|
177
177
|
encoding: UTF-8
|
178
|
-
string:
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
</IdentificacaoRps>
|
188
|
-
<DataEmissao>2015-02-05T17:59:01</DataEmissao>
|
189
|
-
<NaturezaOperacao>1</NaturezaOperacao>
|
190
|
-
<OptanteSimplesNacional>1</OptanteSimplesNacional>
|
191
|
-
<IncentivadorCultural>2</IncentivadorCultural>
|
192
|
-
<Status>1</Status>
|
193
|
-
<Servico>
|
194
|
-
<Valores>
|
195
|
-
<ValorServicos>12.0</ValorServicos>
|
196
|
-
<ValorPis>0</ValorPis>
|
197
|
-
<ValorCofins>0</ValorCofins>
|
198
|
-
<ValorInss>0</ValorInss>
|
199
|
-
<ValorIr>0</ValorIr>
|
200
|
-
<ValorCsll>0</ValorCsll>
|
201
|
-
<IssRetido>2</IssRetido>
|
202
|
-
<ValorIss>0</ValorIss>
|
203
|
-
<Aliquota>0</Aliquota>
|
204
|
-
</Valores>
|
205
|
-
<ItemListaServico>0105</ItemListaServico>
|
206
|
-
<CodigoTributacaoMunicipio>010501</CodigoTributacaoMunicipio>
|
207
|
-
<Discriminacao>Venda do Serviço XYZ.</Discriminacao>
|
208
|
-
<CodigoMunicipio>3304557</CodigoMunicipio>
|
209
|
-
</Servico>
|
210
|
-
<Prestador>
|
211
|
-
<Cnpj>12390095000186</Cnpj>
|
212
|
-
<InscricaoMunicipal>04807995</InscricaoMunicipal>
|
213
|
-
</Prestador>
|
214
|
-
<Tomador>
|
215
|
-
<IdentificacaoTomador>
|
216
|
-
<CpfCnpj>
|
217
|
-
<Cnpj>98924674000187</Cnpj>
|
218
|
-
</CpfCnpj>
|
219
|
-
</IdentificacaoTomador>
|
220
|
-
<RazaoSocial>XPTO Tecnologia Ltda.</RazaoSocial>
|
221
|
-
<Endereco>
|
222
|
-
<Endereco>Rua qualquer nome</Endereco>
|
223
|
-
<Numero>33</Numero>
|
224
|
-
<Complemento>Sala 1</Complemento>
|
225
|
-
<Bairro>Seu bairro</Bairro>
|
226
|
-
<CodigoMunicipio>3550308</CodigoMunicipio>
|
227
|
-
<Uf>SP</Uf>
|
228
|
-
<Cep>22255777</Cep>
|
229
|
-
</Endereco>
|
230
|
-
<Contato>
|
231
|
-
<Telefone>2222-2222</Telefone>
|
232
|
-
<Email>customer@example.com</Email>
|
233
|
-
</Contato>
|
234
|
-
</Tomador>
|
235
|
-
</InfRps>
|
236
|
-
</Rps>
|
237
|
-
</GerarNfseEnvio>
|
238
|
-
</inputXML></GerarNfseRequest></soap:Body></soap:Envelope>
|
178
|
+
string: <?xml version="1.0" encoding="UTF-8"?><soap:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
179
|
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://notacarioca.rio.gov.br/"
|
180
|
+
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><GerarNfseRequest><inputXML><GerarNfseEnvio
|
181
|
+
xmlns="http://notacarioca.rio.gov.br/WSNacional/XSD/1/nfse_pcrj_v01.xsd"><Rps><InfRps
|
182
|
+
xmlns="http://www.abrasf.org.br/ABRASF/arquivos/nfse.xsd" Id="1030"><IdentificacaoRps><Numero>1030</Numero><Serie>A</Serie><Tipo>1</Tipo></IdentificacaoRps><DataEmissao>2015-04-13T17:45:43</DataEmissao><NaturezaOperacao>1</NaturezaOperacao><OptanteSimplesNacional>1</OptanteSimplesNacional><IncentivadorCultural>2</IncentivadorCultural><Status>1</Status><Servico><Valores><ValorServicos>12.0</ValorServicos><ValorPis>0</ValorPis><ValorCofins>0</ValorCofins><ValorInss>0</ValorInss><ValorIr>0</ValorIr><ValorCsll>0</ValorCsll><IssRetido>2</IssRetido><ValorIss>0</ValorIss><Aliquota>0</Aliquota></Valores><ItemListaServico>0105</ItemListaServico><CodigoTributacaoMunicipio>010501</CodigoTributacaoMunicipio><Discriminacao>Venda
|
183
|
+
do Serviço XYZ.</Discriminacao><CodigoMunicipio>3304557</CodigoMunicipio></Servico><Prestador><Cnpj>12390095000186</Cnpj><InscricaoMunicipal>04807995</InscricaoMunicipal></Prestador><Tomador><IdentificacaoTomador><CpfCnpj><Cnpj>98924674000187</Cnpj></CpfCnpj></IdentificacaoTomador><RazaoSocial>XPTO
|
184
|
+
Tecnologia Ltda.</RazaoSocial><Endereco><Endereco>Rua qualquer
|
185
|
+
nome</Endereco><Numero>33</Numero><Complemento>Sala
|
186
|
+
1</Complemento><Bairro>Seu bairro</Bairro><CodigoMunicipio>3550308</CodigoMunicipio><Uf>SP</Uf><Cep>22255777</Cep></Endereco><Contato><Telefone>2222-2222</Telefone><Email>customer@example.com</Email></Contato></Tomador></InfRps></Rps></GerarNfseEnvio></inputXML></GerarNfseRequest></soap:Body></soap:Envelope>
|
239
187
|
headers:
|
240
188
|
Soapaction:
|
241
189
|
- '"http://notacarioca.rio.gov.br/GerarNfse"'
|
242
190
|
Content-Type:
|
243
191
|
- text/xml;charset=UTF-8
|
244
192
|
Content-Length:
|
245
|
-
- '
|
193
|
+
- '2420'
|
246
194
|
Accept-Encoding:
|
247
195
|
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
248
196
|
Accept:
|
@@ -267,7 +215,7 @@ http_interactions:
|
|
267
215
|
X-Powered-By:
|
268
216
|
- ASP.NET
|
269
217
|
Date:
|
270
|
-
-
|
218
|
+
- Mon, 13 Apr 2015 20:45:45 GMT
|
271
219
|
Content-Length:
|
272
220
|
- '575'
|
273
221
|
body:
|
@@ -296,5 +244,5 @@ http_interactions:
|
|
296
244
|
PC9HZXJhck5mc2VSZXNwb25zZT48L3NvYXA6Qm9keT48L3NvYXA6RW52ZWxv
|
297
245
|
cGU+
|
298
246
|
http_version:
|
299
|
-
recorded_at:
|
247
|
+
recorded_at: Mon, 13 Apr 2015 20:45:45 GMT
|
300
248
|
recorded_with: VCR 2.9.3
|