Convert Binary output from HTTP Get to screenshot URL

As the title suggests, I am trying to do a HTTP GET to RapidAPI to pull back the URL from a screenshot API.

I have the HTTP GET working fine, and returns 200 OK status but the data output is binary.

I have tried to create a set multiple variables module which then adds a function of either base64(2.data) or tostring(2.data). Neither of which give me the URL.

In RapidAPI I can see the output URL and it looks fine - how do I access this in MAKE?

Thanks!

Welcome to the Make community!

How does this output data look like?

1. Screenshots of module fields and filters

Please share screenshots of relevant module fields and filters in question? It would really help other community members to see what you’re looking at.

You can upload images here using the Upload icon in the text editor:

2. Scenario blueprint

Please export the scenario blueprint file to allow others to view the mappings and settings. At the bottom of the scenario editor, you can click on the three dots to find the Export Blueprint menu item.


(Note: Exporting your scenario will not include private information or keys to your connections)

Uploading it here will look like this:

blueprint.json (12.3 KB)

3. And most importantly, Input/Output bundles

Please provide the input and output bundles of the trigger/iterator/aggregator modules by running the scenario (or get from the scenario History tab), then click the white speech bubble on the top-right of each module and select “Download input/output bundles”.

A.

Save each bundle contents in your text editor as a bundle.txt file, and upload it here into this discussion thread.

Uploading them here will look like this:

module-1-output-bundle.txt (12.3 KB)

B.

If you are unable to upload files on this forum, alternatively you can paste the formatted bundles in this manner:

  • Either add three backticks ``` before and after the code, like this:

    ```
    input/output bundle content goes here
    ```

  • Or use the format code button in the editor:

Providing the input/output bundles will allow others to replicate what is going on in the scenario even if they do not use the external service.

Following these steps will allow others to assist you here. Thanks!

samliew – request private consultation

Join the Make Fans Discord server to chat with other makers!

1 Like

Sure here we go.

Blueprint:
url_to_screenshot_to_gsheet_v3.json (106.0 KB)

[
    {
        "statusCode": 200,
        "headers": [
            {
                "name": "date",
                "value": "Fri, 28 Jun 2024 05:11:27 GMT"
            },
            {
                "name": "content-type",
                "value": "image/png"
            },
            {
                "name": "content-length",
                "value": "125469"
            },
            {
                "name": "connection",
                "value": "close"
            },
            {
                "name": "via",
                "value": "1.1 ce855a64257bf53f14f7868e50f037d4.cloudfront.net (CloudFront)"
            },
            {
                "name": "x-amzn-requestid",
                "value": "b86d0453-1491-4c0f-8a8e-0af7b6707ac2"
            },
            {
                "name": "x-amzn-trace-id",
                "value": "Root=1-667e45fd-637a43df47ec1a500f8d76e4;Parent=47b47a38f1a452bf;Sampled=0;lineage=cd102c2a:0"
            },
            {
                "name": "x-amz-cf-id",
                "value": "rgp9dj0KQt56pm04p_XaR27GGdKm2WCGXCpgcDIbPmrj8DdzdyjW9Q=="
            },
            {
                "name": "x-amz-cf-pop",
                "value": "DUB56-P2"
            },
            {
                "name": "access-control-allow-credentials",
                "value": "true"
            },
            {
                "name": "x-cache",
                "value": "Miss from cloudfront"
            },
            {
                "name": "x-amz-apigw-id",
                "value": "aD_flEfKDoEEcvA="
            },
            {
                "name": "access-control-allow-origin",
                "value": "*"
            },
            {
                "name": "access-control-allow-headers",
                "value": "*"
            },
            {
                "name": "x-ratelimit-requests-limit",
                "value": "1000"
            },
            {
                "name": "x-ratelimit-requests-remaining",
                "value": "986"
            },
            {
                "name": "x-ratelimit-requests-reset",
                "value": "2528193"
            },
            {
                "name": "server",
                "value": "RapidAPI-1.2.8"
            },
            {
                "name": "x-rapidapi-version",
                "value": "1.2.8"
            },
            {
                "name": "x-rapidapi-region",
                "value": "AWS - eu-west-1"
            }
        ],
        "cookieHeaders": [],
        "data": "IMTBuffer(125469, binary, 8675afd2d0681852cc7d7dc0014d2a88f6b62264): 89504e470d0a1a0a0000000d4948445200000400000003300806000000bec012a00000200049444154789cecdd777814d5fec7f1cf6e76373d9042024448420d55918e8a8060c70e82a8a02257d10bfa53510445c52b967b6d57454541a5491151144190",
        "fileSize": 125469
    }
]

Ah, I know what’s the problem now. You need to upload the image to a file hosting storage like Google Drive, before you can get a URL.

A URL is a public address to a resource on the internet. Currently your image is not “hosted” on the internet, so you need to upload it somewhere first.

You can find some other file hosting services here https://www.make.com/en/integrations

samliew – request private consultation

Join the Make Fans Discord server to chat with other makers!

2 Likes

Ok, I’m a bit confused - so I can’t just ‘pull’ that URL from the API output and use it in other modules further along in the scenario? I really just want to inject that URL into gsheets cells in later modules via a router.

I have to go HTTP GET → Gdrive → Gsheets?

Thanks

According to the API documentation,

Screenshot_2024-06-28_140604

So no, there is no URL, and you have to organise that yourself.

samliew – request private consultation

Join the Make Fans Discord server to chat with other makers!

2 Likes