# Wikibooks

> Read Wikibooks, Wikimedia's library of free textbooks. Search its books, chapters and recipes, read a page's text or a book's table of contents, pick a random book, browse a category, and keep up with what is being written.

App · 9 actions. Web page: https://docs.lodol.com/docs/integrations/wikibooks

## Actions

### Get a page summary

What a book or chapter is about, in one paragraph, with its lead picture. This is the card view: enough to put a book in a digest, a Slack message or an email without reading the whole page first.

**Inputs**

- Page title (`title`, text, required): The title of the book or chapter, as it appears at the top of the page: 'C programming' for a whole book, 'C programming/Variables' for one chapter, 'Cookbook:Pancake' for a recipe. Redirects are followed, so an old name still works. Use Search Wikibooks to find one.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `book` (text): The book the page belongs to: its title up to the first slash, which is the book's contents page.
- `description` (text): A few words saying what it is. Often empty on Wikibooks.
- `image_url` (text): The lead picture at full size, if any.
- `language` (text)
- `last_edited` (text)
- `pageid` (number)
- `summary` (text): The page's opening paragraph, as plain text. Empty for most books' contents pages, which open with the chapter list instead.
- `thumbnail_url` (text): A small version of the lead picture, if any.
- `title` (text)
- `url` (text)

**Example output**

```json
{
  "book": "C programming",
  "description": "general-purpose programming language",
  "image_url": "",
  "language": "en",
  "last_edited": "2026-10-14T12:25:43Z",
  "pageid": 31445,
  "summary": "",
  "thumbnail_url": "",
  "title": "C programming",
  "url": "https://en.wikibooks.org/wiki/C_programming"
}
```

### Get a page's edit history

Who changed one book page or chapter, when, and what they said they were doing. Use it to tell whether a book is still being written, to credit its authors, or to check a chapter a workflow depends on for changes since the last run.

**Inputs**

- Page title (`title`, text, required): The title of the book or chapter, as it appears at the top of the page: 'C programming' for a whole book, 'C programming/Variables' for one chapter, 'Cookbook:Pancake' for a recipe. Redirects are followed, so an old name still works. Use Search Wikibooks to find one.
- Newest to include (`start`, date and time): Only changes at or before this moment. Leave empty for up to now.
- Oldest to include (`end`, date and time): Only changes at or after this moment. Set it to when the last run finished to see only what is new. Leave empty for no lower bound.
- Order (`direction`, text): Which end of the window to start from. Defaults to newest first. One of: `older` (Newest first), `newer` (Oldest first). Default: `older`.
- How many edits (`limit`, number): The most edits to return. Defaults to 20. From 1 to 50. Default: `20`.
- Continue from (`continue_from`, text): Pick up where a previous run stopped: pass the 'next_page_token' that run returned. Leave empty to start at the beginning.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `count` (number)
- `direction` (text)
- `language` (text)
- `next_page_token` (text): Pass back as 'continue_from' for the next page; empty when there is nothing more.
- `pageid` (number)
- `revisions` (list)
- `title` (text)
- `url` (text)

**Example output**

```json
{
  "count": 2,
  "direction": "older",
  "language": "en",
  "next_page_token": "20260724095802|4655457",
  "pageid": 31445,
  "revisions": [
    {
      "edited_at": "2026-10-14T12:25:43Z",
      "editor": "Alexey Vazhnov",
      "is_minor": false,
      "note": "/* Related Wikibooks */ + [[Embedded Systems/C Programming]]",
      "previous_revision_id": 4674048,
      "revision_id": 4676044,
      "size_bytes": 4790,
      "tags": [
        "wikieditor"
      ],
      "url": "https://en.wikibooks.org/wiki/C_programming?oldid=4676044"
    },
    {
      "edited_at": "2026-10-04T11:47:26Z",
      "editor": "Alexey Vazhnov",
      "is_minor": false,
      "note": "/* Reference tables */ + [[/Language reference/#Character sets|Character sets]]; use [[en:w:Wikipedia:Naming conventions (capitalization)]], see discussion \"The book title capitalization\" in [[Talk:C programming]]",
      "previous_revision_id": 4655458,
      "revision_id": 4674048,
      "size_bytes": 4753,
      "tags": [
        "wikieditor"
      ],
      "url": "https://en.wikibooks.org/wiki/C_programming?oldid=4674048"
    }
  ],
  "title": "C programming",
  "url": "https://en.wikibooks.org/wiki/C_programming"
}
```

