You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 14, 2022. It is now read-only.
swagger: "2.0"info:
version: "1.1.1"title: API App# during dev, should point to your local machinehost: localhost:8080# basePath prefixes all resource pathsbasePath: /#schemes:
# tip: remove http to make production-grade
- http
- https# format of bodies a client can send (Content-Type)consumes:
- application/json# format of the responses to the client (Accepts)produces:
- application/jsonpaths:
/hello:
# binds a127 app logic to a routex-swagger-router-controller: hello_worldget:
description: Returns 'Hello' to the caller# used as the method name of the controlleroperationId: helloparameters:
- name: namein: querydescription: The name of the person to whom to say hellorequired: falsetype: stringresponses:
"200":
description: Successschema:
# a pointer to a definition$ref: "#/definitions/HelloWorldResponse"# responses may fall through to errorsdefault:
description: Errorschema:
$ref: "#/definitions/ErrorResponse"/users:
# binds a127 app logic to a routex-swagger-router-controller: users_apiget:
description: Returns 'users' to the caller# used as the method name of the controlleroperationId: usersparameters:
# - name: name# - name: user# - user: user & error name# - user: name & error name# - name: users
- name: namein: querydescription: The name of the person to whom to say usersrequired: falsetype: stringresponses:
"200":
description: Successschema:
# a pointer to a definition$ref: "#/definitions/UserApiResponse"# responses may fall through to errorsdefault:
description: Errorschema:
$ref: "#/definitions/ErrorResponse"/swagger:
x-swagger-pipe: swagger_raw# complex objects have schema definitionsdefinitions:
HelloWorldResponse:
required:
- messageproperties:
message:
type: stringUserApiResponse:
required:
# 202 & respond
- messageproperties:
message:
type: stringErrorResponse:
required:
- messageproperties:
message:
type: string
# swagger configuration file# values in the swagger hash are system configuration for swagger-nodeswagger:
fittingsDirs: [ api/fittings ]defaultPipe: nullswaggerControllerPipe: swagger_controllers # defines the standard processing pipe for controllers# values defined in the bagpipes key are the bagpipes pipes and fittings definitions# (see https://github.com/apigee-127/bagpipes)bagpipes:
_router:
name: swagger_routermockMode: falsemockControllersDirs: [api/mocks]controllersDirs: [api/controllers]_swagger_validate:
name: swagger_validatorvalidateResponse: false# validateResponse: true# pipe for all swagger-node controllersswagger_controllers:
- onError: json_error_handler
- cors
- swagger_security
- _swagger_validate
- express_compatibility
- _router# pipe to serve swagger (endpoint is in swagger.yaml)swagger_raw:
name: swagger_raw# any other values in this file are just loaded into the config for application access...
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
bug & help wanted
http://localhost:8080/users?name=xgqfrms
codes
The text was updated successfully, but these errors were encountered: