types-nora-api 0.0.474 → 0.0.477

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/dist/api/graphql/core/index.d.ts +374 -0
  2. package/dist/api/graphql/core/index.js +420 -0
  3. package/dist/api/graphql/index.d.ts +2 -5
  4. package/dist/api/graphql/index.js +3 -6
  5. package/dist/api/graphql/leituras/Arquivo/index.d.ts +41 -0
  6. package/dist/api/graphql/leituras/Arquivo/index.js +74 -0
  7. package/dist/api/graphql/leituras/ArquivoTipadoArte/index.d.ts +35 -0
  8. package/dist/api/graphql/leituras/ArquivoTipadoArte/index.js +50 -0
  9. package/dist/api/graphql/leituras/Aventura/index.d.ts +39 -0
  10. package/dist/api/graphql/leituras/Aventura/index.js +51 -0
  11. package/dist/api/graphql/leituras/ChaveNovoAvatar/index.d.ts +38 -0
  12. package/dist/api/graphql/leituras/ChaveNovoAvatar/index.js +51 -0
  13. package/dist/api/graphql/leituras/DetalheArquivoInterno/index.d.ts +30 -0
  14. package/dist/api/graphql/leituras/DetalheArquivoInterno/index.js +44 -0
  15. package/dist/api/graphql/leituras/Emblema/index.d.ts +38 -0
  16. package/dist/api/graphql/leituras/Emblema/index.js +64 -0
  17. package/dist/api/graphql/leituras/GrupoAventura/index.d.ts +63 -0
  18. package/dist/api/graphql/leituras/GrupoAventura/index.js +159 -0
  19. package/dist/api/graphql/leituras/Personagem/index.d.ts +46 -0
  20. package/dist/api/graphql/leituras/Personagem/index.js +76 -0
  21. package/dist/api/graphql/leituras/Sessao/index.d.ts +54 -0
  22. package/dist/api/graphql/leituras/Sessao/index.js +71 -0
  23. package/dist/api/graphql/leituras/TipoArquivo/index.d.ts +30 -0
  24. package/dist/api/graphql/leituras/TipoArquivo/index.js +48 -0
  25. package/dist/api/graphql/leituras/TipoPersonagem/index.d.ts +31 -0
  26. package/dist/api/graphql/leituras/TipoPersonagem/index.js +49 -0
  27. package/dist/api/graphql/leituras/Usuario/index.d.ts +32 -0
  28. package/dist/api/graphql/leituras/Usuario/index.js +50 -0
  29. package/dist/api/graphql/leituras/index.d.ts +57 -0
  30. package/dist/api/graphql/leituras/index.js +59 -0
  31. package/dist/api/rest/index.d.ts +44 -1
  32. package/dist/api/rest/index.js +41 -1
  33. package/dist/dominio/index.d.ts +56 -0
  34. package/dist/dominio/index.js +14 -0
  35. package/dist/dtos/index.d.ts +40 -80
  36. package/dist/dtos/index.js +1 -69
  37. package/dist/menus/index.d.ts +5 -4
  38. package/dist/menus/index.js +3 -1
  39. package/dist/paginas/index.d.ts +2 -1
  40. package/dist/paginas/index.js +2 -1
  41. package/dist/ws/index.d.ts +214 -1
  42. package/dist/ws/index.js +61 -2
  43. package/package.json +8 -2
@@ -55,6 +55,57 @@ type PAYLOAD__EmitirFichaEmJogo = {
55
55
  codigoSala: SalaDeJogo_Codigo;
56
56
  idFicha: number;
57
57
  };
58
+ declare const TESTE_VOZ_ID_SALA = "testevoz-global";
59
+ type TesteVoz_IdSala = typeof TESTE_VOZ_ID_SALA;
60
+ type TesteVoz_IdUsuario = string;
61
+ type TesteVoz_IdSocket = string;
62
+ type TesteVoz_DescricaoSessaoTipo = "offer" | "answer";
63
+ type TesteVoz_DescricaoSessao = {
64
+ type: TesteVoz_DescricaoSessaoTipo;
65
+ sdp: string;
66
+ };
67
+ type TesteVoz_IceCandidate = {
68
+ candidate: string;
69
+ sdpMid: string | null;
70
+ sdpMLineIndex: number | null;
71
+ usernameFragment?: string | null;
72
+ };
73
+ type PAYLOAD__TesteVoz_entrarNaSala = Record<string, never>;
74
+ type RESPONSE__TesteVoz_entrarNaSala = {
75
+ idSala: TesteVoz_IdSala;
76
+ idUsuario: TesteVoz_IdUsuario;
77
+ usuariosJaConectados: TesteVoz_IdUsuario[];
78
+ };
79
+ type PAYLOAD__TesteVoz_enviarOffer = {
80
+ idUsuarioDestino: TesteVoz_IdUsuario;
81
+ offer: TesteVoz_DescricaoSessao;
82
+ };
83
+ type PAYLOAD__TesteVoz_enviarAnswer = {
84
+ idUsuarioDestino: TesteVoz_IdUsuario;
85
+ answer: TesteVoz_DescricaoSessao;
86
+ };
87
+ type PAYLOAD__TesteVoz_enviarIceCandidate = {
88
+ idUsuarioDestino: TesteVoz_IdUsuario;
89
+ candidate: TesteVoz_IceCandidate;
90
+ };
91
+ type EMIT__TesteVoz_usuarioEntrou = {
92
+ idUsuario: TesteVoz_IdUsuario;
93
+ };
94
+ type EMIT__TesteVoz_usuarioSaiu = {
95
+ idUsuario: TesteVoz_IdUsuario;
96
+ };
97
+ type EMIT__TesteVoz_receberOffer = {
98
+ idUsuarioOrigem: TesteVoz_IdUsuario;
99
+ offer: TesteVoz_DescricaoSessao;
100
+ };
101
+ type EMIT__TesteVoz_receberAnswer = {
102
+ idUsuarioOrigem: TesteVoz_IdUsuario;
103
+ answer: TesteVoz_DescricaoSessao;
104
+ };
105
+ type EMIT__TesteVoz_receberIceCandidate = {
106
+ idUsuarioOrigem: TesteVoz_IdUsuario;
107
+ candidate: TesteVoz_IceCandidate;
108
+ };
58
109
  type SOCKET_AcessoUsuario = {
59
110
  usuario: UsuarioParaObjetoAutenticacaoDto;
60
111
  paginaAtual?: PaginaTemplate | null;
@@ -255,6 +306,64 @@ declare namespace EventosWebSocket {
255
306
  };
256
307
  };
257
308
  };
309
+ readonly TesteVoz: {
310
+ entrarNaSala: {
311
+ tipo: "envia-e-recebe";
312
+ autenticacao_necessaria: false;
313
+ payload: PAYLOAD__TesteVoz_entrarNaSala;
314
+ response: RESPONSE__TesteVoz_entrarNaSala;
315
+ };
316
+ enviarOffer: {
317
+ tipo: "envia";
318
+ autenticacao_necessaria: false;
319
+ payload: PAYLOAD__TesteVoz_enviarOffer;
320
+ };
321
+ enviarAnswer: {
322
+ tipo: "envia";
323
+ autenticacao_necessaria: false;
324
+ payload: PAYLOAD__TesteVoz_enviarAnswer;
325
+ };
326
+ enviarIceCandidate: {
327
+ tipo: "envia";
328
+ autenticacao_necessaria: false;
329
+ payload: PAYLOAD__TesteVoz_enviarIceCandidate;
330
+ };
331
+ usuarioEntrou: {
332
+ tipo: "emite";
333
+ autenticacao_necessaria: false;
334
+ payload: EMIT__TesteVoz_usuarioEntrou;
335
+ response: EMIT__TesteVoz_usuarioEntrou;
336
+ delivery: "broadcast";
337
+ };
338
+ usuarioSaiu: {
339
+ tipo: "emite";
340
+ autenticacao_necessaria: false;
341
+ payload: EMIT__TesteVoz_usuarioSaiu;
342
+ response: EMIT__TesteVoz_usuarioSaiu;
343
+ delivery: "broadcast";
344
+ };
345
+ receberOffer: {
346
+ tipo: "emite";
347
+ autenticacao_necessaria: false;
348
+ payload: EMIT__TesteVoz_receberOffer;
349
+ response: EMIT__TesteVoz_receberOffer;
350
+ delivery: "broadcast";
351
+ };
352
+ receberAnswer: {
353
+ tipo: "emite";
354
+ autenticacao_necessaria: false;
355
+ payload: EMIT__TesteVoz_receberAnswer;
356
+ response: EMIT__TesteVoz_receberAnswer;
357
+ delivery: "broadcast";
358
+ };
359
+ receberIceCandidate: {
360
+ tipo: "emite";
361
+ autenticacao_necessaria: false;
362
+ payload: EMIT__TesteVoz_receberIceCandidate;
363
+ response: EMIT__TesteVoz_receberIceCandidate;
364
+ delivery: "broadcast";
365
+ };
366
+ };
258
367
  };
