nitrostack 1.0.65 → 1.0.67

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 (61) hide show
  1. package/package.json +3 -2
  2. package/src/studio/README.md +140 -0
  3. package/src/studio/app/api/auth/fetch-metadata/route.ts +71 -0
  4. package/src/studio/app/api/auth/register-client/route.ts +67 -0
  5. package/src/studio/app/api/chat/route.ts +250 -0
  6. package/src/studio/app/api/health/checks/route.ts +42 -0
  7. package/src/studio/app/api/health/route.ts +13 -0
  8. package/src/studio/app/api/init/route.ts +109 -0
  9. package/src/studio/app/api/ping/route.ts +13 -0
  10. package/src/studio/app/api/prompts/[name]/route.ts +21 -0
  11. package/src/studio/app/api/prompts/route.ts +13 -0
  12. package/src/studio/app/api/resources/[...uri]/route.ts +18 -0
  13. package/src/studio/app/api/resources/route.ts +13 -0
  14. package/src/studio/app/api/roots/route.ts +13 -0
  15. package/src/studio/app/api/sampling/route.ts +14 -0
  16. package/src/studio/app/api/tools/[name]/call/route.ts +41 -0
  17. package/src/studio/app/api/tools/route.ts +23 -0
  18. package/src/studio/app/api/widget-examples/route.ts +44 -0
  19. package/src/studio/app/auth/callback/page.tsx +175 -0
  20. package/src/studio/app/auth/page.tsx +560 -0
  21. package/src/studio/app/chat/page.tsx +1133 -0
  22. package/src/studio/app/chat/page.tsx.backup +390 -0
  23. package/src/studio/app/globals.css +486 -0
  24. package/src/studio/app/health/page.tsx +179 -0
  25. package/src/studio/app/layout.tsx +68 -0
  26. package/src/studio/app/logs/page.tsx +279 -0
  27. package/src/studio/app/page.tsx +351 -0
  28. package/src/studio/app/page.tsx.backup +346 -0
  29. package/src/studio/app/ping/page.tsx +209 -0
  30. package/src/studio/app/prompts/page.tsx +230 -0
  31. package/src/studio/app/resources/page.tsx +315 -0
  32. package/src/studio/app/settings/page.tsx +199 -0
  33. package/src/studio/branding.md +807 -0
  34. package/src/studio/components/EnlargeModal.tsx +138 -0
  35. package/src/studio/components/LogMessage.tsx +153 -0
  36. package/src/studio/components/MarkdownRenderer.tsx +410 -0
  37. package/src/studio/components/Sidebar.tsx +295 -0
  38. package/src/studio/components/ToolCard.tsx +139 -0
  39. package/src/studio/components/WidgetRenderer.tsx +346 -0
  40. package/src/studio/lib/api.ts +207 -0
  41. package/src/studio/lib/http-client-transport.ts +222 -0
  42. package/src/studio/lib/llm-service.ts +480 -0
  43. package/src/studio/lib/log-manager.ts +76 -0
  44. package/src/studio/lib/mcp-client.ts +258 -0
  45. package/src/studio/lib/store.ts +192 -0
  46. package/src/studio/lib/theme-provider.tsx +50 -0
  47. package/src/studio/lib/types.ts +107 -0
  48. package/src/studio/lib/widget-loader.ts +90 -0
  49. package/src/studio/middleware.ts +27 -0
  50. package/src/studio/next.config.js +38 -0
  51. package/src/studio/package.json +35 -0
  52. package/src/studio/postcss.config.mjs +10 -0
  53. package/src/studio/public/nitrocloud.png +0 -0
  54. package/src/studio/tailwind.config.ts +67 -0
  55. package/src/studio/tsconfig.json +42 -0
  56. package/templates/typescript-oauth/AI_AGENT_CLI_REFERENCE.md +0 -701
  57. package/templates/typescript-oauth/AI_AGENT_SDK_REFERENCE.md +0 -1260
  58. package/templates/typescript-oauth/package-lock.json +0 -4253
  59. package/templates/typescript-pizzaz/IMPLEMENTATION.md +0 -98
  60. package/templates/typescript-starter/AI_AGENT_CLI_REFERENCE.md +0 -701
  61. package/templates/typescript-starter/AI_AGENT_SDK_REFERENCE.md +0 -1260
