-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathapi.yml
169 lines (169 loc) · 4.04 KB
/
api.yml
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
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
openapi: 3.0.1
info:
title: Prometheus exporter
description: Export summary statistics and flow metrics in Prometheus format. See [RESTflow API](../../../api/index.html) for additional Prometheus exporters.
contact:
name: sFlow-RT.com
url: https://sflow-rt.com/
version: 1.0.0
paths:
/export.js/statistics/{group}/{agent}/{metric}/txt:
get:
tags:
- Statistics
summary: Get summary statistics
parameters:
- name: group
in: path
description: Label used to group statistics
required: true
schema:
type: string
example: cluster
- name: agent
in: path
description: IP address(es) or ALL or TOPOLOGY
required: true
style: simple
explode: false
schema:
type: array
items:
type: string
example:
- ALL
- name: metric
description: Metric name(s)
in: path
required: true
style: simple
explode: false
schema:
type: array
items:
type: string
example:
- max:load_one
- name: filter
in: query
description: Filter data sources
required: false
style: form
schema:
type: object
items:
type: array
items:
type: string
responses:
200:
description: OK
content:
text/plain:
schema:
type: string
example: sflow_max_load_one{group="cluster"} 11.2
/export.js/flows/{agent}/txt:
get:
tags:
- Flows
summary: Get flow values
parameters:
- name: agent
in: path
description: IP address(es) or ALL or TOPOLOGY
required: true
style: simple
explode: false
schema:
type: array
items:
type: string
example:
- ALL
- name: metric
in: query
description: Metric name
required: true
schema:
type: string
- name: key
in: query
description: Flow key(s)
required: true
style: form
explode: false
schema:
type: array
items:
type: string
example:
- ipsource
- name: value
in: query
description: Flow value
required: true
schema:
type: string
example: bytes
- name: filter
in: query
description: Filter flow attributes
required: false
schema:
type: string
- name: n
in: query
description: Number of largest flow entries to maintain
required: false
schema:
type: integer
- name: t
in: query
description: Smooting factor (in seconds)
required: false
schema:
type: integer
- name: label
in: query
description: Label flow key(s)
required: false
style: form
explode: false
schema:
type: array
items:
type: string
- name: aggMode
in: query
description: Method of aggregating duplicate flow records
required: false
schema:
type: string
enum: [sum,max,edge,core]
- name: maxFlows
in: query
description: Maximum number of flow records to return
required: false
schema:
type: integer
- name: minValue
in: query
description: Only report flows exceeding specified value
required: false
schema:
type: float
- name: scale
in: query
description: Scale values by specified amount
required: false
schema:
type: float
responses:
200:
description: OK
content:
text/plain:
schema:
type: string
example: pair{src="10.0.0.1",dst="10.0.0.2"} 10.1