259
368
  }
260
369
  declare function isRecord(value: unknown): value is Record<string, unknown>;
@@ -336,6 +445,37 @@ declare const Eventos_Envia: {
336
445
  readonly UsuariosExistentes: {
337
446
  eventos: {};
338
447
  };
448
+ readonly TesteVoz: {
449
+ eventos: {
450
+ enviarOffer: {
451
+ tipo: "envia";
452
+ autenticacao_necessaria: false;
453
+ payload: PAYLOAD__TesteVoz_enviarOffer;
454
+ } & {
455
+ readonly nome: "enviarOffer";
456
+ readonly gateway: "TesteVoz";
457
+ readonly fullName: "TesteVoz:enviarOffer";
458
+ };
459
+ enviarAnswer: {
460
+ tipo: "envia";
461
+ autenticacao_necessaria: false;
462
+ payload: PAYLOAD__TesteVoz_enviarAnswer;
463
+ } & {
464
+ readonly nome: "enviarAnswer";
465
+ readonly gateway: "TesteVoz";
466
+ readonly fullName: "TesteVoz:enviarAnswer";
467
+ };
468
+ enviarIceCandidate: {
469
+ tipo: "envia";
470
+ autenticacao_necessaria: false;
471
+ payload: PAYLOAD__TesteVoz_enviarIceCandidate;
472
+ } & {
473
+ readonly nome: "enviarIceCandidate";
474
+ readonly gateway: "TesteVoz";
475
+ readonly fullName: "TesteVoz:enviarIceCandidate";
476
+ };
477
+ };
478
+ };
339
479
  };
