Skip to content

Commit 6b4727f

Browse files
authored
Merge pull request #93 from tharropoulos/lint
feat: CI pipeline and OpenAPI specification cleanup
2 parents ee1f60d + 138881b commit 6b4727f

File tree

6 files changed

+2981
-24
lines changed

6 files changed

+2981
-24
lines changed

.github/workflows/lint.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Lint OpenAPI Specification
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
lint:
7+
runs-on: ubuntu-latest
8+
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v4
12+
13+
- name: Setup Node.js
14+
uses: actions/setup-node@v4
15+
with:
16+
cache: 'npm'
17+
18+
- name: Install Redocly CLI
19+
run: npm install
20+
21+
- name: Lint OpenAPI specification
22+
run: npm run lint
23+
24+
- name: Bundle OpenAPI specification
25+
run: npm run bundle
26+
27+
- name: Upload bundled specification
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: bundled-openapi
31+
path: bundled-openapi.yml

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules

.redocly.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
extends:
2+
- recommended
3+
4+
rules:
5+
operation-4xx-response: off

openapi.yml

Lines changed: 18 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,22 @@ info:
33
title: Typesense API
44
description: "An open source search engine for building delightful search experiences."
55
version: '28.0'
6+
license:
7+
name: GPL-3.0
8+
url: https://opensource.org/licenses/GPL-3.0
9+
servers:
10+
- url: "{protocol}://{hostname}:{port}"
11+
description: Typesense Server
12+
variables:
13+
protocol:
14+
default: http
15+
description: The protocol of your Typesense server
16+
hostname:
17+
default: localhost
18+
description: The hostname of your Typesense server
19+
port:
20+
default: "8108"
21+
description: The port of your Typesense server
622
externalDocs:
723
description: Find out more about Typsesense
824
url: https://typesense.org
@@ -72,6 +88,7 @@ tags:
7288
description: Find out more
7389
url: https://typesense.org/docs/29.0/api/natural-language-search.html
7490

91+
paths:
7592
/collections:
7693
get:
7794
tags:
@@ -935,6 +952,7 @@ tags:
935952
tags:
936953
- conversations
937954
post:
955+
summary: Create a conversation model
938956
description: Create a Conversation Model
939957
operationId: createConversationModel
940958
requestBody:
@@ -2716,24 +2734,6 @@ components:
27162734
x-go-type: "[]*ApiKey"
27172735
items:
27182736
$ref: "#/components/schemas/ApiKey"
2719-
ScopedKeyParameters:
2720-
type: object
2721-
properties:
2722-
filter_by:
2723-
type: string
2724-
expires_at:
2725-
type: integer
2726-
format: int64
2727-
SnapshotParameters:
2728-
type: object
2729-
properties:
2730-
snapshot_path:
2731-
type: string
2732-
ErrorResponse:
2733-
type: object
2734-
properties:
2735-
message:
2736-
type: string
27372737
MultiSearchResult:
27382738
type: object
27392739
required:
@@ -3820,12 +3820,6 @@ components:
38203820
properties:
38213821
name:
38223822
type: string
3823-
# client libraries already have .create, .upsert,... methods so we omit the `action` param
3824-
DocumentIndexParameters:
3825-
type: object
3826-
properties:
3827-
dirty_values:
3828-
$ref: "#/components/schemas/DirtyValues"
38293823
DirtyValues:
38303824
type: string
38313825
enum: [coerce_or_reject, coerce_or_drop, drop, reject]

0 commit comments

Comments
 (0)