Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Media

Media abilities of the Hostinger AI plugin's WordPress site MCP server. Browse the media library, upload files from a URL, and edit or delete attachments.

Browse the media library, upload files from a URL, and edit or delete attachments.

Available: Always.

Ability
What it does
Type

Delete a WordPress media item permanently.

Destructive · Safe to retry

Get a WordPress media item details by ID.

Read-only

Get the actual file content (blob) of a WordPress media item.

Read-only

List WordPress media items with pagination and filtering.

Read-only

Search WordPress media items by title, caption, or description with filtering options.

Read-only

Update a WordPress media item metadata.

Changes the site · Safe to retry

Sideload a file from an external URL into the WordPress media library, so it can be used as a featured image or inside post content.

Changes the site

Delete Media

hostinger-ai/media-delete · Destructive · Safe to retry

Delete a WordPress media item permanently.

Required parameter
Type
Description

id

integer

Unique identifier for the resource

Description sent to AI tools

Delete a WordPress media item permanently. This action cannot be undone.

Get Media

hostinger-ai/media-get · Read-only

Get a WordPress media item details by ID.

Required parameter
Type
Description

id

integer

Unique identifier for the resource

Description sent to AI tools

Get a WordPress media item details by ID. Returns the full media object with all fields.

Get Media File

hostinger-ai/media-get-file · Read-only

Get the actual file content (blob) of a WordPress media item.

Required parameter
Type
Description

id

integer

The ID of the media item

Optional parameters (1)
Parameter
Type
Description

size

string

Optional. The size of the image to retrieve (thumbnail, medium, large, full). Defaults to full/original size.

List Media

hostinger-ai/media-list · Read-only

List WordPress media items with pagination and filtering.

No required parameters.

Optional parameters (19)
Parameter
Type
Default
Description

context

one of view, embed, edit

view

Scope under which the request is made; determines fields present in response.

page

integer

1

Current page of the collection.

per_page

integer

10

Maximum number of items to be returned in result set.

search

string

Limit results to those matching a string.

author

array of integer

[]

Limit result set to posts assigned to specific authors.

author_exclude

array of integer

[]

Ensure result set excludes posts assigned to specific authors.

exclude

array of integer

[]

Ensure result set excludes specific IDs.

include

array of integer

[]

Limit result set to specific IDs.

search_semantics

one of exact

How to interpret the search input.

offset

integer

Offset the result set by a specific number of items.

order

one of asc, desc

desc

Order sort attribute ascending or descending.

orderby

one of author, date, id, include, modified, parent, relevance, slug, include_slugs, title

date

Sort collection by post attribute.

parent

array of integer

[]

Limit result set to items with particular parent IDs.

parent_exclude

array of integer

[]

Limit result set to all items except those of a particular parent ID.

search_columns

array of post_title, post_content, post_excerpt

[]

Array of column names to be searched.

slug

array of string

Limit result set to posts with one or more specific slugs.

status

array of inherit, private, trash

inherit

Limit result set to posts assigned one or more statuses.

media_type

array of image, video, text, application, audio

Limit result set to attachments of a particular media type or media types.

mime_type

array of string

Limit result set to attachments of a particular MIME type or MIME types.

Search Media

hostinger-ai/media-search · Read-only

Search WordPress media items by title, caption, or description with filtering options.

No required parameters.

Optional parameters (7)
Parameter
Type
Default
Description

search

string

Search term to look for in media titles, captions, and descriptions

media_type

string

Filter by media type (image, video, audio, application)

mime_type

string

Filter by MIME type (e.g., image/jpeg, video/mp4)

author

integer

Filter by author ID

parent

integer

Filter by parent post ID

page

integer

1

Page number for pagination

per_page

integer

10

Number of items per page

Update Media

hostinger-ai/media-update · Changes the site · Safe to retry

Update a WordPress media item metadata.

Required parameter
Type
Description

id

integer

Unique identifier for the resource

Optional parameters (13)
Parameter
Type
Description

slug

string

An alphanumeric identifier for the post unique to its type.

status

one of publish, future, draft, pending, private, in-progress, failed, wc-pending, wc-processing, wc-on-hold, wc-completed, wc-cancelled, wc-refunded, wc-failed, wc-checkout-draft

A named status for the post.

title

object

The title for the post.

author

integer

The ID for the author of the post.

featured_media

integer

The ID of the featured media for the post.

comment_status

one of open, closed

Whether or not comments are open on the post.

ping_status

one of open, closed

Whether or not the post can be pinged.

meta

object

Meta fields.

template

string

The theme file to use to display the post.

alt_text

string

Alternative text to display when attachment is not displayed.

caption

object

The attachment caption.

description

object

The attachment description.

post

integer

The ID for the associated post of the attachment.

Description sent to AI tools

Update a WordPress media item metadata. Only provided fields will be updated.

Upload Media From URL

hostinger-ai/media-upload-from-url · Changes the site

Sideload a file from an external URL into the WordPress media library, so it can be used as a featured image or inside post content.

Required parameter
Type
Description

url

string

Publicly reachable URL of the file to sideload into the media library.

Optional parameters (6)
Parameter
Type
Description

filename

string

Optional. File name to store the file under, including extension. Defaults to the file name from the URL.

title

string

Optional. Attachment title.

caption

string

Optional. Attachment caption.

description

string

Optional. Attachment description.

alt_text

string

Optional. Alternative text for images. Recommended for accessibility and SEO.

post_id

integer

Optional. ID of the post the attachment should be attached to.

Description sent to AI tools

Sideload a file from an external URL into the WordPress media library, so it can be used as a featured image or inside post content. Any publicly reachable direct file URL is acceptable, including stock photo CDNs - the file is downloaded and stored locally, so the resulting attachment never depends on the external URL staying alive. The url must point at the file itself and return HTTP 200 with a file content type, not at a web page containing the image.

Last updated

Was this helpful?