@adminide-stack/marketplace-module-server 12.0.4-alpha.95 → 13.0.1-alpha.0

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 (175) hide show
  1. package/lib/containers/module.d.ts +4 -4
  2. package/lib/containers/module.d.ts.map +1 -1
  3. package/lib/containers/module.js +12 -7
  4. package/lib/containers/module.js.map +1 -1
  5. package/lib/dataloaders/index.d.ts +1 -1
  6. package/lib/dataloaders/index.d.ts.map +1 -1
  7. package/lib/dataloaders/publisher-data-loader.d.ts +6 -0
  8. package/lib/dataloaders/publisher-data-loader.d.ts.map +1 -0
  9. package/lib/demo/test-graphql-examples.d.ts +73 -0
  10. package/lib/demo/test-graphql-examples.d.ts.map +1 -0
  11. package/lib/graphql/resolvers/form-templates-resolver.d.ts +220 -0
  12. package/lib/graphql/resolvers/form-templates-resolver.d.ts.map +1 -0
  13. package/lib/graphql/resolvers/form-templates-resolver.js +170 -0
  14. package/lib/graphql/resolvers/form-templates-resolver.js.map +1 -0
  15. package/lib/graphql/resolvers/gallery-resolver.d.ts +15 -0
  16. package/lib/graphql/resolvers/gallery-resolver.d.ts.map +1 -0
  17. package/lib/graphql/resolvers/gallery-resolver.js +35 -0
  18. package/lib/graphql/resolvers/gallery-resolver.js.map +1 -0
  19. package/lib/graphql/resolvers/index.d.ts +247 -1
  20. package/lib/graphql/resolvers/index.d.ts.map +1 -1
  21. package/lib/graphql/resolvers/index.js +1 -1
  22. package/lib/graphql/resolvers/installed-extension-resolver.d.ts.map +1 -1
  23. package/lib/graphql/resolvers/installed-extension-resolver.js +161 -35
  24. package/lib/graphql/resolvers/installed-extension-resolver.js.map +1 -1
  25. package/lib/graphql/resolvers/marketplace-form-resolver.d.ts +13 -0
  26. package/lib/graphql/resolvers/marketplace-form-resolver.d.ts.map +1 -0
  27. package/lib/graphql/resolvers/marketplace-form-resolver.js +90 -0
  28. package/lib/graphql/resolvers/marketplace-form-resolver.js.map +1 -0
  29. package/lib/graphql/resolvers/publisher-analytics-resolver.d.ts +14 -0
  30. package/lib/graphql/resolvers/publisher-analytics-resolver.d.ts.map +1 -0
  31. package/lib/graphql/resolvers/publisher-analytics-resolver.js +221 -0
  32. package/lib/graphql/resolvers/publisher-analytics-resolver.js.map +1 -0
  33. package/lib/graphql/resolvers/publisher-resolver.d.ts +5 -0
  34. package/lib/graphql/resolvers/publisher-resolver.d.ts.map +1 -0
  35. package/lib/graphql/resolvers/publisher-resolver.js +183 -0
  36. package/lib/graphql/resolvers/publisher-resolver.js.map +1 -0
  37. package/lib/graphql/resolvers/registry-extension-resolver.d.ts.map +1 -1
  38. package/lib/graphql/resolvers/registry-extension-resolver.js +34 -167
  39. package/lib/graphql/resolvers/registry-extension-resolver.js.map +1 -1
  40. package/lib/graphql/schemas/extension-pricing.graphql +546 -0
  41. package/lib/graphql/schemas/extension-pricing.graphql.js +1 -0
  42. package/lib/graphql/schemas/extension-pricing.graphql.js.map +1 -0
  43. package/lib/graphql/schemas/extension-registry.graphql +91 -58
  44. package/lib/graphql/schemas/extension-registry.graphql.js +1 -1
  45. package/lib/graphql/schemas/form-templates.graphql +269 -0
  46. package/lib/graphql/schemas/form-templates.graphql.js +1 -0
  47. package/lib/graphql/schemas/form-templates.graphql.js.map +1 -0
  48. package/lib/graphql/schemas/gallery-schema.graphql +247 -0
  49. package/lib/graphql/schemas/gallery-schema.graphql.js +1 -0
  50. package/lib/graphql/schemas/gallery-schema.graphql.js.map +1 -0
  51. package/lib/graphql/schemas/index.d.ts.map +1 -1
  52. package/lib/graphql/schemas/index.js +3 -1
  53. package/lib/graphql/schemas/index.js.map +1 -1
  54. package/lib/graphql/schemas/installed-extension.graphql +37 -7
  55. package/lib/graphql/schemas/installed-extension.graphql.js +1 -1
  56. package/lib/graphql/schemas/publisher-analytics.graphql +305 -0
  57. package/lib/graphql/schemas/publisher-analytics.graphql.js +1 -0
  58. package/lib/graphql/schemas/publisher-analytics.graphql.js.map +1 -0
  59. package/lib/graphql/schemas/publisher.graphql +584 -0
  60. package/lib/graphql/schemas/publisher.graphql.js +1 -0
  61. package/lib/graphql/schemas/publisher.graphql.js.map +1 -0
  62. package/lib/graphql/schemas/service.graphql +15 -0
  63. package/lib/index.d.ts +1 -1
  64. package/lib/index.js +1 -1
  65. package/lib/index.js.map +1 -1
  66. package/lib/migrations/dbMigrations/DropOldPublisherIndexMigration.d.ts +20 -0
  67. package/lib/migrations/dbMigrations/DropOldPublisherIndexMigration.d.ts.map +1 -0
  68. package/lib/migrations/dbMigrations/DropOldPublisherIndexMigration.js +61 -0
  69. package/lib/migrations/dbMigrations/DropOldPublisherIndexMigration.js.map +1 -0
  70. package/lib/migrations/index.d.ts +2 -0
  71. package/lib/migrations/index.d.ts.map +1 -0
  72. package/lib/module.d.ts +1 -1
  73. package/lib/module.d.ts.map +1 -1
  74. package/lib/module.js +11 -26
  75. package/lib/module.js.map +1 -1
  76. package/lib/services/extension-gallery-repository.d.ts +17 -0
  77. package/lib/services/extension-gallery-repository.d.ts.map +1 -0
  78. package/lib/services/extension-gallery-repository.js +192 -0
  79. package/lib/services/extension-gallery-repository.js.map +1 -0
  80. package/lib/services/extension-gallery-service-new.d.ts +39 -0
  81. package/lib/services/extension-gallery-service-new.d.ts.map +1 -0
  82. package/lib/services/extension-gallery-service.d.ts +30 -0
  83. package/lib/services/extension-gallery-service.d.ts.map +1 -0
  84. package/lib/services/extension-gallery-service.js +334 -0
  85. package/lib/services/extension-gallery-service.js.map +1 -0
  86. package/lib/services/index.d.ts +4 -1
  87. package/lib/services/index.d.ts.map +1 -1
  88. package/lib/services/installed-extension-service-ext.d.ts +5 -2
  89. package/lib/services/installed-extension-service-ext.d.ts.map +1 -1
  90. package/lib/services/installed-extension-service-ext.js +364 -117
  91. package/lib/services/installed-extension-service-ext.js.map +1 -1
  92. package/lib/services/installed-extension-service.d.ts +30 -13
  93. package/lib/services/installed-extension-service.d.ts.map +1 -1
  94. package/lib/services/installed-extension-service.js +301 -68
  95. package/lib/services/installed-extension-service.js.map +1 -1
  96. package/lib/services/installed-extension-service.test.d.ts +0 -1
  97. package/lib/services/publisher-analytics-service.d.ts +128 -0
  98. package/lib/services/publisher-analytics-service.d.ts.map +1 -0
  99. package/lib/services/publisher-event-service.d.ts +48 -0
  100. package/lib/services/publisher-event-service.d.ts.map +1 -0
  101. package/lib/services/publisher-event-service.js +296 -0
  102. package/lib/services/publisher-event-service.js.map +1 -0
  103. package/lib/services/publisher-service-context.d.ts +1 -0
  104. package/lib/services/publisher-service-context.d.ts.map +1 -0
  105. package/lib/services/publisher-service.d.ts +62 -0
  106. package/lib/services/publisher-service.d.ts.map +1 -0
  107. package/lib/services/publisher-service.js +135 -0
  108. package/lib/services/publisher-service.js.map +1 -0
  109. package/lib/store/models/index.d.ts +1 -1
  110. package/lib/store/models/index.d.ts.map +1 -1
  111. package/lib/store/models/installed-extension-model.d.ts.map +1 -1
  112. package/lib/store/models/installed-extension-model.js +17 -45
  113. package/lib/store/models/installed-extension-model.js.map +1 -1
  114. package/lib/store/models/publisher-event-model.d.ts +11 -0
  115. package/lib/store/models/publisher-event-model.d.ts.map +1 -0
  116. package/lib/store/models/publisher-model.d.ts +5 -0
  117. package/lib/store/models/publisher-model.d.ts.map +1 -0
  118. package/lib/store/models/publisher-model.js +117 -0
  119. package/lib/store/models/publisher-model.js.map +1 -0
  120. package/lib/store/models/publisher-stats-model.d.ts +1 -0
  121. package/lib/store/models/publisher-stats-model.d.ts.map +1 -0
  122. package/lib/store/repositories/index.d.ts +1 -1
  123. package/lib/store/repositories/index.d.ts.map +1 -1
  124. package/lib/store/repositories/installed-extension-repository.d.ts +17 -11
  125. package/lib/store/repositories/installed-extension-repository.d.ts.map +1 -1
  126. package/lib/store/repositories/installed-extension-repository.js +123 -75
  127. package/lib/store/repositories/installed-extension-repository.js.map +1 -1
  128. package/lib/store/repositories/publisher-analytics-repository.d.ts +1 -0
  129. package/lib/store/repositories/publisher-analytics-repository.d.ts.map +1 -0
  130. package/lib/store/repositories/publisher-repository.d.ts +19 -0
  131. package/lib/store/repositories/publisher-repository.d.ts.map +1 -0
  132. package/lib/store/repositories/publisher-repository.js +87 -0
  133. package/lib/store/repositories/publisher-repository.js.map +1 -0
  134. package/lib/templates/constants/DB_COLL_NAMES.ts.template +1 -1
  135. package/lib/templates/constants/SERVER_TYPES.ts.template +8 -5
  136. package/lib/templates/repositories/ExtensionGalleryRepository.ts.template +44 -0
  137. package/lib/templates/repositories/InstalledExtensionRepository.ts.template +19 -14
  138. package/lib/templates/repositories/MarketplacePublisherRepository.ts.template +24 -0
  139. package/lib/templates/repositories/RegistryExtensionRepository.ts.template +2 -2
  140. package/lib/templates/services/ExtensionGalleryDataLoader.ts.template +2 -0
  141. package/lib/templates/services/ExtensionGalleryService.ts.template +79 -0
  142. package/lib/templates/services/InstalledExtensionService.ts.template +63 -32
  143. package/lib/templates/services/MarketplacePublisherService.ts.template +51 -0
  144. package/lib/templates/services/PublisherDataLoader.ts.template +3 -0
  145. package/lib/templates/services/PublisherEventService.ts.template +56 -0
  146. package/lib/templates/services/RegistryExtensionService.ts.template +46 -2
  147. package/lib/tests/extension-integration.test.d.ts +0 -1
  148. package/lib/tests/install-extension-graphql.test.d.ts +2 -0
  149. package/lib/tests/install-extension-graphql.test.d.ts.map +1 -0
  150. package/lib/utils/publisherValidation.d.ts +23 -0
  151. package/lib/utils/publisherValidation.d.ts.map +1 -0
  152. package/lib/utils/publisherValidation.js +144 -0
  153. package/lib/utils/publisherValidation.js.map +1 -0
  154. package/package.json +13 -9
  155. package/lib/constants/extension-events.d.ts +0 -136
  156. package/lib/constants/extension-events.d.ts.map +0 -1
  157. package/lib/dataloaders/registry-extension-data-loader.d.ts +0 -6
  158. package/lib/dataloaders/registry-extension-data-loader.d.ts.map +0 -1
  159. package/lib/dataloaders/registry-extension-data-loader.js +0 -6
  160. package/lib/dataloaders/registry-extension-data-loader.js.map +0 -1
  161. package/lib/graphql/schemas/service.graphql.js +0 -1
  162. package/lib/graphql/schemas/service.graphql.js.map +0 -1
  163. package/lib/services/extension-service.d.ts +0 -42
  164. package/lib/services/extension-service.d.ts.map +0 -1
  165. package/lib/services/extension-service.js +0 -60
  166. package/lib/services/extension-service.js.map +0 -1
  167. package/lib/store/models/registry-extension-model.d.ts +0 -5
  168. package/lib/store/models/registry-extension-model.d.ts.map +0 -1
  169. package/lib/store/models/registry-extension-model.js +0 -83
  170. package/lib/store/models/registry-extension-model.js.map +0 -1
  171. package/lib/store/repositories/registry-extension-repository.d.ts +0 -54
  172. package/lib/store/repositories/registry-extension-repository.d.ts.map +0 -1
  173. package/lib/store/repositories/registry-extension-repository.js +0 -137
  174. package/lib/store/repositories/registry-extension-repository.js.map +0 -1
  175. package/lib/templates/services/RegistryExtensionDataLoader.ts.template +0 -2
