# Plataforma - OnApp

Comprende métodos de procesamiento para la aplicación tracker, generalmente esta particularidad se requiere como autenticación el TokenApp (JWT) para su funcionamiento.

# Método de autenticación - auth

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/auth

Este método genera el token de autenticación que le permitirá hacer uso de los servicios.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px;"><tbody><tr><td style="width: 188px;">**Parámetros**</td><td style="width: 320px;">**Descripción**</td><td style="width: 301px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr style="height: 57px;"><td style="width: 188px; height: 57px;">type</td><td style="width: 320px; height: 57px;">El tipo de aplicación que solicita codificado en Base64.</td><td style="width: 301px; height: 57px;"><span role="presentation" style="padding-right: 0.1px; color: #3366ff;">Mg==</span></td></tr><tr style="height: 41px;"><td style="width: 188px; height: 41px;">uid</td><td style="width: 320px; height: 41px;"><span style="color: #212121;"><span style="font-family: Inter, system-ui, apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica, Arial, sans-serif;"><span style="font-size: small;">IMEI o identificador único del dispositivo codificado en Base64.</span></span></span>

</td><td style="width: 301px; height: 41px;"><span style="color: #3366ff;">MTIzNDU2Nzg5</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/auth' \
--form 'type="Mg=="' \
--form 'uid="OGVkNTU2NTE3NmM0MzM3Mw=="'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": "200",
    "data": "eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU",
    "extra": {
        "idcliente": "44897",
        "iddistribuidor": "45296"
        "idvehiculo": "138634",
        "hash": "jpg8PUcekJQ",
        "tipo_equipo": "11"
    }
}
```

# Datos del dispositivo - getdata_device

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getdata\_device

Obtiene la información del dispositivo.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getdata_device' \
--header 'Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjgwNzEwMTMiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.l26c6-zqG8SLukYakCPX8DMZnDpWm0ATzmPCtfggk4o'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": "200",
    "data": {
        "id": "198880",
        "device": "8e785176c43373",
        "fecha_de_alta": "2022-02-22",
        "idcliente_distribuidor": "4121896",
        "vehiculo": "Ford",
        "idvehiculo": "1691202",
        "idcliente_sistema": "411897",
        "cliente": "Transportes del sur",
        "distribuidor": "Navitrack"
    },
    "extra": []
}
```

# Listar rondines - getRondinesProceso

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getRondinesProceso

Este método lista la información de los rondines programados para hoy y/o de la semana.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr style="height: 41px;"><td style="width: 140px; height: 41px;">imei</td><td style="width: 307px; height: 41px;"><span style="color: #212121;"><span style="font-family: Inter, system-ui, apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica, Arial, sans-serif;"><span style="font-size: small;">IMEI o identificador único del dispositivo codificado en Base64.</span></span></span>

