GiphyApi

interface GiphyApi

Giphy through the backend's optional proxy service, which adds Wire's Giphy API key. Backends without that service answer 404.

Inheritors

Functions

Link copied to clipboard
abstract suspend fun downloadGif(url: String, maxSizeInBytes: Long, sink: Sink): NetworkResponse<Long>

Downloads a GIF from Giphy's CDN into sink, without Wire credentials. Fails unless url and the final address after redirects are HTTPS giphy.com addresses, and stops reading once the body exceeds maxSizeInBytes.

Link copied to clipboard
abstract suspend fun search(query: String, limit: Int, offset: Int, rating: String, language: String?): NetworkResponse<GiphyGifsResponseDTO>
Link copied to clipboard
abstract suspend fun searchSuggestions(query: String): NetworkResponse<GiphySearchSuggestionsResponseDTO>
Link copied to clipboard
abstract suspend fun trending(limit: Int, offset: Int, rating: String): NetworkResponse<GiphyGifsResponseDTO>