---
title: "Save Results"
method: POST
path: "/queries/save-results"
---

# Save Results

`POST /queries/save-results`

Save result rows as a reusable thin-wrapper saved query (REST twin of save-mcp-query).

## Request body

- SaveResultsRequest — Request model for saving result rows as a thin-wrapper saved query. Shared by the REST `POST /queries/save-results` endpoint and the `save-mcp-query` MCP tool so the payload shape stays identical.
  - `query_name` string, required — Name for the query
  - `action` 'discover' | 'segment' | 'contacts' | 'append' | 'match', required — Underlying action type. One of: ['discover', 'segment', 'contacts', 'append', 'match']
  - `query_params` object — Original query params for UI reconstruction
  - `data` object[], required — Thin rows: domain + custom columns
  - `domain_column` string — Column name containing domains
  - `tags` string[] — Initial tags to apply

## Response `200`

Successful Response

- QuerySaveResponse — Response model for saving/creating queries and exclusion lists.
  - `query_id` string, required
  - `query_name` string, nullable
  - `action` string, nullable
  - `domain_count` integer, nullable
  - `persona_id_count` integer, nullable
  - `row_count` integer, nullable
  - `tags` string[], nullable
  - `message` string, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-08-30** `11d1e74d88c7` — 1 breaking, 5 info
  - request property `action` was restricted to a list of enum values
  - added the new `append` enum value to the request property `action`
  - added the new `contacts` enum value to the request property `action`
  - added the new `discover` enum value to the request property `action`
  - …2 more
- **2026-08-18** `6b838ca10add` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/discolike/apis/discolike-api/changes/queries/save-results/post.md)

---

[API](https://skmtc.dev/discolike/apis/discolike-api.md) · [All operations](https://skmtc.dev/discolike/apis/discolike-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/discolike/discolike-api/revisions/11d1e74d88c7/schema)
