Skip to main content
GET
/
query-rewrites
/
{id}
Get a query rewrite
import requests

url = "https://{commerce_studio_id}.experiencemanager.lucidworks.com/query-rewrites/{id}"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
{
  "type": "HEAD_TAIL",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "createdBy": "<string>",
  "creationDate": "2023-11-07T05:31:56Z",
  "lastModifiedBy": "<string>",
  "lastModified": "2023-11-07T05:31:56Z",
  "published": true,
  "version": "2023-11-07T05:31:56Z",
  "stagingFusionSyncStatus": {
    "lastSyncedVersion": "2023-11-07T05:31:56Z",
    "fusionVersion": "<string>"
  },
  "liveFusionSyncStatus": {
    "lastSyncedVersion": "2023-11-07T05:31:56Z",
    "fusionVersion": "<string>"
  },
  "markedForDeletion": true,
  "description": "<string>",
  "externalId": "<string>",
  "migratedId": "<string>",
  "surfaceForm": "<string>",
  "outputs": [
    "<string>"
  ]
}

Documentation Index

Fetch the complete documentation index at: https://doc.lucidworks.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

The rewrite's Universally-Unique Identifier (UUID). You can also use the externalId, if the rewrite has one.

Query Parameters

fields
enum<string>[]

Optional additional fields to include in the response. Keep in mind that additional fields can slow the call and increase the response size.

Available options:
FUSION_SYNC_STATUS,
MIGRATION

Response

200 - application/json

OK

Replace underperforming queries with queries that produce higher click-through rates.

type
enum<string>
required

Query rewrite type. Determines which schema applies.

Available options:
HEAD_TAIL
id
string<uuid>

Entity ID.

createdBy
string

User who created the entity.

creationDate
string<date-time>

Date when the entity was created.

lastModifiedBy
string

User who last updated the entity.

lastModified
string<date-time>

Date when the entity was last updated.

published
boolean

Whether the rewrite is staged or published.

version
string<date-time>

The version of this rewrite for synchronization purposes. Not the same as lastModified, and not used for If-Match in the API.

stagingFusionSyncStatus
FusionSyncStatusV2Summary · object

Status of this content's synchronization.

liveFusionSyncStatus
FusionSyncStatusV2Summary · object

Status of this content's synchronization.

markedForDeletion
boolean

True if this rewrite is marked for deletion but has not yet been fully removed from the system. This should only show up as true in rare cases. The system is supposed to resolve this situation eventually. Rewrites in this state (true) should not show up in the listing endpoints (other than GET by ID) unless explicitly requested to be included. Intended for troubleshooting purposes.

description
string

Rewrite description.

externalId
string

An optional ID set by external users of the API at creation time. Cannot be changed after creation.

migratedId
string

If this was originally migrated from another system, this field shows the ID of the original rewrite.

surfaceForm
string

The underperforming query to replace.

outputs
string[]

Query phrases that produce higher click-through rates to replace the underperforming query.