{
  "openapi": "3.0.1",
  "info": {
    "title": "GitHub Repo Search — Stars, Language & Topics",
    "description": "Search and scrape GitHub repositories by keyword, language, stars, forks, or topic. Extract structured repo metadata including owner, license, topics, and activity timestamps. Sort by stars, forks, or recently updated. Export to JSON, CSV, or API. No token required.",
    "version": "2.0",
    "x-build-id": "O3LqPHCXwDD1YE2So"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/ryanclinton~github-repo-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-ryanclinton-github-repo-search",
        "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/ryanclinton~github-repo-search/runs": {
      "post": {
        "operationId": "runs-sync-ryanclinton-github-repo-search",
        "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/ryanclinton~github-repo-search/run-sync": {
      "post": {
        "operationId": "run-sync-ryanclinton-github-repo-search",
        "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": {
          "query": {
            "title": "Search Query",
            "type": "string",
            "description": "Search query using GitHub syntax. Examples: 'web scraping', 'machine learning language:python', 'topic:nextjs stars:>500'",
            "default": "web scraping language:python"
          },
          "mode": {
            "title": "Solution Mode",
            "enum": [
              "market-map",
              "dependency-audit",
              "adoption-shortlist",
              "maintainer-outreach",
              "trend-watch",
              "repo-due-diligence"
            ],
            "type": "string",
            "description": "Pre-configured workflow. Each mode auto-selects enrichments, scoring, and sorting for a specific use case. Leave empty for manual configuration."
          },
          "sortBy": {
            "title": "Sort By",
            "enum": [
              "stars",
              "forks",
              "updated",
              "best-match"
            ],
            "type": "string",
            "description": "How to sort results. Overridden by mode if set.",
            "default": "stars"
          },
          "minStars": {
            "title": "Min Stars",
            "type": "integer",
            "description": "Minimum star count (appended to query as stars:>=N)"
          },
          "language": {
            "title": "Language Filter",
            "type": "string",
            "description": "Filter by programming language (e.g., python, rust, typescript)"
          },
          "maxResults": {
            "title": "Max Results",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum repositories to return. With auto-partition enabled, can exceed 1,000.",
            "default": 30
          },
          "excludeForks": {
            "title": "Exclude Forks",
            "type": "boolean",
            "description": "Filter out forked repositories from results",
            "default": false
          },
          "excludeArchived": {
            "title": "Exclude Archived",
            "type": "boolean",
            "description": "Filter out archived repositories from results",
            "default": false
          },
          "autoPartitionResults": {
            "title": "Auto-Partition (Break 1,000 Cap)",
            "type": "boolean",
            "description": "When a query matches more than 1,000 repos, automatically split into sub-queries by star ranges to retrieve more. Deduplicates across partitions.",
            "default": false
          },
          "compareRepos": {
            "title": "Compare Specific Repos",
            "maxItems": 20,
            "type": "array",
            "description": "Compare specific repos side-by-side. Enter full names like 'facebook/react'. Skips search and fetches each repo directly. Scores, ranks, and picks a winner.",
            "items": {
              "type": "string"
            }
          },
          "enrichRepoData": {
            "title": "Enrich Repo Data",
            "type": "boolean",
            "description": "Fetch additional data per repo: community profile, activity stats, languages, releases, contributor count. Adds ~3-5 parallel API calls per repo. Auto-enabled by solution modes.",
            "default": false
          },
          "extractContributorEmails": {
            "title": "Extract Contributor Emails",
            "type": "boolean",
            "description": "Extract real email addresses from recent commits. Filters out noreply/bot addresses. Auto-enabled by maintainer-outreach and due-diligence modes.",
            "default": false
          },
          "compareToPreviousRun": {
            "title": "Compare to Previous Run",
            "type": "boolean",
            "description": "Detect changes since last run: new repos, score changes, newly abandoned repos. Useful for scheduled monitoring. Stores state in a named key-value store.",
            "default": false
          },
          "githubToken": {
            "title": "GitHub Token (Optional)",
            "type": "string",
            "description": "Personal access token for higher rate limits (5000 req/hr vs 60). Strongly recommended for enrichment and large result sets. Create at github.com/settings/tokens — no special scopes needed."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}