mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-29 13:45:20 +01:00
Move the webhook event API definition to legacy_swagger.yaml (#11127)
The API definition is put on the wrong swagger file introduced by PR #11029 by mistake Signed-off-by: Wenkai Yin <yinw@vmware.com>
This commit is contained in:
parent
9ebcf95758
commit
32f226901f
@ -3212,6 +3212,30 @@ paths:
|
|||||||
description: User have no permission to list webhook jobs of the project.
|
description: User have no permission to list webhook jobs of the project.
|
||||||
'500':
|
'500':
|
||||||
description: Unexpected internal errors.
|
description: Unexpected internal errors.
|
||||||
|
'/projects/{project_id}/webhook/events':
|
||||||
|
get:
|
||||||
|
summary: Get supported event types and notify types.
|
||||||
|
description: Get supportted event types and notify types.
|
||||||
|
tags:
|
||||||
|
- Products
|
||||||
|
parameters:
|
||||||
|
- name: project_id
|
||||||
|
in: path
|
||||||
|
type: integer
|
||||||
|
format: int64
|
||||||
|
required: true
|
||||||
|
description: Relevant project ID.
|
||||||
|
responses:
|
||||||
|
'200':
|
||||||
|
description: Success
|
||||||
|
schema:
|
||||||
|
$ref: '#/definitions/SupportedWebhookEventTypes'
|
||||||
|
'401':
|
||||||
|
description: User need to log in first.
|
||||||
|
'403':
|
||||||
|
description: User have no permission to list webhook jobs of the project.
|
||||||
|
'500':
|
||||||
|
description: Unexpected internal errors.
|
||||||
'/projects/{project_id}/immutabletagrules':
|
'/projects/{project_id}/immutabletagrules':
|
||||||
get:
|
get:
|
||||||
summary: List all immutable tag rules of current project
|
summary: List all immutable tag rules of current project
|
||||||
@ -6120,3 +6144,23 @@ definitions:
|
|||||||
'Success': 5
|
'Success': 5
|
||||||
'Error': 2,
|
'Error': 2,
|
||||||
'Running': 3
|
'Running': 3
|
||||||
|
SupportedWebhookEventTypes:
|
||||||
|
type: object
|
||||||
|
description: Supportted webhook event types and notify types.
|
||||||
|
properties:
|
||||||
|
event_type:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
$ref: '#/definitions/EventType'
|
||||||
|
notify_type:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
$ref: '#/definitions/NotifyType'
|
||||||
|
EventType:
|
||||||
|
type: string
|
||||||
|
description: Webhook supportted event type.
|
||||||
|
example: 'pullImage'
|
||||||
|
NotifyType:
|
||||||
|
type: string
|
||||||
|
description: Webhook supportted notify type.
|
||||||
|
example: 'http'
|
||||||
|
@ -558,24 +558,6 @@ paths:
|
|||||||
$ref: '#/responses/401'
|
$ref: '#/responses/401'
|
||||||
'500':
|
'500':
|
||||||
$ref: '#/responses/500'
|
$ref: '#/responses/500'
|
||||||
# TODO replace project_id with project_name
|
|
||||||
/projects/{project_id}/webhook/events:
|
|
||||||
get:
|
|
||||||
summary: Get supported event types and notify types.
|
|
||||||
description: Get supportted event types and notify types.
|
|
||||||
tags:
|
|
||||||
- notification
|
|
||||||
parameters:
|
|
||||||
- $ref: '#/parameters/projectId'
|
|
||||||
responses:
|
|
||||||
'200':
|
|
||||||
description: Success
|
|
||||||
schema:
|
|
||||||
$ref: '#/definitions/SupportedWebhookEventTypes'
|
|
||||||
'401':
|
|
||||||
$ref: '#/responses/401'
|
|
||||||
'403':
|
|
||||||
$ref: '#/responses/403'
|
|
||||||
/projects/{project_name}/logs:
|
/projects/{project_name}/logs:
|
||||||
get:
|
get:
|
||||||
summary: Get recent logs of the projects
|
summary: Get recent logs of the projects
|
||||||
@ -1066,23 +1048,3 @@ definitions:
|
|||||||
op_time:
|
op_time:
|
||||||
type: string
|
type: string
|
||||||
description: The time when this operation is triggered.
|
description: The time when this operation is triggered.
|
||||||
SupportedWebhookEventTypes:
|
|
||||||
type: object
|
|
||||||
description: Supportted webhook event types and notify types.
|
|
||||||
properties:
|
|
||||||
event_type:
|
|
||||||
type: array
|
|
||||||
items:
|
|
||||||
$ref: '#/definitions/EventType'
|
|
||||||
notify_type:
|
|
||||||
type: array
|
|
||||||
items:
|
|
||||||
$ref: '#/definitions/NotifyType'
|
|
||||||
EventType:
|
|
||||||
type: string
|
|
||||||
description: Webhook supportted event type.
|
|
||||||
example: 'pullImage'
|
|
||||||
NotifyType:
|
|
||||||
type: string
|
|
||||||
description: Webhook supportted notify type.
|
|
||||||
example: 'http'
|
|
||||||
|
Loading…
Reference in New Issue
Block a user