io.github.quafadas.dairect.ImageDetails.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of api_3 Show documentation
Show all versions of api_3 Show documentation
Open AI API and examples
The newest version!
package io.github.quafadas.dairect
import smithy4s.Hints
import smithy4s.Schema
import smithy4s.ShapeId
import smithy4s.ShapeTag
import smithy4s.schema.Schema.string
import smithy4s.schema.Schema.struct
final case class ImageDetails(file_id: String, detail: Option[String] = None)
object ImageDetails extends ShapeTag.Companion[ImageDetails] {
val id: ShapeId = ShapeId("io.github.quafadas.dairect", "ImageDetails")
val hints: Hints = Hints.empty
// constructor using the original order from the spec
private def make(file_id: String, detail: Option[String]): ImageDetails = ImageDetails(file_id, detail)
implicit val schema: Schema[ImageDetails] = struct(
string.required[ImageDetails]("file_id", _.file_id),
string.optional[ImageDetails]("detail", _.detail),
)(make).withId(id).addHints(hints)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy