/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ package dev.plexapi.sdk; import static dev.plexapi.sdk.operations.Operations.RequestOperation; import dev.plexapi.sdk.models.operations.GetColorsRequest; import dev.plexapi.sdk.models.operations.GetColorsRequestBuilder; import dev.plexapi.sdk.models.operations.GetColorsResponse; import dev.plexapi.sdk.models.operations.GetImageRequest; import dev.plexapi.sdk.models.operations.GetImageRequestBuilder; import dev.plexapi.sdk.models.operations.GetImageResponse; import dev.plexapi.sdk.operations.GetColors; import dev.plexapi.sdk.operations.GetImage; import java.lang.Exception; /** * Service provided to compute UltraBlur colors and images. */ public class UltraBlur { private final SDKConfiguration sdkConfiguration; private final AsyncUltraBlur asyncSDK; UltraBlur(SDKConfiguration sdkConfiguration) { this.sdkConfiguration = sdkConfiguration; this.asyncSDK = new AsyncUltraBlur(this, sdkConfiguration); } /** * Switches to the async SDK. * * @return The async SDK */ public AsyncUltraBlur async() { return asyncSDK; } /** * Get UltraBlur Colors * *
Retrieves the four colors extracted from an image for clients to use to generate an ultrablur image. * * @return The call builder */ public GetColorsRequestBuilder getColors() { return new GetColorsRequestBuilder(sdkConfiguration); } /** * Get UltraBlur Colors * *
Retrieves the four colors extracted from an image for clients to use to generate an ultrablur image.
*
* @param request The request object containing all the parameters for the API call.
* @return The response from the API call
* @throws Exception if the API call fails
*/
public GetColorsResponse getColors(GetColorsRequest request) throws Exception {
RequestOperation Retrieves a server-side generated UltraBlur image based on the provided color inputs. Clients should always call this via the photo transcoder endpoint.
*
* @return The call builder
*/
public GetImageRequestBuilder getImage() {
return new GetImageRequestBuilder(sdkConfiguration);
}
/**
* Get UltraBlur Image
*
* Retrieves a server-side generated UltraBlur image based on the provided color inputs. Clients should always call this via the photo transcoder endpoint.
*
* @param request The request object containing all the parameters for the API call.
* @return The response from the API call
* @throws Exception if the API call fails
*/
public GetImageResponse getImage(GetImageRequest request) throws Exception {
RequestOperation