    let response = undefined;

    response = await client.call('{{ method.method | caseLower }}', apiPath, {
{% for parameter in method.parameters.header %}
        '{{ parameter.name }}': ${{ parameter.name | caseCamel | escapeKeyword }},
{% endfor %}
{% for key, header in method.headers %}
        '{{ key }}': '{{ header }}',
{% endfor %}
    }, payload{% if method.type == 'location' %}, 'arraybuffer'{% endif %});

    {%~ if method.type == 'location' %}
    if (overrideForCli) {
        response = Buffer.from(response);
    }

    fs.writeFileSync(destination, response);
    {%~ endif %}
    if (parseOutput) {
    {%~ if hasConsolePreview(method.name,service.name) %}
        if(console) {
            showConsoleLink('{{service.name}}', '{{ method.name }}'
        {%- for parameter in method.parameters.path -%}{%- set param = (parameter.name | caseCamel | escapeKeyword)  -%}{%- if param  ends with 'Id' -%}, {{ param }} {%- endif -%}{%- endfor -%}
            );
         } else {
            parse(response)
        }
    {%~ else %}
        parse(response)
    {%~ endif %}
    }

    return response;
