Skip to contentSkip to filters

API guides

Common tasks from the first request to the last, with the errors each one meets.

The examples read the key from $WW_API_KEY; Get started shows how to create one. Every request follows the shared rules for rate limits, pagination, errors and retries.

Find upcoming events in a field

List the seminars, conferences and workshops coming up in one field, then read the details of one.

  1. 1

    List the fields and take the slug of yours. Neuroscience is neuro.

    curl --fail-with-body "https://world-wide.org/api/v1/fields" -H "Authorization: Bearer $WW_API_KEY"
  2. 2

    Search without q to list everything under the filters, soonest first. Each entry in items has an id such as conference:019b….

    curl --fail-with-body --get "https://world-wide.org/api/v1/search" \
      -d "field=neuro" -d "type=seminar,conference,workshop" -d "when=upcoming" -d "limit=50" \
      -H "Authorization: Bearer $WW_API_KEY"
  3. 3

    While hasMore is true, ask for the next page. The first 1,000 rows can be paged; for more, split the period with from and to and page each part.

    curl --fail-with-body --get "https://world-wide.org/api/v1/search" \
      -d "field=neuro" -d "type=seminar,conference,workshop" -d "when=upcoming" -d "limit=50" -d "page=2" \
      -H "Authorization: Bearer $WW_API_KEY"
  4. 4

    Pass an id to Get an item for its description, links, topics and type-specific metadata.

    curl --fail-with-body "https://world-wide.org/api/v1/items/conference:019b891c-b981-74dc-8f5c-87b1e1ec2c91" -H "Authorization: Bearer $WW_API_KEY"

If it fails

  • An empty items with partial null means nothing matched. If partial is set, the types in partial.missingTypes could not be read in time: repeat the request later.
  • 400 names the filter it refused, for example a jobs-only filter with event types, or from together with q.
  • 503 SEARCH_UNAVAILABLE: wait the 5 seconds in Retry-After and repeat.

Keep a copy of open funding calls

Read every open funding call in a field into your own store and refresh it on a schedule.

  1. 1

    List the fields with ids. The listings by type filter by the field's id, not its slug.

    curl --fail-with-body "https://world-wide.org/api/v1/domains?includeCounts=false" -H "Authorization: Bearer $WW_API_KEY"
  2. 2

    List funding with that id as domainId and openOnly=true, 100 a page. Increase page while pagination.hasNext is true.

    curl --fail-with-body "https://world-wide.org/api/v1/grants?domainId=019b891c-b981-74dc-8f5c-87b1e1ec2c1e&openOnly=true&limit=100&page=1" -H "Authorization: Bearer $WW_API_KEY"
  3. 3

    Key each row by contentType and id together. A job row is a job listed under funding. Listings can move between pages during a scan or leave the selected field. Deduplicate by that key and recheck a missing call before changing its status.

  4. 4

    To recheck particular rows between runs, get up to 32 items by id as <contentType>:<id>. A missing id means the API could not return a public item for it. Use the listing or its source to confirm closure.

    curl --fail-with-body --get "https://world-wide.org/api/v1/items" \
      --data-urlencode "ids=grant:019b891c-b981-74dc-8f5c-87b1e1ec2c71,job:019b891c-b981-74dc-8f5c-87b1e1ec2c61" \
      -H "Authorization: Bearer $WW_API_KEY"

The whole sync in Python, with paging, keying and retries:

import os
import time

import requests

BASE = "https://world-wide.org/api/v1"
session = requests.Session()
session.headers["Authorization"] = f"Bearer {os.environ['WW_API_KEY']}"


def get(path, **params):
    """GET one page, waiting out rate limits and brief outages."""
    for attempt in range(5):
        try:
            response = session.get(f"{BASE}{path}", params=params, timeout=30)
        except (requests.ConnectionError, requests.Timeout):
            if attempt == 4:
                raise
            time.sleep(2**attempt)
            continue
        if response.status_code in (429, 503) or response.status_code >= 500:
            wait = int(response.headers.get("Retry-After", 2**attempt))
            if attempt == 4 or wait > 300:  # stop when the server asks for a longer wait
                break
            time.sleep(wait)
            continue
        break
    response.raise_for_status()
    return response.json()


fields = get("/domains", includeCounts="false")["data"]
neuro = next(field for field in fields if field["slug"] == "neuro")

calls, page = {}, 1
while True:
    body = get("/grants", domainId=neuro["id"], openOnly="true", limit=100, page=page)
    for call in body["data"]:
        calls[f"{call['contentType']}:{call['id']}"] = call
    if not body["pagination"]["hasNext"]:
        break
    page += 1

print(len(calls), "open funding calls in", neuro["name"])

