Versões comparadas

Chave

  • Esta linha foi adicionada.
  • Esta linha foi removida.
  • A formatação mudou.

Sumário



Índice
excludeSumário

Objetivo



Esse documento tem o objetivo de exemplificar o uso da API utilizando todos os métodos implementados.

1 - Métodos



Serão apresentados 4 métodos, os quais foram implementados na API de Usuários, são eles:

  • GET
  • POST
  • PUT
  • DELETE

1.1 - GET


1.1.1 - Get All (Recuperar todos os usuários)


Informações
iconfalse
title1.1.1 GetAll
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": true,
    "items": [
        {
            "id": "00001",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00001",
            "name": {
                "formatted": "ITAMAR MENDES DA SILVEIRA"
            },
            "userName": "00001",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00001-02-98",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00001-02-98",
            "name": {
                "formatted": "ALONSO LIGORIO PINTO"
            },
            "userName": "00001-02-98",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "0000125",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "0000125",
            "name": {
                "formatted": "RUDIVAL JOSE DOS SANTOS"
            },
            "userName": "0000125",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00002",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00002",
            "name": {
                "formatted": "JOAO DA SILVA JORDAM"
            },
            "userName": "00002",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00003",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00003",
            "name": {
                "formatted": "MARIA CONCEICAO DE ASSIS"
            },
            "userName": "00003",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00004",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00004",
            "name": {
                "formatted": "ADALBERTO DE JESUS LIMA"
            },
            "userName": "00004",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00005",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00005",
            "name": {
                "formatted": "ALESSANDRA LOPES DE ABREU"
            },
            "userName": "00005",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00006",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00006",
            "name": {
                "formatted": "FERNANDO HENRIQUE VALLE KURTEN"
            },
            "userName": "00006",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00007",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00007",
            "name": {
                "formatted": "JOAQUIM FARIAS DAMASCENO"
            },
            "userName": "00007",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00008",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00008",
            "name": {
                "formatted": "ZELIA APARECIDA DA SILVA"
            },
            "userName": "00008",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00009",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00009",
            "name": {
                "formatted": "BEATRIZ MENGA"
            },
            "userName": "00009",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00010",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00010",
            "name": {
                "formatted": "ANTONIO GATES BILL"
            },
            "userName": "00010",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00011",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00011",
            "name": {
                "formatted": "MARCELO MATTAR DINIZ"
            },
            "userName": "00011",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00012",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00012",
            "name": {
                "formatted": "ANA LUIZA  DE SOUZA PRATES"
            },
            "userName": "00012",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00013",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00013",
            "name": {
                "formatted": "ALEXANDRE COTTA LEAO"
            },
            "userName": "00013",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00014",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00014",
            "name": {
                "formatted": "PEDRO DE ALCANTARA"
            },
            "userName": "00014",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00015",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00015",
            "name": {
                "formatted": "LEOPOLDO DOS SANTOS DE OLIVEIRA NETO"
            },
            "userName": "00015",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00038-02-105",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00038-02-105",
            "name": {
                "formatted": "WILMAN MAIA CABRAL"
            },
            "userName": "00038-02-105",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00039",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00039",
            "name": {
                "formatted": "ANTONIO CARLOS DE BRAGANÇA"
            },
            "userName": "00039",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00047",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00047",
            "name": {
                "formatted": "RODRIGO FIALHO BARRICHELLO"
            },
            "userName": "00047",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        }
    ]
}


1.1.2 - Order (Resultado Ordenado)

Informações
titleParâmetros

Order: parâmetro responsável pela ordenação do resultado, podendo ser ascendente ou descendente. O resultado com a ordem descendente deve ser precedida do caractere "-" (menos).

Exemplo 1: ?order=campo1 (Ascendente)

Exemplo 2: ?order=-campo1 (Descendente)

Múltiplos campos de ordenação: ?order=[-]campo1, [-]campo2, [-]campo3 ...

Informações
iconfalse
title1.1.2 Order (Asc)
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users?order=[-]{campo}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Campo: active

