{
  "openapi": "3.0.1",
  "info": {
    "title": "iGraal Merchants and Cashback Rates Scraper",
    "description": "Get the shops listed on iGraal and Shoop in France, Germany, Poland and Spain. Each row gives the shop name, its website, the network behind it, a grade and the number of live coupons. Open one shop for its cashback rate tiers and conditions, or follow its rate changes.",
    "version": "1.0",
    "x-build-id": "2qWpTHZb5AROyJqkw"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/happyendpoint~igraal-merchants-cashback-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-happyendpoint-igraal-merchants-cashback-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/happyendpoint~igraal-merchants-cashback-scraper/runs": {
      "post": {
        "operationId": "runs-sync-happyendpoint-igraal-merchants-cashback-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/happyendpoint~igraal-merchants-cashback-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-happyendpoint-igraal-merchants-cashback-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "required": [
          "operation"
        ],
        "properties": {
          "operation": {
            "title": "Operation",
            "enum": [
              "merchants",
              "merchantsCatalog",
              "merchantDetails",
              "merchantAutocomplete",
              "merchantByUrl",
              "cashbackRate",
              "cashbackCampaign",
              "affiliateCampaigns",
              "cashbackEvents",
              "merchantKeywords",
              "affiliateNetworks",
              "markets",
              "categories",
              "reference"
            ],
            "type": "string",
            "description": "Which data to fetch. Each option is one kind of request."
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "The most results to return. The run stops once it has this many.",
            "default": 100
          },
          "merchantId": {
            "title": "Merchant ID",
            "pattern": "^[A-Za-z0-9_-]{1,40}$",
            "type": "string",
            "description": "The ID of one shop, as the id key of merchant rows returns it. It only works in the country it came from. Used by: Merchant details, Cashback rate, Cashback rate events, Merchant search terms."
          },
          "url": {
            "title": "iGraal page link",
            "type": "string",
            "description": "A merchant page link of iGraal France, copied from your browser. The website of a shop itself is not accepted. Used by: Merchant by page link."
          },
          "campaignId": {
            "title": "Campaign ID",
            "pattern": "^[A-Za-z0-9_-]{1,40}$",
            "type": "string",
            "description": "The ID of one cashback campaign, located in the cashback block returned by Cashback rate and Merchant details. Used by: Cashback campaign."
          },
          "legacyIds": {
            "title": "Campaign numbers",
            "pattern": "^[0-9]{1,10}(,[0-9]{1,10}){0,19}$",
            "type": "string",
            "description": "Old-style campaign numbers with a comma between them. They are the numbers of the campaigns, not the numbers of the shops. Use it for numbers you already hold. Used by: Affiliate campaigns."
          },
          "market": {
            "title": "Country",
            "enum": [
              "fr",
              "de",
              "pl",
              "es"
            ],
            "type": "string",
            "description": "The country whose site you want. Required for most operations; Merchant by page link takes none, and Affiliate networks covers all countries when it is empty. Used by: Search merchants, Merchant catalog, Merchant details, Merchant name suggestions, Cashback rate, Affiliate campaigns, Cashback rate events, Merchant search terms, Affiliate networks, Categories."
          },
          "query": {
            "title": "Name search",
            "maxLength": 100,
            "type": "string",
            "description": "Words to look for in a name: a shop name, or a network name in Affiliate networks. Name suggestions work from the first letters. Used by: Search merchants, Merchant name suggestions, Affiliate networks."
          },
          "merchantIds": {
            "title": "Merchant IDs",
            "pattern": "^[A-Za-z0-9_-]{1,40}(,[A-Za-z0-9_-]{1,40}){0,49}$",
            "type": "string",
            "description": "Several shop IDs with a comma between them, to get those shops in one search. Used by: Search merchants."
          },
          "categoryIds": {
            "title": "Category IDs",
            "pattern": "^[0-9a-fA-F-]{8,40}(,[0-9a-fA-F-]{8,40}){0,19}$",
            "type": "string",
            "description": "Category IDs taken from Categories, separated by commas. Picking a main category brings in the shops of its subcategories too. Used by: Search merchants."
          },
          "affiliateNetworkIds": {
            "title": "Affiliate network IDs",
            "pattern": "^[A-Za-z0-9_-]{1,40}(,[A-Za-z0-9_-]{1,40}){0,19}$",
            "type": "string",
            "description": "Network IDs from Affiliate networks, with a comma between them. Shops on at least one of these networks stay in. Used by: Search merchants."
          },
          "qualityPositions": {
            "title": "Quality grades",
            "pattern": "^[0-9]{1,2}(,[0-9]{1,2}){0,12}$",
            "type": "string",
            "description": "Grade numbers from Reference tables, with a comma between them. A shop at any of the grades is kept. Used by: Search merchants."
          },
          "hasCashback": {
            "title": "Paying cashback now",
            "type": "boolean",
            "description": "Turn it on to keep only shops paying cashback at the moment. Leave it unset for all shops; do not set it to false, because the site refuses that value. Used by: Search merchants."
          },
          "published": {
            "title": "Shown on the site",
            "type": "boolean",
            "description": "Turn it on to keep only the shops the site currently lists. Leave it unset for all shops; set to false to keep only the shops that the public directory does not list. Used by: Search merchants."
          },
          "eventType": {
            "title": "Event type",
            "enum": [
              "ACTIVATED",
              "REACTIVATED",
              "STOPPED",
              "MAX_CASHBACK_CHANGED"
            ],
            "type": "string",
            "description": "Show just the chosen event type from the rate timeline. Leave it empty to see every type. Used by: Cashback rate events."
          },
          "upcomingOnly": {
            "title": "Future events only",
            "type": "boolean",
            "description": "Turn it on to see only the events that are still to come, and leave it off for the full history. Used by: Cashback rate events."
          },
          "sort": {
            "title": "Sort merchants",
            "enum": [
              "relevance",
              "name"
            ],
            "type": "string",
            "description": "How merchant search orders its results. Leave it empty for the site ranking. Used by: Search merchants."
          },
          "order": {
            "title": "Name order",
            "enum": [
              "asc",
              "desc"
            ],
            "type": "string",
            "description": "Direction of the name sort. It has no effect on the site ranking. Used by: Search merchants."
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}