MPGateway


Click here for a complete list of operations.

MPG_Send_SMS

Envio de SMS Síncrono.

Parâmetros da MPG_Send_SMS: Versão 01r33
----------------------------------------------------------------------------------------------------------------------------------
Credencial - Obrigatório - Chave de 20 posições para acesso ao Mobile Pronto Gateway. Esta chave é única
Principal_User - Obrigatório - Código do Usuário Principal para autenticar no Gateway. Normalmente o CNPJ ou CPF
Aux_User - Obrigatório - Código do Usuário Auxiliar/Apoio para qualificar a Mensagem
Mobile - Obrigatório - Celular que receberá o SMS. Formato mundial: +99(999)99999999, sendo pais,ddd e mobile
Send_Project - Obrigatório - Se (S)im a sigla da mensagem vem no início.
Se (N)ão não vem. Tamanho máximo=9 (XXXXXXXX:).
Exemplo: MPG:
Message - Obrigatório - Mensagem que será enviada ao mobile. Tamanho máximo de 142 posições.

Tipos de Retorno:
----------------------------------------------------------------------------------------------------------------------------------
000 - Mensagem enviada com Sucesso.
----------------------------------------------------------------------------------------------------------------------------------
001 - Credencial Inválida/ Invalid Credencial.
002 - Cod Usuario Principal Inválido/Principal User Invalid.
003 - Cod Usuario Principal não é da Credencial/Principal User x Credencial Invalid.
004 - Cod Usuario Auxiliar Inválido. É obrigatório para empresa centralizadora/Aux User is necessary.
005 - Mobile Inválido/Invalid Mobile -> Format +999999(999999)9999999999
006 - Pais do Telefone Destino Inválido/Invalid Country
007 - Flag Envia_Projeto tem que ser S ou N/Send Project need to be Y or N
008 - Mensagem ou Nome_Projeto+Mensagem > que 142 posições/ Message plus Send_Project > 142
009 - Sem crédito para envio de SMS. Favor repor/Out of credit
010 - Usuário da Empresa está com Telefone Inválido, impossibilitando o envio de aviso de estoque mínimo/
011 - Pais do Telefone Usuário da Empresa Inválido/
012 - Número de Telefone Celular no formato padrão, mas incorreto
013 - Mensagem Vazia ou Corpo Inválido
014 - Data programada inválida - Formato correto = dd/MM/yyyy hh:mm >>> Somente na Versão 02r00
015 - ID da Mensagem informado ultrapassou 40 posições >>> Somente na Versão 02r00
016 - ID da Mensagem já foi informado >>> Somente na Versão 02r00
017 - Entrega da Mensagem Cancelada
018 - Erro no Envio do SMS de Aviso de Estoque Mínimo
-----------------------------------------------------------------------------------------------------------------------------------
De 800 a 880 - Falha no MPGateway. Avise ao Suporte Mobile Pronto
900 - MPGateway indisponível
De 990 a 999 - Erro no acesso as operadoras. Contate Equipe Mobile Pronto
-----------------------------------------------------------------------------------------------------------------------------------

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 /Service.asmx HTTP/1.1
Host: www.mpgateway.com
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://www.mpgateway.com/MPG_Send_SMS"

<?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_Send_SMS xmlns="http://www.mpgateway.com/">
      <Credencial>string</Credencial>
      <Principal_User>string</Principal_User>
      <Aux_User>string</Aux_User>
      <Mobile>string</Mobile>
      <Send_Project>string</Send_Project>
      <Message>string</Message>
    </MPG_Send_SMS>
  </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_Send_SMSResponse xmlns="http://www.mpgateway.com/">
      <MPG_Send_SMSResult>string</MPG_Send_SMSResult>
    </MPG_Send_SMSResponse>
  </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 /Service.asmx HTTP/1.1
Host: www.mpgateway.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_Send_SMS xmlns="http://www.mpgateway.com/">
      <Credencial>string</Credencial>
      <Principal_User>string</Principal_User>
      <Aux_User>string</Aux_User>
      <Mobile>string</Mobile>
      <Send_Project>string</Send_Project>
      <Message>string</Message>
    </MPG_Send_SMS>
  </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_Send_SMSResponse xmlns="http://www.mpgateway.com/">
      <MPG_Send_SMSResult>string</MPG_Send_SMSResult>
    </MPG_Send_SMSResponse>
  </soap12:Body>
</soap12:Envelope>