mirror of
				https://github.com/Unleash/unleash.git
				synced 2025-10-27 11:02:16 +01:00 
			
		
		
		
	chore: backport changes from 4.20 (#3021)
## About the changes Changes included in 4.20 release, mainly improving OpenAPI tags
This commit is contained in:
		
							parent
							
								
									751b714642
								
							
						
					
					
						commit
						9c214858c7
					
				| @ -13,6 +13,11 @@ const OPENAPI_TAGS = [ | |||||||
|         description: |         description: | ||||||
|             'Create, update, and delete [Unleash API tokens](https://docs.getunleash.io/reference/api-tokens-and-client-keys).', |             'Create, update, and delete [Unleash API tokens](https://docs.getunleash.io/reference/api-tokens-and-client-keys).', | ||||||
|     }, |     }, | ||||||
|  |     { | ||||||
|  |         name: 'Personal access tokens', | ||||||
|  |         description: | ||||||
|  |             'Create, update, and delete [Personal access tokens](https://docs.getunleash.io/reference/api-tokens-and-client-keys#personal-access-tokens).', | ||||||
|  |     }, | ||||||
|     { |     { | ||||||
|         name: 'Archive', |         name: 'Archive', | ||||||
|         description: |         description: | ||||||
| @ -96,10 +101,20 @@ const OPENAPI_TAGS = [ | |||||||
|             'Experimental endpoints that may change or disappear at any time.', |             'Experimental endpoints that may change or disappear at any time.', | ||||||
|     }, |     }, | ||||||
|     { name: 'Edge', description: 'Endpoints related to Unleash on the Edge.' }, |     { name: 'Edge', description: 'Endpoints related to Unleash on the Edge.' }, | ||||||
|  |     { | ||||||
|  |         name: 'Frontend API', | ||||||
|  |         description: | ||||||
|  |             'API for connecting client-side (frontend) applications to Unleash.', | ||||||
|  |     }, | ||||||
|     { |     { | ||||||
|         name: 'Maintenance', |         name: 'Maintenance', | ||||||
|         description: 'Enable/disable the maintenance mode of Unleash.', |         description: 'Enable/disable the maintenance mode of Unleash.', | ||||||
|     }, |     }, | ||||||
|  |     { | ||||||
|  |         name: 'Change Requests', | ||||||
|  |         description: | ||||||
|  |             'API for managing [change requests](https://docs.getunleash.io/reference/change-requests).', | ||||||
|  |     }, | ||||||
| ] as const; | ] as const; | ||||||
| 
 | 
 | ||||||
| // make the export mutable, so it can be used in a schema
 | // make the export mutable, so it can be used in a schema
 | ||||||
|  | |||||||
| @ -39,7 +39,7 @@ export default class PatController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 openApiService.validPath({ |                 openApiService.validPath({ | ||||||
|                     tags: ['API tokens'], |                     tags: ['Personal access tokens'], | ||||||
|                     operationId: 'getPats', |                     operationId: 'getPats', | ||||||
|                     responses: { 200: createResponseSchema('patsSchema') }, |                     responses: { 200: createResponseSchema('patsSchema') }, | ||||||
|                 }), |                 }), | ||||||
| @ -52,7 +52,7 @@ export default class PatController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 openApiService.validPath({ |                 openApiService.validPath({ | ||||||
|                     tags: ['API tokens'], |                     tags: ['Personal access tokens'], | ||||||
|                     operationId: 'createPat', |                     operationId: 'createPat', | ||||||
|                     requestBody: createRequestSchema('patSchema'), |                     requestBody: createRequestSchema('patSchema'), | ||||||
|                     responses: { 200: createResponseSchema('patSchema') }, |                     responses: { 200: createResponseSchema('patSchema') }, | ||||||
| @ -68,7 +68,7 @@ export default class PatController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 openApiService.validPath({ |                 openApiService.validPath({ | ||||||
|                     tags: ['API tokens'], |                     tags: ['Personal access tokens'], | ||||||
|                     operationId: 'deletePat', |                     operationId: 'deletePat', | ||||||
|                     responses: { 200: emptyResponse }, |                     responses: { 200: emptyResponse }, | ||||||
|                 }), |                 }), | ||||||
|  | |||||||
| @ -63,7 +63,7 @@ export default class ProxyController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 this.services.openApiService.validPath({ |                 this.services.openApiService.validPath({ | ||||||
|                     tags: ['Unstable'], |                     tags: ['Frontend API'], | ||||||
|                     operationId: 'getFrontendFeatures', |                     operationId: 'getFrontendFeatures', | ||||||
|                     responses: { |                     responses: { | ||||||
|                         200: createResponseSchema('proxyFeaturesSchema'), |                         200: createResponseSchema('proxyFeaturesSchema'), | ||||||
| @ -93,7 +93,7 @@ export default class ProxyController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 this.services.openApiService.validPath({ |                 this.services.openApiService.validPath({ | ||||||
|                     tags: ['Unstable'], |                     tags: ['Frontend API'], | ||||||
|                     operationId: 'registerFrontendMetrics', |                     operationId: 'registerFrontendMetrics', | ||||||
|                     requestBody: createRequestSchema('proxyMetricsSchema'), |                     requestBody: createRequestSchema('proxyMetricsSchema'), | ||||||
|                     responses: { 200: emptyResponse }, |                     responses: { 200: emptyResponse }, | ||||||
| @ -108,7 +108,7 @@ export default class ProxyController extends Controller { | |||||||
|             permission: NONE, |             permission: NONE, | ||||||
|             middleware: [ |             middleware: [ | ||||||
|                 this.services.openApiService.validPath({ |                 this.services.openApiService.validPath({ | ||||||
|                     tags: ['Unstable'], |                     tags: ['Frontend API'], | ||||||
|                     operationId: 'registerFrontendClient', |                     operationId: 'registerFrontendClient', | ||||||
|                     requestBody: createRequestSchema('proxyClientSchema'), |                     requestBody: createRequestSchema('proxyClientSchema'), | ||||||
|                     responses: { 200: emptyResponse }, |                     responses: { 200: emptyResponse }, | ||||||
|  | |||||||
| @ -7915,7 +7915,7 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|           }, |           }, | ||||||
|         }, |         }, | ||||||
|         "tags": [ |         "tags": [ | ||||||
|           "API tokens", |           "Personal access tokens", | ||||||
|         ], |         ], | ||||||
|       }, |       }, | ||||||
|       "post": { |       "post": { | ||||||
| @ -7944,7 +7944,7 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|           }, |           }, | ||||||
|         }, |         }, | ||||||
|         "tags": [ |         "tags": [ | ||||||
|           "API tokens", |           "Personal access tokens", | ||||||
|         ], |         ], | ||||||
|       }, |       }, | ||||||
|     }, |     }, | ||||||
| @ -7967,7 +7967,7 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|           }, |           }, | ||||||
|         }, |         }, | ||||||
|         "tags": [ |         "tags": [ | ||||||
|           "API tokens", |           "Personal access tokens", | ||||||
|         ], |         ], | ||||||
|       }, |       }, | ||||||
|     }, |     }, | ||||||
| @ -8364,6 +8364,10 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|       "description": "Manage logins, passwords, etc.", |       "description": "Manage logins, passwords, etc.", | ||||||
|       "name": "Auth", |       "name": "Auth", | ||||||
|     }, |     }, | ||||||
|  |     { | ||||||
|  |       "description": "API for managing [change requests](https://docs.getunleash.io/reference/change-requests).", | ||||||
|  |       "name": "Change Requests", | ||||||
|  |     }, | ||||||
|     { |     { | ||||||
|       "description": "Endpoints for [Unleash server-side clients](https://docs.getunleash.io/reference/sdks).", |       "description": "Endpoints for [Unleash server-side clients](https://docs.getunleash.io/reference/sdks).", | ||||||
|       "name": "Client", |       "name": "Client", | ||||||
| @ -8388,6 +8392,10 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|       "description": "Create, update, and delete [features toggles](https://docs.getunleash.io/reference/feature-toggles).", |       "description": "Create, update, and delete [features toggles](https://docs.getunleash.io/reference/feature-toggles).", | ||||||
|       "name": "Features", |       "name": "Features", | ||||||
|     }, |     }, | ||||||
|  |     { | ||||||
|  |       "description": "API for connecting client-side (frontend) applications to Unleash.", | ||||||
|  |       "name": "Frontend API", | ||||||
|  |     }, | ||||||
|     { |     { | ||||||
|       "description": "[Import and export](https://docs.getunleash.io/deploy/import_export) the state of your Unleash instance.", |       "description": "[Import and export](https://docs.getunleash.io/deploy/import_export) the state of your Unleash instance.", | ||||||
|       "name": "Import/Export", |       "name": "Import/Export", | ||||||
| @ -8408,6 +8416,10 @@ If the provided project does not exist, the list of events will be empty.", | |||||||
|       "description": "Endpoints related to the operational status of this Unleash instance.", |       "description": "Endpoints related to the operational status of this Unleash instance.", | ||||||
|       "name": "Operational", |       "name": "Operational", | ||||||
|     }, |     }, | ||||||
|  |     { | ||||||
|  |       "description": "Create, update, and delete [Personal access tokens](https://docs.getunleash.io/reference/api-tokens-and-client-keys#personal-access-tokens).", | ||||||
|  |       "name": "Personal access tokens", | ||||||
|  |     }, | ||||||
|     { |     { | ||||||
|       "description": "Evaluate an Unleash context against your feature toggles.", |       "description": "Evaluate an Unleash context against your feature toggles.", | ||||||
|       "name": "Playground", |       "name": "Playground", | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user