no more lg-backbone (#50)
This commit is contained in:
@ -1,5 +1,11 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
### [1.0.0-rc] - May 8th, 2021
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Migrated to io.bkbn group and package name
|
||||||
|
|
||||||
### [1.0.0-beta] - May 6th, 2021
|
### [1.0.0-beta] - May 6th, 2021
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
@ -25,7 +25,7 @@ fun RepositoryHandler.github(packageUrl: String) = maven {
|
|||||||
|
|
||||||
// 2 Add the repo in question (in this case Kompendium)
|
// 2 Add the repo in question (in this case Kompendium)
|
||||||
repositories {
|
repositories {
|
||||||
github("https://maven.pkg.github.com/lg-backbone/kompendium")
|
github("https://maven.pkg.github.com/bkbnio/kompendium")
|
||||||
}
|
}
|
||||||
|
|
||||||
// 3 Add the package like any normal dependency
|
// 3 Add the package like any normal dependency
|
||||||
@ -199,7 +199,7 @@ If this is a blocker, please open a GitHub issue, and we can start to think out
|
|||||||
Work on V1 of Kompendium has come to a close. This, however, does not mean it has achieved complete
|
Work on V1 of Kompendium has come to a close. This, however, does not mean it has achieved complete
|
||||||
parity with the OpenAPI feature spec, nor does it have all-of-the nice to have features that a truly next-gen API spec
|
parity with the OpenAPI feature spec, nor does it have all-of-the nice to have features that a truly next-gen API spec
|
||||||
should have. There are several outstanding features that have been added to the
|
should have. There are several outstanding features that have been added to the
|
||||||
[V2 Milestone](https://github.com/lg-backbone/kompendium/milestone/2). Among others, this includes
|
[V2 Milestone](https://github.com/bkbnio/kompendium/milestone/2). Among others, this includes
|
||||||
|
|
||||||
- Polymorphic support
|
- Polymorphic support
|
||||||
- AsyncAPI Integration
|
- AsyncAPI Integration
|
||||||
@ -207,4 +207,4 @@ should have. There are several outstanding features that have been added to the
|
|||||||
- MavenCentral Release
|
- MavenCentral Release
|
||||||
|
|
||||||
If you have a feature that you would like to see implemented that is not on this list, or discover a 🐞, please open
|
If you have a feature that you would like to see implemented that is not on this list, or discover a 🐞, please open
|
||||||
an issue [here](https://github.com/lg-backbone/kompendium/issues/new)
|
an issue [here](https://github.com/bkbnio/kompendium/issues/new)
|
||||||
|
@ -5,7 +5,7 @@ plugins {
|
|||||||
}
|
}
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
group = "org.leafygreens"
|
group = "io.bkbn"
|
||||||
version = run {
|
version = run {
|
||||||
val baseVersion =
|
val baseVersion =
|
||||||
project.findProperty("project.version") ?: error("project.version must be set in gradle.properties")
|
project.findProperty("project.version") ?: error("project.version must be set in gradle.properties")
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
# Kompendium
|
# Kompendium
|
||||||
project.version=1.0.0-beta
|
project.version=1.0.0-rc
|
||||||
# Kotlin
|
# Kotlin
|
||||||
kotlin.code.style=official
|
kotlin.code.style=official
|
||||||
# Gradle
|
# Gradle
|
||||||
|
@ -24,7 +24,7 @@ publishing {
|
|||||||
repositories {
|
repositories {
|
||||||
maven {
|
maven {
|
||||||
name = "GithubPackages"
|
name = "GithubPackages"
|
||||||
url = uri("https://maven.pkg.github.com/lg-backbone/kompendium")
|
url = uri("https://maven.pkg.github.com/bkbnio/kompendium")
|
||||||
credentials {
|
credentials {
|
||||||
username = System.getenv("GITHUB_ACTOR")
|
username = System.getenv("GITHUB_ACTOR")
|
||||||
password = System.getenv("GITHUB_TOKEN")
|
password = System.getenv("GITHUB_TOKEN")
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
package org.leafygreens.kompendium.auth
|
package io.bkbn.kompendium.auth
|
||||||
|
|
||||||
import io.ktor.auth.AuthenticationRouteSelector
|
import io.ktor.auth.AuthenticationRouteSelector
|
||||||
import io.ktor.routing.Route
|
import io.ktor.routing.Route
|
||||||
import org.leafygreens.kompendium.path.CorePathCalculator
|
import io.bkbn.kompendium.path.CorePathCalculator
|
||||||
import org.slf4j.LoggerFactory
|
import org.slf4j.LoggerFactory
|
||||||
|
|
||||||
class AuthPathCalculator : CorePathCalculator() {
|
class AuthPathCalculator : CorePathCalculator() {
|
@ -1,12 +1,12 @@
|
|||||||
package org.leafygreens.kompendium.auth
|
package io.bkbn.kompendium.auth
|
||||||
|
|
||||||
import io.ktor.auth.Authentication
|
import io.ktor.auth.Authentication
|
||||||
import io.ktor.auth.basic
|
import io.ktor.auth.basic
|
||||||
import io.ktor.auth.BasicAuthenticationProvider
|
import io.ktor.auth.BasicAuthenticationProvider
|
||||||
import io.ktor.auth.jwt.jwt
|
import io.ktor.auth.jwt.jwt
|
||||||
import io.ktor.auth.jwt.JWTAuthenticationProvider
|
import io.ktor.auth.jwt.JWTAuthenticationProvider
|
||||||
import org.leafygreens.kompendium.Kompendium
|
import io.bkbn.kompendium.Kompendium
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecSchemaSecurity
|
import io.bkbn.kompendium.models.oas.OpenApiSpecSchemaSecurity
|
||||||
|
|
||||||
object KompendiumAuth {
|
object KompendiumAuth {
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.auth
|
package io.bkbn.kompendium.auth
|
||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonInclude
|
import com.fasterxml.jackson.annotation.JsonInclude
|
||||||
import com.fasterxml.jackson.databind.SerializationFeature
|
import com.fasterxml.jackson.databind.SerializationFeature
|
||||||
@ -21,17 +21,17 @@ import io.ktor.server.testing.withTestApplication
|
|||||||
import kotlin.test.AfterTest
|
import kotlin.test.AfterTest
|
||||||
import kotlin.test.assertEquals
|
import kotlin.test.assertEquals
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
import org.leafygreens.kompendium.Kompendium
|
import io.bkbn.kompendium.Kompendium
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedGet
|
import io.bkbn.kompendium.Notarized.notarizedGet
|
||||||
import org.leafygreens.kompendium.auth.KompendiumAuth.notarizedBasic
|
import io.bkbn.kompendium.auth.KompendiumAuth.notarizedBasic
|
||||||
import org.leafygreens.kompendium.auth.KompendiumAuth.notarizedJwt
|
import io.bkbn.kompendium.auth.KompendiumAuth.notarizedJwt
|
||||||
import org.leafygreens.kompendium.auth.util.TestData
|
import io.bkbn.kompendium.auth.util.TestData
|
||||||
import org.leafygreens.kompendium.auth.util.TestParams
|
import io.bkbn.kompendium.auth.util.TestParams
|
||||||
import org.leafygreens.kompendium.auth.util.TestResponse
|
import io.bkbn.kompendium.auth.util.TestResponse
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
import org.leafygreens.kompendium.routes.openApi
|
import io.bkbn.kompendium.routes.openApi
|
||||||
import org.leafygreens.kompendium.routes.redoc
|
import io.bkbn.kompendium.routes.redoc
|
||||||
|
|
||||||
internal class KompendiumAuthTest {
|
internal class KompendiumAuthTest {
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.auth.util
|
package io.bkbn.kompendium.auth.util
|
||||||
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
@ -1,8 +1,8 @@
|
|||||||
package org.leafygreens.kompendium.auth.util
|
package io.bkbn.kompendium.auth.util
|
||||||
|
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumField
|
import io.bkbn.kompendium.annotations.KompendiumField
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumParam
|
import io.bkbn.kompendium.annotations.KompendiumParam
|
||||||
import org.leafygreens.kompendium.annotations.ParamType
|
import io.bkbn.kompendium.annotations.ParamType
|
||||||
|
|
||||||
data class TestParams(
|
data class TestParams(
|
||||||
@KompendiumParam(ParamType.PATH) val a: String,
|
@KompendiumParam(ParamType.PATH) val a: String,
|
@ -21,7 +21,7 @@ publishing {
|
|||||||
repositories {
|
repositories {
|
||||||
maven {
|
maven {
|
||||||
name = "GithubPackages"
|
name = "GithubPackages"
|
||||||
url = uri("https://maven.pkg.github.com/lg-backbone/kompendium")
|
url = uri("https://maven.pkg.github.com/bkbnio/kompendium")
|
||||||
credentials {
|
credentials {
|
||||||
username = System.getenv("GITHUB_ACTOR")
|
username = System.getenv("GITHUB_ACTOR")
|
||||||
password = System.getenv("GITHUB_TOKEN")
|
password = System.getenv("GITHUB_TOKEN")
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import org.leafygreens.kompendium.models.meta.ErrorMap
|
import io.bkbn.kompendium.models.meta.ErrorMap
|
||||||
import org.leafygreens.kompendium.models.meta.SchemaMap
|
import io.bkbn.kompendium.models.meta.SchemaMap
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpec
|
import io.bkbn.kompendium.models.oas.OpenApiSpec
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfo
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfo
|
||||||
import org.leafygreens.kompendium.path.CorePathCalculator
|
import io.bkbn.kompendium.path.CorePathCalculator
|
||||||
import org.leafygreens.kompendium.path.PathCalculator
|
import io.bkbn.kompendium.path.PathCalculator
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Maintains all state for the Kompendium library
|
* Maintains all state for the Kompendium library
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import io.ktor.routing.Route
|
import io.ktor.routing.Route
|
||||||
import kotlin.reflect.KType
|
import kotlin.reflect.KType
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import java.util.UUID
|
import java.util.UUID
|
||||||
import kotlin.reflect.KClass
|
import kotlin.reflect.KClass
|
||||||
@ -7,18 +7,18 @@ import kotlin.reflect.full.isSubclassOf
|
|||||||
import kotlin.reflect.full.memberProperties
|
import kotlin.reflect.full.memberProperties
|
||||||
import kotlin.reflect.jvm.javaField
|
import kotlin.reflect.jvm.javaField
|
||||||
import kotlin.reflect.typeOf
|
import kotlin.reflect.typeOf
|
||||||
import org.leafygreens.kompendium.models.meta.SchemaMap
|
import io.bkbn.kompendium.models.meta.SchemaMap
|
||||||
import org.leafygreens.kompendium.models.oas.ArraySchema
|
import io.bkbn.kompendium.models.oas.ArraySchema
|
||||||
import org.leafygreens.kompendium.models.oas.DictionarySchema
|
import io.bkbn.kompendium.models.oas.DictionarySchema
|
||||||
import org.leafygreens.kompendium.models.oas.EnumSchema
|
import io.bkbn.kompendium.models.oas.EnumSchema
|
||||||
import org.leafygreens.kompendium.models.oas.FormatSchema
|
import io.bkbn.kompendium.models.oas.FormatSchema
|
||||||
import org.leafygreens.kompendium.models.oas.ObjectSchema
|
import io.bkbn.kompendium.models.oas.ObjectSchema
|
||||||
import org.leafygreens.kompendium.models.oas.ReferencedSchema
|
import io.bkbn.kompendium.models.oas.ReferencedSchema
|
||||||
import org.leafygreens.kompendium.models.oas.SimpleSchema
|
import io.bkbn.kompendium.models.oas.SimpleSchema
|
||||||
import org.leafygreens.kompendium.util.Helpers.COMPONENT_SLUG
|
import io.bkbn.kompendium.util.Helpers.COMPONENT_SLUG
|
||||||
import org.leafygreens.kompendium.util.Helpers.genericNameAdapter
|
import io.bkbn.kompendium.util.Helpers.genericNameAdapter
|
||||||
import org.leafygreens.kompendium.util.Helpers.getReferenceSlug
|
import io.bkbn.kompendium.util.Helpers.getReferenceSlug
|
||||||
import org.leafygreens.kompendium.util.Helpers.logged
|
import io.bkbn.kompendium.util.Helpers.logged
|
||||||
import org.slf4j.LoggerFactory
|
import org.slf4j.LoggerFactory
|
||||||
|
|
||||||
/**
|
/**
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import java.util.UUID
|
import java.util.UUID
|
||||||
import kotlin.reflect.KClass
|
import kotlin.reflect.KClass
|
||||||
@ -10,21 +10,21 @@ import kotlin.reflect.full.findAnnotation
|
|||||||
import kotlin.reflect.full.memberProperties
|
import kotlin.reflect.full.memberProperties
|
||||||
import kotlin.reflect.full.primaryConstructor
|
import kotlin.reflect.full.primaryConstructor
|
||||||
import kotlin.reflect.jvm.javaField
|
import kotlin.reflect.jvm.javaField
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumParam
|
import io.bkbn.kompendium.annotations.KompendiumParam
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.RequestInfo
|
import io.bkbn.kompendium.models.meta.RequestInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
import org.leafygreens.kompendium.models.oas.ExampleWrapper
|
import io.bkbn.kompendium.models.oas.ExampleWrapper
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecMediaType
|
import io.bkbn.kompendium.models.oas.OpenApiSpecMediaType
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecParameter
|
import io.bkbn.kompendium.models.oas.OpenApiSpecParameter
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecPathItemOperation
|
import io.bkbn.kompendium.models.oas.OpenApiSpecPathItemOperation
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecReferencable
|
import io.bkbn.kompendium.models.oas.OpenApiSpecReferencable
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecReferenceObject
|
import io.bkbn.kompendium.models.oas.OpenApiSpecReferenceObject
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecRequest
|
import io.bkbn.kompendium.models.oas.OpenApiSpecRequest
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecResponse
|
import io.bkbn.kompendium.models.oas.OpenApiSpecResponse
|
||||||
import org.leafygreens.kompendium.util.Helpers
|
import io.bkbn.kompendium.util.Helpers
|
||||||
import org.leafygreens.kompendium.util.Helpers.getReferenceSlug
|
import io.bkbn.kompendium.util.Helpers.getReferenceSlug
|
||||||
import org.leafygreens.kompendium.util.Helpers.getSimpleSlug
|
import io.bkbn.kompendium.util.Helpers.getSimpleSlug
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The MethodParser is responsible for converting route metadata and types into an OpenAPI compatible data class.
|
* The MethodParser is responsible for converting route metadata and types into an OpenAPI compatible data class.
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import io.ktor.application.ApplicationCall
|
import io.ktor.application.ApplicationCall
|
||||||
import io.ktor.features.StatusPages
|
import io.ktor.features.StatusPages
|
||||||
@ -7,15 +7,15 @@ import io.ktor.routing.Route
|
|||||||
import io.ktor.routing.method
|
import io.ktor.routing.method
|
||||||
import io.ktor.util.pipeline.PipelineContext
|
import io.ktor.util.pipeline.PipelineContext
|
||||||
import io.ktor.util.pipeline.PipelineInterceptor
|
import io.ktor.util.pipeline.PipelineInterceptor
|
||||||
import org.leafygreens.kompendium.KompendiumPreFlight.errorNotarizationPreFlight
|
import io.bkbn.kompendium.KompendiumPreFlight.errorNotarizationPreFlight
|
||||||
import org.leafygreens.kompendium.MethodParser.parseErrorInfo
|
import io.bkbn.kompendium.MethodParser.parseErrorInfo
|
||||||
import org.leafygreens.kompendium.MethodParser.parseMethodInfo
|
import io.bkbn.kompendium.MethodParser.parseMethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo.GetInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo.GetInfo
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo.PostInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo.PostInfo
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo.PutInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo.PutInfo
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo.DeleteInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo.DeleteInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecPathItem
|
import io.bkbn.kompendium.models.oas.OpenApiSpecPathItem
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Notarization methods are the primary way that a Ktor API using Kompendium differentiates
|
* Notarization methods are the primary way that a Ktor API using Kompendium differentiates
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.annotations
|
package io.bkbn.kompendium.annotations
|
||||||
|
|
||||||
@Retention(AnnotationRetention.RUNTIME)
|
@Retention(AnnotationRetention.RUNTIME)
|
||||||
@Target(AnnotationTarget.PROPERTY)
|
@Target(AnnotationTarget.PROPERTY)
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.annotations
|
package io.bkbn.kompendium.annotations
|
||||||
|
|
||||||
@Retention(AnnotationRetention.RUNTIME)
|
@Retention(AnnotationRetention.RUNTIME)
|
||||||
@Target(AnnotationTarget.PROPERTY)
|
@Target(AnnotationTarget.PROPERTY)
|
@ -0,0 +1,6 @@
|
|||||||
|
package io.bkbn.kompendium.models.meta
|
||||||
|
|
||||||
|
import kotlin.reflect.KType
|
||||||
|
import io.bkbn.kompendium.models.oas.OpenApiSpecResponse
|
||||||
|
|
||||||
|
typealias ErrorMap = Map<KType, Pair<Int, OpenApiSpecResponse<*>>?>
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.meta
|
package io.bkbn.kompendium.models.meta
|
||||||
|
|
||||||
import kotlin.reflect.KClass
|
import kotlin.reflect.KClass
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.meta
|
package io.bkbn.kompendium.models.meta
|
||||||
|
|
||||||
data class RequestInfo<TReq>(
|
data class RequestInfo<TReq>(
|
||||||
val description: String,
|
val description: String,
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.meta
|
package io.bkbn.kompendium.models.meta
|
||||||
|
|
||||||
import io.ktor.http.HttpStatusCode
|
import io.ktor.http.HttpStatusCode
|
||||||
|
|
@ -0,0 +1,5 @@
|
|||||||
|
package io.bkbn.kompendium.models.meta
|
||||||
|
|
||||||
|
import io.bkbn.kompendium.models.oas.OpenApiSpecComponentSchema
|
||||||
|
|
||||||
|
typealias SchemaMap = Map<String, OpenApiSpecComponentSchema>
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpec(
|
data class OpenApiSpec(
|
||||||
val openapi: String = "3.0.3",
|
val openapi: String = "3.0.3",
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
sealed class OpenApiSpecComponentSchema(open val default: Any? = null) {
|
sealed class OpenApiSpecComponentSchema(open val default: Any? = null) {
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
// TODO I *think* the only thing I need here is the security https://swagger.io/specification/#components-object
|
// TODO I *think* the only thing I need here is the security https://swagger.io/specification/#components-object
|
||||||
data class OpenApiSpecComponents(
|
data class OpenApiSpecComponents(
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecLink(
|
data class OpenApiSpecLink(
|
||||||
val operationRef: String?, // todo mutually exclusive with operationId
|
val operationRef: String?, // todo mutually exclusive with operationId
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecMediaType<T>(
|
data class OpenApiSpecMediaType<T>(
|
||||||
val schema: OpenApiSpecReferenceObject,
|
val schema: OpenApiSpecReferenceObject,
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecOAuthFlows(
|
data class OpenApiSpecOAuthFlows(
|
||||||
val implicit: OpenApiSpecOAuthFlow?,
|
val implicit: OpenApiSpecOAuthFlow?,
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecPathItem(
|
data class OpenApiSpecPathItem(
|
||||||
var get: OpenApiSpecPathItemOperation? = null,
|
var get: OpenApiSpecPathItemOperation? = null,
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecPathItemOperation(
|
data class OpenApiSpecPathItemOperation(
|
||||||
var tags: Set<String> = emptySet(),
|
var tags: Set<String> = emptySet(),
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
sealed class OpenApiSpecReferencable
|
sealed class OpenApiSpecReferencable
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecSchemaSecurity(
|
data class OpenApiSpecSchemaSecurity(
|
||||||
val type: String? = null, // TODO Enum? "apiKey", "http", "oauth2", "openIdConnect"
|
val type: String? = null, // TODO Enum? "apiKey", "http", "oauth2", "openIdConnect"
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecServerVariable(
|
data class OpenApiSpecServerVariable(
|
||||||
val `enum`: Set<String>, // todo enforce not empty
|
val `enum`: Set<String>, // todo enforce not empty
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.models.oas
|
package io.bkbn.kompendium.models.oas
|
||||||
|
|
||||||
data class OpenApiSpecTag(
|
data class OpenApiSpecTag(
|
||||||
val name: String,
|
val name: String,
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.path
|
package io.bkbn.kompendium.path
|
||||||
|
|
||||||
import io.ktor.routing.PathSegmentConstantRouteSelector
|
import io.ktor.routing.PathSegmentConstantRouteSelector
|
||||||
import io.ktor.routing.PathSegmentParameterRouteSelector
|
import io.ktor.routing.PathSegmentParameterRouteSelector
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.path
|
package io.bkbn.kompendium.path
|
||||||
|
|
||||||
import io.ktor.routing.Route
|
import io.ktor.routing.Route
|
||||||
|
|
@ -1,11 +1,11 @@
|
|||||||
package org.leafygreens.kompendium.routes
|
package io.bkbn.kompendium.routes
|
||||||
|
|
||||||
import io.ktor.application.call
|
import io.ktor.application.call
|
||||||
import io.ktor.response.respond
|
import io.ktor.response.respond
|
||||||
import io.ktor.routing.Routing
|
import io.ktor.routing.Routing
|
||||||
import io.ktor.routing.get
|
import io.ktor.routing.get
|
||||||
import io.ktor.routing.route
|
import io.ktor.routing.route
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpec
|
import io.bkbn.kompendium.models.oas.OpenApiSpec
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provides an out-of-the-box route to return the generated [OpenApiSpec]
|
* Provides an out-of-the-box route to return the generated [OpenApiSpec]
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.routes
|
package io.bkbn.kompendium.routes
|
||||||
|
|
||||||
import io.ktor.application.call
|
import io.ktor.application.call
|
||||||
import io.ktor.html.respondHtml
|
import io.ktor.html.respondHtml
|
||||||
@ -13,7 +13,7 @@ import kotlinx.html.script
|
|||||||
import kotlinx.html.style
|
import kotlinx.html.style
|
||||||
import kotlinx.html.title
|
import kotlinx.html.title
|
||||||
import kotlinx.html.unsafe
|
import kotlinx.html.unsafe
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpec
|
import io.bkbn.kompendium.models.oas.OpenApiSpec
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Provides an out-of-the-box route to view docs using ReDoc
|
* Provides an out-of-the-box route to view docs using ReDoc
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.util
|
package io.bkbn.kompendium.util
|
||||||
|
|
||||||
import java.lang.reflect.ParameterizedType
|
import java.lang.reflect.ParameterizedType
|
||||||
import kotlin.reflect.KClass
|
import kotlin.reflect.KClass
|
||||||
@ -6,7 +6,6 @@ import kotlin.reflect.KProperty
|
|||||||
import kotlin.reflect.KType
|
import kotlin.reflect.KType
|
||||||
import kotlin.reflect.full.createType
|
import kotlin.reflect.full.createType
|
||||||
import kotlin.reflect.jvm.javaField
|
import kotlin.reflect.jvm.javaField
|
||||||
import org.leafygreens.kompendium.util.Helpers.getReferenceSlug
|
|
||||||
import org.slf4j.LoggerFactory
|
import org.slf4j.LoggerFactory
|
||||||
|
|
||||||
object Helpers {
|
object Helpers {
|
@ -1,6 +0,0 @@
|
|||||||
package org.leafygreens.kompendium.models.meta
|
|
||||||
|
|
||||||
import kotlin.reflect.KType
|
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecResponse
|
|
||||||
|
|
||||||
typealias ErrorMap = Map<KType, Pair<Int, OpenApiSpecResponse<*>>?>
|
|
@ -1,5 +0,0 @@
|
|||||||
package org.leafygreens.kompendium.models.meta
|
|
||||||
|
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecComponentSchema
|
|
||||||
|
|
||||||
typealias SchemaMap = Map<String, OpenApiSpecComponentSchema>
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import io.ktor.application.Application
|
import io.ktor.application.Application
|
||||||
import io.ktor.http.HttpMethod
|
import io.ktor.http.HttpMethod
|
||||||
@ -10,33 +10,33 @@ import java.net.URI
|
|||||||
import kotlin.test.AfterTest
|
import kotlin.test.AfterTest
|
||||||
import kotlin.test.Test
|
import kotlin.test.Test
|
||||||
import kotlin.test.assertEquals
|
import kotlin.test.assertEquals
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfo
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfo
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfoContact
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfoContact
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfoLicense
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfoLicense
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecServer
|
import io.bkbn.kompendium.models.oas.OpenApiSpecServer
|
||||||
import org.leafygreens.kompendium.routes.openApi
|
import io.bkbn.kompendium.routes.openApi
|
||||||
import org.leafygreens.kompendium.routes.redoc
|
import io.bkbn.kompendium.routes.redoc
|
||||||
import org.leafygreens.kompendium.util.TestHelpers.getFileSnapshot
|
import io.bkbn.kompendium.util.TestHelpers.getFileSnapshot
|
||||||
import org.leafygreens.kompendium.util.complexType
|
import io.bkbn.kompendium.util.complexType
|
||||||
import org.leafygreens.kompendium.util.configModule
|
import io.bkbn.kompendium.util.configModule
|
||||||
import org.leafygreens.kompendium.util.emptyGet
|
import io.bkbn.kompendium.util.emptyGet
|
||||||
import org.leafygreens.kompendium.util.nestedUnderRootModule
|
import io.bkbn.kompendium.util.nestedUnderRootModule
|
||||||
import org.leafygreens.kompendium.util.nonRequiredParamsGet
|
import io.bkbn.kompendium.util.nonRequiredParamsGet
|
||||||
import org.leafygreens.kompendium.util.notarizedDeleteModule
|
import io.bkbn.kompendium.util.notarizedDeleteModule
|
||||||
import org.leafygreens.kompendium.util.notarizedGetModule
|
import io.bkbn.kompendium.util.notarizedGetModule
|
||||||
import org.leafygreens.kompendium.util.notarizedGetWithMultipleThrowables
|
import io.bkbn.kompendium.util.notarizedGetWithMultipleThrowables
|
||||||
import org.leafygreens.kompendium.util.notarizedGetWithNotarizedException
|
import io.bkbn.kompendium.util.notarizedGetWithNotarizedException
|
||||||
import org.leafygreens.kompendium.util.notarizedPostModule
|
import io.bkbn.kompendium.util.notarizedPostModule
|
||||||
import org.leafygreens.kompendium.util.notarizedPutModule
|
import io.bkbn.kompendium.util.notarizedPutModule
|
||||||
import org.leafygreens.kompendium.util.pathParsingTestModule
|
import io.bkbn.kompendium.util.pathParsingTestModule
|
||||||
import org.leafygreens.kompendium.util.primitives
|
import io.bkbn.kompendium.util.primitives
|
||||||
import org.leafygreens.kompendium.util.returnsList
|
import io.bkbn.kompendium.util.returnsList
|
||||||
import org.leafygreens.kompendium.util.rootModule
|
import io.bkbn.kompendium.util.rootModule
|
||||||
import org.leafygreens.kompendium.util.statusPageModule
|
import io.bkbn.kompendium.util.statusPageModule
|
||||||
import org.leafygreens.kompendium.util.statusPageMultiExceptions
|
import io.bkbn.kompendium.util.statusPageMultiExceptions
|
||||||
import org.leafygreens.kompendium.util.trailingSlash
|
import io.bkbn.kompendium.util.trailingSlash
|
||||||
import org.leafygreens.kompendium.util.withDefaultParameter
|
import io.bkbn.kompendium.util.withDefaultParameter
|
||||||
import org.leafygreens.kompendium.util.withExamples
|
import io.bkbn.kompendium.util.withExamples
|
||||||
|
|
||||||
internal class KompendiumTest {
|
internal class KompendiumTest {
|
||||||
|
|
||||||
@ -450,7 +450,7 @@ internal class KompendiumTest {
|
|||||||
),
|
),
|
||||||
license = OpenApiSpecInfoLicense(
|
license = OpenApiSpecInfoLicense(
|
||||||
name = "MIT",
|
name = "MIT",
|
||||||
url = URI("https://github.com/lg-backbone/kompendium/blob/main/LICENSE")
|
url = URI("https://github.com/bkbnio/kompendium/blob/main/LICENSE")
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
servers = mutableListOf(
|
servers = mutableListOf(
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium
|
package io.bkbn.kompendium
|
||||||
|
|
||||||
import java.util.UUID
|
import java.util.UUID
|
||||||
import kotlin.test.Test
|
import kotlin.test.Test
|
||||||
@ -7,21 +7,21 @@ import kotlin.test.assertFailsWith
|
|||||||
import kotlin.test.assertFalse
|
import kotlin.test.assertFalse
|
||||||
import kotlin.test.assertNotNull
|
import kotlin.test.assertNotNull
|
||||||
import kotlin.test.assertTrue
|
import kotlin.test.assertTrue
|
||||||
import org.leafygreens.kompendium.Kontent.generateKontent
|
import io.bkbn.kompendium.Kontent.generateKontent
|
||||||
import org.leafygreens.kompendium.Kontent.generateParameterKontent
|
import io.bkbn.kompendium.Kontent.generateParameterKontent
|
||||||
import org.leafygreens.kompendium.models.oas.DictionarySchema
|
import io.bkbn.kompendium.models.oas.DictionarySchema
|
||||||
import org.leafygreens.kompendium.models.oas.FormatSchema
|
import io.bkbn.kompendium.models.oas.FormatSchema
|
||||||
import org.leafygreens.kompendium.models.oas.ObjectSchema
|
import io.bkbn.kompendium.models.oas.ObjectSchema
|
||||||
import org.leafygreens.kompendium.models.oas.ReferencedSchema
|
import io.bkbn.kompendium.models.oas.ReferencedSchema
|
||||||
import org.leafygreens.kompendium.util.ComplexRequest
|
import io.bkbn.kompendium.util.ComplexRequest
|
||||||
import org.leafygreens.kompendium.util.TestInvalidMap
|
import io.bkbn.kompendium.util.TestInvalidMap
|
||||||
import org.leafygreens.kompendium.util.TestNestedModel
|
import io.bkbn.kompendium.util.TestNestedModel
|
||||||
import org.leafygreens.kompendium.util.TestSimpleModel
|
import io.bkbn.kompendium.util.TestSimpleModel
|
||||||
import org.leafygreens.kompendium.util.TestSimpleWithEnumList
|
import io.bkbn.kompendium.util.TestSimpleWithEnumList
|
||||||
import org.leafygreens.kompendium.util.TestSimpleWithEnums
|
import io.bkbn.kompendium.util.TestSimpleWithEnums
|
||||||
import org.leafygreens.kompendium.util.TestSimpleWithList
|
import io.bkbn.kompendium.util.TestSimpleWithList
|
||||||
import org.leafygreens.kompendium.util.TestSimpleWithMap
|
import io.bkbn.kompendium.util.TestSimpleWithMap
|
||||||
import org.leafygreens.kompendium.util.TestWithUUID
|
import io.bkbn.kompendium.util.TestWithUUID
|
||||||
|
|
||||||
@ExperimentalStdlibApi
|
@ExperimentalStdlibApi
|
||||||
internal class KontentTest {
|
internal class KontentTest {
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.util
|
package io.bkbn.kompendium.util
|
||||||
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
@ -1,12 +1,9 @@
|
|||||||
package org.leafygreens.kompendium.util
|
package io.bkbn.kompendium.util
|
||||||
|
|
||||||
import java.util.UUID
|
import java.util.UUID
|
||||||
import kotlin.reflect.KParameter
|
import io.bkbn.kompendium.annotations.KompendiumField
|
||||||
import kotlin.reflect.full.primaryConstructor
|
import io.bkbn.kompendium.annotations.KompendiumParam
|
||||||
import org.leafygreens.kompendium.MethodParser
|
import io.bkbn.kompendium.annotations.ParamType
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumField
|
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumParam
|
|
||||||
import org.leafygreens.kompendium.annotations.ParamType
|
|
||||||
|
|
||||||
data class TestSimpleModel(val a: String, val b: Int)
|
data class TestSimpleModel(val a: String, val b: Int)
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.util
|
package io.bkbn.kompendium.util
|
||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonInclude
|
import com.fasterxml.jackson.annotation.JsonInclude
|
||||||
import com.fasterxml.jackson.databind.SerializationFeature
|
import com.fasterxml.jackson.databind.SerializationFeature
|
||||||
@ -13,14 +13,14 @@ import io.ktor.response.respond
|
|||||||
import io.ktor.response.respondText
|
import io.ktor.response.respondText
|
||||||
import io.ktor.routing.route
|
import io.ktor.routing.route
|
||||||
import io.ktor.routing.routing
|
import io.ktor.routing.routing
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedDelete
|
import io.bkbn.kompendium.Notarized.notarizedDelete
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedException
|
import io.bkbn.kompendium.Notarized.notarizedException
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedGet
|
import io.bkbn.kompendium.Notarized.notarizedGet
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedPost
|
import io.bkbn.kompendium.Notarized.notarizedPost
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedPut
|
import io.bkbn.kompendium.Notarized.notarizedPut
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.RequestInfo
|
import io.bkbn.kompendium.models.meta.RequestInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
|
|
||||||
fun Application.configModule() {
|
fun Application.configModule() {
|
||||||
install(ContentNegotiation) {
|
install(ContentNegotiation) {
|
@ -1,9 +1,9 @@
|
|||||||
package org.leafygreens.kompendium.util
|
package io.bkbn.kompendium.util
|
||||||
|
|
||||||
import io.ktor.http.HttpStatusCode
|
import io.ktor.http.HttpStatusCode
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.RequestInfo
|
import io.bkbn.kompendium.models.meta.RequestInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
|
|
||||||
object TestResponseInfo {
|
object TestResponseInfo {
|
||||||
private val testGetResponse = ResponseInfo<TestResponse>(HttpStatusCode.OK, "A Successful Endeavor")
|
private val testGetResponse = ResponseInfo<TestResponse>(HttpStatusCode.OK, "A Successful Endeavor")
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license" : {
|
"license" : {
|
||||||
"name" : "MIT",
|
"name" : "MIT",
|
||||||
"url" : "https://github.com/lg-backbone/kompendium/blob/main/LICENSE"
|
"url" : "https://github.com/bkbnio/kompendium/blob/main/LICENSE"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"servers" : [ {
|
"servers" : [ {
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
package org.leafygreens.kompendium.playground
|
package io.bkbn.kompendium.playground
|
||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonInclude
|
import com.fasterxml.jackson.annotation.JsonInclude
|
||||||
import com.fasterxml.jackson.databind.SerializationFeature
|
import com.fasterxml.jackson.databind.SerializationFeature
|
||||||
@ -19,24 +19,24 @@ import io.ktor.routing.routing
|
|||||||
import io.ktor.server.engine.embeddedServer
|
import io.ktor.server.engine.embeddedServer
|
||||||
import io.ktor.server.netty.Netty
|
import io.ktor.server.netty.Netty
|
||||||
import io.ktor.webjars.Webjars
|
import io.ktor.webjars.Webjars
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedDelete
|
import io.bkbn.kompendium.Notarized.notarizedDelete
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedException
|
import io.bkbn.kompendium.Notarized.notarizedException
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedGet
|
import io.bkbn.kompendium.Notarized.notarizedGet
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedPost
|
import io.bkbn.kompendium.Notarized.notarizedPost
|
||||||
import org.leafygreens.kompendium.Notarized.notarizedPut
|
import io.bkbn.kompendium.Notarized.notarizedPut
|
||||||
import org.leafygreens.kompendium.auth.KompendiumAuth.notarizedBasic
|
import io.bkbn.kompendium.auth.KompendiumAuth.notarizedBasic
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testAuthenticatedSingleGetInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testAuthenticatedSingleGetInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testGetWithExamples
|
import io.bkbn.kompendium.playground.PlaygroundToC.testGetWithExamples
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testIdGetInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testIdGetInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testPostWithExamples
|
import io.bkbn.kompendium.playground.PlaygroundToC.testPostWithExamples
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testSingleDeleteInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testSingleDeleteInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testSingleGetInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testSingleGetInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testSingleGetInfoWithThrowable
|
import io.bkbn.kompendium.playground.PlaygroundToC.testSingleGetInfoWithThrowable
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testSinglePostInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testSinglePostInfo
|
||||||
import org.leafygreens.kompendium.playground.PlaygroundToC.testSinglePutInfo
|
import io.bkbn.kompendium.playground.PlaygroundToC.testSinglePutInfo
|
||||||
import org.leafygreens.kompendium.routes.openApi
|
import io.bkbn.kompendium.routes.openApi
|
||||||
import org.leafygreens.kompendium.routes.redoc
|
import io.bkbn.kompendium.routes.redoc
|
||||||
import org.leafygreens.kompendium.swagger.swaggerUI
|
import org.leafygreens.kompendium.swagger.swaggerUI
|
||||||
|
|
||||||
fun main() {
|
fun main() {
|
@ -1,8 +1,8 @@
|
|||||||
package org.leafygreens.kompendium.playground
|
package io.bkbn.kompendium.playground
|
||||||
|
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumField
|
import io.bkbn.kompendium.annotations.KompendiumField
|
||||||
import org.leafygreens.kompendium.annotations.KompendiumParam
|
import io.bkbn.kompendium.annotations.KompendiumParam
|
||||||
import org.leafygreens.kompendium.annotations.ParamType
|
import io.bkbn.kompendium.annotations.ParamType
|
||||||
|
|
||||||
data class ExampleParams(
|
data class ExampleParams(
|
||||||
@KompendiumParam(ParamType.PATH) val id: Int,
|
@KompendiumParam(ParamType.PATH) val id: Int,
|
@ -1,9 +1,9 @@
|
|||||||
package org.leafygreens.kompendium.playground
|
package io.bkbn.kompendium.playground
|
||||||
|
|
||||||
import io.ktor.http.HttpStatusCode
|
import io.ktor.http.HttpStatusCode
|
||||||
import org.leafygreens.kompendium.models.meta.MethodInfo
|
import io.bkbn.kompendium.models.meta.MethodInfo
|
||||||
import org.leafygreens.kompendium.models.meta.RequestInfo
|
import io.bkbn.kompendium.models.meta.RequestInfo
|
||||||
import org.leafygreens.kompendium.models.meta.ResponseInfo
|
import io.bkbn.kompendium.models.meta.ResponseInfo
|
||||||
|
|
||||||
object PlaygroundToC {
|
object PlaygroundToC {
|
||||||
val testGetWithExamples = MethodInfo.GetInfo<Unit, ExampleResponse>(
|
val testGetWithExamples = MethodInfo.GetInfo<Unit, ExampleResponse>(
|
@ -1,11 +1,11 @@
|
|||||||
package org.leafygreens.kompendium.playground
|
package io.bkbn.kompendium.playground
|
||||||
|
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
import org.leafygreens.kompendium.Kompendium
|
import io.bkbn.kompendium.Kompendium
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfo
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfo
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfoContact
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfoContact
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecInfoLicense
|
import io.bkbn.kompendium.models.oas.OpenApiSpecInfoLicense
|
||||||
import org.leafygreens.kompendium.models.oas.OpenApiSpecServer
|
import io.bkbn.kompendium.models.oas.OpenApiSpecServer
|
||||||
|
|
||||||
val oas = Kompendium.openApiSpec.copy(
|
val oas = Kompendium.openApiSpec.copy(
|
||||||
info = OpenApiSpecInfo(
|
info = OpenApiSpecInfo(
|
||||||
@ -20,7 +20,7 @@ val oas = Kompendium.openApiSpec.copy(
|
|||||||
),
|
),
|
||||||
license = OpenApiSpecInfoLicense(
|
license = OpenApiSpecInfoLicense(
|
||||||
name = "MIT",
|
name = "MIT",
|
||||||
url = URI("https://github.com/lg-backbone/kompendium/blob/main/LICENSE")
|
url = URI("https://github.com/bkbnio/kompendium/blob/main/LICENSE")
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
servers = mutableListOf(
|
servers = mutableListOf(
|
@ -23,7 +23,7 @@ publishing {
|
|||||||
repositories {
|
repositories {
|
||||||
maven {
|
maven {
|
||||||
name = "GithubPackages"
|
name = "GithubPackages"
|
||||||
url = uri("https://maven.pkg.github.com/lg-backbone/kompendium")
|
url = uri("https://maven.pkg.github.com/bkbnio/kompendium")
|
||||||
credentials {
|
credentials {
|
||||||
username = System.getenv("GITHUB_ACTOR")
|
username = System.getenv("GITHUB_ACTOR")
|
||||||
password = System.getenv("GITHUB_TOKEN")
|
password = System.getenv("GITHUB_TOKEN")
|
||||||
|
Reference in New Issue
Block a user