Job categories
GET /v1/categories lists the 28 green job categories with slug, name, sector, description and the number of live jobs in each. Use the slugs as a filter.
#The request
GET /v1/categories returns the 28 green categories GreenHired uses to group jobs. Use a category's slug as the category filter of List jobs. The endpoint takes no parameters.
/v1/categoriesapi.greenhired.comcategories:readThe 28 green categories.
curl -s https://api.greenhired.com/v1/categories \
-H "Authorization: Bearer $GREENHIRED_API_KEY" const res = await fetch('https://api.greenhired.com/v1/categories', {
headers: { Authorization: 'Bearer ' + process.env.GREENHIRED_API_KEY },
});
const { data } = await res.json();
console.log(data.map((c) => c.slug + ' (' + c.open_jobs + ')').join('\n')); import os, requests
res = requests.get(
"https://api.greenhired.com/v1/categories",
headers={"Authorization": "Bearer " + os.environ["GREENHIRED_API_KEY"]},
timeout=15,
)
for c in res.json()["data"]:
print(c["slug"], c["open_jobs"]) #What you get
open_jobs number is an example){
"slug": "renewable-energy",
"name": "Renewable Energy",
"sector": "Energy",
"description": "Generation of energy from solar, wind, hydro, geothermal, tidal, and biomass sources.",
"open_jobs": 42
} The answer is { "data": [ ... ] }. open_jobs counts the live jobs this API may show. The counts can be up to a minute old, so there is no need to call this more than once a minute.
#The 28 slugs
renewable-energy, energy-storage-grid, energy-efficiency, climate-tech, carbon-markets, esg-sustainability, conservation-biodiversity, sustainable-agriculture, forestry-land-use, water-management, green-building, smart-cities-urban, clean-transportation-ev, sustainable-aviation-shipping, green-finance, circular-economy, waste-management, sustainable-fashion, environmental-policy-law, environmental-justice, sustainable-tourism, environmental-education, environmental-science, green-chemistry-materials, climate-data-analytics, environmental-health-safety, ocean-blue-economy and air-quality.
Read the list from the endpoint rather than hard-coding it, so you always have the current names and counts.
#Frequently asked questions
- Can a job be in more than one category?
- A job has one
green_category. Thecategoryfilter on/v1/jobsaccepts up to 28 slugs at once, so you can still ask for several categories in one request. - How often do the counts change?
- They can be up to a minute old. Cache the answer on your side for at least that long.
- Do I filter by slug or by name?
- By
slug, for examplecategory=renewable-energy. Thenameis for showing to people.
Was this page helpful?