Wikipedia / MediaWiki Transforms API

Wikitext HTML transformation

Operations 10

POST /transform/html/to/wikitext Wikimedia REST Transform HTML to Wikitext
POST /transform/html/to/wikitext/{title} Wikimedia REST Transform HTML to Wikitext
POST /transform/html/to/wikitext/{title}/{revision} Wikimedia REST Transform HTML to Wikitext
POST /transform/wikitext/to/html Wikimedia REST Transform Wikitext to HTML
POST /transform/wikitext/to/html/{title} Wikimedia REST Transform Wikitext to HTML
POST /transform/wikitext/to/html/{title}/{revision} Wikimedia REST Transform Wikitext to HTML
POST /transform/wikitext/to/lint Wikimedia REST Check Wikitext for Lint Errors
POST /transform/wikitext/to/lint/{title} Wikimedia REST Check Wikitext for Lint Errors
POST /transform/wikitext/to/lint/{title}/{revision} Wikimedia REST Check Wikitext for Lint Errors
POST /transform/wikitext/to/mobile-html/{title} Wikimedia REST Transform Wikitext to Mobile HTML #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/wikipedia-transforms-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

wikipedia-transforms-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Wikipedia Transforms API
  version: 1.0.0
  x-refined-note:
  - x-generated-from differs across the merged source definitions and was not carried
  - x-last-validated differs across the merged source definitions and was not carried
  - x-source-url differs across the merged source definitions and was not carried
  description: 'Operations tagged Transforms across 2 of this provider''s published API definitions: wikipedia-rest-v1-openapi.yaml, wikipedia-mediawiki-core-rest-openapi.yaml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://en.wikipedia.org/api/rest_v1
  description: English Wikipedia REST v1 endpoint
- url: https://{lang}.wikipedia.org/api/rest_v1
  description: Per-language Wikipedia REST v1 endpoint
  variables:
    lang:
      default: en
      description: Language code (e.g. en, de, fr, es, ja)
- url: https://en.wikipedia.org/w/rest.php/v1
  description: English Wikipedia
- url: https://{lang}.wikipedia.org/w/rest.php/v1
  description: Per-language Wikipedia (en, de, fr, es, ja, zh, ...)
  variables:
    lang:
      default: en
      description: Language subdomain
- url: https://api.wikimedia.org/core/v1/wikipedia/{lang}
  description: Wikimedia API Gateway equivalent of the Core REST API
  variables:
    lang:
      default: en
      description: Language code
tags:
- name: Transforms
  description: convert content between HTML and Wikitext
