@djangocfg/api 1.2.23 → 1.2.24

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 (93) hide show
  1. package/dist/index.cjs +4025 -3009
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.d.cts +3089 -1662
  4. package/dist/index.d.ts +3089 -1662
  5. package/dist/index.mjs +4009 -3002
  6. package/dist/index.mjs.map +1 -1
  7. package/package.json +2 -2
  8. package/src/cfg/generated/_utils/fetchers/cfg__centrifugo.ts +3 -2
  9. package/src/cfg/generated/_utils/fetchers/cfg__centrifugo__centrifugo_monitoring.ts +5 -5
  10. package/src/cfg/generated/_utils/fetchers/cfg__grpc__grpc_api_keys.ts +78 -0
  11. package/src/cfg/generated/_utils/fetchers/cfg__grpc__grpc_proto_files.ts +91 -0
  12. package/src/cfg/generated/_utils/fetchers/cfg__rq__rq_jobs.ts +10 -8
  13. package/src/cfg/generated/_utils/fetchers/cfg__rq__rq_registries.ts +24 -22
  14. package/src/cfg/generated/_utils/fetchers/cfg__rq__rq_schedules.ts +5 -4
  15. package/src/cfg/generated/_utils/fetchers/index.ts +2 -0
  16. package/src/cfg/generated/_utils/hooks/cfg__centrifugo.ts +3 -2
  17. package/src/cfg/generated/_utils/hooks/cfg__centrifugo__centrifugo_monitoring.ts +5 -5
  18. package/src/cfg/generated/_utils/hooks/cfg__grpc__grpc_api_keys.ts +66 -0
  19. package/src/cfg/generated/_utils/hooks/cfg__grpc__grpc_proto_files.ts +83 -0
  20. package/src/cfg/generated/_utils/hooks/cfg__rq__rq_jobs.ts +8 -6
  21. package/src/cfg/generated/_utils/hooks/cfg__rq__rq_registries.ts +16 -14
  22. package/src/cfg/generated/_utils/hooks/cfg__rq__rq_schedules.ts +3 -2
  23. package/src/cfg/generated/_utils/hooks/index.ts +2 -0
  24. package/src/cfg/generated/_utils/schemas/ApiKey.schema.ts +32 -0
  25. package/src/cfg/generated/_utils/schemas/ApiKeyStats.schema.ts +23 -0
  26. package/src/cfg/generated/_utils/schemas/Command.schema.ts +13 -0
  27. package/src/cfg/generated/_utils/schemas/DashboardCharts.schema.ts +10 -10
  28. package/src/cfg/generated/_utils/schemas/GRPCCallRequestRequest.schema.ts +2 -2
  29. package/src/cfg/generated/_utils/schemas/GRPCConfig.schema.ts +6 -6
  30. package/src/cfg/generated/_utils/schemas/{GRPCExampleSerializer.schema.ts → GRPCExample.schema.ts} +3 -3
  31. package/src/cfg/generated/_utils/schemas/GRPCExamplesList.schema.ts +2 -2
  32. package/src/cfg/generated/_utils/schemas/{GRPCFeaturesSerializer.schema.ts → GRPCFeatures.schema.ts} +4 -4
  33. package/src/cfg/generated/_utils/schemas/{GRPCFrameworkConfigSerializer.schema.ts → GRPCFrameworkConfig.schema.ts} +3 -3
  34. package/src/cfg/generated/_utils/schemas/{GRPCInterceptorInfoSerializer.schema.ts → GRPCInterceptorInfo.schema.ts} +3 -3
  35. package/src/cfg/generated/_utils/schemas/GRPCOverviewStats.schema.ts +1 -1
  36. package/src/cfg/generated/_utils/schemas/{GRPCServerConfigSerializer.schema.ts → GRPCServerConfig.schema.ts} +3 -3
  37. package/src/cfg/generated/_utils/schemas/GRPCServerInfo.schema.ts +6 -6
  38. package/src/cfg/generated/_utils/schemas/{GRPCServiceInfoSerializer.schema.ts → GRPCServiceInfo.schema.ts} +3 -3
  39. package/src/cfg/generated/_utils/schemas/{GRPCStatsSerializer.schema.ts → GRPCStats.schema.ts} +3 -3
  40. package/src/cfg/generated/_utils/schemas/JobListRequest.schema.ts +28 -0
  41. package/src/cfg/generated/_utils/schemas/{MethodInfoSerializer.schema.ts → MethodInfo.schema.ts} +3 -3
  42. package/src/cfg/generated/_utils/schemas/MethodList.schema.ts +2 -2
  43. package/src/cfg/generated/_utils/schemas/{MethodStatsSerializer.schema.ts → MethodStats.schema.ts} +3 -3
  44. package/src/cfg/generated/_utils/schemas/{MethodSummarySerializer.schema.ts → MethodSummary.schema.ts} +5 -5
  45. package/src/cfg/generated/_utils/schemas/{MonitoringServiceStatsSerializer.schema.ts → MonitoringServiceStats.schema.ts} +3 -3
  46. package/src/cfg/generated/_utils/schemas/PaginatedApiKeyList.schema.ts +24 -0
  47. package/src/cfg/generated/_utils/schemas/PaginatedJobListList.schema.ts +24 -0
  48. package/src/cfg/generated/_utils/schemas/PaginatedPublishList.schema.ts +24 -0
  49. package/src/cfg/generated/_utils/schemas/PaginatedScheduledJobList.schema.ts +24 -0
  50. package/src/cfg/generated/_utils/schemas/ProtoFileDetail.schema.ts +27 -0
  51. package/src/cfg/generated/_utils/schemas/ProtoFileList.schema.ts +23 -0
  52. package/src/cfg/generated/_utils/schemas/ProtoGenerateError.schema.ts +20 -0
  53. package/src/cfg/generated/_utils/schemas/ProtoGenerateRequestRequest.schema.ts +20 -0
  54. package/src/cfg/generated/_utils/schemas/ProtoGenerateResponse.schema.ts +24 -0
  55. package/src/cfg/generated/_utils/schemas/Publish.schema.ts +29 -0
  56. package/src/cfg/generated/_utils/schemas/{RecentErrorSerializer.schema.ts → RecentError.schema.ts} +3 -3
  57. package/src/cfg/generated/_utils/schemas/RecentRequest.schema.ts +5 -0
  58. package/src/cfg/generated/_utils/schemas/ServiceDetail.schema.ts +6 -6
  59. package/src/cfg/generated/_utils/schemas/ServiceList.schema.ts +2 -2
  60. package/src/cfg/generated/_utils/schemas/ServiceMethods.schema.ts +2 -2
  61. package/src/cfg/generated/_utils/schemas/{ServiceStatsSerializer.schema.ts → ServiceStats.schema.ts} +3 -3
  62. package/src/cfg/generated/_utils/schemas/index.ts +26 -19
  63. package/src/cfg/generated/cfg__centrifugo/client.ts +1 -1
  64. package/src/cfg/generated/cfg__centrifugo/models.ts +19 -0
  65. package/src/cfg/generated/cfg__centrifugo__centrifugo_monitoring/client.ts +6 -5
  66. package/src/cfg/generated/cfg__centrifugo__centrifugo_monitoring/models.ts +37 -11
  67. package/src/cfg/generated/cfg__dashboard__dashboard_commands/models.ts +10 -1
  68. package/src/cfg/generated/cfg__grpc__grpc_api_keys/client.ts +56 -0
  69. package/src/cfg/generated/cfg__grpc__grpc_api_keys/index.ts +2 -0
  70. package/src/cfg/generated/cfg__grpc__grpc_api_keys/models.ts +79 -0
  71. package/src/cfg/generated/cfg__grpc__grpc_charts/models.ts +0 -96
  72. package/src/cfg/generated/cfg__grpc__grpc_configuration/models.ts +10 -10
  73. package/src/cfg/generated/cfg__grpc__grpc_monitoring/models.ts +15 -5
  74. package/src/cfg/generated/cfg__grpc__grpc_proto_files/client.ts +54 -0
  75. package/src/cfg/generated/cfg__grpc__grpc_proto_files/index.ts +2 -0
  76. package/src/cfg/generated/cfg__grpc__grpc_proto_files/models.ts +35 -0
  77. package/src/cfg/generated/cfg__grpc__grpc_services/models.ts +8 -8
  78. package/src/cfg/generated/cfg__grpc__grpc_testing/models.ts +2 -2
  79. package/src/cfg/generated/cfg__rq__rq_jobs/client.ts +8 -8
  80. package/src/cfg/generated/cfg__rq__rq_jobs/models.ts +65 -0
  81. package/src/cfg/generated/cfg__rq__rq_registries/client.ts +37 -34
  82. package/src/cfg/generated/cfg__rq__rq_registries/models.ts +65 -0
  83. package/src/cfg/generated/cfg__rq__rq_schedules/client.ts +4 -4
  84. package/src/cfg/generated/cfg__rq__rq_schedules/models.ts +25 -0
  85. package/src/cfg/generated/client.ts +6 -0
  86. package/src/cfg/generated/index.ts +10 -0
  87. package/src/cfg/generated/schema.ts +1613 -935
  88. package/src/cfg/generated/_utils/schemas/ErrorDistributionChartSerializer.schema.ts +0 -24
  89. package/src/cfg/generated/_utils/schemas/RecentPublishes.schema.ts +0 -23
  90. package/src/cfg/generated/_utils/schemas/RequestVolumeChartSerializer.schema.ts +0 -25
  91. package/src/cfg/generated/_utils/schemas/ResponseTimeChartSerializer.schema.ts +0 -25
  92. package/src/cfg/generated/_utils/schemas/ServerUptimeChartSerializer.schema.ts +0 -25
  93. package/src/cfg/generated/_utils/schemas/ServiceActivityChartSerializer.schema.ts +0 -24
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@djangocfg/api",
3
- "version": "1.2.23",
3
+ "version": "1.2.24",
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.23",
71
+ "@djangocfg/typescript-config": "^1.2.24",
72
72
  "react": "^19.1.0",
