Skip to content

Import from a URL

POSThttps://api.vidmoat.com/v1/media/import
Bearer tokenScope media.writeupload capTry it in the playground

Fetch a public http(s) URL server-side, up to your plan's upload cap or 512 MB, whichever is smaller. Destinations pass through the SSRF guard, so private ranges and metadata endpoints are refused.

Body#

  • urlstringrequired
    A public http or https URL to a video, image or audio file. Redirects are followed; the fetch times out after 120 seconds.

Response#

Returns 201.

Response fields#

  • mediaobject
    The stored file.
    Show 6 child fields
    • urlstring
      Use as a clip src.
    • filenamestring
      Stored name.
    • mediaTypeenum
      What it is.
      One of video, audio, image
    • contentTypestring
      MIME type.
    • bytesinteger
      Size.
    • durationSecnumber or null
      Length, for video and audio.
  • hintstring
    What to do with it.

Errors#

Besides the errors any request can get (authentication, rate limits):

StatusCodeWhen
400invalid_requestNo url, a private or unresolvable host, or a file that is not video, image or audio.
413payload_too_largeThe file is larger than the import limit.
502provider_errorThe URL could not be fetched (an upstream 404 or a timeout, for example).