Skip to content

Commit 513de48

Browse files
committed
add openapi extensions to CompleteConfig example
1 parent 4291a88 commit 513de48

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

examples/src/main/kotlin/io/github/smiley4/ktoropenapi/examples/CompleteConfig.kt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,14 @@ private fun Application.myModule() {
220220
url = "example.com/hello"
221221
description = "external documentation of 'hello'-route"
222222
}
223+
extensions = mapOf(
224+
"x-custom-extension" to "custom-value",
225+
"x-another-extension" to mapOf(
226+
"nested" to "value",
227+
"number" to 42
228+
),
229+
"x-simple-flag" to true
230+
)
223231
request {
224232
queryParameter<String>("name") {
225233
description = "the name to greet"

0 commit comments

Comments
 (0)