Skip to content

Commit 7a1eeb4

Browse files
author
cibot
committed
Definitions Update search
1 parent 0e8c66f commit 7a1eeb4

File tree

1 file changed

+83
-62
lines changed

1 file changed

+83
-62
lines changed

alsdkdefs/apis/search/search.v2.yaml

Lines changed: 83 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ openapi: 3.0.2
22
info:
33
title: Alert Logic Universal Search Service
44
version: '2.0'
5-
description: "Service for submitting searches and getting their results.\nThis API is datatype agnostic as the selection of which datatype to search over is now done in the SQL via the FROM part of the query. "
5+
description: "Service for submitting searches and getting their results.\nThis API is datatype-agnostic as the selection of which datatype to search over is now done in the SQL via the FROM part of the query. "
66
servers:
77
- url: 'https://api.global-services.global.alertlogic.com'
88
description: production
@@ -17,7 +17,7 @@ paths:
1717
tags: []
1818
responses:
1919
'201':
20-
description: Created
20+
description: The search has been created and is executing.
2121
content:
2222
application/json:
2323
schema:
@@ -62,6 +62,24 @@ paths:
6262
- report
6363
default: auto
6464
in: query
65+
- name: timeframe
66+
in: query
67+
description: 'A number of seconds back from the current time to query. I.e. a value of 3600 indicates that the
68+
query should start from 1 hour ago (3600 seconds ago) until now.'
69+
schema:
70+
type: integer
71+
minimum: 1
72+
maximum: 31622400 # NOTE: This comes from MAX_TIMEFRAME in search_lib
73+
- name: start
74+
in: query
75+
description: 'The start of the time period to search as a Unix epoch timestamp.'
76+
schema:
77+
$ref: '#/components/schemas/EpochTimestamp'
78+
- name: end
79+
in: query
80+
description: 'The end of the time period to search as a Unix epoch timestamp.'
81+
schema:
82+
$ref: '#/components/schemas/EpochTimestamp'
6583
requestBody:
6684
content:
6785
text/plain:
@@ -95,7 +113,7 @@ paths:
95113
default: 'false'
96114
in: query
97115
description: Return search execution details
98-
- name: offest
116+
- name: offset
99117
schema:
100118
type: integer
101119
in: query
@@ -161,26 +179,62 @@ components:
161179
required: true
162180
description: AIMS Account Id
163181
schemas:
182+
EpochTimestamp:
183+
type: integer
184+
minimum: 0
185+
MessagesParams:
186+
title: MessagesParams
187+
type: object
188+
required:
189+
- ids
190+
properties:
191+
ids:
192+
type: array
193+
items:
194+
type: string
195+
fields:
196+
type: string
197+
tokens_offsets:
198+
type: string
199+
enum:
200+
- 'true'
201+
- 'false'
202+
default: 'false'
203+
properties:
204+
type: string
205+
enum:
206+
- 'true'
207+
- 'false'
208+
default: 'false'
209+
MessagesResponse:
210+
title: Messages
211+
type: array
212+
required:
213+
- id
214+
- fields
215+
items:
216+
type: object
217+
properties:
218+
id:
219+
type: object
220+
properties:
221+
msgid:
222+
type: string
223+
aid:
224+
type: integer
225+
account:
226+
type: integer
227+
fields:
228+
type: object
229+
error:
230+
type: object
164231
SearchCreated:
165232
title: SearchCreated
166233
type: object
167234
properties:
168235
search_uuid:
169236
type: string
170237
description: The unique id for the search request
171-
SearchFailed:
172-
title: SearchFailed
173-
type: object
174-
properties:
175-
search_status:
176-
type: string
177-
enum:
178-
- failed
179-
status_details:
180-
type: string
181-
description: 'User friendly status '
182-
details:
183-
$ref: '#/components/schemas/SearchDetails'
184238
SearchDetails:
185239
title: SearchDetails
186240
type: object
@@ -202,6 +256,19 @@ components:
202256
description: Last update to the search in Epoch
203257
stats:
204258
$ref: '#/components/schemas/SearchStats'
259+
SearchFailed:
260+
title: SearchFailed
261+
type: object
262+
properties:
263+
search_status:
264+
type: string
265+
enum:
266+
- failed
267+
status_details:
268+
type: string
269+
description: 'User friendly status '
270+
details:
271+
$ref: '#/components/schemas/SearchDetails'
205272
SearchStats:
206273
title: SearchStats
207274
type: object
@@ -234,52 +301,6 @@ components:
234301
type: integer
235302
sorts_executed:
236303
type: integer
237-
MessagesParams:
238-
title: MessagesParams
239-
type: object
240-
required:
241-
- ids
242-
properties:
243-
ids:
244-
type: array
245-
items:
246-
type: string
247-
fields:
248-
type: string
249-
tokens_offsets:
250-
type: string
251-
enum:
252-
- 'true'
253-
- 'false'
254-
default: 'false'
255-
properties:
256-
type: string
257-
enum:
258-
- 'true'
259-
- 'false'
260-
default: 'false'
261-
MessagesResponse:
262-
title: Messages
263-
type: array
264-
required:
265-
- id
266-
- fields
267-
items:
268-
type: object
269-
properties:
270-
id:
271-
type: object
272-
properties:
273-
msgid:
274-
type: string
275-
aid:
276-
type: integer
277-
account:
278-
type: integer
279-
fields:
280-
type: object
281-
error:
282-
type: object
283304
securitySchemes:
284305
X-AIMS-Auth-Token:
285306
name: X-AIMS-Auth-Token

0 commit comments

Comments
 (0)