340
480
  declare const Eventos_Emite: {
341
481
  readonly Chat: {
@@ -455,6 +595,65 @@ declare const Eventos_Emite: {
455
595
  readonly UsuariosExistentes: {
456
596
  eventos: {};
457
597
  };
598
+ readonly TesteVoz: {
599
+ eventos: {
600
+ usuarioEntrou: {
601
+ tipo: "emite";
602
+ autenticacao_necessaria: false;
603
+ payload: EMIT__TesteVoz_usuarioEntrou;
604
+ response: EMIT__TesteVoz_usuarioEntrou;
605
+ delivery: "broadcast";
606
+ } & {
607
+ readonly nome: "usuarioEntrou";
608
+ readonly gateway: "TesteVoz";
609
+ readonly fullName: "TesteVoz:usuarioEntrou";
610
+ };
611
+ usuarioSaiu: {
612
+ tipo: "emite";
613
+ autenticacao_necessaria: false;
614
+ payload: EMIT__TesteVoz_usuarioSaiu;
615
+ response: EMIT__TesteVoz_usuarioSaiu;
616
+ delivery: "broadcast";
617
+ } & {
618
+ readonly nome: "usuarioSaiu";
619
+ readonly gateway: "TesteVoz";
620
+ readonly fullName: "TesteVoz:usuarioSaiu";
621
+ };
622
+ receberOffer: {
623
+ tipo: "emite";
624
+ autenticacao_necessaria: false;
625
+ payload: EMIT__TesteVoz_receberOffer;
626
+ response: EMIT__TesteVoz_receberOffer;
627
+ delivery: "broadcast";
628
+ } & {
629
+ readonly nome: "receberOffer";
630
+ readonly gateway: "TesteVoz";
631
+ readonly fullName: "TesteVoz:receberOffer";
632
+ };
633
+ receberAnswer: {
634
+ tipo: "emite";
635
+ autenticacao_necessaria: false;
636
+ payload: EMIT__TesteVoz_receberAnswer;
637
+ response: EMIT__TesteVoz_receberAnswer;
638
+ delivery: "broadcast";
639
+ } & {
640
+ readonly nome: "receberAnswer";
641
+ readonly gateway: "TesteVoz";
642
+ readonly fullName: "TesteVoz:receberAnswer";
643
+ };
644
+ receberIceCandidate: {
645
+ tipo: "emite";
646
+ autenticacao_necessaria: false;
647
+ payload: EMIT__TesteVoz_receberIceCandidate;
648
+ response: EMIT__TesteVoz_receberIceCandidate;
649
+ delivery: "broadcast";
650
+ } & {
651
+ readonly nome: "receberIceCandidate";
652
+ readonly gateway: "TesteVoz";
653
+ readonly fullName: "TesteVoz:receberIceCandidate";
654
+ };
655
+ };
656
+ };
458
657
  };
459
658
  declare const Eventos_EnviaERecebe: {
460
659
  readonly Chat: {
@@ -508,5 +707,19 @@ declare const Eventos_EnviaERecebe: {
508
707
  };
509
708
  };
510
709
  };
710
+ readonly TesteVoz: {
711
+ eventos: {
712
+ entrarNaSala: {
713
+ tipo: "envia-e-recebe";
714
+ autenticacao_necessaria: false;
715
+ payload: PAYLOAD__TesteVoz_entrarNaSala;
716
+ response: RESPONSE__TesteVoz_entrarNaSala;
717
+ } & {
718
+ readonly nome: "entrarNaSala";
719
+ readonly gateway: "TesteVoz";
720
+ readonly fullName: "TesteVoz:entrarNaSala";
721
+ };
722
+ };
723
+ };
511
724
  };
512
- export { EmitDelivery, EventoAuthDefault, EventoEmite, EventoEmiteAny, EventoEnvia, EventoEnviaERecebe, EventoSchema, EventoTipo, EventoTipoLiteral, EventosEmiteMap, EventosWebSocket, Eventos_Emite, Eventos_Envia, Eventos_EnviaERecebe, FiltraEventosPorTipo, GatewayDef, Gateways, MensagemChatPayload, MensagemChatRecebida, PAYLOAD__EmitirFichaEmJogo, PAYLOAD__ExecutaTestePericia_PROTOTIPO, PAYLOAD__INDIVIDUAL__NARRADOR_executaAcaoParticipante_PROTOTIPO, PAYLOAD__NARRADOR_executaAcaoParticipante_PROTOTIPO, PAYLOAD__emitirMensagemSalaJogo, PAYLOAD__emitirMensagemSalaJogo__Enviando, PAYLOAD__emitirMensagemSalaJogo__Escutando, PAYLOAD__executaTestePericia, SOCKET_AcessoUsuario, SOCKET_UsuarioExistente, SalaChat, SalaChatFront, TelemetryConnectionInfo, TelemetryEventLog, TelemetrySnapshot, WsEmitParams, WsEmitTarget, WsErrorResponse, WsEventAudience, WsEventAudienceMultiplo, WsEventAudienceUnico, WsResult, WsUnauthorizedErrorResponse, createGateway, criarEventosFiltrados, getEmitDelivery, isRecord, isWsErrorResponse, isWsUnauthorizedErrorResponse, wsChain, wsErro, wsMap, wsUnauthorized };
725
+ export { EMIT__TesteVoz_receberAnswer, EMIT__TesteVoz_receberIceCandidate, EMIT__TesteVoz_receberOffer, EMIT__TesteVoz_usuarioEntrou, EMIT__TesteVoz_usuarioSaiu, EmitDelivery, EventoAuthDefault, EventoEmite, EventoEmiteAny, EventoEnvia, EventoEnviaERecebe, EventoSchema, EventoTipo, EventoTipoLiteral, EventosEmiteMap, EventosWebSocket, Eventos_Emite, Eventos_Envia, Eventos_EnviaERecebe, FiltraEventosPorTipo, GatewayDef, Gateways, MensagemChatPayload, MensagemChatRecebida, PAYLOAD__EmitirFichaEmJogo, PAYLOAD__ExecutaTestePericia_PROTOTIPO, PAYLOAD__INDIVIDUAL__NARRADOR_executaAcaoParticipante_PROTOTIPO, PAYLOAD__NARRADOR_executaAcaoParticipante_PROTOTIPO, PAYLOAD__TesteVoz_entrarNaSala, PAYLOAD__TesteVoz_enviarAnswer, PAYLOAD__TesteVoz_enviarIceCandidate, PAYLOAD__TesteVoz_enviarOffer, PAYLOAD__emitirMensagemSalaJogo, PAYLOAD__emitirMensagemSalaJogo__Enviando, PAYLOAD__emitirMensagemSalaJogo__Escutando, PAYLOAD__executaTestePericia, RESPONSE__TesteVoz_entrarNaSala, SOCKET_AcessoUsuario, SOCKET_UsuarioExistente, SalaChat, SalaChatFront, TESTE_VOZ_ID_SALA, TelemetryConnectionInfo, TelemetryEventLog, TelemetrySnapshot, TesteVoz_DescricaoSessao, TesteVoz_DescricaoSessaoTipo, TesteVoz_IceCandidate, TesteVoz_IdSala, TesteVoz_IdSocket, TesteVoz_IdUsuario, WsEmitParams, WsEmitTarget, WsErrorResponse, WsEventAudience, WsEventAudienceMultiplo, WsEventAudienceUnico, WsResult, WsUnauthorizedErrorResponse, createGateway, criarEventosFiltrados, getEmitDelivery, isRecord, isWsErrorResponse, isWsUnauthorizedErrorResponse, wsChain, wsErro, wsMap, wsUnauthorized };
package/dist/ws/index.js CHANGED
@@ -1,5 +1,6 @@
1
1
  // AUTO-GENERATED FILE - DO NOT EDIT
2
2
  // Contratos WebSocket
3
+ const TESTE_VOZ_ID_SALA = "testevoz-global";
3
4
  function isWsErrorResponse(payload) { return !!payload && typeof payload === "object" && payload._wsErro === true; }
4
5
  function isWsUnauthorizedErrorResponse(payload) { return isWsErrorResponse(payload) && payload.code === "UNAUTHORIZED"; }
5
6
  function wsErro(mensagem, extra) { return { _wsErro: true, mensagem, ...(extra ?? {}) }; }
@@ -97,7 +98,65 @@ var EventosWebSocket;
97
98
  // autenticacao_necessaria: false,
98
99
  },
