Retrieve BLOB of image URL on Exact Online

When I have an image url like:

    select act.LogoThumbnailUrl
    from   exactonlinerest..accounts act
    limit  10

how can I retrieve the logo across the secured Exact Online connection?

The logo retrieved on the URL without Exact Online connection is a stub image.

You can directly retrieve the thumbnails using ThumbnailByUrl:

    select t.*
    from   exactonlinerest..accounts
    join   ThumbnailByUrl(act.logothumbnailurl) t

Or with a custom size using ThumbnailByRow:

    select t.*
    from   exactonlinerest..accounts act
    join   thumbnailbyrow(act.division, 'Accounts', act.id, 32) t
    limit  10

Result example:

You can also send HTTP requests across the secured connection with Exact Online using the NativePlatformScalarRequests table. It is available for all platforms and allows you to send native requests. For Exact Online it are HTTP requests, for MySQL it are MySQL-specific SQL statements.

The results are returned as blob or text.

An example to retrieve the logos:

    --
     -- Request logos.
    --
    insert into NATIVEPLATFORMSCALARREQUESTS
    ( url
    , blob_preferred
    , orig_system_group
    , orig_system_reference
    )
    select act.LogoThumbnailUrl
    ,      true
    ,      'act'
    ,      'act-' || to_char(act.id)
    from   exactonlinerest..accounts@eol act
    --
    -- Skip default and missing icons.
    --
    where  logothumbnailurl not like '%placeholder%'
    and    coalesce(length(logothumbnailurl), 0) > 0

    --
    -- Get the logos.
    --
    select orig_system_reference
    ,      result_blob
    from   NATIVEPLATFORMSCALARREQUESTS

Example of result:

You can export these images to a database using an Invantive SQL insert statement or export to file system using for instance:

local export documents in result_blob to "c:\temp" filename automatic