{"swagger":"2.0","info":{"title":"OSSInsight API","description":"OSSInsight API","version":"0.1.0"},"definitions":{},"paths":{"/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/healthy/":{"get":{"description":"Check if the API server is healthy.","tags":["system"],"responses":{"200":{"description":"OK","schema":{"type":"object","description":"OK","properties":{"healthy":{"type":"boolean"},"isTiDBHealthy":{"type":"boolean"},"isRedisHealthy":{"type":"boolean"},"isShadowTiDBHealthy":{"type":"boolean"}}}}}}},"/collections/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/q/{wildcard}":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/bot/questionToSQL/":{"post":{"parameters":[{"name":"body","in":"body","schema":{"type":"object","properties":{"question":{"type":"string"},"context":{"type":"object","properties":{"repo_id":{"type":"number"},"repo_name":{"type":"string"}}}}}}],"responses":{"200":{"description":"Default Response"}}}},"/v1/{wildcard}":{"get":{"operationId":"other-api","summary":"Other Query API","responses":{"200":{"description":"Default Response"}}}},"/user/":{"get":{"description":"Get the authenticated user","tags":["user"],"responses":{"200":{"description":"OK","schema":{"type":"object","description":"OK","properties":{"id":{"type":"number","description":"The id of user"},"name":{"type":"string","description":"The name of user"},"emailAddress":{"type":"string"},"emailGetUpdates":{"type":"boolean"},"githubId":{"type":"number"},"githubLogin":{"type":"string"},"avatarUrl":{"type":"string"},"createdAt":{"type":"string"}}}},"404":{"description":"User not found","schema":{"type":"object","description":"User not found"}}}}},"/explorer/answer/":{"post":{"summary":"Get answer of a new question","description":"Answer a question to the AI bot, he will return a sql query, and execute the query to get the result.","tags":["explorer"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","properties":{"question":{"type":"string"},"format":{"type":"string","enum":["json","sqlite"]},"ignoreCache":{"type":"boolean","default":false}}}}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/tags/":{"get":{"summary":"Get tags list","tags":["explorer"],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/":{"post":{"summary":"Answer new a question","description":"Answer a question to the AI bot, he will return a sql query, and execute the query to get the result.","tags":["explorer"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","properties":{"question":{"type":"string"},"ignoreCache":{"type":"boolean","default":false}}}}],"responses":{"200":{"description":"Default Response"}}}},"/collections/{id}/":{"get":{"parameters":[{"type":"number","required":true,"in":"path","name":"collectionId"}],"responses":{"200":{"description":"Default Response"}}}},"/bot/questionToSQL/quota/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/v1/collections/":{"get":{"operationId":"list-collections","summary":"List collections","description":"List collections.","tags":["Collections"],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"id","data_type":"BIGINT","nullable":false},{"col":"name","data_type":"VARCHAR","nullable":false}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"Repository ID"},"repo_name":{"type":"string","description":"Repository name"}},"additionalProperties":true},"example":[{"id":"1","name":"Static Site Generator"},{"id":"2","name":"Open Source Database"},{"id":"10001","name":"CSS Framework"},{"id":"10002","name":"Google Analytics Alternative"},{"id":"10003","name":"Low Code Development Tool"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/q/playground/":{"post":{"responses":{"200":{"description":"Default Response"}}}},"/user/email-updates/":{"get":{"description":"Get email updates setting","tags":["user"],"responses":{"200":{"description":"OK","schema":{"type":"object","description":"OK","properties":{"emailGetUpdates":{"type":"boolean"}}}}}},"put":{"description":"Update email updates setting","tags":["user"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["enable"],"properties":{"enable":{"type":"boolean","description":"Enable email updates"}}}}],"responses":{"200":{"description":"OK","schema":{"type":"object","description":"OK","properties":{"emailGetUpdates":{"type":"boolean"}}}}}}},"/user/subscriptions/":{"get":{"description":"Get email updates setting","tags":["user"],"responses":{"200":{"description":"OK","schema":{"type":"array","description":"OK","items":{"type":"object","properties":{"userId":{"type":"number"},"repoId":{"type":"number"},"repoName":{"type":"string"},"subscribed":{"type":"number"},"subscribedAt":{"type":"string"}}}}}}}},"/gh/organizations/{id}/":{"get":{"parameters":[{"type":"number","description":"The id of the organization.","required":true,"in":"path","name":"id"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/organizations/search/":{"get":{"parameters":[{"type":"string","description":"The keyword to search users.","required":true,"in":"query","name":"keyword"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/repos/search/":{"get":{"parameters":[{"type":"string","description":"The keyword to search repos.","required":true,"in":"query","name":"keyword"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/repositories/{id}/":{"get":{"parameters":[{"type":"number","description":"The id of the repository.","required":true,"in":"path","name":"id"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/users/{username}/":{"get":{"parameters":[{"type":"string","description":"The username of the user.","required":true,"in":"path","name":"username"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/user/{id}/":{"get":{"parameters":[{"type":"number","description":"The id of the user.","required":true,"in":"path","name":"id"}],"responses":{"200":{"description":"Default Response"}}}},"/gh/users/search/":{"get":{"parameters":[{"type":"string","description":"The keyword to search users.","required":true,"in":"query","name":"keyword"}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/{questionId}/":{"get":{"summary":"Get Question Result","description":"Return the question result","tags":["explorer"],"parameters":[{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}}},"/playground/sql/generate/":{"post":{"parameters":[{"name":"body","in":"body","schema":{"type":"object","properties":{"question":{"type":"string"},"context":{"type":"object","properties":{"repo_id":{"type":"number"},"repo_name":{"type":"string"}}}}}}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/recommend/":{"get":{"summary":"Get recommend questions","description":"Get recommend questions by AI generated or sort by popularity.","tags":["explorer"],"parameters":[{"type":"boolean","required":false,"in":"query","name":"aiGenerated"},{"type":"number","default":"10","minimum":1,"maximum":100,"required":false,"in":"query","name":"n"},{"type":"number","required":false,"in":"query","name":"tagId"}],"responses":{"200":{"description":"Default Response"}}}},"/q/explain/{queryName}/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/v1/trends/repos/":{"get":{"operationId":"list-trending-repos","summary":"List trending repos","description":"Trending repos is an open source alternative to GitHub trends, which showcases recently popular open source projects in the GitHub community.\n\n> **Note**\n>\n> Please URI encode the requested parameters, e.g. `C++` needs to be encoded as `C%2B%2B`.\n \n☁️ Daily run on [TiDB Cloud](https://tidbcloud.com/?utm_source=ossinsight&utm_medium=ossinsight_api), analyze upon dataset that has over 6 billion GitHub events.","tags":["Trends"],"parameters":[{"type":"string","description":"Specify the period of time to calculate trending repos.","enum":["past_24_hours","past_week","past_month","past_3_months"],"default":"past_24_hours","required":false,"in":"query","name":"period"},{"type":"string","description":"Specify using which programming language to filter trending repos. If not specified, all languages will be included.","enum":["All","JavaScript","Java","Python","PHP","C++","C#","TypeScript","Shell","C","Ruby","Rust","Go","Kotlin","HCL","PowerShell","CMake","Groovy","PLpgSQL","TSQL","Dart","Swift","HTML","CSS","Elixir","Haskell","Solidity","Assembly","R","Scala","Julia","Lua","Clojure","Erlang","Common Lisp","Emacs Lisp","OCaml","MATLAB","Objective-C","Perl","Fortran"],"default":"All","required":false,"in":"query","name":"language"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"repo_id","data_type":"INT","nullable":true},{"col":"repo_name","data_type":"VARCHAR","nullable":true},{"col":"primary_language","data_type":"VARCHAR","nullable":true},{"col":"description","data_type":"VARCHAR","nullable":true},{"col":"stars","data_type":"INT","nullable":true},{"col":"forks","data_type":"INT","nullable":true},{"col":"pull_requests","data_type":"INT","nullable":true},{"col":"pushes","data_type":"INT","nullable":true},{"col":"total_score","data_type":"DOUBLE","nullable":true},{"col":"contributor_logins","data_type":"VARCHAR","nullable":true},{"col":"collection_names","data_type":"VARCHAR","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"ID of the repo"},"repo_name":{"type":"string","description":"Name of the repo"},"primary_language":{"type":"string","description":"Primary programing language used by the repo"},"description":{"type":"string","description":"Description of the repo"},"stars":{"type":"string","description":"Number of stars in the period"},"forks":{"type":"string","description":"Number of forks in the period"},"pull_requests":{"type":"string","description":"Number of pull requests in the period"},"pushes":{"type":"string","description":"Number of pushes in the period"},"total_score":{"type":"string","description":"Total score of the repo"},"contributor_logins":{"type":"string","description":"Comma separated list of active contributor logins"},"collection_names":{"type":"string","description":"Comma separated list of collection names"}}},"example":[{"collection_names":"CICD","contributor_logins":"cplee,nektos-ci,usagirei,ae-ou,MrNossiom","description":"Run your GitHub Actions locally 🚀","forks":"5","primary_language":"Go","pull_requests":"6","pushes":"17","repo_id":"163883279","repo_name":"nektos/act","stars":"395","total_score":"1565.7526"},{"collection_names":"ChatGPT Alternatives","contributor_logins":"antonkesy,ruanslv,starplatinum3,AlexandroLuis,realhaik","description":"Inference code for LLaMA models","forks":"48","primary_language":"Python","pull_requests":"41","pushes":"7","repo_id":"601538369","repo_name":"facebookresearch/llama","stars":"209","total_score":"1079.0274"},{"collection_names":"Stable Diffusion Ecosystem","contributor_logins":"atiorh,SaladDays831,ZachNagengast,TimYao18,vzsg","description":"Stable Diffusion with Core ML on Apple Silicon","forks":"5","primary_language":"Python","pull_requests":"7","pushes":"5","repo_id":"566576114","repo_name":"apple/ml-stable-diffusion","stars":"99","total_score":"575.2498"},{"collection_names":"Stable Diffusion Ecosystem","contributor_logins":"danonymous856,EvilPhi666,FurkanGozukara,Prathyusha-98,ca-kishida","description":"High-Resolution Image Synthesis with Latent Diffusion Models","forks":"6","primary_language":"Python","pull_requests":"2","pushes":"","repo_id":"569927055","repo_name":"Stability-AI/stablediffusion","stars":"75","total_score":"483.0236"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/gh/repos/{owner}/{repo}/":{"get":{"parameters":[{"type":"string","description":"The owner of the repo.","required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response"}}}},"/v1/collections/hot/":{"get":{"operationId":"list-hot-collections","summary":"List hot collections","description":"List hot collections with top repositories of the collection.","tags":["Collections"],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"id","data_type":"BIGINT","nullable":false},{"col":"name","data_type":"VARCHAR","nullable":false},{"col":"repos","data_type":"BIGINT","nullable":false},{"col":"repo_id","data_type":"BIGINT","nullable":false},{"col":"repo_name","data_type":"VARCHAR","nullable":false},{"col":"repo_current_period_rank","data_type":"INT","nullable":true},{"col":"repo_past_period_rank","data_type":"INT","nullable":true},{"col":"repo_rank_changes","data_type":"BIGINT","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Collection ID"},"name":{"type":"string","description":"Collection name"},"repos":{"type":"string","description":"The number of repositories in the collection"},"repo_id":{"type":"string","description":"Repository ID"},"repo_name":{"type":"string","description":"Repository name"},"repo_current_period_rank":{"type":"string","description":"The rank of the repository in the collection in the current period"},"repo_past_period_rank":{"type":"string","description":"The rank of the repository in the collection in the past period"},"repo_rank_changes":{"type":"string","description":"The rank changes of the repository in the collection"}},"additionalProperties":true},"example":[{"id":"10010","name":"Artificial Intelligence","repos":"36","repo_id":"155220641","repo_name":"huggingface/transformers","repo_current_period_rank":"1","repo_past_period_rank":"1","repo_rank_changes":"0"},{"id":"10010","name":"Artificial Intelligence","repos":"36","repo_id":"65600975","repo_name":"pytorch/pytorch","repo_current_period_rank":"3","repo_past_period_rank":"4","repo_rank_changes":"1"},{"id":"10010","name":"Artificial Intelligence","repos":"36","repo_id":"458588993","repo_name":"nebuly-ai/nebullvm","repo_current_period_rank":"2","repo_past_period_rank":"2","repo_rank_changes":"0"},{"id":"10078","name":"ChatGPT Apps","repos":"36","repo_id":"599394820","repo_name":"Chanzhaoyu/chatgpt-web","repo_current_period_rank":"3","repo_past_period_rank":"6","repo_rank_changes":"3"},{"id":"10078","name":"ChatGPT Apps","repos":"36","repo_id":"609416865","repo_name":"yetone/openai-translator","repo_current_period_rank":"2","repo_past_period_rank":"","repo_rank_changes":""},{"id":"10078","name":"ChatGPT Apps","repos":"36","repo_id":"608555244","repo_name":"microsoft/visual-chatgpt","repo_current_period_rank":"1","repo_past_period_rank":"","repo_rank_changes":""}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":6,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/gh/repo/{owner}/{repo}/":{"get":{"parameters":[{"type":"string","description":"The owner of the repo.","required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/{questionId}/feedback/":{"get":{"summary":"Get feedbacks for answer","tags":["explorer"],"parameters":[{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}},"post":{"summary":"Add feedback for answer","tags":["explorer"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["satisfied"],"properties":{"satisfied":{"type":"boolean"},"feedbackContent":{"type":"string","maxLength":200}}}},{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}},"delete":{"summary":"Cancel feedback for answer","tags":["explorer"],"parameters":[{"type":"boolean","required":true,"in":"query","name":"satisfied"},{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/{questionId}/recommend/":{"post":{"summary":"Recommend question","tags":["explorer"],"parameters":[{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/{questionId}/tags/":{"get":{"summary":"Get tags of question","tags":["explorer"],"parameters":[{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}},"post":{"summary":"Set tags for question","tags":["explorer"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","properties":{"tagIds":{"type":"array","items":{"type":"number"}}}}},{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}}},"/playground/sql/generate/quota/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/repos/{owner}/{repo}/subscribe/":{"put":{"description":"Subscribe the repository updates","parameters":[{"type":"string","description":"The login of the repository's owner, for example, `pingcap` is the `owner` part of `pingcap/tidb` repository.","required":true,"in":"path","name":"owner"},{"type":"string","description":"The repo name of the repository, for example, `tidb` is the `repo` part of `pingcap/tidb` repository.","required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response"}}}},"/repos/{owner}/{repo}/unsubscribe/":{"put":{"description":"Unsubscribe the repository updates","parameters":[{"type":"string","description":"The login of the repository's owner, for example, `pingcap` is the `owner` part of `pingcap/tidb` repository.","required":true,"in":"path","name":"owner"},{"type":"string","description":"The repo name of the repository, for example, `tidb` is the `repo` part of `pingcap/tidb` repository.","required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response"}}}},"/explorer/questions/recommend/batchRefresh/":{"post":{"summary":"Refresh recommend questions","description":"Refresh recommended questions in batch.","tags":["explorer"],"responses":{"200":{"description":"Default Response"}}}},"/qo/repos/groups/osdb/":{"get":{"responses":{"200":{"description":"Default Response"}}}},"/v1/collections/{collection_id}/ranking_by_issues/":{"get":{"operationId":"collection-repo-ranking-by-issues","summary":"Repository ranking by issues","description":"Rank the GitHub repositories in the specified collection according to the number of issues.","tags":["Collections"],"parameters":[{"type":"string","description":"The period of the range.","enum":["past_28_days","past_month"],"default":"past_28_days","required":false,"in":"query","name":"period"},{"type":"number","description":"The ID of collection","required":true,"in":"path","name":"collection_id"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"repo_id","data_type":"BIGINT","nullable":false},{"col":"repo_name","data_type":"VARCHAR","nullable":false},{"col":"current_period_growth","data_type":"BIGINT","nullable":false},{"col":"current_period_rank","data_type":"BIGINT","nullable":false},{"col":"past_period_growth","data_type":"BIGINT","nullable":false},{"col":"past_period_rank","data_type":"BIGINT","nullable":false},{"col":"growth_pop","data_type":"DECIMAL","nullable":false},{"col":"rank_pop","data_type":"BIGINT","nullable":false},{"col":"total","data_type":"BIGINT","nullable":false}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"The repository ID"},"repo_name":{"type":"string","description":"The repository name"},"current_period_growth":{"type":"string","description":"issues growth in the current period (past 28 days / current month)"},"past_period_growth":{"type":"string","description":"issues growth in the past period (The 28 days before the past 28 days / past month)"},"growth_pop":{"type":"string","description":"The period-over-period growth of issues"},"rank_pop":{"type":"string","description":"The period-over-period rank changes of issues"},"total":{"type":"string","description":"The current total issues of repository"}},"additionalProperties":true},"example":[{"repo_id":"16563587","repo_name":"cockroachdb/cockroach","current_period_growth":"677","past_period_growth":"729","growth_pop":"-7.13","rank_pop":"0","total":"54541","current_period_rank":"1","past_period_rank":"1"},{"repo_id":"60246359","repo_name":"clickhouse/clickhouse","current_period_growth":"268","past_period_growth":"296","growth_pop":"-9.46","rank_pop":"-1","total":"16732","current_period_rank":"2","past_period_rank":"3"},{"repo_id":"41986369","repo_name":"pingcap/tidb","current_period_growth":"263","past_period_growth":"214","growth_pop":"22.90","rank_pop":"-3","total":"15622","current_period_rank":"3","past_period_rank":"6"},{"repo_id":"105944401","repo_name":"yugabyte/yugabyte-db","current_period_growth":"246","past_period_growth":"298","growth_pop":"-17.45","rank_pop":"2","total":"15079","current_period_rank":"4","past_period_rank":"2"},{"repo_id":"208728772","repo_name":"milvus-io/milvus","current_period_growth":"234","past_period_growth":"237","growth_pop":"-1.27","rank_pop":"0","total":"8675","current_period_rank":"5","past_period_rank":"5"},{"repo_id":"507775","repo_name":"elastic/elasticsearch","current_period_growth":"214","past_period_growth":"144","growth_pop":"48.61","rank_pop":"-3","total":"31578","current_period_rank":"6","past_period_rank":"9"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":7,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/collections/{collection_id}/ranking_by_prs/":{"get":{"operationId":"collection-repo-ranking-by-prs","summary":"Repository ranking by prs","description":"Rank the GitHub repositories in the specified collection according to the number of pull requests.","tags":["Collections"],"parameters":[{"type":"string","description":"The period of the range.","enum":["past_28_days","past_month"],"default":"past_28_days","required":false,"in":"query","name":"period"},{"type":"number","description":"The ID of collection","required":true,"in":"path","name":"collection_id"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"repo_id","data_type":"BIGINT","nullable":false},{"col":"repo_name","data_type":"VARCHAR","nullable":false},{"col":"current_period_growth","data_type":"BIGINT","nullable":false},{"col":"current_period_rank","data_type":"BIGINT","nullable":false},{"col":"past_period_growth","data_type":"BIGINT","nullable":false},{"col":"past_period_rank","data_type":"BIGINT","nullable":false},{"col":"growth_pop","data_type":"DECIMAL","nullable":false},{"col":"rank_pop","data_type":"BIGINT","nullable":false},{"col":"total","data_type":"BIGINT","nullable":false}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"The repository ID"},"repo_name":{"type":"string","description":"The repository name"},"current_period_growth":{"type":"string","description":"prs growth in the current period (past 28 days / current month)"},"past_period_growth":{"type":"string","description":"prs growth in the past period (The 28 days before the past 28 days / past month)"},"growth_pop":{"type":"string","description":"The period-over-period growth of prs"},"rank_pop":{"type":"string","description":"The period-over-period rank changes of prs"},"total":{"type":"string","description":"The current total prs of repository"}},"additionalProperties":true},"example":[{"repo_id":"16563587","repo_name":"cockroachdb/cockroach","current_period_growth":"677","past_period_growth":"729","growth_pop":"-7.13","rank_pop":"0","total":"54541","current_period_rank":"1","past_period_rank":"1"},{"repo_id":"60246359","repo_name":"clickhouse/clickhouse","current_period_growth":"268","past_period_growth":"296","growth_pop":"-9.46","rank_pop":"-1","total":"16732","current_period_rank":"2","past_period_rank":"3"},{"repo_id":"41986369","repo_name":"pingcap/tidb","current_period_growth":"263","past_period_growth":"214","growth_pop":"22.90","rank_pop":"-3","total":"15622","current_period_rank":"3","past_period_rank":"6"},{"repo_id":"105944401","repo_name":"yugabyte/yugabyte-db","current_period_growth":"246","past_period_growth":"298","growth_pop":"-17.45","rank_pop":"2","total":"15079","current_period_rank":"4","past_period_rank":"2"},{"repo_id":"208728772","repo_name":"milvus-io/milvus","current_period_growth":"234","past_period_growth":"237","growth_pop":"-1.27","rank_pop":"0","total":"8675","current_period_rank":"5","past_period_rank":"5"},{"repo_id":"507775","repo_name":"elastic/elasticsearch","current_period_growth":"214","past_period_growth":"144","growth_pop":"48.61","rank_pop":"-3","total":"31578","current_period_rank":"6","past_period_rank":"9"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":7,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/collections/{collection_id}/ranking_by_stars/":{"get":{"operationId":"collection-repo-ranking-by-stars","summary":"Repository ranking by stars","description":"Rank the GitHub repositories in the specified collection according to the number of stars.","tags":["Collections"],"parameters":[{"type":"string","description":"The period of the range.","enum":["past_28_days","past_month"],"default":"past_28_days","required":false,"in":"query","name":"period"},{"type":"number","description":"The ID of collection","required":true,"in":"path","name":"collection_id"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"repo_id","data_type":"BIGINT","nullable":false},{"col":"repo_name","data_type":"VARCHAR","nullable":false},{"col":"current_period_growth","data_type":"BIGINT","nullable":false},{"col":"current_period_rank","data_type":"BIGINT","nullable":false},{"col":"past_period_growth","data_type":"BIGINT","nullable":false},{"col":"past_period_rank","data_type":"BIGINT","nullable":false},{"col":"growth_pop","data_type":"DECIMAL","nullable":false},{"col":"rank_pop","data_type":"BIGINT","nullable":false},{"col":"total","data_type":"BIGINT","nullable":false}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"The repository ID"},"repo_name":{"type":"string","description":"The repository name"},"current_period_growth":{"type":"string","description":"Stars growth in the current period (past 28 days / current month)"},"past_period_growth":{"type":"string","description":"Stars growth in the past period (The 28 days before the past 28 days / past month)"},"growth_pop":{"type":"string","description":"The period-over-period growth of stars"},"rank_pop":{"type":"string","description":"The period-over-period rank changes of stars"},"total":{"type":"string","description":"The current total stars of repository"}},"additionalProperties":true},"example":[{"repo_id":"208728772","repo_name":"milvus-io/milvus","current_period_growth":"612","current_period_rank":"1","growth_pop":"-20.31","past_period_growth":"768","past_period_rank":"1","rank_pop":"0","total":"23803"},{"repo_id":"60246359","repo_name":"clickhouse/clickhouse","current_period_growth":"418","current_period_rank":"2","growth_pop":"-9.72","past_period_growth":"463","past_period_rank":"2","rank_pop":"0","total":"30935"},{"repo_id":"507775","repo_name":"elastic/elasticsearch","current_period_growth":"377","current_period_rank":"3","growth_pop":"2.45","past_period_growth":"368","past_period_rank":"4","rank_pop":"-1","total":"69228"},{"repo_id":"138754790","repo_name":"duckdb/duckdb","current_period_growth":"335","current_period_rank":"4","growth_pop":"-15.83","past_period_growth":"398","past_period_rank":"3","rank_pop":"1","total":"11408"},{"repo_id":"99919302","repo_name":"apache/incubator-doris","current_period_growth":"329","current_period_rank":"5","growth_pop":"28.02","past_period_growth":"257","past_period_rank":"6","rank_pop":"-1","total":"9310"},{"repo_id":"927442","repo_name":"postgres/postgres","current_period_growth":"210","current_period_rank":"6","growth_pop":"4.48","past_period_growth":"201","past_period_rank":"10","rank_pop":"-4","total":"13731"},{"repo_id":"41986369","repo_name":"pingcap/tidb","current_period_growth":"202","current_period_rank":"7","growth_pop":"-3.81","past_period_growth":"210","past_period_rank":"8","rank_pop":"-1","total":"36325"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":7,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/collections/{collection_id}/repos/":{"get":{"operationId":"list-repos-of-collection","summary":"List collection repositories","description":"List the repositories of collection.","tags":["Collections"],"parameters":[{"type":"number","description":"The ID of collection","required":true,"in":"path","name":"collection_id"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"repo_id","data_type":"BIGINT","nullable":false},{"col":"repo_name","data_type":"VARCHAR","nullable":false}]},"rows":{"type":"array","items":{"type":"object","properties":{"repo_id":{"type":"string","description":"Repository ID"},"repo_name":{"type":"string","description":"Repository name"}},"additionalProperties":true},"example":[{"repo_id":"507775","repo_name":"elastic/elasticsearch"},{"repo_id":"41986369","repo_name":"pingcap/tidb"},{"repo_id":"60246359","repo_name":"clickhouse/clickhouse"},{"repo_id":"108110","repo_name":"mongodb/mongo"},{"repo_id":"48833910","repo_name":"tikv/tikv"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/issue_creators/":{"get":{"operationId":"list-issue-creators","summary":"List issue creators","description":"Querying the issue creators for a given repository.","tags":["Issue Creators"],"parameters":[{"type":"string","description":"Specify the field by which to sort the issue creators list (values with a `-desc` suffix indicate descending sorting)","enum":["issues","issues-desc","first_issue_opened_at","first_issue_opened_at-desc","login"],"default":"issues-desc","required":false,"in":"query","name":"sort"},{"type":"boolean","description":"Whether to exclude robot accounts (includes GitHub App and normal users whose username matches the pattern, for example: `ti-chi-bot`).","default":true,"required":false,"in":"query","name":"exclude_bots"},{"type":"integer","description":"Page number of the results to fetch.","default":1,"required":false,"in":"query","name":"page"},{"type":"integer","description":"The number of results per page (max 100).","default":30,"required":false,"in":"query","name":"page_size"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"id","data_type":"INT","nullable":false},{"col":"login","data_type":"VARCHAR","nullable":false},{"col":"name","data_type":"VARCHAR","nullable":false},{"col":"issues","data_type":"INT","nullable":true},{"col":"first_issue_opened_at","data_type":"DATETIME","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the issue creator"},"login":{"type":"string","description":"The login (username) of the issue creator"},"name":{"type":"string","description":"The name of the issue creator"},"issues":{"type":"string","description":"The number of issues created by the issue creator"},"first_issue_opened_at":{"type":"string","description":"The date of the first issue created by the issue creator"}},"additionalProperties":true},"example":[{"id":"73684","login":"yahonda","name":"Yasuo Honda","issues":"12","first_issue_opened_at":"2022-01-04 02:47:05"},{"id":"1000627","login":"lcwangchao","name":"王超","issues":"211","first_issue_opened_at":"2021-06-03 01:06:44"},{"id":"7499936","login":"qw4990","name":"Yuanjia Zhang","issues":"276","first_issue_opened_at":"2018-12-24 02:55:49"},{"id":"15825830","login":"AilinKid","name":"Arenatlx","issues":"128","first_issue_opened_at":"2019-07-26 14:06:29"},{"id":"21033020","login":"glkappe","name":"","issues":"29","first_issue_opened_at":"2020-07-30 08:12:09"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/explorer/questions/{questionId}/recommend/cancel/":{"post":{"summary":"Cancel recommend question","tags":["explorer"],"parameters":[{"type":"string","required":true,"in":"path","name":"questionId"}],"responses":{"200":{"description":"Default Response"}}}},"/v1/repos/{owner}/{repo}/pull_request_creators/":{"get":{"operationId":"list-pull-request-creators","summary":"List pull request creators","description":"Querying the pull request creators list in a given repository.\n\nThis API provides multiple ways to sort the query results, for example:\n\n- `sort=prs-desc` (Default): Sorted in descending order based on `prs` field (the number of PRs they have contributed), meaning that the contributor with the most PRs is at the top.\n- `sort=first_pr_merged_at-desc`: Sorted in descending order based on `first_pr_merged_at` field (the time of their first merged PR), which means you can got a list of new code contributors of the repository.\n  ","tags":["Pull Request Creators"],"parameters":[{"type":"string","description":"Specify the field by which to sort the pull request creators list (values with a `-desc` suffix indicate descending sorting)","enum":["login","prs","prs-desc","first_pr_opened_at","first_pr_opened_at-desc","first_pr_merged_at","first_pr_merged_at-desc"],"default":"prs-desc","required":false,"in":"query","name":"sort"},{"type":"boolean","description":"Whether to exclude robot accounts (includes GitHub App and normal users whose username matches the pattern, for example: `ti-chi-bot`).","default":true,"required":false,"in":"query","name":"exclude_bots"},{"type":"integer","description":"Page number of the results to fetch.","default":1,"required":false,"in":"query","name":"page"},{"type":"integer","description":"The number of results per page (max 100).","default":30,"required":false,"in":"query","name":"page_size"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"id","data_type":"INT","nullable":false},{"col":"login","data_type":"VARCHAR","nullable":false},{"col":"name","data_type":"VARCHAR","nullable":false},{"col":"prs","data_type":"INT","nullable":true},{"col":"first_pr_opened_at","data_type":"DATETIME","nullable":true},{"col":"first_pr_merged_at","data_type":"DATETIME","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the pull request creator"},"login":{"type":"string","description":"The login (username) of the pull request creator"},"name":{"type":"string","description":"The name of the pull request creator"},"prs":{"type":"string","description":"The number of pull requests created by the pull request creator"},"first_pr_opened_at":{"type":"string","description":"The date of the first pull request created by the pull request creator"},"first_pr_merged_at":{"type":"string","description":"The date of the first merged pull request be merged into the repository"}},"additionalProperties":true},"example":[{"id":"1420062","login":"tiancaiamao","name":"","prs":"1300","first_pr_opened_at":"2016-06-20 14:08:39","first_pr_merged_at":"2016-06-21 07:45:27"},{"id":"3427324","login":"hawkingrei","name":"Weizhen Wang","prs":"927","first_pr_opened_at":"2017-05-17 15:00:50","first_pr_merged_at":"2017-05-22 04:47:11"},{"id":"26020263","login":"crazycs520","name":"crazycs","prs":"788","first_pr_opened_at":"2018-06-12 05:02:07","first_pr_merged_at":"2018-06-29 03:01:35"},{"id":"891222","login":"coocood","name":"Evan Zhou","prs":"779","first_pr_opened_at":"2015-09-06 05:58:15","first_pr_merged_at":"2015-09-06 07:10:13"},{"id":"4242506","login":"zimulala","name":"Lynn","prs":"774","first_pr_opened_at":"2015-09-06 10:51:19","first_pr_merged_at":"2015-09-06 12:32:33"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/issue_creators/history/":{"get":{"operationId":"issue-creators-history","summary":"Issue creators history","description":"Querying the historical trend of the number of issue creators in a given repository.","tags":["Issue Creators"],"parameters":[{"type":"string","description":"The time interval of the data points.","enum":["day","week","month"],"default":"month","required":false,"in":"query","name":"per"},{"type":"string","description":"The start date of the time range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the time range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"date","data_type":"VARCHAR","nullable":true},{"col":"issue_creators","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","description":"The date of the data point"},"issue_creators":{"type":"string","description":"The number of issue creators on the date point"}},"additionalProperties":true},"example":[{"date":"2023-04-01","issue_creators":"1546"},{"date":"2023-05-01","issue_creators":"1560"},{"date":"2023-06-01","issue_creators":"1568"},{"date":"2023-07-01","issue_creators":"1579"},{"date":"2023-08-01","issue_creators":"1580"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/issue_creators/countries/":{"get":{"operationId":"list-countries-of-issue-creators","summary":"List countries/regions of issue creators","description":"List countries/regions of stargazers for the specified repository.\n  \n> **Notice**:\n> In the overall data, about **3.5%** of GitHub users provided valid country/region information.\n\n> **Note**: \n> By default, the API does not count users without valid country/region information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Issue Creators"],"parameters":[{"type":"boolean","description":"Whether to exclude issue creators with unknown country/region information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"country_code","data_type":"CHAR","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true},{"col":"issue_creators","data_type":"BIGINT","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"country_code":{"type":"string","description":"Country/region code"},"issue_creators":{"type":"string","description":"Number of issue creators from the country/region"},"percentage":{"type":"string","description":"Percentage of issue creators from the country/region"}},"additionalProperties":true},"example":[{"country_code":"CN","issue_creators":"7131","percentage":"0.8749"},{"country_code":"US","issue_creators":"316","percentage":"0.0388"},{"country_code":"CA","issue_creators":"243","percentage":"0.0298"},{"country_code":"NL","issue_creators":"223","percentage":"0.0274"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/issue_creators/organizations/":{"get":{"operationId":"list-organizations-of-issue-creators","summary":"List organizations of stargazers","description":"List organizations of stargazers for the specified repository. \n\n> **Notice**:\n> In the overall data, about **5.62%** of GitHub users provided valid organization information.\n\n> **Note**: \n> By default, the API does not count users without valid organization information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Issue Creators"],"parameters":[{"type":"boolean","description":"Whether to exclude issue creators with unknown organization information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"org_name","data_type":"VARCHAR","nullable":true},{"col":"issue_creators","data_type":"BIGINT","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"issue_creators":{"type":"string","description":"Number of issue creators from the organization"},"org_name":{"type":"string","description":"Name of the organization"},"percentage":{"type":"string","description":"Percentage of issue creators from the organization"}},"additionalProperties":true},"example":[{"issue_creators":"117","org_name":"pingcap","percentage":"0.2833"},{"issue_creators":"9","org_name":"tencent","percentage":"0.0218"},{"issue_creators":"7","org_name":"alibaba","percentage":"0.0169"},{"issue_creators":"6","org_name":"bytedance","percentage":"0.0145"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/stargazers/countries/":{"get":{"operationId":"list-countries-of-stargazers","summary":"List countries/regions of stargazers","description":"List countries/regions of stargazers for the specified repository.\n  \n> **Notice**:\n> In the overall data, about **3.5%** of GitHub users provided valid country/region information.\n\n> **Note**: \n> By default, the API does not count users without valid country/region information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Stargazers"],"parameters":[{"type":"boolean","description":"Whether to exclude issue creators with unknown country/region information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"country_code","data_type":"CHAR","nullable":true},{"col":"stargazers","data_type":"BIGINT","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"country_code":{"type":"string","description":"Country/region code"},"stargazers":{"type":"string","description":"Number of stargazers from the country/region"},"percentage":{"type":"string","description":"Percentage of stargazers from the country/region"}}},"example":[{"country_code":"CN","percentage":"0.5935","stargazers":"9189"},{"country_code":"US","percentage":"0.0996","stargazers":"1542"},{"country_code":"JP","percentage":"0.0305","stargazers":"473"},{"country_code":"DE","percentage":"0.0267","stargazers":"413"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/stargazers/organizations/":{"get":{"operationId":"list-organizations-of-stargazers","summary":"List organizations of stargazers","description":"List organizations of stargazers for the specified repository. \n\n> **Notice**:\n> In the overall data, about **5.62%** of GitHub users provided valid organization information.\n\n> **Note**: \n> By default, the API does not count users without valid organization information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Stargazers"],"parameters":[{"type":"boolean","description":"Whether to exclude stargazers with unknown organization information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"org_name","data_type":"VARCHAR","nullable":true},{"col":"stargazers","data_type":"BIGINT","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"org_name":{"type":"string","description":"Name of the organization"},"percentage":{"type":"string","description":"Percentage of stargazers from the organization"},"stargazers":{"type":"string","description":"Number of stargazers from the organization"}}},"example":[{"org_name":"tencent","percentage":"0.0217","stargazers":"199"},{"org_name":"bytedance","percentage":"0.0192","stargazers":"176"},{"org_name":"alibaba","percentage":"0.0162","stargazers":"148"},{"org_name":"pingcap","percentage":"0.0119","stargazers":"109"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/pull_request_creators/history/":{"get":{"operationId":"pull-request-creators-history","summary":"Pull request creators history","description":"Querying the historical trend of the number of pull request creators in a given repository.","tags":["Pull Request Creators"],"parameters":[{"type":"string","description":"The time interval of the data points.","enum":["day","week","month"],"default":"month","required":false,"in":"query","name":"per"},{"type":"string","description":"The start date of the time range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the time range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"date","data_type":"VARCHAR","nullable":true},{"col":"pull_request_creators","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","description":"The date of the data point"},"pull_request_creators":{"type":"string","description":"The cumulative number of pull request creators"}}},"example":[{"date":"2023-03-01","pull_request_creators":"912"},{"date":"2023-04-01","pull_request_creators":"915"},{"date":"2023-05-01","pull_request_creators":"924"},{"date":"2023-06-01","pull_request_creators":"932"},{"date":"2023-08-01","pull_request_creators":"933"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/stargazers/history/":{"get":{"operationId":"stargazers-history","summary":"Stargazers history","description":"Querying the historical trend of the number of stargazers in a given repository.","tags":["Stargazers"],"parameters":[{"type":"string","description":"The time interval of the data points.","enum":["day","week","month"],"default":"month","required":false,"in":"query","name":"per"},{"type":"string","description":"The start date of the time range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the time range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"date","data_type":"VARCHAR","nullable":true},{"col":"pull_request_creators","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","description":"The date of the data point"},"stargazers":{"type":"string","description":"The cumulative number of stargazers"}}},"example":[{"date":"2023-04-01","stargazers":"35389"},{"date":"2023-05-01","stargazers":"35593"},{"date":"2023-06-01","stargazers":"35805"},{"date":"2023-07-01","stargazers":"36019"},{"date":"2023-08-01","stargazers":"36026"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":5,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/pull_request_creators/countries/":{"get":{"operationId":"list-countries-of-pr-creators","summary":"List countries/regions of PR creators","description":"List countries/regions of pull request creators for the specified repository.\n\n> **Notice**:\n> In the overall data, about **3.5%** of GitHub users provided valid country/region information.\n\n> **Note**: \n> By default, the API does not count users without valid country/region information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Pull Request Creators"],"parameters":[{"type":"boolean","description":"Whether to exclude issue creators with unknown country/region information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"country_code","data_type":"CHAR","nullable":true},{"col":"pull_request_creators","data_type":"BIGINT","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"country_code":{"type":"string","description":"Country/region code"},"percentage":{"type":"string","description":"Percentage of pull request creators from the country/region"},"pull_request_creators":{"type":"string","description":"Number of pull request creators from the country/region"}}},"example":[{"country_code":"CN","percentage":"0.8802","pull_request_creators":"13619"},{"country_code":"NL","percentage":"0.0508","pull_request_creators":"786"},{"country_code":"US","percentage":"0.0400","pull_request_creators":"619"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":3,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/v1/repos/{owner}/{repo}/pull_request_creators/organizations/":{"get":{"operationId":"list-organizations-of-pr-creators","summary":"List organizations of PR creators","description":"List organizations of pull request creators for the specified repository.\n\n> **Notice**:\n> In the overall data, about **5.62%** of GitHub users has valid organization information.\n\n> **Note**: \n> By default, the API does not count users without valid organization information. \n> If you need to count these users, you can set the `exclude_unknown` parameter to `false`.\n","tags":["Pull Request Creators"],"parameters":[{"type":"boolean","description":"Whether to exclude PR creators with unknown organization information","default":true,"required":false,"in":"query","name":"exclude_unknown"},{"type":"string","description":"The start date of the range.","default":"2000-01-01","required":false,"in":"query","name":"from"},{"type":"string","description":"The end date of the range.","default":"2099-01-01","required":false,"in":"query","name":"to"},{"type":"string","description":"The owner of the repo.","examples":["pingcap"],"required":true,"in":"path","name":"owner"},{"type":"string","description":"The name of the repo.","examples":["tidb"],"required":true,"in":"path","name":"repo"}],"responses":{"200":{"description":"Default Response","schema":{"type":"object","required":["type","data"],"properties":{"type":{"type":"string","description":"The type of the endpoint.","enum":["sql_endpoint"],"example":"sql_endpoint"},"data":{"type":"object","required":["columns","rows","result"],"properties":{"columns":{"type":"array","items":{"type":"object","required":["col","data_type","nullable"],"properties":{"col":{"type":"string","description":"The name of the column in the query result."},"data_type":{"type":"string","enum":["CHAR","BIGINT","DECIMAL","INT","UNSIGNED BIGINT","TINYINT","TIMESTAMP","TEXT","VARCHAR","DATETIME","DOUBLE","FLOAT","DATE","TIME","YEAR","MEDIUMINT","SMALLINT","BIT","BINARY","VARBINARY","JSON","ENUM","SET","TINYTEXT","MEDIUMTEXT","LONGTEXT","TINYBLOB","MEDIUMBLOB","BLOB","LONGBLOB"],"description":"The data type of the column."},"nullable":{"type":"boolean","description":"Whether the column is nullable."}},"additionalProperties":true},"example":[{"col":"org_name","data_type":"VARCHAR","nullable":true},{"col":"pull_request_creators","data_type":"BIGINT","nullable":true},{"col":"percentage","data_type":"DECIMAL","nullable":true}]},"rows":{"type":"array","items":{"type":"object","properties":{"org_name":{"type":"string","description":"Name of the organization"},"percentage":{"type":"string","description":"Percentage of pull request creators from the organization"},"pull_request_creators":{"type":"string","description":"Number of pull request creators from the organization"}}},"example":[{"org_name":"pingcap","percentage":"0.3064","pull_request_creators":"106"},{"org_name":"bytedance","percentage":"0.0318","pull_request_creators":"11"},{"org_name":"alibaba","percentage":"0.0260","pull_request_creators":"9"},{"org_name":"tencent","percentage":"0.0173","pull_request_creators":"6"}]},"result":{"type":"object","properties":{"code":{"type":"number","description":"The code of the response."},"message":{"type":"string","description":"The message of the response."},"start_ms":{"type":"number","description":"The start time of the query in milliseconds."},"end_ms":{"type":"number","description":"The end time of the query in milliseconds."},"latency":{"type":"string","description":"The latency of the query."},"row_count":{"type":"number","description":"The number of rows in the query result."},"row_affect":{"type":"number","description":"The number of rows affected by the query."},"limit":{"type":"number","description":"The maximum number of rows in the query result."},"databases":{"type":"array","description":"The databases used in the query.","items":{"type":"string"}}},"additionalProperties":true,"example":{"code":200,"message":"Query OK!","start_ms":1690957407469,"end_ms":1690957407499,"latency":"30ms","row_count":4,"row_affect":0,"limit":50,"databases":["gharchive_dev"]}}}}}}}}}},"/docs/json":{"get":{"responses":{"200":{"description":"Default Response"}}}}}}