</td><td style="width: 362px; height: 41px;"><span style="color: #3366ff;">MTIzNDU2Nzg5</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getRondinesProceso' \
--header 'Authorization: eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU' \
--form 'imei="OGVkNTU2NTE3NmM0MzM3Mw=="'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": {
        "2022-04-27": [
            {
                "idruta_proceso": 0,
                "idruta": "23884",
                "nombre": "testHora",
                "fecha_inicio": "2022-04-27",
                "hora_inicio": "13:45",
                "fecha_fin": "2022-04-27",
                "hora_fin": "15:00:00",
                "estatus": "",
                "idvehiculo": "169202",
                "lugares": [
                    {
                        "id": "uid43662083",
                        "tipo": 0,
                        "orden": "1",
                        "nombre": "q1",
                        "dist_pa": 0,
                        "latLng": "0,0",
                        "fEstimada": "",
                        "tolerancia": 0,
                        "timeBetween": 0,
                        "distLleg": "0",
                        "orientacion": "",
                        "completado": 0,
                        "tipoLugarTag": "1",
                        "codigo": "uid43662083",
                        "sinoGPS": "0"
                    },
                    {
                        "id": "uid43707424",
                        "tipo": 0,
                        "orden": "2",
                        "nombre": "q2",
                        "dist_pa": 0,
                        "latLng": "0,0",
                        "fEstimada": "",
                        "tolerancia": 0,
                        "timeBetween": 0,
                        "distLleg": "0",
                        "orientacion": "",
                        "completado": 0,
                        "tipoLugarTag": "1",
                        "codigo": "uid43707424",
                        "sinoGPS": "0"
                    }
                ]
            }
        ],
        "2022-04-30": [
            {
                "idruta_proceso": 0,
                "idruta": "23884",
                "nombre": "testHora",
                "fecha_inicio": "2022-04-30",
                "hora_inicio": "13:45",
                "fecha_fin": "2022-04-30",
                "hora_fin": "15:00:00",
                "estatus": "",
                "idvehiculo": "169202",
                "lugares": [
                    {
                        "id": "uid43662083",
                        "tipo": 0,
                        "orden": "1",
                        "nombre": "q1",
                        "dist_pa": 0,
                        "latLng": "0,0",
                        "fEstimada": "",
                        "tolerancia": 0,
                        "timeBetween": 0,
                        "distLleg": "0",
                        "orientacion": "",
                        "completado": 0,
                        "tipoLugarTag": "1",
                        "codigo": "uid43662083",
                        "sinoGPS": "0"
                    },
                    {
                        "id": "uid43707424",
                        "tipo": 0,
                        "orden": "2",
                        "nombre": "q2",
                        "dist_pa": 0,
                        "latLng": "0,0",
                        "fEstimada": "",
                        "tolerancia": 0,
                        "timeBetween": 0,
                        "distLleg": "0",
                        "orientacion": "",
                        "completado": 0,
                        "tipoLugarTag": "1",
                        "codigo": "uid43707424",
                        "sinoGPS": "0"
                    }
                ]
            }
        ]
    },
    "extra": {
        "nombre": "TestUser",
        "patente": "27223"
    }
}
```

# Listar puntos de rondín - getPuntosRondinProceso

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getRondinesProceso

Este método lista la información de los puntos del rondín.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">idruta\_proceso</td><td style="width: 307px;"><span style="color: #212121;"><span style="font-family: Inter, system-ui, apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica, Arial, sans-serif;"><span style="font-size: small;">Id de la ruta en proceso en base64.</span></span></span>

</td><td style="width: 362px;"><span style="color: #3366ff;">MA==</span></td></tr><tr style="height: 41px;"><td style="width: 140px; height: 41px;">imei</td><td style="width: 307px; height: 41px;"><span style="color: #212121;"><span style="font-family: Inter, system-ui, apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica, Arial, sans-serif;"><span style="font-size: small;">IMEI o identificador único del dispositivo codificado en Base64.</span></span></span>

</td><td style="width: 362px; height: 41px;"><span style="color: #3366ff;">MTIzNDU2Nzg5</span></td></tr><tr><td style="width: 140px;">idruta</td><td style="width: 307px;"><span style="color: #212121;"><span style="font-family: Inter, system-ui, apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica, Arial, sans-serif;"><span style="font-size: small;">Id de la ruta en base 64.</span></span></span>

</td><td style="width: 362px;"><span style="color: #3366ff;">MTcwMTQ=</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://qa_api.service24gps.com/api/v1/onapp/getPuntosRondinProceso' \
--header 'Authorization: eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU'\
--data-urlencode 'idruta_proceso=MA==' \
--data-urlencode 'imei=MTIzNDU2Nzg5' \
--data-urlencode 'idruta=MTcwMTQ='
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": [
        {
            "nombre": "Lugar 1",
            "status": "",
            "codigo": "MiLugar1",
            "uid": "uid65658949",
            "latitud": "0",
            "longitud": "0",
            "orden": "1"
        },
        {
            "nombre": "Lugar 2",
            "status": "",
            "codigo": "MiLugar2",
            "uid": "uid42324784",
            "latitud": "0",
            "longitud": "0",
            "orden": "2"
        },
        {
            "nombre": "Lugar 3",
            "status": "",
            "codigo": "MiLugar33",
            "uid": "uid16380798",
            "latitud": "0",
            "longitud": "0",
            "orden": "3"
        },
        {
            "nombre": "Lugar 4",
            "status": "",
            "codigo": "MiLugar44",
            "uid": "uid86091311",
            "latitud": "0",
            "longitud": "0",
            "orden": "4"
        },
        {
            "nombre": "Lugar 5",
            "status": "",
            "codigo": "MiLugar55",
            "uid": "uid29985878",
            "latitud": "0",
            "longitud": "0",
            "orden": "5"
        },
        {
            "nombre": "Lugar 6",
            "status": "",
            "codigo": "uid54005553",
            "uid": "uid68640714",
            "latitud": "0",
            "longitud": "0",
            "orden": "6"
        }
    ],
    "extra": []
}
```

