# Get Query Sets

<Heading
  as={"h1"}
  className={"openapi__heading"}
  children={"Get Query Sets"}
>
</Heading>

<MethodEndpoint
  method={"get"}
  path={"/api/v2/workspaces/{workspace_id}/query_sets"}
  context={"endpoint"}
>
  
</MethodEndpoint>

Returns query sets.

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

<ParamsDetails
  parameters={[{"in":"path","name":"workspace_id","required":true,"schema":{"format":"uuid","title":"Workspace ID","type":"string"}},{"description":"How many entries do you want to display? Leaving this field empty keeps the default and max 10 results are returned.","in":"query","name":"limit","required":false,"schema":{"default":10,"description":"How many entries do you want to display? Leaving this field empty keeps the default and max 10 results are returned.","maximum":100,"title":"Limit","type":"integer"}},{"description":"Enter an ID if you want to see all entries before this ID.","in":"query","name":"before","required":false,"schema":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"description":"Enter an ID if you want to see all entries before this ID.","title":"Before"}},{"description":"Enter an ID if you want to see all entries after this ID.","in":"query","name":"after","required":false,"schema":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"description":"Enter an ID if you want to see all entries after this ID.","title":"After"}},{"description":"Which page do you want to see? Type the number.","in":"query","name":"page_number","required":false,"schema":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Which page do you want to see? Type the number.","title":"Page Number"}},{"description":"The name of the entity you want to sort by.","in":"query","name":"field","required":false,"schema":{"default":"created_at","description":"The name of the entity you want to sort by.","enum":["name","created_at"],"title":"Field","type":"string"}},{"description":"Choose how you want to sort the results.","in":"query","name":"order","required":false,"schema":{"default":"DESC","description":"Choose how you want to sort the results.","enum":["ASC","DESC"],"title":"Order","type":"string"}},{"description":"Partial implementation of the OData $select operator. It currently only supports selecting fields from the root entity or a child entity. Selecting fields from children's children is not supported. If you use this parameter, the API answer is always a flat list of distinct JSON objects with the selected properties, for example, '[{\"given_name\": \"user1\", \"user_id\": \"...\"}, ...]' for 'select=created_by/given_name, created_by/user_id'. The results are ordered by the first selected attribute. To learn more about the OData filter syntax, see: [Querying Data](https://www.odata.org/getting-started/basic-tutorial/#queryData).","in":"query","name":"select","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Partial implementation of the OData $select operator. It currently only supports selecting fields from the root entity or a child entity. Selecting fields from children's children is not supported. If you use this parameter, the API answer is always a flat list of distinct JSON objects with the selected properties, for example, '[{\"given_name\": \"user1\", \"user_id\": \"...\"}, ...]' for 'select=created_by/given_name, created_by/user_id'. The results are ordered by the first selected attribute. To learn more about the OData filter syntax, see: [Querying Data](https://www.odata.org/getting-started/basic-tutorial/#queryData).","title":"Select"}}]}
>
  
</ParamsDetails>

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

<StatusCodes
  id={undefined}
  label={undefined}
  responses={{"200":{"content":{"application/json":{"schema":{"properties":{"data":{"description":"A list of matching query sets.","items":{"properties":{"created_at":{"description":"Timestamp of when the query set was created.","format":"date-time","title":"Created at","type":"string"},"created_by":{"properties":{"family_name":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Family name of a user.","title":"Family name"},"given_name":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Given name of a user.","title":"Given name"},"user_id":{"format":"uuid","title":"User Id","type":"string"}},"required":["user_id"],"title":"Oauth User","type":"object","description":"The user who created the query set."},"name":{"description":"Name of the query set.","title":"Name","type":"string"},"query_set_id":{"description":"Query set ID.","format":"uuid","title":"Query set ID","type":"string"}},"required":["query_set_id","name","created_by","created_at"],"title":"QuerySet","type":"object"},"title":"Matching query sets in the request page matching your filter criteria","type":"array"},"has_more":{"description":"Whether the paginated result has more results.","title":"Has more results","type":"boolean"},"total":{"description":"The total number of results matching your query.","title":"Total number of results","type":"integer"}},"required":["data","has_more","total"],"title":"PaginatedQuerySets","type":"object"}}},"description":"Successful Response"},"422":{"content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"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>