99
100
  });
100
- EventosWebSocket.gateways = { Chat, Jogo, ExecucaoDeJogo, UsuariosConectados, UsuariosExistentes };
101
+ const TesteVoz = createGateway({
102
+ entrarNaSala: {
103
+ tipo: "envia-e-recebe",
104
+ autenticacao_necessaria: false,
105
+ payload: {},
106
+ response: {},
107
+ },
108
+ enviarOffer: {
109
+ tipo: "envia",
110
+ autenticacao_necessaria: false,
111
+ payload: {},
112
+ },
113
+ enviarAnswer: {
114
+ tipo: "envia",
115
+ autenticacao_necessaria: false,
116
+ payload: {},
117
+ },
118
+ enviarIceCandidate: {
119
+ tipo: "envia",
120
+ autenticacao_necessaria: false,
121
+ payload: {},
122
+ },
123
+ usuarioEntrou: {
124
+ tipo: "emite",
125
+ autenticacao_necessaria: false,
126
+ payload: {},
127
+ response: {},
128
+ delivery: "broadcast",
129
+ },
130
+ usuarioSaiu: {
131
+ tipo: "emite",
132
+ autenticacao_necessaria: false,
133
+ payload: {},
134
+ response: {},
135
+ delivery: "broadcast",
136
+ },
137
+ receberOffer: {
138
+ tipo: "emite",
139
+ autenticacao_necessaria: false,
140
+ payload: {},
141
+ response: {},
142
+ delivery: "broadcast",
143
+ },
144
+ receberAnswer: {
145
+ tipo: "emite",
146
+ autenticacao_necessaria: false,
147
+ payload: {},
148
+ response: {},
149
+ delivery: "broadcast",
150
+ },
151
+ receberIceCandidate: {
152
+ tipo: "emite",
153
+ autenticacao_necessaria: false,
154
+ payload: {},
155
+ response: {},
156
+ delivery: "broadcast",
157
+ },
158
+ });
159
+ EventosWebSocket.gateways = { Chat, Jogo, ExecucaoDeJogo, UsuariosConectados, UsuariosExistentes, TesteVoz };
101
160
  })(EventosWebSocket || (EventosWebSocket = {}));