# Obtener formularios  - getForms

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/onapp/getForms

Obtiene el listado de todos los formularios creados por el cliente, y la estructura almacenada.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px;"><tbody><tr><td style="width: 173px;">**Parámetros**</td><td style="width: 335px;">**Descripción**</td><td style="width: 301px;"><span style="color: #000000;">**<span role="presentation" style="padding-right: 0.1px;">Ejemplo</span>**</span></td></tr><tr style="height: 41px;"><td style="width: 173px; height: 41px;">token</td><td style="width: 335px; height: 41px;">Token generado por el método auth.</td><td style="width: 301px; height: 41px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getforms' \
--header 'Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjgwNzEwMTMiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.l26c6-zqG8SLukYakCPX8DMZnDpWm0ATzmPCtfggk4o'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": "200",
    "data": {
        "v2": [
            {
                "id": "852",
                "nombre": "Cuestionario prueba 2",
                "header": {
                    "imagen1": "https://newspace1.nyc3.digitaloceanspaces.com/DynamicForms/formato/41897/p2000220405.jpg",
                    "imagen2": "https://newspace1.nyc3.digitaloceanspaces.com/DynamicForms/formato/41897/p200120405.jpg",
                    "nombre": "Cuestionario prueba 2",
                    "showFolio": "1"
                },
                "generales": {
                    "1": {
                        "texto": "test1",
                        "respuesta": "13",
                        "alineacion": "1",
                        "orden": "1",
                        "opciones": {
                            "1": {
                                "nombre": "    test1    "
                            },
                            "2": {
                                "nombre": "    test2    "
                            }
                            }
                        }
                    },
                    "2": {
                        "texto": "test2",
                        "respuesta": "14",
                        "alineacion": "1",
                        "orden": "1",
                        "opciones": {
                            "1": {
                                "nombre": "    test    "
                            },
                            "2": {
                                "nombre": "    test    "
                            },
                            }
                        }
                    }
                },
                "categorias": {
                    "1": {
                        "texto": "validacion",
                        "respuesta": "16",
                        "alineacion": "1",
                        "orden": "1"
                    },
                    "2": {
                        "texto": "fecha inicio",
                        "respuesta": "6",
                        "alineacion": "1",
                        "orden": "1"
                    }
                },
                "footes": null,
                "vigencia": "-1",
                "metadatos": {
                    "idFormato": "852",
                    "imei": "ed55625c43373",
                    "url": "https://qa.service24gps.com:443/DynamicForms/ChangeElementStatus/AnswerForms/ContestarFormato?token=88396386fba25",
                    "noFinalizar": 1,
                    "vigencia": "2022-04-04",
                    "contador": 3
                },
                "token": "88378963ba25",
                "status": "1"
            }
        ],
        "v3": [
            {
                "assignedid": "71192",
                "idform": "863",
                "duration": "-1",
                "version": "3",
                "name": "Formulario prueba",
                "form": [
                    {
                        "type": "header",
                        "subtype": "h1",
                        "label": "Prueba formulario titulo"
                    },
                    {
                        "type": "text",
                        "required": false,
                        "label": "Campo de Texto",
                        "className": "form-control",
                        "name": "text-1649348824011",
                        "value": "Prueba de texto formulario",
                        "subtype": "text"
                    },
                    {
                        "type": "customDatetime",
                        "subtype": "datetime-local",
                        "required": false,
                        "label": "Fecha / Hora",
                        "name": "customDatetime-1649349101208",
                        "value": "2022-04-07T11:31"
                    },
                    {
                        "type": "starRating",
                        "required": false,
                        "label": "Calificación",
                        "name": "starRating-1649349115836"
                    },
                    {
                        "type": "jSignature",
                        "required": false,
                        "label": "Firma",
                        "description": "firma de enterado",
                        "name": "jSignature-1649349139232"
                    },
                    {
                        "type": "multimedia",
                        "subtype": "image",
                        "required": false,
                        "label": "Multimedia",
                        "name": "multimedia-1649429241021"
                    }
                ],
                "answered": "0",
                "date": "2022-04-08",
                "hour": "07:57:13",
                "onlyOnce": false
            }
        ]
    },
    "extra": []
}
```

# Listar formularios - getformatos

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getformatos

Este método lista los formularios asignados al dispositivo.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getformatos' \
--header 'Authorization: eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": "200",
    "data": [
        {
            "metadatos": {
                "idFormato": "852",
                "imei": "8ed55678921123373",
                "url": "https://qa.service24gps.com:443/DynamicForms/ChangeElementStatus/AnswerForms/ContestarFormato?token=88396386fba25",
                "noFinalizar": 1,
                "vigencia": "2022-04-04",
                "contador": 3
            },
            "token": "88396386fba25",
            "estado": "1",
            "timestamp_creacion": "2022-04-05 10:33:21",
            "nombre": "Cuestionario prueba 2"
        },
        {
            "metadatos": {
                "idFormato": "846",
                "imei": "8ed55678921123373",
                "url": "https://qa.service24gps.com:443/DynamicForms/ChangeElementStatus/AnswerForms/ContestarFormato?token=d5144a9b4b81d",
                "noFinalizar": 1,
                "vigencia": "2022-04-04",
                "contador": 1
            },
            "token": "d5144a9b4b81d",
            "estado": "1",
            "timestamp_creacion": "2022-04-05 08:37:24",
            "nombre": "Cuestionario prueba"
        }
    ],
    "extra": []
}
```

