SDK Method | Java
Learn to implement ScraperAPI's Java SDK for efficient web scraping. Includes setup for Requests and Scrapy, with advanced features like JS rendering.
To make it easier to get up and running you can also use our SDK. First, you will need to install the SDK:
install the library: https://search.maven.org/artifact/com.scraperapi/sdk/1.2
Then integrate it into your code:
// remember to install the library: https://search.maven.org/artifact/com.scraperapi/sdk/1.2
import com.scraperapi
ScraperApiClient client = new ScraperApiClient("APIKEY");
client.get("http://httpbin.org/ip")
.result();
To enable extra functionality while using our SDK, simply add an additional parameter to the GET request:
ScraperApiClient client = new ScraperApiClient("APIKEY");
client.get("http://httpbin.org/ip")
.render(true)
.result();
To use two or more parameters, simply add them to the GET request:
ScraperApiClient client = new ScraperApiClient("APIKEY");
client.get("http://httpbin.org/ip")
.render(true)
.premium(true)
.result();
Last updated
Was this helpful?