{
  "openapi": "3.1.0",
  "info": {
    "title": "Trending API",
    "version": "1.0.0",
    "description": "The most-read Wikipedia articles for any day and language, with internal pages filtered out.\n\nWhat the world is reading, right now. The most-viewed Wikipedia articles for any day and any language edition — the closest thing that exists to a public interest-graph — served clean: internal pages (Main Page, Special:, Portal: and their localized equivalents in Spanish, French, German, Russian, Japanese and more) are filtered out and ranks renumbered, so position 1 is a real story, with its view count and article URL. Yesterday's English list at build time: a true-crime story at 987,730 views, then a film release and Miss World 2026. Works across every Wikipedia language (es, fr, de, ja...), and a per-article endpoint returns the daily view series for any topic over up to 90 days with total, daily average and the peak day — instant interest-over-time for any subject (Taylor Swift, past week: 97,776 views, peaking September 2). Data is Wikimedia's CC0 pageview service, edge-cached 1-6 hours. News dashboards, content planning, SEO tooling, social listening, trivia and \"what's hot\" widgets — attention, quantified.",
    "contact": {
      "name": "Data and APIs",
      "url": "https://dataandapis.com/contact"
    },
    "termsOfService": "https://dataandapis.com/terms-of-service",
    "license": {
      "name": "Data and APIs Terms of Service",
      "url": "https://dataandapis.com/terms-of-service"
    },
    "x-logo": {
      "url": "https://dataandapis.com/images/trending.webp"
    }
  },
  "externalDocs": {
    "description": "Documentation, live tester and pricing",
    "url": "https://dataandapis.com/apis/trending"
  },
  "servers": [
    {
      "url": "https://api-trending.dataandapis.com"
    }
  ],
  "tags": [
    {
      "name": "Data",
      "description": "Trending API belongs to the Data category of the Data and APIs catalog."
    }
  ],
  "paths": {
    "/v1/trending/article": {
      "get": {
        "operationId": "articleInterest",
        "summary": "Article Interest",
        "description": "Article Interest endpoint of the Trending API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/trending/article-interest"
        },
        "parameters": [
          {
            "name": "days",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "7"
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "en"
          },
          {
            "name": "title",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "Taylor Swift"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "ok": true,
                  "project": "en.wikipedia.org",
                  "title": "Taylor Swift",
                  "url": "https://en.wikipedia.org/wiki/Taylor_Swift",
                  "days": 7,
                  "total_views": 91919,
                  "average_daily_views": 13131,
                  "peak": {
                    "date": "2026-09-06",
                    "views": 14543
                  },
                  "series": [
                    {
                      "date": "2026-09-05",
                      "views": 13258
                    },
                    {
                      "date": "2026-09-06",
                      "views": 14543
                    },
                    {
                      "date": "2026-09-07",
                      "views": 13187
                    },
                    {
                      "date": "2026-09-08",
                      "views": 13698
                    },
                    {
                      "date": "2026-09-09",
                      "views": 12620
                    },
                    {
                      "date": "2026-09-10",
                      "views": 12464
                    },
                    {
                      "date": "2026-09-11",
                      "views": 12149
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/sources": {
      "get": {
        "operationId": "dataSources",
        "summary": "Data Sources",
        "description": "Data Sources endpoint of the Trending API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/trending/data-sources"
        },
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "ok": true,
                  "sources": [
                    {
                      "slug": "wikimedia-pageviews",
                      "name": "Wikimedia Pageviews API",
                      "publisher": "Wikimedia Foundation",
                      "licence": "CC0 (pageview counts)",
                      "source_url": "https://wikimedia.org/api/rest_v1/",
                      "file_url": "https://wikimedia.org/api/rest_v1/metrics/pageviews/top/en.wikipedia.org/all-access/{yyyy}/{mm}/{dd}",
                      "cadence": "daily aggregates (lag ~24-48h); responses edge-cached 1-6h"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/trending": {
      "get": {
        "operationId": "trendingArticles",
        "summary": "Trending Articles",
        "description": "Trending Articles endpoint of the Trending API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/trending/trending-articles"
        },
        "parameters": [
          {
            "name": "date",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "en"
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "10"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "ok": true,
                  "project": "en.wikipedia.org",
                  "date": "2026-09-11",
                  "note": "Internal pages (Main Page, Special:, ...) are filtered out; ranks renumbered.",
                  "articles": [
                    {
                      "rank": 1,
                      "title": "September 11 attacks",
                      "views": 665793,
                      "url": "https://en.wikipedia.org/wiki/September_11_attacks"
                    },
                    {
                      "rank": 2,
                      "title": "United Airlines Flight 93",
                      "views": 259863,
                      "url": "https://en.wikipedia.org/wiki/United_Airlines_Flight_93"
                    },
                    {
                      "rank": 3,
                      "title": "Elena Rybakina",
                      "views": 231270,
                      "url": "https://en.wikipedia.org/wiki/Elena_Rybakina"
                    },
                    {
                      "rank": 4,
                      "title": "American Airlines Flight 11",
                      "views": 178794,
                      "url": "https://en.wikipedia.org/wiki/American_Airlines_Flight_11"
                    },
                    {
                      "rank": 5,
                      "title": "Shailene Woodley",
                      "views": 174654,
                      "url": "https://en.wikipedia.org/wiki/Shailene_Woodley"
                    },
                    {
                      "rank": 6,
                      "title": "Killing of the Clancy children",
                      "views": 165310,
                      "url": "https://en.wikipedia.org/wiki/Killing_of_the_Clancy_children"
                    },
                    {
                      "rank": 7,
                      "title": "Casualties of the September 11 attacks",
                      "views": 159040,
                      "url": "https://en.wikipedia.org/wiki/Casualties_of_the_September_11_attacks"
                    },
                    {
                      "rank": 8,
                      "title": "Aryna Sabalenka",
                      "views": 152768,
                      "url": "https://en.wikipedia.org/wiki/Aryna_Sabalenka"
                    },
                    {
                      "rank": 9,
                      "title": "Hijackers in the September 11 attacks",
                      "views": 149298,
                      "url": "https://en.wikipedia.org/wiki/Hijackers_in_the_September_11_attacks"
                    },
                    {
                      "rank": 10,
                      "title": "Mohamed Atta",
                      "views": 138911,
                      "url": "https://en.wikipedia.org/wiki/Mohamed_Atta"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Create a free key at https://dataandapis.com/sign-up. 500 tokens a month on the Free plan; this API costs 1 token per call."
      }
    }
  },
  "security": [
    {
      "ApiKey": []
    }
  ]
}