Tipo de Ordenação: Ascendente

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users?order=active

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": true,
    "items": [
        {
            "id": "00001",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00001",
            "name": {
                "formatted": "ITAMAR MENDES DA SILVEIRA"
            },
            "userName": "00001",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00001-02-98",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00001-02-98",
            "name": {
                "formatted": "ALONSO LIGORIO PINTO"
            },
            "userName": "00001-02-98",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "0000125",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "0000125",
            "name": {
                "formatted": "RUDIVAL JOSE DOS SANTOS"
            },
            "userName": "0000125",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00002",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00002",
            "name": {
                "formatted": "JOAO DA SILVA JORDAM"
            },
            "userName": "00002",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00003",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00003",
            "name": {
                "formatted": "MARIA CONCEICAO DE ASSIS"
            },
            "userName": "00003",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00004",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00004",
            "name": {
                "formatted": "ADALBERTO DE JESUS LIMA"
            },
            "userName": "00004",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00005",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00005",
            "name": {
                "formatted": "ALESSANDRA LOPES DE ABREU"
            },
            "userName": "00005",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00006",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00006",
            "name": {
                "formatted": "FERNANDO HENRIQUE VALLE KURTEN"
            },
            "userName": "00006",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00007",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00007",
            "name": {
                "formatted": "JOAQUIM FARIAS DAMASCENO"
            },
            "userName": "00007",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00008",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00008",
            "name": {
                "formatted": "ZELIA APARECIDA DA SILVA"
            },
            "userName": "00008",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00009",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00009",
            "name": {
                "formatted": "BEATRIZ MENGA"
            },
            "userName": "00009",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00010",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00010",
            "name": {
                "formatted": "ANTONIO GATES BILL"
            },
            "userName": "00010",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00011",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00011",
            "name": {
                "formatted": "MARCELO MATTAR DINIZ"
            },
            "userName": "00011",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00012",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00012",
            "name": {
                "formatted": "ANA LUIZA  DE SOUZA PRATES"
            },
            "userName": "00012",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00013",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00013",
            "name": {
                "formatted": "ALEXANDRE COTTA LEAO"
            },
            "userName": "00013",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00014",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00014",
            "name": {
                "formatted": "PEDRO DE ALCANTARA"
            },
            "userName": "00014",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00015",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00015",
            "name": {
                "formatted": "LEOPOLDO DOS SANTOS DE OLIVEIRA NETO"
            },
            "userName": "00015",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00038-02-105",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00038-02-105",
            "name": {
                "formatted": "WILMAN MAIA CABRAL"
            },
            "userName": "00038-02-105",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00039",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00039",
            "name": {
                "formatted": "ANTONIO CARLOS DE BRAGANÇA"
            },
            "userName": "00039",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        },
        {
            "id": "00047",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00047",
            "name": {
                "formatted": "RODRIGO FIALHO BARRICHELLO"
            },
            "userName": "00047",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        }
    ]
}
Informações
iconfalse
title1.1.2 Order (Desc)
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users?order=[-]{campo}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Campo: active

