# G2 Scraper - Reviews, Products, Analytics & Discussions (`kaix/g2-scraper`) Actor

🔥 ~$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.

- **URL**: https://apify.com/kaix/g2-scraper.md
- **Developed by:** [Kai](https://apify.com/kaix) (community)
- **Categories:** E-commerce, AI, Lead generation
- **Features:** Limited permissions
- **Stats:** 51 total users, 22 monthly users, 99.3% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.04 / 1,000 reviews

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## G2 Scraper

Collect structured G2 product profiles, software reviews, analytics, facet
values, and product discussions. Use product URLs or slugs, or find products
by keyword, category, or vendor.

### Review intelligence

| Area | Available data |
| --- | --- |
| Review text | Title, structured pros, cons, recommendations, benefits, full review text, and matching search snippets |
| Dimension ratings | Overall star value plus ease of use, setup, administration, support, requirements, security, and business ratings when G2 supplies them |
| Reviewer context | Company segment, industry, role, region, review source, contract length, and discount fields |
| Themes and switching | Loved and disliked themes, products switched from, switching reasons, and nested switching themes |
| Product analysis | Rating distributions, percentiles, trends, demographics, top themes, and switching-reason counts |

### Choose a collection mode

| Goal | Main input | Dataset output |
|---|---|---|
| Collect product reviews | `products`, `search`, `category`, or `vendor` | default and `products` |
| Search review text | `reviewSearch`, with an optional product selector | default |
| Find similar reviews | `similarTo` | default |
| Fetch known reviews | `reviewIds` | default |
| Collect product analytics | `products` with `analytics: true` | `products` and `analytics` |
| Compare products | `compare` | `products` and `analytics` |
| Add valid filter values to a run | `enumFields` | `metadata`, followed by the selected main output |

`enumFields` is additive. It writes the requested filter values to `metadata`,
then the selected review, product, analytics, or comparison job continues. If
you provide only `enumFields`, the run finishes after it writes metadata.

### Collect reviews for one product

```json
{
  "products": ["https://www.g2.com/products/slack/reviews"]
}
```

Use `maxReviewsPerProduct: 0` only when you want all available matching
reviews.

### Find products before you collect reviews

Find products by keyword:

```json
{
  "search": "project management",
  "maxProducts": 5,
  "maxReviewsPerProduct": 20
}
```

Browse a category:

```json
{
  "category": "CRM",
  "maxProducts": 10,
  "maxReviewsPerProduct": 20
}
```

Browse products from one vendor:

```json
{
  "vendor": "Salesforce",
  "maxProducts": 5,
  "maxReviewsPerProduct": 10
}
```

### Filter product reviews

This example keeps low-rating enterprise reviews from the selected date:

```json
{
  "products": ["slack"],
  "dateFrom": "2025-01-01",
  "ratings": ["1", "2"],
  "companySegment": ["enterprise"],
  "maxReviewsPerProduct": 100
}
```

Facet filters accept G2's facet values. First, list the values in the
`metadata` Dataset:

```json
{
  "enumFields": ["source_type", "response_type"]
}
```

Then use a listed value in a product review run:

```json
{
  "products": ["slack"],
  "primaryRegions": ["Americas"],
  "sourceTypes": ["organic"],
  "responseTypes": ["video"],
  "maxReviewsPerProduct": 50
}
```

### Search review text

Use a product selector to search within selected products:

```json
{
  "products": ["slack"],
  "reviewSearch": "customer support",
  "includeHighlights": true
}
```

Omit the product selector to search reviews across products:

```json
{
  "reviewSearch": "customer support",
  "maxReviews": 50,
  "collapseByProduct": true
}
```

### Analyse or compare products

```json
{
  "products": ["slack"],
  "analytics": true
}
```

```json
{
  "compare": ["slack", "clickup", "jira"]
}
```

Comparison mode writes one product record and one analytics record for each resolved product. It does not create a separate comparison record.

### Find known or similar reviews

Find reviews that are similar to supplied text:

```json
{
  "similarTo": "The API was difficult to integrate",
  "maxReviews": 20
}
```

Fetch known review IDs:

```json
{
  "reviewIds": ["13038740"]
}
```

### Add product discussions

Set `includeDiscussions` in product review mode. Discussion records go to the
`discussions` Dataset.

```json
{
  "products": ["slack"],
  "maxReviewsPerProduct": 10,
  "includeDiscussions": true
}
```

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `products` | string\[] | | Product URLs, product slugs, product names, or G2 category URLs |
| `maxReviewsPerProduct` | integer | `20` | Maximum reviews for each product; `0` removes this limit |
| `sortBy` | string | `DATE_DESC` | `DATE_DESC`, `DATE_ASC`, `RATING_DESC`, `RATING_ASC`, `HELPFUL_DESC`, `G2_DEFAULT` |
| `ratings` | string\[] | `["1","2","3","4","5"]` | `1`, `2`, `3`, `4`, `5` |
| `companySegment` | string\[] | | `small_business`, `mid_market`, `enterprise` |
| `dateFrom` | string | | Lower date bound; use `YYYY-MM-DD` |
| `dateTo` | string | | Upper date bound; use `YYYY-MM-DD` |
| `includeNonPublic` | boolean | `true` | Also return approved reviews that G2 does not show publicly; set `false` for public reviews only. Each review has an `isPublic` field. Discussions are not affected |
| `primaryRegions` | string\[] | | `Americas`, `Asia Pacific`, `EMEA` |
| `sourceTypes` | string\[] | | Collection-source facets; use `enumFields` to list available values |
| `responseTypes` | string\[] | | Review-medium facets, such as `text` or `video` |
| `loveThemes` | string\[] | | Themes that reviewers liked |
| `hateThemes` | string\[] | | Themes that reviewers disliked |
| `switchingThemes` | string\[] | | Reasons that reviewers switched products |
| `discounts` | string\[] | | Reported discount facets |
| `reviewSources` | string\[] | | Review-source channel facets |
| `reviewSearch` | string | | Search review text; without a product selector, the search is global |
| `search` | string | | Find products by keyword |
| `category` | string | | Find products in a G2 category |
| `vendor` | string | | Find products by vendor name |
| `maxProducts` | integer | `10` | Maximum products in search, category, or vendor mode; `0` removes this limit |
| `compare` | string\[] | | Product URLs, slugs, or names for product and analytics output |
| `analytics` | boolean | `false` | Write analytics instead of individual reviews for resolved product selectors |
| `enumFields` | string\[] | | `source_type`, `response_type`, `love_theme_humanized`, `hate_theme_humanized`, `switching_theme_humanized`, `discount`, `review_source` |
| `similarTo` | string | | Find reviews that are similar to this text |
| `reviewIds` | string\[] | | Fetch reviews by G2 review ID or review page URL |
| `maxReviews` | integer | `100` | Maximum global or similar-search reviews; `0` removes the global-search limit, while Similar search stays limited to 1,000 |
| `collapseByProduct` | boolean | `false` | Keep one review per product in global or Similar search; global search then returns at most 10,000 products |
| `includeDiscussions` | boolean | `false` | Also collect discussions in product review mode; ignored in analytics mode |
| `includeHighlights` | boolean | `true` | Include matching snippets when `reviewSearch` is set |
| `proxyConfiguration` | object | `{"useApifyProxy":true}` | Connection settings passed to Apify |

The Actor requires at least one selector. `enumFields` always runs first and
does not replace the main job. Of the dedicated main selectors, the Actor uses
`reviewIds` before `similarTo`, and `similarTo` before `compare`, when more than
one is present. A `reviewSearch` without a product selector runs globally. With
`products`, `search`, `category`, or `vendor`, it filters the selected products
instead. Repeated product selectors are preserved and can produce repeated
records.

`ratings`, `companySegment`, date, region, facet, and `reviewSearch` filters apply to
product reviews, global search, Similar search, analytics, and comparison. They
do not apply to review-ID or facet-discovery modes. `sortBy` controls product
and global review searches.

The Actor uses `dateFrom` and `dateTo` as supplied. It does not reject
unsupported date formats or compare their order. Use `YYYY-MM-DD`, and make
sure `dateFrom` is not later than `dateTo`.

The next example shows valid syntax for every input field. It is a field reference, not a recommended combination of modes.

<details>
<summary>Complete input example</summary>

```json
{
  "products": ["slack"],
  "maxReviewsPerProduct": 100,
  "sortBy": "DATE_DESC",
  "ratings": ["1", "2", "3", "4", "5"],
  "companySegment": ["small_business", "mid_market", "enterprise"],
  "dateFrom": "2026-01-01",
  "dateTo": "2026-12-31",
  "primaryRegions": ["Americas", "Asia Pacific", "EMEA"],
  "sourceTypes": ["organic"],
  "responseTypes": ["text"],
  "loveThemes": ["Ease of use"],
  "hateThemes": ["Price"],
  "switchingThemes": ["Features"],
  "discounts": ["0-10%"],
  "reviewSources": ["G2"],
  "reviewSearch": "support",
  "search": "chat",
  "category": "collaboration",
  "vendor": "Salesforce",
  "maxProducts": 10,
  "compare": ["slack", "teams"],
  "analytics": true,
  "enumFields": [
    "source_type",
    "response_type",
    "love_theme_humanized",
    "hate_theme_humanized",
    "switching_theme_humanized",
    "discount",
    "review_source"
  ],
  "similarTo": "easy to use",
  "reviewIds": ["13038740"],
  "maxReviews": 100,
  "collapseByProduct": true,
  "includeDiscussions": true,
  "includeHighlights": false,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

</details>

### Output

The Actor can write to five Datasets. Open the Dataset named in the table for the selected mode.

| Dataset | When it is used | Record type |
|---|---|---|
| default | Product review, global search, Similar search, or review-ID mode | Review |
| products | Product, analytics, or comparison mode | Product |
| analytics | Analytics or comparison mode | Analytics |
| discussions | Product review mode with `includeDiscussions` | Discussion |
| metadata | Facet discovery mode | Facet values |

Unavailable optional review values are `null`. Missing text can be an empty string. Lists can be empty.

#### Review example

This selected-field projection contains point-in-time values dated 28 June
2026\. Reviewer identity and other fields are omitted. Use the field reference
for the complete record.

```json
{
  "id": "13038740",
  "productId": 3437,
  "productName": "Slack",
  "reviewUrl": "https://www.g2.com/products/slack/reviews/slack-review-13038740",
  "title": "One-Click Integrations That Just Work for slack",
  "pros": "Integration with other apps has to be 1 click",
  "cons": "UI when you send the messages. The typing window should be adjustable",
  "recommendations": null,
  "benefits": "connect and chatting with the team",
  "responseType": "text",
  "nps": 8,
  "npsScore": 4,
  "submittedAt": "2026-06-26T17:10:48.781-05:00",
  "publishedAt": "2026-06-26T19:30:00.900-05:00",
  "status": "approved",
  "isPublic": true,
  "highlightedSnippets": null,
  "scrapedAt": "2026-06-28T06:00:34.982Z"
}
```

#### Review field reference

All fields in this table are present. A nullable field has the JSON value
`null` when G2 has no value for it.

| Group | JSON field contract |
|---|---|
| Identity | `id` and `productName`: string; `reviewUrl`: string or `null`; `productId`: number |
| Text | `title`, `rawText`, and `responseType`: string; `pros`, `cons`, `recommendations`, and `benefits`: string or `null` |
| Ratings | `nps`, `npsScore`, `easeOfUse`, `easeOfSetup`, `easeOfAdmin`, `easeOfDoingBusinessWith`, `meetsRequirements`, `qualityOfSupport`, `securityConfidence`, `securityImportance`, and `direction`: number or `null` |
| Reviewer | `userName`: string; `country`, `region`, `primaryRegion`, `companySegmentLabel`, `industryLabel`, and `roleLabel`: string or `null`; `companySegment`, `industry`, and `role`: number or `null` |
| Sentiment | `loveTheme`, `loveThemeHumanized`, `loveThemeParentHumanized`, `hateTheme`, `hateThemeHumanized`, and `hateThemeParentHumanized`: string or `null` |
| Switching | `switchedFromOtherProduct` and `switchedReason`: string or `null`; `switchedFromProductIds`: number array or `null`; `switchingThemes`: string array or `null`; `switchingThemesNested`: object array or `null`, with string `name` and `humanizedName` in each item |
| Publication | `submittedAt` and `status`: string; `publishedAt`, `reviewSource`, `sourceType`, `contractLength`, and `discount`: string or `null`; `helpful`: number; `englishAvailable`, `isPublic`, `published`, and `productPaidProfile`: boolean; `price`: number or `null` |
| Product context | `productIds` and `categoryIds`: number array or `null` |
| Additional values | `defaultSort`, `serviceLocation`, `contractLengthWeight`, and `discountWeight`: number or `null`; `templateKeyword`, `videoReviewSubmittedAt`, and `userUpdatedAt`: string or `null`; `editionIds` and `expertiseIds`: string array or `null`; `everApproved`, `isInLimbo`, `read`, and `reportable`: boolean |
| Search and collection | `highlightedSnippets`: string array or `null`; `scrapedAt`: string |

Reviewer job titles and avatar URLs are not available. `industry` and `role`
are numeric G2 codes, and their label fields are present only for mapped
values. They are output values, not filters. `country` and `region` are also
output values; use `primaryRegions` for geography filtering.

#### Product field reference

All product fields are present.

| Group | JSON field contract |
|---|---|
| Identity | `name`, `slug`, `description`, `productUrl`, and `vendorName`: string |
| Ratings | `starRating`, `g2Rating`, and `mozPageAuthority`: number or `null`; `averageRating`: string; `reviewCount`: number |
| Classification | `categoryNames`, `featureKeywords`, and `tagNames`: string array; `categoryIds`: number array |
| Images | `thumbImageUrl` and `faviconUrl`: string or `null` |
| Other values | `type`, `uuid`, and `scrapedAt`: string; `isConsumer` and `isFeatured`: boolean |

#### Analytics field reference

All analytics fields are present. Arrays can be empty.

| Group | JSON field contract |
|---|---|
| Identity and totals | `productId`, `totalReviews`, and `totalHelpfulVotes`: number; `productName`, `productSlug`, and `scrapedAt`: string |
| Rating statistics | `nps`, `easeOfUse`, `easeOfSetup`, `easeOfAdmin`, `qualityOfSupport`, `meetsRequirements`, `easeOfDoingBusinessWith`, `securityConfidence`, `securityImportance`, and `direction`: objects; each has number-or-`null` `avg`, `stdDev`, `min`, and `max`, plus number `count` |
| Distribution | `ratingDistribution`: object whose rating keys map to number counts; `npsPercentiles`: object with number `p10`, `p25`, `p50`, `p75`, and `p90` |
| Counts | `uniqueCountries` and `uniqueIndustries`: number |
| Top themes | `topLoveThemes` and `topHateThemes`: object arrays; each item has string `theme`, number `count`, and object-array `sampleReviews`; each sample has string `title` and `userName`, and number `npsScore` |
| Unique themes | `uniquelyLoved` and `uniquelyHated`: object arrays; each item has string `theme` and number `score` and `count` |
| Switching | `switchingReasons`: object array; each item has string `reason` and number `count` |
| Demographics | `bySegment` and `byIndustry`: object arrays with number `code`, string-or-`null` `label`, and number `count`; `byRegion`: object array with string `region` and number `count`; `bySourceType`: object array with string `type` and number `count` |
| Trends | `reviewsOverTime`: object array; each item has string `month` and number `count` |

This analytics projection contains point-in-time values. It omits the other
fields listed above.

```json
{
  "productId": 3437,
  "productName": "Slack",
  "productSlug": "slack",
  "totalReviews": 20201,
  "totalHelpfulVotes": 69,
  "nps": {
    "avg": 9.211870699470323,
    "stdDev": 1.1668658162744323,
    "min": 0,
    "max": 10,
    "count": 20201
  },
  "ratingDistribution": {
    "1": 40,
    "2": 93,
    "3": 468,
    "4": 3646,
    "5": 15954
  },
  "npsPercentiles": {
    "p10": 8,
    "p25": 9,
    "p50": 10,
    "p75": 10,
    "p90": 10
  },
  "uniqueCountries": 140,
  "uniqueIndustries": 145,
  "reviewsOverTime": [
    { "month": "2014-02", "count": 1 },
    { "month": "2026-06", "count": 73 }
  ]
}
```

#### Discussion and facet-value fields

Discussion records have this contract:

| Group | JSON field contract |
|---|---|
| Identity | `id`: string; `productId` and `categoryId`: number or `null`; `productName` and `categoryName`: string or `null` |
| Content | `title` and `content`: string; `tagNames`: string array |
| Counts | `commentsCount`, `votesUp`, `votesTotal`, and `helpful`: number |
| Flags | `isPublic`, `unanswered`, `seeded`, `pinned`, and `vendorQuestion`: boolean |
| Dates | `createdAt`, `updatedAt`, and `scrapedAt`: string |

Some discussions contain a title without content. In a facet-value record,
`field` is a string, `type` is the string `enum_values`, `values` is a string
array, and `count` is a number equal to `values.length`.

This facet projection contains point-in-time values. The `values` array is
shortened; `count` describes the full array.

```json
{
  "field": "source_type",
  "type": "enum_values",
  "values": ["organic", "user_profile", "vendor"],
  "count": 21
}
```

### Mode and result behaviour

- Review and analytics modes return approved reviews. G2 flags some approved reviews as not public, and the Actor returns them by default. Set `includeNonPublic` to `false` to return public reviews only. A requested review ID is omitted when it does not resolve to such a review, and the log names it. Review-ID records do not have a guaranteed order.
- A product name, such as `Microsoft Teams`, finds the G2 product with that exact name. The log shows the slug that it found.
- A run that reaches its maximum cost per run stops early and keeps the results that it charged for. The run status message tells you so.
- Similar search returns at most 1,000 reviews and keeps relevance order.
- Global search with `collapseByProduct` returns at most 10,000 products. The
  run log tells you when it stops at this limit.
- G2 search can return reviews of products that G2 no longer lists. G2 has no
  page for these reviews, so their `reviewUrl` is `null`.
- `maxReviewsPerProduct: 0`, `maxProducts: 0`, or global `maxReviews: 0` can produce a long run.
- Product `reviewCount` is G2's total. It can be higher than the number of reviews that the Actor can collect.
- Unknown products, empty searches, and modes with no matches can finish with empty Datasets.
- If one product fails, completed sibling products remain available. A product can also keep partial output if G2 stops returning reviews early. If all requested product targets fail, the run completes with empty output.
- Some reviews do not have distinct pros, cons, or benefits. The Actor does not create missing text.
- `rawText` holds all answers of a review as one text, with a line break between answers. The Actor splits the text only when the number of parts fits the review form: 3 parts give `pros`, `cons`, and `benefits`. Until July 2022 the form also asked for recommendations to others, so 4 parts in a review submitted before August 2022 give `pros`, `cons`, `recommendations`, and `benefits`. Any other count means that an answer has its own line breaks, for example a list, so all four sections are `null`. `rawText` always has the full text.

# Actor input Schema

## `products` (type: `array`):

G2 product URLs (e.g. https://www.g2.com/products/slack/reviews), slugs (e.g. slack), or product names as G2 shows them (e.g. Microsoft Teams). Also accepts category URLs.

## `maxReviewsPerProduct` (type: `integer`):

Maximum number of matching public, approved reviews per product. Set to 0 for no limit.

## `sortBy` (type: `string`):

How to sort reviews. Rating options use the 1–5 star rating.

## `ratings` (type: `array`):

Only include reviews with these star ratings. Leave empty for all ratings.

## `companySegment` (type: `array`):

Filter by company size.

## `dateFrom` (type: `string`):

Lower date bound forwarded to G2. Use YYYY-MM-DD.

## `dateTo` (type: `string`):

Upper date bound forwarded to G2. Use YYYY-MM-DD.

## `includeNonPublic` (type: `boolean`):

G2 approves some reviews but does not show them publicly. Keep this on to return them. Turn it off to return only public reviews. Each review has an isPublic field. Discussions are not affected.

## `primaryRegions` (type: `array`):

Filter by reviewer primary region.

## `sourceTypes` (type: `array`):

Filter by how the review was collected (e.g. organic, g2_incentivized). Discover values via enumFields: source_type.

## `responseTypes` (type: `array`):

Filter by review medium (e.g. text, video). Discover values via enumFields: response_type.

## `loveThemes` (type: `array`):

Filter by what reviewers liked (e.g. Automation, Analytics). Discover values via enumFields: love_theme_humanized.

## `hateThemes` (type: `array`):

Filter by what reviewers disliked. Discover values via enumFields: hate_theme_humanized.

## `switchingThemes` (type: `array`):

Filter by why reviewers switched products. Discover values via enumFields: switching_theme_humanized.

## `discounts` (type: `array`):

Filter by reported discount. Discover values via enumFields: discount.

## `reviewSources` (type: `array`):

Filter by review source channel. Discover values via enumFields: review_source.

## `reviewSearch` (type: `string`):

Full-text search within review text. When used without products, searches globally across all products.

## `search` (type: `string`):

Find products by keyword search (e.g. 'project management').

## `category` (type: `string`):

Find products in a G2 category (e.g. 'CRM', 'Project Management').

## `vendor` (type: `string`):

Find all products by vendor name (e.g. 'Salesforce').

## `maxProducts` (type: `integer`):

Maximum products to scrape in search/category/vendor mode. Set to 0 for all matching products.

## `compare` (type: `array`):

Compare products side-by-side with analytics. Use G2 product URLs (e.g. https://www.g2.com/products/slack/reviews), slugs, or product names (e.g. \['slack', 'Microsoft Teams', 'discord']).

## `analytics` (type: `boolean`):

Return aggregation analytics for resolved product selectors instead of individual reviews.

## `enumFields` (type: `array`):

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.

## `similarTo` (type: `string`):

Find reviews similar to this text.

## `reviewIds` (type: `array`):

Fetch specific reviews by G2 review ID or review page URL.

## `maxReviews` (type: `integer`):

Maximum reviews for global or similar search. For global search, 0 means all matches. Similar search is always capped at 1,000.

## `collapseByProduct` (type: `boolean`):

Deduplicate global and similar-search results to one review per product. Global search then returns at most 10,000 products.

## `includeDiscussions` (type: `boolean`):

Also fetch Q\&A discussion threads in product review mode. This option is ignored in analytics mode.

## `includeHighlights` (type: `boolean`):

Include highlighted matching snippets when using reviewSearch.

## `proxyConfiguration` (type: `object`):

Configure network routing. Apify Proxy is enabled by default.

## Actor input object example

```json
{
  "products": [
    "https://www.g2.com/products/slack/reviews"
  ],
  "maxReviewsPerProduct": 20,
  "sortBy": "DATE_DESC",
  "ratings": [
    "1",
    "2",
    "3",
    "4",
    "5"
  ],
  "includeNonPublic": true,
  "maxProducts": 10,
  "analytics": false,
  "maxReviews": 100,
  "collapseByProduct": false,
  "includeDiscussions": false,
  "includeHighlights": true,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `reviews` (type: `string`):

No description

## `metadata` (type: `string`):

No description

## `analytics` (type: `string`):

No description

## `products` (type: `string`):

No description

## `discussions` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "products": [
        "https://www.g2.com/products/slack/reviews"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("kaix/g2-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "products": ["https://www.g2.com/products/slack/reviews"],
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("kaix/g2-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "products": [
    "https://www.g2.com/products/slack/reviews"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call kaix/g2-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,kaix/g2-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/MGzffVZRO2j1Gh7td/builds/viH4VtYEBtcr0HcrO/openapi.json
