# Pipeline Search History Result

<Heading
  as={"h1"}
  className={"openapi__heading"}
  children={"Pipeline Search History Result"}
>
</Heading>

<MethodEndpoint
  method={"get"}
  path={"/api/v2/workspaces/{workspace_id}/pipelines/{pipeline_id}/search_history/{query_id}"}
  context={"endpoint"}
>
  
</MethodEndpoint>

Returns the search history for a specific query_id.

<Heading
  id={"request"}
  as={"h2"}
  className={"openapi-tabs__heading"}
  children={"Request"}
>
</Heading>

<ParamsDetails
  parameters={[{"description":"Unique identifier of a pipeline.","in":"path","name":"pipeline_id","required":true,"schema":{"description":"Unique identifier of a pipeline.","format":"uuid","title":"Pipeline Id","type":"string"}},{"description":"Unique identifier of the search query.","in":"path","name":"query_id","required":true,"schema":{"description":"Unique identifier of the search query.","format":"uuid","title":"Query Id","type":"string"}},{"description":"Type the id of the workspace.","in":"path","name":"workspace_id","required":true,"schema":{"description":"Type the id of the workspace.","format":"uuid","title":"Workspace Id","type":"string"}}]}
>
  
</ParamsDetails>

<RequestSchema
  title={"Body"}
  body={undefined}
>
  
</RequestSchema>

<StatusCodes
  id={undefined}
  label={undefined}
  responses={{"200":{"content":{"application/json":{"schema":{"properties":{"_debug":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Debug"},"answers":{"default":[],"description":"List of deepset answers.","items":{"properties":{"answer":{"title":"Answer","type":"string"},"context":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"},{"type":"null"}],"description":"Context of the answer.","title":"Context"},"document_id":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ID of the document.","title":"Document ID"},"document_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"description":"IDs of the document.","title":"Document IDs"},"file":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"description":"Object containing the `file_id` and `name` of a file. This is used to associate a document with a file.","title":"File Reference Object (deprecated, use `files` instead)"},"files":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"description":"List of objects containing the `file_id` and `name` of a file. This is used to associate an answer with its source files.","title":"File Reference Objects"},"meta":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"description":"The metadata of this document.","title":"Metadata of file"},"offsets_in_context":{"anyOf":[{"items":{"properties":{"end":{"description":"End of span.","title":"End","type":"integer"},"start":{"description":"Start of span.","title":"Start","type":"integer"}},"required":["start","end"],"title":"DeepsetCloudSpan","type":"object"},"type":"array"},{"items":{"properties":{"col":{"description":"Column of the answer.","title":"Column","type":"integer"},"row":{"description":"Row of the answer.","title":"Row","type":"integer"}},"required":["row","col"],"title":"DeepsetCloudTableCell","type":"object"},"type":"array"},{"type":"null"}],"description":"Offsets of the answer in the context.","title":"Offsets in Context"},"offsets_in_document":{"anyOf":[{"items":{"properties":{"end":{"description":"End of span.","title":"End","type":"integer"},"start":{"description":"Start of span.","title":"Start","type":"integer"}},"required":["start","end"],"title":"DeepsetCloudSpan","type":"object"},"type":"array"},{"items":{"properties":{"col":{"description":"Column of the answer.","title":"Column","type":"integer"},"row":{"description":"Row of the answer.","title":"Row","type":"integer"}},"required":["row","col"],"title":"DeepsetCloudTableCell","type":"object"},"type":"array"},{"type":"null"}],"description":"Offsets of the answer in the document.","title":"Offsets in Document"},"prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"The prompt that was used to generate the result.","title":"Prompt"},"result_id":{"description":"Unique identifier of the result.","format":"uuid","title":"Result ID","type":"string"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"description":"Score of the answer.","title":"Score"},"type":{"description":"Type of the answer.","enum":["generative","extractive","other"],"title":"Answer Type","type":"string"}},"required":["answer","type"],"title":"DeepsetCloudAnswer","type":"object"},"title":"Answers","type":"array"},"created_at":{"description":"Specifies when the search query was run.","format":"date-time","title":"Created At","type":"string"},"documents":{"default":[],"description":"List of deepset documents.","items":{"properties":{"content":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"},{"type":"null"}],"description":"Content of the document.","title":"Content"},"embedding":{"anyOf":[{"items":{"type":"number"},"type":"array"},{"type":"null"}],"description":"Embedding of the document.","title":"Embedding"},"file":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"description":"Object containing the `file_id` and `name` of a file. This is used to associate a document with a file.","title":"File Reference Object (deprecated, use `files` instead)"},"id":{"description":"ID of the document.","title":"Document ID","type":"string"},"meta":{"additionalProperties":true,"description":"The metadata of this document.","title":"Metadata of file","type":"object"},"result_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"description":"Unique identifier of the result.","title":"Result ID"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"description":"Shows the relevance score of the prediction.","title":"Score"}},"required":["id","meta"],"title":"DeepsetCloudDocument","type":"object"},"title":"Documents","type":"array"},"duration":{"description":"The number of seconds the pipeline took to find the answer.","title":"Duration","type":"number"},"extra_outputs":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"description":"Additional outputs returned by the pipeline. You can specify which extra outputs you want to include using the pipeline yaml `outputs` configuration section.","title":"Extra Outputs"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"description":"Filters you can use to narrow down the search. For more information, see [filtering logic](https://docs.cloud.deepset.ai/docs/filtering-logic).","title":"Haystack Filters"},"output_files":{"anyOf":[{"items":{"properties":{"file_id":{"format":"uuid","title":"File Id","type":"string"},"file_name":{"title":"File Name","type":"string"}},"required":["file_id","file_name"],"title":"OutputFile","type":"object"},"type":"array"},{"type":"null"}],"description":"Files generated by the pipeline, available for download.","title":"Output Files"},"prompts":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"description":"The prompts used in the query. This is only returned if the `view_prompts` flag is set to `true`.","title":"Prompts"},"query":{"description":"The search query.","title":"Query","type":"string"},"query_id":{"description":"Unique identifier of the search query.","format":"uuid","title":"Query ID","type":"string"},"session_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"description":"The ID of the search session you want to use for chat.","title":"Search Session ID"}},"required":["query","created_at","duration"],"title":"SearchHistoryV2","type":"object"}}},"description":"Successful Response"},"422":{"content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"ctx":{"title":"Context","type":"object"},"input":{"title":"Input"},"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"title":"Location","type":"array"},"msg":{"title":"Message","type":"string"},"type":{"title":"Error Type","type":"string"}},"required":["loc","msg","type"],"title":"ValidationError","type":"object"},"title":"Detail","type":"array"}},"title":"HTTPValidationError","type":"object"}}},"description":"Validation Error"}}}
>
  
</StatusCodes>
