-
Notifications
You must be signed in to change notification settings - Fork 0
/
api.yaml
81 lines (72 loc) · 2.08 KB
/
api.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
openapi: 3.0.3
info:
title: API for scanner
description: |-
This is API to run **brakeman** scanner
Some useful links:
- [https://github.com/presidentbeef/brakeman](https://github.com/presidentbeef/brakeman)
- [https://hub.docker.com/r/presidentbeef/brakeman](https://hub.docker.com/r/presidentbeef/brakeman)
- [https://brakemanscanner.org/docs/](https://brakemanscanner.org/docs/)
- [https://github.com/manojbinjola/ruby-project](https://github.com/manojbinjola/ruby-project)
contact:
email: [email protected]
version: 0.0.1
servers:
- url: http://replace.me
- url: http://localhost:80
tags:
- name: Scanner
description: Run scan against the ruby code
externalDocs:
description: Find out more
url: https://github.com/presidentbeef/brakeman
paths:
/:
get:
tags:
- Scanner
summary: Get the report
description: Returns report from the server
responses:
'200':
description: successful operation
'404':
description: File not found
post:
tags:
- Scanner
summary: Run the scanner
description: Run the scanner against the ruby code
requestBody:
description: Run scan
content:
application/json:
schema:
$ref: '#/components/schemas/RunScan'
required: true
responses:
'200':
description: Successful operation
content:
application/json:
schema:
$ref: '#/components/schemas/RunScan'
'400':
description: Invalid input
components:
schemas:
RunScan:
type: object
properties:
source_code_url:
type: string
description: SCM repo with the code to scan
example: https://github.com/manojbinjola/ruby-project
lang:
type: string
description: Code Programming language
example: ruby
scanner_name:
type: string
description: Scanner name
example: brakeman