Skip to main content
Glama

Create a download job

get_ajax_download_php

Submits a new download job for the given url in the requested format. Returns a unique id you can pass to the Progress endpoint to poll for completion and retrieve the final download URL. Billing per call: 1 Credits.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoThe URL-encoded URL of the video to download (YouTube and other supported sources).
apikeyNoYour personal API key.
formatNoThe output format to download. Accepted values: `mp3`, `m4a`, `webm_audio`, `aac`, `flac`, `opus`, `ogg`, `wav`, `144`, `240`, `360`, `480`, `720`, `1080`, `1440`, `4k`, `8k`. Audio formats have a 120-minute base duration limit; video formats have format-specific limits (1080p=90m, 1440p=60m, 4k/8k=15m, everything else=120m).
add_infoNoSet to `1` to include the `info` object (title + thumbnail) in the response. Defaults to `0` when omitted.
end_timeNoOptional. End time (in seconds) of a cut/segment download.
no_mergeNoIf set to `1`, audio and video streams are **not** merged. The client receives a zip file containing the separate streams. Defaults to `0` (streams are merged into a single file).
start_timeNoOptional. Start time (in seconds) of a cut/segment download. When `start_time`/`end_time` are supplied, progress is not reported — the Progress endpoint only returns initialization and the final success / failure status.
audio_qualityNoAudio bitrate in kbps. Common values include `128`, `192`, `256`, `320`.
audio_languageNoYouTube only. Selects the audio track language by BCP-47 / YouTube language code. If the requested track is not available on the video, the default track is used instead. No additional cost. Supported codes: `af, az, id, ms, bs, ca, cs, da, de, et, en-IN, en-GB, en, es, es-419, es-US, eu, fil, fr, fr-CA, gl, hr, zu, is, it, sw, lv, lt, hu, nl, no, uz, pl, pt-PT, pt, ro, sq, sk, sl, sr-Latn, fi, sv, vi, tr, be, bg, ky, kk, mk, mn, ru, sr, uk, el, hy, iw, ur, ar, fa, ne, mr, hi, as, bn, pa, gu,…
allow_extended_durationNoSet to `1` to permit downloads whose video duration exceeds the format's base duration limit. Extended-duration jobs are charged a multiplier of the base price (see the `ExtendedDuration` response object). Defaults to `0` when omitted.

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full transparency burden. It disclosed that the tool starts an asynchronous job, returns an id for polling, and that every call costs 1 Credit. It does not deeply document error behavior, but for a job-submission tool this is meaningful and mostly indicates that behavior.

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?

Two short sentences cover the core purpose, the asynchronous return, the polling step, and the cost. There is no fluff or repetition, and the most important details are front-loaded.

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

Completeness4/5

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

The description gives a complete high-level lifecycle: create job, get id, poll, retrieve final URL. However, because there is no output schema and no explanation of the accept response body, a unhelpfulness for the agent to know exactly what additional fields to expect beyond the id. Still, the schema provides rich supplemental detail for all parameters.

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 schema already provides rich descriptions for all 10 parameters, including accepted values, defaults, duration limits, and special conditions. The description only repeats url and format without adding new syntax or semantic detail beyond the schema, so it stays at the schema coverage baseline.

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 is explicitly action-oriented: "Submits a new download job for the given `url` in the requested `format`." It also explains the unique id returned for later progress polling, which clearly separates this tool from the sibling get_ajax_progress.

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 explains the intended sequence: submit a job, get an id, pass it to the Progress endpoint, and poll for the final URL. It does not provide explicit when-not-to-use guidance, but the subordinate relationship to the progress tool is clear enough.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

A4.1/5.0
Disambiguation5/5

The two tools have clearly distinct roles: one creates a download job and the other polls its progress. There is no overlap or ambiguity between them.

Naming Consistency3/5

Both tools share the get_ajax_ prefix, which is consistent, but the second segment is not parallel: download_php is an implementation detail while progress is a resource. The naming is readable but not cleanly patterned.

Tool Count4/5

Two tools is minimal but appropriate for a narrow asynchronous download API: submit and poll are the essential operations. It is slightly below the typical 3-15 range, but each tool earns its place.

Completeness4/5

The core workflow is covered: submit a job, poll for completion, and retrieve the final download URL. Missing cancel or format-discovery endpoints are minor gaps for this narrow scope.

Resources