### Get a page's text

Read one book page or chapter as plain text, along with its list of sections, so a later step can summarise it, translate it or turn it into a quiz. Narrow it to one section to pull just the exercises or just one recipe step. A book's contents page comes back as its chapter list in reading order.

**Inputs**

- Page title (`title`, text, required): The title of the book or chapter, as it appears at the top of the page: 'C programming' for a whole book, 'C programming/Variables' for one chapter, 'Cookbook:Pancake' for a recipe. Redirects are followed, so an old name still works. Use Search Wikibooks to find one.
- Only this section (`section`, text): Only the text under this heading and its subsections, matched without regard to case. The 'sections' list this action returns is where the headings come from. Leave empty for the whole page.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `book` (text): The book the page belongs to: its title up to the first slash, which is the book's contents page.
- `language` (text)
- `last_edited` (text)
- `namespace` (number)
- `namespace_name` (text)
- `pageid` (number)
- `section` (text): The section filter that was applied, if any.
- `sections` (list): The page's headings, in the order they appear.
- `text` (text): The readable text, with no wiki markup.
- `title` (text): The page's title after redirects.
- `url` (text)
- `word_count` (number)

**Example output**

```json
{
  "book": "C programming",
  "language": "en",
  "last_edited": "2026-10-14T12:25:43Z",
  "namespace": 0,
  "namespace_name": "Book",
  "pageid": 31445,
  "section": "Introduction",
  "sections": [
    {
      "heading": "Table of contents",
      "level": 1,
      "url": "https://en.wikibooks.org/wiki/C_programming#Table_of_contents",
      "word_count": 0
    },
    {
      "heading": "Introduction",
      "level": 2,
      "url": "https://en.wikibooks.org/wiki/C_programming#Introduction",
      "word_count": 14
    },
    {
      "heading": "Beginning C",
      "level": 2,
      "url": "https://en.wikibooks.org/wiki/C_programming#Beginning_C",
      "word_count": 29
    }
  ],
  "text": "Introduction\n\nWhy learn C?\n History\n What you need before you can learn\n Obtaining a compiler",
  "title": "C programming",
  "url": "https://en.wikibooks.org/wiki/C_programming",
  "word_count": 15
}
```

### Get a random book

Pick books at random from the library: a book of the day for a newsletter, or something new to read. Choose whole books, or any page including single chapters. Pair it with Get a page summary to send a description along with it.

**Inputs**

- Pick from (`pick_from`, text): Whole books, or any page. Defaults to whole books. One of: `books` (Whole books), `any` (Any page, chapters included). Default: `books`.
- From these parts of the wiki (`namespaces`, list): Where to pick from. Leave empty for the main library of books. One or more of: `0` (Books - every book and its chapters), `102` (Cookbook - recipes), `110` (Wikijunior - books for children), `112` (Subject - the library's subject index), `14` (Category), `2` (User - personal drafts), `4` (Wikibooks - the project's own pages), `12` (Help), `10` (Template), `6` (File), `1` (Talk - discussion of a book page).
- How many (`count`, number): How many to pick. Defaults to 1. From 1 to 20. Default: `1`.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `count` (number)
- `language` (text)
- `pages` (list)
- `pick_from` (text)

**Example output**

```json
{
  "count": 2,
  "language": "en",
  "pages": [
    {
      "book": "The Computer Revolution",
      "is_chapter": false,
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": null,
      "title": "The Computer Revolution",
      "url": "https://en.wikibooks.org/wiki/The_Computer_Revolution"
    },
    {
      "book": "Gyakuten Kenji 2",
      "is_chapter": false,
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": null,
      "title": "Gyakuten Kenji 2",
      "url": "https://en.wikibooks.org/wiki/Gyakuten_Kenji_2"
    }
  ],
  "pick_from": "books"
}
```

### List a book's chapters

A book's table of contents: every chapter in reading order, with the part of the book it sits in and how finished it is (Wikibooks rates each chapter from 0% to 100% developed). Chapters the contents page lists but nobody has written yet are included and marked, and pages filed under the book that the contents page leaves out come last.

**Inputs**

