Saltar al contenido
Skillpedia
APIs y servidores (backend)25 mil · #10085

nocobase-realtime

Qué hace

Esta skill guía el diseño de actualizaciones en vivo en aplicaciones y plugins de NocoBase 3. Es para desarrolladores que quieren que las páginas muestren datos nuevos o el progreso según ocurre.

Cuándo usarla

  • ✓Cuando quieres que una página se actualice al cambiar registros, sin hacer consultas repetidas.
  • ✓Cuando necesitas mostrar el progreso de una tarea o notificaciones personales en directo.
  • ✓Cuando quieres transmitir registros o enviar actualizaciones en vivo a varios procesos del servidor.

Link de la skill

https://github.com/nocobase/nocobase/blob/v3-develop/packages/libs/realtime/skills/nocobase-realtime/SKILL.md

Cópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.

Cómo usar

La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.

Mensaje listo para pegar

Usa esta skill para ayudarme: https://github.com/nocobase/nocobase/blob/v3-develop/packages/libs/realtime/skills/nocobase-realtime/SKILL.md Lee el archivo SKILL.md de ese link y sigue sus instrucciones en mi tarea.
¿Quieres que tu IA encuentre skills como esta por sí sola?Instala el MCP gratis de Skillpedia: una línea, y busca entre 15.000+ skills antes de cada tarea.Instalar en 1 minuto →

Ejemplo de qué pedirle a la IA

“Quiero que mi página de pedidos se actualice en vivo cuando se guarde un pedido nuevo, sin tener que recargarla cada pocos segundos.”

5 skills nuevas por semana. 1 minuto de lectura.

Cómo funciona

La IA decide qué fuente de datos es la autoritativa y después configura los temas del servidor y los hooks del cliente. Los eventos en vivo son avisos breves, y la página vuelve a cargar los datos reales cuando hace falta.

Contenido técnico (SKILL.md original)

Texto original del autor, en inglés, directo de GitHub.

NocoBase Realtime

Use the installed package declarations as the API authority. Applications reuse the host server service through realtimeServiceToken from @nocobase/app-server/realtime and the host browser client through @nocobase/app-client. Do not create a socket or service per component. In a source workspace, this Skill lives under packages/libs/realtime/skills/nocobase-realtime; in generated applications, package Skills are synchronized copies.

Choose the data contract first

Identify the authoritative snapshot endpoint, its access policy, the committed writes that announce changes, and how a disconnected client catches up. Realtime events are transient hints; durable business data remains in its owning service. A successful publication means broker admission, not browser processing. Prefer small invalidations containing a record ID or revision over copying protected record contents into an event.

  • Read server integration for topic declaration, resource authorization, transaction boundaries, limits and distributed deployment.
  • Read client integration for query correctness, coalesced refresh, readiness, errors, manual retry and cleanup.
  • Read business scenarios when choosing between snapshots, cursors, progress and periodic reconciliation.
  • Read verification for meaningful acceptance cases and adapter recovery tests.

Boundaries to preserve

Register topics during provider boot and release them during shutdown. Unknown topics are denied. A user topic derives the subscriber's user from the authenticated connection; publishing uses the intended recipient, never a user ID supplied as subscription authority by the browser. Resource families reuse the HTTP endpoint's policy and recheck it on delivery.

Publish only after commit. Treat a notification failure separately from an already successful write; use the domain's durable job/outbox when announcements must be retried. Never skip distributed publication because this process has no subscribers. eventId supports tracing and bounded duplicate suppression; business revisions and persisted cursors own ordering and gap recovery.

Read snapshots after the topic's onReady, including initial subscription and reconnect. Transport onOpen is too early. For TanStack Query use refreshRealtimeQueries, which waits for pre-event reads and follows them with a new read. Return the actual refresh promise to the scheduler so failures and trailing events are observed.

Remove a poll only after identifying all its producers and failure recovery. Time-based expiry, external systems without announcements, bounded initialization waits and failed best-effort publication can still require reconciliation. A healthy WebSocket alone does not prove the snapshot is fresh.

Preguntas frecuentes

¿Un evento en vivo contiene todos los datos?

No. Los eventos son avisos breves, y los datos duraderos se mantienen en su servicio habitual.

¿Es esto para las funciones de voz de OpenAI?

No. Es para actualizaciones en vivo dentro de las aplicaciones NocoBase.

¿Qué pasa cuando se desconecta un navegador?

La skill cubre la recuperación por instantánea, para que la página se ponga al día al reconectarse.

Detalles

Descripción original del autor

Design and implement live updates in NocoBase 3 applications and plugins using @nocobase/realtime, host client hooks and authorized server topics. Use for replacing business polling, snapshot recovery, task progress, personal notifications, streamed logs or multi-process fan-out. Not for OpenAI audio Realtime APIs.

repo: nocobase/nocobase

Popularidad

Estrellas en GitHub
25 mil
Posición en el ranking
#10085
Licencia
—
Actualizada
2/11/2026

¿Te sirve esta skill?

0

Entra para votar.

Comentarios

  • …

Más skills de este repositorio

Skills parecidas