# API Call History APIs

APIs for accessing the *API Call History*.

## Get Call ID

> Get the details of an API call from the \_API Call History\_.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadAPILog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"callId":{"name":"callId","in":"path","required":true,"description":"Execute API `call_id`.","schema":{"type":"string","format":"uuid"}}}},"paths":{"/{tenant}/api/v3/log/getexecutionhistorybycallid/{callId}":{"get":{"tags":["API Call History APIs"],"summary":"Get Call ID","description":"Get the details of an API call from the _API Call History_.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadAPILog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"getLogGetExecutionHistoryByCallid","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/callId"},{"name":"index","in":"query","required":false,"description":"Index number for the record to get. With `v4/execute`, multiple request records can be submitted at once.","schema":{"type":"integer","minimum":0}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```

## Download as Excel

> Get a copy of the original Excel file with inputs embedded with the \_API Call History\_ for an Execute API \`call\_id\`.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadAPILog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"folder":{"name":"folder","in":"path","required":true,"description":"Folder associated with the API call.","schema":{"type":"string"}},"service":{"name":"service","in":"path","required":true,"description":"Service associated with the API call.","schema":{"type":"string"}},"callId":{"name":"callId","in":"path","required":true,"description":"Execute API `call_id`.","schema":{"type":"string","format":"uuid"}}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/download/xml/{callId}":{"post":{"tags":["API Call History APIs"],"summary":"Download as Excel","description":"Get a copy of the original Excel file with inputs embedded with the _API Call History_ for an Execute API `call_id`.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadAPILog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"getDownloadXML","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"},{"$ref":"#/components/parameters/callId"}],"requestBody":{"required":true,"description":"The request body should be empty or `{}`.","content":{"application/json":{"schema":{"type":"object"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```

## Download Log as CSV post log job

> Get a ZIP of CSV files from the \_API Call History\_ of a Spark service. This is equivalent to the \_API Call History\_ functionality to \_Download all API calls\_, \_Download as CSV\_.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadCsvLog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"folder":{"name":"folder","in":"path","required":true,"description":"Folder associated with the API call.","schema":{"type":"string"}},"service":{"name":"service","in":"path","required":true,"description":"Service associated with the API call.","schema":{"type":"string"}}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/log/downloadcsv":{"post":{"tags":["API Call History APIs"],"summary":"Download Log as CSV post log job","description":"Get a ZIP of CSV files from the _API Call History_ of a Spark service. This is equivalent to the _API Call History_ functionality to _Download all API calls_, _Download as CSV_.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadCsvLog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"postLogDownloadCSV","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"request_data":{"type":"object","properties":{"timezone_offset":{"type":"integer","description":"Number of hours to adjust the returned timestamps."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"string","format":"date-time"}],"description":"Timestamp for start log time filter. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert dates to ISO 8601."},"end_date":{"anyOf":[{"type":"null"},{"type":"string","format":"date"},{"type":"string","format":"date-time"}],"description":"Timestamp for end log time filter. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert dates to ISO 8601."},"call_ids":{"type":["null","array"],"items":{"type":"string"},"description":"Array containing `call_id`s, or single element `correlation_id`, or single element `source_system` to filter."},"callpurpose":{"type":["null","string"],"description":"`call_purpose` to filter."},"userName":{"type":["null","string"],"description":"Username to filter."},"has_warnings":{"type":["null","boolean"],"description":"Filter calls with warnings."},"has_errors":{"type":["null","boolean"],"description":"Filter calls with errors."}}},"request_meta":{"type":"object","properties":{"version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`version_id` to filter for a specific service version."}}}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```

## Download Log as CSV get log job status

> Get a ZIP of CSV files from the \_API Call History\_ of a Spark service. This is equivalent to the \_API Call History\_ functionality to \_Download all API calls\_, \_Download as CSV\_.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadCsvLog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"folder":{"name":"folder","in":"path","required":true,"description":"Folder associated with the API call.","schema":{"type":"string"}},"service":{"name":"service","in":"path","required":true,"description":"Service associated with the API call.","schema":{"type":"string"}},"jobId":{"name":"jobId","in":"path","required":true,"description":"`job_id` associated from `POST` job.","schema":{"type":"string","format":"uuid"}}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/log/downloadcsv/status/{jobId}":{"get":{"tags":["API Call History APIs"],"summary":"Download Log as CSV get log job status","description":"Get a ZIP of CSV files from the _API Call History_ of a Spark service. This is equivalent to the _API Call History_ functionality to _Download all API calls_, _Download as CSV_.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadCsvLog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"getLogDownloadCSVStatus","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"},{"$ref":"#/components/parameters/jobId"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```

## Download Log as JSON post log job

> Get a ZIP of JSON files from the \_API Call History\_ of a Spark service. This is equivalent to the \_API Call History\_ functionality to \_Download all API calls\_, \_Download as JSON\_.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadJSONLog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"folder":{"name":"folder","in":"path","required":true,"description":"Folder associated with the API call.","schema":{"type":"string"}},"service":{"name":"service","in":"path","required":true,"description":"Service associated with the API call.","schema":{"type":"string"}}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/log/downloadJSON":{"post":{"tags":["API Call History APIs"],"summary":"Download Log as JSON post log job","description":"Get a ZIP of JSON files from the _API Call History_ of a Spark service. This is equivalent to the _API Call History_ functionality to _Download all API calls_, _Download as JSON_.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadJSONLog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"postLogDownloadJSON","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"request_data":{"type":"object","properties":{"timezone_offset":{"type":"integer","description":"Number of hours to adjust the returned timestamps."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"string","format":"date-time"}],"description":"Timestamp for start log time filter. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert dates to ISO 8601."},"end_date":{"anyOf":[{"type":"null"},{"type":"string","format":"date"},{"type":"string","format":"date-time"}],"description":"Timestamp for end log time filter. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert dates to ISO 8601."},"call_ids":{"type":["null","array"],"items":{"type":["null","string"]},"description":"Array containing `call_id`s, or single element `correlation_id`, or single element `source_system` to filter."},"callpurpose":{"type":["null","string"],"description":"`call_purpose` to filter."},"userName":{"type":["null","string"],"description":"Username to filter."},"has_warnings":{"type":["null","boolean"],"description":"Filter calls with warnings."},"has_errors":{"type":["null","boolean"],"description":"Filter calls with errors."}}},"request_meta":{"type":"object","properties":{"version_id":{"type":"string","format":"uuid","description":"`version_id` to filter for a specific service version."}}}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```

## Download Log as JSON get log job status

> Get a ZIP of JSON files from the \_API Call History\_ of a Spark service. This is equivalent to the \_API Call History\_ functionality to \_Download all API calls\_, \_Download as JSON\_.\<br>\<br> If using an API key, the API key group must contain user groups that are also assigned to \`Spark.DownloadJSONLog.json\` or \`Spark.AllEncompassingProxy.json\`.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"API Call History APIs","description":"APIs for accessing the _API Call History_."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironmentname"}}}],"security":[{"bearerToken":[]},{"tenantName":[],"syntheticKey":[]}],"components":{"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token can be accessed from the user menu."},"tenantName":{"type":"apiKey","in":"header","name":"x-tenant-name","description":"Tenant name header required when using API key authentication."}},"parameters":{"tenant":{"name":"tenant","in":"path","required":true,"description":"Tenant is part of your login URL and also available in the user menu.","schema":{"type":"string"}},"folder":{"name":"folder","in":"path","required":true,"description":"Folder associated with the API call.","schema":{"type":"string"}},"service":{"name":"service","in":"path","required":true,"description":"Service associated with the API call.","schema":{"type":"string"}},"jobId":{"name":"jobId","in":"path","required":true,"description":"`job_id` associated from `POST` job.","schema":{"type":"string","format":"uuid"}}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/log/downloadJSON/status/{jobId}":{"get":{"tags":["API Call History APIs"],"summary":"Download Log as JSON get log job status","description":"Get a ZIP of JSON files from the _API Call History_ of a Spark service. This is equivalent to the _API Call History_ functionality to _Download all API calls_, _Download as JSON_.<br><br> If using an API key, the API key group must contain user groups that are also assigned to `Spark.DownloadJSONLog.json` or `Spark.AllEncompassingProxy.json`.","operationId":"getLogDownloadJSONStatus","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"},{"$ref":"#/components/parameters/jobId"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}}}}
```


---

# Agent Instructions: 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/spark-apis/spark-openapi-specification/api-call-history-apis.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.
