How to import file from Integromat module?

Hey, I’m using Transloadit via Integromat (a no-code automation service similar to Zapier).

I’m using the /video/thumbs template, and the Integromat module is POSTing the video .mp4 URL as a field called ‘url’ when the assembly runs.

My question: How do I modify my code to retrieve that file??

Here’s a screenshot of the Transloadit module in Integromat

And here’s my Transloadit code:
{
“steps”: {
“:original”: {
“robot”: “/upload/handle”
},
“ipad_encoded”: {
“use”: “:original”,
“robot”: “/video/encode”,
“ffmpeg_stack”: “v4.3.1”,
“height”: 480,
“preset”: “ipad-high”,
“turbo”: true,
“width”: 640
},
“thumbnailed”: {
“use”: “ipad_encoded”,
“robot”: “/video/thumbs”,
“count”: 10,
“ffmpeg_stack”: “v4.3.1”
},
“large_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 120,
“imagemagick_stack”: “v2.0.7”,
“width”: 120
},
“medium_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 75,
“imagemagick_stack”: “v2.0.7”,
“width”: 75
},
“small_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 30,
“imagemagick_stack”: “v2.0.7”,
“width”: 30
},
“exported”: {
“use”: [
“ipad_encoded”,
“thumbnailed”,
“small_resized”,
“medium_resized”,
“large_resized”,
“:original”
],
“robot”: “/s3/store”,
“credentials”: “YOUR_AWS_CREDENTIALS”
}
}
}

Hi there!

You can use our /http/import Robot to use the video in your template.

For example, you would replace “:original” with “import” like so:

"import": {
  "robot": "/http/import",
  "url": "${fields.url}"
}

Then adjust the rest of your template respectively to use the new step, and it should work :+1:

Hope this answers your question!

Thank you! For anyone else with this problem, here’s the full working code:

{
“steps”: {
“:import”: {
“robot”: “/http/import”,
“url”: “${fields.url}”
},
“ipad_encoded”: {
“use”: “:import”,
“robot”: “/video/encode”,
“ffmpeg_stack”: “v4.3.1”,
“height”: 480,
“preset”: “ipad-high”,
“turbo”: true,
“width”: 640
},
“thumbnailed”: {
“use”: “ipad_encoded”,
“robot”: “/video/thumbs”,
“count”: 10,
“ffmpeg_stack”: “v4.3.1”
},
“large_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 120,
“imagemagick_stack”: “v2.0.7”,
“width”: 120
},
“medium_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 75,
“imagemagick_stack”: “v2.0.7”,
“width”: 75
},
“small_resized”: {
“use”: “thumbnailed”,
“robot”: “/image/resize”,
“result”: true,
“height”: 30,
“imagemagick_stack”: “v2.0.7”,
“width”: 30
},
“exported”: {
“use”: [
“ipad_encoded”,
“thumbnailed”,
“small_resized”,
“medium_resized”,
“large_resized”,
“:original”
],
“robot”: “/s3/store”,
“credentials”: “YOUR_AWS_CREDENTIALS”
}
}
}

Hi, is “url”: “${fields.url}” definitely the correct code?

When I put my URL in directly it works
“url”: “https://i.imgur.com/D4xkXay.mp4

When I put in the code
“url”: “${fields.url}”

It sometimes works, but often returns the error:

  • The operation failed with an error. [500] CurlCommand failed with exit code: 22: HTTP page not retrieved. The requested url was not found or returned another error with the HTTP error code being 400 or above. This return code only appears if -f/–fail is used. Tried to connect to host: https://i.imgur.com/xVdJ9aF.mp4

The field should work. Can you send a failing assembly ID please? I’ll take a look for you :slight_smile: