Documentação da tabela grupos

Endpoints de grupos da integração MPM+ (POST, GET e PUT). Base de produção: https://mobtef.conexaoapi.com.br/mpm. Base de homologação: https://mobtef-homolog.conexaoapi.com.br/mpm.

Tabela grupos

POST /grupos

POST https://mobtef.conexaoapi.com.br/mpm/grupos
Campos e tipos (headers)
Campo Tipo
empresa_idint
tokenstring
dispositivo_idint
dispositivo_modelint
dispositivo_tipoint
app_versaoint
app_nomestring
plataformastring
Content-Typestring (application/json)
Exemplo de headers
[
  { "key": "empresa_id", "value": 980 },
  { "key": "token", "value": "980663439286631" },
  { "key": "dispositivo_id", "value": 1 },
  { "key": "dispositivo_model", "value": 1 },
  { "key": "dispositivo_tipo", "value": 1 },
  { "key": "app_versao", "value": 1 },
  { "key": "app_nome", "value": "MEGA" },
  { "key": "plataforma", "value": "WEB" },
  { "key": "Content-Type", "value": "application/json" }
]
Campos e tipos (body da requisição)
Campo Tipo
nomestring (obrigatório)
integracaostring
path_imagemstring
mobilebool
Body da requisição
{
  "nome": "PAPELARIA 11",
  "integracao": "MEUCODIGO",
  "path_imagem": "https://meupdvmovel.com.br/docs/sanduiche.jpg",
  "mobile": true
}
cURL (produção)
curl --location 'https://mobtef.conexaoapi.com.br/mpm/grupos' \
--header 'empresa_id: 980' \
--header 'token: 980663439286631' \
--header 'dispositivo_id: 1' \
--header 'dispositivo_model: 1' \
--header 'dispositivo_tipo: 1' \
--header 'app_versao: 1' \
--header 'app_nome: MEGA' \
--header 'plataforma: WEB' \
--header 'Content-Type: application/json' \
--data '{
    "nome": "PAPELARIA 11",
    "integracao": "MEUCODIGO",
    "path_imagem": "https://meupdvmovel.com.br/docs/sanduiche.jpg",
    "mobile": true
}'
Campos e tipos (resposta)
Campo Tipo
statusstring
messagestring
dataarray
data[].idint
Exemplo de resposta
{
  "status": "sucess",
  "message": "Criado com sucesso.",
  "data": [
    {
      "id": 584
    }
  ]
}

Exemplo no novo modelo de requisição: https://mobtef.conexaoapi.com.br/mpm/grupos.

GET /grupos

GET https://mobtef.conexaoapi.com.br/mpm/grupos

O GET pode ser usado para sincronização por data (atualizacao) ou para buscar um registro específico informando grupo_id no header.

Campos e tipos (headers)
Campo Tipo
empresa_idint
tokenint
dispositivo_idint
dispositivo_modelint
dispositivo_tipoint
app_versaoint
app_nomestring
plataformastring
atualizacaostring (data) — opcional (sincronização)
grupo_idint — opcional (consulta de um grupo)
Exemplo de headers
[
  { "key": "empresa_id", "value": 8 },
  { "key": "token", "value": 8041023 },
  { "key": "dispositivo_id", "value": 1 },
  { "key": "dispositivo_model", "value": 1 },
  { "key": "dispositivo_tipo", "value": 1 },
  { "key": "app_versao", "value": 1 },
  { "key": "app_nome", "value": "MEGA" },
  { "key": "plataforma", "value": "WEB" },
  { "key": "grupo_id", "value": 584 }
]
cURL (homologação)
curl --location 'https://mobtef-homolog.conexaoapi.com.br/mpm/grupos' \
--header 'empresa_id: 8' \
--header 'token: 8041023' \
--header 'dispositivo_id: 1' \
--header 'dispositivo_model: 1' \
--header 'dispositivo_tipo: 1' \
--header 'app_versao: 1' \
--header 'app_nome: MEGA' \
--header 'plataforma: WEB' \
--header 'grupo_id: 584'
Campos e tipos (resposta)
Campo Tipo
statusstring
messagestring
dataarray
data[].idint
data[].nomestring
data[].path_imagemstring | null
data[].codigostring
data[].integracaostring | null
data[].ativobool
Exemplo de resposta
{
    "status": "success",
    "message": "Operação realizada com sucesso.",
    "data": [
        {
            "id": 584,
            "nome": "PAPELARIA",
            "path_imagem": null,
            "codigo": "1515",
            "integracao": null,
            "ativo": true
        }
    ]
}

PUT /grupos

PUT https://mobtef.conexaoapi.com.br/mpm/grupos

No PUT, informe grupo_id no header para identificar o registro que será atualizado.

Campos e tipos (headers)
Campo Tipo
empresa_idint
tokenstring
dispositivo_idint
dispositivo_modelint
dispositivo_tipoint
app_versaoint
app_nomestring
plataformastring
grupo_idint
Content-Typestring (application/json)
Exemplo de headers
[
  { "key": "empresa_id", "value": 980 },
  { "key": "token", "value": "980663439286631" },
  { "key": "dispositivo_id", "value": 1 },
  { "key": "dispositivo_model", "value": 1 },
  { "key": "dispositivo_tipo", "value": 1 },
  { "key": "app_versao", "value": 1 },
  { "key": "app_nome", "value": "MEGA" },
  { "key": "plataforma", "value": "WEB" },
  { "key": "grupo_id", "value": 1891 },
  { "key": "Content-Type", "value": "application/json" }
]
Campos e tipos (body da requisição)
Campo Tipo
nomestring
path_imagemstring
mobilebool
ativobool
Body da requisição
{
    "nome":"PAPEIS E FORMULARIOS",
    "path_imagem":"https://caminhodaimagem.com.br/imagem.png",
    "mobile": false,
    "ativo": false
}
cURL (produção)
curl --location --request PUT 'https://mobtef.conexaoapi.com.br/mpm/grupos' \
--header 'empresa_id: 980' \
--header 'token: 980663439286631' \
--header 'dispositivo_id: 1' \
--header 'dispositivo_model: 1' \
--header 'dispositivo_tipo: 1' \
--header 'app_versao: 1' \
--header 'app_nome: MEGA' \
--header 'plataforma: WEB' \
--header 'grupo_id: 1891' \
--header 'Content-Type: application/json' \
--data '{
    "nome":"PAPEIS E FORMULARIOS",
    "path_imagem":"https://caminhodaimagem.com.br/imagem.png",
    "mobile": false,
    "ativo": false
}'
Campos e tipos (resposta)
Campo Tipo
statusstring
messagestring
dataarray
data[].idint
data[].nomestring
data[].path_imagemstring
data[].codigostring
data[].ativobool
data[].integracaostring | null
Exemplo de resposta
{
    "status": "success",
    "message": "Atualizado com sucesso.",
    "data": [
        {
            "id": 584,
            "nome": "PAPEIS E FORMULARIOS",
            "path_imagem": "https://caminhodaimagem.com.br/imagem.png",
            "codigo": "21567",
            "ativo": true,
            "integracao": null
        }
    ]
}

Exemplo no novo modelo de requisição: https://mobtef.conexaoapi.com.br/mpm/grupos.