- Book (`title`, text, required): The book's title, which is the title of its contents page, for example 'C programming' or 'Cookbook:Table of Contents'. Redirects are followed. Use Search Wikibooks to find one.
- What to include (`scope`, text): Whether to add pages filed under the book that its contents page does not list. Defaults to every page. One of: `all` (Every page filed under the book), `contents` (Only the chapters its contents page lists). Default: `all`.
- How many chapters (`limit`, number): The most chapters to return. Defaults to 100. From 1 to 500. Default: `100`.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `chapters` (list)
- `count` (number)
- `in_contents_count` (number): How many the contents page lists.
- `language` (text)
- `scope` (text)
- `title` (text): The book's title after redirects.
- `unwritten_count` (number): How many the contents page lists that nobody has written yet.
- `url` (text)

**Example output**

```json
{
  "chapters": [
    {
      "chapter": "Why learn C?",
      "development_percent": 100,
      "exists": true,
      "in_contents": true,
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": null,
      "part": "Introduction",
      "position": 2,
      "title": "C programming/Why learn C?",
      "url": "https://en.wikibooks.org/wiki/C_programming/Why_learn_C%3F"
    },
    {
      "chapter": "History",
      "development_percent": 100,
      "exists": true,
      "in_contents": true,
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": null,
      "part": "Introduction",
      "position": 3,
      "title": "C programming/History",
      "url": "https://en.wikibooks.org/wiki/C_programming/History"
    }
  ],
  "count": 2,
  "in_contents_count": 2,
  "language": "en",
  "scope": "all",
  "title": "C programming",
  "unwritten_count": 0,
  "url": "https://en.wikibooks.org/wiki/C_programming"
}
```

### List recent changes

What has been written or edited across a whole Wikibooks edition lately, newest first, with the book each change belongs to. Run it on a schedule to post the week's new chapters, or set the oldest moment to the last run to see only what is new. Wikibooks keeps about thirty days of changes.

**Inputs**

- Limit to these parts of the wiki (`namespaces`, list): Only pages in these parts of Wikibooks. Leave empty for the reading material: books, Cookbook recipes, Wikijunior and the subject index. One or more of: `0` (Books - every book and its chapters), `102` (Cookbook - recipes), `110` (Wikijunior - books for children), `112` (Subject - the library's subject index), `14` (Category), `2` (User - personal drafts), `4` (Wikibooks - the project's own pages), `12` (Help), `10` (Template), `6` (File), `1` (Talk - discussion of a book page).
- Kinds of change (`change_types`, list): Which kinds of change to include. Leave empty for every kind. One or more of: `edit` (Edits to existing pages), `new` (Newly created pages), `log` (Log entries such as deletions, moves and uploads), `categorize` (Pages added to or removed from a category).
- Leave out (`filters`, list): Narrow the list further. Leave empty to include everything. One or more of: `!minor` (Skip minor edits), `minor` (Only minor edits), `!bot` (Skip bot edits), `bot` (Only bot edits), `!anon` (Skip edits by signed-out people), `anon` (Only edits by signed-out people), `!redirect` (Skip redirects), `redirect` (Only redirects).
- Newest to include (`start`, date and time): Only changes at or before this moment. Leave empty for up to now.
- Oldest to include (`end`, date and time): Only changes at or after this moment. Set it to when the last run finished to see only what is new. Leave empty for no lower bound.
- Order (`direction`, text): Which end of the window to start from. Defaults to newest first. One of: `older` (Newest first), `newer` (Oldest first). Default: `older`.
- How many changes (`limit`, number): The most changes to return. Defaults to 50. From 1 to 500. Default: `50`.
- Continue from (`continue_from`, text): Pick up where a previous run stopped: pass the 'next_page_token' that run returned. Leave empty to start at the beginning.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `changes` (list)
- `count` (number)
- `direction` (text)
- `language` (text)
- `next_page_token` (text): Pass back as 'continue_from' for the next page; empty when there is nothing more.

**Example output**