102
161
  function isRecord(value) { return typeof value === 'object' && value !== null; }
103
162
  function getEmitDelivery(gatewayName, eventName) {
@@ -133,4 +192,4 @@ function criarEventosFiltrados(tipo) {
133
192
  const Eventos_Envia = criarEventosFiltrados('envia');
134
193
  const Eventos_Emite = criarEventosFiltrados('emite');
135
194
  const Eventos_EnviaERecebe = criarEventosFiltrados('envia-e-recebe');
136
- export { EventosWebSocket, Eventos_Emite, Eventos_Envia, Eventos_EnviaERecebe, createGateway, criarEventosFiltrados, getEmitDelivery, isRecord, isWsErrorResponse, isWsUnauthorizedErrorResponse, wsChain, wsErro, wsMap, wsUnauthorized };
195
+ export { EventosWebSocket, Eventos_Emite, Eventos_Envia, Eventos_EnviaERecebe, TESTE_VOZ_ID_SALA, createGateway, criarEventosFiltrados, getEmitDelivery, isRecord, isWsErrorResponse, isWsUnauthorizedErrorResponse, wsChain, wsErro, wsMap, wsUnauthorized };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "types-nora-api",
3
- "version": "0.0.474",
3
+ "version": "0.0.477",
4
4
  "description": "Tipagem da Nora-Api compartilhada com o universodomedo.com",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -63,7 +63,13 @@
63
63
  "clean": "node -e \"const fs = require('fs'); fs.rmSync('dist', { recursive: true, force: true });\"",
64
64
  "build:types": "tsx --tsconfig tsconfig.json scripts/gerarTypesNoraApi.ts",
65
65
  "build": "npm run clean && npm run build:types && tsc",
66
- "prepare": "npm run build"
66
+ "dev": "tsx --tsconfig tsconfig.json scripts/watchTypesNoraApiLocal.ts",
67
+ "check:shape": "tsx --tsconfig tsconfig.json scripts/checkTypesNoraApi.ts",
68
+ "duplicates": "tsx --tsconfig tsconfig.json scripts/reportTypesNoraApiDuplicates.ts",
69
+ "smoke": "tsx --tsconfig tsconfig.json scripts/smokeTypesNoraApi.ts",
70
+ "check": "npm run build && npm run check:shape && npm run duplicates && npm run smoke",
71
+ "doctor": "tsx --tsconfig tsconfig.json scripts/doctorTypesNoraApiLocal.ts",
72
+ "prepublishOnly": "npm run check"
67
73
  },
68
74
  "files": [
69
75
  "dist"