@@ -1,98 +0,0 @@
1
- # Pizza Shop Template - Complete Implementation
2
-
3
- This document contains all the code for the remaining files in the pizza shop template.
4
-
5
- ## Server Files
6
-
7
- ### src/modules/pizzaz/pizzaz.module.ts
8
- ```typescript
9
- import { Module } from '@nestjs/common';
10
- import { PizzazService } from './pizzaz.service';
11
- import { PizzazTools } from './pizzaz.tools';
12
-
13
- @Module({
14
- providers: [PizzazService, PizzazTools],
15
- exports: [PizzazService, PizzazTools],
16
- })
17
- export class PizzazModule {}
18
- ```
19
-
20
- ### src/health/health.controller.ts
21
- ```typescript
22
- import { Controller, Get } from '@nestjs/common';
23
-
24
- @Controller('health')
25
- export class HealthController {
26
- @Get()
27
- check() {
28
- return { status: 'ok', timestamp: new Date().toISOString() };
29
- }
30
- }
31
- ```
32
-
33
- ### src/app.module.ts
34
- ```typescript
35
- import { Module } from '@nestjs/common';
36
- import { NitroModule } from 'nitrostack';
37
- import { PizzazModule } from './modules/pizzaz/pizzaz.module';
38
- import { HealthController } from './health/health.controller';
39
-
40
- @Module({
41
- imports: [
42
- NitroModule.forRoot({
43
- name: 'pizzaz-finder',
44
- version: '1.0.0',
45
- description: 'Find the best pizza shops in San Francisco',
46
- }),
47
- PizzazModule,
48
- ],
49
- controllers: [HealthController],
50
- })
51
- export class AppModule {}
52
- ```
53
-
54
- ### src/index.ts
55
- ```typescript
56
- import { NestFactory } from '@nestjs/core';
57
- import { AppModule } from './app.module';
58
-
59
- async function bootstrap() {
60
- const app = await NestFactory.create(AppModule);
61
-
62
- // Enable CORS for studio
63
- app.enableCors();
64
-
65
- const port = process.env.PORT || 3000;
66
- await app.listen(port);
67
-
68
- console.log(`🍕 Pizzaz Finder MCP Server running on http://localhost:${port}`);
69
- console.log(`📍 Health check: http://localhost:${port}/health`);
70
- console.log(`🔧 MCP endpoint: http://localhost:${port}/mcp`);
71
- }
72
-
73
- bootstrap();
74
- ```
75
-
76
- ---
77
-
78
- ## Widget Files
79
-
80
- Due to length, I'll provide the widget implementation as separate files. Please create these files manually or I can provide them in chunks.
81
-
82
- **Key Widget Files Needed:**
83
- 1. `src/widgets/package.json` - Widget dependencies
84
- 2. `src/widgets/next.config.js` - Next.js config
85
- 3. `src/widgets/tailwind.config.ts` - Tailwind config
86
- 4. `src/widgets/app/layout.tsx` - Root layout
87
- 5. `src/widgets/app/pizza-map/page.tsx` - Map widget (uses Mapbox)
88
- 6. `src/widgets/app/pizza-list/page.tsx` - List widget
89
- 7. `src/widgets/app/pizza-shop/page.tsx` - Shop details widget
90
- 8. `src/widgets/components/PizzaCard.tsx` - Reusable card component
91
- 9. `src/widgets/styles/globals.css` - Global styles with Tailwind
92
-
93
- Would you like me to:
94
- A) Create all widget files now (will take multiple steps)
95
- B) Create a simplified version without Mapbox first
96
- C) Provide the code in a single comprehensive document for you to copy
97
-
98
- Let me know your preference and I'll proceed accordingly.