Overview
The Equipment API allows you to manage TETRA radio equipment (terminals) including creating, retrieving, updating, and deleting equipment records. Each equipment has properties like TEI, ISSI, terminal type, state, warranty information, and more.Endpoints
List Equipment
Retrieve a paginated list of equipment with search capabilities.Search term to filter equipment by TEI, ISSI, provider, or owner
Page number for pagination (40 items per page)
Array of equipment objects
Create Equipment
Create a new equipment record.Terminal type ID (references tipo_terminal table)
Equipment state name
TETRA Equipment Identity (must be unique)
Individual Short Subscriber Identity
Descriptive name for the ISSI
Equipment owner
Equipment provider
Warranty status checkbox
Warranty expiration date
Additional observations
/equipos on success.
Error Responses
“Ya se encuentra un equipo con el mismo TEI” - Equipment with this TEI already exists
Show Equipment
Equipment ID
Update Equipment
Update an existing equipment record.Equipment ID to update
TETRA Equipment Identity
State ID
State change date
Individual Short Subscriber Identity
ISSI name
Primary battery number
Secondary battery number
Provider
Owner
Warranty checkbox
Warranty expiration
Observations
Delete Equipment
Delete an equipment record and all related fleet and history records.Equipment ID to delete
/equipos with success message.
Error Response
“Equipo no encontrado.” - Equipment not found
Additional Endpoints
View Equipment History
View assignment history for a specific equipment.Equipment ID
Export Equipment to Excel
Export all equipment records to an Excel file.ListadoEquipos_{timestamp}.xlsx.
Example Request
Error Codes
Bad Request - Missing required fields or validation error
Unauthorized - Authentication required
Forbidden - Insufficient permissions (requires ver-equipo, crear-equipo, editar-equipo, or borrar-equipo)
Not Found - Equipment not found
Unprocessable Entity - Duplicate TEI or validation failure
Models
Equipment Model
The Equipment model (App\Models\Equipo) represents a TETRA radio terminal.
Relationships
tipo_terminal- BelongsTo TipoTerminal (brand, model, type)estado- BelongsTo Estado (operational state)flota_general- HasMany FlotaGeneral (fleet assignments)historico- HasMany Historico (assignment history)auditoria- HasMany Auditoria (audit trail)
app/Http/Controllers/EquipoController.php
Model: app/Models/Equipo.php