Skip to content

Instantly share code, notes, and snippets.

@nikitavoloboev
Last active May 21, 2024 17:23
Show Gist options
  • Save nikitavoloboev/39f667045e503fb170b245a14dc2209c to your computer and use it in GitHub Desktop.
Save nikitavoloboev/39f667045e503fb170b245a14dc2209c to your computer and use it in GitHub Desktop.
kuskus-go-openapi.json
{"components":{"requestBodies":{"MyInput":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MyInput"}}},"description":"Request body for main.MyInput","required":true}},"schemas":{"MyInput":{"properties":{"name":{"type":"string"}},"type":"object"},"MyOutput":{"properties":{"message":{"type":"string"}},"type":"object"},"string":{"type":"string"}}},"info":{"description":"OpenAPI","title":"OpenAPI","version":"0.0.1"},"openapi":"3.0.3","paths":{"/get":{"get":{"description":"controller: main.getName","operationId":"GET /get:getName","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/string"}}},"description":"OK"},"default":{"description":""}},"summary":"getName","tags":["string"]}},"/post":{"post":{"description":"controller: main.sayHello","operationId":"POST /post:sayHello","requestBody":{"$ref":"#/components/requestBodies/MyInput"},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MyOutput"}}},"description":"OK"},"default":{"description":""}},"summary":"sayHello","tags":["MyOutput"]}}}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment