WS501 - Consult Import Protocol
Click here to see version history
| Update date | Service publication date | Changes |
|---|---|---|
| 04/15/2021 | 04/15/2021 | Creation of v3 |
| 10/22/2026 | — | Documented status / resultado messages in the Response |
Objective
This integration aims to provide consultation on the progress of imports using the protocols received.
Method description
Método |
getImportProtocolStatus |
Versão |
3 |
WSDL principal |
https://soap.comprovei.com.br/importQueue/v3/index.php?wsdl |
WSDL de contingência |
https://soapcontingencia.comprovei.com.br/importQueue/v3/index.php?wsdl |
Important
- The connection to our service must be made to our main server, however we strongly suggest that a connection to our contingency server is also made available, as a guarantee of the availability of our services. The contingency server is only turned on in situations where our main server is unavailable. Making the connection url parameterizable is also a good practice;
- Our connections are secure using the SSL protocol. For security reasons, our certificates are constantly changed without prior notice. Therefore, it is recommended that you do not develop integrations based on a fixed certificate.
- We constantly (and without prior notice) add new fields and structures to both requests and responses from our web services. Anyone who uses our webservices must implement it in such a way that the programs that consume these webservices do not stop working when the mentioned field changes occur.
Version
You are accessing version 3 of our integration system. If you wish to consult the previous version, click here.
Features
- Calls will be made via
SOAPover HTTPS; - The origin of the
Web Servicecall will be the client's system;
Authentication
- Calls will have message-level authentication (SOAP Header);
- Request the
username/passwordfrom the account administrator.
Request
The request for our Web Service is composed as follows:
Header
Within the <Credentials> TAG:
| TAG | Type | Description |
|---|---|---|
Usuario |
string | User for authentication. |
Senha |
string | User password for authentication |
Body
Inside the <getImportProtocolStatus> TAG:
| TAG | Type | Description |
|---|---|---|
protocolo |
string | Protocol for checking the progress of the import request. |
Request Example
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Header>
<Credenciais xmlns="WebServiceComprovei">
<Usuario>usuario</Usuario>
<Senha>senha</Senha>
</Credenciais>
</Header>
<Body>
<getImportProtocolStatus xmlns="WebServiceComprovei:getImportProtocolStatus">
<protocolo>20170804598506cf87a0d</protocolo>
</getImportProtocolStatus>
</Body>
</Envelope>
Response
Our Web Service responds to you as follows:
| TAG | Type | Description |
|---|---|---|
status |
string | Success or error message for the method call. |
protocolo |
string | Protocol informed in the request. |
metodo |
string | Method requested when generating the import. |
dataCriacao |
string | Date and time of the import request. |
dataConclusao |
string | Date and time the import was completed. |
processado |
string | Sim or Não indicating that the import has already been processed. |
resultado |
string | Import success or error message (synchronous acceptance or asynchronous processing). |
status values
API message literals are returned in Portuguese (as below).
status |
Note |
|---|---|
Protocolo encontrado. |
Lookup ok; see resultado |
Protocolo não encontrado. |
Unknown protocol |
Por favor, envie o número de protocolo para a consulta. |
Empty protocol |
Usuário não autenticado! |
999 |
Método não autorizado para o seu usuário! |
998 |
Typical resultado values
The resultado field may have been written at acceptance (synchronous error / duplicate file) or during asynchronous processing.
Document processing
| Message (template) | Success |
|---|---|
Documentos importados com sucesso! |
yes |
{n} Documentos importados. O restante apresentou estes erros: + - Documento {key}: {value} |
partial |
Nenhum documento importado. Aconteceram os seguintes erros: + lines |
no |
- Algum alertas foram gerados durante a importação: |
warning |
Erro ao inserir o cliente! Parada: {n} - {error} |
per document |
Erro ao inserir o documento! Parada: {n} - {error} |
per document |
Documento não encontrado após inserção! dkey: {dkey} |
per document |
Importado com sucesso, mas sem adicionar na fila de replicação! |
warning |
Importado com sucesso, mas sem adicionar os itens na fila de replicação! |
warning |
Route processing
| Message (template) | Success |
|---|---|
Rota enviada para processamento. Por favor, aguarde alguns segundos. |
yes (deferred) |
Rota importada com sucesso! |
yes |
Falha ao enviar rota para fila SQS. Tente novamente. |
no |
Erro ao inserir na imports! - {error} |
no |
Erro ao inserir a base de origem! - {error} |
no |
Erro ao inserir a base de destino! - {error} |
no |
Erro ao inserir a rota! - {error} |
no |
Erro ao cadastrar tipo de veiculo! |
no |
Erro ao inserir no histórico! / Erro ao inserir no log! |
no |
Erro ao inserir o cliente/documento/parada/itens/...! Parada: {n} |
no |
Verbo {verb} não implementado. |
no |
Idempotency / reprocessing
| Message |
|---|
Protocolo já em processamento! |
Protocolo já processado! |
ETag não encontrado |
Response Example
<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:WebServiceComprovei" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body>
<ns1:getImportProtocolStatusResponse>
<status xsi:type="xsd:string">Protocolo encontrado.</status>
<protocolo xsi:type="xsd:string">20170804598506cf87a0d</protocolo>
<metodo xsi:type="xsd:string">uploadRoute</metodo>
<dataCriacao xsi:type="xsd:string">04/08/2017 20:44:15</dataCriacao>
<dataConclusao xsi:type="xsd:string">04/08/2017 20:44:34</dataConclusao>
<processado xsi:type="xsd:string">Sim</processado>
<resultado xsi:type="xsd:string">Rota importada com sucesso!</resultado>
</ns1:getImportProtocolStatusResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>