-
Notifications
You must be signed in to change notification settings - Fork 51
/
openapi.yaml
147 lines (147 loc) · 3.78 KB
/
openapi.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
openapi: 3.0.0
servers:
- description: SwaggerHub API Auto Mocking
url: https://virtserver.swaggerhub.com/nuclia/nucliadb/1.0.0
- description: SwaggerHub API Auto Mocking
url: https://europe1.stashify.cloud/1.0.0
info:
version: "1.0.0"
title: nucliadb Search API
description: >-
This is an example of using OAuth2 Application Flow in a specification to
describe security to your API.
security:
- application:
- read
- write
paths:
/kb/{kb_uuid}/search:
get:
parameters:
- in: path
name: kb_uuid
schema:
type: string
required: true
description: UUID of the knowledgebox
- in: query
name: q
schema:
type: string
required: false
description: >-
Text query. It can be with quotes to force keyword search on that elements.
- in: query
name: filter
schema:
type: string
required: false
description: >-
Filter query. It should be a list of tags to filter. It can be a range query.
- in: query
name: order
schema:
type: string
required: false
description: Order query
- in: query
name: v
schema:
type: string
required: false
description: BASE64 vector encoding
- in: query
name: rid
schema:
type: string
required: false
description: Resource search
- in: query
name: disable
schema:
type: array
items:
type: string
enum: [paragraph, semantic, document, relations]
required: false
description: Disable paragraph, semantic, document, relations
- in: query
name: enable
schema:
type: array
items:
type: string
enum: [ask]
required: false
description: Disable paragraph, semantic, document, relations
summary: Main search query
description: >-
This is an example operation to show how security is applied to the
call.
responses:
"200":
description: OK
components:
schemas:
KnowledgeBox:
title: A knowledge box at nucliadb
type: object
properties:
title:
type: string
slug:
type: string
icon:
type: string
description: BASE64 Image
Resource:
title: A Resource at nucliadb
type: object
properties:
title:
type: string
description:
type: string
slug:
type: string
urls:
type: array
items:
type: object
properties:
uri:
type: string
headers:
type: object
block:
type: object
additionalProperties:
type: object
properties:
blocks:
type: array
items:
type: object
text:
type: object
additionalProperties:
type: string
labels:
type: object
entities:
type: object
paragraphs:
type: object
related:
type: object
securitySchemes:
application:
type: oauth2
flows:
authorizationCode:
authorizationUrl: https://auth.stashify.cloud/oauth/token
tokenUrl: https://auth.stashify.cloud/oauth/token
refreshUrl: https://auth.stashify.cloud/oauth/token
scopes:
write: allows modifying resources
read: allows reading resources