> 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/spark-apis/spark-openapi-specification/metadata-apis.md).

# Metadata APIs

Get `metadata` subservice data from a Spark service. Depending on the desired reference parameter, different URIs are available.

## Reference by folder and service

> In Excel, the name \`Xoutput\_metadata.\<parameter>\` is used to define the \`metadata\` subservice.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"Metadata APIs","description":"Get `metadata` subservice data from a Spark service. Depending on the desired reference parameter, different URIs are available."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironment"}}}],"security":[{"bearerAuth":[]},{"tenantName":[],"apiKeyAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"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 sign-in 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"}}},"responses":{"metadata":{"description":"OK","headers":{"spark_total_time":{"schema":{"type":"number","description":"The time it took for Spark to process the inputs, perform the calculation, execute any `Ximage`, `Xreport`, `Xsolve` parameters in `ms`. This does not include any transit time."}},"X-RateLimit-Limit":{"schema":{"type":"number","description":"Spark rate limiter value."}},"X-RateLimit-Remaining":{"schema":{"type":"number","description":"Remaining calls for the rate limiter."}},"X-RateLimit-Reset":{"schema":{"type":"number","description":"[Unix epoch time](https://en.wikipedia.org/wiki/Unix_time) representing when the rate limit is reset. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert to ISO 8601."}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v3EngineApiResponseEntity"}}}}},"schemas":{"v3EngineApiResponseEntity":{"type":"object","properties":{"status":{"type":["null","string"],"description":"API response status."},"response_data":{"$ref":"#/components/schemas/v3EngineResponseData"},"response_meta":{"$ref":"#/components/schemas/v3EngineResponseMetadata"},"error":{"$ref":"#/components/schemas/v3ResponseError"},"traceEvents":{"type":["null","array"],"description":"Trace event data returned when \"`profile\": true`.","items":{"type":"object"}}},"additionalProperties":false},"v3EngineResponseData":{"type":"object","properties":{"outputs":{"$ref":"#/components/schemas/v3ServiceOutputs"},"warnings":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionValidation"},"description":"Array of warnings."},"errors":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionError"},"description":"Array of errors."},"inputs":{"type":["null","object"],"description":"Inputs from the request will be returned in the response if the `request_meta` `response_data_inputs` is `true`."},"trace":{"type":["null","object"]}},"additionalProperties":false},"v3ServiceOutputs":{"type":"object","description":"Object that contains key value pairs returned from the Spark service. See documentation for more information."},"v3EngineExecutionValidation":{"type":"object","description":"Object for describing validation warnings.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the validation message."},"message":{"type":["null","string"],"description":"Validation message."}},"additionalProperties":false},"v3EngineExecutionError":{"type":"object","description":"Object for describing errors.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the error."},"message":{"type":["null","string"],"description":"Error message."},"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"additional_details":{"type":["null","string"],"description":"Additional error details."}},"additionalProperties":false},"v3EngineResponseMetadata":{"type":"object","properties":{"system":{"type":["null","string"],"description":"System that processed the request."},"request_timestamp":{"oneOf":[{"type":"null"},{"type":"string","format":"date-time"}],"description":"Request timestamp."},"service_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`service_id` of the resolved service."},"version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`version_id` of the resolved service version."},"version":{"type":["null","string"],"description":"Resolved service version number."},"process_time":{"type":["null","integer"],"description":"Time for Spark to process the API call in `ms`."},"call_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Universally unique identifier for this API call. This can be referenced in the **API Call History**."},"compiler_type":{"type":["null","string"],"description":"Calculation engine used by Spark to process the request."},"compiler_version":{"type":["null","string"],"description":"Calculation engine by Spark to process the request."},"source_hash":{"type":["null","string"]},"engine_id":{"type":["null","string"],"description":"Hash generated for this service."},"correlation_id":{"type":["null","string"],"description":"Value from request body."},"response_data_inputs":{"type":["null","boolean"],"description":"Value from request body."},"array_outputs":{"type":["null","string"],"description":"Value from request body."},"random_seed":{"type":["null","integer"],"description":"Value from request body."},"show_max_calc_chain":{"type":["null","boolean"],"description":"Value from request body."},"profile":{"type":["null","boolean"],"description":"Value from request body."},"trace":{"type":["null","boolean"],"description":"Value from request body."},"debug_build":{"type":["null","boolean"],"description":"Indicate if this service was compiled using the debug build."},"top_n_profile":{"type":["null","integer"],"description":"Value from request body."},"parameterset_version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Value from request body."},"xconnector_parse_mode":{"type":["null","integer"],"description":"Value from request body."},"debug_xcall":{"type":["null","boolean"],"description":"Value from request body."},"debug_solve":{"type":["null","boolean"],"description":"Value from request body."},"manual_now":{"type":["null","integer"],"description":"Value from request body."}},"additionalProperties":true},"v3ResponseError":{"type":"object","description":"Object for describing errors.","properties":{"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"message":{"type":["null","string"],"description":"Error message."},"additional_details":{"type":["null","object"],"description":"Additional error details."}},"additionalProperties":false}}},"paths":{"/{tenant}/api/v3/folders/{folder}/services/{service}/metadata":{"get":{"tags":["Metadata APIs"],"summary":"Reference by folder and service","description":"In Excel, the name `Xoutput_metadata.<parameter>` is used to define the `metadata` subservice.","operationId":"getFoldersServicesMetadata","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/folder"},{"$ref":"#/components/parameters/service"}],"responses":{"200":{"$ref":"#/components/responses/metadata"}}}}}}
```

## Reference by service\_id

> In Excel, the name \`Xoutput\_metadata.\<parameter>\` is used to define the \`metadata\` subservice.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"Metadata APIs","description":"Get `metadata` subservice data from a Spark service. Depending on the desired reference parameter, different URIs are available."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironment"}}}],"security":[{"bearerAuth":[]},{"tenantName":[],"apiKeyAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"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 sign-in URL and also available in the user menu.","schema":{"type":"string"}},"serviceId":{"name":"serviceId","in":"path","required":true,"description":"`service_id` of the requested service.","schema":{"type":"string","format":"uuid"}}},"responses":{"metadata":{"description":"OK","headers":{"spark_total_time":{"schema":{"type":"number","description":"The time it took for Spark to process the inputs, perform the calculation, execute any `Ximage`, `Xreport`, `Xsolve` parameters in `ms`. This does not include any transit time."}},"X-RateLimit-Limit":{"schema":{"type":"number","description":"Spark rate limiter value."}},"X-RateLimit-Remaining":{"schema":{"type":"number","description":"Remaining calls for the rate limiter."}},"X-RateLimit-Reset":{"schema":{"type":"number","description":"[Unix epoch time](https://en.wikipedia.org/wiki/Unix_time) representing when the rate limit is reset. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert to ISO 8601."}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v3EngineApiResponseEntity"}}}}},"schemas":{"v3EngineApiResponseEntity":{"type":"object","properties":{"status":{"type":["null","string"],"description":"API response status."},"response_data":{"$ref":"#/components/schemas/v3EngineResponseData"},"response_meta":{"$ref":"#/components/schemas/v3EngineResponseMetadata"},"error":{"$ref":"#/components/schemas/v3ResponseError"},"traceEvents":{"type":["null","array"],"description":"Trace event data returned when \"`profile\": true`.","items":{"type":"object"}}},"additionalProperties":false},"v3EngineResponseData":{"type":"object","properties":{"outputs":{"$ref":"#/components/schemas/v3ServiceOutputs"},"warnings":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionValidation"},"description":"Array of warnings."},"errors":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionError"},"description":"Array of errors."},"inputs":{"type":["null","object"],"description":"Inputs from the request will be returned in the response if the `request_meta` `response_data_inputs` is `true`."},"trace":{"type":["null","object"]}},"additionalProperties":false},"v3ServiceOutputs":{"type":"object","description":"Object that contains key value pairs returned from the Spark service. See documentation for more information."},"v3EngineExecutionValidation":{"type":"object","description":"Object for describing validation warnings.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the validation message."},"message":{"type":["null","string"],"description":"Validation message."}},"additionalProperties":false},"v3EngineExecutionError":{"type":"object","description":"Object for describing errors.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the error."},"message":{"type":["null","string"],"description":"Error message."},"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"additional_details":{"type":["null","string"],"description":"Additional error details."}},"additionalProperties":false},"v3EngineResponseMetadata":{"type":"object","properties":{"system":{"type":["null","string"],"description":"System that processed the request."},"request_timestamp":{"oneOf":[{"type":"null"},{"type":"string","format":"date-time"}],"description":"Request timestamp."},"service_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`service_id` of the resolved service."},"version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`version_id` of the resolved service version."},"version":{"type":["null","string"],"description":"Resolved service version number."},"process_time":{"type":["null","integer"],"description":"Time for Spark to process the API call in `ms`."},"call_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Universally unique identifier for this API call. This can be referenced in the **API Call History**."},"compiler_type":{"type":["null","string"],"description":"Calculation engine used by Spark to process the request."},"compiler_version":{"type":["null","string"],"description":"Calculation engine by Spark to process the request."},"source_hash":{"type":["null","string"]},"engine_id":{"type":["null","string"],"description":"Hash generated for this service."},"correlation_id":{"type":["null","string"],"description":"Value from request body."},"response_data_inputs":{"type":["null","boolean"],"description":"Value from request body."},"array_outputs":{"type":["null","string"],"description":"Value from request body."},"random_seed":{"type":["null","integer"],"description":"Value from request body."},"show_max_calc_chain":{"type":["null","boolean"],"description":"Value from request body."},"profile":{"type":["null","boolean"],"description":"Value from request body."},"trace":{"type":["null","boolean"],"description":"Value from request body."},"debug_build":{"type":["null","boolean"],"description":"Indicate if this service was compiled using the debug build."},"top_n_profile":{"type":["null","integer"],"description":"Value from request body."},"parameterset_version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Value from request body."},"xconnector_parse_mode":{"type":["null","integer"],"description":"Value from request body."},"debug_xcall":{"type":["null","boolean"],"description":"Value from request body."},"debug_solve":{"type":["null","boolean"],"description":"Value from request body."},"manual_now":{"type":["null","integer"],"description":"Value from request body."}},"additionalProperties":true},"v3ResponseError":{"type":"object","description":"Object for describing errors.","properties":{"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"message":{"type":["null","string"],"description":"Error message."},"additional_details":{"type":["null","object"],"description":"Additional error details."}},"additionalProperties":false}}},"paths":{"/{tenant}/api/v3/service/{serviceId}/metadata":{"get":{"tags":["Metadata APIs"],"summary":"Reference by service_id","description":"In Excel, the name `Xoutput_metadata.<parameter>` is used to define the `metadata` subservice.","operationId":"getv3ServiceMetadata","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/serviceId"}],"responses":{"200":{"$ref":"#/components/responses/metadata"}}}}}}
```

## Reference by version\_id

> In Excel, the name \`Xoutput\_metadata.\<parameter>\` is used to define the \`metadata\` subservice.

```json
{"openapi":"3.1.0","info":{"title":"Spark OpenAPI specification","version":"0.1.0"},"tags":[{"name":"Metadata APIs","description":"Get `metadata` subservice data from a Spark service. Depending on the desired reference parameter, different URIs are available."}],"servers":[{"url":"https://excel.{environment}.coherent.global","variables":{"environment":{"default":"myenvironment"}}}],"security":[{"bearerAuth":[]},{"tenantName":[],"apiKeyAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"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 sign-in URL and also available in the user menu.","schema":{"type":"string"}},"versionId":{"name":"versionId","in":"path","required":true,"description":"`version_id` of the requested service.","schema":{"type":"string","format":"uuid"}}},"responses":{"executeV3":{"description":"OK","headers":{"spark_total_time":{"schema":{"type":"number","description":"The time it took for Spark to process the inputs, perform the calculation, execute any `Ximage`, `Xreport`, `Xsolve` parameters in `ms`. This does not include any transit time."}},"X-RateLimit-Limit":{"schema":{"type":"number","description":"Spark rate limiter value."}},"X-RateLimit-Remaining":{"schema":{"type":"number","description":"Remaining calls for the rate limiter."}},"X-RateLimit-Reset":{"schema":{"type":"number","description":"[Unix epoch time](https://en.wikipedia.org/wiki/Unix_time) representing when the rate limit is reset. Use [Timestamp converter](https://www.timestamp-converter.com/) to convert to ISO 8601."}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v3EngineApiResponseEntity"}}}}},"schemas":{"v3EngineApiResponseEntity":{"type":"object","properties":{"status":{"type":["null","string"],"description":"API response status."},"response_data":{"$ref":"#/components/schemas/v3EngineResponseData"},"response_meta":{"$ref":"#/components/schemas/v3EngineResponseMetadata"},"error":{"$ref":"#/components/schemas/v3ResponseError"},"traceEvents":{"type":["null","array"],"description":"Trace event data returned when \"`profile\": true`.","items":{"type":"object"}}},"additionalProperties":false},"v3EngineResponseData":{"type":"object","properties":{"outputs":{"$ref":"#/components/schemas/v3ServiceOutputs"},"warnings":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionValidation"},"description":"Array of warnings."},"errors":{"type":["null","array"],"items":{"$ref":"#/components/schemas/v3EngineExecutionError"},"description":"Array of errors."},"inputs":{"type":["null","object"],"description":"Inputs from the request will be returned in the response if the `request_meta` `response_data_inputs` is `true`."},"trace":{"type":["null","object"]}},"additionalProperties":false},"v3ServiceOutputs":{"type":"object","description":"Object that contains key value pairs returned from the Spark service. See documentation for more information."},"v3EngineExecutionValidation":{"type":"object","description":"Object for describing validation warnings.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the validation message."},"message":{"type":["null","string"],"description":"Validation message."}},"additionalProperties":false},"v3EngineExecutionError":{"type":"object","description":"Object for describing errors.","properties":{"source_path":{"type":["null","string"],"description":"Source path of the error."},"message":{"type":["null","string"],"description":"Error message."},"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"additional_details":{"type":["null","string"],"description":"Additional error details."}},"additionalProperties":false},"v3EngineResponseMetadata":{"type":"object","properties":{"system":{"type":["null","string"],"description":"System that processed the request."},"request_timestamp":{"oneOf":[{"type":"null"},{"type":"string","format":"date-time"}],"description":"Request timestamp."},"service_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`service_id` of the resolved service."},"version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"`version_id` of the resolved service version."},"version":{"type":["null","string"],"description":"Resolved service version number."},"process_time":{"type":["null","integer"],"description":"Time for Spark to process the API call in `ms`."},"call_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Universally unique identifier for this API call. This can be referenced in the **API Call History**."},"compiler_type":{"type":["null","string"],"description":"Calculation engine used by Spark to process the request."},"compiler_version":{"type":["null","string"],"description":"Calculation engine by Spark to process the request."},"source_hash":{"type":["null","string"]},"engine_id":{"type":["null","string"],"description":"Hash generated for this service."},"correlation_id":{"type":["null","string"],"description":"Value from request body."},"response_data_inputs":{"type":["null","boolean"],"description":"Value from request body."},"array_outputs":{"type":["null","string"],"description":"Value from request body."},"random_seed":{"type":["null","integer"],"description":"Value from request body."},"show_max_calc_chain":{"type":["null","boolean"],"description":"Value from request body."},"profile":{"type":["null","boolean"],"description":"Value from request body."},"trace":{"type":["null","boolean"],"description":"Value from request body."},"debug_build":{"type":["null","boolean"],"description":"Indicate if this service was compiled using the debug build."},"top_n_profile":{"type":["null","integer"],"description":"Value from request body."},"parameterset_version_id":{"oneOf":[{"type":"null"},{"type":"string","format":"uuid"}],"description":"Value from request body."},"xconnector_parse_mode":{"type":["null","integer"],"description":"Value from request body."},"debug_xcall":{"type":["null","boolean"],"description":"Value from request body."},"debug_solve":{"type":["null","boolean"],"description":"Value from request body."},"manual_now":{"type":["null","integer"],"description":"Value from request body."}},"additionalProperties":true},"v3ResponseError":{"type":"object","description":"Object for describing errors.","properties":{"error_category":{"type":["null","string"],"description":"Error category."},"error_type":{"type":["null","string"],"description":"Error type."},"message":{"type":["null","string"],"description":"Error message."},"additional_details":{"type":["null","object"],"description":"Additional error details."}},"additionalProperties":false}}},"paths":{"/{tenant}/api/v3/version/{versionId}/metadata":{"get":{"tags":["Metadata APIs"],"summary":"Reference by version_id","description":"In Excel, the name `Xoutput_metadata.<parameter>` is used to define the `metadata` subservice.","operationId":"getv3VersionMetadata","parameters":[{"$ref":"#/components/parameters/tenant"},{"$ref":"#/components/parameters/versionId"}],"responses":{"200":{"$ref":"#/components/responses/executeV3"}}}}}}
```