73
73
  "react-dom": "^19.1.0",
74
74
  "tsup": "^8.5.0",
@@ -29,6 +29,7 @@
29
29
  * const users = await getUsers({ page: 1 }, api)
30
30
  * ```
31
31
  */
32
+ import { PublishSchema, type Publish } from '../schemas/Publish.schema'
32
33
  import { getAPIInstance } from '../../api-instance'
33
34
 
34
35
  /**
@@ -38,10 +39,10 @@ import { getAPIInstance } from '../../api-instance'
38
39
  * @path /cfg/centrifugo/monitor/channels/
39
40
  */
40
41
  export async function getCentrifugoMonitorChannelsRetrieve( client?: any
41
- ): Promise<any> {
42
+ ): Promise<Publish> {
42
43
  const api = client || getAPIInstance()
43
44
  const response = await api.cfg_centrifugo.monitorChannelsRetrieve()
44
- return response
45
+ return PublishSchema.parse(response)
45
46
  }
46
47
 
47
48
 
@@ -32,7 +32,7 @@
32
32
  import { CentrifugoOverviewStatsSchema, type CentrifugoOverviewStats } from '../schemas/CentrifugoOverviewStats.schema'
33
33
  import { ChannelListSchema, type ChannelList } from '../schemas/ChannelList.schema'
34
34
  import { HealthCheckSchema, type HealthCheck } from '../schemas/HealthCheck.schema'
35
- import { RecentPublishesSchema, type RecentPublishes } from '../schemas/RecentPublishes.schema'
35
+ import { PaginatedPublishListSchema, type PaginatedPublishList } from '../schemas/PaginatedPublishList.schema'
36
36
  import { getAPIInstance } from '../../api-instance'
37
37
 
38
38
  /**
@@ -69,11 +69,11 @@ export async function getCentrifugoMonitorOverviewRetrieve( params?: { hours?:
69
69
  * @method GET
70
70
  * @path /cfg/centrifugo/monitor/publishes/
71
71
  */
72
- export async function getCentrifugoMonitorPublishesRetrieve( params?: { channel?: string; count?: number; offset?: number; status?: string }, client?: any
73
- ): Promise<RecentPublishes> {
72
+ export async function getCentrifugoMonitorPublishesList( params?: { channel?: string; page?: number; page_size?: number; status?: string }, client?: any
73
+ ): Promise<PaginatedPublishList> {
74
74
  const api = client || getAPIInstance()
75
- const response = await api.cfg_centrifugo_monitoring.centrifugoMonitorPublishesRetrieve(params?.channel, params?.count, params?.offset, params?.status)
76
- return RecentPublishesSchema.parse(response)
75
+ const response = await api.cfg_centrifugo_monitoring.centrifugoMonitorPublishesList(params?.channel, params?.page, params?.page_size, params?.status)
76
+ return PaginatedPublishListSchema.parse(response)
77
77
  }
78
78
 
79
79
 
@@ -0,0 +1,78 @@
1
+ /**
2
+ * Typed fetchers for Grpc Api Keys
3
+ *
4
+ * Universal functions that work in any environment:
5
+ * - Next.js (App Router / Pages Router / Server Components)
6
+ * - React Native
7
+ * - Node.js backend
8
+ *
9
+ * These fetchers use Zod schemas for runtime validation.
10
+ *
11
+ * Usage:
12
+ * ```typescript
13
+ * // Configure API once (in your app entry point)
14
+ * import { configureAPI } from '../../api-instance'
15
+ * configureAPI({ baseUrl: 'https://api.example.com' })
16
+ *
17
+ * // Then use fetchers anywhere
18
+ * const users = await getUsers({ page: 1 })
19
+ *
20
+ * // With SWR
21
+ * const { data } = useSWR(['users', params], () => getUsers(params))
22
+ *
23
+ * // With React Query
24
+ * const { data } = useQuery(['users', params], () => getUsers(params))
25
+ *
26
+ * // In Server Component or SSR (pass custom client)
27
+ * import { API } from '../../index'
28
+ * const api = new API('https://api.example.com')
29
+ * const users = await getUsers({ page: 1 }, api)
30
+ * ```
31
+ */
32
+ import { ApiKeySchema, type ApiKey } from '../schemas/ApiKey.schema'
33
+ import { ApiKeyStatsSchema, type ApiKeyStats } from '../schemas/ApiKeyStats.schema'
34
+ import { PaginatedApiKeyListSchema, type PaginatedApiKeyList } from '../schemas/PaginatedApiKeyList.schema'
35
+ import { getAPIInstance } from '../../api-instance'
36
+
37
+ /**
38
+ * List API keys
39
+ *
40
+ * @method GET
41
+ * @path /cfg/grpc/api-keys/
42
+ */
43
+ export async function getGrpcApiKeysList( params?: { is_active?: boolean; key_type?: string; page?: number; page_size?: number; user_id?: number }, client?: any
44
+ ): Promise<PaginatedApiKeyList> {
45
+ const api = client || getAPIInstance()
46
+ const response = await api.cfg_grpc_api_keys.list(params?.is_active, params?.key_type, params?.page, params?.page_size, params?.user_id)
47
+ return PaginatedApiKeyListSchema.parse(response)
48
+ }
49
+
50
+
51
+ /**
52
+ * Get API key details
53
+ *
54
+ * @method GET
55
+ * @path /cfg/grpc/api-keys/{id}/
56
+ */
57
+ export async function getGrpcApiKeysRetrieve( id: number, client?: any
58
+ ): Promise<ApiKey> {
59
+ const api = client || getAPIInstance()
60
+ const response = await api.cfg_grpc_api_keys.retrieve(id)
61
+ return ApiKeySchema.parse(response)
62
+ }
63
+
64
+
65
+ /**
66
+ * Get API keys statistics
67
+ *
68
+ * @method GET
69
+ * @path /cfg/grpc/api-keys/stats/
70
+ */
71
+ export async function getGrpcApiKeysStatsRetrieve( client?: any
72
+ ): Promise<ApiKeyStats> {
73
+ const api = client || getAPIInstance()
74
+ const response = await api.cfg_grpc_api_keys.statsRetrieve()
75
+ return ApiKeyStatsSchema.parse(response)
76
+ }
77
+
78
+
@@ -0,0 +1,91 @@
1
+ /**
2
+ * Typed fetchers for Grpc Proto Files
3
+ *
4
+ * Universal functions that work in any environment:
5
+ * - Next.js (App Router / Pages Router / Server Components)
6
+ * - React Native
7
+ * - Node.js backend
8
+ *
9
+ * These fetchers use Zod schemas for runtime validation.
10
+ *
11
+ * Usage:
12
+ * ```typescript
13
+ * // Configure API once (in your app entry point)
14
+ * import { configureAPI } from '../../api-instance'
15
+ * configureAPI({ baseUrl: 'https://api.example.com' })
16
+ *
17
+ * // Then use fetchers anywhere
18
+ * const users = await getUsers({ page: 1 })
19
+ *
20
+ * // With SWR
21
+ * const { data } = useSWR(['users', params], () => getUsers(params))
22
+ *
23
+ * // With React Query
24
+ * const { data } = useQuery(['users', params], () => getUsers(params))
25
+ *
26
+ * // In Server Component or SSR (pass custom client)
27
+ * import { API } from '../../index'
28
+ * const api = new API('https://api.example.com')
29
+ * const users = await getUsers({ page: 1 }, api)
30
+ * ```
31
+ */
32
+ import { ProtoGenerateRequestRequestSchema, type ProtoGenerateRequestRequest } from '../schemas/ProtoGenerateRequestRequest.schema'
33
+ import { ProtoGenerateResponseSchema, type ProtoGenerateResponse } from '../schemas/ProtoGenerateResponse.schema'
34
+ import { getAPIInstance } from '../../api-instance'
35
+
36
+ /**
37
+ * List all proto files
38
+ *
39
+ * @method GET
40
+ * @path /cfg/grpc/proto-files/
41
+ */
42
+ export async function getGrpcProtoFilesList( client?: any
43
+ ): Promise<any> {
44
+ const api = client || getAPIInstance()
45
+ const response = await api.cfg_grpc_proto_files.list()
46
+ return response
47
+ }
48
+
49
+
50
+ /**
51
+ * Download proto file
52
+ *
53
+ * @method GET
54
+ * @path /cfg/grpc/proto-files/{id}/
55
+ */
56
+ export async function getGrpcProtoFilesRetrieve( id: string, pk: string, client?: any
57
+ ): Promise<any> {
58
+ const api = client || getAPIInstance()
59
+ const response = await api.cfg_grpc_proto_files.retrieve(id, pk)
60
+ return response
61
+ }
62
+
63
+
64
+ /**
65
+ * Download all proto files
66
+ *
67
+ * @method GET
68
+ * @path /cfg/grpc/proto-files/download-all/
69
+ */
70
+ export async function getGrpcProtoFilesDownloadAllRetrieve( client?: any
71
+ ): Promise<any> {
72
+ const api = client || getAPIInstance()
73
+ const response = await api.cfg_grpc_proto_files.downloadAllRetrieve()
74
+ return response
75
+ }
76
+
77
+
78
+ /**
79
+ * Generate proto files
80
+ *
81
+ * @method POST
82
+ * @path /cfg/grpc/proto-files/generate/
83
+ */
84
+ export async function createGrpcProtoFilesGenerateCreate( data: ProtoGenerateRequestRequest, client?: any
85
+ ): Promise<ProtoGenerateResponse> {
86
+ const api = client || getAPIInstance()
87
+ const response = await api.cfg_grpc_proto_files.generateCreate(data)
88
+ return ProtoGenerateResponseSchema.parse(response)
89
+ }
90
+
91
+
@@ -31,6 +31,8 @@
31
31
  */
32
32
  import { JobActionResponseSchema, type JobActionResponse } from '../schemas/JobActionResponse.schema'
33
33
  import { JobDetailSchema, type JobDetail } from '../schemas/JobDetail.schema'
34
+ import { JobListRequestSchema, type JobListRequest } from '../schemas/JobListRequest.schema'
35
+ import { PaginatedJobListListSchema, type PaginatedJobListList } from '../schemas/PaginatedJobListList.schema'
34
36
  import { getAPIInstance } from '../../api-instance'
35
37
 
36
38
  /**
@@ -39,11 +41,11 @@ import { getAPIInstance } from '../../api-instance'
39
41
  * @method GET
40
42
  * @path /cfg/rq/jobs/
41
43
  */
42
- export async function getRqJobsList( params?: { queue?: string; status?: string }, client?: any
43
- ): Promise<any> {
44
+ export async function getRqJobsList( params?: { page?: number; page_size?: number; queue?: string; status?: string }, client?: any
45
+ ): Promise<PaginatedJobListList> {
44
46
  const api = client || getAPIInstance()
45
- const response = await api.cfg_rq_jobs.list(params?.queue, params?.status)
46
- return response
47
+ const response = await api.cfg_rq_jobs.list(params?.page, params?.page_size, params?.queue, params?.status)
48
+ return PaginatedJobListListSchema.parse(response)
47
49
  }
48
50
 
49
51
 
@@ -81,10 +83,10 @@ export async function deleteRqJobsDestroy( id: string, client?: any
81
83
  * @method POST
82
84
  * @path /cfg/rq/jobs/{id}/cancel/
83
85
  */
84
- export async function createRqJobsCancelCreate( id: string, client?: any
86
+ export async function createRqJobsCancelCreate( id: string, data: JobListRequest, client?: any
85
87
  ): Promise<JobActionResponse> {
86
88
  const api = client || getAPIInstance()
87
- const response = await api.cfg_rq_jobs.cancelCreate(id)
89
+ const response = await api.cfg_rq_jobs.cancelCreate(id, data)
88
90
  return JobActionResponseSchema.parse(response)
89
91
  }
90
92
 
@@ -95,10 +97,10 @@ export async function createRqJobsCancelCreate( id: string, client?: any
95
97
  * @method POST
96
98
  * @path /cfg/rq/jobs/{id}/requeue/
97
99
  */
98
- export async function createRqJobsRequeueCreate( id: string, client?: any
100
+ export async function createRqJobsRequeueCreate( id: string, data: JobListRequest, client?: any
99
101
  ): Promise<JobActionResponse> {
100
102
  const api = client || getAPIInstance()
101
- const response = await api.cfg_rq_jobs.requeueCreate(id)
103
+ const response = await api.cfg_rq_jobs.requeueCreate(id, data)
102
104
  return JobActionResponseSchema.parse(response)
103
105
  }
104
106
 
@@ -30,6 +30,8 @@
30
30
  * ```
31
31
  */
32
32
  import { JobActionResponseSchema, type JobActionResponse } from '../schemas/JobActionResponse.schema'
33
+ import { JobListRequestSchema, type JobListRequest } from '../schemas/JobListRequest.schema'
34
+ import { PaginatedJobListListSchema, type PaginatedJobListList } from '../schemas/PaginatedJobListList.schema'
33
35
  import { getAPIInstance } from '../../api-instance'
34
36
 
35
37
  /**
@@ -38,11 +40,11 @@ import { getAPIInstance } from '../../api-instance'
38
40
  * @method GET
39
41
  * @path /cfg/rq/jobs/registries/deferred/
40
42
  */
41
- export async function getRqJobsRegistriesDeferredList( params?: { queue?: string }, client?: any
42
- ): Promise<any> {
43
+ export async function getRqJobsRegistriesDeferredList( params?: { page?: number; page_size?: number; queue?: string }, client?: any
44
+ ): Promise<PaginatedJobListList> {
43
45
  const api = client || getAPIInstance()
44
- const response = await api.cfg_rq_registries.rqJobsRegistriesDeferredList(params?.queue)
45
- return response
46
+ const response = await api.cfg_rq_registries.rqJobsRegistriesDeferredList(params?.page, params?.page_size, params?.queue)
47
+ return PaginatedJobListListSchema.parse(response)
46
48
  }
47
49
 
48
50
 
@@ -52,11 +54,11 @@ export async function getRqJobsRegistriesDeferredList( params?: { queue?: strin
52
54
  * @method GET
53
55
  * @path /cfg/rq/jobs/registries/failed/
54
56
  */
55
- export async function getRqJobsRegistriesFailedList( params?: { queue?: string }, client?: any
56
- ): Promise<any> {
57
+ export async function getRqJobsRegistriesFailedList( params?: { page?: number; page_size?: number; queue?: string }, client?: any
58
+ ): Promise<PaginatedJobListList> {
57
59
  const api = client || getAPIInstance()
58
- const response = await api.cfg_rq_registries.rqJobsRegistriesFailedList(params?.queue)
59
- return response
60
+ const response = await api.cfg_rq_registries.rqJobsRegistriesFailedList(params?.page, params?.page_size, params?.queue)
61
+ return PaginatedJobListListSchema.parse(response)
60
62
  }
61
63
 
62
64
 
@@ -66,10 +68,10 @@ export async function getRqJobsRegistriesFailedList( params?: { queue?: string
66
68
  * @method POST
67
69
  * @path /cfg/rq/jobs/registries/failed/clear/
68
70
  */
69
- export async function createRqJobsRegistriesFailedClearCreate( params: { queue: string }, client?: any
71
+ export async function createRqJobsRegistriesFailedClearCreate( data: JobListRequest, params: { queue: string }, client?: any
70
72
  ): Promise<JobActionResponse> {
71
73
  const api = client || getAPIInstance()
72
- const response = await api.cfg_rq_registries.rqJobsRegistriesFailedClearCreate(params.queue)
74
+ const response = await api.cfg_rq_registries.rqJobsRegistriesFailedClearCreate(data, params.queue)
73
75
  return JobActionResponseSchema.parse(response)
74
76
  }
75
77
 
@@ -80,10 +82,10 @@ export async function createRqJobsRegistriesFailedClearCreate( params: { queue:
80
82
  * @method POST
81
83
  * @path /cfg/rq/jobs/registries/failed/requeue-all/
82
84
  */
83
- export async function createRqJobsRegistriesFailedRequeueAllCreate( params: { queue: string }, client?: any
85
+ export async function createRqJobsRegistriesFailedRequeueAllCreate( data: JobListRequest, params: { queue: string }, client?: any
84
86
  ): Promise<JobActionResponse> {
85
87
  const api = client || getAPIInstance()
86
- const response = await api.cfg_rq_registries.rqJobsRegistriesFailedRequeueAllCreate(params.queue)
88
+ const response = await api.cfg_rq_registries.rqJobsRegistriesFailedRequeueAllCreate(data, params.queue)
87
89
  return JobActionResponseSchema.parse(response)
88
90
  }
89
91
 
@@ -94,11 +96,11 @@ export async function createRqJobsRegistriesFailedRequeueAllCreate( params: { q
94
96
  * @method GET
95
97
  * @path /cfg/rq/jobs/registries/finished/
96
98
  */
97
- export async function getRqJobsRegistriesFinishedList( params?: { queue?: string }, client?: any
98
- ): Promise<any> {
99
+ export async function getRqJobsRegistriesFinishedList( params?: { page?: number; page_size?: number; queue?: string }, client?: any
100
+ ): Promise<PaginatedJobListList> {
99
101
  const api = client || getAPIInstance()
100
- const response = await api.cfg_rq_registries.rqJobsRegistriesFinishedList(params?.queue)
101
- return response
102
+ const response = await api.cfg_rq_registries.rqJobsRegistriesFinishedList(params?.page, params?.page_size, params?.queue)
103
+ return PaginatedJobListListSchema.parse(response)
102
104
  }
103
105
 
104
106
 
@@ -108,10 +110,10 @@ export async function getRqJobsRegistriesFinishedList( params?: { queue?: strin
108
110
  * @method POST
109
111
  * @path /cfg/rq/jobs/registries/finished/clear/
110
112
  */
111
- export async function createRqJobsRegistriesFinishedClearCreate( params: { queue: string }, client?: any
113
+ export async function createRqJobsRegistriesFinishedClearCreate( data: JobListRequest, params: { queue: string }, client?: any
112
114
  ): Promise<JobActionResponse> {
113
115
  const api = client || getAPIInstance()
114
- const response = await api.cfg_rq_registries.rqJobsRegistriesFinishedClearCreate(params.queue)
116
+ const response = await api.cfg_rq_registries.rqJobsRegistriesFinishedClearCreate(data, params.queue)
115
117
  return JobActionResponseSchema.parse(response)
116
118
  }
117
119
 
@@ -122,11 +124,11 @@ export async function createRqJobsRegistriesFinishedClearCreate( params: { queu
122
124
  * @method GET
123
125
  * @path /cfg/rq/jobs/registries/started/
124
126
  */
125
- export async function getRqJobsRegistriesStartedList( params?: { queue?: string }, client?: any
126
- ): Promise<any> {
127
+ export async function getRqJobsRegistriesStartedList( params?: { page?: number; page_size?: number; queue?: string }, client?: any
128
+ ): Promise<PaginatedJobListList> {
127
129
  const api = client || getAPIInstance()
128
- const response = await api.cfg_rq_registries.rqJobsRegistriesStartedList(params?.queue)
129
- return response
130
+ const response = await api.cfg_rq_registries.rqJobsRegistriesStartedList(params?.page, params?.page_size, params?.queue)
131
+ return PaginatedJobListListSchema.parse(response)
130
132
  }
131
133
 
132
134
 
@@ -29,6 +29,7 @@
29
29
  * const users = await getUsers({ page: 1 }, api)
30
30
  * ```
31
31
  */
32
+ import { PaginatedScheduledJobListSchema, type PaginatedScheduledJobList } from '../schemas/PaginatedScheduledJobList.schema'
32
33
  import { ScheduleActionResponseSchema, type ScheduleActionResponse } from '../schemas/ScheduleActionResponse.schema'
33
34
  import { ScheduleCreateRequestSchema, type ScheduleCreateRequest } from '../schemas/ScheduleCreateRequest.schema'
34
35
  import { ScheduledJobSchema, type ScheduledJob } from '../schemas/ScheduledJob.schema'
@@ -40,11 +41,11 @@ import { getAPIInstance } from '../../api-instance'
40
41
  * @method GET
41
42
  * @path /cfg/rq/schedules/
42
43
  */
43
- export async function getRqSchedulesList( params?: { queue?: string }, client?: any
44
- ): Promise<any> {
44
+ export async function getRqSchedulesList( params?: { page?: number; page_size?: number; queue?: string }, client?: any
45
+ ): Promise<PaginatedScheduledJobList> {
45
46
  const api = client || getAPIInstance()
46
- const response = await api.cfg_rq_schedules.list(params?.queue)
47
- return response
47
+ const response = await api.cfg_rq_schedules.list(params?.page, params?.page_size, params?.queue)
48
+ return PaginatedScheduledJobListSchema.parse(response)
48
49
  }
49
50
 
50
51
 
@@ -41,9 +41,11 @@ export * from './cfg__dashboard__dashboard_overview'
41
41
  export * from './cfg__dashboard__dashboard_statistics'
42
42
  export * from './cfg__dashboard__dashboard_system'
43
43
  export * from './cfg__endpoints'
44
+ export * from './cfg__grpc__grpc_api_keys'
44
45
  export * from './cfg__grpc__grpc_charts'
45
46
  export * from './cfg__grpc__grpc_configuration'
46
47
  export * from './cfg__grpc__grpc_monitoring'
48
+ export * from './cfg__grpc__grpc_proto_files'
47
49
  export * from './cfg__grpc__grpc_services'
48
50
  export * from './cfg__grpc__grpc_testing'
49
51
  export * from './cfg__health'
@@ -18,6 +18,7 @@ import useSWR from 'swr'
18
18
  import { useSWRConfig } from 'swr'
19
19
  import * as Fetchers from '../fetchers/cfg__centrifugo'
20
20
  import type { API } from '../../index'
21
+ import type { Publish } from '../schemas/Publish.schema'
21
22
 
22
23
  /**
23
24
  * API operation
@@ -25,8 +26,8 @@ import type { API } from '../../index'
25
26
  * @method GET
26
27
  * @path /cfg/centrifugo/monitor/channels/
27
28
  */
28
- export function useCentrifugoMonitorChannelsRetrieve(client?: API): ReturnType<typeof useSWR<any>> {
29
- return useSWR<any>(
29
+ export function useCentrifugoMonitorChannelsRetrieve(client?: API): ReturnType<typeof useSWR<Publish>> {
30
+ return useSWR<Publish>(
30
31
  'cfg-centrifugo-monitor-channel',
31
32
  () => Fetchers.getCentrifugoMonitorChannelsRetrieve(client)
32
33
  )
@@ -21,7 +21,7 @@ import type { API } from '../../index'
21
21
  import type { CentrifugoOverviewStats } from '../schemas/CentrifugoOverviewStats.schema'
22
22
  import type { ChannelList } from '../schemas/ChannelList.schema'
23
23
  import type { HealthCheck } from '../schemas/HealthCheck.schema'
24
- import type { RecentPublishes } from '../schemas/RecentPublishes.schema'
24
+ import type { PaginatedPublishList } from '../schemas/PaginatedPublishList.schema'
25
25
 
26
26
  /**
27
27
  * Get Centrifugo health status
@@ -57,10 +57,10 @@ export function useCentrifugoMonitorOverviewRetrieve(params?: { hours?: number }
57
57
  * @method GET
58
58
  * @path /cfg/centrifugo/monitor/publishes/
59
59
  */
60
- export function useCentrifugoMonitorPublishesRetrieve(params?: { channel?: string; count?: number; offset?: number; status?: string }, client?: API): ReturnType<typeof useSWR<RecentPublishes>> {
61
- return useSWR<RecentPublishes>(
62
- params ? ['cfg-centrifugo-monitor-publishe', params] : 'cfg-centrifugo-monitor-publishe',
63
- () => Fetchers.getCentrifugoMonitorPublishesRetrieve(params, client)
60
+ export function useCentrifugoMonitorPublishesList(params?: { channel?: string; page?: number; page_size?: number; status?: string }, client?: API): ReturnType<typeof useSWR<PaginatedPublishList>> {
61
+ return useSWR<PaginatedPublishList>(
62
+ params ? ['cfg-centrifugo-monitor-publishes', params] : 'cfg-centrifugo-monitor-publishes',
63
+ () => Fetchers.getCentrifugoMonitorPublishesList(params, client)
64
64
  )
65
65
  }
66
66
 
@@ -0,0 +1,66 @@
1
+ /**
2
+ * SWR Hooks for Grpc Api Keys
3
+ *
4
+ * React hooks powered by SWR for data fetching with automatic caching,
5
+ * revalidation, and optimistic updates.
6
+ *
7
+ * Usage:
8
+ * ```typescript
9
+ * // Query hooks (GET)
10
+ * const { data, error, isLoading } = useUsers({ page: 1 })
11
+ *
12
+ * // Mutation hooks (POST/PUT/PATCH/DELETE)
13
+ * const createUser = useCreateUser()
14
+ * await createUser({ name: 'John', email: 'john@example.com' })
15
+ * ```
16
+ */
17
+ import useSWR from 'swr'
18
+ import { useSWRConfig } from 'swr'
19
+ import * as Fetchers from '../fetchers/cfg__grpc__grpc_api_keys'
20
+ import type { API } from '../../index'
21
+ import type { ApiKey } from '../schemas/ApiKey.schema'
22
+ import type { ApiKeyStats } from '../schemas/ApiKeyStats.schema'
23
+ import type { PaginatedApiKeyList } from '../schemas/PaginatedApiKeyList.schema'
24
+
25
+ /**
26
+ * List API keys
27
+ *
28
+ * @method GET
29
+ * @path /cfg/grpc/api-keys/
30
+ */
31
+ export function useGrpcApiKeysList(params?: { is_active?: boolean; key_type?: string; page?: number; page_size?: number; user_id?: number }, client?: API): ReturnType<typeof useSWR<PaginatedApiKeyList>> {
32
+ return useSWR<PaginatedApiKeyList>(
33
+ params ? ['cfg-grpc-api-keys', params] : 'cfg-grpc-api-keys',
34
+ () => Fetchers.getGrpcApiKeysList(params, client)
35
+ )
36
+ }
37
+
38
+
39
+ /**
40
+ * Get API key details
41
+ *
42
+ * @method GET
43
+ * @path /cfg/grpc/api-keys/{id}/
44
+ */
45
+ export function useGrpcApiKeysRetrieve(id: number, client?: API): ReturnType<typeof useSWR<ApiKey>> {
46
+ return useSWR<ApiKey>(
47
+ ['cfg-grpc-api-key', id],
48
+ () => Fetchers.getGrpcApiKeysRetrieve(id, client)
49
+ )
50
+ }
51
+
52
+
53
+ /**
54
+ * Get API keys statistics
55
+ *
56
+ * @method GET
57
+ * @path /cfg/grpc/api-keys/stats/
58
+ */
59
+ export function useGrpcApiKeysStatsRetrieve(client?: API): ReturnType<typeof useSWR<ApiKeyStats>> {
60
+ return useSWR<ApiKeyStats>(
61
+ 'cfg-grpc-api-keys-stat',
62
+ () => Fetchers.getGrpcApiKeysStatsRetrieve(client)
63
+ )
64
+ }
65
+
66
+
@@ -0,0 +1,83 @@
1
+ /**
2
+ * SWR Hooks for Grpc Proto Files
3
+ *
4
+ * React hooks powered by SWR for data fetching with automatic caching,
5
+ * revalidation, and optimistic updates.
6
+ *
7
+ * Usage:
8
+ * ```typescript
9
+ * // Query hooks (GET)
10
+ * const { data, error, isLoading } = useUsers({ page: 1 })
11
+ *
12
+ * // Mutation hooks (POST/PUT/PATCH/DELETE)
13
+ * const createUser = useCreateUser()
14
+ * await createUser({ name: 'John', email: 'john@example.com' })
15
+ * ```
16
+ */
17
+ import useSWR from 'swr'
18
+ import { useSWRConfig } from 'swr'
19
+ import * as Fetchers from '../fetchers/cfg__grpc__grpc_proto_files'
20
+ import type { API } from '../../index'
21
+ import type { ProtoGenerateRequestRequest } from '../schemas/ProtoGenerateRequestRequest.schema'
22
+ import type { ProtoGenerateResponse } from '../schemas/ProtoGenerateResponse.schema'
23
+
24
+ /**
25
+ * List all proto files
26
+ *
27
+ * @method GET
28
+ * @path /cfg/grpc/proto-files/
29
+ */
30
+ export function useGrpcProtoFilesList(client?: API): ReturnType<typeof useSWR<any>> {
31
+ return useSWR<any>(
32
+ 'cfg-grpc-proto-files',
33
+ () => Fetchers.getGrpcProtoFilesList(client)
34
+ )
35
+ }
36
+
37
+
38
+ /**
39
+ * Download proto file
40
+ *
41
+ * @method GET
42
+ * @path /cfg/grpc/proto-files/{id}/
43
+ */
44
+ export function useGrpcProtoFilesRetrieve(id: string, pk: string, client?: API): ReturnType<typeof useSWR<any>> {
45
+ return useSWR<any>(
46
+ ['cfg-grpc-proto-file', id],
47
+ () => Fetchers.getGrpcProtoFilesRetrieve(id, pk, client)
48
+ )
49
+ }
50
+
51
+
52
+ /**
53
+ * Download all proto files
54
+ *
55
+ * @method GET
56
+ * @path /cfg/grpc/proto-files/download-all/
57
+ */
58
+ export function useGrpcProtoFilesDownloadAllRetrieve(client?: API): ReturnType<typeof useSWR<any>> {
59
+ return useSWR<any>(
60
+ 'cfg-grpc-proto-files-download-all',
61
+ () => Fetchers.getGrpcProtoFilesDownloadAllRetrieve(client)
62
+ )
63
+ }
64
+
65
+
66
+ /**
67
+ * Generate proto files
68
+ *
69
+ * @method POST
70
+ * @path /cfg/grpc/proto-files/generate/
71
+ */
72
+ export function useCreateGrpcProtoFilesGenerateCreate() {
73
+ const { mutate } = useSWRConfig()
74
+
75
+ return async (data: ProtoGenerateRequestRequest, client?: API): Promise<ProtoGenerateResponse> => {
76
+ const result = await Fetchers.createGrpcProtoFilesGenerateCreate(data, client)
77
+ // Revalidate related queries
78
+ mutate('cfg-grpc-proto-files-generate')
79
+ return result
80
+ }
81
+ }
82
+
83
+
@@ -20,6 +20,8 @@ import * as Fetchers from '../fetchers/cfg__rq__rq_jobs'
20
20
  import type { API } from '../../index'
21
21
  import type { JobActionResponse } from '../schemas/JobActionResponse.schema'
22
22
  import type { JobDetail } from '../schemas/JobDetail.schema'
23
+ import type { JobListRequest } from '../schemas/JobListRequest.schema'
24
+ import type { PaginatedJobListList } from '../schemas/PaginatedJobListList.schema'
23
25
 
24
26
  /**
25
27
  * List all jobs
@@ -27,8 +29,8 @@ import type { JobDetail } from '../schemas/JobDetail.schema'
27
29
  * @method GET
28
30
  * @path /cfg/rq/jobs/
29
31
  */
30
- export function useRqJobsList(params?: { queue?: string; status?: string }, client?: API): ReturnType<typeof useSWR<any>> {
31
- return useSWR<any>(
32
+ export function useRqJobsList(params?: { page?: number; page_size?: number; queue?: string; status?: string }, client?: API): ReturnType<typeof useSWR<PaginatedJobListList>> {
33
+ return useSWR<PaginatedJobListList>(
32
34
  params ? ['cfg-rq-jobs', params] : 'cfg-rq-jobs',
33
35
  () => Fetchers.getRqJobsList(params, client)
34
36
  )
@@ -77,8 +79,8 @@ export function useDeleteRqJobsDestroy() {
77
79
  export function useCreateRqJobsCancelCreate() {
78
80
  const { mutate } = useSWRConfig()
79
81
 
80
- return async (id: string, client?: API): Promise<JobActionResponse> => {
81
- const result = await Fetchers.createRqJobsCancelCreate(id, client)
82
+ return async (id: string, data: JobListRequest, client?: API): Promise<JobActionResponse> => {
83
+ const result = await Fetchers.createRqJobsCancelCreate(id, data, client)
82
84
  // Revalidate related queries
83
85
  mutate('cfg-rq-jobs-cancel')
84
86
  return result
@@ -95,8 +97,8 @@ export function useCreateRqJobsCancelCreate() {
95
97
  export function useCreateRqJobsRequeueCreate() {
96
98
  const { mutate } = useSWRConfig()
97
99
 
98
- return async (id: string, client?: API): Promise<JobActionResponse> => {
99
- const result = await Fetchers.createRqJobsRequeueCreate(id, client)
100
+ return async (id: string, data: JobListRequest, client?: API): Promise<JobActionResponse> => {
101
+ const result = await Fetchers.createRqJobsRequeueCreate(id, data, client)
100
102
  // Revalidate related queries
101
103
  mutate('cfg-rq-jobs-requeue')
102
104
  return result