This repository was archived by the owner on Dec 10, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +33
-3
lines changed Expand file tree Collapse file tree 2 files changed +33
-3
lines changed Original file line number Diff line number Diff line change 11import * as path from 'path' ;
22import * as Serverless from 'serverless' ;
33import { DefinitionGenerator } from '../DefinitionGenerator' ;
4- import { merge } from '../utils' ;
4+ import _ = require ( 'lodash' ) ;
55
66class ServerlessInterface extends Serverless {
77 public service : any = { } ;
@@ -49,7 +49,7 @@ describe('OpenAPI Documentation Generator', () => {
4949
5050 const funcConfigs = sls . service . getAllFunctions ( ) . map ( ( functionName ) => {
5151 const func = sls . service . getFunction ( functionName ) ;
52- return merge ( { _functionName : functionName } , func ) ;
52+ return _ . merge ( { _functionName : functionName } , func ) ;
5353 } ) ;
5454
5555 docGen . readFunctions ( funcConfigs ) ;
Original file line number Diff line number Diff line change @@ -189,13 +189,43 @@ components:
189189info :
190190 title : ' '
191191 description : ' '
192- version : ae88c557-65e0-4feb-a885-ebe66a58cca8
192+ version : 96d3d004-1a24-4384-9df7-1e7416393223
193193paths :
194194 /create :
195195 post :
196196 operationId : createUser
197197 summary : Create User
198198 description : Creates a user and then sends a generated password email
199+ requestBody :
200+ content :
201+ application/json :
202+ schema :
203+ $ref : ' #/components/schemas/PutDocumentRequest'
204+ description : A user information object
205+ parameters :
206+ - name : username
207+ in : path
208+ description : The username for a user to create
209+ required : true
210+ schema :
211+ type : string
212+ pattern : ' ^[-a-z0-9_]+$'
213+ - name : membershipType
214+ in : query
215+ description : The user's Membership Type
216+ required : false
217+ allowEmptyValue : false
218+ schema :
219+ type : string
220+ enum :
221+ - premium
222+ - standard
223+ - name : SessionId
224+ in : cookie
225+ description : A Session ID variable
226+ required : false
227+ schema :
228+ type : string
199229 responses :
200230 ' 201 ' :
201231 description : A user object along with generated API Keys
You can’t perform that action at this time.
0 commit comments