From f56d6891aa22152f84ef098f69a29db2942e284b Mon Sep 17 00:00:00 2001 From: Lizandro Guarnizo <77708265+lizandrogd@users.noreply.github.com> Date: Thu, 25 Jun 2026 11:24:23 -0500 Subject: [PATCH] feat(websms): add API integration documentation with code examples Shows endpoint, auth, request/response formats and code tabs for cURL, JavaScript, PHP and Python. API Key is auto-injected from the page state so examples are ready to copy-paste. Co-Authored-By: Claude Sonnet 4.6 --- resources/views/websms_config.html | 138 +++++++++++++++++++++++++++++ 1 file changed, 138 insertions(+) diff --git a/resources/views/websms_config.html b/resources/views/websms_config.html index c8017bd..6359162 100644 --- a/resources/views/websms_config.html +++ b/resources/views/websms_config.html @@ -111,6 +111,144 @@

+ +
+
+
+

Documentación de integración

+

Cómo enviar SMS desde tu propio sistema

+
+ REST API +
+ + +
+

Endpoint

+
+ POST + https://admin.u-site.app/api/sms/send + +
+
+ + +
+

Autenticación

+
+ Incluye tu API Key en el header Authorization: Bearer {API_KEY}.
+ Encuentra tu API Key en la sección API Key (envío externo) de esta página. +
+
+ + +
+
+

Body (JSON)

+
+
{
+  "numero":  "573001234567",
+  "mensaje": "Hola, este es tu código: 9821"
+}
+
+
+
numeroTeléfono en formato internacional sin + (ej: 573001234567)
+
mensajeTexto del SMS. Máx 160 caracteres para un crédito.
+
+
+
+

Respuestas

+
+
+ 200 — Enviado +
+
{ "ok": true, "id": "6a3d4f155..." }
+
+
+
+ 401 — No autenticado +
+
{ "error": "token requerido" }
+
+
+
+ 400 — Datos inválidos +
+
{ "error": "numero y mensaje son requeridos" }
+
+
+
+ 500 — Error LabsMobile +
+
{ "error": "descripción del error" }
+
+
+
+
+
+ + +
+

Ejemplos de código

+ +
+ +
+ + +
+
+

+        
+ +
+ + +
+
+

+        
+ +
+ + +
+
+

+        
+ +
+ + +
+
+

+        
+ +
+
+ +

+
+

Últimos envíos