```json
{
  "changes": [
    {
      "book": "Vehicle Identification Numbers (VIN codes)",
      "edited_at": "2026-10-19T23:12:49Z",
      "editor": "JustTheFacts33",
      "is_bot": false,
      "is_minor": false,
      "is_new": false,
      "namespace": 0,
      "namespace_name": "Book",
      "note": "/* Trim Level/Drive Wheels/Restraint System (Position 5) */",
      "pageid": 485791,
      "revision_id": 4677173,
      "size_bytes": 49436,
      "size_change": 2,
      "tags": [
        "wikieditor"
      ],
      "title": "Vehicle Identification Numbers (VIN codes)/Jaguar/VIN Codes",
      "type": "edit",
      "url": "https://en.wikibooks.org/wiki/Vehicle_Identification_Numbers_(VIN_codes)/Jaguar/VIN_Codes"
    }
  ],
  "count": 1,
  "direction": "older",
  "language": "en",
  "next_page_token": "20261019230342|5083916"
}
```

### List the categories a page is in

Where one book or chapter is filed: the book's own category and the subject shelves it sits on. Read a book's categories, then list the pages in one of them to find the books next to it. Wikibooks also files books by how complete they are and whether they are featured, in hidden categories; choose every category to see those too.

**Inputs**

- Page title (`title`, text, required): The title of the book or chapter, as it appears at the top of the page: 'C programming' for a whole book, 'C programming/Variables' for one chapter, 'Cookbook:Pancake' for a recipe. Redirects are followed, so an old name still works. Use Search Wikibooks to find one.
- Which categories (`visibility`, text): Whether to include the wiki's hidden maintenance categories, which say how a page is being looked after rather than what it is about. Defaults to the ones readers see. One of: `visible` (The ones readers see), `all` (Every category, maintenance ones included), `hidden` (Only the hidden maintenance ones). Default: `visible`.
- How many categories (`limit`, number): The most categories to return. Defaults to 50. From 1 to 500. Default: `50`.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `categories` (list)
- `count` (number)
- `language` (text)
- `pageid` (number)
- `title` (text)
- `url` (text)
- `visibility` (text)

**Example output**

```json
{
  "categories": [
    {
      "hidden": false,
      "name": "Book:C programming",
      "namespace": 14,
      "namespace_name": "Category",
      "sorts_as": " ",
      "title": "Category:Book:C programming",
      "url": "https://en.wikibooks.org/wiki/Category:Book:C_programming"
    },
    {
      "hidden": false,
      "name": "Shelf:C programming language",
      "namespace": 14,
      "namespace_name": "Category",
      "sorts_as": "C programming",
      "title": "Category:Shelf:C programming language",
      "url": "https://en.wikibooks.org/wiki/Category:Shelf:C_programming_language"
    }
  ],
  "count": 2,
  "language": "en",
  "pageid": 31445,
  "title": "C programming",
  "url": "https://en.wikibooks.org/wiki/C_programming",
  "visibility": "visible"
}
```

### List the pages in a category

Everything filed under one category, which is how Wikibooks groups books by subject and tracks their progress: every book in a subject, every recipe of a cuisine, or everything added since a date. The result also says how many the category holds altogether. Type the name with or without the 'Category:' prefix.

**Inputs**

- Category (`category`, text, required): The category to list, with or without the 'Category:' prefix. Use List the categories a page is in to find one.
- What to include (`member_types`, list): Which kinds of page to return. Leave empty for pages and subcategories. One or more of: `page` (Pages), `subcat` (Subcategories), `file` (Files).
- Sort by (`sort`, text): How to order the list. Defaults to alphabetically. One of: `sortkey` (Alphabetically), `timestamp` (By when each was added to the category). Default: `sortkey`.
- Order (`order`, text): Which way round to sort. Defaults to A to Z, or oldest first when sorting by date. One of: `ascending` (A to Z, or oldest first), `descending` (Z to A, or newest first). Default: `ascending`.
- How many pages (`limit`, number): The most pages to return. Defaults to 50. From 1 to 500. Default: `50`.
- Continue from (`continue_from`, text): Pick up where a previous run stopped: pass the 'next_page_token' that run returned. Leave empty to start at the beginning.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `category` (text)
- `count` (number): How many this run returned.
- `language` (text)
- `next_page_token` (text): Pass back as 'continue_from' for the next page; empty when there is nothing more.
- `order` (text)
- `pages` (list)
- `sort` (text)
- `total_files` (number)
- `total_in_category` (number): How many the category holds altogether.
- `total_pages` (number)
- `total_subcategories` (number)
- `url` (text)

**Example output**