If it fails

  • 429: wait Retry-After seconds. From one server, 50 requests a minute is the ceiling, so pages of 100 read 5,000 rows a minute.
  • 500, 502, 503, 504 or a dropped connection: repeat the same page; every read is safe to repeat.
  • 400 on page: (page - 1) × limit may not exceed 100,000.

Read a conference programme

Find a conference, then read its sessions as JSON or as a calendar file, and its ePosters with their files.

  1. 1

    List conferences in a field and take the conference_id of one. Its event_id is a different id that no conference route accepts.

    curl --fail-with-body "https://world-wide.org/api/v1/conferences?domainSlug=neuro&limit=20" -H "Authorization: Bearer $WW_API_KEY"
  2. 2

    Get the conference to check it is public: 404 here means the remaining steps would return nothing.

    curl --fail-with-body "https://world-wide.org/api/v1/conferences/019b891c-b981-74dc-8f5c-87b1e1ec2c91" -H "Authorization: Bearer $WW_API_KEY"
  3. 3

    List the programme by start time, 100 sessions a page. Request the next page while a page holds 100 sessions.

    curl --fail-with-body "https://world-wide.org/api/v1/conferences/019b891c-b981-74dc-8f5c-87b1e1ec2c91/sessions?limit=100&page=1" -H "Authorization: Bearer $WW_API_KEY"
  4. 4

    Or save each page as iCalendar for a calendar app. Fetch it from your server with the key; the file is not a subscription link.

    curl --fail-with-body "https://world-wide.org/api/v1/conferences/019b891c-b981-74dc-8f5c-87b1e1ec2c91/sessions?limit=100&format=ics" \
      -H "Authorization: Bearer $WW_API_KEY" --output programme.ics
  5. 5

    List its ePosters with include=files for each poster's public files.

    curl --fail-with-body "https://world-wide.org/api/v1/conferences/019b891c-b981-74dc-8f5c-87b1e1ec2c91/eposters?include=files&limit=100" -H "Authorization: Bearer $WW_API_KEY"

If it fails

  • 404 from the conference or its programme: the id is an event_id, a slug or a conference that is not public.
  • The ePosters route answers 200 with an empty list for any id, so check the conference first.
  • The same conference is conference:<conference_id> in the catalogue routes, such as Get an item and List a conference's sessions.

Search by meaning

Turn a research question into a topic, rank the catalogue by meaning and topic links, and read the results in one batch.

  1. 1

    Resolve the topic by name. Each node's id is topic:<slug>.

    curl --fail-with-body -X POST "https://world-wide.org/api/v1/discovery/graph" -H "Authorization: Bearer $WW_API_KEY" -H "Content-Type: application/json" \
      -d '{"operation":"resolve","kind":"topic","query":"working memory","limit":3}'
  2. 2

    Send the slug after topic: (working-memory) in topics to Scientific discovery search, with the question as query. hybrid ranks by words, meaning and topic links; facets counts every match by type before paging. For the next page, send the same body with page one higher while hasMore is true.

    curl --fail-with-body -X POST "https://world-wide.org/api/v1/discovery/search" -H "Authorization: Bearer $WW_API_KEY" -H "Content-Type: application/json" \
      -d '{"query":"How does sleep support working memory?","mode":"hybrid","topics":["working-memory"],"types":["seminar","podcast"],"facets":["types"],"limit":10}'
  3. 3

    Read up to 32 results at once with batch. requests says for each id whether it was found and which id it resolved to.

    curl --fail-with-body -X POST "https://world-wide.org/api/v1/discovery/collections" -H "Authorization: Bearer $WW_API_KEY" -H "Content-Type: application/json" \
      -d '{"operation":"batch","ids":["seminar:019b891c-b981-74dc-8f5c-87b1e1ec2c21","podcast:019b891c-b981-74dc-8f5c-87b1e1ec2f01"]}'

If it fails

  • Check partial and coverage before quoting counts: if the query could not be embedded, an automatic search answers with keyword matches and sets partial.
  • 422 with similarTo and mode: "semantic": that item has no embedding; use hybrid.
  • 503 SEARCH_UNAVAILABLE: back off and retry, or send mode: "lexical".

Export records in bulk

Load one type of record into a spreadsheet or database, up to 1,000 rows a request.

  1. 1

    Edit the integration in Settings → API keys and tick Bulk data export.

  2. 2

    Request the data export with an exact field slug as domain. Add 1,000 to offset for each next file, and stop when a file holds fewer than 1,000 rows. As JSON, stop when has_more is false.

    curl --fail-with-body "https://world-wide.org/api/data/output?type=jobs&domain=neuro&format=csv&limit=1000&offset=0" \
      -H "Authorization: Bearer $WW_API_KEY" --output jobs-0.csv

If it fails

  • 403: the key lacks Bulk data export.
  • domain must be the exact slug: neuroscience returns no rows where neuro returns them.
  • 400 on offset: an export reaches 100,000 rows into a type; split it by field.