Media

A library an agent can tidy, and cannot be tricked into raiding.

Uploads, imports from a URL, alt text and captions, attachment and resizing. The import path is the most carefully written code in the plugin, because a fetch made by your own server is the one place an agent could be pointed somewhere it should not go.

Sites with an accessibility gap measured in hundreds of images, and anyone migrating assets in from somewhere else.

3 jobs

What people actually ask for.

Each of these is carried by named operations that exist in the release you can download today. The ids under every answer are the calls involved — nothing here is a plan.

“Write alt text for every image on the blog that is missing it.”

The library is listed, the gaps identified, and alt text and captions written back as first-class fields rather than as post-meta guesswork.

  • media-list needs upload_files
  • media-meta-update needs edit_post

“Pull these images in from the old site and attach them to the right posts.”

Each URL is checked before the request and again after every redirect, against the address it resolved to rather than the hostname it was given. A URL that lands on a private range is refused.

  • media-import needs upload_files
  • media-attach needs edit_post

“The hero image is enormous. Sort it out.”

The registered image sizes are read from the site itself, and the attachment regenerated against them rather than against invented dimensions.

  • image-size-list needs read
  • media-resize needs edit_post + upload_files
The shape of it

8 operations, 3 of them reads.

The library: attachment details, uploads, alt text and captions, and import from a URL behind a guarded fetch.

Nothing extra to install. This module runs on core WordPress alone.

Every operation, with its policy

Reads

3 operations that only report. A read still asks WordPress for a capability against the object.

Writes

5 that change something — each one previewed as a diff, snapshotted, verified by reading the site back, and reversible from wp-admin.

Tier

Free, permanently. Nothing in this area moves into a paid tier later.

The limit

What it will not do here.

An agent cannot delete media. It can add, describe, attach and resize; removing a file from a live site is not in the surface.

Note 1

media-import is the most carefully written code in the plugin. The URL is checked before the request and again after every redirect, against the address it resolved to rather than the name it was given, so a hostname pointing at a private range is refused rather than fetched.

Note 2

Alt text is a first-class field, not an afterthought: media-meta-update exists so an agent can close an accessibility gap across a library without touching anything else.

Next

Try it, or read further.

Get the free plugin How a write is guarded