@djangocfg/api 1.2.36 → 1.2.37

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 (33) hide show
  1. package/dist/index.cjs +1766 -1726
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.d.cts +223 -118
  4. package/dist/index.d.ts +223 -118
  5. package/dist/index.mjs +1766 -1726
  6. package/dist/index.mjs.map +1 -1
  7. package/package.json +2 -2
  8. package/src/cfg/generated/_utils/fetchers/cfg__centrifugo__centrifugo_monitoring.ts +3 -3
  9. package/src/cfg/generated/_utils/fetchers/cfg__health.ts +3 -3
  10. package/src/cfg/generated/_utils/fetchers/cfg__rq__rq_monitoring.ts +3 -3
  11. package/src/cfg/generated/_utils/hooks/cfg__centrifugo__centrifugo_monitoring.ts +3 -3
  12. package/src/cfg/generated/_utils/hooks/cfg__health.ts +3 -3
  13. package/src/cfg/generated/_utils/hooks/cfg__rq__rq_monitoring.ts +3 -3
  14. package/src/cfg/generated/_utils/schemas/ArchiveItemChunk.schema.ts +1 -1
  15. package/src/cfg/generated/_utils/schemas/ArchiveItemChunkDetail.schema.ts +1 -1
  16. package/src/cfg/generated/_utils/schemas/{HealthCheck.schema.ts → CentrifugoHealthCheck.schema.ts} +3 -3
  17. package/src/cfg/generated/_utils/schemas/DRFHealthCheck.schema.ts +25 -0
  18. package/src/cfg/generated/_utils/schemas/DocumentArchiveDetail.schema.ts +1 -1
  19. package/src/cfg/generated/_utils/schemas/{MethodStats.schema.ts → GRPCMethodStats.schema.ts} +3 -3
  20. package/src/cfg/generated/_utils/schemas/GRPCServiceRegistryMethodStats.schema.ts +26 -0
  21. package/src/cfg/generated/_utils/schemas/MethodList.schema.ts +2 -2
  22. package/src/cfg/generated/_utils/schemas/MethodSummary.schema.ts +2 -2
  23. package/src/cfg/generated/_utils/schemas/RQHealthCheck.schema.ts +31 -0
  24. package/src/cfg/generated/_utils/schemas/index.ts +5 -2
  25. package/src/cfg/generated/cfg__centrifugo__centrifugo_monitoring/client.ts +1 -1
  26. package/src/cfg/generated/cfg__centrifugo__centrifugo_monitoring/models.ts +1 -1
  27. package/src/cfg/generated/cfg__grpc__grpc_monitoring/models.ts +2 -2
  28. package/src/cfg/generated/cfg__grpc__grpc_services/models.ts +17 -15
  29. package/src/cfg/generated/cfg__health/client.ts +1 -1
  30. package/src/cfg/generated/cfg__health/models.ts +14 -8
  31. package/src/cfg/generated/cfg__rq__rq_monitoring/client.ts +1 -1
  32. package/src/cfg/generated/cfg__rq__rq_monitoring/models.ts +18 -8
  33. package/src/cfg/generated/schema.json +401 -126
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@djangocfg/api",
3
- "version": "1.2.36",
3
+ "version": "1.2.37",
4
4
  "author": {
5
5
  "name": "DjangoCFG",
6
6
  "url": "https://djangocfg.com"
@@ -68,7 +68,7 @@
68
68
  "@types/node": "^22.15.3",
69
69
  "@types/react": "19.2.2",
70
70
  "@types/react-dom": "19.2.1",
71
- "@djangocfg/typescript-config": "^1.2.36",
71
+ "@djangocfg/typescript-config": "^1.2.37",
72
72
  "react": "^19.1.0",
73
73
  "react-dom": "^19.1.0",
74
74
  "tsup": "^8.5.0",
@@ -30,9 +30,9 @@
30
30
  * ```
31
31
  */
32
32
  import { consola } from 'consola'
33
+ import { CentrifugoHealthCheckSchema, type CentrifugoHealthCheck } from '../schemas/CentrifugoHealthCheck.schema'
33
34
  import { CentrifugoOverviewStatsSchema, type CentrifugoOverviewStats } from '../schemas/CentrifugoOverviewStats.schema'
34
35
  import { ChannelListSchema, type ChannelList } from '../schemas/ChannelList.schema'
35
- import { HealthCheckSchema, type HealthCheck } from '../schemas/HealthCheck.schema'
36
36
  import { PaginatedPublishListSchema, type PaginatedPublishList } from '../schemas/PaginatedPublishList.schema'
37
37
  import { TimelineResponseSchema, type TimelineResponse } from '../schemas/TimelineResponse.schema'
38
38
  import { getAPIInstance } from '../../api-instance'
@@ -108,11 +108,11 @@ export async function getCentrifugoMonitorChannelsRetrieve( params?: { hours?:
108
108
  * @path /cfg/centrifugo/monitor/health/
109
109
  */
110
110
  export async function getCentrifugoMonitorHealthRetrieve( client?: any
111
- ): Promise<HealthCheck> {
111
+ ): Promise<CentrifugoHealthCheck> {
112
112
  const api = client || getAPIInstance()
113
113
  const response = await api.cfg_centrifugo_monitoring.centrifugoMonitorHealthRetrieve()
114
114
  try {
115
- return HealthCheckSchema.parse(response)
115
+ return CentrifugoHealthCheckSchema.parse(response)
116
116
  } catch (error) {
117
117
  // Zod validation error - log detailed information
118
118
  consola.error('❌ Zod Validation Failed');
@@ -30,7 +30,7 @@
30
30
  * ```
31
31
  */
32
32
  import { consola } from 'consola'
33
- import { HealthCheckSchema, type HealthCheck } from '../schemas/HealthCheck.schema'
33
+ import { DRFHealthCheckSchema, type DRFHealthCheck } from '../schemas/DRFHealthCheck.schema'
34
34
  import { QuickHealthSchema, type QuickHealth } from '../schemas/QuickHealth.schema'
35
35
  import { getAPIInstance } from '../../api-instance'
36
36
 
@@ -41,11 +41,11 @@ import { getAPIInstance } from '../../api-instance'
41
41
  * @path /cfg/health/drf/
42
42
  */
43
43
  export async function getHealthDrfRetrieve( client?: any
44
- ): Promise<HealthCheck> {
44
+ ): Promise<DRFHealthCheck> {
45
45
  const api = client || getAPIInstance()
46
46
  const response = await api.cfg_health.drfRetrieve()
47
47
  try {
48
- return HealthCheckSchema.parse(response)
48
+ return DRFHealthCheckSchema.parse(response)
49
49
  } catch (error) {
50
50
  // Zod validation error - log detailed information
51
51
  consola.error('❌ Zod Validation Failed');
@@ -30,8 +30,8 @@
30
30
  * ```
31
31
  */
32
32
  import { consola } from 'consola'
33
- import { HealthCheckSchema, type HealthCheck } from '../schemas/HealthCheck.schema'
34
33
  import { RQConfigSchema, type RQConfig } from '../schemas/RQConfig.schema'
34
+ import { RQHealthCheckSchema, type RQHealthCheck } from '../schemas/RQHealthCheck.schema'
35
35
  import { getAPIInstance } from '../../api-instance'
36
36
 
37
37
  /**
@@ -105,11 +105,11 @@ export async function getRqMonitorConfigRetrieve( client?: any
105
105
  * @path /cfg/rq/monitor/health/
106
106
  */
107
107
  export async function getRqMonitorHealthRetrieve( client?: any
108
- ): Promise<HealthCheck> {
108
+ ): Promise<RQHealthCheck> {
109
109
  const api = client || getAPIInstance()
110
110
  const response = await api.cfg_rq_monitoring.rqMonitorHealthRetrieve()
111
111
  try {
112
- return HealthCheckSchema.parse(response)
112
+ return RQHealthCheckSchema.parse(response)
113
113
  } catch (error) {
114
114
  // Zod validation error - log detailed information
115
115
  consola.error('❌ Zod Validation Failed');
@@ -17,9 +17,9 @@
17
17
  import useSWR from 'swr'
18
18
  import * as Fetchers from '../fetchers/cfg__centrifugo__centrifugo_monitoring'
19
19
  import type { API } from '../../index'
20
+ import type { CentrifugoHealthCheck } from '../schemas/CentrifugoHealthCheck.schema'
20
21
  import type { CentrifugoOverviewStats } from '../schemas/CentrifugoOverviewStats.schema'
21
22
  import type { ChannelList } from '../schemas/ChannelList.schema'
22
- import type { HealthCheck } from '../schemas/HealthCheck.schema'
23
23
  import type { PaginatedPublishList } from '../schemas/PaginatedPublishList.schema'
24
24
  import type { TimelineResponse } from '../schemas/TimelineResponse.schema'
25
25
 
@@ -43,8 +43,8 @@ export function useCentrifugoMonitorChannelsRetrieve(params?: { hours?: number }
43
43
  * @method GET
44
44
  * @path /cfg/centrifugo/monitor/health/
45
45
  */
46
- export function useCentrifugoMonitorHealthRetrieve(client?: API): ReturnType<typeof useSWR<HealthCheck>> {
47
- return useSWR<HealthCheck>(
46
+ export function useCentrifugoMonitorHealthRetrieve(client?: API): ReturnType<typeof useSWR<CentrifugoHealthCheck>> {
47
+ return useSWR<CentrifugoHealthCheck>(
48
48
  'cfg-centrifugo-monitor-health',
49
49
  () => Fetchers.getCentrifugoMonitorHealthRetrieve(client)
50
50
  )
@@ -17,7 +17,7 @@
17
17
  import useSWR from 'swr'
18
18
  import * as Fetchers from '../fetchers/cfg__health'
19
19
  import type { API } from '../../index'
20
- import type { HealthCheck } from '../schemas/HealthCheck.schema'
20
+ import type { DRFHealthCheck } from '../schemas/DRFHealthCheck.schema'
21
21
  import type { QuickHealth } from '../schemas/QuickHealth.schema'
22
22
 
23
23
  /**
@@ -26,8 +26,8 @@ import type { QuickHealth } from '../schemas/QuickHealth.schema'
26
26
  * @method GET
27
27
  * @path /cfg/health/drf/
28
28
  */
29
- export function useHealthDrfRetrieve(client?: API): ReturnType<typeof useSWR<HealthCheck>> {
30
- return useSWR<HealthCheck>(
29
+ export function useHealthDrfRetrieve(client?: API): ReturnType<typeof useSWR<DRFHealthCheck>> {
30
+ return useSWR<DRFHealthCheck>(
31
31
  'cfg-health-drf',
32
32
  () => Fetchers.getHealthDrfRetrieve(client)
33
33
  )
@@ -17,8 +17,8 @@
17
17
  import useSWR from 'swr'
18
18
  import * as Fetchers from '../fetchers/cfg__rq__rq_monitoring'
19
19
  import type { API } from '../../index'
20
- import type { HealthCheck } from '../schemas/HealthCheck.schema'
21
20
  import type { RQConfig } from '../schemas/RQConfig.schema'
21
+ import type { RQHealthCheck } from '../schemas/RQHealthCheck.schema'
22
22
 
23
23
  /**
24
24
  * Get RQ configuration
@@ -40,8 +40,8 @@ export function useRqMonitorConfigRetrieve(client?: API): ReturnType<typeof useS
40
40
  * @method GET
41
41
  * @path /cfg/rq/monitor/health/
42
42
  */
43
- export function useRqMonitorHealthRetrieve(client?: API): ReturnType<typeof useSWR<HealthCheck>> {
44
- return useSWR<HealthCheck>(
43
+ export function useRqMonitorHealthRetrieve(client?: API): ReturnType<typeof useSWR<RQHealthCheck>> {
44
+ return useSWR<RQHealthCheck>(
45
45
  'cfg-rq-monitor-health',
46
46
  () => Fetchers.getRqMonitorHealthRetrieve(client)
47
47
  )
@@ -19,7 +19,7 @@ export const ArchiveItemChunkSchema = z.object({
19
19
  character_count: z.int(),
20
20
  embedding_model: z.string(),
21
21
  embedding_cost: z.number(),
22
- context_summary: z.record(z.string(), z.record(z.string(), z.any())),
22
+ context_summary: z.object({}),
23
23
  created_at: z.iso.datetime(),
24
24
  })
25
25
 
@@ -19,7 +19,7 @@ export const ArchiveItemChunkDetailSchema = z.object({
19
19
  character_count: z.int(),
20
20
  embedding_model: z.string(),
21
21
  embedding_cost: z.number(),
22
- context_summary: z.record(z.string(), z.record(z.string(), z.any())),
22
+ context_summary: z.object({}),
23
23
  created_at: z.iso.datetime(),
24
24
  context_metadata: z.record(z.string(), z.any()),
25
25
  })
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Zod schema for HealthCheck
2
+ * Zod schema for CentrifugoHealthCheck
3
3
  *
4
4
  * This schema provides runtime validation and type inference.
5
5
  * * Health check response.
@@ -9,7 +9,7 @@ import { z } from 'zod'
9
9
  /**
10
10
  * Health check response.
11
11
  */
12
- export const HealthCheckSchema = z.object({
12
+ export const CentrifugoHealthCheckSchema = z.object({
13
13
  status: z.string(),
14
14
  wrapper_url: z.string(),
15
15
  has_api_key: z.boolean(),
@@ -19,4 +19,4 @@ export const HealthCheckSchema = z.object({
19
19
  /**
20
20
  * Infer TypeScript type from Zod schema
21
21
  */
22
- export type HealthCheck = z.infer<typeof HealthCheckSchema>
22
+ export type CentrifugoHealthCheck = z.infer<typeof CentrifugoHealthCheckSchema>
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Zod schema for DRFHealthCheck
3
+ *
4
+ * This schema provides runtime validation and type inference.
5
+ * * Serializer for health check response.
6
+ * */
7
+ import { z } from 'zod'
8
+
9
+ /**
10
+ * Serializer for health check response.
11
+ */
12
+ export const DRFHealthCheckSchema = z.object({
13
+ status: z.string(),
14
+ timestamp: z.iso.datetime(),
15
+ service: z.string(),
16
+ version: z.string(),
17
+ checks: z.record(z.string(), z.record(z.string(), z.any())),
18
+ environment: z.record(z.string(), z.record(z.string(), z.any())),
19
+ links: z.record(z.string(), z.record(z.string(), z.any())).optional(),
20
+ })
21
+
22
+ /**
23
+ * Infer TypeScript type from Zod schema
24
+ */
25
+ export type DRFHealthCheck = z.infer<typeof DRFHealthCheckSchema>
@@ -38,7 +38,7 @@ export const DocumentArchiveDetailSchema = z.object({
38
38
  created_at: z.iso.datetime(),
39
39
  updated_at: z.iso.datetime(),
40
40
  items: z.array(ArchiveItemSchema),
41
- file_tree: z.record(z.string(), z.record(z.string(), z.any())),
41
+ file_tree: z.record(z.string(), z.any()),
42
42
  metadata: z.record(z.string(), z.any()).nullable().optional(),
43
43
  })
44
44
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Zod schema for MethodStats
2
+ * Zod schema for GRPCMethodStats
3
3
  *
4
4
  * This schema provides runtime validation and type inference.
5
5
  * * Statistics for a single gRPC method.
@@ -9,7 +9,7 @@ import { z } from 'zod'
9
9
  /**
10
10
  * Statistics for a single gRPC method.
11
11
  */
12
- export const MethodStatsSchema = z.object({
12
+ export const GRPCMethodStatsSchema = z.object({
13
13
  method_name: z.string(),
14
14
  service_name: z.string(),
15
15
  total: z.int(),
@@ -22,4 +22,4 @@ export const MethodStatsSchema = z.object({
22
22
  /**
23
23
  * Infer TypeScript type from Zod schema
24
24
  */
25
- export type MethodStats = z.infer<typeof MethodStatsSchema>
25
+ export type GRPCMethodStats = z.infer<typeof GRPCMethodStatsSchema>
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Zod schema for GRPCServiceRegistryMethodStats
3
+ *
4
+ * This schema provides runtime validation and type inference.
5
+ * * Statistics for a single method.
6
+ * */
7
+ import { z } from 'zod'
8
+
9
+ /**
10
+ * Statistics for a single method.
11
+ */
12
+ export const GRPCServiceRegistryMethodStatsSchema = z.object({
13
+ total_requests: z.int().optional(),
14
+ successful: z.int().optional(),
15
+ errors: z.int().optional(),
16
+ success_rate: z.number().optional(),
17
+ avg_duration_ms: z.number().optional(),
18
+ p50_duration_ms: z.number().optional(),
19
+ p95_duration_ms: z.number().optional(),
20
+ p99_duration_ms: z.number().optional(),
21
+ })
22
+
23
+ /**
24
+ * Infer TypeScript type from Zod schema
25
+ */
26
+ export type GRPCServiceRegistryMethodStats = z.infer<typeof GRPCServiceRegistryMethodStatsSchema>
@@ -5,13 +5,13 @@
5
5
  * * List of gRPC methods with statistics.
6
6
  * */
7
7
  import { z } from 'zod'
8
- import { MethodStatsSchema } from './MethodStats.schema'
8
+ import { GRPCMethodStatsSchema } from './GRPCMethodStats.schema'
9
9
 
10
10
  /**
11
11
  * List of gRPC methods with statistics.
12
12
  */
13
13
  export const MethodListSchema = z.object({
14
- methods: z.array(MethodStatsSchema),
14
+ methods: z.array(GRPCMethodStatsSchema),
15
15
  total_methods: z.int(),
16
16
  })
17
17
 
@@ -5,7 +5,7 @@
5
5
  * * Summary information for a method.
6
6
  * */
7
7
  import { z } from 'zod'
8
- import { MethodStatsSchema } from './MethodStats.schema'
8
+ import { GRPCServiceRegistryMethodStatsSchema } from './GRPCServiceRegistryMethodStats.schema'
9
9
 
10
10
  /**
11
11
  * Summary information for a method.
@@ -16,7 +16,7 @@ export const MethodSummarySchema = z.object({
16
16
  service_name: z.string(),
17
17
  request_type: z.string().optional(),
18
18
  response_type: z.string().optional(),
19
- stats: MethodStatsSchema,
19
+ stats: GRPCServiceRegistryMethodStatsSchema,
20
20
  })
21
21
 
22
22
  /**
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Zod schema for RQHealthCheck
3
+ *
4
+ * This schema provides runtime validation and type inference.
5
+ * * Health check response serializer.
6
+
7
+ Provides overall RQ cluster health status.
8
+ * */
9
+ import { z } from 'zod'
10
+
11
+ /**
12
+ * Health check response serializer.
13
+
14
+ Provides overall RQ cluster health status.
15
+ */
16
+ export const RQHealthCheckSchema = z.object({
17
+ status: z.string(),
18
+ worker_count: z.int(),
19
+ queue_count: z.int(),
20
+ total_jobs: z.int(),
21
+ timestamp: z.iso.datetime(),
22
+ enabled: z.boolean(),
23
+ redis_connected: z.boolean(),
24
+ wrapper_url: z.string().optional(),
25
+ has_api_key: z.boolean().optional(),
26
+ })
27
+
28
+ /**
29
+ * Infer TypeScript type from Zod schema
30
+ */
31
+ export type RQHealthCheck = z.infer<typeof RQHealthCheckSchema>
@@ -45,6 +45,7 @@ export * from './CentrifugoChannelsResult.schema'
45
45
  export * from './CentrifugoClientInfo.schema'
46
46
  export * from './CentrifugoConfig.schema'
47
47
  export * from './CentrifugoError.schema'
48
+ export * from './CentrifugoHealthCheck.schema'
48
49
  export * from './CentrifugoHistoryRequestRequest.schema'
49
50
  export * from './CentrifugoHistoryResponse.schema'
50
51
  export * from './CentrifugoHistoryResult.schema'
@@ -90,6 +91,7 @@ export * from './ConnectionTokenResponse.schema'
90
91
  export * from './ConstanceConfig.schema'
91
92
  export * from './Currency.schema'
92
93
  export * from './DRFConfig.schema'
94
+ export * from './DRFHealthCheck.schema'
93
95
  export * from './DashboardCharts.schema'
94
96
  export * from './DashboardOverview.schema'
95
97
  export * from './DatabaseConfig.schema'
@@ -123,15 +125,16 @@ export * from './GRPCFeatures.schema'
123
125
  export * from './GRPCFrameworkConfig.schema'
124
126
  export * from './GRPCHealthCheck.schema'
125
127
  export * from './GRPCInterceptorInfo.schema'
128
+ export * from './GRPCMethodStats.schema'
126
129
  export * from './GRPCOverviewStats.schema'
127
130
  export * from './GRPCRegisteredService.schema'
128
131
  export * from './GRPCServerConfig.schema'
129
132
  export * from './GRPCServerInfo.schema'
130
133
  export * from './GRPCServerStatus.schema'
131
134
  export * from './GRPCServiceInfo.schema'
135
+ export * from './GRPCServiceRegistryMethodStats.schema'
132
136
  export * from './GRPCStats.schema'
133
137
  export * from './GRPCTestLog.schema'
134
- export * from './HealthCheck.schema'
135
138
  export * from './JWTConfig.schema'
136
139
  export * from './JobActionResponse.schema'
137
140
  export * from './JobDetail.schema'
@@ -149,7 +152,6 @@ export * from './MessageCreateRequest.schema'
149
152
  export * from './MessageRequest.schema'
150
153
  export * from './MethodInfo.schema'
151
154
  export * from './MethodList.schema'
152
- export * from './MethodStats.schema'
153
155
  export * from './MethodSummary.schema'
154
156
  export * from './ModelStatistics.schema'
155
157
  export * from './Newsletter.schema'
@@ -220,6 +222,7 @@ export * from './QueueStats.schema'
220
222
  export * from './QuickAction.schema'
221
223
  export * from './QuickHealth.schema'
222
224
  export * from './RQConfig.schema'
225
+ export * from './RQHealthCheck.schema'
223
226
  export * from './RQSchedule.schema'
224
227
  export * from './RecentError.schema'
225
228
  export * from './RecentRequest.schema'
@@ -37,7 +37,7 @@ export class CfgCentrifugoMonitoring {
37
37
  *
38
38
  * Returns the current health status of the Centrifugo client.
39
39
  */
40
- async centrifugoMonitorHealthRetrieve(): Promise<Models.HealthCheck> {
40
+ async centrifugoMonitorHealthRetrieve(): Promise<Models.CentrifugoHealthCheck> {
41
41
  const response = await this.client.request('GET', "/cfg/centrifugo/monitor/health/");
42
42
  return response;
43
43
  }
@@ -15,7 +15,7 @@ export interface ChannelList {
15
15
  *
16
16
  * Response model (includes read-only fields).
17
17
  */
18
- export interface HealthCheck {
18
+ export interface CentrifugoHealthCheck {
19
19
  /** Health status: healthy or unhealthy */
20
20
  status: string;
21
21
  /** Configured wrapper URL */
@@ -23,7 +23,7 @@ export interface GRPCHealthCheck {
23
23
  */
24
24
  export interface MethodList {
25
25
  /** Method statistics */
26
- methods: Array<MethodStats>;
26
+ methods: Array<GRPCMethodStats>;
27
27
  /** Total number of methods */
28
28
  total_methods: number;
29
29
  }
@@ -85,7 +85,7 @@ export interface PaginatedRecentRequestList {
85
85
  *
86
86
  * Response model (includes read-only fields).
87
87
  */
88
- export interface MethodStats {
88
+ export interface GRPCMethodStats {
89
89
  /** Method name */
90
90
  method_name: string;
91
91
  /** Service name */
@@ -160,28 +160,30 @@ export interface MethodSummary {
160
160
  request_type?: string;
161
161
  /** Response message type */
162
162
  response_type?: string;
163
- stats: MethodStats;
163
+ stats: GRPCServiceRegistryMethodStats;
164
164
  }
165
165
 
166
166
  /**
167
- * Statistics for a single gRPC method.
167
+ * Statistics for a single method.
168
168
  *
169
169
  * Response model (includes read-only fields).
170
170
  */
171
- export interface MethodStats {
172
- /** Method name */
173
- method_name: string;
174
- /** Service name */
175
- service_name: string;
171
+ export interface GRPCServiceRegistryMethodStats {
176
172
  /** Total requests */
177
- total: number;
173
+ total_requests?: number;
178
174
  /** Successful requests */
179
- successful: number;
180
- /** Error requests */
181
- errors: number;
182
- /** Average duration */
183
- avg_duration_ms: number;
184
- /** Last activity timestamp */
185
- last_activity_at: string | null;
175
+ successful?: number;
176
+ /** Failed requests */
177
+ errors?: number;
178
+ /** Success rate percentage */
179
+ success_rate?: number;
180
+ /** Average duration in milliseconds */
181
+ avg_duration_ms?: number;
182
+ /** P50 duration in milliseconds */
183
+ p50_duration_ms?: number;
184
+ /** P95 duration in milliseconds */
185
+ p95_duration_ms?: number;
186
+ /** P99 duration in milliseconds */
187
+ p99_duration_ms?: number;
186
188
  }
187
189
 
@@ -14,7 +14,7 @@ export class CfgHealth {
14
14
  /**
15
15
  * Return comprehensive health check data.
16
16
  */
17
- async drfRetrieve(): Promise<Models.HealthCheck> {
17
+ async drfRetrieve(): Promise<Models.DRFHealthCheck> {
18
18
  const response = await this.client.request('GET', "/cfg/health/drf/");
19
19
  return response;
20
20
  }
@@ -1,17 +1,23 @@
1
1
  /**
2
- * Health check response.
2
+ * Serializer for health check response.
3
3
  *
4
4
  * Response model (includes read-only fields).
5
5
  */
6
- export interface HealthCheck {
7
- /** Health status: healthy or unhealthy */
6
+ export interface DRFHealthCheck {
7
+ /** Overall health status: healthy, degraded, or unhealthy */
8
8
  status: string;
9
- /** Configured wrapper URL */
10
- wrapper_url: string;
11
- /** Whether API key is configured */
12
- has_api_key: boolean;
13
- /** Current timestamp */
9
+ /** Timestamp of the health check */
14
10
  timestamp: string;
11
+ /** Service name */
12
+ service: string;
13
+ /** Django-CFG version */
14
+ version: string;
15
+ /** Detailed health checks for databases, cache, and system */
16
+ checks: Record<string, any>;
17
+ /** Environment information */
18
+ environment: Record<string, any>;
19
+ /** Useful API endpoint links */
20
+ links?: Record<string, any>;
15
21
  }
16
22
 
17
23
  /**
@@ -27,7 +27,7 @@ export class CfgRqMonitoring {
27
27
  * Returns RQ cluster health status including worker count and queue
28
28
  * status.
29
29
  */
30
- async rqMonitorHealthRetrieve(): Promise<Models.HealthCheck> {
30
+ async rqMonitorHealthRetrieve(): Promise<Models.RQHealthCheck> {
31
31
  const response = await this.client.request('GET', "/cfg/rq/monitor/health/");
32
32
  return response;
33
33
  }
@@ -22,19 +22,29 @@ export interface RQConfig {
22
22
  }
23
23
 
24
24
  /**
25
- * Health check response.
25
+ * Health check response serializer. Provides overall RQ cluster health status.
26
26
  *
27
27
  * Response model (includes read-only fields).
28
28
  */
29
- export interface HealthCheck {
30
- /** Health status: healthy or unhealthy */
29
+ export interface RQHealthCheck {
30
+ /** Health status (healthy/degraded/unhealthy) */
31
31
  status: string;
32
- /** Configured wrapper URL */
33
- wrapper_url: string;
34
- /** Whether API key is configured */
35
- has_api_key: boolean;
36
- /** Current timestamp */
32
+ /** Total number of active workers */
33
+ worker_count: number;
34
+ /** Number of configured queues */
35
+ queue_count: number;
36
+ /** Total jobs across all queues */
37
+ total_jobs: number;
38
+ /** Health check timestamp */
37
39
  timestamp: string;
40
+ /** RQ enabled status */
41
+ enabled: boolean;
42
+ /** Redis connection status */
43
+ redis_connected: boolean;
44
+ /** Wrapper URL (optional) */
45
+ wrapper_url?: string;
46
+ /** API key configured status */
47
+ has_api_key?: boolean;
38
48
  }
39
49
 
40
50
  /**