Skip to main content
Glama

wp_upload_media

Upload files to WordPress media library from local storage. Specify file path, title, alt text, caption, description, and attach to posts.

Instructions

Uploads a file to the WordPress media library.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteNoThe ID of the WordPress site to target (from mcp-wordpress.config.json). Required if multiple sites are configured.
file_pathYesThe local, absolute path to the file to upload.
titleNoThe title for the media item.
alt_textNoAlternative text for the media item (for accessibility).
captionNoThe caption for the media item.
descriptionNoThe description for the media item.
postNoThe ID of a post to attach this media to.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/docdyhr/mcp-wordpress'

If you have feedback or need assistance with the MCP directory API, please join our Discord server