Tipo de Ordenação: Descendente

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users?order=-active

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": true,
    "items": [
        {
            "id": "agapito",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "agapito",
            "name": {
                "formatted": "Anderson Teixeira Agapito"
            },
            "userName": "agapito",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "alan",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "alan",
            "name": {
                "formatted": "Alan de Jesus"
            },
            "userName": "alan",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Andreia Valquiria",
            "meta": {
                "resourceType": "User",
                "created": "2011-10-10T13:52:19",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Andreia Valquiria",
            "name": {
                "formatted": "Andreia Valquiria Pereira"
            },
            "userName": "Andreia Valquiria",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Aracelle",
            "meta": {
                "resourceType": "User",
                "created": "2011-03-31T15:44:57",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Aracelle",
            "name": {
                "formatted": "Aracelle Soares Ramos"
            },
            "userName": "Aracelle",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "astoni",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "astoni",
            "name": {
                "formatted": "Adriano Astoni"
            },
            "userName": "astoni",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Bartira",
            "meta": {
                "resourceType": "User",
                "created": "2011-10-10T13:53:14",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Bartira",
            "name": {
                "formatted": "Bartira Sofia Da Silva Carvalho"
            },
            "userName": "Bartira",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "carlosphilippe",
            "meta": {
                "resourceType": "User",
                "created": "2018-10-05T09:41:20",
                "lastModified": "2018-10-05T09:41:20"
            },
            "externalId": "280c4852-9222-4983-be6f-f7a275d63111",
            "name": {
                "formatted": ""
            },
            "userName": "carlosphilippe",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "cecilia",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "cecilia",
            "name": {
                "formatted": "Cecília Franco"
            },
            "userName": "cecilia",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "charles",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "charles",
            "name": {
                "formatted": "Charles Pierre"
            },
            "userName": "charles",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "cintia",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "cintia",
            "name": {
                "formatted": "Cintia Cristina de Moura"
            },
            "userName": "cintia",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "claudia",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "claudia",
            "name": {
                "formatted": "Claudia Leontina Martins"
            },
            "userName": "claudia",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Coutinho",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Coutinho",
            "name": {
                "formatted": "Rodrigo Coutinho"
            },
            "userName": "Coutinho",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "cristiano",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "cristiano",
            "name": {
                "formatted": "Cristiano Cesar Figueiredo Soares"
            },
            "userName": "cristiano",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Cristiliane",
            "meta": {
                "resourceType": "User",
                "created": "2011-10-10T13:56:01",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Cristiliane",
            "name": {
                "formatted": "Cristiliane Moreira Mariano Feitoza"
            },
            "userName": "Cristiliane",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Amanda",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Amanda",
            "name": {
                "formatted": "Amanda Miranda de Oliveira"
            },
            "userName": "Amanda",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Breno",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Breno",
            "name": {
                "formatted": "Breno José Agostinho Batista"
            },
            "userName": "Breno",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Cristina.Almeida",
            "meta": {
                "resourceType": "User",
                "created": "2011-03-31T12:39:42",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Cristina.Almeida",
            "name": {
                "formatted": "Cristina de Almeida"
            },
            "userName": "Cristina.Almeida",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Daniela",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Daniela",
            "name": {
                "formatted": "Daniela Silvia Pereira"
            },
            "userName": "Daniela",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Davi",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Davi",
            "name": {
                "formatted": "Davi Leles"
            },
            "userName": "Davi",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        },
        {
            "id": "Denise",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "Denise",
            "name": {
                "formatted": "Denise Gentiluomo Diniz"
            },
            "userName": "Denise",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        }
    ]
}

1.1.3 - Filter (Resultado filtrado)


Informações
iconfalse
title1.1.3 Filter
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users?{campo}={valor}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Campo: userName

Valor: carlosphilippe

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users?userName=carlosphilippe



Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": false,
    "items": [
        {
            "id": "carlosphilippe",
            "meta": {
                "resourceType": "User",
                "created": "2018-10-05T09:41:20",
                "lastModified": "2018-10-05T09:41:20"
            },
            "externalId": "280c4852-9222-4983-be6f-f7a275d63111",
            "name": {
                "formatted": ""
            },
            "userName": "carlosphilippe",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": true
        }
    ]
}

1.1.4 - Paginação


Informações
titleParâmetros

Page: Página que será apresentada.

PageSize: Quantidade máxima de registros por página que serão apresentados.

Exemplo: ?page=valor1&pageSize=1

Valores padrão: Caso não sejam preenchidos os parâmetros evidenciados acima serão preenchidos com valores padrão.

Page: 1

PageSize: 20

Informações
iconfalse
title1.1.4 Paginacao
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users?page={valor1}&pageSize={valor2}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Valor1: 1

Valor2: 1

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users?page=1&pageSize=1

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": true,
    "items": [
        {
            "id": "00001",
            "meta": {
                "resourceType": "User",
                "created": "2014-07-07T15:32:15",
                "lastModified": "2018-10-05T09:34:53"
            },
            "externalId": "00001",
            "name": {
                "formatted": "ITAMAR MENDES DA SILVEIRA"
            },
            "userName": "00001",
            "emails": [
                {
                    "value": "[email protected]",
                    "primary": true
                }
            ],
            "active": false
        }
    ]
}

1.1.5 - Fields (Retorno de campos específicos no resultado)


Informações
titleParâmetros

Fields: parâmetro responsável pela especialização de campos em um resultado, ou seja, o usuário define quais campos serão apresentados no resultado.

Exemplo: ?fields=campo1

Múltiplos campos de ordenação: ?fields=campo1, campo2, campo3 ...

Informações
iconfalse
title1.1.5 Fields
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users?fields={campo}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Campo: userName

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users?fields=userName

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "hasNext": true,
    "items": [
        {
            "userName": "00001"
        },
        {
            "userName": "00001-02-98"
        },
        {
            "userName": "0000125"
        },
        {
            "userName": "00002"
        },
        {
            "userName": "00003"
        },
        {
            "userName": "00004"
        },
        {
            "userName": "00005"
        },
        {
            "userName": "00006"
        },
        {
            "userName": "00007"
        },
        {
            "userName": "00008"
        },
        {
            "userName": "00009"
        },
        {
            "userName": "00010"
        },
        {
            "userName": "00011"
        },
        {
            "userName": "00012"
        },
        {
            "userName": "00013"
        },
        {
            "userName": "00014"
        },
        {
            "userName": "00015"
        },
        {
            "userName": "00038-02-105"
        },
        {
            "userName": "00039"
        },
        {
            "userName": "00047"
        }
    ]
}

1.1.6 - GetOne (Recuperar usuário pelo Identificador)


Informações
iconfalse
title1.1.6 Fields
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users/{id}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Id: 00001

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users/00001

Informações
iconfalse
titleExemplo Postman

Informações
iconfalse
titleExemplo de Resultado
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "_expandables": [
        "groups"
    ],
    "id": "00001",
    "meta": {
        "resourceType": "User",
        "created": "2014-07-07T15:32:15",
        "lastModified": "2018-10-05T09:34:53"
    },
    "externalId": "00001",
    "name": {
        "formatted": "ITAMAR MENDES DA SILVEIRA"
    },
    "userName": "00001",
    "emails": [
        {
            "value": "[email protected]",
            "primary": true
        }
    ],
    "active": false
}

