---
title: "invoke-dynamic-image | Customer&#x27;s Canvas Hub"
canonical: "https://customerscanvas.com/docs/hub/printer-guide/pipelines/tasks/invoke-dynamic-image/"
---

# invoke-dynamic-image

> Learn how the invoke-dynamic-image task calls Dynamic Image functions and saves results.

This task calls the functions of the Dynamic Image application. The execution result is saved as an artifact. 

The dynamic-image address is automatically extracted from the tenant settings in BackOffice using the corresponding storefront API request.

## Parameters

- `command` (string) - The name of the callable dynamic-image function. 
- `commandPrefix` (string) - _(optional)_ The prefix of the callable dynamic-image function (`api/v2/rendering` by default). 
- `commandArgs` (string) - The parameters for calling the dynamic-image function, which will be passed as a query string.
- `body` - The request parameters.

These parameters support [argument interpolation](https://customerscanvas.com/docs/hub/printer-guide/pipelines/concepts/interpolation.md) following the common rules.

The URL for invoking the dynamic-image is composed using these parameters as follows: `<base-dynamic-image-url>/<commandPrefix>/<command>?<commandArgs>` where `<base-dynamic-image-url>` is taken from the tenant settings in BackOffice, and `<commandPrefix>`, `<command>`, and `<commandArgs>` are taken from the task parameters. 

## Example

``` json
{
    "description": "Perform imposition with 'Dynamic Image' application",
    "name": "perform-imposition",
    "type": "invoke-dynamic-image",
    "inputArtifacts": [
        "design"
    ],
    "parameters": {
        "command": "hires",
        "commandArgs" : "disableCache=true",
        "body": {
            "template": "template.psd",
            "data" : {
                "Layer 1": {
                    "type": "image",
                    "image": "{{design:url}}"
                }
            }
        }
    },
    "outputArtifacts": [
        "design"
    ]
}
```
