Skip to content

Commit

Permalink
Call real api
Browse files Browse the repository at this point in the history
  • Loading branch information
ghostbuster91 committed Jul 8, 2020
1 parent 52da34c commit d956824
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions core/src/main/scala/sttp/example/Main.scala
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
package sttp.example

import org.openapitools.client.api.PetApi
import org.openapitools.client.model.Pet
import org.openapitools.client.api.StoreApi
import org.openapitools.client.core.{ApiKeyValue, SttpSerializer}
import sttp.client.HttpURLConnectionBackend

object Main {
def main(args: Array[String]): Unit = {
PetApi()(???).addPet(Pet(Some(123), photoUrls = Seq.empty, name = "reks"))
implicit val serializer: SttpSerializer = new SttpSerializer()
implicit val apiKeyValue = ApiKeyValue("")
implicit val backend = HttpURLConnectionBackend()
println(StoreApi().getInventory().send())
}
}

0 comments on commit d956824

Please sign in to comment.