{
  "openapi": "3.0.1",
  "info": {
    "title": "PubMed Scraper: Papers, MeSH and Citations",
    "description": "Scrape PubMed papers by topic, author, journal, MeSH term or institution. Get abstracts, authors with affiliations and countries, MeSH terms, grants, trial registrations and NIH citation metrics such as relative citation ratio. Includes yearly publication trends. Export to CSV or Excel.",
    "version": "1.0",
    "x-build-id": "JnbJhbZ17MnTrc7fd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/parselab~pubmed-research-papers-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-parselab-pubmed-research-papers-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/parselab~pubmed-research-papers-scraper/runs": {
      "post": {
        "operationId": "runs-sync-parselab-pubmed-research-papers-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/parselab~pubmed-research-papers-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-parselab-pubmed-research-papers-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "maxItems": {
            "title": "Max Items",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000."
          },
          "mode": {
            "title": "What to collect",
            "enum": [
              "articles",
              "lookup",
              "trends"
            ],
            "type": "string",
            "description": "Articles returns the papers that match a search. Lookup returns papers by PubMed id or DOI. Trends returns how many papers per year match each search term.",
            "default": "articles"
          },
          "searchTerms": {
            "title": "Search terms",
            "type": "array",
            "description": "Words or PubMed searches, for example semaglutide weight loss or glioblastoma AND immunotherapy. Each term is searched on its own and repeated papers are removed. Put one search per line.",
            "items": {
              "type": "string"
            }
          },
          "authors": {
            "title": "Authors",
            "type": "array",
            "description": "Author names as written in PubMed, for example Smith JA or Fauci AS.",
            "items": {
              "type": "string"
            }
          },
          "journals": {
            "title": "Journals",
            "type": "array",
            "description": "Journal names or abbreviations, for example Lancet or N Engl J Med.",
            "items": {
              "type": "string"
            }
          },
          "meshTerms": {
            "title": "MeSH terms",
            "type": "array",
            "description": "Medical subject headings assigned by indexers, for example Diabetes Mellitus, Type 2.",
            "items": {
              "type": "string"
            }
          },
          "affiliations": {
            "title": "Institutions",
            "type": "array",
            "description": "Part of an author affiliation, for example Mayo Clinic or Karolinska.",
            "items": {
              "type": "string"
            }
          },
          "publicationTypes": {
            "title": "Publication types",
            "type": "array",
            "description": "For example Review, Meta-Analysis, Randomized Controlled Trial, Clinical Trial, Case Reports, Systematic Review.",
            "items": {
              "type": "string"
            }
          },
          "languages": {
            "title": "Languages",
            "type": "array",
            "description": "For example English, Spanish, German.",
            "items": {
              "type": "string"
            }
          },
          "pmids": {
            "title": "PubMed ids",
            "type": "array",
            "description": "Lookup mode. PubMed ids (PMID), for example 33301246.",
            "items": {
              "type": "string"
            }
          },
          "dois": {
            "title": "DOIs",
            "type": "array",
            "description": "Lookup mode. DOIs, for example 10.1056/NEJMoa2034577.",
            "items": {
              "type": "string"
            }
          },
          "dateFrom": {
            "title": "Published from",
            "type": "string",
            "description": "First publication date: 2024, 2024-05 or 2024-05-31."
          },
          "dateTo": {
            "title": "Published until",
            "type": "string",
            "description": "Last publication date: 2025, 2025-06 or 2025-06-30."
          },
          "freeFullTextOnly": {
            "title": "Only papers with free full text",
            "type": "boolean",
            "description": "Keep papers that can be read for free.",
            "default": false
          },
          "hasAbstractOnly": {
            "title": "Only papers with an abstract",
            "type": "boolean",
            "description": "Skip records that have a title only.",
            "default": false
          },
          "humansOnly": {
            "title": "Only studies in humans",
            "type": "boolean",
            "description": "Keep papers indexed with the human subject heading.",
            "default": false
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "newest",
              "relevance",
              "oldest"
            ],
            "type": "string",
            "description": "Articles mode.",
            "default": "newest"
          },
          "includeCitationMetrics": {
            "title": "Add citation metrics",
            "type": "boolean",
            "description": "Adds citations, citations per year, relative citation ratio, percentile, clinical citations and translation score from the NIH citation database.",
            "default": true
          },
          "abstractMaxChars": {
            "title": "Abstract length limit",
            "minimum": 100,
            "type": "integer",
            "description": "Cut each abstract after this many characters. Leave empty for the full abstract."
          },
          "yearsBack": {
            "title": "Years for trends",
            "minimum": 1,
            "maximum": 60,
            "type": "integer",
            "description": "Trends mode. How many years back to count when no dates are given.",
            "default": 10
          },
          "ncbiApiKey": {
            "title": "NCBI access code (optional)",
            "type": "string",
            "description": "Free code from your NCBI account. Without it PubMed allows 3 requests per second, with it 10, so large runs are about three times faster."
          },
          "contactEmail": {
            "title": "Contact email (optional)",
            "type": "string",
            "description": "NCBI asks tools to send a contact email. It is only sent to NCBI."
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}