$API_TOKEN=<YOUR_API_TOKEN>
$cat > input.json << 'EOF'
<{
< "productsA": [
< {
< "id": "A1",
< "title": "Sony WH-1000XM5 Wireless Noise Cancelling Headphones, Black",
< "brand": "Sony",
< "price": 349.99,
< "url": "https://shop-a.example/p/sony-wh1000xm5"
< },
< {
< "id": "A2",
< "title": "Apple iPhone 15 128GB Black",
< "brand": "Apple",
< "price": 799,
< "url": "https://shop-a.example/p/iphone-15-128-black"
< },
< {
< "id": "A3",
< "title": "Samsung Galaxy S24 Ultra 256GB Titanium Gray",
< "brand": "Samsung",
< "price": 1299.99,
< "url": "https://shop-a.example/p/s24-ultra-256"
< },
< {
< "id": "A4",
< "title": "Coca-Cola Original Taste 6 x 330ml cans",
< "brand": "Coca-Cola",
< "price": 4.99,
< "url": "https://shop-a.example/p/coke-6x330"
< },
< {
< "id": "A5",
< "title": "L'Oréal Paris Revitalift Laser X3 Day Cream 50ml",
< "brand": "L'Oréal Paris",
< "price": 24.9,
< "gtin": "3600523257461",
< "url": "https://shop-a.example/p/revitalift-laser"
< },
< {
< "id": "A6",
< "title": "Nike Air Force 1 '07 Men's Shoes White Size 42",
< "brand": "Nike",
< "price": 110,
< "url": "https://shop-a.example/p/af1-white-42"
< }
< ],
< "productsB": [
< {
< "id": "B1",
< "title": "SONY WH1000XM5 Noise-Cancelling Bluetooth Headphones (Black)",
< "price": 329,
< "url": "https://shop-b.example/item/1"
< },
< {
< "id": "B2",
< "title": "iPhone 15 256 GB - Black - Apple",
< "price": 899,
< "url": "https://shop-b.example/item/2"
< },
< {
< "id": "B3",
< "title": "Apple iPhone 15 (128 GB) – Black",
< "price": 779,
< "url": "https://shop-b.example/item/3"
< },
< {
< "id": "B4",
< "title": "Samsung Galaxy S24 Ultra 256 Go Gris Titane",
< "price": 1249,
< "url": "https://shop-b.example/item/4"
< },
< {
< "id": "B5",
< "title": "Coca-Cola Original 330 ml can",
< "price": 0.99,
< "url": "https://shop-b.example/item/5"
< },
< {
< "id": "B6",
< "title": "L'Oreal Revitalift Laser X3 Anti-Ageing Day Cream 50 ml",
< "price": 21.99,
< "gtin": "03600523257461",
< "url": "https://shop-b.example/item/6"
< }
< ]
<}
<EOF
$curl "https://api.apify.com/v2/actors/freecamp008~product-matcher/runs?token=$API_TOKEN" \
< -X POST \
< -d @input.json \
< -H 'Content-Type: application/json'