{
  "openapi": "3.0.1",
  "info": {
    "title": "Reddit User Profile Posts and Comments Scraper User Comments",
    "description": "Extract Reddit user profile posts and comments, including post titles, comment text, subreddits, scores, timestamps, awards, and engagement data. Analyze user activity, research communities, track content history, discover audience insights, and build datasets for marketing and research.",
    "version": "0.1",
    "x-build-id": "rilvlaNVamZdKWwZ5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapier~reddit-user-profile-posts-and-comments-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapier-reddit-user-profile-posts-and-comments-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/scrapier~reddit-user-profile-posts-and-comments-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapier-reddit-user-profile-posts-and-comments-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/scrapier~reddit-user-profile-posts-and-comments-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapier-reddit-user-profile-posts-and-comments-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": "🎯 Reddit Profiles or Keywords",
            "type": "array",
            "description": "One or more Reddit targets. Each entry can be a bare username (cyPersimmon9), a u/ handle (u/cyPersimmon9), a full profile URL (https://www.reddit.com/user/cyPersimmon9), or a keyword search (keyword:python).\n\nAuthored-comment collection applies to user targets only; keyword targets return posts.",
            "items": {
              "type": "string"
            }
          },
          "includeUserComments": {
            "title": "💬 Include Authored Comments",
            "type": "boolean",
            "description": "When on, fetch the user's own written comments in addition to their posts. Example: a profile with 8 posts and maxUserComments=50 yields up to 8 post rows + 50 comment rows + 1 summary row. Default is true. (Keyword targets are unaffected.)",
            "default": true
          },
          "maxUserComments": {
            "title": "🔢 Max Authored Comments Per User",
            "minimum": 0,
            "maximum": 1000,
            "type": "integer",
            "description": "Cap on authored comments collected per user (0 = skip). A user feed serves at most ~1000 most-recent comments. Example: 50 keeps the 50 newest authored comments. Default is 50.",
            "default": 50
          },
          "userCommentSort": {
            "title": "🗂️ Authored Comment Sort",
            "enum": [
              "new",
              "top",
              "controversial",
              "hot"
            ],
            "type": "string",
            "description": "Ordering applied to the user's authored-comment feed. Default is new.",
            "default": "new"
          },
          "sortOrder": {
            "title": "🗂️ Post Sort",
            "enum": [
              "new",
              "hot",
              "top",
              "controversial"
            ],
            "type": "string",
            "description": "How submitted posts are ordered: new (recent), hot (trending), top (highest scored), controversial (most debated). Default is new.",
            "default": "new"
          },
          "maxPosts": {
            "title": "🔢 Post Limit Per Profile",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum submitted posts collected per profile or keyword. A user feed serves at most ~1000 most-recent posts. Example: 50 keeps the 50 newest posts. Default is 50.",
            "default": 50
          },
          "fetchSelftext": {
            "title": "📄 Enrich Posts With Full Text",
            "type": "boolean",
            "description": "Attempt per-post enrichment (full untruncated selftext, preview, subreddit_subscribers, video media). Note: enrichment uses Reddit's per-thread JSON which is frequently bot-walled in-container, so listing-level fidelity is what is reliably returned. Default is true.",
            "default": true
          },
          "maxComments": {
            "title": "🗨️ Reply Comments Per Post",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Attach up to this many top-level comments made ON each post (a `comments` array on the post row). Distinct from the user's OWN authored comments (see Authored Comment History above). Default is 0 (skip). Sourced from per-thread JSON — may be empty when Reddit walls it.",
            "default": 0
          },
          "proxyConfiguration": {
            "title": "🌐 Proxy Configuration",
            "type": "object",
            "description": "Proxy settings. Default routes through Apify residential with retries; if you supply a custom proxy (proxyUrls or a non-residential Apify group) it is tried first, then residential fallback."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}