Skip to content

Commit 94b1235

Browse files
Add YAML OAS file for #21587
1 parent d9c95ab commit 94b1235

1 file changed

Lines changed: 69 additions & 0 deletions

File tree

  • modules/openapi-generator/src/test/resources/3_0/typescript-fetch
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
openapi: 3.0.1
2+
info:
3+
title: Example API
4+
version: 1.0.0
5+
paths:
6+
/api/endpoint:
7+
get:
8+
operationId: GetEndpoint
9+
summary: Get endpoint
10+
tags:
11+
- Examples
12+
responses:
13+
'200':
14+
description: Successful response
15+
content:
16+
application/json:
17+
schema:
18+
type: object
19+
title: OneOfResponse
20+
oneOf:
21+
- $ref: '#/components/schemas/OptionOne'
22+
- $ref: '#/components/schemas/OptionTwo'
23+
- type: string
24+
enum:
25+
- "fixed-value-a"
26+
- "fixed-value-b"
27+
- "fixed-value-c"
28+
- type: boolean
29+
- type: number
30+
- type: string
31+
format: date
32+
- type: string
33+
format: date-time
34+
- type: integer
35+
format: int64
36+
enum: [10, 20, 30]
37+
- type: array
38+
items:
39+
type: number
40+
- type: array
41+
items:
42+
type: object
43+
- type: array
44+
items:
45+
type: string
46+
enum:
47+
- "oneof-array-enum-a"
48+
- "oneof-array-enum-b"
49+
- "oneof-array-enum-c"
50+
- type: array
51+
items:
52+
type: number
53+
uniqueItems: true
54+
55+
components:
56+
schemas:
57+
OptionOne:
58+
type: object
59+
title: OptionOne
60+
properties:
61+
propOne:
62+
type: number
63+
additionalProperties: true
64+
OptionTwo:
65+
type: object
66+
title: OptionTwo
67+
properties:
68+
propTwo:
69+
type: string

0 commit comments

Comments
 (0)