← All integrations
Import.io + R

Import.io data in R

Fetch the Import.io extractor’s latest-run CSV with httr2 and read it with readr. Schedule the extractor and every script starts from fresh data.

Connects via
EndpointREST API
Setup
5 min
Available on
Endpoints: every planAPI: every plan
R
library(httr2)
library(readr)

csv <- request(Sys.getenv("IMPORTIO_CSV_URL")) |>
  req_perform() |>
  resp_body_string()

prices <- read_csv(I(csv))
head(prices)

How it connects.

Source

The web

Any public page, rendered, through managed proxies

Engine

Import.io

Rendering, proxy routing, captcha handling, extraction

Path

Data endpoint

Latest successful run, CSV or JSON

Destination

R

Extractor results into a tibble with httr2 and readr.

Also connects via the REST API.

What teams do with it.

Statistical price analysis

Model price elasticity or promotion frequency on live market data.

Reproducible reports

Quarto and R Markdown reports that re-read the latest run when they knit.

Research datasets

Collect web data for academic and journalistic work with a documented source.

Set it up.

  1. install.packages(c("httr2", "readr")).
  2. Copy “CSV from latest successful run” into IMPORTIO_CSV_URL.
  3. Fetch and read it.

Questions.

Can I read a specific run?

Yes. List runs with GET https://api.import.io/crawlruns/ and download one with /crawlruns/{id}/csv.

Do endpoint downloads count as queries?

No. The latest-run CSV, JSON and Google Sheets endpoints return data your extractor already collected, so they don’t count toward your plan. Only the Live Query API runs an extraction per request.

How fresh is the data?

As fresh as your schedule. Run the extractor hourly, daily or weekly and the endpoint always serves the latest successful run.

How do I authenticate?

Pass your API key as the _apikey query parameter. Copy it from account settings at app.import.io.

Is the API on every plan?

Yes. The trial and Standard include rate-limited API access. Professional and Advanced include full API access and webhooks.

Fresh web data
in R.