{
  "openapi": "3.0.1",
  "info": {
    "title": "G2 Scraper",
    "description": "Scrape the ranked software landscape of any G2 category: rating, review count, the top pros and cons with how many reviews mention each, G2's own review summary, and which placements are paid.",
    "version": "0.1",
    "x-build-id": "13qayMFIrDmGy2ubJ"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/juanoox~g2-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-juanoox-g2-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/juanoox~g2-scraper/runs": {
      "post": {
        "operationId": "runs-sync-juanoox-g2-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/juanoox~g2-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-juanoox-g2-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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "G2 category or product URLs",
            "type": "array",
            "description": "Paste a category URL to get its whole ranked landscape, or a product URL to get that product alone. Both kinds can be mixed in one run. Category sort is respected: append ?order=highest_rated or ?order=popular and the Actor keeps that order across pages.",
            "default": [
              "https://www.g2.com/categories/crm"
            ],
            "items": {
              "type": "string"
            }
          },
          "maxPagesPerListing": {
            "title": "Max pages per category",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "How deep to go in each category. A page holds 15 ranked products, so 3 pages is the top 45. Large categories run past 100 pages.",
            "default": 3
          },
          "scrapeProductDetails": {
            "title": "Also open each product page",
            "type": "boolean",
            "description": "Adds one request per product and fills in what the ranking does not publish: how many reviews mention each of the ten attributes (the ranking only shows the top one of each), every category G2 lists the product in, and the vendor's own description. Off by default because it multiplies the request count by about 15.",
            "default": false
          },
          "minRating": {
            "title": "Minimum rating",
            "type": "string",
            "description": "Keep only products rated at or above this, on a 0-5 scale. Products with no rating are dropped, because they cannot be said to clear a minimum. Leave empty for no filter.",
            "default": ""
          },
          "minReviews": {
            "title": "Minimum number of reviews",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only products backed by at least this many reviews. A 5.0 rating from 4 reviewers is noise; this is how you drop it. Leave empty for no filter."
          },
          "includeSponsored": {
            "title": "Include paid placements",
            "type": "boolean",
            "description": "G2 sells slots inside its category listings and does not separate them from the ranking. Every row carries isSponsored, and paid slots get rank: null because they hold no ranked position. Turn this off for a ranking with no advertising in it.",
            "default": true
          },
          "prosKeywords": {
            "title": "Filter by strengths",
            "type": "array",
            "description": "Keep only products whose reviewers praise one of these, matched against the pros list, e.g. \"Ease of Use\", \"Integrations\".",
            "items": {
              "type": "string"
            }
          },
          "consKeywords": {
            "title": "Filter by complaints",
            "type": "array",
            "description": "Keep only products whose reviewers complain about one of these, e.g. \"Expensive\", \"Learning Curve\". This is how you find the competitors whose users are unhappy about the thing you do well.",
            "items": {
              "type": "string"
            }
          },
          "vendorKeywords": {
            "title": "Filter by vendor or product name",
            "type": "array",
            "description": "Keep only products whose vendor or name contains one of these.",
            "items": {
              "type": "string"
            }
          },
          "maxItems": {
            "title": "Max results",
            "minimum": 0,
            "maximum": 500000,
            "type": "integer",
            "description": "Hard cap on how many products are saved and charged. 0 means no cap.",
            "default": 100
          },
          "includeSeen": {
            "title": "Include products already seen in previous runs",
            "type": "boolean",
            "description": "Off means the run only saves products it has never returned before, which is what you want when tracking a category over time.",
            "default": true
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "Parallel requests. G2 sits behind DataDome; going high gets you blocked rather than fast.",
            "default": 2
          },
          "maxRequestRetries": {
            "title": "Max retries per request",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "How many times a blocked or failed request is retried before the target is given up on.",
            "default": 3
          },
          "maxRequestsPerMinute": {
            "title": "Max requests per minute",
            "minimum": 1,
            "maximum": 600,
            "type": "integer",
            "description": "Rate limit for the whole run.",
            "default": 20
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}