paths:
  /transform/html/to/wikitext:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform HTML to Wikitext
      description: 'Transform [Parsoid HTML](https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec)

        to Wikitext.


        When converting pre-existing (possibly modified) content, you should

        pass in the `title`, `revision`, and `If-Match` header. This lets

        [Parsoid](https://www.mediawiki.org/wiki/Parsoid) preserve small

        syntactic variations in wikitext, which ensures that diffs are

        readable.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s

        '
      parameters:
      - name: if-match
        in: header
        description: 'The `ETag` header of the original render indicating it''s revision and timeuuid.

          Required if both `title` and `revision` parameters are present.

          '
        schema:
          type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - html
              properties:
                html:
                  type: string
                  description: The HTML to transform
                  x-textarea: true
                scrub_wikitext:
                  type: boolean
                  description: Normalise the DOM to yield cleaner wikitext?
        required: true
      responses:
        '200':
          description: MediaWiki Wikitext.
          content:
            text/plain; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/wikitext/1.0.0":
              schema:
                type: string
        '403':
          description: Access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/html/to/wikitext/{title}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform HTML to Wikitext
      description: 'Transform [Parsoid HTML](https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec)

        to Wikitext.


        When converting pre-existing (possibly modified) content, you should

        pass in the `title`, `revision`, and `If-Match` header. This lets

        [Parsoid](https://www.mediawiki.org/wiki/Parsoid) preserve small

        syntactic variations in wikitext, which ensures that diffs are

        readable.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s

        '
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      - name: if-match
        in: header
        description: 'The `ETag` header of the original render indicating it''s revision and timeuuid.

          Required if both `title` and `revision` parameters are present.

          '
        schema:
          type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - html
              properties:
                html:
                  type: string
                  description: The HTML to transform
                  x-textarea: true
                scrub_wikitext:
                  type: boolean
                  description: Normalise the DOM to yield cleaner wikitext?
        required: true
      responses:
        '200':
          description: MediaWiki Wikitext.
          content:
            text/plain; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/wikitext/1.0.0":
              schema:
                type: string
        '403':
          description: Access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/html/to/wikitext/{title}/{revision}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform HTML to Wikitext
      description: 'Transform [Parsoid HTML](https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec)

        to Wikitext.


        When converting pre-existing (possibly modified) content, you should

        pass in the `title`, `revision`, and `If-Match` header. This lets

        [Parsoid](https://www.mediawiki.org/wiki/Parsoid) preserve small

        syntactic variations in wikitext, which ensures that diffs are

        readable.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s

        '
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      - name: revision
        in: path
        description: The page revision
        required: true
        schema:
          type: integer
      - name: if-match
        in: header
        description: 'The `ETag` header of the original render indicating it''s revision and timeuuid.

          Required if both `title` and `revision` parameters are present.

          '
        schema:
          type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - html
              properties:
                html:
                  type: string
                  description: The HTML to transform
                  x-textarea: true
                scrub_wikitext:
                  type: boolean
                  description: Normalise the DOM to yield cleaner wikitext?
        required: true
      responses:
        '200':
          description: MediaWiki Wikitext.
          content:
            text/plain; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/wikitext/1.0.0":
              schema:
                type: string
        '403':
          description: Access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/html:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform Wikitext to HTML
      description: 'Transform wikitext to HTML. Note that if you set `stash: true`, you

        also need to supply the title.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s (5 req/s when `stash: true`)

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to transform to HTML
                  x-textarea: true
                body_only:
                  type: boolean
                  description: Return only `body.innerHTML`
                stash:
                  type: boolean
                  description: Whether to temporarily stash the result of the transformation
        required: true
      responses:
        '200':
          description: See wikipage https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec
          content:
            text/html; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/HTML/2.1.0":
              schema:
                type: string
        '403':
          description: access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/html/{title}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform Wikitext to HTML
      description: 'Transform wikitext to HTML. Note that if you set `stash: true`, you

        also need to supply the title.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s (5 req/s when `stash: true`)

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to transform to HTML
                  x-textarea: true
                body_only:
                  type: boolean
                  description: Return only `body.innerHTML`
                stash:
                  type: boolean
                  description: Whether to temporarily stash the result of the transformation
        required: true
      responses:
        '200':
          description: See wikipage https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec
          content:
            text/html; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/HTML/2.1.0":
              schema:
                type: string
        '403':
          description: access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: true
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      x-amples:
      - title: Transform wikitext to html
        request:
          params:
            domain: en.wikipedia.org
            title: User:BSitzmann_(WMF)/MCS/Test/Frankenstein
          body:
            wikitext: == Heading ==
            body_only: true
        response:
          status: 200
          headers:
            content-type: /^text\/html.+/
          body: /^<h2.*>Heading<\/h2>$/
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/html/{title}/{revision}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform Wikitext to HTML
      description: 'Transform wikitext to HTML. Note that if you set `stash: true`, you

        also need to supply the title.


        - Stability: [stable](https://www.mediawiki.org/wiki/API_versioning#Stable)

        - Rate limit: 25 req/s (5 req/s when `stash: true`)

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to transform to HTML
                  x-textarea: true
                body_only:
                  type: boolean
                  description: Return only `body.innerHTML`
                stash:
                  type: boolean
                  description: Whether to temporarily stash the result of the transformation
        required: true
      responses:
        '200':
          description: See wikipage https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec
          content:
            text/html; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/HTML/2.1.0":
              schema:
                type: string
        '403':
          description: access to the specific revision is restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '404':
          description: Unknown page title or revision
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      - name: revision
        in: path
        description: The page revision
        required: true
        schema:
          type: integer
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/lint:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Check Wikitext for Lint Errors
      description: 'Parse the supplied wikitext and check it for lint errors.


        - Stability: [experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)

        - Rate limit: 25 req/s

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to check
                  x-textarea: true
          application/json:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to check
                  x-textarea: true
        required: true
      responses:
        '200':
          description: Linter errors, if any, as a JSON blob
          content:
            application/json:
              schema:
                type: object
        '404':
          description: Unknown page title
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Latest revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/lint/{title}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Check Wikitext for Lint Errors
      description: 'Parse the supplied wikitext and check it for lint errors.


        - Stability: [experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)

        - Rate limit: 25 req/s

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to check
                  x-textarea: true
        required: true
      responses:
        '200':
          description: Linter errors, if any, as a JSON blob
          content:
            application/json:
              schema:
                type: object
        '404':
          description: Unknown page title
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Latest revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/lint/{title}/{revision}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Check Wikitext for Lint Errors
      description: 'Parse the supplied wikitext and check it for lint errors.


        - Stability: [experimental](https://www.mediawiki.org/wiki/API_versioning#Experimental)

        - Rate limit: 25 req/s

        '
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to check
                  x-textarea: true
        required: true
      responses:
        '200':
          description: Linter errors, if any, as a JSON blob
          content:
            application/json:
              schema:
                type: object
        '404':
          description: Unknown page title
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '409':
          description: Latest revision was restricted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        '410':
          description: Page was deleted
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      x-monitor: false
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      - name: revision
        in: path
        description: The page revision
        required: true
        schema:
          type: integer
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
  /transform/wikitext/to/mobile-html/{title}:
    post:
      tags:
      - Transforms
      summary: Wikimedia REST Transform Wikitext to Mobile HTML
      description: 'Transform wikitext to Mobile HTML.


        - Stability: [stable](https://www.mediawiki.org/wiki/Wikimedia_Product/Wikimedia_Product_Infrastructure_team/API_endpoint_stability_policy#Stable)

        - Rate limit: 25 req/s (5 req/s when `stash: true`)


        Please follow [wikitech-l](https://lists.wikimedia.org/mailman/listinfo/wikitech-l) or [mediawiki-api-announce](https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce) for announcements of breaking changes.

        '
      parameters:
      - name: title
        in: path
        description: 'Page title. Use underscores instead of spaces. Use percent-encoding. Example: `Main_Page`.'
        required: true
        schema:
          type: string
      - name: Accept-Language
        in: header
        description: 'The desired language variant code for wikis where LanguageConverter is enabled. Example: `sr-el` for Latin transcription of the Serbian language.

          '
        schema:
          type: string
      - name: output-mode
        in: header
        description: Output mode for mobile-html. Default is `editPreview`.
        required: false
        schema:
          type: string
          enum:
          - editPreview
          - contentAndReferences
          - content
          - references
      requestBody:
        content:
          multipart/form-data:
            schema:
              required:
              - wikitext
              properties:
                wikitext:
                  type: string
                  description: The Wikitext to transform to HTML
                  x-textarea: true
        required: true
      responses:
        '200':
          description: See wikipage https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec
          content:
            text/html; charset=utf-8; profile="https://www.mediawiki.org/wiki/Specs/Mobile-HTML/1.0.0":
              schema:
                type: string
        '404':
          description: Unknown page title
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
        default:
          description: Error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/problem'
      operationId: transformWikitextToMobileHtml
      x-monitor: false
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    servers:
    - url: https://en.wikipedia.org/api/rest_v1
      description: English Wikipedia REST v1 endpoint
    - url: https://{lang}.wikipedia.org/api/rest_v1
      description: Per-language Wikipedia REST v1 endpoint
      variables:
        lang:
          default: en
          description: Language code (e.g. en, de, fr, es, ja)
components:
  schemas:
    problem:
      required:
      - type
      type: object
      properties:
        type:
          type: string
        title:
          type: string
        detail:
          type: string
        instance:
          type: string
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: OAuth 2.0 bearer token issued via api.wikimedia.org. Required for write operations.
x-refined-from:
- wikipedia-rest-v1-openapi.yaml
- wikipedia-mediawiki-core-rest-openapi.yaml
x-host-basePath: /api/rest_v1
x-default-params: {}