```json
{
  "category": "Category:Subject:Computer programming",
  "count": 2,
  "language": "en",
  "next_page_token": "page|4150504c4945442050524f4752414d4d494e470a4150504c4945442050524f4752414d4d494e47|422799",
  "order": "ascending",
  "pages": [
    {
      "added": "2025-02-17T15:06:52Z",
      "book": "99 Elm Problems",
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": 371320,
      "sorts_as": "99 Elm Problems",
      "title": "99 Elm Problems",
      "type": "page",
      "url": "https://en.wikibooks.org/wiki/99_Elm_Problems"
    },
    {
      "added": "2025-02-17T15:06:49Z",
      "book": "A First Course to Network Coding",
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": 295168,
      "sorts_as": "A First Course to Network Coding",
      "title": "A First Course to Network Coding",
      "type": "page",
      "url": "https://en.wikibooks.org/wiki/A_First_Course_to_Network_Coding"
    }
  ],
  "sort": "sortkey",
  "total_files": 0,
  "total_in_category": 147,
  "total_pages": 75,
  "total_subcategories": 72,
  "url": "https://en.wikibooks.org/wiki/Category:Subject:Computer_programming"
}
```

### Search Wikibooks

Search the full text of one Wikibooks edition and get back the books, chapters and recipes that match, each with the passage the words were found in and the book it belongs to. This is the way in: every other action takes a title, and this is where a title comes from.

**Inputs**

- What to look for (`query`, text, required): The words to search for. Put a phrase in double quotes to keep the words together, and put a minus sign before a word to exclude it.
- Limit to these parts of the wiki (`namespaces`, list): Only pages in these parts of Wikibooks. Leave empty for the reading material: books, Cookbook recipes, Wikijunior and the subject index. One or more of: `0` (Books - every book and its chapters), `102` (Cookbook - recipes), `110` (Wikijunior - books for children), `112` (Subject - the library's subject index), `14` (Category), `2` (User - personal drafts), `4` (Wikibooks - the project's own pages), `12` (Help), `10` (Template), `6` (File), `1` (Talk - discussion of a book page).
- Order (`sort`, text): How to order the results. Defaults to best match first. One of: `relevance` (Best match first), `last_edit_desc` (Most recently updated first), `last_edit_asc` (Least recently updated first), `create_timestamp_desc` (Newest pages first), `create_timestamp_asc` (Oldest pages first), `incoming_links_desc` (Most linked-to first), `incoming_links_asc` (Least linked-to first), `title_natural_asc` (Title, A to Z), `title_natural_desc` (Title, Z to A), `just_match` (Fastest, in no particular order), `random` (Shuffled). Default: `relevance`.
- How many results (`limit`, number): The most results to return. Defaults to 10. From 1 to 50. Default: `10`.
- Continue from (`continue_from`, text): Pick up where a previous run stopped: pass the 'next_page_token' that run returned. Leave empty to start at the beginning.
- Wikibooks edition (`language`, text): Which language edition of Wikibooks to read. The list is fetched from Wikimedia, so it is the editions Wikibooks currently has. Leave empty for English. Default: `en`.

**Outputs**

- `count` (number): How many results this run returned.
- `language` (text)
- `next_page_token` (text): Pass back as 'continue_from' for the next page; empty when there is nothing more.
- `query` (text)
- `results` (list)
- `sort` (text)
- `total_matches` (number): How many pages match in total.

**Example output**

```json
{
  "count": 2,
  "language": "en",
  "next_page_token": "2",
  "query": "python",
  "results": [
    {
      "book": "Python Programming",
      "last_edited": "2026-04-05T14:23:38Z",
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": 1672,
      "size_bytes": 4906,
      "snippet": "This book describes Python, an open-source general-purpose interpreted programming language available for the most popular operating systems. The current",
      "title": "Python Programming",
      "url": "https://en.wikibooks.org/wiki/Python_Programming",
      "word_count": 286
    },
    {
      "book": "Python Programming",
      "last_edited": "2026-05-17T10:17:23Z",
      "namespace": 0,
      "namespace_name": "Book",
      "pageid": 14824,
      "size_bytes": 7071,
      "snippet": "Welcome to Python! This tutorial will show you how to start writing programs. Python programs are nothing more than text files, and they may be edited",
      "title": "Python Programming/Creating Python Programs",
      "url": "https://en.wikibooks.org/wiki/Python_Programming/Creating_Python_Programs",
      "word_count": 835
    }
  ],
  "sort": "relevance",
  "total_matches": 1544
}
```
