> For the complete documentation index, see [llms.txt](https://docs.coherent.global/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.coherent.global/assistant/custom-functions/xcall-legacy-functions/getoutput.md).

# GETOUTPUT

{% hint style="warning" %}
This is an outdated custom function which we have replaced with [SPARK\_XCALL](/assistant/custom-functions/spark_xcall.md). This is available through the add-in for backward compatibility.
{% endhint %}

## Syntax

`CS.SPARK_GETOUTPUT(xcall_block, output_name)`

* `xcall_block`. Required. Range address of the XCall block in upstream service. E.g. `$A$1:$B$4`. You can also use a named range for convenience.
* `output_name`. Required. Name of the requested output.

### UDFCall Block

Create a [UDFCALLAPI](/assistant/custom-functions/xcall-legacy-functions/udfcallapi.md) block in the Excel workbook (upstream service) to make an API call. The UDFCall block can be anywhere in your workbook but must be on the same sheet as your `Spark_UdfCallAPI` function.

* This table needs to include
  * `CALLTYPE`: `SparkService`
  * `FOLDERNAME`: name of the folder containing downstream service.
  * `SERVICENAME`: name of downstream service.
  * `REQUESTBODY`: payload for calling downstream service. Must be in JSON format. You can copy the `REQUESTBODY` from downstream service API tester. If this is your first time using the SparkService we encourage to leave content of "request\_meta" empty. Spark will use the latest version and the default Service Type to execute this service.
* XCall block example

<figure><img src="/files/nNJdVV6JDnRYZem9ZoXr" alt="" width="330"><figcaption></figcaption></figure>

* `REQUESTBODY` example (v3 format)

```json
{
    "request_data": {
        "inputs": {
            "InputField": "InputValue"
        }
    },
    "request_meta": {}
}
```

## Output

The function will return the value of the output that is selected.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.coherent.global/assistant/custom-functions/xcall-legacy-functions/getoutput.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
