| # |
| # Licensed to the Apache Software Foundation (ASF) under one or more |
| # contributor license agreements. See the NOTICE file distributed with |
| # this work for additional information regarding copyright ownership. |
| # The ASF licenses this file to You under the Apache License, Version 2.0 |
| # (the "License"); you may not use this file except in compliance with |
| # the License. You may obtain a copy of the License at |
| # |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| |
| definitions: |
| main.QueryEventResponse: |
| properties: |
| event: |
| $ref: '#/definitions/model.Event' |
| type: object |
| main.QueryEventsResponse: |
| properties: |
| events: |
| items: |
| $ref: '#/definitions/model.Event' |
| type: array |
| total: |
| description: total count |
| type: integer |
| type: object |
| main.SaveEventRequest: |
| properties: |
| event: |
| $ref: '#/definitions/model.Event' |
| type: object |
| model.Event: |
| properties: |
| create_time: |
| type: string |
| definition: |
| type: string |
| file_name: |
| type: string |
| id: |
| type: integer |
| status: |
| type: integer |
| title: |
| type: string |
| update_time: |
| type: string |
| version: |
| type: string |
| type: object |
| info: |
| contact: {} |
| description: This is a event catalog server. |
| license: |
| name: Apache 2.0 |
| url: http://www.apache.org/licenses/LICENSE-2.0.html |
| title: Event Catalog API |
| version: "1.0" |
| paths: |
| /catalog: |
| get: |
| consumes: |
| - application/json |
| description: query event catalog list |
| parameters: |
| - description: query page |
| in: query |
| name: page |
| type: string |
| - description: query size |
| in: query |
| name: size |
| type: string |
| produces: |
| - application/json |
| responses: |
| "200": |
| description: OK |
| schema: |
| $ref: '#/definitions/main.QueryEventsResponse' |
| "400": |
| description: Bad Request |
| "404": |
| description: Not Found |
| "500": |
| description: Internal Server Error |
| summary: query event catalog list |
| tags: |
| - Catalog |
| post: |
| consumes: |
| - application/json |
| description: save event catalog |
| parameters: |
| - description: event catalog data |
| in: body |
| name: request |
| required: true |
| schema: |
| $ref: '#/definitions/main.SaveEventRequest' |
| produces: |
| - application/json |
| responses: |
| "200": |
| description: OK |
| "400": |
| description: Bad Request |
| "404": |
| description: Not Found |
| "500": |
| description: Internal Server Error |
| summary: save event catalog |
| tags: |
| - Catalog |
| /catalog/{eventId}: |
| get: |
| consumes: |
| - application/json |
| description: query event catalog detail info |
| parameters: |
| - description: event id |
| in: path |
| name: eventId |
| required: true |
| type: string |
| produces: |
| - application/json |
| responses: |
| "200": |
| description: OK |
| schema: |
| $ref: '#/definitions/main.QueryEventResponse' |
| "400": |
| description: Bad Request |
| "404": |
| description: Not Found |
| "500": |
| description: Internal Server Error |
| summary: query event catalog detail info |
| tags: |
| - Catalog |
| swagger: "2.0" |