Scientific Scholar

Scientific Scholar · GPT Actions

arXiv API

This specification provides a standardized interface to interact with the arXiv API, allowing users to query for academic papers and related metadata hosted on arXiv.org.

  • GET /queryRetrieves articles based on query parameters

    Allows querying the arXiv database for articles using various filters and search criteria. Returns results in Atom 1.0 format.

Original API schema
{
  "openapi": "3.0.0",
  "info": {
    "title": "arXiv API",
    "description": "This specification provides a standardized interface to interact with the arXiv API, allowing users to query for academic papers and related metadata hosted on arXiv.org.",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://export.arxiv.org/api",
      "description": "Main API server"
    }
  ],
  "paths": {
    "/query": {
      "get": {
        "operationId": "queryArticles",
        "summary": "Retrieves articles based on query parameters",
        "description": "Allows querying the arXiv database for articles using various filters and search criteria. Returns results in Atom 1.0 format.",
        "parameters": [
          {
            "name": "search_query",
            "in": "query",
            "description": "Query string to search in the database. Can target specific fields with prefixes like 'ti:', 'au:', etc.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "id_list",
            "in": "query",
            "description": "A comma-delimited list of arXiv IDs to specifically include in the search.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The offset index for results (0-based). Useful for pagination.",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 0
            }
          },
          {
            "name": "max_results",
            "in": "query",
            "description": "The maximum number of results to return. Useful for pagination.",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 10
            }
          },
          {
            "name": "sortBy",
            "in": "query",
            "description": "Field to sort results by. Options include 'relevance', 'lastUpdatedDate', 'submittedDate'.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "sortOrder",
            "in": "query",
            "description": "Order to sort results. Options include 'ascending' or 'descending'.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "An Atom feed containing the requested articles and metadata.",
            "content": {
              "application/atom+xml": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "feed": {
                      "type": "object",
                      "properties": {
                        "title": {
                          "type": "string"
                        },
                        "id": {
                          "type": "string"
                        },
                        "updated": {
                          "type": "string"
                        },
                        "link": {
                          "type": "object"
                        },
                        "entry": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Article"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request - often due to malformed parameters.",
            "content": {
              "application/atom+xml": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/atom+xml": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Article": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "published": {
            "type": "string"
          },
          "updated": {
            "type": "string"
          },
          "summary": {
            "type": "string"
          },
          "author": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Author"
            }
          },
          "link": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Link"
            }
          },
          "category": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Category"
            }
          },
          "arxiv:comment": {
            "type": "string"
          },
          "arxiv:affiliation": {
            "type": "string"
          },
          "arxiv:journal_ref": {
            "type": "string"
          },
          "arxiv:doi": {
            "type": "string"
          }
        }
      },
      "Author": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "arxiv:affiliation": {
            "type": "string"
          }
        }
      },
      "Link": {
        "type": "object",
        "properties": {
          "href": {
            "type": "string"
          },
          "rel": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        }
      },
      "Category": {
        "type": "object",
        "properties": {
          "term": {
            "type": "string"
          },
          "scheme": {
            "type": "string"
          }
        }
      },
      "Error": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "summary": {
            "type": "string"
          },
          "updated": {
            "type": "string"
          },
          "link": {
            "type": "object",
            "properties": {
              "href": {
                "type": "string"
              }
            }
          }
        }
      }
    }
  }
}