Skip to main content
이제 REST API의 버전이 지정되었습니다. 자세한 내용은 "API 버전 관리 정보"를 참조하세요.

트래픽률 제한에 대한 REST API 엔드포인트

REST API를 사용하여 현재 속도 제한 상태를 확인합니다.

속도 제한 정보

언제든지 현재 속도 제한 상태를 확인할 수 있습니다. 속도 제한 규칙에 대한 자세한 내용은 "REST API에 대한 트래픽률 제한"을 참조하세요.

검색 항목에 대한 REST API에는 REST API 엔드포인트의 나머지 부분을 제어하는 속도 제한과는 별도로 사용자 지정 속도 제한이 있습니다. 자세한 내용은 "검색에 대한 REST API 엔드포인트"을(를) 참조하세요. 또한 GraphQL API에는 REST API의 속도 제한과는 별도이며 다른 방식으로 계산되는 사용자 지정 속도 제한이 있습니다. 자세한 내용은 "GraphQL API에 대한 트래픽률 제한 및 노드 제한"을(를) 참조하세요. 이러한 이유로 API 응답은 속도 제한을 분류합니다. resources 아래에는 다른 범주와 관련된 개체가 표시됩니다.

  • core 개체는 REST API에서 검색과 관련되지 않은 모든 리소스에 대한 속도 제한 상태를 알려줍니다.

  • search 개체는 검색 REST API에 대한 속도 제한 상태를 알려줍니다(코드 검색 제외). 자세한 내용은 "검색에 대한 REST API 엔드포인트"을(를) 참조하세요.

  • code_search 개체는 검색 REST API에 대한 속도 제한 상태를 알려줍니다. 자세한 내용은 "검색에 대한 REST API 엔드포인트"을(를) 참조하세요.

  • graphql 개체는 GraphQL API에 대한 속도 제한 상태를 알려줍니다.

  • integration_manifest 개체는 POST /app-manifests/{code}/conversions 작업에 대한 속도 제한 상태를 알려줍니다. 자세한 내용은 "매니페스트에서 GitHub 앱 등록"을(를) 참조하세요.

  • dependency_snapshots 개체는 종속성 그래프 스냅샷을 제출하기 위한 속도 제한 상태를 제공합니다. 자세한 내용은 "종속성 그래프에 대한 REST API 엔드포인트"을(를) 참조하세요.

  • code_scanning_upload 개체는 코드 검사에 SARIF 결과를 업로드하기 위한 속도 제한 상태를 알려줍니다. 자세한 내용은 "GitHub에 SARIF 파일 업로드"을(를) 참조하세요.

  • actions_runner_registration 개체는 GitHub Actions에 자체 호스팅 실행기를 등록하기 위한 속도 제한 상태를 알려줍니다. 자세한 내용은 "자체 호스트형 실행기에 대한 REST API 엔드포인트"을(를) 참조하세요.

속도 제한 응답의 헤더 및 값에 대한 자세한 내용은 “REST API에 대한 트래픽률 제한”을 참조하세요.

Get rate limit status for the authenticated user

Note: Accessing this endpoint does not count against your REST API rate limit.

Some categories of endpoints have custom rate limits that are separate from the rate limit governing the other REST API endpoints. For this reason, the API response categorizes your rate limit. Under resources, you'll see objects relating to different categories:

  • The core object provides your rate limit status for all non-search-related resources in the REST API.
  • The search object provides your rate limit status for the REST API for searching (excluding code searches). For more information, see "Search."
  • The code_search object provides your rate limit status for the REST API for searching code. For more information, see "Search code."
  • The graphql object provides your rate limit status for the GraphQL API. For more information, see "Resource limitations."
  • The integration_manifest object provides your rate limit status for the POST /app-manifests/{code}/conversions operation. For more information, see "Creating a GitHub App from a manifest."
  • The dependency_snapshots object provides your rate limit status for submitting snapshots to the dependency graph. For more information, see "Dependency graph."
  • The code_scanning_upload object provides your rate limit status for uploading SARIF results to code scanning. For more information, see "Uploading a SARIF file to GitHub."
  • The actions_runner_registration object provides your rate limit status for registering self-hosted runners in GitHub Actions. For more information, see "Self-hosted runners."
  • The source_import object is no longer in use for any API endpoints, and it will be removed in the next API version. For more information about API versions, see "API Versions."

Note: The rate object is deprecated. If you're writing new API client code or updating existing code, you should use the core object instead of the rate object. The core object contains the same information that is present in the rate object.

"Get rate limit status for the authenticated user"에 대한 세분화된 액세스 토큰

이 엔드포인트는 다음 토큰 형식에서 작동합니다.:

토큰에 어떤 권한도 필요하지 않습니다.

공용 리소스만 요청되는 경우 인증 없이 이 엔드포인트를 사용할 수 있습니다.

"Get rate limit status for the authenticated user"에 대한 HTTP 응답 상태 코드

상태 코드설명
200

OK

304

Not modified

404

Resource not found

"Get rate limit status for the authenticated user"에 대한 코드 샘플

요청 예제

get/rate_limit
curl -L \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "X-GitHub-Api-Version: 2022-11-28" \ https://api.github.com/rate_limit

Response

Status: 200
{ "resources": { "core": { "limit": 5000, "used": 1, "remaining": 4999, "reset": 1691591363 }, "search": { "limit": 30, "used": 12, "remaining": 18, "reset": 1691591091 }, "graphql": { "limit": 5000, "used": 7, "remaining": 4993, "reset": 1691593228 }, "integration_manifest": { "limit": 5000, "used": 1, "remaining": 4999, "reset": 1691594631 }, "source_import": { "limit": 100, "used": 1, "remaining": 99, "reset": 1691591091 }, "code_scanning_upload": { "limit": 500, "used": 1, "remaining": 499, "reset": 1691594631 }, "actions_runner_registration": { "limit": 10000, "used": 0, "remaining": 10000, "reset": 1691594631 }, "scim": { "limit": 15000, "used": 0, "remaining": 15000, "reset": 1691594631 }, "dependency_snapshots": { "limit": 100, "used": 0, "remaining": 100, "reset": 1691591091 }, "code_search": { "limit": 10, "used": 0, "remaining": 10, "reset": 1691591091 } }, "rate": { "limit": 5000, "used": 1, "remaining": 4999, "reset": 1372700873 } }