1.2 - POST


1.2.1 - Post (Inserir um usuário)


Informações
iconfalse
title1.2.1 Post
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users

Informações
iconfalse
titleExemplo de Entrada Postman

Informações
iconfalse
titleExemplo de Entrada
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
  "id": "testeapiusuario",
  "meta": {
    "resourceType": "User",
    "created": "2018-09-21T16:49:57.336Z",
    "lastModified": "2018-09-21T16:49:57.336Z"
  },
  "externalId": "0001e",
  "name": {
    "givenName": "TesteAPI",
    "familyName": "Usuário"
  },
  "userName": "testeapiusuario",
  "phoneNumbers": [
    {
      "value": "31974964158"
    }
  ],
  "emails": [
    {
      "value": "[email protected]",
      "type": "string",
      "primary": true
    }
  ],
  "active": true,
  "groups": [
    {
      "value": "01",
      "display": "geral"
    }
  ],
  "title": "Mr",
  "manager": [
    {
      "managerId": "01",
      "displayName": "Geral"
    }
  ]
}
Informações
iconfalse
titleExemplo de Resultado Positivo Postman

Informações
iconfalse
titleExemplo de Resultado Positivo
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "id": "testeapiusuario",
    "meta": {
        "resourceType": "User",
        "created": "2018-09-21T16:49:57.336Z",
        "lastModified": "2018-09-21T16:49:57.336Z"
    },
    "externalId": "0001e",
    "name": {
        "givenName": "TesteAPI",
        "familyName": "Usuário"
    },
    "userName": "testeapiusuario",
    "phoneNumbers": [
        {
            "value": "31974964158"
        }
    ],
    "emails": [
        {
            "value": "[email protected]",
            "type": "string",
            "primary": true
        }
    ],
    "active": true,
    "groups": [
        {
            "value": "01",
            "display": "geral"
        }
    ],
    "title": "Mr",
    "manager": [
        {
            "managerId": "01",
            "displayName": "Geral"
        }
    ]
}
Informações
iconfalse
titleExemplo de Resultado Negativo Postman

