{
  "openapi": "3.0.1",
  "info": {
    "title": "G2 Scraper - Reviews, Products, Analytics & Discussions",
    "description": "🔥 ~$0.05/1K reviews 🔥 Scrape G2.com software reviews, products, analytics, comparisons, and discussions. Faceted filtering, facet-value discovery, 72 review fields, NLP sentiment, switching intelligence.",
    "version": "0.1",
    "x-build-id": "09Pt0q1i9kcpBy5Jy"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/kaix~g2-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-kaix-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/kaix~g2-scraper/runs": {
      "post": {
        "operationId": "runs-sync-kaix-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/kaix~g2-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-kaix-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",
        "properties": {
          "products": {
            "title": "Product URLs or slugs",
            "type": "array",
            "description": "G2 product URLs (e.g. https://www.g2.com/products/slack/reviews) or just slugs (e.g. slack). Also accepts category URLs.",
            "items": {
              "type": "string"
            }
          },
          "maxReviewsPerProduct": {
            "title": "Max reviews per product",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum number of reviews to scrape per product. Set to 0 for no limit (all reviews).",
            "default": 20
          },
          "sortBy": {
            "title": "Sort reviews by",
            "enum": [
              "DATE_DESC",
              "DATE_ASC",
              "RATING_DESC",
              "RATING_ASC",
              "HELPFUL_DESC",
              "G2_DEFAULT"
            ],
            "type": "string",
            "description": "How to sort reviews.",
            "default": "DATE_DESC"
          },
          "ratings": {
            "title": "Star ratings to include",
            "type": "array",
            "description": "Only include reviews with these star ratings. Leave empty for all ratings.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "4",
                "5"
              ],
              "enumTitles": [
                "1 star",
                "2 stars",
                "3 stars",
                "4 stars",
                "5 stars"
              ]
            },
            "default": [
              "1",
              "2",
              "3",
              "4",
              "5"
            ]
          },
          "companySegment": {
            "title": "Company size filter",
            "type": "array",
            "description": "Filter by company size.",
            "items": {
              "type": "string",
              "enum": [
                "small_business",
                "mid_market",
                "enterprise"
              ],
              "enumTitles": [
                "Small Business",
                "Mid-Market",
                "Enterprise"
              ]
            }
          },
          "dateFrom": {
            "title": "Reviews from date",
            "type": "string",
            "description": "ISO date, only reviews submitted on or after this date."
          },
          "dateTo": {
            "title": "Reviews to date",
            "type": "string",
            "description": "ISO date, only reviews submitted on or before this date."
          },
          "primaryRegions": {
            "title": "Primary region",
            "type": "array",
            "description": "Filter by reviewer primary region.",
            "items": {
              "type": "string",
              "enum": [
                "Americas",
                "Asia Pacific",
                "EMEA"
              ],
              "enumTitles": [
                "Americas",
                "Asia Pacific",
                "EMEA"
              ]
            }
          },
          "sourceTypes": {
            "title": "Review source type",
            "type": "array",
            "description": "Filter by how the review was collected (e.g. organic, g2_incentivized). Discover values via enumFields: source_type.",
            "items": {
              "type": "string"
            }
          },
          "responseTypes": {
            "title": "Response type",
            "type": "array",
            "description": "Filter by review medium (e.g. text, video). Discover values via enumFields: response_type.",
            "items": {
              "type": "string"
            }
          },
          "loveThemes": {
            "title": "Loved themes",
            "type": "array",
            "description": "Filter by what reviewers liked (e.g. Automation, Analytics). Discover values via enumFields: love_theme_humanized.",
            "items": {
              "type": "string"
            }
          },
          "hateThemes": {
            "title": "Hated themes",
            "type": "array",
            "description": "Filter by what reviewers disliked. Discover values via enumFields: hate_theme_humanized.",
            "items": {
              "type": "string"
            }
          },
          "switchingThemes": {
            "title": "Switching themes",
            "type": "array",
            "description": "Filter by why reviewers switched products. Discover values via enumFields: switching_theme_humanized.",
            "items": {
              "type": "string"
            }
          },
          "discounts": {
            "title": "Discount",
            "type": "array",
            "description": "Filter by reported discount. Discover values via enumFields: discount.",
            "items": {
              "type": "string"
            }
          },
          "reviewSources": {
            "title": "Review source channel",
            "type": "array",
            "description": "Filter by review source channel. Discover values via enumFields: review_source.",
            "items": {
              "type": "string"
            }
          },
          "reviewSearch": {
            "title": "Search within reviews",
            "type": "string",
            "description": "Full-text search within review text. When used without products, searches globally across all products."
          },
          "search": {
            "title": "Search products",
            "type": "string",
            "description": "Find products by keyword search (e.g. 'project management')."
          },
          "category": {
            "title": "Browse by category",
            "type": "string",
            "description": "Find products in a G2 category (e.g. 'CRM', 'Project Management')."
          },
          "vendor": {
            "title": "Browse by vendor",
            "type": "string",
            "description": "Find all products by vendor name (e.g. 'Salesforce')."
          },
          "maxProducts": {
            "title": "Max products",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum products to scrape in search/category/vendor mode.",
            "default": 10
          },
          "compare": {
            "title": "Compare products",
            "type": "array",
            "description": "Compare products side-by-side with analytics (e.g. ['slack', 'teams', 'discord']).",
            "items": {
              "type": "string"
            }
          },
          "analytics": {
            "title": "Analytics mode",
            "type": "boolean",
            "description": "Return aggregation analytics per product instead of individual reviews.",
            "default": false
          },
          "enumFields": {
            "title": "Discover facet values",
            "type": "array",
            "description": "Return the distinct values for these review facets (saved to the metadata dataset) instead of scraping reviews. Use the values to populate the reviewer-facet filters.",
            "items": {
              "type": "string",
              "enum": [
                "source_type",
                "response_type",
                "love_theme_humanized",
                "hate_theme_humanized",
                "switching_theme_humanized",
                "discount",
                "review_source"
              ]
            }
          },
          "similarTo": {
            "title": "Find similar reviews",
            "type": "string",
            "description": "Find reviews similar to this text."
          },
          "reviewIds": {
            "title": "Fetch reviews by ID",
            "type": "array",
            "description": "Fetch specific reviews by their G2 review ID.",
            "items": {
              "type": "string"
            }
          },
          "maxReviews": {
            "title": "Max reviews (global/similar search)",
            "minimum": 0,
            "type": "integer",
            "description": "Max total reviews for global search or similar mode. Set to 0 for no limit.",
            "default": 100
          },
          "collapseByProduct": {
            "title": "One review per product",
            "type": "boolean",
            "description": "Deduplicate global search results to one review per product.",
            "default": false
          },
          "includeDiscussions": {
            "title": "Include discussions",
            "type": "boolean",
            "description": "Also fetch Q&A discussion threads per product.",
            "default": false
          },
          "includeHighlights": {
            "title": "Include search highlights",
            "type": "boolean",
            "description": "Include highlighted matching snippets when using reviewSearch.",
            "default": true
          },
          "includeNonPublic": {
            "title": "Include non-public reviews",
            "type": "boolean",
            "description": "Include non-public and rejected reviews.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}