SchemaDownloader

object SchemaDownloader

Types

Link copied to clipboard
enum SpecVersion : Enum<SchemaDownloader.SpecVersion>

Functions

Link copied to clipboard
inline fun <T> Any?.cast(): T?
Link copied to clipboard
fun download(    endpoint: String?,     graph: String?,     key: String?,     graphVariant: String,     registryUrl: String = "https://graphql.api.apollographql.com/api/graphql",     schema: File,     insecure: Boolean = false,     headers: Map<String, String> = emptyMap())

Main entry point for downloading a schema either from introspection or from the Apollo Studio registry

Link copied to clipboard
fun downloadIntrospection(    endpoint: String,     headers: Map<String, String>,     insecure: Boolean,     specVersion: SchemaDownloader.SpecVersion): String

throws if an HTTP or network error happens

Link copied to clipboard
fun downloadRegistry(    key: String,     graph: String,     variant: String,     endpoint: String = "https://graphql.api.apollographql.com/api/graphql",     headers: Map<String, String>,     insecure: Boolean): String
Link copied to clipboard
fun getIntrospectionQuery(specVersion: SchemaDownloader.SpecVersion): String