Informações
iconfalse
titleExemplo de Resultado Negativo
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "Code": "RMSDbKeyException",
    "Message": "Chave duplicada\r\n\r\nPossíveis causas:\r\n  - inclusão de registro cujo valor da chave primária já existe\r\n  - inclusão de registro cujo valor do índice único já existe",
    "DetailMessage": "   em RM.Lib.Data.DbServices.UpdateTable(DataTable table, UpdateMode mode, Boolean logOperation, String userName, Int32 batchSize) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Data\\RMSData.cs:linha 897\r\n   em RM.Lib.Data.DbServices.UpdateTable(DataTable table, UpdateMode mode, String userName, Int32 batchSize) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Data\\RMSData.cs:linha 865\r\n   em RM.Lib.Data.DbServices.QueryUpdate(DataSet dataSet, String tableName, String codUsuario) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Data\\RMSData.cs:linha 3429\r\n   em RM.Lib.Data.DbServices.QueryUpdate(DataSet dataSet, String tableName) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Data\\RMSData.cs:linha 3423\r\n   em RM.Glb.Seguranca.GlbUsuarioData.DoSaveRecord(DataSet dataSet, Int32& rowsAffected, Object ownerData) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Seguranca.Data\\GlbUsuarioData.cs:linha 473\r\n   em RM.Lib.Server.RMSDataServer.InternalSaveRecord(RMSContext context, DataSet& dataSet, Object ownerData, Boolean skipSecurity, Boolean skipSecurityCollumns) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 1477\r\n   em RM.Lib.Server.RMSDataServer.SaveRecord(RMSContext context, DataSet& dataSet, Object ownerData) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 651\r\n   em RM.Glb.Api.UserControllerServer.Save(String id, User record) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Api\\UserController.Server.cs:linha 336\r\n   em RM.Glb.Api.UserControllerServer.OnPost(User record) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Api\\UserController.Server.cs:linha 269\r\n   em RM.Lib.Server.RMSCrudServer`1.Post(T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\Api\\RMSCrudServer.cs:linha 80\r\n   em RM.Lib.Api.RMSCrudController`1.OnPost(T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api\\Controllers\\RMSCrudController.cs:linha 135\r\n   em RM.Lib.Api.RMSCrudController`1.Post(T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api\\Controllers\\RMSCrudController.cs:linha 125\r\n   em lambda_method(Closure , Object , Object[] )\r\n   em System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass10.<GetExecutor>b__9(Object instance, Object[] methodParameters)\r\n   em System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary`2 arguments, CancellationToken cancellationToken)\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__0.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   em RM.Lib.Api.Server.ApiAuthenticationFilter.ResultWithChallenge.<ExecuteAsync>d__2.MoveNext() na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api.Server\\Filters\\Api.AuthenticationFilter.cs:linha 193\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.AuthenticationFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()",
    "HelpUrl": null,
    "Details": [
        {
            "Code": "Exception",
            "Message": "Violation of PRIMARY KEY constraint 'PKGUSUARIO'. Cannot insert duplicate key in object 'dbo.GUSUARIO'. The duplicate key value is (testeapiusuario).\r\nThe statement has been terminated.",
            "DetailMessage": null,
            "HelpUrl": null,
            "Details": [
                {
                    "Code": "Exception",
                    "Message": "INSERT INTO [GUSUARIO] ([CODUSUARIO], [NOME], [STATUS], [DATAINICIO], [IGNORARAUTENTICACAOLDAP], [DATAEXPIRACAO], [CONFIRMABTNOK], [SENHA], [CONTROLE], [ULTIMACOLIGADA], [CODACESSO], [DTAEXPSENHA], [DIASEXPSENHA], [OBRIGAALTERARSENHA], [NUMLOGININVALIDO], [DATALOGININVALIDO], [EMAIL], [ACESSONET], [INTERNO1], [DATAULTIMOACESSO], [CODUSUARIOREDE], [DOMINIOREDE], [DATAULTIMOACESSOVALIDO], [USUARIOTWITTER], [SENHATWITTER], [USUARIOFACEBOOK], [SENHAFACEBOOK], [USUARIOLINKEDIN], [SENHALINKEDIN], [USERIDFLUIGIDENTITY], [NOMESOCIAL], [USERID], [RECCREATEDBY], [RECCREATEDON], [RECMODIFIEDBY], [RECMODIFIEDON]) VALUES ('testeapiusuario', null, 1, '08/10/2018 00:00:00', 'F', null, 1, 'jcmaAAAA', -17702, , 'Acesso01', null, , 'T', , null, '[email protected]', 'F', null, null, null, null, null, null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, null, '9b69c210-8d20-45b6-afae-534ce10fd4b7', 'mestre', CONVERT ( DATETIME, CONVERT ( VARCHAR, GETDATE(), 120) ), 'mestre', CONVERT ( DATETIME, CONVERT ( VARCHAR, GETDATE(), 120) ))",
                    "DetailMessage": null,
                    "HelpUrl": null,
                    "Details": null
                }
            ]
        },
        {
            "Code": "Exception",
            "Message": "INSERT INTO [GUSUARIO] ([CODUSUARIO], [NOME], [STATUS], [DATAINICIO], [IGNORARAUTENTICACAOLDAP], [DATAEXPIRACAO], [CONFIRMABTNOK], [SENHA], [CONTROLE], [ULTIMACOLIGADA], [CODACESSO], [DTAEXPSENHA], [DIASEXPSENHA], [OBRIGAALTERARSENHA], [NUMLOGININVALIDO], [DATALOGININVALIDO], [EMAIL], [ACESSONET], [INTERNO1], [DATAULTIMOACESSO], [CODUSUARIOREDE], [DOMINIOREDE], [DATAULTIMOACESSOVALIDO], [USUARIOTWITTER], [SENHATWITTER], [USUARIOFACEBOOK], [SENHAFACEBOOK], [USUARIOLINKEDIN], [SENHALINKEDIN], [USERIDFLUIGIDENTITY], [NOMESOCIAL], [USERID], [RECCREATEDBY], [RECCREATEDON], [RECMODIFIEDBY], [RECMODIFIEDON]) VALUES ('testeapiusuario', null, 1, '08/10/2018 00:00:00', 'F', null, 1, 'jcmaAAAA', -17702, , 'Acesso01', null, , 'T', , null, '[email protected]', 'F', null, null, null, null, null, null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, '\\FEz\\1B\\7F1\\18\\B7\\27', null, null, '9b69c210-8d20-45b6-afae-534ce10fd4b7', 'mestre', CONVERT ( DATETIME, CONVERT ( VARCHAR, GETDATE(), 120) ), 'mestre', CONVERT ( DATETIME, CONVERT ( VARCHAR, GETDATE(), 120) ))",
            "DetailMessage": null,
            "HelpUrl": null,
            "Details": null
        }
    ]
}

1.3 - PUT


1.3.1 - Put (Atualizar um usuário)


Informações
iconfalse
title1.3.1 Post
Expandir
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users/{id}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8099

Id: 00001

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users/testeapiusuario

Informações
iconfalse
titleExemplo de Entrada Postman

Informações
iconfalse
titleExemplo de Entrada
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
  "id": "testeapiusuario",
  "meta": {
    "resourceType": "User",
    "created": "2018-09-21T16:49:57.336Z",
    "lastModified": "2018-09-21T16:49:57.336Z"
  },
  "externalId": "0001e",
  "name": {
    "givenName": "TesteAPI",
    "familyName": "Usuário"
  },
  "userName": "testeapiusuario",
  "phoneNumbers": [
    {
      "value": "31974964158"
    }
  ],
  "emails": [
    {
      "value": "[email protected]",
      "type": "string",
      "primary": true
    }
  ],
  "active": true,
  "groups": [
    {
      "value": "01",
      "display": "geral"
    }
  ],
  "title": "Mr",
  "manager": [
    {
      "managerId": "01",
      "displayName": "Geral"
    }
  ]
}
Informações
iconfalse
titleExemplo de Resultado Positivo Postman

Informações
iconfalse
titleExemplo de Resultado Positivo
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "id": "testeapiusuario",
    "meta": {
        "resourceType": "User",
        "created": "2018-09-21T16:49:57.336Z",
        "lastModified": "2018-09-21T16:49:57.336Z"
    },
    "externalId": "0001e",
    "name": {
        "givenName": "TesteAPI",
        "familyName": "Usuário"
    },
    "userName": "testeapiusuario",
    "phoneNumbers": [
        {
            "value": "31974964158"
        }
    ],
    "emails": [
        {
            "value": "[email protected]",
            "type": "string",
            "primary": true
        }
    ],
    "active": true,
    "groups": [
        {
            "value": "01",
            "display": "geral"
        }
    ],
    "title": "Mr",
    "manager": [
        {
            "managerId": "01",
            "displayName": "Geral"
        }
    ]
}
Informações
iconfalse
titleExemplo de Resultado Negativo Postman