@@ -0,0 +1,584 @@
1
+ """
2
+ A publisher represents an organization or individual who publishes extensions
3
+ """
4
+ type MarketplacePublisher implements Node @entity {
5
+ """
6
+ The unique identifier of the publisher.
7
+ """
8
+ id: ID! @id
9
+
10
+ """
11
+ The unique publisher ID (UUID).
12
+ """
13
+ publisherId: String! @column
14
+
15
+ """
16
+ The unique name/slug of the publisher (e.g., 'stackflow1', 'microsoft').
17
+ """
18
+ name: String! @column
19
+
20
+ """
21
+ The display name of the publisher.
22
+ """
23
+ displayName: String! @column
24
+
25
+ """
26
+ The publisher's description.
27
+ """
28
+ description: String @column
29
+
30
+ """
31
+ The publisher's website URL.
32
+ """
33
+ websiteUrl: String @column
34
+
35
+ """
36
+ The publisher's logo/avatar URL.
37
+ """
38
+ logoUrl: String @column
39
+
40
+ """
41
+ The publisher's avatar URL (alias for logoUrl).
42
+ """
43
+ avatar: String @column
44
+
45
+ """
46
+ The publisher's email contact.
47
+ """
48
+ email: String @column
49
+
50
+ """
51
+ The tenant ID associated with this publisher.
52
+ """
53
+ tenant: Tenant @column(overrideType: "ObjectId")
54
+
55
+ """
56
+ Whether the publisher is verified.
57
+ """
58
+ verified: Boolean! @column
59
+
60
+ """
61
+ The date when the publisher was created.
62
+ """
63
+ createdAt: DateTime! @column(overrideType: "Date")
64
+
65
+ """
66
+ The date when the publisher was last updated.
67
+ """
68
+ updatedAt: DateTime! @column(overrideType: "Date")
69
+
70
+ """
71
+ The number of extensions published by this publisher.
72
+ """
73
+ extensionCount: Int! @column
74
+
75
+ """
76
+ The total number of downloads across all extensions.
77
+ """
78
+ totalDownloads: Int! @column
79
+
80
+ """
81
+ The extensions published by this publisher.
82
+ """
83
+ extensions: [RegistryExtension!]! @column(overrideType: "[ObjectId]")
84
+
85
+ """
86
+ Whether the current user can manage this publisher.
87
+ """
88
+ viewerCanManage: Boolean!
89
+
90
+ """
91
+ Real-time analytics stats (computed from time series data).
92
+ """
93
+ stats: MarketplacePublisherStats
94
+
95
+ """
96
+ Historical analytics data (computed from time series data).
97
+ """
98
+ analytics(
99
+ startDate: DateTime!
100
+ endDate: DateTime!
101
+ granularity: AnalyticsGranularity!
102
+ ): [MarketplacePublisherAnalytics!]!
103
+
104
+ """
105
+ Trend analysis (computed from time series data).
106
+ """
107
+ trends(days: Int = 30): MarketplacePublisherTrend
108
+ }
109
+
110
+ """
111
+ Publisher statistics and metrics
112
+ """
113
+ type PublisherStats {
114
+ """
115
+ Total number of extensions.
116
+ """
117
+ totalExtensions: Int!
118
+
119
+ """
120
+ Total downloads across all extensions.
121
+ """
122
+ totalDownloads: Int!
123
+
124
+ """
125
+ Total active installations.
126
+ """
127
+ totalInstallations: Int!
128
+
129
+ """
130
+ Average rating across all extensions.
131
+ """
132
+ averageRating: Float!
133
+
134
+ """
135
+ Number of verified publishers.
136
+ """
137
+ verifiedCount: Int!
138
+
139
+ """
140
+ Most popular extension.
141
+ """
142
+ topExtension: RegistryExtension
143
+ }
144
+
145
+ """
146
+ Real-time analytics stats for a marketplace publisher (computed from time series)
147
+ """
148
+ type MarketplacePublisherStats {
149
+ """
150
+ Total number of downloads.
151
+ """
152
+ totalDownloads: Int!
153
+
154
+ """
155
+ Total number of installations.
156
+ """
157
+ totalInstalls: Int!
158
+
159
+ """
160
+ Total number of views.
161
+ """
162
+ totalViews: Int!
163
+
164
+ """
165
+ Average rating.
166
+ """
167
+ averageRating: Float!
168
+
169
+ """
170
+ Total number of ratings received.
171
+ """
172
+ totalRatings: Int!
173
+
174
+ """
175
+ Number of extensions published.
176
+ """
177
+ extensionCount: Int!
178
+
179
+ """
180
+ Last updated timestamp.
181
+ """
182
+ lastUpdated: DateTime!
183
+ }
184
+
185
+ """
186
+ Historical analytics data point for a marketplace publisher (computed from time series)
187
+ """
188
+ type MarketplacePublisherAnalytics {
189
+ """
190
+ The date/time for this data point.
191
+ """
192
+ date: DateTime!
193
+
194
+ """
195
+ Number of downloads in this period.
196
+ """
197
+ downloads: Int!
198
+
199
+ """
200
+ Number of installations in this period.
201
+ """
202
+ installs: Int!
203
+
204
+ """
205
+ Number of views in this period.
206
+ """
207
+ views: Int!
208
+
209
+ """
210
+ Number of ratings in this period.
211
+ """
212
+ ratings: Int!
213
+
214
+ """
215
+ Average rating for this period.
216
+ """
217
+ averageRating: Float!
218
+
219
+ """
220
+ Unique users who interacted with publisher content.
221
+ """
222
+ uniqueUsers: Int!
223
+ }
224
+
225
+ """
226
+ Trend analysis for a marketplace publisher (computed from time series)
227
+ """
228
+ type MarketplacePublisherTrend {
229
+ """
230
+ Download trend direction.
231
+ """
232
+ downloadTrend: TrendDirection!
233
+
234
+ """
235
+ Download trend percentage change.
236
+ """
237
+ downloadChange: Float!
238
+
239
+ """
240
+ Installation trend direction.
241
+ """
242
+ installTrend: TrendDirection!
243
+
244
+ """
245
+ Installation trend percentage change.
246
+ """
247
+ installChange: Float!
248
+
249
+ """
250
+ View trend direction.
251
+ """
252
+ viewTrend: TrendDirection!
253
+
254
+ """
255
+ View trend percentage change.
256
+ """
257
+ viewChange: Float!
258
+
259
+ """
260
+ Rating trend direction.
261
+ """
262
+ ratingTrend: TrendDirection!
263
+
264
+ """
265
+ Rating trend percentage change.
266
+ """
267
+ ratingChange: Float!
268
+
269
+ """
270
+ Overall trend score (composite metric).
271
+ """
272
+ trendScore: Float!
273
+ }
274
+
275
+ """
276
+ Analytics granularity options
277
+ """
278
+ enum AnalyticsGranularity {
279
+ HOUR
280
+ DAY
281
+ WEEK
282
+ MONTH
283
+ YEAR
284
+ }
285
+
286
+ """
287
+ Trend direction enumeration
288
+ """
289
+ enum TrendDirection {
290
+ INCREASING
291
+ DECREASING
292
+ STABLE
293
+ }
294
+
295
+ extend type Query {
296
+ """
297
+ Get a publisher by name.
298
+ """
299
+ publisher(name: String!): MarketplacePublisher
300
+
301
+ """
302
+ Get all publishers with optional filtering.
303
+ """
304
+ publishers(
305
+ """
306
+ Filter by verified status.
307
+ """
308
+ verified: Boolean
309
+
310
+ """
311
+ Search query for publisher name or description.
312
+ """
313
+ search: String
314
+
315
+ """
316
+ Number of results to return (default: 20, max: 100).
317
+ """
318
+ first: Int
319
+
320
+ """
321
+ Number of results to skip.
322
+ """
323
+ skip: Int
324
+
325
+ """
326
+ Sort order.
327
+ """
328
+ orderBy: PublisherOrderBy
329
+ ): PublisherConnection!
330
+
331
+ """
332
+ Get publisher statistics.
333
+ """
334
+ publisherStats: PublisherStats!
335
+ }
336
+
337
+ extend type Mutation {
338
+ """
339
+ Create a new publisher.
340
+ """
341
+ createPublisherMutation(input: CreatePublisherInput!): CreatePublisherPayload!
342
+
343
+ """
344
+ Update an existing publisher.
345
+ """
346
+ updatePublisherMutation(id: ID!, input: UpdatePublisherInput!): UpdatePublisherPayload!
347
+
348
+ """
349
+ Verify a publisher.
350
+ """
351
+ verifyPublisherMutation(id: ID!): VerifyPublisherPayload!
352
+ }
353
+
354
+ """
355
+ Input for creating a new publisher
356
+ """
357
+ input CreatePublisherInput {
358
+ """
359
+ The display name of the publisher.
360
+ """
361
+ displayName: String!
362
+
363
+ """
364
+ The unique name/slug of the publisher.
365
+ """
366
+ publisherName: String!
367
+
368
+ """
369
+ The publisher's description.
370
+ """
371
+ description: String
372
+
373
+ """
374
+ The publisher's website URL.
375
+ """
376
+ website: String
377
+
378
+ """
379
+ The publisher's email contact.
380
+ """
381
+ email: String
382
+
383
+ """
384
+ The publisher's domain for verification.
385
+ """
386
+ domain: String
387
+
388
+ """
389
+ The tenant ID associated with this publisher.
390
+ """
391
+ tenant: ID
392
+ }
393
+
394
+ """
395
+ Input for updating a publisher
396
+ """
397
+ input UpdatePublisherInput {
398
+ """
399
+ The display name of the publisher.
400
+ """
401
+ displayName: String!
402
+
403
+ """
404
+ The publisher's description.
405
+ """
406
+ description: String
407
+
408
+ """
409
+ The publisher's website URL.
410
+ """
411
+ website: String
412
+
413
+ """
414
+ The publisher's logo/avatar URL.
415
+ """
416
+ avatarUrl: String
417
+
418
+ """
419
+ The tenant ID associated with this publisher.
420
+ """
421
+ tenant: ID
422
+ }
423
+
424
+ """
425
+ Payload for create publisher mutation
426
+ """
427
+ type CreatePublisherPayload {
428
+ """
429
+ The created publisher.
430
+ """
431
+ publisher: MarketplacePublisher!
432
+
433
+ """
434
+ Success flag.
435
+ """
436
+ success: Boolean!
437
+
438
+ """
439
+ Error message if any.
440
+ """
441
+ error: String
442
+ }
443
+
444
+ """
445
+ Payload for update publisher mutation
446
+ """
447
+ type UpdatePublisherPayload {
448
+ """
449
+ The updated publisher.
450
+ """
451
+ publisher: MarketplacePublisher
452
+
453
+ """
454
+ Success flag.
455
+ """
456
+ success: Boolean!
457
+
458
+ """
459
+ Error message if any.
460
+ """
461
+ error: String
462
+ }
463
+
464
+ """
465
+ Payload for verify publisher mutation
466
+ """
467
+ type VerifyPublisherPayload {
468
+ """
469
+ The verified publisher.
470
+ """
471
+ publisher: MarketplacePublisher
472
+
473
+ """
474
+ Success flag.
475
+ """
476
+ success: Boolean!
477
+
478
+ """
479
+ Error message if any.
480
+ """
481
+ error: String
482
+ }
483
+
484
+ """
485
+ Publisher connection for pagination
486
+ """
487
+ type PublisherConnection {
488
+ """
489
+ List of publishers.
490
+ """
491
+ nodes: [MarketplacePublisher!]!
492
+
493
+ """
494
+ Total count of publishers.
495
+ """
496
+ totalCount: Int!
497
+
498
+ """
499
+ Whether there are more results.
500
+ """
501
+ hasNextPage: Boolean!
502
+
503
+ """
504
+ Whether there are previous results.
505
+ """
506
+ hasPreviousPage: Boolean!
507
+ }
508
+
509
+ """
510
+ Sort options for publishers
511
+ """
512
+ enum PublisherOrderBy {
513
+ """
514
+ Sort by name (A-Z).
515
+ """
516
+ NAME_ASC
517
+
518
+ """
519
+ Sort by name (Z-A).
520
+ """
521
+ NAME_DESC
522
+
523
+ """
524
+ Sort by creation date (newest first).
525
+ """
526
+ CREATED_DESC
527
+
528
+ """
529
+ Sort by creation date (oldest first).
530
+ """
531
+ CREATED_ASC
532
+
533
+ """
534
+ Sort by extension count (most first).
535
+ """
536
+ EXTENSIONS_DESC
537
+
538
+ """
539
+ Sort by extension count (least first).
540
+ """
541
+ EXTENSIONS_ASC
542
+
543
+ """
544
+ Sort by total downloads (most first).
545
+ """
546
+ DOWNLOADS_DESC
547
+
548
+ """
549
+ Sort by total downloads (least first).
550
+ """
551
+ DOWNLOADS_ASC
552
+ }
553
+
554
+ """
555
+ Extension manifest author information
556
+ """
557
+ type ExtensionManifestAuthor @entity(embedded: true) {
558
+ """
559
+ The author's name.
560
+ """
561
+ name: String! @column
562
+
563
+ """
564
+ The author's email.
565
+ """
566
+ email: String @column
567
+
568
+ """
569
+ The author's website URL.
570
+ """
571
+ url: String @column
572
+
573
+ """
574
+ Whether the author is verified.
575
+ """
576
+ verified: Boolean @column
577
+ }
578
+
579
+ extend type ExtensionManifest {
580
+ """
581
+ The publisher who published this extension.
582
+ """
583
+ publisherDetails: MarketplacePublisher
584
+ }
@@ -0,0 +1 @@
1
+ var publisherSchema = "\"\"\"\nA publisher represents an organization or individual who publishes extensions\n\"\"\"\ntype MarketplacePublisher implements Node @entity {\n \"\"\"\n The unique identifier of the publisher.\n \"\"\"\n id: ID! @id\n\n \"\"\"\n The unique publisher ID (UUID).\n \"\"\"\n publisherId: String! @column\n\n \"\"\"\n The unique name/slug of the publisher (e.g., 'stackflow1', 'microsoft').\n \"\"\"\n name: String! @column\n\n \"\"\"\n The display name of the publisher.\n \"\"\"\n displayName: String! @column\n\n \"\"\"\n The publisher's description.\n \"\"\"\n description: String @column\n\n \"\"\"\n The publisher's website URL.\n \"\"\"\n websiteUrl: String @column\n\n \"\"\"\n The publisher's logo/avatar URL.\n \"\"\"\n logoUrl: String @column\n\n \"\"\"\n The publisher's avatar URL (alias for logoUrl).\n \"\"\"\n avatar: String @column\n\n \"\"\"\n The publisher's email contact.\n \"\"\"\n email: String @column\n\n \"\"\"\n The tenant ID associated with this publisher.\n \"\"\"\n tenant: Tenant @column(overrideType: \"ObjectId\")\n\n \"\"\"\n Whether the publisher is verified.\n \"\"\"\n verified: Boolean! @column\n\n \"\"\"\n The date when the publisher was created.\n \"\"\"\n createdAt: DateTime! @column(overrideType: \"Date\")\n\n \"\"\"\n The date when the publisher was last updated.\n \"\"\"\n updatedAt: DateTime! @column(overrideType: \"Date\")\n\n \"\"\"\n The number of extensions published by this publisher.\n \"\"\"\n extensionCount: Int! @column\n\n \"\"\"\n The total number of downloads across all extensions.\n \"\"\"\n totalDownloads: Int! @column\n\n \"\"\"\n The extensions published by this publisher.\n \"\"\"\n extensions: [RegistryExtension!]! @column(overrideType: \"[ObjectId]\")\n\n \"\"\"\n Whether the current user can manage this publisher.\n \"\"\"\n viewerCanManage: Boolean!\n\n \"\"\"\n Real-time analytics stats (computed from time series data).\n \"\"\"\n stats: MarketplacePublisherStats\n\n \"\"\"\n Historical analytics data (computed from time series data).\n \"\"\"\n analytics(\n startDate: DateTime!\n endDate: DateTime!\n granularity: AnalyticsGranularity!\n ): [MarketplacePublisherAnalytics!]!\n\n \"\"\"\n Trend analysis (computed from time series data).\n \"\"\"\n trends(days: Int = 30): MarketplacePublisherTrend\n}\n\n\"\"\"\nPublisher statistics and metrics\n\"\"\"\ntype PublisherStats {\n \"\"\"\n Total number of extensions.\n \"\"\"\n totalExtensions: Int!\n\n \"\"\"\n Total downloads across all extensions.\n \"\"\"\n totalDownloads: Int!\n\n \"\"\"\n Total active installations.\n \"\"\"\n totalInstallations: Int!\n\n \"\"\"\n Average rating across all extensions.\n \"\"\"\n averageRating: Float!\n\n \"\"\"\n Number of verified publishers.\n \"\"\"\n verifiedCount: Int!\n\n \"\"\"\n Most popular extension.\n \"\"\"\n topExtension: RegistryExtension\n}\n\n\"\"\"\nReal-time analytics stats for a marketplace publisher (computed from time series)\n\"\"\"\ntype MarketplacePublisherStats {\n \"\"\"\n Total number of downloads.\n \"\"\"\n totalDownloads: Int!\n\n \"\"\"\n Total number of installations.\n \"\"\"\n totalInstalls: Int!\n\n \"\"\"\n Total number of views.\n \"\"\"\n totalViews: Int!\n\n \"\"\"\n Average rating.\n \"\"\"\n averageRating: Float!\n\n \"\"\"\n Total number of ratings received.\n \"\"\"\n totalRatings: Int!\n\n \"\"\"\n Number of extensions published.\n \"\"\"\n extensionCount: Int!\n\n \"\"\"\n Last updated timestamp.\n \"\"\"\n lastUpdated: DateTime!\n}\n\n\"\"\"\nHistorical analytics data point for a marketplace publisher (computed from time series)\n\"\"\"\ntype MarketplacePublisherAnalytics {\n \"\"\"\n The date/time for this data point.\n \"\"\"\n date: DateTime!\n\n \"\"\"\n Number of downloads in this period.\n \"\"\"\n downloads: Int!\n\n \"\"\"\n Number of installations in this period.\n \"\"\"\n installs: Int!\n\n \"\"\"\n Number of views in this period.\n \"\"\"\n views: Int!\n\n \"\"\"\n Number of ratings in this period.\n \"\"\"\n ratings: Int!\n\n \"\"\"\n Average rating for this period.\n \"\"\"\n averageRating: Float!\n\n \"\"\"\n Unique users who interacted with publisher content.\n \"\"\"\n uniqueUsers: Int!\n}\n\n\"\"\"\nTrend analysis for a marketplace publisher (computed from time series)\n\"\"\"\ntype MarketplacePublisherTrend {\n \"\"\"\n Download trend direction.\n \"\"\"\n downloadTrend: TrendDirection!\n\n \"\"\"\n Download trend percentage change.\n \"\"\"\n downloadChange: Float!\n\n \"\"\"\n Installation trend direction.\n \"\"\"\n installTrend: TrendDirection!\n\n \"\"\"\n Installation trend percentage change.\n \"\"\"\n installChange: Float!\n\n \"\"\"\n View trend direction.\n \"\"\"\n viewTrend: TrendDirection!\n\n \"\"\"\n View trend percentage change.\n \"\"\"\n viewChange: Float!\n\n \"\"\"\n Rating trend direction.\n \"\"\"\n ratingTrend: TrendDirection!\n\n \"\"\"\n Rating trend percentage change.\n \"\"\"\n ratingChange: Float!\n\n \"\"\"\n Overall trend score (composite metric).\n \"\"\"\n trendScore: Float!\n}\n\n\"\"\"\nAnalytics granularity options\n\"\"\"\nenum AnalyticsGranularity {\n HOUR\n DAY\n WEEK\n MONTH\n YEAR\n}\n\n\"\"\"\nTrend direction enumeration\n\"\"\"\nenum TrendDirection {\n INCREASING\n DECREASING\n STABLE\n}\n\nextend type Query {\n \"\"\"\n Get a publisher by name.\n \"\"\"\n publisher(name: String!): MarketplacePublisher\n\n \"\"\"\n Get all publishers with optional filtering.\n \"\"\"\n publishers(\n \"\"\"\n Filter by verified status.\n \"\"\"\n verified: Boolean\n\n \"\"\"\n Search query for publisher name or description.\n \"\"\"\n search: String\n\n \"\"\"\n Number of results to return (default: 20, max: 100).\n \"\"\"\n first: Int\n\n \"\"\"\n Number of results to skip.\n \"\"\"\n skip: Int\n\n \"\"\"\n Sort order.\n \"\"\"\n orderBy: PublisherOrderBy\n ): PublisherConnection!\n\n \"\"\"\n Get publisher statistics.\n \"\"\"\n publisherStats: PublisherStats!\n}\n\nextend type Mutation {\n \"\"\"\n Create a new publisher.\n \"\"\"\n createPublisherMutation(input: CreatePublisherInput!): CreatePublisherPayload!\n\n \"\"\"\n Update an existing publisher.\n \"\"\"\n updatePublisherMutation(id: ID!, input: UpdatePublisherInput!): UpdatePublisherPayload!\n\n \"\"\"\n Verify a publisher.\n \"\"\"\n verifyPublisherMutation(id: ID!): VerifyPublisherPayload!\n}\n\n\"\"\"\nInput for creating a new publisher\n\"\"\"\ninput CreatePublisherInput {\n \"\"\"\n The display name of the publisher.\n \"\"\"\n displayName: String!\n\n \"\"\"\n The unique name/slug of the publisher.\n \"\"\"\n publisherName: String!\n\n \"\"\"\n The publisher's description.\n \"\"\"\n description: String\n\n \"\"\"\n The publisher's website URL.\n \"\"\"\n website: String\n\n \"\"\"\n The publisher's email contact.\n \"\"\"\n email: String\n\n \"\"\"\n The publisher's domain for verification.\n \"\"\"\n domain: String\n\n \"\"\"\n The tenant ID associated with this publisher.\n \"\"\"\n tenant: ID\n}\n\n\"\"\"\nInput for updating a publisher\n\"\"\"\ninput UpdatePublisherInput {\n \"\"\"\n The display name of the publisher.\n \"\"\"\n displayName: String!\n\n \"\"\"\n The publisher's description.\n \"\"\"\n description: String\n\n \"\"\"\n The publisher's website URL.\n \"\"\"\n website: String\n\n \"\"\"\n The publisher's logo/avatar URL.\n \"\"\"\n avatarUrl: String\n\n \"\"\"\n The tenant ID associated with this publisher.\n \"\"\"\n tenant: ID\n}\n\n\"\"\"\nPayload for create publisher mutation\n\"\"\"\ntype CreatePublisherPayload {\n \"\"\"\n The created publisher.\n \"\"\"\n publisher: MarketplacePublisher!\n\n \"\"\"\n Success flag.\n \"\"\"\n success: Boolean!\n\n \"\"\"\n Error message if any.\n \"\"\"\n error: String\n}\n\n\"\"\"\nPayload for update publisher mutation\n\"\"\"\ntype UpdatePublisherPayload {\n \"\"\"\n The updated publisher.\n \"\"\"\n publisher: MarketplacePublisher\n\n \"\"\"\n Success flag.\n \"\"\"\n success: Boolean!\n\n \"\"\"\n Error message if any.\n \"\"\"\n error: String\n}\n\n\"\"\"\nPayload for verify publisher mutation\n\"\"\"\ntype VerifyPublisherPayload {\n \"\"\"\n The verified publisher.\n \"\"\"\n publisher: MarketplacePublisher\n\n \"\"\"\n Success flag.\n \"\"\"\n success: Boolean!\n\n \"\"\"\n Error message if any.\n \"\"\"\n error: String\n}\n\n\"\"\"\nPublisher connection for pagination\n\"\"\"\ntype PublisherConnection {\n \"\"\"\n List of publishers.\n \"\"\"\n nodes: [MarketplacePublisher!]!\n\n \"\"\"\n Total count of publishers.\n \"\"\"\n totalCount: Int!\n\n \"\"\"\n Whether there are more results.\n \"\"\"\n hasNextPage: Boolean!\n\n \"\"\"\n Whether there are previous results.\n \"\"\"\n hasPreviousPage: Boolean!\n}\n\n\"\"\"\nSort options for publishers\n\"\"\"\nenum PublisherOrderBy {\n \"\"\"\n Sort by name (A-Z).\n \"\"\"\n NAME_ASC\n\n \"\"\"\n Sort by name (Z-A).\n \"\"\"\n NAME_DESC\n\n \"\"\"\n Sort by creation date (newest first).\n \"\"\"\n CREATED_DESC\n\n \"\"\"\n Sort by creation date (oldest first).\n \"\"\"\n CREATED_ASC\n\n \"\"\"\n Sort by extension count (most first).\n \"\"\"\n EXTENSIONS_DESC\n\n \"\"\"\n Sort by extension count (least first).\n \"\"\"\n EXTENSIONS_ASC\n\n \"\"\"\n Sort by total downloads (most first).\n \"\"\"\n DOWNLOADS_DESC\n\n \"\"\"\n Sort by total downloads (least first).\n \"\"\"\n DOWNLOADS_ASC\n}\n\n\"\"\"\nExtension manifest author information\n\"\"\"\ntype ExtensionManifestAuthor @entity(embedded: true) {\n \"\"\"\n The author's name.\n \"\"\"\n name: String! @column\n\n \"\"\"\n The author's email.\n \"\"\"\n email: String @column\n\n \"\"\"\n The author's website URL.\n \"\"\"\n url: String @column\n\n \"\"\"\n Whether the author is verified.\n \"\"\"\n verified: Boolean @column\n}\n\nextend type ExtensionManifest {\n \"\"\"\n The publisher who published this extension.\n \"\"\"\n publisherDetails: MarketplacePublisher\n}\n";export{publisherSchema as default};//# sourceMappingURL=publisher.graphql.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"publisher.graphql.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -3,6 +3,14 @@ extend enum MoleculerServiceName {
3
3
  ExtensionService
