{
  "openapi": "3.0.1",
  "info": {
    "title": "Research Paper Scraper",
    "description": "Scholar scrapers fail because Scholar blocks them. OpenAlex is open, keyless and unblockable. Three fields Scholar will not give you: the abstract rebuilt from the inverted index it ships instead of prose, field-weighted impact so citations compare across fields, and 134,038 retraction flags.",
    "version": "0.1",
    "x-build-id": "UAkvR9tQhwSPgWks3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/datalayer~research-paper-intelligence/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-datalayer-research-paper-intelligence",
        "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/datalayer~research-paper-intelligence/runs": {
      "post": {
        "operationId": "runs-sync-datalayer-research-paper-intelligence",
        "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/datalayer~research-paper-intelligence/run-sync": {
      "post": {
        "operationId": "run-sync-datalayer-research-paper-intelligence",
        "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": {
          "searchTerm": {
            "title": "Search term",
            "type": "string",
            "description": "Matched against title and abstract, e.g. CRISPR base editing, solid state battery. Give at least one of this, an institution, a country or an author.",
            "default": "CRISPR"
          },
          "authorId": {
            "title": "OpenAlex author id",
            "type": "string",
            "description": "Restrict to one author, e.g. A5023888391.",
            "default": ""
          },
          "institutionRor": {
            "title": "Institution ROR id",
            "type": "string",
            "description": "Restrict to one institution by ROR id, e.g. 00f54p054 for Stanford. Accepts the bare id or the full https://ror.org/... URL.",
            "default": ""
          },
          "countryCode": {
            "title": "Country code",
            "type": "string",
            "description": "Two-letter country of the author institutions, e.g. au, gb, us.",
            "default": ""
          },
          "fromDate": {
            "title": "Published from",
            "type": "string",
            "description": "ISO date, e.g. 2024-01-01. Leave empty for no lower bound.",
            "default": "2024-01-01"
          },
          "toDate": {
            "title": "Published to",
            "type": "string",
            "description": "ISO date. Leave empty for no upper bound.",
            "default": ""
          },
          "workTypes": {
            "title": "Work types",
            "type": "array",
            "description": "Leave empty for all types.",
            "items": {
              "type": "string",
              "enum": [
                "article",
                "review",
                "preprint",
                "book",
                "book-chapter",
                "dataset",
                "dissertation",
                "report",
                "letter",
                "editorial",
                "erratum"
              ]
            },
            "default": []
          },
          "openAccessOnly": {
            "title": "Open access only",
            "type": "boolean",
            "description": "Only papers with a legally readable full text.",
            "default": false
          },
          "retractedOnly": {
            "title": "Retracted papers only",
            "type": "boolean",
            "description": "OpenAlex flags over 134,000 retracted works. Turn this on to audit a field, a journal or an institution for retractions.",
            "default": false
          },
          "minCitations": {
            "title": "Minimum citations",
            "minimum": 0,
            "type": "integer",
            "description": "0 means no minimum.",
            "default": 0
          },
          "excludeParatext": {
            "title": "Exclude front matter",
            "type": "boolean",
            "description": "Drop indexes, covers and editorial furniture, which OpenAlex marks as paratext.",
            "default": true
          },
          "includeWorks": {
            "title": "Include paper rows",
            "type": "boolean",
            "description": "Return one row per paper. Turn off to get only the analysis row.",
            "default": true
          },
          "includeAnalysis": {
            "title": "Include analysis row",
            "type": "boolean",
            "description": "Output by year, median field-weighted impact, retraction and open-access share, top institutions, authors, journals and countries.",
            "default": true
          },
          "includeAbstract": {
            "title": "Reconstruct abstracts",
            "type": "boolean",
            "description": "OpenAlex ships abstracts as an inverted index rather than prose. Turn this on to get readable abstract text back.",
            "default": true
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "cited_by_count:desc",
              "publication_date:desc",
              "publication_date:asc",
              "relevance_score:desc"
            ],
            "type": "string",
            "description": "Most cited first is the useful default for a survey; newest first is what you want for monitoring a field.",
            "default": "cited_by_count:desc"
          },
          "maxWorks": {
            "title": "Max papers",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "OpenAlex serves 200 per page with cursor paging.",
            "default": 200
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. OpenAlex is an open API and does not require a proxy.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}