Flag of Ukraine
Our /tus/store Robot

Export files to Tus-compatible servers

🤖/tus/store exports encoding results to any Tus-compatible server.

Usage example

Export uploaded files to the Tus live demo server:

{
  "steps": {
    "exported": {
      "robot": "/tus/store",
      "use": ":original",
      "endpoint": "https://tusd.tusdemo.net/files/"
    }
  }
}

Parameters

  • use

    String / Array of Strings / Object required

    Specifies which Step(s) to use as input.

    • You can pick any names for Steps except ":original" (reserved for user uploads handled by Transloadit)

    • You can provide several Steps as input with arrays:

      "use": [
        ":original",
        "encoded",
        "resized"
      ]
      

    💡 That’s likely all you need to know about use, but you can view Advanced use cases.

  • endpoint

    Stringrequired

    The URL of the Tus-compatible server, which you're uploading files to.

  • credentials

    String

    Create Template Credentials for this Robot in your Transloadit account and use the name of the Template Credentials as this parameter's value. For this Robot, use the HTTP template, which allows request headers to be passed along to the destination server.

  • headers

    Object

    Optional extra headers outside of the Template Credentials can be passed along within this parameter.

    Although, we recommend to exclusively use Template Credentials, this may be necessary if you're looking to use dynamic credentials, which isn't a feature supported by Template Credentials.

  • metadata

    Object ⋅ default: { "filename": "example.png", "basename": "example", "extension": "png" }

    Metadata to pass along to the Tus-compatible server with your file. Default values are always included, which contain some information on the uploaded file.

  • url_template

    String

    The URL of the file in the Assembly Status JSON. The following Assembly Variables are supported. If this is not specified, the upload URL specified by the destination server will be used instead.

  • ssl_url_template

    String

    The SSL URL of the file in the Assembly Status JSON. The following Assembly Variables are supported. If this is not specified, the upload URL specified by the destination server will be used instead, as long as it starts with https.

Note: The URLs in the result JSON already point to the file on your target storage platform, so you can just save that URL in your database.

Demos

Related blog posts