Informações
iconfalse
titleExemplo de Resultado Negativo
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
{
    "Code": "RMSApplicationException",
    "Message": "Já existe um usuário com esse e-mail",
    "DetailMessage": "   em RM.Lib.RMSException.Throw(String message) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib\\Utils\\RMSException.cs:linha 131\r\n   em RM.Glb.Seguranca.GlbUsuarioData.ValidateRow(DataRow row) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Seguranca.Data\\GlbUsuarioData.cs:linha 759\r\n   em RM.Lib.Server.RMSDataServer.ValidateTableRows(DataTable masterTable) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 2509\r\n   em RM.Lib.Server.RMSDataServer.DoValidateRows(DataSet dataSet) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 2449\r\n   em RM.Lib.Server.RMSDataServer.InternalSaveRecord(RMSContext context, DataSet& dataSet, Object ownerData, Boolean skipSecurity, Boolean skipSecurityCollumns) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 1413\r\n   em RM.Lib.Server.RMSDataServer.SaveRecord(RMSContext context, DataSet& dataSet, Object ownerData) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\RMSDataServer.cs:linha 651\r\n   em RM.Glb.Api.UserControllerServer.Save(String id, User record) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Api\\UserController.Server.cs:linha 336\r\n   em RM.Glb.Api.UserControllerServer.OnPut(String id, User record) na C:\\RM\\Atual\\Release\\Glb-Globais\\RM.Glb.Api\\UserController.Server.cs:linha 274\r\n   em RM.Lib.Server.RMSCrudServer`1.Put(String id, T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Server\\Api\\RMSCrudServer.cs:linha 99\r\n   em RM.Lib.Api.RMSCrudController`1.OnPut(String id, T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api\\Controllers\\RMSCrudController.cs:linha 163\r\n   em RM.Lib.Api.RMSCrudController`1.Put(String id, T record) na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api\\Controllers\\RMSCrudController.cs:linha 152\r\n   em lambda_method(Closure , Object , Object[] )\r\n   em System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass10.<GetExecutor>b__9(Object instance, Object[] methodParameters)\r\n   em System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary`2 arguments, CancellationToken cancellationToken)\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__0.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   em RM.Lib.Api.Server.ApiAuthenticationFilter.ResultWithChallenge.<ExecuteAsync>d__2.MoveNext() na C:\\RM\\Atual\\Release\\Lib\\RM.Lib.Api.Server\\Filters\\Api.AuthenticationFilter.cs:linha 193\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.AuthenticationFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- Fim do rastreamento de pilha do local anterior onde a exceção foi gerada ---\r\n   em System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   em System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   em System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()",
    "HelpUrl": null,
    "Details": null
}

1.4 - DELETE


1.4.1 - Delete (Deletar um usuário)


Informações
iconfalse
title1.4.1 Delete
Expandir
titleClique aqui para expandir...
Informações
iconfalse
titleConfiguração

Máscara de Url: http://{domínio}:{porta}/api/rm/glb/v1/users/{id}

Informações
iconfalse
titleExemplo de Configuração

Domínio: localhost

Porta: 8050

Id: Teste_01

Url Utilizada: http://localhost:8099/api/rm/glb/v1/users/Teste_01

Informações
iconfalse
titleExemplo de Entrada Postman

Informações
iconfalse
titleExemplo de Resultado Negativo Postman

(Colar imagem)

Obs.: Em caso de sucesso, será retornado o respondeCode = 204 e a resposta em branco.

Informações
iconfalse
titleExemplo de Resultado Negativo Postman

(Colar imagem)


Informações
iconfalse
titleExemplo de Resultado Negativo
Expandir
titleVer resultado JSON...
Bloco de código
languagejs
firstline1
titleResultado (JSON)
linenumberstrue
(Colar JSON)