This repository has been archived by the owner on Mar 26, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 18
/
swagger.yaml
154 lines (152 loc) · 4.2 KB
/
swagger.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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
# Example YAML to get you started quickly.
# Be aware that YAML has indentation based scoping.
# Code completion support is available so start typing for available options.
swagger: '2.0'
# This is your document metadata
info:
version: "0.7.0"
title: Checks-Out
securityDefinitions:
CookieSession:
type: apiKey
in: header
name: user_sess
HeaderSession:
type: apiKey
in: header
name: Authorization
QuerySession:
type: apiKey
in: query
name: access_token
# Describe your paths here
paths:
/api/count:
# This is a HTTP operation
get:
# Describe this verb here. Note: you can use markdown
description: |
Number of public and private repositories.
responses:
# Response code
200:
description: count
# A schema describing your response object.
# Use JSON Schema format
schema:
type: number
/api/repos:
# This is a HTTP operation
get:
# Describe this verb here. Note: you can use markdown
description: |
Metadata about the public GitHub repositories
registered with this service. This endpoint is
enabled if the CHECKS_OUT_SUNLIGHT environment variable
is set.
produces:
- application/json
responses:
# Response code
200:
description: repositories
# A schema describing your response object.
# Use JSON Schema format
schema:
type: array
description: Repos
items:
description: Repo
properties:
id:
type: number
owner:
type: string
name:
type: string
slug:
type: string
link_url:
type: string
private:
type: boolean
/api/repos/{owner}/{repo}/config:
get:
# Describe this verb here. Note: you can use markdown
description: |
Parses repository configuration file
and returns a complete configuration with
default sections populated.
parameters:
- name: owner
in: path
required: true
description: user or organization
type: string
- name: repo
in: path
required: true
description: repository name
type: string
security:
- CookieSession: [ ]
- HeaderSession: [ ]
- QuerySession: [ ]
produces:
- application/json
responses:
# Response code
200:
description: configuration
# A schema describing your response object.
# Use JSON Schema format
schema:
description: ChecksOutConfig
type: object
/api/repos/{owner}/{repo}/maintainers:
get:
# Describe this verb here. Note: you can use markdown
description: |
Parses repository MAINTAINERS configuration file
and returns the populated group information.
parameters:
- name: owner
in: path
required: true
description: user or organization
type: string
- name: repo
in: path
required: true
description: repository name
type: string
security:
- CookieSession: [ ]
- HeaderSession: [ ]
- QuerySession: [ ]
produces:
- application/json
responses:
# Response code
200:
description: maintainers
# A schema describing your response object.
# Use JSON Schema format
schema:
description: Maintainers
type: object
/version:
# This is a HTTP operation
get:
# Describe this verb here. Note: you can use markdown
description: |
Version information. This endpoint is enabled if the
CHECKS_OUT_SUNLIGHT environment variable is set.
responses:
# Response code
200:
description: version
# A schema describing your response object.
# Use JSON Schema format
schema:
type: string