Maven Central MIT License Java CI/CD
Java client for the Tinify API, used for TinyPNG and TinyJPG. Tinify compresses your images intelligently. Read more at http://tinify.com.
Go to the documentation for the Java client.
Install the API client via Maven:
<dependency> <groupId>com.tinify</groupId> <artifactId>tinify</artifactId> <version>1.8.8</version> </dependency>
import com.tinify.*; import java.io.IOException; public class Compress { public static void main(String[] args) throws java.io.IOException { Tinify.setKey("YOUR_API_KEY"); Tinify.fromFile("unoptimized.png").toFile("optimized.png"); } }
mvn test
TINIFY_KEY=$YOUR_API_KEY mvn -Pintegration integration-test
This software is licensed under the MIT License. View the license.