4
4
  }
5
5
 
6
+ extend enum SlotFillPluginName {
7
+ extension_publish_page_slot_fill
8
+ }
9
+
10
+ extend enum SlotFillEnum {
11
+ ExtensionPublishPageSlotFill
12
+ }
13
+
6
14
  enum ExtensionServiceAction {
7
15
  OnExtensionInstalled
8
16
  OnExtensionUninstalled
@@ -69,6 +77,13 @@ type ExtensionDisabledEvent {
69
77
  reason: String! # 'user', 'admin', 'policy', 'system'
70
78
  }
71
79
 
80
+ extend enum SlotFillPluginName {
81
+ extension_publish_page_slot_fill
82
+ }
83
+
84
+ extend enum SlotFillEnum {
85
+ ExtensionPublishPageSlotFill
86
+ }
72
87
  """
73
88
  Event fired when an extension is updated
74
89
  """
package/lib/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { Feature } from '@common-stack/server-core';
2
- declare const _default: Feature<import("@common-stack/server-core").ConfigurationScope, any>;
2
+ declare const _default: Feature<any, any>;
3
3
  export default _default;
4
4
  export * from './services';
5
5
  export * from './store';
package/lib/index.js CHANGED
@@ -1 +1 @@
1
- import {Feature}from'@common-stack/server-core';import module from'./module.js';export{RegistryExtensionService}from'./services/extension-service.js';export{InstalledExtensionService}from'./services/installed-extension-service.js';export{InstalledExtensionServiceExt}from'./services/installed-extension-service-ext.js';export{RegistryExtensionModelFunc}from'./store/models/registry-extension-model.js';export{InstalledExtensionModelFunc}from'./store/models/installed-extension-model.js';export{RegistryExtensionRepository}from'./store/repositories/registry-extension-repository.js';export{InstalledExtensionRepository}from'./store/repositories/installed-extension-repository.js';var index = new Feature(module);export{index as default};//# sourceMappingURL=index.js.map
1
+ import {Feature}from'@common-stack/server-core';import module$1 from'./module.js';export{InstalledExtensionService}from'./services/installed-extension-service.js';export{InstalledExtensionServiceExt}from'./services/installed-extension-service-ext.js';export{MarketplacePublisherService}from'./services/publisher-service.js';export{PublisherEventService}from'./services/publisher-event-service.js';export{ExtensionGalleryService}from'./services/extension-gallery-service.js';export{ExtensionGalleryRepository}from'./services/extension-gallery-repository.js';export{InstalledExtensionModelFunc}from'./store/models/installed-extension-model.js';export{PublisherModelFunc,PublisherSchema}from'./store/models/publisher-model.js';export{InstalledExtensionRepository}from'./store/repositories/installed-extension-repository.js';export{MarketplacePublisherRepository}from'./store/repositories/publisher-repository.js';var index = new Feature(module$1);export{index as default};//# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":[null],"names":[],"mappings":"uqBAGA,YAAmC,IAAA,OAAA,CAAA,MAAA,CAAA"}
1
+ {"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":[null],"names":["module"],"mappings":"84BAGA,YAAA,IAAA,OAAmC,CAAAA,QAAA,CAAA"}
@@ -0,0 +1,20 @@
1
+ import { IDatabaseMigration } from '@adminide-stack/core';
2
+ import type { Connection } from 'mongoose';
3
+ import { CdmLogger } from '@cdm-logger/core';
4
+ /**
5
+ * Migration to drop the old publisherName_1 index from MarketplacePublisher collection.
6
+ *
7
+ * Ensures:
8
+ * - No duplicate index issues
9
+ * - Safe to run multiple times
10
+ * - Works across all tenant databases
11
+ */
12
+ export declare class DropOldPublisherNameIndexMigration implements IDatabaseMigration {
13
+ private readonly db;
14
+ id: string;
15
+ private readonly logger;
16
+ constructor(db: Connection, logger: CdmLogger.ILogger);
17
+ up(): Promise<void>;
18
+ down(): Promise<void>;
19
+ }
20
+ //# sourceMappingURL=DropOldPublisherIndexMigration.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DropOldPublisherIndexMigration.d.ts","sourceRoot":"","sources":["../../../src/migrations/dbMigrations/DropOldPublisherIndexMigration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAG7C;;;;;;;GAOG;AACH,qBACa,kCAAmC,YAAW,kBAAkB;IAQrE,OAAO,CAAC,QAAQ,CAAC,EAAE;IANvB,EAAE,SAAyD;IAE3D,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAoB;gBAItB,EAAE,EAAE,UAAU,EAE/B,MAAM,EAAE,SAAS,CAAC,OAAO;IAKhB,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IA4BnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAyBrC"}