CopyHero

List Product Matches

GET
/api/v1/products/{internal_product_id}/matches

Every other product of mine that matches this one, on any signal, in one unpaged list: image_hash (identical pHash and PDQ within pdq_max: the same picture), image_embedding (visually similar) and text (similar content). Each item names its match_reasons and carries the score per signal; hash matches come first. The embedding signals always return their limit nearest products, so filter on the scores. Hash and image embedding compare the images a product was imported with, not later edits.

Authorization

HTTPBearer
headerAuthorizationBearer <token>

Path Parameters

internal_product_id*Internal Product Id
Formatuuid

Query Parameters

signals?array<>|

Signals to search; all three when omitted.

pdq_max?Pdq Max

image_hash: most differing PDQ bits that still match.

Range0 <= value <= 64
Default31
min_image_score?Min Image Score
Range0 <= value <= 1
Default0
min_text_score?Min Text Score
Range0 <= value <= 1
Default0
limit?Limit

Most matches read per signal, best first; a signal that returns exactly this many may have more.

Range1 <= value <= 200
Default50
store_ids?array<integer>|

Only products linked to any of these stores. Repeated values: ?store_ids=12&store_ids=17

Response Body

Successful Response

application/json
  1. response
unavailable_signals*array<>

Requested signals that could not run because the query product has no fingerprint or embedding yet.

items*array<>
Example Request
curl -X GET 'https://app.copyhero.app/api/v1/products/497f6eca-6276-4993-bfeb-53cbbbba6f08/matches'
Example Response
{  "unavailable_signals": [    "image_hash"  ],  "items": [    {      "match_reasons": [        "image_hash"      ],      "pdq_distance": 0,      "image_score": 0,      "text_score": 0,      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "owner_id": 0,      "title": "string",      "handle": "string",      "vendor": "string",      "product_type": "string",      "seo_title": "string",      "seo_description": "string",      "source_type": "string",      "source_url": "string",      "import_extras": {},      "created_at": "2019-08-24T14:15:22Z",      "updated_at": "2019-08-24T14:15:22Z",      "tags": [        "string"      ],      "images": [        {          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",          "src": "string",          "position": 0,          "alt_text": "string",          "thumbnail_url": "string",          "blur_data_url": "string"        }      ],      "store_links": [        {          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",          "store_id": 0,          "store_name": "string",          "store_url": "string",          "store_domain": "string",          "push_blueprint_id": 0,          "push_blueprint_name": "string",          "store_backend_product_id": "string",          "store_backend_handle": "string",          "sync_state": "string",          "last_pushed_at": "2019-08-24T14:15:22Z",          "last_pulled_at": "2019-08-24T14:15:22Z",          "last_webhook_at": "2019-08-24T14:15:22Z",          "remote_deleted_at": "2019-08-24T14:15:22Z",          "last_sync_error": "string"        }      ],      "sales": [        {          "currency": "AED",          "revenue_total": "string",          "revenue_7d": "string",          "revenue_30d": "string"        }      ],      "price": "string",      "currency": "string",      "category": "string",      "category_name": "string"    }  ]}