EntryEndpoint
Represents the top-level URI of an API. Derive from this open class and add your own set of child Endpoints as properties.
Constructors
Link copied to clipboard
constructor(uri: URI, httpClient: OkHttpClient, serializers: List<Serializer>, errorHandler: ErrorHandler = DefaultErrorHandler(), linkExtractor: LinkExtractor = AggregateLinkExtractor(HeaderLinkExtractor(), HalLinkExtractor()))
Creates a new entry endpoint.
constructor(uri: URI, httpClient: OkHttpClient, serializer: Serializer = KotlinxJsonSerializer(), errorHandler: ErrorHandler = DefaultErrorHandler(), linkExtractor: LinkExtractor = AggregateLinkExtractor(HeaderLinkExtractor(), HalLinkExtractor()))
Creates a new entry endpoint.
constructor(uri: URI, credentials: HttpCredentials? = null, serializer: Serializer = KotlinxJsonSerializer(), errorHandler: ErrorHandler = DefaultErrorHandler(), linkExtractor: LinkExtractor = AggregateLinkExtractor(HeaderLinkExtractor(), HalLinkExtractor()))
Creates a new entry endpoint.
Properties
Functions
Link copied to clipboard
Deserializes an entity using the first serializer that supports the body's content type.
Link copied to clipboard
Deserializes a list of entities using the first serializer that supports the body's content type.
Link copied to clipboard
Retrieves a link template with a specific relation type.
Link copied to clipboard
Link copied to clipboard
Serializes a list of entities using the first serializer.
Link copied to clipboard
Registers one or more default links for a specific relation type.
Link copied to clipboard
Registers a default link template for a specific relation type.