# REST API 简介

熟悉 REST API 文档。

可以使用 GitHub 的 API 生成脚本和应用程序，这些脚本和应用程序可自动执行进程、与 GitHub 集成并扩展 GitHub。 例如，可使用 API 对问题进行会审、生成分析仪表板或者管理发布。

各个 REST API 端点单独记录，端点按其主要影响的资源分类。 例如，可以在 [适用于问题的 REST API 终结点](/zh/enterprise-server@3.21/rest/issues) 中找到议题相关终结点。

## REST API 入门

如果不熟悉 REST API\*\*\*\*，可以参考快速入门或入门指南获取简介。 有关详细信息，请参阅：

* [GitHub REST API 快速入门](/zh/enterprise-server@3.21/rest/quickstart)
* [REST API 入门](/zh/enterprise-server@3.21/rest/guides/getting-started-with-the-rest-api)

如果熟悉 REST API\*\*\*\* 但不熟悉 GitHub 的 REST API，参考身份验证文档可能有帮助。 有关详细信息，请参阅：

* [对 REST API 进行身份验证](/zh/enterprise-server@3.21/rest/overview/authenticating-to-the-rest-api)

如果要生成使用 REST API 的脚本或应用程序\*\*\*\*，下列部分指南可能有帮助。 有关使用 REST API 编写脚本的示例，请参阅：

* [使用 REST API 和 JavaScript 编写脚本](/zh/enterprise-server@3.21/rest/guides/scripting-with-the-rest-api-and-javascript)
* [使用 REST API 和 Ruby 编写脚本](/zh/enterprise-server@3.21/rest/guides/scripting-with-the-rest-api-and-ruby)
* [构建响应 Webhook 事件的GitHub应用](/zh/enterprise-server@3.21/apps/creating-github-apps/writing-code-for-a-github-app/building-a-github-app-that-responds-to-webhook-events)
* [使用 GitHub 应用生成 CLI](/zh/enterprise-server@3.21/apps/creating-github-apps/writing-code-for-a-github-app/building-a-cli-with-a-github-app)
* [自动重新传送存储库 Webhook 的失败交付](/zh/enterprise-server@3.21/webhooks/using-webhooks/automatically-redelivering-failed-deliveries-for-a-repository-webhook)

有关便于使用 REST API 编写脚本的库列表，请参阅 [REST API 的库](/zh/enterprise-server@3.21/rest/overview/libraries-for-the-rest-api)。

如果要生成使用 REST API 的脚本或应用程序，你可能还有意使用 Webhook 获取有关事件或 GitHub App 的通知，以便代表用户或在组织中访问资源。 有关详细信息，请参阅 [关于 网络钩子](/zh/enterprise-server@3.21/webhooks/about-webhooks) 和 [决定何时生成GitHub应用](/zh/enterprise-server@3.21/apps/creating-github-apps/about-creating-github-apps/deciding-when-to-build-a-github-app)。

## 其他阅读材料

* [比较GitHub的 REST API 和 GraphQL API](/zh/enterprise-server@3.21/rest/overview/comparing-githubs-rest-api-and-graphql-api)
* [使用 REST API 的最佳做法](/zh/enterprise-server@3.21/rest/guides/best-practices-for-using-the-rest-api)
* [确保 API 凭据安全](/zh/enterprise-server@3.21/rest/overview/keeping-your-api-credentials-secure)
* [REST API 故障排除](/zh/enterprise-server@3.21/rest/overview/troubleshooting-the-rest-api)