> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lightdrift.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Add image search to an agent's publishing workflow

> Use Images MCP to find image candidates for a page, preserve credits, and separate retrieval from the final publishing decision.

An agent building a landing page or a presentation needs a usable image and the information that travels with it. Lightdrift's Images MCP exposes image search, similar-image search and metadata retrieval. It returns the source's license declarations and attribution alongside each result.

This workflow keeps a person in charge of selecting and publishing the image. It is useful when a developer wants an agent to prepare a small review queue without silently treating the highest-ranked result as cleared for use.

## Connect the image tools

Use `https://lightdrift.ai/mcp` in a client that supports remote MCP over Streamable HTTP. Complete Lightdrift sign-in in an OAuth-capable client, or configure a Lightdrift API key using the client's private secret settings. See the [client setup instructions](/guides/images-mcp) for the supported configuration paths.

Check the tool list for `search_images`, `find_similar_images`, and `get_image`. Listing tools does not run an image search. Successful search and similar-image calls currently cost \$0.005 each; `get_image` is free. Check your available account credits and the [live price](https://api.lightdrift.ai/v1/pricing) before asking an agent to search.

## Give the agent a bounded brief

For a coastal travel page, try this prompt:

> Use Lightdrift to make one search for five landscape photos of a coastal lighthouse at dusk, with space for a headline on the left. Request commercial and derivative permissions. Keep every candidate's asset ID, source, file URL, dimensions and full rights object. Return a review table with source links and required credits. Do not download or publish an image, and do not search again without asking me. If the response reports relaxed filters or degraded ranking, tell me.

This is a sample brief, not a promise that the requested image is available. Inspect the tool call before execution if your client supports it. A corresponding `search_images` argument object is:

```json theme={null}
{
  "query": "coastal lighthouse at dusk with open sky on the left for a headline",
  "k": 5,
  "filters": {
    "commercial": true,
    "derivatives": true,
    "orientation": "landscape"
  }
}
```

The MCP client supplies the call envelope and authentication. This JSON is the tool's arguments, not a request to POST directly to the MCP endpoint. For a REST workflow, see the [itinerary review example](/guides/itinerary-images).

## Keep retrieval and approval separate

Review the preview and source page for each shortlisted result. Confirm the subject, layout fit and actual pixel dimensions. A plausible caption or high rank does not verify a landmark, person or product.

Retain the complete result with the search's `query_id`. In particular, keep `rights.attribution`, `rights.license_verbatim`, `rights.provenance_url`, and `rights.basis`, together with the permission flags. A missing or null flag is unresolved information. If a required credit is absent, hold the candidate for review.

Render source titles and attribution as text in your application, not as trusted HTML. Carry the required credit into the published page, slide export or other final output. A license filter reflects source declarations; it does not clear every intended use. Read [Rights answers](/guides/rights) for the scope of this metadata.

## Handle the result you actually got

| Observation                          | Next step                                                                                                                    |
| ------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------- |
| No useful candidates                 | Keep the image unset. Revise the subject or composition brief before authorizing another search.                             |
| A filter was relaxed                 | Check the returned dimensions and other requirements against the layout.                                                     |
| Ranking is degraded                  | Review the returned candidates; don't present the order as normal reranking. A successful degraded response is still billed. |
| The call times out                   | Check account usage and any available result before repeating. A new search may charge again.                                |
| Metadata is needed for a saved asset | Use `get_image` instead of another search.                                                                                   |

## Try it on a real page

[Open Lightdrift](https://lightdrift.ai/?utm_source=lightdrift_docs\&utm_medium=owned_content\&utm_campaign=lig27_agent_review_v1\&utm_content=guide_cta), connect your client, and run one brief from a page you are building. Check whether a candidate is usable and whether its credit survives into your output. Keep a note of what stopped you if no candidate qualified.

The example arguments were checked against current Lightdrift documentation on September 26, 2026. This guide does not report an authenticated search result or measured image quality.
