3
I am getting the following error return from Webservice when I try to send XML
<?xml version="1.0" encoding="UTF-8" ?>
<RetornoEnvioRPS xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.prefeitura.sp.gov.br/nfe">
<Cabecalho Versao="1" xmlns="">
<Sucesso>false</Sucesso>
</Cabecalho>
<Erro xmlns="">
<Codigo>1001</Codigo>
<Descricao>XML não compatível com Schema.The element 'PedidoEnvioRPS' in namespace 'http://www.prefeitura.sp.gov.br/nfe' has invalid child element 'RPS' in namespace 'http://www.prefeitura.sp.gov.br/nfe'. List of possible elements expected: 'RPS'.</Descricao>
</Erro>
</RetornoEnvioRPS>
The sending XML is as follows:
<?xml version="1.0" encoding="UTF-8"?>
<PedidoEnvioRPS xmlns="http://www.prefeitura.sp.gov.br/nfe" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Cabecalho xmlns="" Versao="1">
<CPFCNPJRemetente>
<CNPJ>53002458000101</CNPJ>
</CPFCNPJRemetente>
</Cabecalho>
<RPS>
<Assinatura>UjBsR09EbGhjZ0dTQUxNQUFBUUNBRU1tQ1p0dU1GUXhEUzhi</Assinatura>
<ChaveRPS>
<InscricaoPrestador>33959249</InscricaoPrestador>
<SerieRPS>00001</SerieRPS>
<NumeroRPS>000000000001</NumeroRPS>
</ChaveRPS>
<TipoRPS>RPS-M</TipoRPS>
<DataEmissao>1957-08-13</DataEmissao>
<StatusRPS>N</StatusRPS>
<TributacaoRPS>F</TributacaoRPS>
<ValorServicos>0</ValorServicos>
<ValorDeducoes>0</ValorDeducoes>
<CodigoServico>0000</CodigoServico>
<AliquotaServicos>0</AliquotaServicos>
<ISSRetido>false</ISSRetido>
-<CPFCNPJTomador>
<CPF>13167474254</CPF>
</CPFCNPJTomador>
<RazaoSocialTomador>TOMADOR PF</RazaoSocialTomador>
<EnderecoTomador>
<TipoLogradouro>Av</TipoLogradouro>
<Logradouro>Paulista</Logradouro>
<NumeroEndereco>100</NumeroEndereco>
<ComplementoEndereco>Cj 35</ComplementoEndereco>
<Bairro>Bela Vista</Bairro>
<Cidade>3550308</Cidade>
<UF>SP</UF>
<CEP>1310100</CEP>
</EnderecoTomador>
<EmailTomador>[email protected]</EmailTomador>
<Discriminacao>Desenvolvimento de Web Site Pessoal.</Discriminacao>
</RPS>
</PedidoEnvioRPS>
I’m working on VB.net.
Which web service address you added as a reference in your project?
– rubStackOverflow
That: https://nfe.prefeitura.sp.gov.br/ws/lotenfe.asmx
– Felipe S