# Listar equipos compartidos - getSharedApps

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getSharedApps

Este método lista los equipos que son de tipo app tracker compartida.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getSharedApps' \
--header 'Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjgwNzEwMTMiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.l26c6-zqG8SLukYakCPX8DMZnDpWm0ATzmPCtfggk4o'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": [
        {
            "IdEquipo": "205526",
            "Identificador": "APPSHARED418969651096603723",
            "Imei": "APPSHARED418961651096603723",
            "Nombre": "LM Compartido",
            "Placa": "TEST123",
            "Compartida": false,
            "TrackerHost": "N/A"
        },
        {
            "IdEquipo": "205527",
            "Identificador": "APPSHARED418961691096876447",
            "Imei": "APPSHARED418961651096876447",
            "Nombre": "Activo Compartido",
            "Placa": "LMMM4",
            "Compartida": false,
            "TrackerHost": "N/A"
        }
    ],
    "extra": []
}
```

# Liberar y asignar equipo compartido - switchApp

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/switchApp

Este método libera y asigna los equipos que son de tipo app tracker compartida.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 282px; width: 809px;"><tbody><tr style="height: 41px;"><td style="width: 140px; height: 41px;">**Parámetros**</td><td style="width: 307px; height: 41px;">**Descripción**</td><td style="width: 362px; height: 41px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr style="height: 125px;"><td style="width: 140px; height: 125px;">Authorization</td><td style="width: 307px; height: 125px;">Token generado por el método auth.</td><td style="width: 362px; height: 125px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr><tr style="height: 75px;"><td style="width: 140px; height: 75px;">oldApp</td><td style="width: 307px; height: 75px;">IMEI o identificador único del dispositivo codificado en Base64 de la app tracker compartida (liberar equipo).</td><td style="width: 362px; height: 75px;"><span style="color: #3366ff;">QVBQU0hBUkVENDE4OTYxNjUxMDk2NjAzNzIz</span></td></tr><tr style="height: 41px;"><td style="width: 140px; height: 41px;">newApp</td><td style="width: 307px; height: 41px;">IMEI o identificador único del dispositivo codificado en Base64 de la app tracker compartida (asignar equipo).</td><td style="width: 362px; height: 41px;"><span style="color: #3366ff;">QVBQU0hBUkVENDE4OTYxNjUxMDk2ODc2NDQ3</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/switchApp' \
--header 'Authorization: eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU' \
--form 'oldApp="QVBQU0hBUkVENDE4OTYxNjUxMDk2NjAzNzIz"' \
--form 'newApp="QVBQU0hBUkVENDE4OTYxNjUxMDk2ODc2NDQ3"'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": "",
    "extra": []
}
```

<span style="color: #ff0000;">**Nota:** La app tracker compartida solo puede ser utilizada en un solo dispositivo.</span>

# Listar menú - getMenuTracker

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/getMenuTracker

