Skip to main content
Glama
hostinger

hostinger-api-mcp

Official
by hostinger

Generate upload URL

agency-hosting_generateUploadURLV1

Generate an authenticated upload URL for Agency Plan website file storage, returning credentials for TUS resumable file uploads.

Instructions

Generate a file browser upload URL with authentication credentials for uploading files to an Agency Plan website's file storage.

Returns url, auth_key and rest_auth_key. Use these to upload a file to the website's file storage via the TUS resumable upload protocol (TUS 1.0.0). Send X-Auth: {auth_key} and X-Auth-Rest: {rest_auth_key} headers on every request below.

  1. Create the upload: POST to {url}/{relative_file_path}?override=true with headers upload-length: {file size in bytes} and upload-offset: 0. Expect 201 Created.

  2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or PATCH requests with an upload-offset header tracking progress) until complete.

relative_file_path is the destination path inside the website's file storage, e.g. app.zip.

Instead of a TUS client, plain curl also works:

FILE=app.zip
SIZE=$(stat -f%z "$FILE")   # stat -c%s on Linux

curl -i -X POST "{url}/${FILE}?override=true" \
  -H "X-Auth: {auth_key}" \
  -H "X-Auth-Rest: {rest_auth_key}" \
  -H "Tus-Resumable: 1.0.0" \
  -H "Upload-Length: ${SIZE}" \
  -H "Upload-Offset: 0"
# -> 201 Created

curl -i -X PATCH "{url}/${FILE}?override=true" \
  -H "X-Auth: {auth_key}" \
  -H "X-Auth-Rest: {rest_auth_key}" \
  -H "Tus-Resumable: 1.0.0" \
  -H "Content-Type: application/offset+octet-stream" \
  -H "Upload-Offset: 0" \
  --data-binary "@${FILE}"
# -> 204 No Content, Upload-Offset response header equals SIZE when done

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
website_uidYesAgency Plan website UID

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Addedv1.44.0

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the minimal annotations, the description discloses exactly what the tool returns, how those credentials must be used, the expected HTTP status codes, required headers, and the full TUS upload sequence. It even clarifies that the tool only generates the URL and credentials rather than performing the upload itself. This is richly transparent for a tool with no output schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Although the description is long, every section earns its place: purpose, return values, protocol steps, and a concrete curl example. The information is front-loaded with the core purpose and return contract, then progressively detailed. The numbered steps and code block make the protocol easy to follow rather than bloated.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of the TUS upload flow, the absence of an output schema, and minimal annotations, the description is remarkably complete. It covers what the tool returns, how to construct the upload request, expected status codes, headers, and even a fallback curl method. An agent has everything needed to invoke the tool and then actually perform the upload.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The only parameter, `website_uid`, already has a 100% schema-description coverage ('Agency Plan website UID'). The description refers to the website's file storage but does not add meaningful new semantics beyond the schema. The baseline of 3 is appropriate because the schema already provides sufficient meaning for the single parameter.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific action ('Generate a file browser upload URL with authentication credentials') and specifies the target resource ('Agency Plan website's file storage'). It also names the exact return values (`url`, `auth_key`, `rest_auth_key`), making the tool's purpose unmistakable and distinct from the many hosting and deployment siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description clearly establishes the context for use: uploading files to an Agency Plan website's file storage. It provides a complete walkthrough of how to use the returned credentials, including TUS protocol steps and a curl example. It does not explicitly mention a sibling alternative such as the non-agency `hosting_generateUploadURLV1`, but the 'Agency Plan' scope makes the intended use clear enough.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/hostinger/api-mcp-server'

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