openapi-specification-types 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/body.d.ts +15 -0
- package/common.d.ts +2 -1
- package/components.d.ts +3 -16
- package/index-v2.d.ts +2 -2
- package/index-v3.d.ts +2 -2
- package/index.d.ts +1 -0
- package/package.json +1 -1
- package/paths.d.ts +2 -0
package/body.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { AnyObject } from "./common"
|
|
2
|
+
import { Schema } from "./schema"
|
|
3
|
+
|
|
4
|
+
export interface RequestBody {
|
|
5
|
+
description?: string
|
|
6
|
+
content: {
|
|
7
|
+
[type: string]: {
|
|
8
|
+
schema: Schema
|
|
9
|
+
example: AnyObject
|
|
10
|
+
examples: Record<string, AnyObject>
|
|
11
|
+
encoding: Record<string, AnyObject>
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
required?: boolean
|
|
15
|
+
}
|
package/common.d.ts
CHANGED
package/components.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RequestBody } from './body'
|
|
2
|
+
import { StringObject } from './common'
|
|
2
3
|
import { Definitions } from './definitions'
|
|
3
|
-
import { Schema } from './schema'
|
|
4
4
|
|
|
5
5
|
export interface Components {
|
|
6
6
|
schemas: Definitions
|
|
@@ -11,19 +11,6 @@ export interface RequestBodies {
|
|
|
11
11
|
[name: string]: RequestBody
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
export interface RequestBody {
|
|
15
|
-
description: string
|
|
16
|
-
content: {
|
|
17
|
-
[type: string]: {
|
|
18
|
-
schema: Schema
|
|
19
|
-
example: AtWillObject
|
|
20
|
-
examples: Record<string, AtWillObject>
|
|
21
|
-
encoding: Record<string, AtWillObject>
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
required: boolean
|
|
25
|
-
}
|
|
26
|
-
|
|
27
14
|
export interface SecuritySchemes {
|
|
28
15
|
[name: string]: SecurityScheme
|
|
29
16
|
}
|
|
@@ -44,7 +31,7 @@ export interface SecurityScheme {
|
|
|
44
31
|
openIdConnectUrl: string
|
|
45
32
|
}
|
|
46
33
|
|
|
47
|
-
interface OAuthFlow {
|
|
34
|
+
export interface OAuthFlow {
|
|
48
35
|
authorizationUrl: string
|
|
49
36
|
tokenUrl: string
|
|
50
37
|
refreshUrl: string
|
package/index-v2.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AnyObject } from './common'
|
|
2
2
|
import { Tag } from './tag'
|
|
3
3
|
import { Paths } from './paths'
|
|
4
4
|
import { Definitions, SecurityDefinitions } from './definitions'
|
|
5
5
|
|
|
6
|
-
export interface OpenAPISpecificationV2 extends
|
|
6
|
+
export interface OpenAPISpecificationV2 extends AnyObject {
|
|
7
7
|
swagger: string
|
|
8
8
|
host: string
|
|
9
9
|
basePath: string
|
package/index-v3.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AnyObject } from './common'
|
|
2
2
|
import { Server } from './server'
|
|
3
3
|
import { Tag } from './tag'
|
|
4
4
|
import { Paths } from './paths'
|
|
5
5
|
import { Components } from './components'
|
|
6
6
|
|
|
7
|
-
export interface OpenAPISpecificationV3 extends
|
|
7
|
+
export interface OpenAPISpecificationV3 extends AnyObject {
|
|
8
8
|
openapi: string
|
|
9
9
|
info: {
|
|
10
10
|
description: string
|
package/index.d.ts
CHANGED
package/package.json
CHANGED
package/paths.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { RequestBody } from './body'
|
|
1
2
|
import { Parameter } from './parameter'
|
|
2
3
|
import { Schema, Properties } from './schema'
|
|
3
4
|
|
|
@@ -24,6 +25,7 @@ export interface Method {
|
|
|
24
25
|
parameters: Parameter[]
|
|
25
26
|
responses: Responses
|
|
26
27
|
security: Security[]
|
|
28
|
+
requestBody?: RequestBody
|
|
27
29
|
}
|
|
28
30
|
|
|
29
31
|
export interface Responses {
|