-
Notifications
You must be signed in to change notification settings - Fork 154
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(feature): generate default examples for WebSocket Sessions (#3039)
default example generation for wss
- Loading branch information
Showing
30 changed files
with
645 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
packages/cli/openapi-ir-sdk/src/sdk/api/resources/finalIr/types/WebsocketMessageExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as FernOpenapiIr from "../../.."; | ||
|
||
export interface WebsocketMessageExample extends FernOpenapiIr.WithDescription { | ||
messageType: string; | ||
payload: FernOpenapiIr.FullExample; | ||
} |
15 changes: 15 additions & 0 deletions
15
packages/cli/openapi-ir-sdk/src/sdk/api/resources/finalIr/types/WebsocketSessionExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as FernOpenapiIr from "../../.."; | ||
|
||
/** | ||
* A complete example associated with the websocket channel. | ||
*/ | ||
export interface WebsocketSessionExample extends FernOpenapiIr.WithDescription { | ||
name: string | undefined; | ||
queryParameters: FernOpenapiIr.QueryParameterExample[] | undefined; | ||
headers: FernOpenapiIr.HeaderExample[] | undefined; | ||
messages: FernOpenapiIr.WebsocketMessageExample[]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
...s/cli/openapi-ir-sdk/src/sdk/api/resources/parseIr/types/WebsocketHandshakeWithExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as FernOpenapiIr from "../../.."; | ||
|
||
export interface WebsocketHandshakeWithExample { | ||
queryParameters: FernOpenapiIr.QueryParameterWithExample[]; | ||
headers: FernOpenapiIr.HeaderWithExample[]; | ||
} |
1 change: 1 addition & 0 deletions
1
packages/cli/openapi-ir-sdk/src/sdk/api/resources/parseIr/types/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
...i/openapi-ir-sdk/src/sdk/serialization/resources/finalIr/types/WebsocketMessageExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as serializers from "../../.."; | ||
import * as FernOpenapiIr from "../../../../api"; | ||
import * as core from "../../../../core"; | ||
|
||
export const WebsocketMessageExample: core.serialization.ObjectSchema< | ||
serializers.WebsocketMessageExample.Raw, | ||
FernOpenapiIr.WebsocketMessageExample | ||
> = core.serialization | ||
.objectWithoutOptionalProperties({ | ||
messageType: core.serialization.string(), | ||
payload: core.serialization.lazy(async () => (await import("../../..")).FullExample), | ||
}) | ||
.extend(core.serialization.lazyObject(async () => (await import("../../..")).WithDescription)); | ||
|
||
export declare namespace WebsocketMessageExample { | ||
interface Raw extends serializers.WithDescription.Raw { | ||
messageType: string; | ||
payload: serializers.FullExample.Raw; | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
...i/openapi-ir-sdk/src/sdk/serialization/resources/finalIr/types/WebsocketSessionExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as serializers from "../../.."; | ||
import * as FernOpenapiIr from "../../../../api"; | ||
import * as core from "../../../../core"; | ||
|
||
export const WebsocketSessionExample: core.serialization.ObjectSchema< | ||
serializers.WebsocketSessionExample.Raw, | ||
FernOpenapiIr.WebsocketSessionExample | ||
> = core.serialization | ||
.objectWithoutOptionalProperties({ | ||
name: core.serialization.string().optional(), | ||
queryParameters: core.serialization | ||
.list(core.serialization.lazyObject(async () => (await import("../../..")).QueryParameterExample)) | ||
.optional(), | ||
headers: core.serialization | ||
.list(core.serialization.lazyObject(async () => (await import("../../..")).HeaderExample)) | ||
.optional(), | ||
messages: core.serialization.list( | ||
core.serialization.lazyObject(async () => (await import("../../..")).WebsocketMessageExample) | ||
), | ||
}) | ||
.extend(core.serialization.lazyObject(async () => (await import("../../..")).WithDescription)); | ||
|
||
export declare namespace WebsocketSessionExample { | ||
interface Raw extends serializers.WithDescription.Raw { | ||
name?: string | null; | ||
queryParameters?: serializers.QueryParameterExample.Raw[] | null; | ||
headers?: serializers.HeaderExample.Raw[] | null; | ||
messages: serializers.WebsocketMessageExample.Raw[]; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
...api-ir-sdk/src/sdk/serialization/resources/parseIr/types/WebsocketHandshakeWithExample.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/** | ||
* This file was auto-generated by Fern from our API Definition. | ||
*/ | ||
|
||
import * as serializers from "../../.."; | ||
import * as FernOpenapiIr from "../../../../api"; | ||
import * as core from "../../../../core"; | ||
|
||
export const WebsocketHandshakeWithExample: core.serialization.ObjectSchema< | ||
serializers.WebsocketHandshakeWithExample.Raw, | ||
FernOpenapiIr.WebsocketHandshakeWithExample | ||
> = core.serialization.objectWithoutOptionalProperties({ | ||
queryParameters: core.serialization.list( | ||
core.serialization.lazyObject(async () => (await import("../../..")).QueryParameterWithExample) | ||
), | ||
headers: core.serialization.list( | ||
core.serialization.lazyObject(async () => (await import("../../..")).HeaderWithExample) | ||
), | ||
}); | ||
|
||
export declare namespace WebsocketHandshakeWithExample { | ||
interface Raw { | ||
queryParameters: serializers.QueryParameterWithExample.Raw[]; | ||
headers: serializers.HeaderWithExample.Raw[]; | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
packages/cli/openapi-ir-sdk/src/sdk/serialization/resources/parseIr/types/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.