Este método lista el menú que se le debe mostrar en la tracker de acuerdo a su plantilla de botones asignada y si no tiene plantilla, se asigna unos botones por defecto.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr><tr><td style="width: 140px;">imei</td><td style="width: 307px;">IMEI o identificador único del dispositivo codificado en Base64.</td><td style="width: 362px;"><span style="color: #3366ff;">MTIzNDU2Nzg5</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/getMenuTracker' \
--header 'Authorization: eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4_5lSMRgTMU' \
--form 'imei="MTIzNDU2Nzg5"'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": [
        {
            "app": 2,
            "idButton": "6",
            "type": "268",
            "title": "Check In con foto",
            "subtitle": "Inicia tu jornada",
            "colorIconFilter": true,
            "icon": "check-in",
            "color": "#7AA5B4",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "check",
            "checkData": "Inicia mi jornada laboral",
            "showCamera": "true",
            "multiplePictures": "true"
        },
        {
            "app": 2,
            "idButton": "8",
            "type": "1435",
            "title": "Check Out con foto",
            "subtitle": "Termina tu jornada",
            "colorIconFilter": true,
            "icon": "check-out",
            "color": "#0A2367",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "check",
            "checkData": "Salida de mi jornada laboral",
            "showCamera": "true",
            "multiplePictures": "true"
        },
        {
            "app": 2,
            "idButton": "10",
            "type": "1478",
            "title": "Audio",
            "subtitle": "Grabar una nota de audio",
            "colorIconFilter": true,
            "icon": "vol-up",
            "color": "#733d01",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "audio"
        },
        {
            "app": 2,
            "idButton": "11",
            "type": "1477",
            "title": "Imagen",
            "subtitle": "Capturar una imagen",
            "colorIconFilter": true,
            "icon": "file",
            "color": "#9c9900",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "image"
        },
        {
            "app": 2,
            "idButton": "13",
            "type": "1568",
            "title": "Firma",
            "subtitle": "Capturar una firma",
            "colorIconFilter": true,
            "icon": "fingerprint-reader",
            "color": "#522c01",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "signature"
        },
        {
            "app": 2,
            "idButton": "4",
            "type": "576",
            "title": "OnForms",
            "subtitle": "Responde un formulario",
            "colorIconFilter": true,
            "icon": "pdf",
            "color": "#f1c40f",
            "colorIcon": "#FFFFFF",
            "platform": "2",
            "action": "module_forms"
        }
    ],
    "extra": []
}
```

# Finalizar Sesión - logout

##### <span class="api-method" data-method="POST">POST</span> https://api.service24gps.com/api/v1/logout

Finaliza la sesión del dispositivo.

<details class="mb-m" id="bkmrk-body-parametersparam"><summary class="text-muted">Ver parámetros de solicitud:</summary>

<div><table class="table" style="height: 269px; width: 809px;"><tbody><tr><td style="width: 140px;">**Parámetros**</td><td style="width: 307px;">**Descripción**</td><td style="width: 362px;"><span role="presentation" style="padding-right: 0.1px;">**<span role="presentation">Ejemplo</span>**</span></td></tr><tr><td style="width: 140px;">Authorization</td><td style="width: 307px;">Token generado por el método auth.</td><td style="width: 362px;"><span style="color: #3366ff;">eyJ0eXAi5225V1QiLCJhbGciOiJIUz7829.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjcxNjU0MTkiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.TvJclXkRKzKmoDgjeOuZCZOYix4HhTXy4\_5lSMRgTMU</span></td></tr><tr><td style="width: 140px;">uiddevice</td><td style="width: 307px;">Identificador único del dispositivo.</td><td style="width: 362px;"><span style="color: #3366ff;">c1698794d07a\_tp785\_689721</span></td></tr></tbody></table>

</div></details>##### Solicitud de ejemplo:

```shell
curl --location --request POST 'https://api.service24gps.com/api/v1/onapp/logout' \
--header 'Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1aWQiOiJPR1ZrTlRVMk5URTNObU0wTXpNM013PT0iLCJ0eXBlIjoiTWc9PSIsImRhdGV0aW1lIjoiMjAyMjA0MjgwNzEwMTMiLCJleHBpcmUiOjIxNjAwLCJjbGllbnRlIjoiTkRFNE9UYz0iLCJkaXN0cmlidWlkb3IiOiJOREU0T1RZPSJ9.l26c6-zqG8SLukYakCPX8DMZnDpWm0ATzmPCtfggk4o' \
--form 'uiddevice="c1698794d07a_tp785_689721"'
```

##### Respuesta de ejemplo:

```JSON
{
    "status": 200,
    "data": "",
    "extra": []
}
```