wb_project: World Bank project data

View source: R/projects.R

wb_projectR Documentation

World Bank project data

Description

Query World Bank project data from the Projects API.

Usage

wb_project(
  id = NULL,
  country = NULL,
  status = NULL,
  region = NULL,
  search = NULL,
  start_date = NULL,
  end_date = NULL
)

Arguments

id

(NULL | character())
Project ID(s) to query, e.g. "P163868" or c("P163868", "P180429"). Default NULL. If provided, other filters are ignored.

country

(NULL | character())
Two-character World Bank country code(s) to filter by, e.g. "BR" or c("BR", "IN"). Regional aggregates such as "1W" (World) or "3A" (Africa) are also accepted. Matching is case insensitive, and projects for any of the given codes are returned. Default NULL.

status

(NULL | character())
Project status(es) to filter by, each one of "active", "closed", "dropped", or "pipeline". Projects with any of the given statuses are returned. Default NULL.

region

(NULL | character())
Region name(s) to filter by, e.g. "South Asia". Matching is case insensitive and by substring, so "Africa" also matches "Eastern and Southern Africa" and "Middle East and North Africa". Projects matching any of the given names are returned. Default NULL.

search

(NULL | character(1))
Free-text search term. Default NULL.

start_date

(NULL | character(1))
Board approval start date in "YYYY-MM-DD" format. Default NULL.

end_date

(NULL | character(1))
Board approval end date in "YYYY-MM-DD" format. Default NULL.

Value

A data.frame() with World Bank project data. The columns are:

  • id: The project ID.

  • project_name: The project name.

  • status: The project status.

  • approval_date: The board approval date.

  • closing_date: The closing date.

  • country_code: The ISO country code.

  • country: The country name.

  • region: The region name.

  • total_commitment: The total commitment amount in millions USD.

  • ibrd_commitment: The IBRD commitment amount in millions USD.

  • ida_commitment: The IDA commitment amount in millions USD.

  • lending_instrument: The lending instrument type.

  • borrower: The borrower name.

  • implementing_agency: The implementing agency name.

  • url: The project URL.

Source

https://search.worldbank.org/api/v2/projects

Examples



# active projects in Brazil related to education
wb_project(country = "BR", status = "active", search = "education")

# active or pipeline projects across two countries
wb_project(country = c("BR", "IN"), status = c("active", "pipeline"))

# look up specific projects
wb_project(id = c("P163868", "P180429"))



worldbank documentation built on Aug. 21, 2026, 9:07 a.m.