PWGatewaySMS


Click here for a complete list of operations.

MPG_Query01

Consulta 01.

Parâmetros da MPG_Query01: Versão: v_2_00
----------------------------------------------------------------------------------------------------------------------------------
Credencial - Obrigatório - Chave de 40 posições para acesso ao Mobile Pronto Gateway. Esta chave é única.
Start_Date - Obrigatório - Data Inicial da Pesquisa.Formato: dd/MM/yyyy.
End_Date - Obrigatório - Data Final da Pesquisa.Formato: dd/MM/yyyy.
Aux_User - Obrigatório - Código do Usuário Auxiliar/Qualificar da Mensagem. Máx.=20 posições. Se > 20 será truncado. Pode ser Vazio.
Mobile - Obrigatório - Celular que receberá o SMS. Formato: +99(999)99999999, sendo pais,ddd e mobile. Pode ser Vazio.
Status_Code - Obrigatório, mas será considerado 1 se não for informado.
Se 1 - SMS enviado com sucesso.
Se 0 - SMS enviado com erro de crítica.
Se 2 - Ambos
Status - Obrigatório - Retorna o código de erro. Se Vazio não houve erro.
Se o número de linhas a ser retornado for maior que 1000 o método retornará somente 1000 linhas.


Tipos de Retorno com Erro: XML vazio
-----------------------------------------------------------------------------------------------------------------------------------
Campo Status vem com:
001 - Credencial Inválida/Invalid Credencial.
002 - Start_Date Inválida/Invalid Start_Date.
003 - End_Date Inválida/Invalid End_Date.
005 - Mobile fora do formato-Formato +999(9999)99999999/Invalid phone number - non-standard
890 - Falha no método MPG_Query01. Avise ao Suporte Mobile Pronto - support@mobilepronto.org.

Tipos de Retorno OK: XML com o resultado solicitado. Serão retornados no máximo 1000 registros.
-----------------------------------------------------------------------------------------------------------------------------------

Test

The test form is only available for requests from the local machine.

SOAP 1.1

The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.

POST /sms/v_2_00/service.asmx HTTP/1.1
Host: pw-api.com
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "PWGateway/MPG_Query01"

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <MPG_Query01 xmlns="PWGateway">
      <Credencial>string</Credencial>
      <Start_Date>string</Start_Date>
      <End_Date>string</End_Date>
      <Aux_User>string</Aux_User>
      <Mobile>string</Mobile>
      <Status_Code>int</Status_Code>
      <Status>string</Status>
    </MPG_Query01>
  </soap:Body>
</soap:Envelope>
HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <MPG_Query01Response xmlns="PWGateway">
      <MPG_Query01Result>
        <xsd:schema>schema</xsd:schema>xml</MPG_Query01Result>
      <Status>string</Status>
    </MPG_Query01Response>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

The following is a sample SOAP 1.2 request and response. The placeholders shown need to be replaced with actual values.

POST /sms/v_2_00/service.asmx HTTP/1.1
Host: pw-api.com
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <MPG_Query01 xmlns="PWGateway">
      <Credencial>string</Credencial>
      <Start_Date>string</Start_Date>
      <End_Date>string</End_Date>
      <Aux_User>string</Aux_User>
      <Mobile>string</Mobile>
      <Status_Code>int</Status_Code>
      <Status>string</Status>
    </MPG_Query01>
  </soap12:Body>
</soap12:Envelope>
HTTP/1.1 200 OK
Content-Type: application/soap+xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <MPG_Query01Response xmlns="PWGateway">
      <MPG_Query01Result>
        <xsd:schema>schema</xsd:schema>xml</MPG_Query01Result>
      <Status>string</Status>
    </MPG_Query01Response>
  </soap12:Body>
</soap12:Envelope>