Swagger open api macro |
---|
swagger: "2.0" info: version: "0.0.1" title: ARES Kudo API server # during dev, should point to your local machine host: localhost:3000 # basePath prefixes all resource paths basePath: /api # tags: - name: ARES Kudo Required description: Required APIs to load and store a drawing - name: ARES Kudo Optional description: Optional APIs to improve interactions for loading and storing a drawing - name: File Sessions description: Optional File Session Handling - name: Commenting description: API support for commenting panel - name: User Sessions description: Optional User Session Handling - name: Block Library description: API support for Block Library 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/json parameters: fileId: name: fileId in: path description: The id of the file required: true type: string libIdsessionId: name: libIdsessionid in: pathheader description: Thethe iduser ofsessionId the library required: true type: string itemIdthreadId: name: itemIdthreadId in: path description: Thethe idcomment ofthread the block required: true type: string ownerTypemarkupId: name: ownerTypemarkupId in: headerpath description: Type of the library (PUBLIC/USER/ORG)markup required: falsetrue type: string sessionIdcommentId: name: sessionidcommentId in: headerpath description: the usercomment sessionId required: true type: string threadIdattachmentId: name: threadIdattachmentId in: path description: the commentattachment thread required: true type: string markupIdoptionalSessionId: name: markupIdsessionid in: pathheader description: the user markupsessionId required: truefalse type: string commentIdpaths: name/files/{fileId}/diffs: commentId inparameters: path description: the- comment $ref: '#/parameters/fileId' required: true - $ref: type: string'#/parameters/optionalSessionId' attachmentId:# binds a127 app logic to name:a attachmentIdroute inx-swagger-router-controller: pathfiles descriptionget: the attachment requireddescription: trueReturns file content type: string optionalSessionId:# used as the method name: of sessionidthe controller in: header operationId: diffs_get description: the user sessionId tags: required: false type:- stringARES paths:Kudo Required /library/blocks: parametersresponses: - $ref: "#/parameters/optionalSessionId200": - $ref: "#/parameters/ownerType" description: Success x-swagger-router-controller: blocks getschema: description: Returns block libraries required: operationId: libraries_get tags: - status - Block Library responses:- baseContent "200": properties: description: Success status: schema: $ref: "#/definitions/LibrariesResponse" type: string default: descriptiondefault: Error"ok" schema: baseContent: $ref: "#/definitions/ErrorResponse" /library/blocks/{libId}/items: type: string parameters: - $ref: "#/parameters/libId" - $refdescription: "#/parameters/optionalSessionId" x-swagger-router-controller: blocksBase64 encoded content of file get: description: Returns# blocksresponses ofmay afall librarythrough to errors operationId: blocks_get "404": tags: description: Error - Block Library responsesschema: "200": $ref: "#/definitions/ErrorResponse" put: description: SuccessUpdate file content # used schema:as the method name of the controller $refoperationId: "#/definitions/BlocksResponse"diffs_put tags: default: - ARES Kudo Required description: Error parameters: - schemaname: body in: $ref: "#/definitions/ErrorResponse"body /library/blocks/{libId}/items/{itemId}/content: parametersrequired: true - $ref: "#/parameters/libId" schema: - $refrequired: "#/parameters/itemId" - $ref: "#/parameters/optionalSessionId" - baseContent - in: query nameproperties: fileType required: false baseContent: default: "dwg" type: string x-swagger-router-controller: blocks getdescription: Base64 encoded content of file description: Returns block file operationId: block_getfile tagsresponses: - Block Library"200": producesdescription: Success - application/octet-stream schema: responses: required: "200": description: Success - status default: - changeId description: Error schemaproperties: $ref status: "#/definitions/ErrorResponse" /library/blocks/{libId}/items/{itemId}/thumbnail: parameters: - $reftype: "#/parameters/libId"string - $ref: "#/parameters/itemId" - $refdefault: "#/parameters/optionalSessionIdok" - in: query namechangeId: fileType required: false type: string default: "png" # responses type: stringmay fall through to errors x-swagger-router-controller: blocks default: get: description: ReturnsError block thumbnail operationIdschema: block_getthumbnail tags: $ref: "#/definitions/ErrorResponse" -/files: Block Library parameters: produces: - $ref: '#/parameters/optionalSessionId' - application/octet-stream x-swagger-router-controller: files responsespost: description: "200":Create/Update a file # used as the method description:name Successof the controller defaultoperationId: post_file tags: description: Error - ARES Kudo Required schema: consumes: $ref: "#/definitions/ErrorResponse" - multipart/form-data /files/{fileId}/diffs parameters: parameters: - in: header - $refname: "#/parameters/fileId"fileId - $refdescription: "#/parameters/optionalSessionId" # binds a127 app logic to a route x-swagger-router-controller: filesID of the file (New file will be created if this value is not specified) getrequired: false description: Returns file content type: string # used as the method name- of the controllerin: formData operationId: diffs_get name: file deprecated: true tagsrequired: true - ARES Kudotype: Optionalfile responses: "200": description: Success schema: required: - statusid - baseContentfilename properties: - isNewFile status: - changeId typeproperties: string id: default: "ok" baseContenttype: string typefilename: string type: description:string Base64 encoded content of file isNewFile: # responses may fall through to errors type: boolean "404": descriptionchangeId: Error schema: type: string $ref: "#/definitions/ErrorResponse" put:# responses may fall through to errors description: Update filedefault: content # used as thedescription: methodError name of the controller operationIdschema: diffs_put deprecated: true tags$ref: "#/definitions/ErrorResponse" /files/{fileId}/data: - ARESparameters: Kudo Optional - $ref: parameters:'#/parameters/fileId' - name$ref: body'#/parameters/optionalSessionId' # binds a127 app logic to in:a bodyroute x-swagger-router-controller: files required: true get: schemadescription: Returns file content # used as required:the method name of the controller operationId: data_get - baseContent tags: properties:- ARES Kudo Required produces: baseContent: - application/octet-stream responses: type: string "200": description: Success description: Base64 encoded content of file # responses may fall through to responses:errors "200404": description: SuccessError schema: required$ref: "#/definitions/ErrorResponse" /files/{fileId}/xref/search: # binds a127 -app statuslogic to a route x-swagger-router-controller: files post: - changeId description: XRef search properties: # used as the method name of the controller status: operationId: xref_search tags: type: string- ARES Kudo Optional parameters: - default$ref: "ok"'#/parameters/fileId' - $ref: '#/parameters/optionalSessionId' changeId: - name: body type in: stringbody # responsesrequired: maytrue fall through to errors schema: default: descriptionrequired: Error schema: - path $ref: "#/definitions/ErrorResponse" /filesproperties: parameters: - $ref: "#/parameters/optionalSessionId" path: x-swagger-router-controller: files post: descriptiontype: Create/Updatearray a file # used as the method name of the controllerdescription: xrefs paths to search operationId: post_file tags: - ARES Kudo Required consumesitems: - multipart/form-data parameters: type: string - inresponses: header name: fileId"200": description: IDSuccess of the file (New file will be created if this value isschema: not specified) requiredtype: falsearray type: string items: - in: formData type: object name: file requiredproperties: true type: file responsespath: "200": descriptiontype: Successstring schema: files: required: type: array - id - filename items: - isNewFile type: object - changeId properties: id: "_id": type: string filenametype: string # responses may fall through to errors type: string default: isNewFile: description: Error typeschema: boolean changeId$ref: "#/definitions/ErrorResponse" /files/{fileId}/preview: # binds a127 app logic to a route typex-swagger-router-controller: stringfiles post: # responses may falldescription: throughOptionally tohandle errorsreceiving updates previews default:# used as the method name of the controller description: Error operationId: preview_post schematags: - ARES Kudo Optional $ref: "#/definitions/ErrorResponse" /files/{fileId}/data: parameters: parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/optionalSessionId"' # binds a127 app logic- toin: aformData route x-swagger-router-controller: files name: file get: description: Returns file contentrequired: true # used as the method name of the controller type: file responses: operationId"200": data_get tagsdescription: Success - ARES Kudo Required schema: producestype: object - application/octet-stream properties: responsesstatus: "200": type: string description default: Success"ok" # responses may fall through to errors "404"default: description: Error schema: $ref: "#/definitions/ErrorResponse" /files/{fileId}/xref/searchinfo: # binds a127 app logic to a route x-swagger-router-controller: files postget: description: XRefReturns file searchinformation # used as the method name of the controller operationId: xrefinfo_searchget tags: - ARES Kudo OptionalRequired parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/optionalSessionId"' responses: - name: body in"200": body requireddescription: trueSuccess schema: required: - pathstatus propertiestype: object pathproperties: typestatus: array descriptiontype: xrefsstring paths to search default: "ok" items: filename: type: string responses: type: string "200": descriptionfolderId: Success schema: type: string type: array owner: items: type: string type: object # responses may fall through to errors properties: "401": pathdescription: User is not autenticated schema: type: string $ref: "#/definitions/ErrorResponse" files"404": description: File is not found type: array schema: items$ref: "#/definitions/ErrorResponse" type: object properties: "_id": type: string # responses may fall through to errors default: description: Error schema: $ref: "#/definitions/ErrorResponse" /files/{fileId}/preview: # binds a127 app logic to a route x-swagger-router-controller: files post: description: Optionally handle receiving updates previews # used as the method name of the controller operationId: preview_post tags: - ARES Kudo Optional parameters: - $ref: "#/parameters/fileId" - $ref: "#/parameters/optionalSessionId" - in: formData name: file required: true type: file responses: "200": description: Success schema: type: object properties: status: type: string default: "ok" # responses may fall through to errors default: description: Error schema: $ref: "#/definitions/ErrorResponse" /files/{fileId}/info: # binds a127 app logic to a route x-swagger-router-controller: files get: description: Returns file information # used as the method name of the controller operationId: info_get tags: - ARES Kudo Required parameters: - $ref: "#/parameters/fileId" - $ref: "#/parameters/optionalSessionId" responses: "200": description: Success schema: required: - status type: object properties: status: type: string default: "ok" filename: type: string folderId: type: string owner: type: string # responses may fall through to errors "401": description: User is not autenticated schema: $ref: "#/definitions/ErrorResponse" "404": description: File is not found schema: $ref: "#/definitions/ErrorResponse" /files/{fileId}/session: # binds a127 app logic to a route parameters: - $ref: "#/parameters/fileId" - $ref: "#/parameters/sessionId" x-swagger-router-controller: files_sessions get: description: get file sessions # used as the method name of the controller operationId: session_get tags: - File Sessions responses: "200": description: Success schema: # a pointer to a definition $ref: "#/definitions/SessionsResponse" # responses may fall through to errors default/files/{fileId}/session: # binds a127 app logic to a route parameters: - description$ref: Error'#/parameters/fileId' - schema$ref: '#/parameters/sessionId' $ref: "#/definitions/ErrorResponse"x-swagger-router-controller: files_sessions postget: description: Createget file session. Sessions need to be either of type "view" or "edit"sessions # used as the method name of the controller operationId: session_post tags: - File Sessions parametersoperationId: session_get tags: - name: body - File Sessions in: body responses: required"200": true schemadescription: Success requiredschema: # a -pointer modeto a definition properties: $ref: "#/definitions/SessionsResponse" # responses may mode:fall through to errors default: type: string description: Error descriptionschema: Type of session requested $ref: "#/definitions/ErrorResponse" enumpost: [view, edit] description: Create file session. Sessions need to be either of fileId:type "view" or "edit" # used as the method name of type:the stringcontroller operationId: session_post descriptiontags: fileId for the file for which the session is- beingFile requestedSessions responsesparameters: "200"- name: body description in: Successbody schemarequired: true requiredschema: -required: status - "_id"mode properties: statusmode: type: string defaultdescription: "ok"Type of session requested "_id": enum: [view, edit] type: string fileId: # responses may fall through to errors defaulttype: string description: Error description: fileId for the file schema:for which the session is being requested $ref: "#/definitions/ErrorResponse" responses: delete: description"200": delete file session # useddescription: asSuccess the method name of the controller operationIdschema: session_delete parameters: required: - name: body - in:status body required: true - "_id" schema: properties: required: status: - mode type: string properties: modedefault: "ok" type"_id": string descriptiontype: Typestring of session requested # responses may fall through to errors enum: [view, edit] default: tags: description: Error - File Sessions responsesschema: "200": $ref: "#/definitions/ErrorResponse" descriptiondelete: Success description: delete file session schema: # used as the method name of the #controller a pointer to a definition operationId: session_delete $ref: "#/definitions/SessionsResponse"parameters: #- responsesname: maybody fall through to errors in: body default: descriptionrequired: Errortrue schema: $refrequired: "#/definitions/ErrorResponse" /auth: # binds a127 app logic- tomode a route x-swagger-router-controller: auth getproperties: description: validate user session mode: # used as the method name of the controller tagstype: string - User Sessions operationIddescription: auth_getType of session requested parameters: - $refenum: "#/parameters/optionalSessionId"[view, edit] responsestags: # responses may fall through to errors- File Sessions responses: "200": description: Success schema: type:# objecta pointer to a definition properties: $ref: "#/definitions/SessionsResponse" # status:responses may fall through to errors typedefault: string defaultdescription: "ok" Error 401: schema: description: Authorization information is missing or invalid.$ref: "#/definitions/ErrorResponse" /usersauth: # binds a127 app logic to a route x-swagger-router-controller: usersauth get: description: Returnsvalidate user objectsession # used as the method name of the controller operationIdtags: users_get tags: - User Sessions - User SessionsoperationId: auth_get parameters: - $ref: "'#/parameters/sessionId"optionalSessionId' responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" 401: description: Authorization information is missing or invalid. /users: # binds a127 app logic to a route x-swagger-router-controller: users get: description: Returns user object # used as the method name results:of the controller operationId: users_get typetags: array - User Sessions itemsparameters: - $ref: '#/parameters/sessionId' typeresponses: object # responses may fall through to errors properties: "200": description: Success fname: schema: type: stringobject properties: description: first name status: surnametype: string default: "ok" type: string results: description: last name of usertype: array "_id"items: type: stringobject emailproperties: typefname: string licenseExpirationDatetype: string type description: integerfirst name preferencessurname: type: objectstring propertiesdescription: last name of user preferences "_displayid": type: string type: object email: properties: type: string graphicswinmodelbackgrndcolor: licenseExpirationDate: type: string type: integer defaultpreferences: White viewtype: object properties: type: object windowpreferences_display: type: object variables: properties: type: object graphicswinmodelbackgrndcolor: properties: type: string dynasnap: default: White type: string view: default: "63" put: descriptiontype: Returns user object # used as the method name of the controller operationId: users_put window: tags: - User Sessions parameters: type: - $ref: "#/parameters/sessionId"object - name: body in: body variables: required: true schema: type: object properties: preferences: properties: type: object description: user preferences dynasnap: properties: window: type: string type: object default: "63" propertiesput: description: Returns user object # used as the method name edit:of the controller operationId: users_put tags: type: object- User Sessions parameters: - $ref: '#/parameters/sessionId' properties: - name: body in: body dockwidgets: required: true schema: properties: type: object preferences: propertiestype: object description: user preferences layerwindow: properties: window: type: object type: object properties: edit: h: type: object typeproperties: string dockwidgets: description: height o the layerwindow responses: type: object # responses may fall through to errors "200": descriptionproperties: Success schema: type: object layerwindow: properties: status: type: object type: string default: "ok" /v1/files/{fileId}/annotations: properties: # binds a127 app logic to a route x-swagger-router-controller: comments get: description: Returns annotations for a file h: # used as the method name of the controller operationId: annotations_get tags: - Commenting type: string parameters: - $ref: "#/parameters/fileId" - $ref: "#/parameters/sessionId" - namedescription: timestampheight o the layerwindow typeresponses: integer # responses may in:fall querythrough to errors required"200": false description: timestampSuccess of last request to only send new items responsesschema: # responses may fall throughtype: toobject errors "200": properties: description: Success status: schema: type: objectstring properties: default: "ok" /v1/files/{fileId}/annotations: # binds status:a127 app logic to a route x-swagger-router-controller: comments typeget: string description: Returns annotations for a file default: "ok"# used as the method name of the controller resultsoperationId: annotations_get tags: type:- objectCommenting parameters: - properties:$ref: '#/parameters/fileId' - $ref: '#/parameters/sessionId' - timestampname: timestamp type: integer type: integer in: query required: false description: time of response description: timestamp of last request to only send new items commmentThreadsresponses: # responses may fall through to errors type: array "200": description: Success description: "" schema: type: object items: properties: typestatus: object markupstype: string default: "ok" type: array results: description: "" type: object items: properties: typetimestamp: object statustype: integer type description: stringtime of response defaultcommmentThreads: "ok" /v1/files/{fileId}/markups: # binds a127 app logic to a route x-swagger-router-controllertype: commentsarray get: description: Returns markups for a file description: "" # used as the method name of the controller operationId: markups_get items: tags: - Commenting parameterstype: object - $ref: "#/parameters/fileId" - $ref: "#/parameters/sessionId"markups: - name: timestamp type: integerarray in: query description: "" required: false description: timestamp of last request to only send newitems: items responses: # responses may fall through to errorstype: object "200": descriptionstatus: Success schema: type: string type: object propertiesdefault: "ok" /v1/files/{fileId}/markups: # binds a127 app logic to a route status: x-swagger-router-controller: comments get: typedescription: stringReturns markups for a file # used as the method name default: "ok"of the controller operationId: markups_get resultstags: - Commenting typeparameters: object - $ref: '#/parameters/fileId' properties: - $ref: '#/parameters/sessionId' - name: timestamp timestamp: type: integer in: query type: integer required: false description: timetimestamp of responselast request to only send new items responses: markups: # responses may fall through to errors "200": type: array description: Success descriptionschema: "" type: object items: properties: status: type: object type: string status: default: "ok" type: string results: default: "ok" /v1/files/{fileId}/commentThreads:type: object # binds a127 app logic to a route x-swagger-router-controller: comments properties: get: description: Returns comments for a file timestamp: # used as the method name of the controller operationId: commentThreads_get type: integer tags: - Commenting parametersdescription: time of response - $ref: "#/parameters/fileId" - $refmarkups: "#/parameters/sessionId" - name: timestamp type: integerarray in: query description: "" required: false description: timestamp of last request to only send newitems: items responses: # responses may fall through to errorstype: object "200": descriptionstatus: Success schema: type: string type: object propertiesdefault: "ok" /v1/files/{fileId}/commentThreads: # binds a127 app logic to a route status: x-swagger-router-controller: comments get: typedescription: stringReturns comments for a file # used as the method name default: "ok" of the controller operationId: commentThreads_get results tags: - Commenting typeparameters: object - $ref: '#/parameters/fileId' properties: - $ref: '#/parameters/sessionId' - name: timestamp timestamp: type: integer in: query type: integer required: false description: timetimestamp of responselast request to only send new items responses: commmentThreads: # responses may fall through to errors "200": type: array description: Success descriptionschema: "" type: object items: properties: typestatus: object statustype: string default: "ok" type: string results: default: "ok" /v1/files/{fileId}/commentThread: #type: bindsobject a127 app logic to a route x-swagger-router-controller: comments postproperties: description: Add a new commentThread for a file timestamp: # used as the method name of the controller operationId: commentThread_post type: integer tags: - Commenting parametersdescription: time of response - $ref: "#/parameters/fileId" - $refcommmentThreads: "#/parameters/sessionId" - name: body intype: bodyarray required: true description: "" schema: type: object items: properties: titletype: object type: string status: text: type: string type: string default: "ok" state/v1/files/{fileId}/commentThread: # binds a127 app logic to a route typex-swagger-router-controller: stringcomments post: description: Add a new commentThread enum: [ACTIVE, RESOLVED]for a file # used as the method name of the ids:controller operationId: commentThread_post typetags: array - Commenting itemsparameters: - $ref: '#/parameters/fileId' type: string responses: - $ref: '#/parameters/sessionId' # responses may- fallname: throughbody to errors "200"in: body description required: Successtrue schema: type: object properties: statustitle: type: string text: default: "ok" timestamptype: string type: integer state: description: time of response /v1/files/{fileId}/commentThread/{threadId}type: string # binds a127 app logic to a route x-swagger-router-controllerenum: comments[ACTIVE, RESOLVED] put: description: Update a commentThread ids: # used as the method name of the controller type: array operationId: commentThread_put tags: items: - Commenting parameters: - $reftype: "#/parameters/fileId"string responses: - $ref: "#/parameters/sessionId" # responses may fall -through $ref: "#/parameters/threadId"to errors - name"200": body indescription: bodySuccess requiredschema: true schematype: object typeproperties: object propertiesstatus: titletype: string type default: string"ok" texttimestamp: type: stringinteger idsdescription: time of response /v1/files/{fileId}/commentThread/{threadId}: # binds a127 app logic to type:a arrayroute x-swagger-router-controller: comments put: items description: Update a commentThread # used as the method name of the type:controller string responses:operationId: commentThread_put tags: # responses may fall through to errors - Commenting "200"parameters: - description$ref: Success'#/parameters/fileId' - schema$ref: '#/parameters/sessionId' - $ref: type: object'#/parameters/threadId' - name: body properties: in: body status: required: true typeschema: string type: object default: "ok" properties: timestamp: title: type: integer type: string description: time of response gettext: description: get a commentThread #type: string used as the method name of the controller operationIdids: commentThread_get tags: -type: Commentingarray parameters: - $refitems: "#/parameters/fileId" - $ref: "#/parameters/sessionId" - $reftype: "#/parameters/threadId"string responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response deleteget: description: Deleteget a commentcommentThread Thread # used as the method name of the controller operationId: commentThread_deleteget tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/threadId"' responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response /v1/files/{fileId}/commentThread/{threadId}/comment/{commentId}:type: integer # binds a127 app logic to a route x-swagger-router-controller: commentsdescription: time of response putdelete: description: UpdateDelete a comment Thread # used as the method name of the controller operationId: commentcommentThread_putdelete tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/threadId"' responses: - $ref: "#/parameters/commentId" # responses may fall -through name:to bodyerrors in"200": body requireddescription: trueSuccess schema: type: object properties: textstatus: type: string responses: default: #"ok" responses may fall through to errors "200"timestamp: description: Success type: integer description: time of schema:response /v1/files/{fileId}/commentThread/{threadId}/comment/{commentId}: # binds a127 app type:logic objectto a route x-swagger-router-controller: comments propertiesput: description: Update a comment status: # used as the method name of the controller typeoperationId: stringcomment_put tags: - default:Commenting "ok" parameters: timestamp- $ref: '#/parameters/fileId' - $ref: '#/parameters/sessionId' type: integer - $ref: '#/parameters/threadId' - description$ref: time of response'#/parameters/commentId' get: - name: body description: Retrieve a comment in: #body used as the method name of the controller required: true operationId: comment_get tagsschema: - Commenting type: object parameters: - $refproperties: "#/parameters/fileId" - $ref: "#/parameters/sessionId" text: - $ref: "#/parameters/threadId" - $reftype: "#/parameters/commentId"string responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response deleteget: description: DeleteRetrieve a comment # used as the method name of the controller operationId: comment_deleteget tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/threadId"' - $ref: "'#/parameters/commentId"' responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response /v1/files/{fileId}/commentThread/{threadId}/comment: # binds a127 app logic to a route x-swagger-router-controller: comments postdelete: description: PostDelete a newcomment comment # used as the method name of the controller operationId: comment_postdelete tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/threadId"' - name: body $ref: '#/parameters/commentId' responses: # responses may fall through to errors in"200": body requireddescription: trueSuccess schema: type: object properties: textstatus: type: string responses: default: #"ok" responses may fall through to errors "200"timestamp: description type: Successinteger schema: description: time of response type/v1/files/{fileId}/commentThread/{threadId}/comment: object # binds a127 app logic to a route properties: x-swagger-router-controller: comments post: statusdescription: Post a new comment # used as the method type:name stringof the controller operationId: comment_post defaulttags: "ok" - Commenting timestampparameters: - $ref: '#/parameters/fileId' type: integer - $ref: '#/parameters/sessionId' - $ref: '#/parameters/threadId' description: time of response /v1/files/{fileId}/markup- name: body # binds a127 app logic to ain: routebody x-swagger-router-controller: comments postrequired: true description: Add a new markup forschema: a file # used as the method nametype: ofobject the controller operationId: markup_post properties: tags: - Commenting text: parameters: - $ref: "#/parameters/fileId" type: string - $refresponses: "#/parameters/sessionId" # -responses name:may bodyfall through to errors in "200": body requireddescription: trueSuccess schema: type: object properties: titlestatus: type: string text default: "ok" timestamp: type: string statetype: integer type: string description: time of response /v1/files/{fileId}/markup: # binds a127 app logic to a route x-swagger-router-controller: comments enumpost: [ACTIVE, RESOLVED] description: Add a new markup for a file ids: # used as the method name of the controller typeoperationId: arraymarkup_post tags: - Commenting items: parameters: - $ref: '#/parameters/fileId' type: string - responses$ref: '#/parameters/sessionId' # responses- mayname: fallbody through to errors "200":in: body descriptionrequired: Successtrue schema: type: object properties: statustitle: type: string text: default: "ok" timestamptype: string typestate: integer descriptiontype: timestring of response /v1/files/{fileId}/markup/{markupId}: # binds a127 app logic to a routeenum: [ACTIVE, RESOLVED] x-swagger-router-controller: comments put: descriptionids: Update a markup # used as the method name of the controller operationId: markup_puttype: array tags: items: - Commenting parameters: - $reftype: "#/parameters/fileId"string responses: - $ref: "#/parameters/sessionId" # responses may fall -through $ref: "#/parameters/markupId"to errors - name"200": body indescription: bodySuccess requiredschema: true schematype: object type properties: object propertiesstatus: title: type: string typedefault: string"ok" texttimestamp: type: stringinteger idsdescription: time of response /v1/files/{fileId}/markup/{markupId}: # binds a127 app logic to a type:route array x-swagger-router-controller: comments put: itemsdescription: Update a markup # used as the method name of type:the stringcontroller responsesoperationId: markup_put tags: # responses may fall through to errors - Commenting "200"parameters: - description$ref: Success'#/parameters/fileId' - schema$ref: '#/parameters/sessionId' - type$ref: object'#/parameters/markupId' - propertiesname: body in: body status: required: true type: string schema: defaulttype: "ok"object timestampproperties: typetitle: integer type: description:string time of response get: descriptiontext: get a markup # used as the method name of thetype: controllerstring operationId: markup_get tagsids: - Commenting parameterstype: array - $ref: "#/parameters/fileId" - $refitems: "#/parameters/sessionId" - $reftype: "#/parameters/markupId"string responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response deleteget: description: deleteget a markup # used as the method name of the controller operationId: markup_deleteget tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/markupId"' responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response /v1/files/{fileId}/markup/{markupId}/comment/{commentId}: # binds a127 app logic to a route x-swagger-router-controller: comments putdelete: description: Updatedelete a markup comment # used as the method name of the controller operationId: markupcommentmarkup_putdelete tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/markupId"' responses: - $ref: "#/parameters/commentId" # responses -may name:fall bodythrough to errors in"200": body requireddescription: trueSuccess schema: type: object properties: textstatus: type: string responses: default: #"ok" responses may fall through to errors "200":timestamp: description type: Successinteger schemadescription: time of response /v1/files/{fileId}/markup/{markupId}/comment/{commentId}: type: object # binds a127 app logic to a route x-swagger-router-controller: comments propertiesput: description: Update a comment status: # used as the method name of the controller typeoperationId: stringmarkupcomment_put tags: - Commenting default: "ok" parameters: - timestamp$ref: '#/parameters/fileId' - $ref: '#/parameters/sessionId' type: integer - $ref: '#/parameters/markupId' - description$ref: time of response'#/parameters/commentId' get: - name: body description: Retrieve a markup comment in: body # used as the method name of the controller required: true operationId: markupcomment_get schema: tags: - Commenting type: object parameters: - $refproperties: "#/parameters/fileId" - $ref: "#/parameters/sessionId" text: - $ref: "#/parameters/markupId" - $reftype: "#/parameters/commentId"string responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response deleteget: description: DeleteRetrieve a markup comment # used as the method name of the controller operationId: markupcomment_deleteget tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "'#/parameters/markupId"' - $ref: "'#/parameters/commentId"' responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response /v1/files/{fileId}/markup/{markupId}/comment delete: # binds a127 app logic to a route description: Delete a markup comment # x-swagger-router-controller: comments post:used as the method name of the controller descriptionoperationId: Postmarkupcomment_delete a new markup comment tags: # used as the method name- ofCommenting the controller parameters: operationId: markupcomment_post - tags:$ref: '#/parameters/fileId' - Commenting $ref: '#/parameters/sessionId' - parameters:$ref: '#/parameters/markupId' - $ref: "'#/parameters/fileId"commentId' responses: # responses -may $ref: "#/parameters/sessionId" fall through to errors - $ref: "#/parameters/markupId"200": - namedescription: bodySuccess inschema: body requiredtype: object true schemaproperties: type: object status: properties: type: string text: default: "ok" type: string responsestimestamp: # responses may fall through to errors type: integer "200": description: Successtime of response /v1/files/{fileId}/markup/{markupId}/comment: # binds schema:a127 app logic to a route x-swagger-router-controller: comments type: object post: description: Post a new properties:markup comment # used as the method name status:of the controller operationId: markupcomment_post typetags: string - Commenting defaultparameters: "ok" - $ref: '#/parameters/fileId' timestamp: - $ref: '#/parameters/sessionId' - type$ref: integer'#/parameters/markupId' - name: body description: time of response /v1/files/{fileId}/attachment:in: body x-swagger-router-controller: comments postrequired: true description: Create a markup attachment schema: # used as the method name of the controllertype: object operationId: attachment_post tagsproperties: - Commenting consumestext: - multipart/form-data parameterstype: string responses: - $ref: "#/parameters/fileId" # responses may - $ref: "#/parameters/sessionId" fall through to errors - in"200": formData namedescription: attachmentSuccess requiredschema: true type: file object responses: "200"properties: description: Success status: schema: requiredtype: string - status default: "ok" - changeId timestamp: properties: type: integer status: description: time of response type/v1/files/{fileId}/attachment: string x-swagger-router-controller: comments post: defaultdescription: "ok" Create a markup attachment # used as the method name changeId:of the controller operationId: attachment_post typetags: string - #Commenting responses may fall through to errors consumes: default: - multipart/form-data descriptionparameters: Error - schema$ref: '#/parameters/fileId' - $ref: "'#/definitions/ErrorResponse"parameters/sessionId' /v1/files/{fileId}/attachments: x-swagger-router-controller- in: commentsformData get: descriptionname: Retrieveattachment all attachments # used asrequired: thetrue method name of the controller operationIdtype: attachments_getfile tagsresponses: - Commenting"200": parametersdescription: Success - $refschema: "#/parameters/fileId" - $refrequired: "#/parameters/sessionId" responses: - status # responses may fall through to errors - changeId "200": descriptionproperties: Success schemastatus: type: object type: string properties: default: "ok" status: changeId: type: string type: string default: "ok"# responses may fall through to errors timestampdefault: description: Error type: integer schema: description $ref: time of response"#/definitions/ErrorResponse" /v1/files/{fileId}/attachments/{attachmentId}: # binds a127 app logic to a route x-swagger-router-controller: comments get: description: Retrieve attachmentall attachments # used as the method name of the controller operationId: attachmentattachments_get tags: - Commenting parameters: - $ref: "'#/parameters/fileId"' - $ref: "'#/parameters/sessionId"' - $ref: "#/parameters/attachmentId" responses: # responses may fall through to errors "200": description: Success schema: type: object properties: status: type: string default: "ok" timestamp: type: integer description: time of response /swagger/v1/files/{fileId}/attachments/{attachmentId}: x-swagger-pipe: swagger_raw # complexbinds objectsa127 haveapp schemalogic definitionsto definitions: SessionsResponse:a route requiredx-swagger-router-controller: comments get: - status description: Retrieve attachment - results properties: # used as the method name status:of the controller typeoperationId: stringattachment_get defaulttags: "ok" results: - Commenting typeparameters: array - items$ref: '#/parameters/fileId' - type$ref: object'#/parameters/sessionId' - properties$ref: '#/parameters/attachmentId' responses: mode: # responses may fall through to errors type: string "200": enumdescription: [view, edit]Success usernameschema: type: stringobject sessionIdproperties: typestatus: string userId: type: string type: string LibrariesResponse: requireddefault: - status"ok" - results propertiestimestamp: status: type: stringinteger default: "ok" resultsdescription: time of response /swagger: type: array x-swagger-pipe: swagger_raw # complex objects have schema definitions itemsdefinitions: SessionsResponse: required: type: object - status properties:- results properties: idstatus: type: string default: "ok" name: results: type: stringarray BlocksResponse: requireditems: - status type: -object results properties: statusproperties: type: string defaultmode: "ok" results: type: array string items: typeenum: object[view, edit] properties: username: id: type: string type: string sessionId: name: type: string thumbnail userId: type: string ErrorResponse: required: - message properties: message: type: string errrorId: type: string |
Content Comparison
General
Content
Integrations