add endpoint to fetch packages
This commit is contained in:
@@ -73,6 +73,22 @@ paths:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ProblemDetails'
|
||||
/manifests/packages:
|
||||
get:
|
||||
operationId: Packages
|
||||
responses:
|
||||
'200':
|
||||
description: 200 response
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/PackagesResponse'
|
||||
default:
|
||||
description: default response
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ProblemDetails'
|
||||
/server/status:
|
||||
get:
|
||||
operationId: GetStatus
|
||||
|
||||
@@ -11,6 +11,15 @@ export class Manifests {
|
||||
default(@body body: ProblemDetails) {}
|
||||
}
|
||||
|
||||
@endpoint({ method: 'GET', path: '/manifests/packages' })
|
||||
export class Packages {
|
||||
@response({ status: 200 })
|
||||
response(@body body: PackagesResponse) {}
|
||||
|
||||
@defaultResponse
|
||||
default(@body body: ProblemDetails) {}
|
||||
}
|
||||
|
||||
export type Manifest =
|
||||
| IManifestSection
|
||||
| IManifestPropertyEditorUI
|
||||
@@ -32,6 +41,16 @@ export interface ManifestsResponse {
|
||||
manifests: Manifest[];
|
||||
}
|
||||
|
||||
export interface PackagesResponse {
|
||||
packages: Package[];
|
||||
}
|
||||
|
||||
export interface Package {
|
||||
name: string;
|
||||
alias: string;
|
||||
version: string;
|
||||
}
|
||||
|
||||
export interface IManifest {
|
||||
type: string;
|
||||
alias: string;
|
||||
|
||||
Reference in New Issue
Block a user