diff --git a/package-lock.json b/package-lock.json index 8ba8180..f44d09f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "version": "0.0.0-semantically-released", "license": "SEE LICENSE IN LICENSE", "dependencies": { - "@octokit/openapi-types-ghec": "^14.0.0", + "@octokit/openapi-types-ghec": "^18.0.0", "ajv": "^8.11.0", "express": "^4.18.1", "fast-glob": "^3.2.12", @@ -30,7 +30,7 @@ "@vercel/ncc": "^0.34.0", "axios": "^0.27.2", "eslint": "^8.32.0", - "github-openapi-graphql-query": "^2.1.2", + "github-openapi-graphql-query": "^4.1.0", "husky": "^8.0.3", "jest": "^28.1.1", "jest-sonar-reporter": "^2.0.0", @@ -803,63 +803,83 @@ "dev": true }, "node_modules/@graphql-tools/merge": { - "version": "8.3.12", - "resolved": "https://registry.npmjs.org/@graphql-tools/merge/-/merge-8.3.12.tgz", - "integrity": "sha512-BFL8r4+FrqecPnIW0H8UJCBRQ4Y8Ep60aujw9c/sQuFmQTiqgWgpphswMGfaosP2zUinDE3ojU5wwcS2IJnumA==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/@graphql-tools/merge/-/merge-9.0.0.tgz", + "integrity": "sha512-J7/xqjkGTTwOJmaJQJ2C+VDBDOWJL3lKrHJN4yMaRLAJH3PosB7GiPRaSDZdErs0+F77sH2MKs2haMMkywzx7Q==", "dev": true, "dependencies": { - "@graphql-tools/utils": "9.1.1", + "@graphql-tools/utils": "^10.0.0", "tslib": "^2.4.0" }, + "engines": { + "node": ">=16.0.0" + }, "peerDependencies": { "graphql": "^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0" } }, "node_modules/@graphql-tools/merge/node_modules/tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true }, "node_modules/@graphql-tools/schema": { - "version": "9.0.10", - "resolved": "https://registry.npmjs.org/@graphql-tools/schema/-/schema-9.0.10.tgz", - "integrity": "sha512-lV0o4df9SpPiaeeDAzgdCJ2o2N9Wvsp0SMHlF2qDbh9aFCFQRsXuksgiDm2yTgT3TG5OtUes/t0D6uPjPZFUbQ==", + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/@graphql-tools/schema/-/schema-10.0.0.tgz", + "integrity": "sha512-kf3qOXMFcMs2f/S8Y3A8fm/2w+GaHAkfr3Gnhh2LOug/JgpY/ywgFVxO3jOeSpSEdoYcDKLcXVjMigNbY4AdQg==", "dev": true, "dependencies": { - "@graphql-tools/merge": "8.3.12", - "@graphql-tools/utils": "9.1.1", + "@graphql-tools/merge": "^9.0.0", + "@graphql-tools/utils": "^10.0.0", "tslib": "^2.4.0", - "value-or-promise": "1.0.11" + "value-or-promise": "^1.0.12" + }, + "engines": { + "node": ">=16.0.0" }, "peerDependencies": { "graphql": "^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0" } }, "node_modules/@graphql-tools/schema/node_modules/tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true }, "node_modules/@graphql-tools/utils": { - "version": "9.1.1", - "resolved": "https://registry.npmjs.org/@graphql-tools/utils/-/utils-9.1.1.tgz", - "integrity": "sha512-DXKLIEDbihK24fktR2hwp/BNIVwULIHaSTNTNhXS+19vgT50eX9wndx1bPxGwHnVBOONcwjXy0roQac49vdt/w==", + "version": "10.0.4", + "resolved": "https://registry.npmjs.org/@graphql-tools/utils/-/utils-10.0.4.tgz", + "integrity": "sha512-MF+nZgGROSnFgyOYWhrl2PuJMlIBvaCH48vtnlnDQKSeDc2fUfOzUVloBAQvnYmK9JBmHHks4Pxv25Ybg3r45Q==", "dev": true, "dependencies": { + "@graphql-typed-document-node/core": "^3.1.1", + "dset": "^3.1.2", "tslib": "^2.4.0" }, + "engines": { + "node": ">=16.0.0" + }, "peerDependencies": { "graphql": "^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0" } }, "node_modules/@graphql-tools/utils/node_modules/tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true }, + "node_modules/@graphql-typed-document-node/core": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@graphql-typed-document-node/core/-/core-3.2.0.tgz", + "integrity": "sha512-mB9oAsNCm9aM3/SOv4YtBMqZbYj10R7dkq8byBqxGY/ncFwhf2oQzMV+LCRlWoDSEBJ3COiR1yeDvMtsoOsuFQ==", + "dev": true, + "peerDependencies": { + "graphql": "^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0" + } + }, "node_modules/@humanwhocodes/config-array": { "version": "0.11.8", "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", @@ -1481,9 +1501,9 @@ "dev": true }, "node_modules/@octokit/openapi-types-ghec": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/@octokit/openapi-types-ghec/-/openapi-types-ghec-14.0.0.tgz", - "integrity": "sha512-xhd9oEvn2aroGn+sk09Ptx/76Y7aKU0EIgHukHPCU1+rGJreO36baEEk6k8ZPblieHNM39FcykJQmtDrETm0KA==" + "version": "18.0.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types-ghec/-/openapi-types-ghec-18.0.0.tgz", + "integrity": "sha512-xY5FTR/DW2gUJdC5GyzkqrfMHhr3u3hg+dUG6bA5FvuuODw6A7+0JTTSS1ndLQEKGmFxP7chf1BKkhvhnqxCew==" }, "node_modules/@octokit/plugin-paginate-rest": { "version": "5.0.1", @@ -3800,6 +3820,15 @@ "node": ">=8" } }, + "node_modules/dset": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/dset/-/dset-3.1.2.tgz", + "integrity": "sha512-g/M9sqy3oHe477Ar4voQxWtaPIFw1jTdKZuomOjhCcBx9nHUNn0pu6NopuFFrTh/TRZIKEj+76vLWFu9BNKk+Q==", + "dev": true, + "engines": { + "node": ">=4" + } + }, "node_modules/duplexer2": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", @@ -4761,12 +4790,12 @@ } }, "node_modules/github-openapi-graphql-query": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/github-openapi-graphql-query/-/github-openapi-graphql-query-2.3.1.tgz", - "integrity": "sha512-bdnRXilCNJoC8/v38uhk65jT0hYwOeT1Q/Y598HTS8g6z74+3yblVceVAEQNoDp/arRI99KUekMwGDgrZ6GdXQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/github-openapi-graphql-query/-/github-openapi-graphql-query-4.1.0.tgz", + "integrity": "sha512-j/HZzIcXub25Yf1kt5t2fy9bGKf004QMiU2JDKQMgAyUmV2ILKCR9AxejqPdCRrqSVo530bRQIFW5gfZoqKV1A==", "dev": true, "dependencies": { - "@graphql-tools/schema": "^9.0.2", + "@graphql-tools/schema": "^10.0.0", "got": "^11.8.5", "graphql": "^16.0.0", "lodash": "^4.17.21", @@ -4876,9 +4905,9 @@ "dev": true }, "node_modules/graphql": { - "version": "16.6.0", - "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.6.0.tgz", - "integrity": "sha512-KPIBPDlW7NxrbT/eh4qPXz5FiFdL5UbaA0XUNz2Rp3Z3hqBSkbj0GVjwFDztsWVauZUWsbKHgMg++sk8UX0bkw==", + "version": "16.7.1", + "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.7.1.tgz", + "integrity": "sha512-DRYR9tf+UGU0KOsMcKAlXeFfX89UiiIZ0dRU3mR0yJfu6OjZqUcp68NnFLnqQU5RexygFoDy1EW+ccOYcPfmHg==", "dev": true, "engines": { "node": "^12.22.0 || ^14.16.0 || ^16.0.0 || >=17.0.0" @@ -12657,9 +12686,9 @@ } }, "node_modules/value-or-promise": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/value-or-promise/-/value-or-promise-1.0.11.tgz", - "integrity": "sha512-41BrgH+dIbCFXClcSapVs5M6GkENd3gQOJpEfPDNa71LsUGMXDL0jMWpI/Rh7WhX+Aalfz2TTS3Zt5pUsbnhLg==", + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/value-or-promise/-/value-or-promise-1.0.12.tgz", + "integrity": "sha512-Z6Uz+TYwEqE7ZN50gwn+1LCVo9ZVrpxRPOhOLnncYkY1ZzOYtrX8Fwf/rFktZ8R5mJms6EZf5TqNOMeZmnPq9Q==", "dev": true, "engines": { "node": ">=12" @@ -13454,60 +13483,69 @@ } }, "@graphql-tools/merge": { - "version": "8.3.12", - "resolved": "https://registry.npmjs.org/@graphql-tools/merge/-/merge-8.3.12.tgz", - "integrity": "sha512-BFL8r4+FrqecPnIW0H8UJCBRQ4Y8Ep60aujw9c/sQuFmQTiqgWgpphswMGfaosP2zUinDE3ojU5wwcS2IJnumA==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/@graphql-tools/merge/-/merge-9.0.0.tgz", + "integrity": "sha512-J7/xqjkGTTwOJmaJQJ2C+VDBDOWJL3lKrHJN4yMaRLAJH3PosB7GiPRaSDZdErs0+F77sH2MKs2haMMkywzx7Q==", "dev": true, "requires": { - "@graphql-tools/utils": "9.1.1", + "@graphql-tools/utils": "^10.0.0", "tslib": "^2.4.0" }, "dependencies": { "tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true } } }, "@graphql-tools/schema": { - "version": "9.0.10", - "resolved": "https://registry.npmjs.org/@graphql-tools/schema/-/schema-9.0.10.tgz", - "integrity": "sha512-lV0o4df9SpPiaeeDAzgdCJ2o2N9Wvsp0SMHlF2qDbh9aFCFQRsXuksgiDm2yTgT3TG5OtUes/t0D6uPjPZFUbQ==", + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/@graphql-tools/schema/-/schema-10.0.0.tgz", + "integrity": "sha512-kf3qOXMFcMs2f/S8Y3A8fm/2w+GaHAkfr3Gnhh2LOug/JgpY/ywgFVxO3jOeSpSEdoYcDKLcXVjMigNbY4AdQg==", "dev": true, "requires": { - "@graphql-tools/merge": "8.3.12", - "@graphql-tools/utils": "9.1.1", + "@graphql-tools/merge": "^9.0.0", + "@graphql-tools/utils": "^10.0.0", "tslib": "^2.4.0", - "value-or-promise": "1.0.11" + "value-or-promise": "^1.0.12" }, "dependencies": { "tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true } } }, "@graphql-tools/utils": { - "version": "9.1.1", - "resolved": "https://registry.npmjs.org/@graphql-tools/utils/-/utils-9.1.1.tgz", - "integrity": "sha512-DXKLIEDbihK24fktR2hwp/BNIVwULIHaSTNTNhXS+19vgT50eX9wndx1bPxGwHnVBOONcwjXy0roQac49vdt/w==", + "version": "10.0.4", + "resolved": "https://registry.npmjs.org/@graphql-tools/utils/-/utils-10.0.4.tgz", + "integrity": "sha512-MF+nZgGROSnFgyOYWhrl2PuJMlIBvaCH48vtnlnDQKSeDc2fUfOzUVloBAQvnYmK9JBmHHks4Pxv25Ybg3r45Q==", "dev": true, "requires": { + "@graphql-typed-document-node/core": "^3.1.1", + "dset": "^3.1.2", "tslib": "^2.4.0" }, "dependencies": { "tslib": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", - "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==", + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.1.tgz", + "integrity": "sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig==", "dev": true } } }, + "@graphql-typed-document-node/core": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@graphql-typed-document-node/core/-/core-3.2.0.tgz", + "integrity": "sha512-mB9oAsNCm9aM3/SOv4YtBMqZbYj10R7dkq8byBqxGY/ncFwhf2oQzMV+LCRlWoDSEBJ3COiR1yeDvMtsoOsuFQ==", + "dev": true, + "requires": {} + }, "@humanwhocodes/config-array": { "version": "0.11.8", "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", @@ -13994,9 +14032,9 @@ "dev": true }, "@octokit/openapi-types-ghec": { - "version": "14.0.0", - "resolved": "https://registry.npmjs.org/@octokit/openapi-types-ghec/-/openapi-types-ghec-14.0.0.tgz", - "integrity": "sha512-xhd9oEvn2aroGn+sk09Ptx/76Y7aKU0EIgHukHPCU1+rGJreO36baEEk6k8ZPblieHNM39FcykJQmtDrETm0KA==" + "version": "18.0.0", + "resolved": "https://registry.npmjs.org/@octokit/openapi-types-ghec/-/openapi-types-ghec-18.0.0.tgz", + "integrity": "sha512-xY5FTR/DW2gUJdC5GyzkqrfMHhr3u3hg+dUG6bA5FvuuODw6A7+0JTTSS1ndLQEKGmFxP7chf1BKkhvhnqxCew==" }, "@octokit/plugin-paginate-rest": { "version": "5.0.1", @@ -15752,6 +15790,12 @@ "is-obj": "^2.0.0" } }, + "dset": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/dset/-/dset-3.1.2.tgz", + "integrity": "sha512-g/M9sqy3oHe477Ar4voQxWtaPIFw1jTdKZuomOjhCcBx9nHUNn0pu6NopuFFrTh/TRZIKEj+76vLWFu9BNKk+Q==", + "dev": true + }, "duplexer2": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", @@ -16473,12 +16517,12 @@ } }, "github-openapi-graphql-query": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/github-openapi-graphql-query/-/github-openapi-graphql-query-2.3.1.tgz", - "integrity": "sha512-bdnRXilCNJoC8/v38uhk65jT0hYwOeT1Q/Y598HTS8g6z74+3yblVceVAEQNoDp/arRI99KUekMwGDgrZ6GdXQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/github-openapi-graphql-query/-/github-openapi-graphql-query-4.1.0.tgz", + "integrity": "sha512-j/HZzIcXub25Yf1kt5t2fy9bGKf004QMiU2JDKQMgAyUmV2ILKCR9AxejqPdCRrqSVo530bRQIFW5gfZoqKV1A==", "dev": true, "requires": { - "@graphql-tools/schema": "^9.0.2", + "@graphql-tools/schema": "^10.0.0", "got": "^11.8.5", "graphql": "^16.0.0", "lodash": "^4.17.21", @@ -16561,9 +16605,9 @@ "dev": true }, "graphql": { - "version": "16.6.0", - "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.6.0.tgz", - "integrity": "sha512-KPIBPDlW7NxrbT/eh4qPXz5FiFdL5UbaA0XUNz2Rp3Z3hqBSkbj0GVjwFDztsWVauZUWsbKHgMg++sk8UX0bkw==", + "version": "16.7.1", + "resolved": "https://registry.npmjs.org/graphql/-/graphql-16.7.1.tgz", + "integrity": "sha512-DRYR9tf+UGU0KOsMcKAlXeFfX89UiiIZ0dRU3mR0yJfu6OjZqUcp68NnFLnqQU5RexygFoDy1EW+ccOYcPfmHg==", "dev": true }, "handlebars": { @@ -22143,9 +22187,9 @@ } }, "value-or-promise": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/value-or-promise/-/value-or-promise-1.0.11.tgz", - "integrity": "sha512-41BrgH+dIbCFXClcSapVs5M6GkENd3gQOJpEfPDNa71LsUGMXDL0jMWpI/Rh7WhX+Aalfz2TTS3Zt5pUsbnhLg==", + "version": "1.0.12", + "resolved": "https://registry.npmjs.org/value-or-promise/-/value-or-promise-1.0.12.tgz", + "integrity": "sha512-Z6Uz+TYwEqE7ZN50gwn+1LCVo9ZVrpxRPOhOLnncYkY1ZzOYtrX8Fwf/rFktZ8R5mJms6EZf5TqNOMeZmnPq9Q==", "dev": true }, "vary": { diff --git a/package.json b/package.json index 8e37d68..700d100 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "@vercel/ncc": "^0.34.0", "axios": "^0.27.2", "eslint": "^8.32.0", - "github-openapi-graphql-query": "^2.1.2", + "github-openapi-graphql-query": "^4.1.0", "husky": "^8.0.3", "jest": "^28.1.1", "jest-sonar-reporter": "^2.0.0", @@ -63,7 +63,7 @@ "typescript": "^4.7.4" }, "dependencies": { - "@octokit/openapi-types-ghec": "^14.0.0", + "@octokit/openapi-types-ghec": "^18.0.0", "ajv": "^8.11.0", "express": "^4.18.1", "fast-glob": "^3.2.12", diff --git a/scripts/api-spec.js b/scripts/api-spec.js index 34d9141..c6a256f 100644 --- a/scripts/api-spec.js +++ b/scripts/api-spec.js @@ -11,7 +11,7 @@ const version = process.env.VERSION.replace(/^v/, ""); const QUERY = ` query ($version: String!, $ignoreChangesBefore: String!) { - endpoints(version: $version, ignoreChangesBefore: $ignoreChangesBefore, filter: { isGithubCloudOnly: false }) { + endpoints(version: $version, ignoreChangesBefore: $ignoreChangesBefore, ghecCompatibilityMode: true, filter: { isGithubCloudOnly: false }) { name scope(format: CAMELCASE) id(format: CAMELCASE) diff --git a/scripts/generated/endpoints.json b/scripts/generated/endpoints.json index 30ff069..49afca3 100644 --- a/scripts/generated/endpoints.json +++ b/scripts/generated/endpoints.json @@ -88,7 +88,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -200,6 +200,126 @@ ], "renamed": null }, + { + "name": "Add selected repository to an organization variable", + "scope": "actions", + "id": "addSelectedRepoToOrgVariable", + "method": "PUT", + "url": "/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a repository to an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their `visibility` field set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#add-selected-repository-to-an-organization-variable", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the variable.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { + "code": 409, + "description": "Response when the visibility of the variable is not set to `selected`" + } + ], + "renamed": null + }, + { + "name": "Add a repository to a required workflow", + "scope": "actions", + "id": "addSelectedRepoToRequiredWorkflow", + "method": "PUT", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a repository to a required workflow. To use this endpoint, the required workflow must be configured to run on selected repositories.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#add-a-repository-to-selected-repositories-list-for-a-required-workflow", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Success" }, + { "code": 404, "description": "Resource Not Found" }, + { "code": 422, "description": "Validation Error" } + ], + "renamed": null + }, { "name": "Approve a workflow run for a fork pull request", "scope": "actions", @@ -227,7 +347,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -286,7 +406,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -317,6 +437,74 @@ ], "renamed": null }, + { + "name": "Create an environment variable", + "scope": "actions", + "id": "createEnvironmentVariable", + "method": "POST", + "url": "/repositories/{repository_id}/environments/{environment_name}/variables", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Create an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `environment:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#create-an-environment-variable", + "parameters": [ + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "value", + "description": "The value of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 201, "description": "Response" }], + "renamed": null + }, { "name": "Create or update an environment secret", "scope": "actions", @@ -326,7 +514,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates an environment secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use\nthis endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "description": "Creates or updates an environment secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use\nthis endpoint.\n\n**Example encrypting a secret using Node.js**\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n**Example encrypting a secret using Python**\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n**Example encrypting a secret using C#**\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n**Example encrypting a secret using Ruby**\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-an-environment-secret", "parameters": [ { @@ -507,7 +695,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use\nthis endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use\nthis endpoint.\n\n**Example encrypting a secret using Node.js**\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n**Example encrypting a secret using Python**\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n**Example encrypting a secret using C#**\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n**Example encrypting a secret using Ruby**\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-a-repository-secret", "parameters": [ { @@ -525,7 +713,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -582,6 +770,89 @@ ], "renamed": null }, + { + "name": "Create an organization variable", + "scope": "actions", + "id": "createOrgVariable", + "method": "POST", + "url": "/orgs/{org}/actions/variables", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\nGitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#create-an-organization-variable", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "value", + "description": "The value of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "visibility", + "description": "The type of repositories in the organization that can access the variable. `selected` means only the repositories specified by `selected_repository_ids` can access the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["all", "private", "selected"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization variable. You can only provide a list of repository ids when the `visibility` is set to `selected`.", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response when creating a variable" } + ], + "renamed": null + }, { "name": "Create a registration token for an organization", "scope": "actions", @@ -638,7 +909,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -709,7 +980,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -724,6 +995,161 @@ "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, + { + "name": "Create a repository variable", + "scope": "actions", + "id": "createRepoVariable", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/variables", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `actions_variables:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#create-a-repository-variable", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "value", + "description": "The value of the variable.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 201, "description": "Response" }], + "renamed": null + }, + { + "name": "Create a required workflow", + "scope": "actions", + "id": "createRequiredWorkflow", + "method": "POST", + "url": "/orgs/{org}/actions/required_workflows", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Create a required workflow in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-a-required-workflow", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "workflow_file_path", + "description": "Path of the workflow file to be configured as a required workflow.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The ID of the repository that contains the workflow file.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "scope", + "description": "Enable the required workflow for all repositories or selected repositories in the organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["selected", "all"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "selected_repository_ids", + "description": "A list of repository IDs where you want to enable the required workflow. You can only provide a list of repository ids when the `scope` is set to `selected`.", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, { "name": "Create a workflow dispatch event", "scope": "actions", @@ -733,7 +1159,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You can use this endpoint to manually trigger a GitHub Actions workflow run. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must configure your GitHub Actions workflow to run when the [`workflow_dispatch` webhook](/developers/webhooks-and-events/webhook-events-and-payloads#workflow_dispatch) event occurs. The `inputs` are configured in the workflow file. For more information about how to configure the `workflow_dispatch` event in the workflow file, see \"[Events that trigger workflows](/actions/reference/events-that-trigger-workflows#workflow_dispatch).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint. For more information, see \"[Creating a personal access token for the command line](https://docs.github.com/articles/creating-a-personal-access-token-for-the-command-line).\"", + "description": "You can use this endpoint to manually trigger a GitHub Actions workflow run. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must configure your GitHub Actions workflow to run when the [`workflow_dispatch` webhook](/developers/webhooks-and-events/webhook-events-and-payloads#workflow_dispatch) event occurs. The `inputs` are configured in the workflow file. For more information about how to configure the `workflow_dispatch` event in the workflow file, see \"[Events that trigger workflows](/actions/reference/events-that-trigger-workflows#workflow_dispatch).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint. For more information, see \"[Creating a personal access token for the command line](https://docs.github.com/enterprise-cloud@latest//articles/creating-a-personal-access-token-for-the-command-line).\"", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-a-workflow-dispatch-event", "parameters": [ { @@ -751,7 +1177,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -845,7 +1271,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -900,7 +1326,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -926,7 +1352,7 @@ }, { "name": "ref", - "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", + "description": "The full Git reference for narrowing down the cache. The `ref` for a branch should be formatted as `refs/heads/`. To reference a pull request use `refs/pull//merge`.", "in": "QUERY", "type": "string", "required": false, @@ -968,7 +1394,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1052,64 +1478,22 @@ "renamed": null }, { - "name": "Delete an organization secret", - "scope": "actions", - "id": "deleteOrgSecret", - "method": "DELETE", - "url": "/orgs/{org}/actions/secrets/{secret_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Deletes a secret in an organization using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-an-organization-secret", - "parameters": [ - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete a repository secret", + "name": "Delete an environment variable", "scope": "actions", - "id": "deleteRepoSecret", + "id": "deleteEnvironmentVariable", "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/secrets/{secret_name}", + "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-repository-secret", + "description": "Deletes an environment variable using the variable name.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `environment:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#delete-an-environment-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -1119,8 +1503,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", "type": "string", "required": true, @@ -1132,8 +1516,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -1149,16 +1533,16 @@ "renamed": null }, { - "name": "Delete a self-hosted runner from an organization", + "name": "Delete an organization secret", "scope": "actions", - "id": "deleteSelfHostedRunnerFromOrg", + "id": "deleteOrgSecret", "method": "DELETE", - "url": "/orgs/{org}/actions/runners/{runner_id}", + "url": "/orgs/{org}/actions/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-self-hosted-runner-from-an-organization", + "description": "Deletes a secret in an organization using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-an-organization-secret", "parameters": [ { "name": "org", @@ -1174,10 +1558,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -1191,20 +1575,20 @@ "renamed": null }, { - "name": "Delete a self-hosted runner from a repository", + "name": "Delete an organization variable", "scope": "actions", - "id": "deleteSelfHostedRunnerFromRepo", + "id": "deleteOrgVariable", "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}", + "url": "/orgs/{org}/actions/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.\n\nYou must authenticate using an access token with the `repo`\nscope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-self-hosted-runner-from-a-repository", + "description": "Deletes an organization variable using the variable name.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\nGitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#delete-an-organization-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1216,8 +1600,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", "type": "string", "required": true, @@ -1227,35 +1611,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete a workflow run", + "name": "Delete a repository secret", "scope": "actions", - "id": "deleteWorkflowRun", + "id": "deleteRepoSecret", "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}", + "url": "/repos/{owner}/{repo}/actions/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Delete a specific workflow run. Anyone with write access to the repository can use this endpoint. If the repository is\nprivate you must use an access token with the `repo` scope. GitHub Apps must have the `actions:write` permission to use\nthis endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-workflow-run", + "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-repository-secret", "parameters": [ { "name": "owner", @@ -1272,7 +1643,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1284,10 +1655,10 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -1301,16 +1672,16 @@ "renamed": null }, { - "name": "Delete workflow run logs", + "name": "Delete a repository variable", "scope": "actions", - "id": "deleteWorkflowRunLogs", + "id": "deleteRepoVariable", "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/logs", + "url": "/repos/{owner}/{repo}/actions/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes all logs for a workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-workflow-run-logs", + "description": "Deletes a repository variable using the variable name.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `actions_variables:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#delete-a-repository-variable", "parameters": [ { "name": "owner", @@ -1327,7 +1698,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1339,10 +1710,10 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -1352,24 +1723,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 500, "description": "Internal Error" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Disable a selected repository for GitHub Actions in an organization", + "name": "Delete a required workflow", "scope": "actions", - "id": "disableSelectedRepositoryGithubActionsOrganization", + "id": "deleteRequiredWorkflow", "method": "DELETE", - "url": "/orgs/{org}/actions/permissions/repositories/{repository_id}", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes a repository from the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#disable-a-selected-repository-for-github-actions-in-an-organization", + "description": "Deletes a required workflow configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-required-workflow", "parameters": [ { "name": "org", @@ -1385,8 +1752,8 @@ "deprecated": null }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", "in": "PATH", "type": "integer", "required": true, @@ -1402,88 +1769,20 @@ "renamed": null }, { - "name": "Disable a workflow", - "scope": "actions", - "id": "disableWorkflow", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/disable", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Disables a workflow and sets the `state` of the workflow to `disabled_manually`. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#disable-a-workflow", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "workflow_id", - "description": "The ID of the workflow. You can also pass the workflow file name as a string.", - "in": "PATH", - "type": null, - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Download an artifact", + "name": "Delete a self-hosted runner from an organization", "scope": "actions", - "id": "downloadArtifact", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/artifacts/{artifact_id}/{archive_format}", + "id": "deleteSelfHostedRunnerFromOrg", + "method": "DELETE", + "url": "/orgs/{org}/actions/runners/{runner_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for `Location:` in\nthe response header to find the URL for the download. The `:archive_format` must be `zip`. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-an-artifact", + "description": "Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-self-hosted-runner-from-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1495,8 +1794,8 @@ "deprecated": null }, { - "name": "artifact_id", - "description": "The unique identifier of the artifact.", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", "in": "PATH", "type": "integer", "required": true, @@ -1506,38 +1805,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "archive_format", - "description": "", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [ - { "code": 302, "description": "Response" }, - { "code": 410, "description": "Gone" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Download job logs for a workflow run", + "name": "Delete a self-hosted runner from a repository", "scope": "actions", - "id": "downloadJobLogsForWorkflowRun", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}/logs", + "id": "deleteSelfHostedRunnerFromRepo", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download a plain text file of logs for a workflow job. This link expires after 1 minute. Look\nfor `Location:` in the response header to find the URL for the download. Anyone with read access to the repository can\nuse this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must\nhave the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-job-logs-for-a-workflow-run", + "description": "Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.\n\nYou must authenticate using an access token with the `repo`\nscope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-self-hosted-runner-from-a-repository", "parameters": [ { "name": "owner", @@ -1554,7 +1837,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1566,8 +1849,8 @@ "deprecated": null }, { - "name": "job_id", - "description": "The unique identifier of the job.", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", "in": "PATH", "type": "integer", "required": true, @@ -1579,20 +1862,20 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Download workflow run attempt logs", + "name": "Delete a workflow run", "scope": "actions", - "id": "downloadWorkflowRunAttemptLogs", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/logs", + "id": "deleteWorkflowRun", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download an archive of log files for a specific workflow run attempt. This link expires after\n1 minute. Look for `Location:` in the response header to find the URL for the download. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-workflow-run-attempt-logs", + "description": "Delete a specific workflow run. Anyone with write access to the repository can use this endpoint. If the repository is\nprivate you must use an access token with the `repo` scope. GitHub Apps must have the `actions:write` permission to use\nthis endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-a-workflow-run", "parameters": [ { "name": "owner", @@ -1609,7 +1892,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1632,35 +1915,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "attempt_number", - "description": "The attempt number of the workflow run.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Download workflow run logs", + "name": "Delete workflow run logs", "scope": "actions", - "id": "downloadWorkflowRunLogs", - "method": "GET", + "id": "deleteWorkflowRunLogs", + "method": "DELETE", "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/logs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download an archive of log files for a workflow run. This link expires after 1 minute. Look for\n`Location:` in the response header to find the URL for the download. Anyone with read access to the repository can use\nthis endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have\nthe `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-workflow-run-logs", + "description": "Deletes all logs for a workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#delete-workflow-run-logs", "parameters": [ { "name": "owner", @@ -1677,7 +1947,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1702,20 +1972,24 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { - "name": "Enable a selected repository for GitHub Actions in an organization", + "name": "Disable a selected repository for GitHub Actions in an organization", "scope": "actions", - "id": "enableSelectedRepositoryGithubActionsOrganization", - "method": "PUT", + "id": "disableSelectedRepositoryGithubActionsOrganization", + "method": "DELETE", "url": "/orgs/{org}/actions/permissions/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Adds a repository to the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#enable-a-selected-repository-for-github-actions-in-an-organization", + "description": "Removes a repository from the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#disable-a-selected-repository-for-github-actions-in-an-organization", "parameters": [ { "name": "org", @@ -1748,16 +2022,16 @@ "renamed": null }, { - "name": "Enable a workflow", + "name": "Disable a workflow", "scope": "actions", - "id": "enableWorkflow", + "id": "disableWorkflow", "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/enable", + "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/disable", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables a workflow and sets the `state` of the workflow to `active`. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#enable-a-workflow", + "description": "Disables a workflow and sets the `state` of the workflow to `disabled_manually`. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#disable-a-workflow", "parameters": [ { "name": "owner", @@ -1774,7 +2048,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1803,16 +2077,16 @@ "renamed": null }, { - "name": "List GitHub Actions caches for a repository", + "name": "Download an artifact", "scope": "actions", - "id": "getActionsCacheList", + "id": "downloadArtifact", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/caches", + "url": "/repos/{owner}/{repo}/actions/artifacts/{artifact_id}/{archive_format}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the GitHub Actions caches for a repository.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/cache#list-github-actions-caches-for-a-repository", + "description": "Gets a redirect URL to download an archive for a repository. This URL expires after 1 minute. Look for `Location:` in\nthe response header to find the URL for the download. The `:archive_format` must be `zip`. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-an-artifact", "parameters": [ { "name": "owner", @@ -1829,7 +2103,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1841,24 +2115,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "artifact_id", + "description": "The unique identifier of the artifact.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -1867,24 +2128,43 @@ "deprecated": null }, { - "name": "ref", - "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", - "in": "QUERY", + "name": "archive_format", + "description": "", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 302, "description": "Response" }, + { "code": 410, "description": "Gone" } + ], + "renamed": null + }, + { + "name": "Download job logs for a workflow run", + "scope": "actions", + "id": "downloadJobLogsForWorkflowRun", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}/logs", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a redirect URL to download a plain text file of logs for a workflow job. This link expires after 1 minute. Look\nfor `Location:` in the response header to find the URL for the download. Anyone with read access to the repository can\nuse this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must\nhave the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-job-logs-for-a-workflow-run", + "parameters": [ { - "name": "key", - "description": "An explicit key or prefix for identifying the cache", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -1893,12 +2173,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created_at` means when the cache was created. `last_accessed_at` means when the cache was last accessed. `size_in_bytes` is the size of the cache in bytes.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created_at", "last_accessed_at", "size_in_bytes"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -1906,12 +2186,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], + "name": "job_id", + "description": "The unique identifier of the job.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -1919,20 +2199,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 302, "description": "Response" }], "renamed": null }, { - "name": "Get GitHub Actions cache usage for a repository", + "name": "Download workflow run attempt logs", "scope": "actions", - "id": "getActionsCacheUsage", + "id": "downloadWorkflowRunAttemptLogs", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/cache/usage", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/logs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets GitHub Actions cache usage for a repository.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-cache-usage-for-a-repository", + "description": "Gets a redirect URL to download an archive of log files for a specific workflow run attempt. This link expires after\n1 minute. Look for `Location:` in the response header to find the URL for the download. Anyone with read access to\nthe repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-workflow-run-attempt-logs", "parameters": [ { "name": "owner", @@ -1949,36 +2229,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List repositories with GitHub Actions cache usage for an organization", - "scope": "actions", - "id": "getActionsCacheUsageByRepoForOrg", - "method": "GET", - "url": "/orgs/{org}/actions/cache/usage-by-repository", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists repositories and their GitHub Actions cache usage for an organization.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nYou must authenticate using an access token with the `read:org` scope to use this endpoint. GitHub Apps must have the `organization_admistration:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repositories-with-github-actions-cache-usage-for-an-organization", - "parameters": [ - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -1990,11 +2241,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -2003,11 +2254,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "attempt_number", + "description": "The attempt number of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -2016,24 +2267,24 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 302, "description": "Response" }], "renamed": null }, { - "name": "Get GitHub Actions cache usage for an enterprise", + "name": "Download workflow run logs", "scope": "actions", - "id": "getActionsCacheUsageForEnterprise", + "id": "downloadWorkflowRunLogs", "method": "GET", - "url": "/enterprises/{enterprise}/actions/cache/usage", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/logs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the total GitHub Actions cache usage for an enterprise.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-cache-usage-for-an-enterprise", + "description": "Gets a redirect URL to download an archive of log files for a workflow run. This link expires after 1 minute. Look for\n`Location:` in the response header to find the URL for the download. Anyone with read access to the repository can use\nthis endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have\nthe `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#download-workflow-run-logs", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2043,26 +2294,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get GitHub Actions cache usage for an organization", - "scope": "actions", - "id": "getActionsCacheUsageForOrg", - "method": "GET", - "url": "/orgs/{org}/actions/cache/usage", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the total GitHub Actions cache usage for an organization.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nYou must authenticate using an access token with the `read:org` scope to use this endpoint. GitHub Apps must have the `organization_admistration:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-cache-usage-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2072,28 +2307,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get allowed actions and reusable workflows for an organization", - "scope": "actions", - "id": "getAllowedActionsOrganization", - "method": "GET", - "url": "/orgs/{org}/actions/permissions/selected-actions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the selected actions and reusable workflows that are allowed in an organization. To use this endpoint, the organization permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-allowed-actions-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "run_id", + "description": "The unique identifier of the workflow run.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2103,24 +2322,24 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 302, "description": "Response" }], "renamed": null }, { - "name": "Get allowed actions and reusable workflows for a repository", + "name": "Enable a selected repository for GitHub Actions in an organization", "scope": "actions", - "id": "getAllowedActionsRepository", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/permissions/selected-actions", + "id": "enableSelectedRepositoryGithubActionsOrganization", + "method": "PUT", + "url": "/orgs/{org}/actions/permissions/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the settings for selected actions and reusable workflows that are allowed in a repository. To use this endpoint, the repository policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for a repository](#set-github-actions-permissions-for-a-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-allowed-actions-for-a-repository", + "description": "Adds a repository to the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#enable-a-selected-repository-for-github-actions-in-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2132,10 +2351,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2145,20 +2364,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get an artifact", + "name": "Enable a workflow", "scope": "actions", - "id": "getArtifact", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/artifacts/{artifact_id}", + "id": "enableWorkflow", + "method": "PUT", + "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/enable", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific artifact for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-artifact", + "description": "Enables a workflow and sets the `state` of the workflow to `active`. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#enable-a-workflow", "parameters": [ { "name": "owner", @@ -2175,7 +2394,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2187,10 +2406,10 @@ "deprecated": null }, { - "name": "artifact_id", - "description": "The unique identifier of the artifact.", + "name": "workflow_id", + "description": "The ID of the workflow. You can also pass the workflow file name as a string.", "in": "PATH", - "type": "integer", + "type": null, "required": true, "enum": null, "allowNull": false, @@ -2200,26 +2419,26 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get an environment public key", + "name": "Create configuration for a just-in-time runner for an Enterprise", "scope": "actions", - "id": "getEnvironmentPublicKey", - "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/public-key", + "id": "generateRunnerJitconfigForEnterprise", + "method": "POST", + "url": "/enterprises/{enterprise}/actions/runners/generate-jitconfig", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-environment-public-key", + "description": "Generates a configuration that can be passed to the runner application at startup.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/self-hosted-runners#create-configuration-for-a-just-in-time-runner-for-an-enterprise", "parameters": [ { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "enterprise", + "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -2229,9 +2448,9 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", - "in": "PATH", + "name": "name", + "description": "The name of the new runner.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -2240,27 +2459,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get an environment secret", - "scope": "actions", - "id": "getEnvironmentSecret", - "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-environment-secret", - "parameters": [ + }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", - "in": "PATH", + "name": "runner_group_id", + "description": "The ID of the runner group to register the runner to.", + "in": "BODY", "type": "integer", "required": true, "enum": null, @@ -2271,10 +2474,10 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", - "in": "PATH", - "type": "string", + "name": "labels", + "description": "The names of the custom labels to add to the runner. **Minimum items**: 1. **Maximum items**: 100.", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -2284,11 +2487,11 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", + "name": "work_folder", + "description": "The working directory to be used for job execution, relative to the runner install directory.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -2297,24 +2500,31 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get default workflow permissions for an enterprise", + "name": "Create configuration for a just-in-time runner for an organization", "scope": "actions", - "id": "getGithubActionsDefaultWorkflowPermissionsEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/actions/permissions/workflow", + "id": "generateRunnerJitconfigForOrg", + "method": "POST", + "url": "/orgs/{org}/actions/runners/generate-jitconfig", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an enterprise,\nas well as whether GitHub Actions can submit approving pull request reviews. For more information, see\n\"[Enforcing a policy for workflow permissions in your enterprise](https://docs.github.com/enterprise-cloud@latest//enterprise-cloud@latest/admin/policies/enforcing-policies-for-your-enterprise/enforcing-policies-for-github-actions-in-your-enterprise#enforcing-a-policy-for-workflow-permissions-in-your-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.\nGitHub Apps must have the `enterprise_administration:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-default-workflow-permissions-for-an-enterprise", + "description": "Generates a configuration that can be passed to the runner application at startup.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/self-hosted-runners#create-configuration-for-a-just-in-time-runner-for-an-organization", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2324,27 +2534,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Success response" }], - "renamed": null - }, - { - "name": "Get default workflow permissions for an organization", - "scope": "actions", - "id": "getGithubActionsDefaultWorkflowPermissionsOrganization", - "method": "GET", - "url": "/orgs/{org}/actions/permissions/workflow", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an organization,\nas well as whether GitHub Actions can submit approving pull request reviews. For more information, see\n\"[Setting the permissions of the GITHUB_TOKEN for your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-organization-settings/disabling-or-limiting-github-actions-for-your-organization#setting-the-permissions-of-the-github_token-for-your-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-default-workflow-permissions", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the new runner.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -2353,28 +2547,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get default workflow permissions for a repository", - "scope": "actions", - "id": "getGithubActionsDefaultWorkflowPermissionsRepository", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/permissions/workflow", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in a repository,\nas well as if GitHub Actions can submit approving pull request reviews.\nFor more information, see \"[Setting the permissions of the GITHUB_TOKEN for your repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#setting-the-permissions-of-the-github_token-for-your-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the repository `administration` permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-default-workflow-permissions-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "runner_group_id", + "description": "The ID of the runner group to register the runner to.", + "in": "BODY", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2384,10 +2562,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "labels", + "description": "The names of the custom labels to add to the runner. **Minimum items**: 1. **Maximum items**: 100.", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -2395,29 +2573,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get GitHub Actions permissions for an organization", - "scope": "actions", - "id": "getGithubActionsPermissionsOrganization", - "method": "GET", - "url": "/orgs/{org}/actions/permissions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the GitHub Actions permissions policy for repositories and allowed actions and reusable workflows in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "work_folder", + "description": "The working directory to be used for job execution, relative to the runner install directory.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -2426,20 +2588,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get GitHub Actions permissions for a repository", + "name": "Create configuration for a just-in-time runner for a repository", "scope": "actions", - "id": "getGithubActionsPermissionsRepository", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/permissions", + "id": "generateRunnerJitconfigForRepo", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/runners/generate-jitconfig", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the GitHub Actions permissions policy for a repository, including whether GitHub Actions is enabled and the actions and reusable workflows allowed to run in the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-a-repository", + "description": "Generates a configuration that can be passed to the runner application at startup.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/self-hosted-runners#create-configuration-for-a-just-in-time-runner-for-a-repository", "parameters": [ { "name": "owner", @@ -2456,7 +2625,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2466,27 +2635,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a job for a workflow run", - "scope": "actions", - "id": "getJobForWorkflowRun", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets a specific job in a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-job-for-a-workflow-run", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the new runner.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -2497,10 +2650,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "runner_group_id", + "description": "The ID of the runner group to register the runner to.", + "in": "BODY", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2510,10 +2663,10 @@ "deprecated": null }, { - "name": "job_id", - "description": "The unique identifier of the job.", - "in": "PATH", - "type": "integer", + "name": "labels", + "description": "The names of the custom labels to add to the runner. **Minimum items**: 1. **Maximum items**: 100.", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -2521,29 +2674,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get an organization public key", - "scope": "actions", - "id": "getOrgPublicKey", - "method": "GET", - "url": "/orgs/{org}/actions/secrets/public-key", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-organization-public-key", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "work_folder", + "description": "The working directory to be used for job execution, relative to the runner install directory.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -2552,24 +2689,31 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get an organization secret", + "name": "List GitHub Actions caches for a repository", "scope": "actions", - "id": "getOrgSecret", + "id": "getActionsCacheList", "method": "GET", - "url": "/orgs/{org}/actions/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/actions/caches", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-organization-secret", + "description": "Lists the GitHub Actions caches for a repository.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/cache#list-github-actions-caches-for-a-repository", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2581,8 +2725,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2592,29 +2736,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get pending deployments for a workflow run", - "scope": "actions", - "id": "getPendingDeploymentsForRun", - "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Get all deployment environments for a workflow run that are waiting for protection rules to pass.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-pending-deployments-for-a-workflow-run", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -2623,11 +2751,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ref", + "description": "The full Git reference for narrowing down the cache. The `ref` for a branch should be formatted as `refs/heads/`. To reference a pull request use `refs/pull//merge`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -2636,33 +2777,59 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "key", + "description": "An explicit key or prefix for identifying the cache", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by. `created_at` means when the cache was created. `last_accessed_at` means when the cache was last accessed. `size_in_bytes` is the size of the cache in bytes.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created_at", "last_accessed_at", "size_in_bytes"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get GitHub Actions permissions for a repository", + "name": "Get GitHub Actions cache usage for a repository", "scope": "actions", - "id": "getRepoPermissions", + "id": "getActionsCacheUsage", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/permissions", + "url": "/repos/{owner}/{repo}/actions/cache/usage", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the GitHub Actions permissions policy for a repository, including whether GitHub Actions is enabled and the actions and reusable workflows allowed to run in the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-a-repository", + "description": "Gets GitHub Actions cache usage for a repository.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-cache-usage-for-a-repository", "parameters": [ { "name": "owner", @@ -2679,7 +2846,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2692,31 +2859,23 @@ } ], "responses": [{ "code": 200, "description": "Response" }], - "renamed": { - "before": { "scope": "actions", "id": "getRepoPermissions" }, - "after": { - "scope": "actions", - "id": "getGithubActionsPermissionsRepository" - }, - "date": "2020-11-10", - "note": null - } + "renamed": null }, { - "name": "Get a repository public key", + "name": "List repositories with GitHub Actions cache usage for an organization", "scope": "actions", - "id": "getRepoPublicKey", + "id": "getActionsCacheUsageByRepoForOrg", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/secrets/public-key", + "url": "/orgs/{org}/actions/cache/usage-by-repository", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-repository-public-key", + "description": "Lists repositories and their GitHub Actions cache usage for an organization.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nYou must authenticate using an access token with the `read:org` scope to use this endpoint. GitHub Apps must have the `organization_admistration:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repositories-with-github-actions-cache-usage-for-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2728,8 +2887,50 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get GitHub Actions cache usage for an organization", + "scope": "actions", + "id": "getActionsCacheUsageForOrg", + "method": "GET", + "url": "/orgs/{org}/actions/cache/usage", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the total GitHub Actions cache usage for an organization.\nThe data fetched using this API is refreshed approximately every 5 minutes, so values returned from this endpoint may take at least 5 minutes to get updated.\nYou must authenticate using an access token with the `read:org` scope to use this endpoint. GitHub Apps must have the `organization_admistration:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-cache-usage-for-an-organization", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2745,20 +2946,20 @@ "renamed": null }, { - "name": "Get a repository secret", + "name": "Get allowed actions and reusable workflows for an organization", "scope": "actions", - "id": "getRepoSecret", + "id": "getAllowedActionsOrganization", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/secrets/{secret_name}", + "url": "/orgs/{org}/actions/permissions/selected-actions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-repository-secret", + "description": "Gets the selected actions and reusable workflows that are allowed in an organization. To use this endpoint, the organization permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-allowed-actions-for-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2768,10 +2969,26 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get allowed actions and reusable workflows for a repository", + "scope": "actions", + "id": "getAllowedActionsRepository", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/permissions/selected-actions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the settings for selected actions and reusable workflows that are allowed in a repository. To use this endpoint, the repository policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for a repository](#set-github-actions-permissions-for-a-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-allowed-actions-for-a-repository", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2783,8 +3000,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2800,16 +3017,16 @@ "renamed": null }, { - "name": "Get the review history for a workflow run", + "name": "Get an artifact", "scope": "actions", - "id": "getReviewsForRun", + "id": "getArtifact", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/approvals", + "url": "/repos/{owner}/{repo}/actions/artifacts/{artifact_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Anyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-the-review-history-for-a-workflow-run", + "description": "Gets a specific artifact for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-artifact", "parameters": [ { "name": "owner", @@ -2826,7 +3043,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -2838,8 +3055,8 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "artifact_id", + "description": "The unique identifier of the artifact.", "in": "PATH", "type": "integer", "required": true, @@ -2855,22 +3072,22 @@ "renamed": null }, { - "name": "Get a self-hosted runner for an organization", + "name": "Get an environment public key", "scope": "actions", - "id": "getSelfHostedRunnerForOrg", + "id": "getEnvironmentPublicKey", "method": "GET", - "url": "/orgs/{org}/actions/runners/{runner_id}", + "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/public-key", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific self-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-self-hosted-runner-for-an-organization", + "description": "Get the public key for an environment, which you need to encrypt environment secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-environment-public-key", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2880,10 +3097,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -2897,22 +3114,22 @@ "renamed": null }, { - "name": "Get a self-hosted runner for a repository", + "name": "Get an environment secret", "scope": "actions", - "id": "getSelfHostedRunnerForRepo", + "id": "getEnvironmentSecret", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}", + "url": "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific self-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-self-hosted-runner-for-a-repository", + "description": "Gets a single environment secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-environment-secret", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2922,8 +3139,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -2935,10 +3152,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -2952,22 +3169,22 @@ "renamed": null }, { - "name": "Get a workflow", + "name": "Get an environment variable", "scope": "actions", - "id": "getWorkflow", + "id": "getEnvironmentVariable", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}", + "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific workflow. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow", + "description": "Gets a specific variable in an environment. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `environments:read` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#get-an-environment-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -2977,8 +3194,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -2990,10 +3207,10 @@ "deprecated": null }, { - "name": "workflow_id", - "description": "The ID of the workflow. You can also pass the workflow file name as a string.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", - "type": null, + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3007,33 +3224,20 @@ "renamed": null }, { - "name": "Get the level of access for workflows outside of the repository", + "name": "Get default workflow permissions for an organization", "scope": "actions", - "id": "getWorkflowAccessToRepository", + "id": "getGithubActionsDefaultWorkflowPermissionsOrganization", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/permissions/access", + "url": "/orgs/{org}/actions/permissions/workflow", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the level of access that workflows outside of the repository have to actions and reusable workflows in the repository.\nThis endpoint only applies to internal repositories. For more information, see \"[Managing GitHub Actions settings for a repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-an-internal-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the\nrepository `administration` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-access-level-to-a-repository", + "description": "Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an organization,\nas well as whether GitHub Actions can submit approving pull request reviews. For more information, see\n\"[Setting the permissions of the GITHUB_TOKEN for your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-organization-settings/disabling-or-limiting-github-actions-for-your-organization#setting-the-permissions-of-the-github_token-for-your-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-default-workflow-permissions", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3049,16 +3253,16 @@ "renamed": null }, { - "name": "Get a workflow run", + "name": "Get default workflow permissions for a repository", "scope": "actions", - "id": "getWorkflowRun", + "id": "getGithubActionsDefaultWorkflowPermissionsRepository", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}", + "url": "/repos/{owner}/{repo}/actions/permissions/workflow", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow-run", + "description": "Gets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in a repository,\nas well as if GitHub Actions can submit approving pull request reviews.\nFor more information, see \"[Setting the permissions of the GITHUB_TOKEN for your repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#setting-the-permissions-of-the-github_token-for-your-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the repository `administration` permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-default-workflow-permissions-for-a-repository", "parameters": [ { "name": "owner", @@ -3075,7 +3279,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3085,12 +3289,28 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get GitHub Actions permissions for an organization", + "scope": "actions", + "id": "getGithubActionsPermissionsOrganization", + "method": "GET", + "url": "/orgs/{org}/actions/permissions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the GitHub Actions permissions policy for repositories and allowed actions and reusable workflows in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-an-organization", + "parameters": [ { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3098,35 +3318,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "exclude_pull_requests", - "description": "If `true` pull requests are omitted from the response (empty array).", - "in": "QUERY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a workflow run attempt", + "name": "Get GitHub Actions permissions for a repository", "scope": "actions", - "id": "getWorkflowRunAttempt", + "id": "getGithubActionsPermissionsRepository", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}", + "url": "/repos/{owner}/{repo}/actions/permissions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific workflow run attempt. Anyone with read access to the repository\ncan use this endpoint. If the repository is private you must use an access token\nwith the `repo` scope. GitHub Apps must have the `actions:read` permission to\nuse this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow-run-attempt", + "description": "Gets the GitHub Actions permissions policy for a repository, including whether GitHub Actions is enabled and the actions and reusable workflows allowed to run in the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-a-repository", "parameters": [ { "name": "owner", @@ -3143,7 +3350,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3153,12 +3360,28 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a job for a workflow run", + "scope": "actions", + "id": "getJobForWorkflowRun", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a specific job in a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-job-for-a-workflow-run", + "parameters": [ { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3168,10 +3391,10 @@ "deprecated": null }, { - "name": "attempt_number", - "description": "The attempt number of the workflow run.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3181,11 +3404,11 @@ "deprecated": null }, { - "name": "exclude_pull_requests", - "description": "If `true` pull requests are omitted from the response (empty array).", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "job_id", + "description": "The unique identifier of the job.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3198,20 +3421,20 @@ "renamed": null }, { - "name": "Get workflow run usage", + "name": "Get an organization public key", "scope": "actions", - "id": "getWorkflowRunUsage", + "id": "getOrgPublicKey", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/timing", + "url": "/orgs/{org}/actions/secrets/public-key", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the number of billable minutes and total run time for a specific workflow run. Billable minutes only apply to workflows in private repositories that use GitHub Enterprise Cloud-hosted runners. Usage is listed for each GitHub Enterprise Cloud-hosted runner operating system in milliseconds. Any job re-runs are also included in the usage. The usage does not include the multiplier for macOS and Windows runners and is not rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-run-usage", + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-organization-public-key", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3221,10 +3444,26 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get an organization secret", + "scope": "actions", + "id": "getOrgSecret", + "method": "GET", + "url": "/orgs/{org}/actions/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-an-organization-secret", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3236,10 +3475,10 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3253,20 +3492,20 @@ "renamed": null }, { - "name": "Get workflow usage", + "name": "Get an organization variable", "scope": "actions", - "id": "getWorkflowUsage", + "id": "getOrgVariable", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/timing", + "url": "/orgs/{org}/actions/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the number of billable minutes used by a specific workflow during the current billing cycle. Billable minutes only apply to workflows in private repositories that use GitHub Enterprise Cloud-hosted runners. Usage is listed for each GitHub Enterprise Cloud-hosted runner operating system in milliseconds. Any job re-runs are also included in the usage. The usage does not include the multiplier for macOS and Windows runners and is not rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nYou can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-usage", + "description": "Gets a specific variable in an organization. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:read` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#get-an-organization-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3278,8 +3517,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", "type": "string", "required": true, @@ -3289,35 +3528,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "workflow_id", - "description": "The ID of the workflow. You can also pass the workflow file name as a string.", - "in": "PATH", - "type": null, - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List artifacts for a repository", + "name": "Get pending deployments for a workflow run", "scope": "actions", - "id": "listArtifactsForRepo", + "id": "getPendingDeploymentsForRun", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/artifacts", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all artifacts for a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-artifacts-for-a-repository", + "description": "Get all deployment environments for a workflow run that are waiting for protection rules to pass.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-pending-deployments-for-a-workflow-run", "parameters": [ { "name": "owner", @@ -3334,7 +3560,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3346,24 +3572,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3376,22 +3589,22 @@ "renamed": null }, { - "name": "List environment secrets", + "name": "Get GitHub Actions permissions for a repository", "scope": "actions", - "id": "listEnvironmentSecrets", + "id": "getRepoPermissions", "method": "GET", - "url": "/repositories/{repository_id}/environments/{environment_name}/secrets", + "url": "/repos/{owner}/{repo}/actions/permissions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-environment-secrets", + "description": "Gets the GitHub Actions permissions policy for a repository, including whether GitHub Actions is enabled and the actions and reusable workflows allowed to run in the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-a-repository", "parameters": [ { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3401,8 +3614,8 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3412,13 +3625,37 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": { + "before": { "scope": "actions", "id": "getRepoPermissions" }, + "after": { + "scope": "actions", + "id": "getGithubActionsPermissionsRepository" }, + "date": "2020-11-10", + "note": null + } + }, + { + "name": "Get a repository public key", + "scope": "actions", + "id": "getRepoPublicKey", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/secrets/public-key", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-repository-public-key", + "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3427,11 +3664,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3444,20 +3681,20 @@ "renamed": null }, { - "name": "List jobs for a workflow run", + "name": "Get a required workflow entity for a repository", "scope": "actions", - "id": "listJobsForWorkflowRun", + "id": "getRepoRequiredWorkflow", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/jobs", + "url": "/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists jobs for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-jobs-for-a-workflow-run", + "description": "Gets a specific required workflow present in a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. For more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-repository-required-workflow", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3470,7 +3707,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3482,8 +3719,8 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "required_workflow_id_for_repo", + "description": "The ID of the required workflow that has run at least once in a repository.", "in": "PATH", "type": "integer", "required": true, @@ -3493,14 +3730,33 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get required workflow usage", + "scope": "actions", + "id": "getRepoRequiredWorkflowUsage", + "method": "GET", + "url": "/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/timing", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the number of billable minutes used by a specific required workflow during the current billing cycle.\n\nBillable minutes only apply to required workflows running in private repositories that use GitHub Enterprise Cloud-hosted runners. Usage is listed for each GitHub Enterprise Cloud-hosted runner operating system in milliseconds. Any job re-runs are also included in the usage. The usage does not include the multiplier for macOS and Windows runners and is not rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions).\"\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-repository-required-workflow-usage", + "parameters": [ { - "name": "filter", - "description": "Filters jobs by their `completed_at` timestamp. `latest` returns jobs from the most recent execution of the workflow run. `all` returns all jobs for a workflow run, including from old executions of the workflow run.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["latest", "all"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -3508,11 +3764,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3521,11 +3777,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "required_workflow_id_for_repo", + "description": "The ID of the required workflow that has run at least once in a repository.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3534,20 +3790,23 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List jobs for a workflow run attempt", + "name": "Get a repository secret", "scope": "actions", - "id": "listJobsForWorkflowRunAttempt", + "id": "getRepoSecret", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs", + "url": "/repos/{owner}/{repo}/actions/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists jobs for a specific workflow run attempt. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-jobs-for-a-workflow-run-attempt", + "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-repository-secret", "parameters": [ { "name": "owner", @@ -3564,7 +3823,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3576,10 +3835,10 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3587,12 +3846,28 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a repository variable", + "scope": "actions", + "id": "getRepoVariable", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/variables/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a specific variable in a repository. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions_variables:read` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#get-a-repository-variable", + "parameters": [ { - "name": "attempt_number", - "description": "The attempt number of the workflow run.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -3602,11 +3877,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3615,11 +3890,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "name", + "description": "The name of the variable.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3628,23 +3903,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List labels for a self-hosted runner for an organization", + "name": "Get a required workflow", "scope": "actions", - "id": "listLabelsForSelfHostedRunnerForOrg", + "id": "getRequiredWorkflow", "method": "GET", - "url": "/orgs/{org}/actions/runners/{runner_id}/labels", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all labels for a self-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-labels-for-a-self-hosted-runner-for-an-organization", + "description": "Get a required workflow configured in an organization.\n\nYou must authenticate using an access token with the `read:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-required-workflow", "parameters": [ { "name": "org", @@ -3660,8 +3932,8 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", "in": "PATH", "type": "integer", "required": true, @@ -3673,23 +3945,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List labels for a self-hosted runner for a repository", + "name": "Get the review history for a workflow run", "scope": "actions", - "id": "listLabelsForSelfHostedRunnerForRepo", + "id": "getReviewsForRun", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/approvals", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all labels for a self-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-labels-for-a-self-hosted-runner-for-a-repository", + "description": "Anyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-the-review-history-for-a-workflow-run", "parameters": [ { "name": "owner", @@ -3706,7 +3975,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3718,8 +3987,8 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "run_id", + "description": "The unique identifier of the workflow run.", "in": "PATH", "type": "integer", "required": true, @@ -3731,23 +4000,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List organization secrets", + "name": "Get a self-hosted runner for an organization", "scope": "actions", - "id": "listOrgSecrets", + "id": "getSelfHostedRunnerForOrg", "method": "GET", - "url": "/orgs/{org}/actions/secrets", + "url": "/orgs/{org}/actions/runners/{runner_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-organization-secrets", + "description": "Gets a specific self-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-self-hosted-runner-for-an-organization", "parameters": [ { "name": "org", @@ -3763,24 +4029,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3793,16 +4046,16 @@ "renamed": null }, { - "name": "List repository secrets", + "name": "Get a self-hosted runner for a repository", "scope": "actions", - "id": "listRepoSecrets", + "id": "getSelfHostedRunnerForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/secrets", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repository-secrets", + "description": "Gets a specific self-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-self-hosted-runner-for-a-repository", "parameters": [ { "name": "owner", @@ -3819,7 +4072,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3831,24 +4084,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -3861,16 +4101,16 @@ "renamed": null }, { - "name": "List repository workflows", + "name": "Get a workflow", "scope": "actions", - "id": "listRepoWorkflows", + "id": "getWorkflow", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/workflows", + "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the workflows in a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repository-workflows", + "description": "Gets a specific workflow. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow", "parameters": [ { "name": "owner", @@ -3887,7 +4127,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -3899,52 +4139,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List runner applications for an organization", - "scope": "actions", - "id": "listRunnerApplicationsForOrg", - "method": "GET", - "url": "/orgs/{org}/actions/runners/downloads", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists binaries for the runner application that you can download and run.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-runner-applications-for-an-organization", - "parameters": [ - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "workflow_id", + "description": "The ID of the workflow. You can also pass the workflow file name as a string.", "in": "PATH", - "type": "string", + "type": null, "required": true, "enum": null, "allowNull": false, @@ -3958,16 +4156,16 @@ "renamed": null }, { - "name": "List runner applications for a repository", + "name": "Get the level of access for workflows outside of the repository", "scope": "actions", - "id": "listRunnerApplicationsForRepo", + "id": "getWorkflowAccessToRepository", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runners/downloads", + "url": "/repos/{owner}/{repo}/actions/permissions/access", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists binaries for the runner application that you can download and run.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-runner-applications-for-a-repository", + "description": "Gets the level of access that workflows outside of the repository have to actions and reusable workflows in the repository.\nThis endpoint only applies to internal and private repositories.\nFor more information, see \"[Allowing access to components in a private repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-a-private-repository)\" and\n\"[Allowing access to components in an internal repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-an-internal-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the\nrepository `administration` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-access-level-to-a-repository", "parameters": [ { "name": "owner", @@ -3984,7 +4182,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4000,20 +4198,20 @@ "renamed": null }, { - "name": "List selected repositories for an organization secret", + "name": "Get a workflow run", "scope": "actions", - "id": "listSelectedReposForOrgSecret", + "id": "getWorkflowRun", "method": "GET", - "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-repositories-for-an-organization-secret", + "description": "Gets a specific workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow-run", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4025,8 +4223,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4038,11 +4236,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4051,10 +4249,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "exclude_pull_requests", + "description": "If `true` pull requests are omitted from the response (empty array).", "in": "QUERY", - "type": "integer", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -4068,20 +4266,20 @@ "renamed": null }, { - "name": "List selected repositories enabled for GitHub Actions in an organization", + "name": "Get a workflow run attempt", "scope": "actions", - "id": "listSelectedRepositoriesEnabledGithubActionsOrganization", + "id": "getWorkflowRunAttempt", "method": "GET", - "url": "/orgs/{org}/actions/permissions/repositories", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-repositories-enabled-for-github-actions-in-an-organization", + "description": "Gets a specific workflow run attempt. Anyone with read access to the repository\ncan use this endpoint. If the repository is private you must use an access token\nwith the `repo` scope. GitHub Apps must have the `actions:read` permission to\nuse this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-a-workflow-run-attempt", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4093,11 +4291,24 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4106,10 +4317,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "attempt_number", + "description": "The attempt number of the workflow run.", + "in": "PATH", "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "exclude_pull_requests", + "description": "If `true` pull requests are omitted from the response (empty array).", + "in": "QUERY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -4123,20 +4347,20 @@ "renamed": null }, { - "name": "List self-hosted runners for an organization", + "name": "Get workflow run usage", "scope": "actions", - "id": "listSelfHostedRunnersForOrg", + "id": "getWorkflowRunUsage", "method": "GET", - "url": "/orgs/{org}/actions/runners", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/timing", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all self-hosted runners configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-self-hosted-runners-for-an-organization", + "description": "Gets the number of billable minutes and total run time for a specific workflow run. Billable minutes only apply to workflows in private repositories that use GitHub Enterprise Cloud-hosted runners. Usage is listed for each GitHub Enterprise Cloud-hosted runner operating system in milliseconds. Any job re-runs are also included in the usage. The usage does not include the multiplier for macOS and Windows runners and is not rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-run-usage", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4148,11 +4372,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4161,11 +4385,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4178,16 +4402,16 @@ "renamed": null }, { - "name": "List self-hosted runners for a repository", + "name": "Get workflow usage", "scope": "actions", - "id": "listSelfHostedRunnersForRepo", + "id": "getWorkflowUsage", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runners", + "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/timing", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the `repo` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-self-hosted-runners-for-a-repository", + "description": "Gets the number of billable minutes used by a specific workflow during the current billing cycle. Billable minutes only apply to workflows in private repositories that use GitHub Enterprise Cloud-hosted runners. Usage is listed for each GitHub Enterprise Cloud-hosted runner operating system in milliseconds. Any job re-runs are also included in the usage. The usage does not include the multiplier for macOS and Windows runners and is not rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nYou can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-workflow-usage", "parameters": [ { "name": "owner", @@ -4204,7 +4428,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4216,24 +4440,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "workflow_id", + "description": "The ID of the workflow. You can also pass the workflow file name as a string.", + "in": "PATH", + "type": null, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4246,16 +4457,16 @@ "renamed": null }, { - "name": "List workflow run artifacts", + "name": "List artifacts for a repository", "scope": "actions", - "id": "listWorkflowRunArtifacts", + "id": "listArtifactsForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/artifacts", + "url": "/repos/{owner}/{repo}/actions/artifacts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists artifacts for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-run-artifacts", + "description": "Lists all artifacts for a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-artifacts-for-a-repository", "parameters": [ { "name": "owner", @@ -4272,7 +4483,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4284,11 +4495,11 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -4297,8 +4508,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -4310,10 +4521,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "name", + "description": "Filters artifacts by exact match on their name field.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -4327,22 +4538,22 @@ "renamed": null }, { - "name": "List workflow runs for a workflow", + "name": "List environment secrets", "scope": "actions", - "id": "listWorkflowRuns", + "id": "listEnvironmentSecrets", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs", + "url": "/repositories/{repository_id}/environments/{environment_name}/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all workflow runs for a workflow. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-runs", + "description": "Lists all secrets available in an environment without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-environment-secrets", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -4352,8 +4563,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -4365,11 +4576,11 @@ "deprecated": null }, { - "name": "workflow_id", - "description": "The ID of the workflow. You can also pass the workflow file name as a string.", - "in": "PATH", - "type": null, - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -4378,10 +4589,10 @@ "deprecated": null }, { - "name": "actor", - "description": "Returns someone's workflow runs. Use the login for the user who created the `push` associated with the check suite or workflow run.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4389,13 +4600,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List environment variables", + "scope": "actions", + "id": "listEnvironmentVariables", + "method": "GET", + "url": "/repositories/{repository_id}/environments/{environment_name}/variables", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all environment variables. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `environments:read` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#list-environment-variables", + "parameters": [ { - "name": "branch", - "description": "Returns workflow runs associated with a branch. Use the name of the branch of the `push`.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4404,11 +4631,11 @@ "deprecated": null }, { - "name": "event", - "description": "Returns workflow run triggered by the event you specify. For example, `push`, `pull_request` or `issue`. For more information, see \"[Events that trigger workflows](https://docs.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows).\"", - "in": "QUERY", + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4417,26 +4644,12 @@ "deprecated": null }, { - "name": "status", - "description": "Returns workflow runs with the check run `status` or `conclusion` that you specify. For example, a conclusion can be `success` or a status can be `in_progress`. Only GitHub can set a status of `waiting` or `requested`.", + "name": "per_page", + "description": "The number of results per page (max 30).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": [ - "completed", - "action_required", - "cancelled", - "failure", - "neutral", - "skipped", - "stale", - "success", - "timed_out", - "in_progress", - "queued", - "requested", - "waiting" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -4444,8 +4657,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -4455,13 +4668,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List jobs for a workflow run", + "scope": "actions", + "id": "listJobsForWorkflowRun", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/jobs", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists jobs for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-jobs-for-a-workflow-run", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4470,11 +4699,11 @@ "deprecated": null }, { - "name": "created", - "description": "Returns workflow runs created within the given date-time range. For more information on the syntax, see \"[Understanding the search syntax](https://docs.github.com/enterprise-cloud@latest//search-github/getting-started-with-searching-on-github/understanding-the-search-syntax#query-for-dates).\"", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4483,12 +4712,25 @@ "deprecated": null }, { - "name": "exclude_pull_requests", - "description": "If `true` pull requests are omitted from the response (empty array).", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "filter", + "description": "Filters jobs by their `completed_at` timestamp. `latest` returns jobs from the most recent execution of the workflow run. `all` returns all jobs for a workflow run, including from old executions of the workflow run.", "in": "QUERY", - "type": "boolean", + "type": "string", "required": false, - "enum": null, + "enum": ["latest", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -4496,8 +4738,8 @@ "deprecated": null }, { - "name": "check_suite_id", - "description": "Returns workflow runs with the `check_suite_id` that you specify.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -4509,10 +4751,10 @@ "deprecated": null }, { - "name": "head_sha", - "description": "Only returns workflow runs that are associated with the specified `head_sha`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4526,16 +4768,16 @@ "renamed": null }, { - "name": "List workflow runs for a repository", + "name": "List jobs for a workflow run attempt", "scope": "actions", - "id": "listWorkflowRunsForRepo", + "id": "listJobsForWorkflowRunAttempt", "method": "GET", - "url": "/repos/{owner}/{repo}/actions/runs", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/attempts/{attempt_number}/jobs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all workflow runs for a repository. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-runs-for-a-repository", + "description": "Lists jobs for a specific workflow run attempt. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-jobs-for-a-workflow-run-attempt", "parameters": [ { "name": "owner", @@ -4552,7 +4794,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4564,11 +4806,11 @@ "deprecated": null }, { - "name": "actor", - "description": "Returns someone's workflow runs. Use the login for the user who created the `push` associated with the check suite or workflow run.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4577,11 +4819,11 @@ "deprecated": null }, { - "name": "branch", - "description": "Returns workflow runs associated with a branch. Use the name of the branch of the `push`.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "attempt_number", + "description": "The attempt number of the workflow run.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4590,10 +4832,10 @@ "deprecated": null }, { - "name": "event", - "description": "Returns workflow run triggered by the event you specify. For example, `push`, `pull_request` or `issue`. For more information, see \"[Events that trigger workflows](https://docs.github.com/en/actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows).\"", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4603,38 +4845,43 @@ "deprecated": null }, { - "name": "status", - "description": "Returns workflow runs with the check run `status` or `conclusion` that you specify. For example, a conclusion can be `success` or a status can be `in_progress`. Only GitHub can set a status of `waiting` or `requested`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": [ - "completed", - "action_required", - "cancelled", - "failure", - "neutral", - "skipped", - "stale", - "success", - "timed_out", - "in_progress", - "queued", - "requested", - "waiting" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List labels for a self-hosted runner for an organization", + "scope": "actions", + "id": "listLabelsForSelfHostedRunnerForOrg", + "method": "GET", + "url": "/orgs/{org}/actions/runners/{runner_id}/labels", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all labels for a self-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-labels-for-a-self-hosted-runner-for-an-organization", + "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4643,11 +4890,43 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List labels for a self-hosted runner for a repository", + "scope": "actions", + "id": "listLabelsForSelfHostedRunnerForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all labels for a self-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-labels-for-a-self-hosted-runner-for-a-repository", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4656,11 +4935,11 @@ "deprecated": null }, { - "name": "created", - "description": "Returns workflow runs created within the given date-time range. For more information on the syntax, see \"[Understanding the search syntax](https://docs.github.com/enterprise-cloud@latest//search-github/getting-started-with-searching-on-github/understanding-the-search-syntax#query-for-dates).\"", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4669,11 +4948,43 @@ "deprecated": null }, { - "name": "exclude_pull_requests", - "description": "If `true` pull requests are omitted from the response (empty array).", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List organization secrets", + "scope": "actions", + "id": "listOrgSecrets", + "method": "GET", + "url": "/orgs/{org}/actions/secrets", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-organization-secrets", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -4682,8 +4993,8 @@ "deprecated": null }, { - "name": "check_suite_id", - "description": "Returns workflow runs with the `check_suite_id` that you specify.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -4695,10 +5006,10 @@ "deprecated": null }, { - "name": "head_sha", - "description": "Only returns workflow runs that are associated with the specified `head_sha`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4712,33 +5023,20 @@ "renamed": null }, { - "name": "Re-run a job from a workflow run", + "name": "List organization variables", "scope": "actions", - "id": "reRunJobForWorkflowRun", - "method": "POST", - "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}/rerun", + "id": "listOrgVariables", + "method": "GET", + "url": "/orgs/{org}/actions/variables", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-job-for-workflow-run", + "description": "Lists all organization variables. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:read` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#list-organization-variables", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4750,11 +5048,11 @@ "deprecated": null }, { - "name": "job_id", - "description": "The unique identifier of the job.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 30).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -4763,10 +5061,10 @@ "deprecated": null }, { - "name": "enable_debug_logging", - "description": "Whether to enable debug logging for the re-run.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4776,23 +5074,20 @@ "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Re-run a workflow", + "name": "List repository organization secrets", "scope": "actions", - "id": "reRunWorkflow", - "method": "POST", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/rerun", + "id": "listRepoOrganizationSecrets", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/organization-secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Re-runs your workflow run using its `id`. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-a-workflow", + "description": "Lists all organization secrets shared with a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/secrets#list-repository-organization-secrets", "parameters": [ { "name": "owner", @@ -4809,7 +5104,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4821,11 +5116,11 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -4834,10 +5129,10 @@ "deprecated": null }, { - "name": "enable_debug_logging", - "description": "Whether to enable debug logging for the re-run.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4847,20 +5142,20 @@ "deprecated": null } ], - "responses": [{ "code": 201, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Re-run failed jobs from a workflow run", + "name": "List repository organization variables", "scope": "actions", - "id": "reRunWorkflowFailedJobs", - "method": "POST", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/rerun-failed-jobs", + "id": "listRepoOrganizationVariables", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/organization-variables", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Re-run all of the failed jobs and their dependent jobs in a workflow run using the `id` of the workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-workflow-failed-jobs", + "description": "Lists all organiation variables shared with a repository. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions_variables:read` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#list-repository-organization-variables", "parameters": [ { "name": "owner", @@ -4877,7 +5172,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -4889,11 +5184,11 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 30).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -4902,10 +5197,10 @@ "deprecated": null }, { - "name": "enable_debug_logging", - "description": "Whether to enable debug logging for the re-run.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -4915,20 +5210,20 @@ "deprecated": null } ], - "responses": [{ "code": 201, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Remove all custom labels from a self-hosted runner for an organization", + "name": "List repository required workflows", "scope": "actions", - "id": "removeAllCustomLabelsFromSelfHostedRunnerForOrg", - "method": "DELETE", - "url": "/orgs/{org}/actions/runners/{runner_id}/labels", + "id": "listRepoRequiredWorkflows", + "method": "GET", + "url": "/repos/{org}/{repo}/actions/required_workflows", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-all-custom-labels-from-a-self-hosted-runner-for-an-organization", + "description": "Lists the required workflows in a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint. For more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repository-required-workflows", "parameters": [ { "name": "org", @@ -4944,10 +5239,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -4955,6 +5250,32 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ @@ -4964,16 +5285,16 @@ "renamed": null }, { - "name": "Remove all custom labels from a self-hosted runner for a repository", + "name": "List repository secrets", "scope": "actions", - "id": "removeAllCustomLabelsFromSelfHostedRunnerForRepo", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", + "id": "listRepoSecrets", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-all-custom-labels-from-a-self-hosted-runner-for-a-repository", + "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repository-secrets", "parameters": [ { "name": "owner", @@ -4990,7 +5311,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5002,11 +5323,24 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5015,27 +5349,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Remove a custom label from a self-hosted runner for an organization", + "name": "List repository variables", "scope": "actions", - "id": "removeCustomLabelFromSelfHostedRunnerForOrg", - "method": "DELETE", - "url": "/orgs/{org}/actions/runners/{runner_id}/labels/{name}", + "id": "listRepoVariables", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/variables", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.\n\nThis endpoint returns a `404 Not Found` status if the custom label is not\npresent on the runner.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-custom-label-from-a-self-hosted-runner-for-an-organization", + "description": "Lists all repository variables. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions_variables:read` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#list-repository-variables", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5047,10 +5378,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -5060,40 +5391,46 @@ "deprecated": null }, { - "name": "name", - "description": "The name of a self-hosted runner's custom label.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 30).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Remove a custom label from a self-hosted runner for a repository", + "name": "List repository workflows", "scope": "actions", - "id": "removeCustomLabelFromSelfHostedRunnerForRepo", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels/{name}", + "id": "listRepoWorkflows", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/workflows", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.\n\nThis endpoint returns a `404 Not Found` status if the custom label is not\npresent on the runner.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-custom-label-from-a-self-hosted-runner-for-a-repository", + "description": "Lists the workflows in a repository. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-repository-workflows", "parameters": [ { "name": "owner", @@ -5110,7 +5447,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5122,11 +5459,11 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5135,11 +5472,11 @@ "deprecated": null }, { - "name": "name", - "description": "The name of a self-hosted runner's custom label.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5148,31 +5485,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Remove selected repository from an organization secret", + "name": "List workflow runs for a required workflow", "scope": "actions", - "id": "removeSelectedRepoFromOrgSecret", - "method": "DELETE", - "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}", + "id": "listRequiredWorkflowRuns", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-selected-repository-from-an-organization-secret", + "description": "List all workflow runs for a required workflow. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. For more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-required-workflow-runs", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5184,8 +5514,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5197,8 +5527,8 @@ "deprecated": null }, { - "name": "repository_id", - "description": "", + "name": "required_workflow_id_for_repo", + "description": "The ID of the required workflow that has run at least once in a repository.", "in": "PATH", "type": "integer", "required": true, @@ -5208,38 +5538,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "Response when repository was removed from the selected list" }, { - "code": 409, - "description": "Conflict when visibility type not set to selected" - } - ], - "renamed": null - }, - { - "name": "Review pending deployments for a workflow run", - "scope": "actions", - "id": "reviewPendingDeploymentsForRun", - "method": "POST", - "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Approve or reject pending deployments that are waiting on approval by a required reviewer.\n\nRequired reviewers with read access to the repository contents and deployments can use this endpoint. Required reviewers must authenticate using an access token with the `repo` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#review-pending-deployments-for-a-workflow-run", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "actor", + "description": "Returns someone's workflow runs. Use the login for the user who created the `push` associated with the check suite or workflow run.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5248,11 +5553,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "branch", + "description": "Returns workflow runs associated with a branch. Use the name of the branch of the `push`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5261,11 +5566,11 @@ "deprecated": null }, { - "name": "run_id", - "description": "The unique identifier of the workflow run.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "event", + "description": "Returns workflow run triggered by the event you specify. For example, `push`, `pull_request` or `issue`. For more information, see \"[Events that trigger workflows](https://docs.github.com/enterprise-cloud@latest//actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows).\"", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5274,12 +5579,27 @@ "deprecated": null }, { - "name": "environment_ids", - "description": "The list of environment ids to approve or reject", - "in": "BODY", - "type": "integer[]", - "required": true, - "enum": null, + "name": "status", + "description": "Returns workflow runs with the check run `status` or `conclusion` that you specify. For example, a conclusion can be `success` or a status can be `in_progress`. Only GitHub can set a status of `waiting` or `requested`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "completed", + "action_required", + "cancelled", + "failure", + "neutral", + "skipped", + "stale", + "success", + "timed_out", + "in_progress", + "queued", + "requested", + "waiting", + "pending" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -5287,12 +5607,12 @@ "deprecated": null }, { - "name": "state", - "description": "Whether to approve or reject deployment to the specified environments.", - "in": "BODY", - "type": "string", - "required": true, - "enum": ["approved", "rejected"], + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5300,40 +5620,24 @@ "deprecated": null }, { - "name": "comment", - "description": "A comment to accompany the deployment review", - "in": "BODY", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Set allowed actions and reusable workflows for an organization", - "scope": "actions", - "id": "setAllowedActionsOrganization", - "method": "PUT", - "url": "/orgs/{org}/actions/permissions/selected-actions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Sets the actions and reusable workflows that are allowed in an organization. To use this endpoint, the organization permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nIf the organization belongs to an enterprise that has `selected` actions and reusable workflows set at the enterprise level, then you cannot override any of the enterprise's allowed actions and reusable workflows settings.\n\nTo use the `patterns_allowed` setting for private repositories, the organization must belong to an enterprise. If the organization does not belong to an enterprise, then the `patterns_allowed` setting only applies to public repositories in the organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-allowed-actions-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "created", + "description": "Returns workflow runs created within the given date-time range. For more information on the syntax, see \"[Understanding the search syntax](https://docs.github.com/enterprise-cloud@latest//search-github/getting-started-with-searching-on-github/understanding-the-search-syntax#query-for-dates).\"", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5342,9 +5646,9 @@ "deprecated": null }, { - "name": "github_owned_allowed", - "description": "Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.", - "in": "BODY", + "name": "exclude_pull_requests", + "description": "If `true` pull requests are omitted from the response (empty array).", + "in": "QUERY", "type": "boolean", "required": false, "enum": null, @@ -5355,10 +5659,10 @@ "deprecated": null }, { - "name": "verified_allowed", - "description": "Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.", - "in": "BODY", - "type": "boolean", + "name": "check_suite_id", + "description": "Returns workflow runs with the `check_suite_id` that you specify.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -5368,10 +5672,10 @@ "deprecated": null }, { - "name": "patterns_allowed", - "description": "Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/*`.\"", - "in": "BODY", - "type": "string[]", + "name": "head_sha", + "description": "Only returns workflow runs that are associated with the specified `head_sha`.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -5381,24 +5685,24 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set allowed actions and reusable workflows for a repository", + "name": "List required workflows", "scope": "actions", - "id": "setAllowedActionsRepository", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/permissions/selected-actions", + "id": "listRequiredWorkflows", + "method": "GET", + "url": "/orgs/{org}/actions/required_workflows", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the actions and reusable workflows that are allowed in a repository. To use this endpoint, the repository permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for a repository](#set-github-actions-permissions-for-a-repository).\"\n\nIf the repository belongs to an organization or enterprise that has `selected` actions and reusable workflows set at the organization or enterprise levels, then you cannot override any of the allowed actions and reusable workflows settings.\n\nTo use the `patterns_allowed` setting for private repositories, the repository must belong to an enterprise. If the repository does not belong to an enterprise, then the `patterns_allowed` setting only applies to public repositories.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-allowed-actions-for-a-repository", + "description": "List all required workflows in an organization.\n\nYou must authenticate using an access token with the `read:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-required-workflows", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5410,11 +5714,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5423,10 +5727,10 @@ "deprecated": null }, { - "name": "github_owned_allowed", - "description": "Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -5434,13 +5738,58 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List runner applications for an organization", + "scope": "actions", + "id": "listRunnerApplicationsForOrg", + "method": "GET", + "url": "/orgs/{org}/actions/runners/downloads", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists binaries for the runner application that you can download and run.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-runner-applications-for-an-organization", + "parameters": [ { - "name": "verified_allowed", - "description": "Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List runner applications for a repository", + "scope": "actions", + "id": "listRunnerApplicationsForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/runners/downloads", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists binaries for the runner application that you can download and run.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-runner-applications-for-a-repository", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -5449,11 +5798,11 @@ "deprecated": null }, { - "name": "patterns_allowed", - "description": "Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/*`.\"", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -5462,20 +5811,20 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set custom labels for a self-hosted runner for an organization", + "name": "List selected repositories for an organization secret", "scope": "actions", - "id": "setCustomLabelsForSelfHostedRunnerForOrg", - "method": "PUT", - "url": "/orgs/{org}/actions/runners/{runner_id}/labels", + "id": "listSelectedReposForOrgSecret", + "method": "GET", + "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-custom-labels-for-a-self-hosted-runner-for-an-organization", + "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-repositories-for-an-organization-secret", "parameters": [ { "name": "org", @@ -5491,10 +5840,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -5504,44 +5853,50 @@ "deprecated": null }, { - "name": "labels", - "description": "The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.", - "in": "BODY", - "type": "string[]", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set custom labels for a self-hosted runner for a repository", + "name": "List selected repositories for an organization variable", "scope": "actions", - "id": "setCustomLabelsForSelfHostedRunnerForRepo", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", + "id": "listSelectedReposForOrgVariable", + "method": "GET", + "url": "/orgs/{org}/actions/variables/{name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-custom-labels-for-a-self-hosted-runner-for-a-repository", + "description": "Lists all repositories that can access an organization variable that is available to selected repositories. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:read` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#list-selected-repositories-for-an-organization-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5553,8 +5908,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", "type": "string", "required": true, @@ -5566,11 +5921,11 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5579,11 +5934,11 @@ "deprecated": null }, { - "name": "labels", - "description": "The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.", - "in": "BODY", - "type": "string[]", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5594,29 +5949,28 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 409, + "description": "Response when the visibility of the variable is not set to `selected`" } ], "renamed": null }, { - "name": "Set default workflow permissions for an enterprise", + "name": "List selected repositories enabled for GitHub Actions in an organization", "scope": "actions", - "id": "setGithubActionsDefaultWorkflowPermissionsEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/permissions/workflow", + "id": "listSelectedRepositoriesEnabledGithubActionsOrganization", + "method": "GET", + "url": "/orgs/{org}/actions/permissions/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an enterprise, and sets\nwhether GitHub Actions can submit approving pull request reviews. For more information, see\n\"[Enforcing a policy for workflow permissions in your enterprise](https://docs.github.com/enterprise-cloud@latest//enterprise-cloud@latest/admin/policies/enforcing-policies-for-your-enterprise/enforcing-policies-for-github-actions-in-your-enterprise#enforcing-a-policy-for-workflow-permissions-in-your-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.\nGitHub Apps must have the `enterprise_administration:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-default-workflow-permissions-for-an-enterprise", + "description": "Lists the selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-repositories-enabled-for-github-actions-in-an-organization", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5628,12 +5982,12 @@ "deprecated": null }, { - "name": "default_workflow_permissions", - "description": "The default workflow permissions granted to the GITHUB_TOKEN when running workflows.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5641,10 +5995,10 @@ "deprecated": null }, { - "name": "can_approve_pull_request_reviews", - "description": "Whether GitHub Actions can approve pull requests. Enabling this can be a security risk.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -5654,20 +6008,20 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Success response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set default workflow permissions for an organization", + "name": "List selected repositories for a required workflow", "scope": "actions", - "id": "setGithubActionsDefaultWorkflowPermissionsOrganization", - "method": "PUT", - "url": "/orgs/{org}/actions/permissions/workflow", + "id": "listSelectedRepositoriesRequiredWorkflow", + "method": "GET", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an organization, and sets if GitHub Actions\ncan submit approving pull request reviews. For more information, see\n\"[Setting the permissions of the GITHUB_TOKEN for your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-organization-settings/disabling-or-limiting-github-actions-for-your-organization#setting-the-permissions-of-the-github_token-for-your-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-default-workflow-permissions", + "description": "Lists the selected repositories that are configured for a required workflow in an organization. To use this endpoint, the required workflow must be configured to run on selected repositories.\n\nYou must authenticate using an access token with the `read:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-repositories-required-workflows", "parameters": [ { "name": "org", @@ -5683,24 +6037,11 @@ "deprecated": null }, { - "name": "default_workflow_permissions", - "description": "The default workflow permissions granted to the GITHUB_TOKEN when running workflows.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "can_approve_pull_request_reviews", - "description": "Whether GitHub Actions can approve pull requests. Enabling this can be a security risk.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -5710,29 +6051,26 @@ } ], "responses": [ - { "code": 204, "description": "Success response" }, - { - "code": 409, - "description": "Conflict response when changing a setting is prevented by the owning enterprise" - } + { "code": 200, "description": "Success" }, + { "code": 404, "description": "Resource Not Found" } ], "renamed": null }, { - "name": "Set default workflow permissions for a repository", + "name": "List self-hosted runners for an organization", "scope": "actions", - "id": "setGithubActionsDefaultWorkflowPermissionsRepository", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/permissions/workflow", + "id": "listSelfHostedRunnersForOrg", + "method": "GET", + "url": "/orgs/{org}/actions/runners", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in a repository, and sets if GitHub Actions\ncan submit approving pull request reviews.\nFor more information, see \"[Setting the permissions of the GITHUB_TOKEN for your repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#setting-the-permissions-of-the-github_token-for-your-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the repository `administration` permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-default-workflow-permissions-for-a-repository", + "description": "Lists all self-hosted runners configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-self-hosted-runners-for-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5744,25 +6082,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "default_workflow_permissions", - "description": "The default workflow permissions granted to the GITHUB_TOKEN when running workflows.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5770,10 +6095,10 @@ "deprecated": null }, { - "name": "can_approve_pull_request_reviews", - "description": "Whether GitHub Actions can approve pull requests. Enabling this can be a security risk.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -5783,30 +6108,24 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Success response" }, - { - "code": 409, - "description": "Conflict response when changing a setting is prevented by the owning organization or enterprise" - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set GitHub Actions permissions for an organization", + "name": "List self-hosted runners for a repository", "scope": "actions", - "id": "setGithubActionsPermissionsOrganization", - "method": "PUT", - "url": "/orgs/{org}/actions/permissions", + "id": "listSelfHostedRunnersForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/runners", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the GitHub Actions permissions policy for repositories and allowed actions and reusable workflows in an organization.\n\nIf the organization belongs to an enterprise that has set restrictive permissions at the enterprise level, such as `allowed_actions` to `selected` actions and reusable workflows, then you cannot override them for the organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-github-actions-permissions-for-an-organization", + "description": "Lists all self-hosted runners configured in a repository. You must authenticate using an access token with the `repo` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-self-hosted-runners-for-a-repository", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5818,12 +6137,12 @@ "deprecated": null }, { - "name": "enabled_repositories", - "description": "The policy that controls the repositories in the organization that are allowed to run GitHub Actions.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, - "enum": ["all", "none", "selected"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5831,12 +6150,25 @@ "deprecated": null }, { - "name": "allowed_actions", - "description": "The permissions policy that controls the actions and reusable workflows that are allowed to run.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["all", "local_only", "selected"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5844,20 +6176,20 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set GitHub Actions permissions for a repository", + "name": "List workflow run artifacts", "scope": "actions", - "id": "setGithubActionsPermissionsRepository", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/permissions", + "id": "listWorkflowRunArtifacts", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/artifacts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the GitHub Actions permissions policy for enabling GitHub Actions and allowed actions and reusable workflows in the repository.\n\nIf the repository belongs to an organization or enterprise that has set restrictive permissions at the organization or enterprise levels, such as `allowed_actions` to `selected` actions and reusable workflows, then you cannot override them for the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-github-actions-permissions-for-a-repository", + "description": "Lists artifacts for a workflow run. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-run-artifacts", "parameters": [ { "name": "owner", @@ -5874,7 +6206,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5886,10 +6218,10 @@ "deprecated": null }, { - "name": "enabled", - "description": "Whether GitHub Actions is enabled on the repository.", - "in": "BODY", - "type": "boolean", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -5899,12 +6231,25 @@ "deprecated": null }, { - "name": "allowed_actions", - "description": "The permissions policy that controls the actions and reusable workflows that are allowed to run.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["all", "local_only", "selected"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -5912,24 +6257,24 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set selected repositories for an organization secret", + "name": "List workflow runs for a workflow", "scope": "actions", - "id": "setSelectedReposForOrgSecret", - "method": "PUT", - "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories", + "id": "listWorkflowRuns", + "method": "GET", + "url": "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-for-an-organization-secret", + "description": "List all workflow runs for a workflow. You can replace `workflow_id` with the workflow file name. For example, you could use `main.yaml`. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-runs", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5941,8 +6286,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -5954,10 +6299,10 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-for-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-selected-repository-from-an-organization-secret) endpoints.", - "in": "BODY", - "type": "integer[]", + "name": "workflow_id", + "description": "The ID of the workflow. You can also pass the workflow file name as a string.", + "in": "PATH", + "type": null, "required": true, "enum": null, "allowNull": false, @@ -5965,29 +6310,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Set selected repositories enabled for GitHub Actions in an organization", - "scope": "actions", - "id": "setSelectedRepositoriesEnabledGithubActionsOrganization", - "method": "PUT", - "url": "/orgs/{org}/actions/permissions/repositories", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Replaces the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-enabled-for-github-actions-in-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "actor", + "description": "Returns someone's workflow runs. Use the login for the user who created the `push` associated with the check suite or workflow run.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -5996,40 +6325,24 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "List of repository IDs to enable for GitHub Actions.", - "in": "BODY", - "type": "integer[]", - "required": true, + "name": "branch", + "description": "Returns workflow runs associated with a branch. Use the name of the branch of the `push`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Set the level of access for workflows outside of the repository", - "scope": "actions", - "id": "setWorkflowAccessToRepository", - "method": "PUT", - "url": "/repos/{owner}/{repo}/actions/permissions/access", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Sets the level of access that workflows outside of the repository have to actions and reusable workflows in the repository.\nThis endpoint only applies to internal repositories. For more information, see \"[Managing GitHub Actions settings for a repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-an-internal-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the\nrepository `administration` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-workflow-access-to-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "event", + "description": "Returns workflow run triggered by the event you specify. For example, `push`, `pull_request` or `issue`. For more information, see \"[Events that trigger workflows](https://docs.github.com/enterprise-cloud@latest//actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows).\"", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -6038,12 +6351,27 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "status", + "description": "Returns workflow runs with the check run `status` or `conclusion` that you specify. For example, a conclusion can be `success` or a status can be `in_progress`. Only GitHub can set a status of `waiting` or `requested`.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": [ + "completed", + "action_required", + "cancelled", + "failure", + "neutral", + "skipped", + "stale", + "success", + "timed_out", + "in_progress", + "queued", + "requested", + "waiting", + "pending" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -6051,40 +6379,24 @@ "deprecated": null }, { - "name": "access_level", - "description": "Defines the level of access that workflows outside of the repository have to actions and reusable workflows within the\nrepository. `none` means access is only possible from workflows in this repository.", - "in": "BODY", - "type": "string", - "required": true, - "enum": ["none", "organization", "enterprise"], + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Check if a repository is starred by the authenticated user", - "scope": "activity", - "id": "checkRepoIsStarredByAuthenticatedUser", - "method": "GET", - "url": "/user/starred/{owner}/{repo}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#check-if-a-repository-is-starred-by-the-authenticated-user", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -6093,52 +6405,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "created", + "description": "Returns workflow runs created within the given date-time range. For more information on the syntax, see \"[Understanding the search syntax](https://docs.github.com/enterprise-cloud@latest//search-github/getting-started-with-searching-on-github/understanding-the-search-syntax#query-for-dates).\"", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "Response if this repository is starred by you" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 404, - "description": "Not Found if this repository is not starred by you" - } - ], - "renamed": null - }, - { - "name": "Delete a repository subscription", - "scope": "activity", - "id": "deleteRepoSubscription", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/subscription", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "This endpoint should only be used to stop watching a repository. To control whether or not you wish to receive notifications from a repository, [set the repository's subscription manually](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-repository-subscription).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-repository-subscription", - "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "exclude_pull_requests", + "description": "If `true` pull requests are omitted from the response (empty array).", + "in": "QUERY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -6147,40 +6431,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "check_suite_id", + "description": "Returns workflow runs with the `check_suite_id` that you specify.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete a thread subscription", - "scope": "activity", - "id": "deleteThreadSubscription", - "method": "DELETE", - "url": "/notifications/threads/{thread_id}/subscription", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Mutes all future notifications for a conversation until you comment on the thread or get an **@mention**. If you are watching the repository of the thread, you will still receive notifications. To ignore future notifications for a repository you are watching, use the [Set a thread subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-thread-subscription) endpoint and set `ignore` to `true`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-thread-subscription", - "parameters": [ + }, { - "name": "thread_id", - "description": "The unique identifier of the pull request thread.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "head_sha", + "description": "Only returns workflow runs that are associated with the specified `head_sha`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -6189,40 +6457,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Get feeds", - "scope": "activity", - "id": "getFeeds", - "method": "GET", - "url": "/feeds", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "GitHub Enterprise Cloud provides several timeline resources in [Atom](http://en.wikipedia.org/wiki/Atom_(standard)) format. The Feeds API lists all the feeds available to the authenticated user:\n\n* **Timeline**: The GitHub Enterprise Cloud global public timeline\n* **User**: The public timeline for any user, using [URI template](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia)\n* **Current user public**: The public timeline for the authenticated user\n* **Current user**: The private timeline for the authenticated user\n* **Current user actor**: The private timeline for activity created by the authenticated user\n* **Current user organizations**: The private timeline for the organizations the authenticated user is a member of.\n* **Security advisories**: A collection of public announcements that provide information about security-related vulnerabilities in software on GitHub Enterprise Cloud.\n\n**Note**: Private feeds are only returned when [authenticating via Basic Auth](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) since current feed URIs use the older, non revocable auth tokens.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-feeds", - "parameters": [], "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a repository subscription", - "scope": "activity", - "id": "getRepoSubscription", + "name": "List workflow runs for a repository", + "scope": "actions", + "id": "listWorkflowRunsForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/subscription", + "url": "/repos/{owner}/{repo}/actions/runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-repository-subscription", + "description": "Lists all workflow runs for a repository. You can use parameters to narrow the list of results. For more information about using parameters, see [Parameters](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#parameters).\n\nAnyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-workflow-runs-for-a-repository", "parameters": [ { "name": "owner", @@ -6239,7 +6487,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6249,104 +6497,39 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "if you subscribe to the repository" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 404, - "description": "Not Found if you don't subscribe to the repository" - } - ], - "renamed": null - }, - { - "name": "Get a thread", - "scope": "activity", - "id": "getThread", - "method": "GET", - "url": "/notifications/threads/{thread_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-thread", - "parameters": [ + }, { - "name": "thread_id", - "description": "The unique identifier of the pull request thread.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "actor", + "description": "Returns someone's workflow runs. Use the login for the user who created the `push` associated with the check suite or workflow run.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Get a thread subscription for the authenticated user", - "scope": "activity", - "id": "getThreadSubscriptionForAuthenticatedUser", - "method": "GET", - "url": "/notifications/threads/{thread_id}/subscription", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "This checks to see if the current user is subscribed to a thread. You can also [get a repository subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-repository-subscription).\n\nNote that subscriptions are only generated if a user is participating in a conversation--for example, they've replied to the thread, were **@mentioned**, or manually subscribe to a thread.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-thread-subscription-for-the-authenticated-user", - "parameters": [ + }, { - "name": "thread_id", - "description": "The unique identifier of the pull request thread.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "branch", + "description": "Returns workflow runs associated with a branch. Use the name of the branch of the `push`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "List events for the authenticated user", - "scope": "activity", - "id": "listEventsForAuthenticatedUser", - "method": "GET", - "url": "/users/{username}/events", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "If you are authenticated as the given user, you will see your private events. Otherwise, you'll only see public events.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-events-for-the-authenticated-user", - "parameters": [ + }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "event", + "description": "Returns workflow run triggered by the event you specify. For example, `push`, `pull_request` or `issue`. For more information, see \"[Events that trigger workflows](https://docs.github.com/enterprise-cloud@latest//actions/automating-your-workflow-with-github-actions/events-that-trigger-workflows).\"", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -6354,6 +6537,34 @@ "alias": null, "deprecated": null }, + { + "name": "status", + "description": "Returns workflow runs with the check run `status` or `conclusion` that you specify. For example, a conclusion can be `success` or a status can be `in_progress`. Only GitHub can set a status of `waiting` or `requested`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "completed", + "action_required", + "cancelled", + "failure", + "neutral", + "skipped", + "stale", + "success", + "timed_out", + "in_progress", + "queued", + "requested", + "waiting", + "pending" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -6379,52 +6590,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List notifications for the authenticated user", - "scope": "activity", - "id": "listNotificationsForAuthenticatedUser", - "method": "GET", - "url": "/notifications", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List all notifications for the current user, sorted by most recently updated.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user", - "parameters": [ - { - "name": "all", - "description": "If `true`, show notifications marked as read.", - "in": "QUERY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "participating", - "description": "If `true`, only shows notifications in which the user is directly participating or mentioned.", - "in": "QUERY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "name": "created", + "description": "Returns workflow runs created within the given date-time range. For more information on the syntax, see \"[Understanding the search syntax](https://docs.github.com/enterprise-cloud@latest//search-github/getting-started-with-searching-on-github/understanding-the-search-syntax#query-for-dates).\"", "in": "QUERY", "type": "string", "required": false, @@ -6436,10 +6605,10 @@ "deprecated": null }, { - "name": "before", - "description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "name": "exclude_pull_requests", + "description": "If `true` pull requests are omitted from the response (empty array).", "in": "QUERY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -6449,8 +6618,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "check_suite_id", + "description": "Returns workflow runs with the `check_suite_id` that you specify.", "in": "QUERY", "type": "integer", "required": false, @@ -6462,10 +6631,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 50).", + "name": "head_sha", + "description": "Only returns workflow runs that are associated with the specified `head_sha`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -6475,33 +6644,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List organization events for the authenticated user", - "scope": "activity", - "id": "listOrgEventsForAuthenticatedUser", - "method": "GET", - "url": "/users/{username}/events/orgs/{org}", + "name": "Re-run a job from a workflow run", + "scope": "actions", + "id": "reRunJobForWorkflowRun", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/jobs/{job_id}/rerun", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This is the user's organization dashboard. You must be authenticated as the user to view this.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-organization-events-for-the-authenticated-user", + "description": "Re-run a job and its dependent jobs in a workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-job-for-workflow-run", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6513,8 +6673,8 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6526,53 +6686,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List public events", - "scope": "activity", - "id": "listPublicEvents", - "method": "GET", - "url": "/events", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "We delay the public events feed by five minutes, which means the most recent event returned by the public events API actually occurred at least five minutes ago.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events", - "parameters": [ - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "job_id", + "description": "The unique identifier of the job.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6581,10 +6699,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "enable_debug_logging", + "description": "Whether to enable debug logging for the re-run.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -6595,24 +6713,22 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 503, "description": "Service unavailable" } + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "List public events for a network of repositories", - "scope": "activity", - "id": "listPublicEventsForRepoNetwork", - "method": "GET", - "url": "/networks/{owner}/{repo}/events", + "name": "Re-run a workflow", + "scope": "actions", + "id": "reRunWorkflow", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/rerun", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-for-a-network-of-repositories", + "description": "Re-runs your workflow run using its `id`. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-a-workflow", "parameters": [ { "name": "owner", @@ -6629,7 +6745,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6641,11 +6757,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6654,10 +6770,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "enable_debug_logging", + "description": "Whether to enable debug logging for the re-run.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -6667,30 +6783,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "List public events for a user", - "scope": "activity", - "id": "listPublicEventsForUser", - "method": "GET", - "url": "/users/{username}/events/public", + "name": "Re-run failed jobs from a workflow run", + "scope": "actions", + "id": "reRunWorkflowFailedJobs", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/rerun-failed-jobs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-for-a-user", + "description": "Re-run all of the failed jobs and their dependent jobs in a workflow run using the `id` of the workflow run. You must authenticate using an access token with the `repo` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#re-run-workflow-failed-jobs", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6702,11 +6812,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6715,10 +6825,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "enable_debug_logging", + "description": "Whether to enable debug logging for the re-run.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -6728,20 +6851,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "List public organization events", - "scope": "activity", - "id": "listPublicOrgEvents", - "method": "GET", - "url": "/orgs/{org}/events", + "name": "Remove all custom labels from a self-hosted runner for an organization", + "scope": "actions", + "id": "removeAllCustomLabelsFromSelfHostedRunnerForOrg", + "method": "DELETE", + "url": "/orgs/{org}/actions/runners/{runner_id}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-organization-events", + "description": "Remove all custom labels from a self-hosted runner configured in an\norganization. Returns the remaining read-only labels from the runner.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-all-custom-labels-from-a-self-hosted-runner-for-an-organization", "parameters": [ { "name": "org", @@ -6757,24 +6880,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6783,24 +6893,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List events received by the authenticated user", - "scope": "activity", - "id": "listReceivedEventsForUser", - "method": "GET", - "url": "/users/{username}/received_events", + "name": "Remove all custom labels from a self-hosted runner for a repository", + "scope": "actions", + "id": "removeAllCustomLabelsFromSelfHostedRunnerForRepo", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "These are events that you've received by watching repos and following users. If you are authenticated as the given user, you will see private events. Otherwise, you'll only see public events.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-events-received-by-the-authenticated-user", + "description": "Remove all custom labels from a self-hosted runner configured in a\nrepository. Returns the remaining read-only labels from the runner.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-all-custom-labels-from-a-self-hosted-runner-for-a-repository", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6812,11 +6925,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6825,11 +6938,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6838,24 +6951,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List public events received by a user", - "scope": "activity", - "id": "listReceivedPublicEventsForUser", - "method": "GET", - "url": "/users/{username}/received_events/public", + "name": "Remove a custom label from a self-hosted runner for an organization", + "scope": "actions", + "id": "removeCustomLabelFromSelfHostedRunnerForOrg", + "method": "DELETE", + "url": "/orgs/{org}/actions/runners/{runner_id}/labels/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-received-by-a-user", + "description": "Remove a custom label from a self-hosted runner configured\nin an organization. Returns the remaining labels from the runner.\n\nThis endpoint returns a `404 Not Found` status if the custom label is not\npresent on the runner.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-custom-label-from-a-self-hosted-runner-for-an-organization", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6867,11 +6983,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6880,11 +6996,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "name", + "description": "The name of a self-hosted runner's custom label.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6893,20 +7009,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List repository events", - "scope": "activity", - "id": "listRepoEvents", - "method": "GET", - "url": "/repos/{owner}/{repo}/events", + "name": "Remove a custom label from a self-hosted runner for a repository", + "scope": "actions", + "id": "removeCustomLabelFromSelfHostedRunnerForRepo", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-events", + "description": "Remove a custom label from a self-hosted runner configured\nin a repository. Returns the remaining labels from the runner.\n\nThis endpoint returns a `404 Not Found` status if the custom label is not\npresent on the runner.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-custom-label-from-a-self-hosted-runner-for-a-repository", "parameters": [ { "name": "owner", @@ -6923,7 +7046,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6935,11 +7058,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6948,11 +7071,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "name", + "description": "The name of a self-hosted runner's custom label.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -6961,24 +7084,31 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List repository notifications for the authenticated user", - "scope": "activity", - "id": "listRepoNotificationsForAuthenticatedUser", - "method": "GET", - "url": "/repos/{owner}/{repo}/notifications", + "name": "Remove selected repository from an organization secret", + "scope": "actions", + "id": "removeSelectedRepoFromOrgSecret", + "method": "DELETE", + "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all notifications for the current user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-notifications-for-the-authenticated-user", + "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-selected-repository-from-an-organization-secret", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -6990,8 +7120,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -7003,37 +7133,49 @@ "deprecated": null }, { - "name": "all", - "description": "If `true`, show notifications marked as read.", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "repository_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ { - "name": "participating", - "description": "If `true`, only shows notifications in which the user is directly participating or mentioned.", - "in": "QUERY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 204, + "description": "Response when repository was removed from the selected list" }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "code": 409, + "description": "Conflict when visibility type not set to selected" + } + ], + "renamed": null + }, + { + "name": "Remove selected repository from an organization variable", + "scope": "actions", + "id": "removeSelectedRepoFromOrgVariable", + "method": "DELETE", + "url": "/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Removes a repository from an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their `visibility` field set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#remove-selected-repository-from-an-organization-variable", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7042,11 +7184,11 @@ "deprecated": null }, { - "name": "before", - "description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "name", + "description": "The name of the variable.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7055,54 +7197,47 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "repository_id", + "description": "", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 409, + "description": "Response when the visibility of the variable is not set to `selected`" } ], - "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List repositories starred by the authenticated user", - "scope": "activity", - "id": "listReposStarredByAuthenticatedUser", - "method": "GET", - "url": "/user/starred", + "name": "Remove a selected repository from required workflow", + "scope": "actions", + "id": "removeSelectedRepoFromRequiredWorkflow", + "method": "DELETE", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists repositories the authenticated user has starred.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-starred-by-the-authenticated-user", + "description": "Removes a repository from a required workflow. To use this endpoint, the required workflow must be configured to run on selected repositories.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-repository-from-selected-repositories-list-for-a-required-workflow", "parameters": [ { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -7110,12 +7245,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -7123,11 +7258,44 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Success" }, + { "code": 404, "description": "Resource Not Found" }, + { "code": 422, "description": "Validation Error" } + ], + "renamed": null + }, + { + "name": "Review custom deployment protection rules for a workflow run", + "scope": "actions", + "id": "reviewCustomGatesForRun", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/deployment_protection_rule", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Approve or reject custom deployment protection rules provided by a GitHub App for a workflow run. For more information, see \"[Using environments for deployment](https://docs.github.com/enterprise-cloud@latest//actions/deployment/targeting-different-environments/using-environments-for-deployment).\"\n\n**Note:** GitHub Apps can only review their own custom deployment protection rules.\nTo approve or reject pending deployments that are waiting for review from a specific person or team, see [`POST /repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments`](/rest/actions/workflow-runs#review-pending-deployments-for-a-workflow-run).\n\nGitHub Apps must have read and write permission for **Deployments** to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/workflow-runs#review-custom-deployment-protection-rules-for-a-workflow-run", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7136,11 +7304,24 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7149,30 +7330,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List repositories starred by a user", - "scope": "activity", - "id": "listReposStarredByUser", - "method": "GET", - "url": "/users/{username}/starred", + "name": "Review pending deployments for a workflow run", + "scope": "actions", + "id": "reviewPendingDeploymentsForRun", + "method": "POST", + "url": "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists repositories a user has starred.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-starred-by-a-user", + "description": "Approve or reject pending deployments that are waiting on approval by a required reviewer.\n\nRequired reviewers with read access to the repository contents and deployments can use this endpoint. Required reviewers must authenticate using an access token with the `repo` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#review-pending-deployments-for-a-workflow-run", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7184,12 +7359,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -7197,12 +7372,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], + "name": "run_id", + "description": "The unique identifier of the workflow run.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -7210,11 +7385,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "environment_ids", + "description": "The list of environment ids to approve or reject", + "in": "BODY", + "type": "integer[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7223,11 +7398,24 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "state", + "description": "Whether to approve or reject deployment to the specified environments.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["approved", "rejected"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "comment", + "description": "A comment to accompany the deployment review", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7240,20 +7428,20 @@ "renamed": null }, { - "name": "List repositories watched by a user", - "scope": "activity", - "id": "listReposWatchedByUser", - "method": "GET", - "url": "/users/{username}/subscriptions", + "name": "Set allowed actions for an organization", + "scope": "actions", + "id": "setAllowedActionsOrganization", + "method": "PUT", + "url": "/orgs/{org}/actions/permissions/selected-actions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists repositories a user is watching.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-watched-by-a-user", + "description": "Sets the actions that are allowed in an organization. To use this endpoint, the organization permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nIf the organization belongs to an enterprise that has `selected` actions set at the enterprise level, then you cannot override any of the enterprise's allowed actions settings.\n\nTo use the `patterns_allowed` setting for private repositories, the organization must belong to an enterprise. If the organization does not belong to an enterprise, then the `patterns_allowed` setting only applies to public repositories in the organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-allowed-actions-for-an-organization", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7265,10 +7453,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "github_owned_allowed", + "description": "Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -7278,10 +7466,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "verified_allowed", + "description": "Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "patterns_allowed", + "description": "Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/*`.", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -7291,20 +7492,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List stargazers", - "scope": "activity", - "id": "listStargazersForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/stargazers", + "name": "Set allowed actions for a repository", + "scope": "actions", + "id": "setAllowedActionsRepository", + "method": "PUT", + "url": "/repos/{owner}/{repo}/actions/permissions/selected-actions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the people that have starred the repository.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-stargazers", + "description": "Sets the actions that are allowed in a repository. To use this endpoint, the repository permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for a repository](#set-github-actions-permissions-for-a-repository).\"\n\nIf the repository belongs to an organization or enterprise that has `selected` actions set at the organization or enterprise levels, then you cannot override any of the allowed actions settings and reusable workflows settings.\n\nTo use the `patterns_allowed` setting for private repositories, the repository must belong to an enterprise. If the repository does not belong to an enterprise, then the `patterns_allowed` setting only applies to public repositories.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-allowed-actions-for-a-repository", "parameters": [ { "name": "owner", @@ -7321,7 +7522,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7333,10 +7534,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "github_owned_allowed", + "description": "Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -7346,10 +7547,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "verified_allowed", + "description": "Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -7357,35 +7558,42 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "patterns_allowed", + "description": "Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/*`.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List repositories watched by the authenticated user", - "scope": "activity", - "id": "listWatchedReposForAuthenticatedUser", - "method": "GET", - "url": "/user/subscriptions", + "name": "Set custom labels for a self-hosted runner for an organization", + "scope": "actions", + "id": "setCustomLabelsForSelfHostedRunnerForOrg", + "method": "PUT", + "url": "/orgs/{org}/actions/runners/{runner_id}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists repositories the authenticated user is watching.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-watched-by-the-authenticated-user", + "description": "Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-custom-labels-for-a-self-hosted-runner-for-an-organization", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7394,11 +7602,24 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "labels", + "description": "The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.", + "in": "BODY", + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7409,23 +7630,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List watchers", - "scope": "activity", - "id": "listWatchersForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/subscribers", + "name": "Set custom labels for a self-hosted runner for a repository", + "scope": "actions", + "id": "setCustomLabelsForSelfHostedRunnerForRepo", + "method": "PUT", + "url": "/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the people watching the specified repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-watchers", + "description": "Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in a repository.\n\nYou must authenticate using an access token with the `repo` scope to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-custom-labels-for-a-self-hosted-runner-for-a-repository", "parameters": [ { "name": "owner", @@ -7442,7 +7665,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7454,11 +7677,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "runner_id", + "description": "Unique identifier of the self-hosted runner.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7467,11 +7690,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "labels", + "description": "The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.", + "in": "BODY", + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7480,28 +7703,48 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Mark notifications as read", - "scope": "activity", - "id": "markNotificationsAsRead", + "name": "Set default workflow permissions for an organization", + "scope": "actions", + "id": "setGithubActionsDefaultWorkflowPermissionsOrganization", "method": "PUT", - "url": "/notifications", + "url": "/orgs/{org}/actions/permissions/workflow", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Marks all notifications as \"read\" removes it from the [default view on GitHub Enterprise Cloud](https://github.com/notifications). If the number of notifications is too large to complete in one request, you will receive a `202 Accepted` status and GitHub Enterprise Cloud will run an asynchronous process to mark notifications as \"read.\" To check whether any \"unread\" notifications remain, you can use the [List notifications for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user) endpoint and pass the query parameter `all=false`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-notifications-as-read", + "description": "Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in an organization, and sets if GitHub Actions\ncan submit approving pull request reviews. For more information, see\n\"[Setting the permissions of the GITHUB_TOKEN for your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-organization-settings/disabling-or-limiting-github-actions-for-your-organization#setting-the-permissions-of-the-github_token-for-your-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-default-workflow-permissions", "parameters": [ { - "name": "last_read_at", - "description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "default_workflow_permissions", + "description": "The default workflow permissions granted to the GITHUB_TOKEN when running workflows.", "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["read", "write"], "allowNull": false, "mapToData": null, "validation": null, @@ -7509,8 +7752,8 @@ "deprecated": null }, { - "name": "read", - "description": "Whether the notification has been read.", + "name": "can_approve_pull_request_reviews", + "description": "Whether GitHub Actions can approve pull requests. Enabling this can be a security risk.", "in": "BODY", "type": "boolean", "required": false, @@ -7523,25 +7766,25 @@ } ], "responses": [ - { "code": 202, "description": "Response" }, - { "code": 205, "description": "Reset Content" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 204, "description": "Success response" }, + { + "code": 409, + "description": "Conflict response when changing a setting is prevented by the owning enterprise" + } ], "renamed": null }, { - "name": "Mark repository notifications as read", - "scope": "activity", - "id": "markRepoNotificationsAsRead", + "name": "Set default workflow permissions for a repository", + "scope": "actions", + "id": "setGithubActionsDefaultWorkflowPermissionsRepository", "method": "PUT", - "url": "/repos/{owner}/{repo}/notifications", + "url": "/repos/{owner}/{repo}/actions/permissions/workflow", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Marks all notifications in a repository as \"read\" removes them from the [default view on GitHub Enterprise Cloud](https://github.com/notifications). If the number of notifications is too large to complete in one request, you will receive a `202 Accepted` status and GitHub Enterprise Cloud will run an asynchronous process to mark notifications as \"read.\" To check whether any \"unread\" notifications remain, you can use the [List repository notifications for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-notifications-for-the-authenticated-user) endpoint and pass the query parameter `all=false`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-repository-notifications-as-read", + "description": "Sets the default workflow permissions granted to the `GITHUB_TOKEN` when running workflows in a repository, and sets if GitHub Actions\ncan submit approving pull request reviews.\nFor more information, see \"[Setting the permissions of the GITHUB_TOKEN for your repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#setting-the-permissions-of-the-github_token-for-your-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the repository `administration` permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-default-workflow-permissions-for-a-repository", "parameters": [ { "name": "owner", @@ -7558,7 +7801,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7570,11 +7813,24 @@ "deprecated": null }, { - "name": "last_read_at", - "description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp.", + "name": "default_workflow_permissions", + "description": "The default workflow permissions granted to the GITHUB_TOKEN when running workflows.", "in": "BODY", "type": "string", "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "can_approve_pull_request_reviews", + "description": "Whether GitHub Actions can approve pull requests. Enabling this can be a security risk.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -7584,28 +7840,31 @@ } ], "responses": [ - { "code": 202, "description": "Response" }, - { "code": 205, "description": "Reset Content" } + { "code": 204, "description": "Success response" }, + { + "code": 409, + "description": "Conflict response when changing a setting is prevented by the owning organization or enterprise" + } ], "renamed": null }, { - "name": "Mark a thread as read", - "scope": "activity", - "id": "markThreadAsRead", - "method": "PATCH", - "url": "/notifications/threads/{thread_id}", + "name": "Set GitHub Actions permissions for an organization", + "scope": "actions", + "id": "setGithubActionsPermissionsOrganization", + "method": "PUT", + "url": "/orgs/{org}/actions/permissions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-a-thread-as-read", + "description": "Sets the GitHub Actions permissions policy for repositories and allowed actions in an organization.\n\nIf the organization belongs to an enterprise that has set restrictive permissions at the enterprise level, such as `allowed_actions` to `selected` actions, then you cannot override them for the organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-github-actions-permissions-for-an-organization", "parameters": [ { - "name": "thread_id", - "description": "The unique identifier of the pull request thread.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -7613,26 +7872,48 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "enabled_repositories", + "description": "The policy that controls the repositories in the organization that are allowed to run GitHub Actions.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["all", "none", "selected"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "allowed_actions", + "description": "The permissions policy that controls the actions and reusable workflows that are allowed to run.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["all", "local_only", "selected"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 205, "description": "Reset Content" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Set a repository subscription", - "scope": "activity", - "id": "setRepoSubscription", + "name": "Set GitHub Actions permissions for a repository", + "scope": "actions", + "id": "setGithubActionsPermissionsRepository", "method": "PUT", - "url": "/repos/{owner}/{repo}/subscription", + "url": "/repos/{owner}/{repo}/actions/permissions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "If you would like to watch a repository, set `subscribed` to `true`. If you would like to ignore notifications made within a repository, set `ignored` to `true`. If you would like to stop watching a repository, [delete the repository's subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-repository-subscription) completely.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-repository-subscription", + "description": "Sets the GitHub Actions permissions policy for enabling GitHub Actions and allowed actions in the repository.\n\nIf the repository belongs to an organization or enterprise that has set restrictive permissions at the organization or enterprise levels, such as `allowed_actions` to `selected` actions, then you cannot override them for the repository.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration` repository permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-github-actions-permissions-for-a-repository", "parameters": [ { "name": "owner", @@ -7649,7 +7930,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7661,11 +7942,11 @@ "deprecated": null }, { - "name": "subscribed", - "description": "Determines if notifications should be received from this repository.", + "name": "enabled", + "description": "Whether GitHub Actions is enabled on the repository.", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -7674,12 +7955,12 @@ "deprecated": null }, { - "name": "ignored", - "description": "Determines if all notifications should be blocked from this repository.", + "name": "allowed_actions", + "description": "The permissions policy that controls the actions and reusable workflows that are allowed to run.", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, - "enum": null, + "enum": ["all", "local_only", "selected"], "allowNull": false, "mapToData": null, "validation": null, @@ -7687,26 +7968,26 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Set a thread subscription", - "scope": "activity", - "id": "setThreadSubscription", + "name": "Set selected repositories for an organization secret", + "scope": "actions", + "id": "setSelectedReposForOrgSecret", "method": "PUT", - "url": "/notifications/threads/{thread_id}/subscription", + "url": "/orgs/{org}/actions/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "If you are watching a repository, you receive notifications for all threads by default. Use this endpoint to ignore future notifications for threads until you comment on the thread or get an **@mention**.\n\nYou can also use this endpoint to subscribe to threads that you are currently not receiving notifications for or to subscribed to threads that you have previously ignored.\n\nUnsubscribing from a conversation in a repository that you are not watching is functionally equivalent to the [Delete a thread subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-thread-subscription) endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-thread-subscription", + "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-for-an-organization-secret", "parameters": [ { - "name": "thread_id", - "description": "The unique identifier of the pull request thread.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -7716,42 +7997,8 @@ "deprecated": null }, { - "name": "ignored", - "description": "Whether to block all notifications from a thread.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Star a repository for the authenticated user", - "scope": "activity", - "id": "starRepoForAuthenticatedUser", - "method": "PUT", - "url": "/user/starred/{owner}/{repo}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Note that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#star-a-repository-for-the-authenticated-user", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -7763,10 +8010,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Add selected repository to an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/actions/secrets#add-selected-repository-to-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-selected-repository-from-an-organization-secret) endpoints.", + "in": "BODY", + "type": "integer[]", "required": true, "enum": null, "allowNull": false, @@ -7776,30 +8023,24 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Unstar a repository for the authenticated user", - "scope": "activity", - "id": "unstarRepoForAuthenticatedUser", - "method": "DELETE", - "url": "/user/starred/{owner}/{repo}", + "name": "Set selected repositories for an organization variable", + "scope": "actions", + "id": "setSelectedReposForOrgVariable", + "method": "PUT", + "url": "/orgs/{org}/actions/variables/{name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#unstar-a-repository-for-the-authenticated-user", + "description": "Replaces all repositories for an organization variable that is available to selected repositories. Organization variables that are available to selected repositories have their `visibility` field set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#set-selected-repositories-for-an-organization-variable", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7811,8 +8052,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "name", + "description": "The name of the variable.", "in": "PATH", "type": "string", "required": true, @@ -7822,34 +8063,47 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "selected_repository_ids", + "description": "The IDs of the repositories that can access the organization variable.", + "in": "BODY", + "type": "integer[]", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 409, + "description": "Response when the visibility of the variable is not set to `selected`" + } ], "renamed": null }, { - "name": "Add a repository to an app installation", - "scope": "apps", - "id": "addRepoToInstallation", + "name": "Sets repositories for a required workflow", + "scope": "actions", + "id": "setSelectedReposToRequiredWorkflow", "method": "PUT", - "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Add a single repository to an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#add-a-repository-to-an-app-installation", + "description": "Sets the repositories for a required workflow that is required for selected repositories.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-for-a-required-workflow", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -7859,8 +8113,8 @@ "deprecated": null }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", "in": "PATH", "type": "integer", "required": true, @@ -7870,41 +8124,41 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "selected_repository_ids", + "description": "The IDs of the repositories for which the workflow should be required.", + "in": "BODY", + "type": "integer[]", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": { - "before": { "scope": "apps", "id": "addRepoToInstallation" }, - "after": { - "scope": "apps", - "id": "addRepoToInstallationForAuthenticatedUser" - }, - "date": "2021-10-05", - "note": null - } + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null }, { - "name": "Add a repository to an app installation", - "scope": "apps", - "id": "addRepoToInstallationForAuthenticatedUser", + "name": "Set selected repositories enabled for GitHub Actions in an organization", + "scope": "actions", + "id": "setSelectedRepositoriesEnabledGithubActionsOrganization", "method": "PUT", - "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "url": "/orgs/{org}/actions/permissions/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Add a single repository to an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#add-a-repository-to-an-app-installation", + "description": "Replaces the list of selected repositories that are enabled for GitHub Actions in an organization. To use this endpoint, the organization permission policy for `enabled_repositories` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an organization](#set-github-actions-permissions-for-an-organization).\"\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `administration` organization permission to use this API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-repositories-enabled-for-github-actions-in-an-organization", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -7914,10 +8168,10 @@ "deprecated": null }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", - "in": "PATH", - "type": "integer", + "name": "selected_repository_ids", + "description": "List of repository IDs to enable for GitHub Actions.", + "in": "BODY", + "type": "integer[]", "required": true, "enum": null, "allowNull": false, @@ -7927,29 +8181,24 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Check a token", - "scope": "apps", - "id": "checkToken", - "method": "POST", - "url": "/applications/{client_id}/token", + "name": "Set the level of access for workflows outside of the repository", + "scope": "actions", + "id": "setWorkflowAccessToRepository", + "method": "PUT", + "url": "/repos/{owner}/{repo}/actions/permissions/access", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "OAuth applications can use a special API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) to use this endpoint, where the username is the OAuth application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#check-a-token", + "description": "Sets the level of access that workflows outside of the repository have to actions and reusable workflows in the repository.\nThis endpoint only applies to internal and private repositories.\nFor more information, see \"[Allowing access to components in a private repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-a-private-repository)\" and\n\"[Allowing access to components in an internal repository](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-github-actions-settings-for-a-repository#allowing-access-to-components-in-an-internal-repository).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the\nrepository `administration` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-workflow-access-to-a-repository", "parameters": [ { - "name": "client_id", - "description": "The client ID of the GitHub app.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -7961,9 +8210,9 @@ "deprecated": null }, { - "name": "access_token", - "description": "The access_token of the OAuth application.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -7972,37 +8221,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a GitHub App from a manifest", - "scope": "apps", - "id": "createFromManifest", - "method": "POST", - "url": "/app-manifests/{code}/conversions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Use this endpoint to complete the handshake necessary when implementing the [GitHub App Manifest flow](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/creating-github-apps-from-a-manifest/). When you create a GitHub App with the manifest flow, you receive a temporary `code` used to retrieve the GitHub App's `id`, `pem` (private key), and `webhook_secret`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#create-a-github-app-from-a-manifest", - "parameters": [ + }, { - "name": "code", - "description": "", - "in": "PATH", + "name": "access_level", + "description": "Defines the level of access that workflows outside of the repository have to actions and reusable workflows within the\nrepository.\n\n`none` means the access is only possible from workflows in this repository. `user` level access allows sharing across user owned private repos only. `organization` level access allows sharing across the organization. `enterprise` level access allows sharing across the enterprise.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["none", "user", "organization", "enterprise"], "allowNull": false, "mapToData": null, "validation": null, @@ -8010,31 +8236,24 @@ "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Create an installation access token for an app", - "scope": "apps", - "id": "createInstallationAccessToken", - "method": "POST", - "url": "/app/installations/{installation_id}/access_tokens", + "name": "Update an environment variable", + "scope": "actions", + "id": "updateEnvironmentVariable", + "method": "PATCH", + "url": "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates an installation access token that enables a GitHub App to make authenticated API requests for the app's installation on an organization or individual account. Installation tokens expire one hour from the time you create them. Using an expired token produces a status code of `401 - Unauthorized`, and requires creating a new installation token. By default the installation token has access to all repositories that the installation can access. To restrict the access to specific repositories, you can provide the `repository_ids` when creating the token. When you omit `repository_ids`, the response does not contain the `repositories` key.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#create-an-installation-access-token-for-an-app", + "description": "Updates an environment variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `environment:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#update-an-environment-variable", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "repository_id", + "description": "The unique identifier of the repository.", "in": "PATH", "type": "integer", "required": true, @@ -8046,10 +8265,10 @@ "deprecated": null }, { - "name": "repositories", - "description": "List of repository names that the token should have access to", + "name": "name", + "description": "The name of the variable.", "in": "BODY", - "type": "string[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -8059,11 +8278,11 @@ "deprecated": null }, { - "name": "repository_ids", - "description": "List of repository IDs that the token should have access to", - "in": "BODY", - "type": "integer[]", - "required": false, + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -8072,10 +8291,10 @@ "deprecated": null }, { - "name": "permissions", - "description": "The permissions granted to the user-to-server access token.", + "name": "value", + "description": "The value of the variable.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -8083,14 +8302,30 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Update an organization variable", + "scope": "actions", + "id": "updateOrgVariable", + "method": "PATCH", + "url": "/orgs/{org}/actions/variables/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates an organization variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\nGitHub Apps must have the `organization_actions_variables:write` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#update-an-organization-variable", + "parameters": [ { - "name": "permissions.actions", - "description": "The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8098,12 +8333,12 @@ "deprecated": null }, { - "name": "permissions.administration", - "description": "The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.", + "name": "name", + "description": "The name of the variable.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8111,12 +8346,12 @@ "deprecated": null }, { - "name": "permissions.checks", - "description": "The level of permission to grant the access token for checks on code.", + "name": "value", + "description": "The value of the variable.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8124,12 +8359,12 @@ "deprecated": null }, { - "name": "permissions.contents", - "description": "The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.", + "name": "visibility", + "description": "The type of repositories in the organization that can access the variable. `selected` means only the repositories specified by `selected_repository_ids` can access the variable.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": ["all", "private", "selected"], "allowNull": false, "mapToData": null, "validation": null, @@ -8137,25 +8372,41 @@ "deprecated": null }, { - "name": "permissions.deployments", - "description": "The level of permission to grant the access token for deployments and deployment statuses.", + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization variable. You can only provide a list of repository ids when the `visibility` is set to `selected`.", "in": "BODY", - "type": "string", + "type": "integer[]", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Update a repository variable", + "scope": "actions", + "id": "updateRepoVariable", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/actions/variables/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates a repository variable that you can reference in a GitHub Actions workflow.\nYou must authenticate using an access token with the `repo` scope to use this endpoint.\nGitHub Apps must have the `actions_variables:write` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/actions/variables#update-a-repository-variable", + "parameters": [ { - "name": "permissions.environments", - "description": "The level of permission to grant the access token for managing repository environments.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8163,12 +8414,12 @@ "deprecated": null }, { - "name": "permissions.issues", - "description": "The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8176,12 +8427,12 @@ "deprecated": null }, { - "name": "permissions.metadata", - "description": "The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.", + "name": "name", + "description": "The name of the variable.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8189,25 +8440,41 @@ "deprecated": null }, { - "name": "permissions.packages", - "description": "The level of permission to grant the access token for packages published to GitHub Packages.", + "name": "value", + "description": "The value of the variable.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Update a required workflow", + "scope": "actions", + "id": "updateRequiredWorkflow", + "method": "PATCH", + "url": "/orgs/{org}/actions/required_workflows/{required_workflow_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Update a required workflow in an organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.\n\nFor more information, see \"[Required Workflows](https://docs.github.com/enterprise-cloud@latest//actions/using-workflows/required-workflows).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#update-a-required-workflow", + "parameters": [ { - "name": "permissions.pages", - "description": "The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8215,12 +8482,12 @@ "deprecated": null }, { - "name": "permissions.pull_requests", - "description": "The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write"], + "name": "required_workflow_id", + "description": "The unique identifier of the required workflow.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8228,12 +8495,12 @@ "deprecated": null }, { - "name": "permissions.repository_hooks", - "description": "The level of permission to grant the access token to manage the post-receive hooks for a repository.", + "name": "workflow_file_path", + "description": "Path of the workflow file to be configured as a required workflow.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8241,12 +8508,12 @@ "deprecated": null }, { - "name": "permissions.repository_projects", - "description": "The level of permission to grant the access token to manage repository projects, columns, and cards.", + "name": "repository_id", + "description": "The ID of the repository that contains the workflow file.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write", "admin"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8254,12 +8521,12 @@ "deprecated": null }, { - "name": "permissions.secret_scanning_alerts", - "description": "The level of permission to grant the access token to view and manage secret scanning alerts.", + "name": "scope", + "description": "Enable the required workflow for all repositories or selected repositories in the organization.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": ["selected", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -8267,38 +8534,47 @@ "deprecated": null }, { - "name": "permissions.secrets", - "description": "The level of permission to grant the access token to manage repository secrets.", + "name": "selected_repository_ids", + "description": "A list of repository IDs where you want to enable the required workflow. A list of repository IDs where you want to enable the required workflow. You can only provide a list of repository ids when the `scope` is set to `selected`.", "in": "BODY", - "type": "string", + "type": "integer[]", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "permissions.security_events", - "description": "The level of permission to grant the access token to view and manage security events like code scanning alerts.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Check if a repository is starred by the authenticated user", + "scope": "activity", + "id": "checkRepoIsStarredByAuthenticatedUser", + "method": "GET", + "url": "/user/starred/{owner}/{repo}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#check-if-a-repository-is-starred-by-the-authenticated-user", + "parameters": [ { - "name": "permissions.single_file", - "description": "The level of permission to grant the access token to manage just a single file.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8306,25 +8582,53 @@ "deprecated": null }, { - "name": "permissions.statuses", - "description": "The level of permission to grant the access token for commit statuses.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 204, + "description": "Response if this repository is starred by you" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { - "name": "permissions.vulnerability_alerts", - "description": "The level of permission to grant the access token to manage Dependabot alerts.", - "in": "BODY", + "code": 404, + "description": "Not Found if this repository is not starred by you" + } + ], + "renamed": null + }, + { + "name": "Delete a repository subscription", + "scope": "activity", + "id": "deleteRepoSubscription", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This endpoint should only be used to stop watching a repository. To control whether or not you wish to receive notifications from a repository, [set the repository's subscription manually](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-repository-subscription).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-repository-subscription", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8332,19 +8636,4110 @@ "deprecated": null }, { - "name": "permissions.workflows", - "description": "The level of permission to grant the access token to update GitHub Actions workflow files.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, - { + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a thread subscription", + "scope": "activity", + "id": "deleteThreadSubscription", + "method": "DELETE", + "url": "/notifications/threads/{thread_id}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Mutes all future notifications for a conversation until you comment on the thread or get an **@mention**. If you are watching the repository of the thread, you will still receive notifications. To ignore future notifications for a repository you are watching, use the [Set a thread subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-thread-subscription) endpoint and set `ignore` to `true`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-thread-subscription", + "parameters": [ + { + "name": "thread_id", + "description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user)).", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Get feeds", + "scope": "activity", + "id": "getFeeds", + "method": "GET", + "url": "/feeds", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "GitHub Enterprise Cloud provides several timeline resources in [Atom](http://en.wikipedia.org/wiki/Atom_(standard)) format. The Feeds API lists all the feeds available to the authenticated user:\n\n* **Timeline**: The GitHub Enterprise Cloud global public timeline\n* **User**: The public timeline for any user, using [URI template](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia)\n* **Current user public**: The public timeline for the authenticated user\n* **Current user**: The private timeline for the authenticated user\n* **Current user actor**: The private timeline for activity created by the authenticated user\n* **Current user organizations**: The private timeline for the organizations the authenticated user is a member of.\n* **Security advisories**: A collection of public announcements that provide information about security-related vulnerabilities in software on GitHub Enterprise Cloud.\n\n**Note**: Private feeds are only returned when [authenticating via Basic Auth](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) since current feed URIs use the older, non revocable auth tokens.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-feeds", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a repository subscription", + "scope": "activity", + "id": "getRepoSubscription", + "method": "GET", + "url": "/repos/{owner}/{repo}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-repository-subscription", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "if you subscribe to the repository" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 404, + "description": "Not Found if you don't subscribe to the repository" + } + ], + "renamed": null + }, + { + "name": "Get a thread", + "scope": "activity", + "id": "getThread", + "method": "GET", + "url": "/notifications/threads/{thread_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets information about a notification thread.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-thread", + "parameters": [ + { + "name": "thread_id", + "description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user)).", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Get a thread subscription for the authenticated user", + "scope": "activity", + "id": "getThreadSubscriptionForAuthenticatedUser", + "method": "GET", + "url": "/notifications/threads/{thread_id}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This checks to see if the current user is subscribed to a thread. You can also [get a repository subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-repository-subscription).\n\nNote that subscriptions are only generated if a user is participating in a conversation--for example, they've replied to the thread, were **@mentioned**, or manually subscribe to a thread.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#get-a-thread-subscription-for-the-authenticated-user", + "parameters": [ + { + "name": "thread_id", + "description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user)).", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List events for the authenticated user", + "scope": "activity", + "id": "listEventsForAuthenticatedUser", + "method": "GET", + "url": "/users/{username}/events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "If you are authenticated as the given user, you will see your private events. Otherwise, you'll only see public events.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-events-for-the-authenticated-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List notifications for the authenticated user", + "scope": "activity", + "id": "listNotificationsForAuthenticatedUser", + "method": "GET", + "url": "/notifications", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "List all notifications for the current user, sorted by most recently updated.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user", + "parameters": [ + { + "name": "all", + "description": "If `true`, show notifications marked as read.", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "participating", + "description": "If `true`, only shows notifications in which the user is directly participating or mentioned.", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "before", + "description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 50).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List organization events for the authenticated user", + "scope": "activity", + "id": "listOrgEventsForAuthenticatedUser", + "method": "GET", + "url": "/users/{username}/events/orgs/{org}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This is the user's organization dashboard. You must be authenticated as the user to view this.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-organization-events-for-the-authenticated-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List public events", + "scope": "activity", + "id": "listPublicEvents", + "method": "GET", + "url": "/events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "We delay the public events feed by five minutes, which means the most recent event returned by the public events API actually occurred at least five minutes ago.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "List public events for a network of repositories", + "scope": "activity", + "id": "listPublicEventsForRepoNetwork", + "method": "GET", + "url": "/networks/{owner}/{repo}/events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-for-a-network-of-repositories", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List public events for a user", + "scope": "activity", + "id": "listPublicEventsForUser", + "method": "GET", + "url": "/users/{username}/events/public", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-for-a-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List public organization events", + "scope": "activity", + "id": "listPublicOrgEvents", + "method": "GET", + "url": "/orgs/{org}/events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-organization-events", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List events received by the authenticated user", + "scope": "activity", + "id": "listReceivedEventsForUser", + "method": "GET", + "url": "/users/{username}/received_events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "These are events that you've received by watching repos and following users. If you are authenticated as the given user, you will see private events. Otherwise, you'll only see public events.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-events-received-by-the-authenticated-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List public events received by a user", + "scope": "activity", + "id": "listReceivedPublicEventsForUser", + "method": "GET", + "url": "/users/{username}/received_events/public", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-public-events-received-by-a-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repository events", + "scope": "activity", + "id": "listRepoEvents", + "method": "GET", + "url": "/repos/{owner}/{repo}/events", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note**: This API is not built to serve real-time use cases. Depending on the time of day, event latency can be anywhere from 30s to 6h.\n", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-events", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repository notifications for the authenticated user", + "scope": "activity", + "id": "listRepoNotificationsForAuthenticatedUser", + "method": "GET", + "url": "/repos/{owner}/{repo}/notifications", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all notifications for the current user in the specified repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-notifications-for-the-authenticated-user", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "all", + "description": "If `true`, show notifications marked as read.", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "participating", + "description": "If `true`, only shows notifications in which the user is directly participating or mentioned.", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "before", + "description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repositories starred by the authenticated user", + "scope": "activity", + "id": "listReposStarredByAuthenticatedUser", + "method": "GET", + "url": "/user/starred", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists repositories the authenticated user has starred.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-starred-by-the-authenticated-user", + "parameters": [ + { + "name": "sort", + "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List repositories starred by a user", + "scope": "activity", + "id": "listReposStarredByUser", + "method": "GET", + "url": "/users/{username}/starred", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists repositories a user has starred.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-starred-by-a-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repositories watched by a user", + "scope": "activity", + "id": "listReposWatchedByUser", + "method": "GET", + "url": "/users/{username}/subscriptions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists repositories a user is watching.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-watched-by-a-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List stargazers", + "scope": "activity", + "id": "listStargazersForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/stargazers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people that have starred the repository.\n\nYou can also find out _when_ stars were created by passing the following custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) via the `Accept` header: `application/vnd.github.star+json`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-stargazers", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List repositories watched by the authenticated user", + "scope": "activity", + "id": "listWatchedReposForAuthenticatedUser", + "method": "GET", + "url": "/user/subscriptions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists repositories the authenticated user is watching.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repositories-watched-by-the-authenticated-user", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List watchers", + "scope": "activity", + "id": "listWatchersForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/subscribers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people watching the specified repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-watchers", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Mark notifications as read", + "scope": "activity", + "id": "markNotificationsAsRead", + "method": "PUT", + "url": "/notifications", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Marks all notifications as \"read\" for the current user. If the number of notifications is too large to complete in one request, you will receive a `202 Accepted` status and GitHub Enterprise Cloud will run an asynchronous process to mark notifications as \"read.\" To check whether any \"unread\" notifications remain, you can use the [List notifications for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user) endpoint and pass the query parameter `all=false`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-notifications-as-read", + "parameters": [ + { + "name": "last_read_at", + "description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "read", + "description": "Whether the notification has been read.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 202, "description": "Response" }, + { "code": 205, "description": "Reset Content" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Mark repository notifications as read", + "scope": "activity", + "id": "markRepoNotificationsAsRead", + "method": "PUT", + "url": "/repos/{owner}/{repo}/notifications", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Marks all notifications in a repository as \"read\" for the current user. If the number of notifications is too large to complete in one request, you will receive a `202 Accepted` status and GitHub Enterprise Cloud will run an asynchronous process to mark notifications as \"read.\" To check whether any \"unread\" notifications remain, you can use the [List repository notifications for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-repository-notifications-for-the-authenticated-user) endpoint and pass the query parameter `all=false`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-repository-notifications-as-read", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "last_read_at", + "description": "Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. Default: The current timestamp.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 202, "description": "Response" }, + { "code": 205, "description": "Reset Content" } + ], + "renamed": null + }, + { + "name": "Mark a thread as read", + "scope": "activity", + "id": "markThreadAsRead", + "method": "PATCH", + "url": "/notifications/threads/{thread_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Marks a thread as \"read.\" Marking a thread as \"read\" is equivalent to clicking a notification in your notification inbox on GitHub Enterprise Cloud: https://github.com/notifications.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#mark-a-thread-as-read", + "parameters": [ + { + "name": "thread_id", + "description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user)).", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 205, "description": "Reset Content" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Set a repository subscription", + "scope": "activity", + "id": "setRepoSubscription", + "method": "PUT", + "url": "/repos/{owner}/{repo}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "If you would like to watch a repository, set `subscribed` to `true`. If you would like to ignore notifications made within a repository, set `ignored` to `true`. If you would like to stop watching a repository, [delete the repository's subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-repository-subscription) completely.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-repository-subscription", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "subscribed", + "description": "Determines if notifications should be received from this repository.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ignored", + "description": "Determines if all notifications should be blocked from this repository.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Set a thread subscription", + "scope": "activity", + "id": "setThreadSubscription", + "method": "PUT", + "url": "/notifications/threads/{thread_id}/subscription", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "If you are watching a repository, you receive notifications for all threads by default. Use this endpoint to ignore future notifications for threads until you comment on the thread or get an **@mention**.\n\nYou can also use this endpoint to subscribe to threads that you are currently not receiving notifications for or to subscribed to threads that you have previously ignored.\n\nUnsubscribing from a conversation in a repository that you are not watching is functionally equivalent to the [Delete a thread subscription](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#delete-a-thread-subscription) endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#set-a-thread-subscription", + "parameters": [ + { + "name": "thread_id", + "description": "The unique identifier of the notification thread. This corresponds to the value returned in the `id` field when you retrieve notifications (for example with the [`GET /notifications` operation](https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#list-notifications-for-the-authenticated-user)).", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ignored", + "description": "Whether to block all notifications from a thread.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Star a repository for the authenticated user", + "scope": "activity", + "id": "starRepoForAuthenticatedUser", + "method": "PUT", + "url": "/user/starred/{owner}/{repo}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Note that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#star-a-repository-for-the-authenticated-user", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Unstar a repository for the authenticated user", + "scope": "activity", + "id": "unstarRepoForAuthenticatedUser", + "method": "DELETE", + "url": "/user/starred/{owner}/{repo}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/activity#unstar-a-repository-for-the-authenticated-user", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Add a repository to an app installation", + "scope": "apps", + "id": "addRepoToInstallation", + "method": "PUT", + "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Add a single repository to an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#add-a-repository-to-an-app-installation", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": { + "before": { "scope": "apps", "id": "addRepoToInstallation" }, + "after": { + "scope": "apps", + "id": "addRepoToInstallationForAuthenticatedUser" + }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "Add a repository to an app installation", + "scope": "apps", + "id": "addRepoToInstallationForAuthenticatedUser", + "method": "PUT", + "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Add a single repository to an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#add-a-repository-to-an-app-installation", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Check a token", + "scope": "apps", + "id": "checkToken", + "method": "POST", + "url": "/applications/{client_id}/token", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "OAuth applications and GitHub applications with OAuth authorizations can use this API method for checking OAuth token validity without exceeding the normal rate limits for failed login attempts. Authentication works differently with this particular endpoint. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) to use this endpoint, where the username is the application `client_id` and the password is its `client_secret`. Invalid tokens will return `404 NOT FOUND`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#check-a-token", + "parameters": [ + { + "name": "client_id", + "description": "The client ID of the GitHub app.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "access_token", + "description": "The access_token of the OAuth or GitHub application.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a GitHub App from a manifest", + "scope": "apps", + "id": "createFromManifest", + "method": "POST", + "url": "/app-manifests/{code}/conversions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Use this endpoint to complete the handshake necessary when implementing the [GitHub App Manifest flow](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/creating-github-apps-from-a-manifest/). When you create a GitHub App with the manifest flow, you receive a temporary `code` used to retrieve the GitHub App's `id`, `pem` (private key), and `webhook_secret`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#create-a-github-app-from-a-manifest", + "parameters": [ + { + "name": "code", + "description": "", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create an installation access token for an app", + "scope": "apps", + "id": "createInstallationAccessToken", + "method": "POST", + "url": "/app/installations/{installation_id}/access_tokens", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates an installation access token that enables a GitHub App to make authenticated API requests for the app's installation on an organization or individual account. Installation tokens expire one hour from the time you create them. Using an expired token produces a status code of `401 - Unauthorized`, and requires creating a new installation token. By default the installation token has access to all repositories that the installation can access. To restrict the access to specific repositories, you can provide the `repository_ids` when creating the token. When you omit `repository_ids`, the response does not contain the `repositories` key.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#create-an-installation-access-token-for-an-app", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repositories", + "description": "List of repository names that the token should have access to", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_ids", + "description": "List of repository IDs that the token should have access to", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions", + "description": "The permissions granted to the user-to-server access token.", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.actions", + "description": "The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.administration", + "description": "The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.checks", + "description": "The level of permission to grant the access token for checks on code.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.contents", + "description": "The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.deployments", + "description": "The level of permission to grant the access token for deployments and deployment statuses.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.environments", + "description": "The level of permission to grant the access token for managing repository environments.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.issues", + "description": "The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.metadata", + "description": "The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.packages", + "description": "The level of permission to grant the access token for packages published to GitHub Packages.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.pages", + "description": "The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.pull_requests", + "description": "The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.repository_hooks", + "description": "The level of permission to grant the access token to manage the post-receive hooks for a repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.repository_projects", + "description": "The level of permission to grant the access token to manage repository projects, columns, and cards.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write", "admin"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.secret_scanning_alerts", + "description": "The level of permission to grant the access token to view and manage secret scanning alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.secrets", + "description": "The level of permission to grant the access token to manage repository secrets.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.security_events", + "description": "The level of permission to grant the access token to view and manage security events like code scanning alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.single_file", + "description": "The level of permission to grant the access token to manage just a single file.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.statuses", + "description": "The level of permission to grant the access token for commit statuses.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.vulnerability_alerts", + "description": "The level of permission to grant the access token to manage Dependabot alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.workflows", + "description": "The level of permission to grant the access token to update GitHub Actions workflow files.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.members", + "description": "The level of permission to grant the access token for organization teams and members.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_administration", + "description": "The level of permission to grant the access token to manage access to an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_custom_roles", + "description": "The level of permission to grant the access token for custom repository roles management. This property is in beta and is subject to change.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_announcement_banners", + "description": "The level of permission to grant the access token to view and manage announcement banners for an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_hooks", + "description": "The level of permission to grant the access token to manage the post-receive hooks for an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_personal_access_tokens", + "description": "The level of permission to grant the access token for viewing and managing fine-grained personal access token requests to an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_personal_access_token_requests", + "description": "The level of permission to grant the access token for viewing and managing fine-grained personal access tokens that have been approved by an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_plan", + "description": "The level of permission to grant the access token for viewing an organization's plan.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_projects", + "description": "The level of permission to grant the access token to manage organization projects and projects beta (where available).", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write", "admin"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_packages", + "description": "The level of permission to grant the access token for organization packages published to GitHub Packages.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_secrets", + "description": "The level of permission to grant the access token to manage organization secrets.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_self_hosted_runners", + "description": "The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_user_blocking", + "description": "The level of permission to grant the access token to view and manage users blocked by the organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.team_discussions", + "description": "The level of permission to grant the access token to manage team discussions and related comments.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Delete an app authorization", + "scope": "apps", + "id": "deleteAuthorization", + "method": "DELETE", + "url": "/applications/{client_id}/grant", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "OAuth and GitHub application owners can revoke a grant for their application and a specific user. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted.\nDeleting an application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-app-authorization", + "parameters": [ + { + "name": "client_id", + "description": "The client ID of the GitHub app.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "access_token", + "description": "The OAuth access token used to authenticate to the GitHub API.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Delete an installation for the authenticated app", + "scope": "apps", + "id": "deleteInstallation", + "method": "DELETE", + "url": "/app/installations/{installation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Uninstalls a GitHub App on a user, organization, or business account. If you prefer to temporarily suspend an app's access to your account's resources, then we recommend the \"[Suspend an app installation](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#suspend-an-app-installation)\" endpoint.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-installation-for-the-authenticated-app", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete an app token", + "scope": "apps", + "id": "deleteToken", + "method": "DELETE", + "url": "/applications/{client_id}/token", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "OAuth or GitHub application owners can revoke a single token for an OAuth application or a GitHub application with an OAuth authorization. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-app-token", + "parameters": [ + { + "name": "client_id", + "description": "The client ID of the GitHub app.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "access_token", + "description": "The OAuth access token used to authenticate to the GitHub API.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Get the authenticated app", + "scope": "apps", + "id": "getAuthenticated", + "method": "GET", + "url": "/app", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns the GitHub App associated with the authentication credentials used. To see how many app installations are associated with this GitHub App, see the `installations_count` in the response. For more details about your app's installations, see the \"[List installations for the authenticated app](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-installations-for-the-authenticated-app)\" endpoint.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-the-authenticated-app", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get an app", + "scope": "apps", + "id": "getBySlug", + "method": "GET", + "url": "/apps/{app_slug}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note**: The `:app_slug` is just the URL-friendly name of your GitHub App. You can find this on the settings page for your GitHub App (e.g., `https://github.com/settings/apps/:app_slug`).\n\nIf the GitHub App you specify is public, you can access this endpoint without authenticating. If the GitHub App you specify is private, you must authenticate with a [personal access token](https://docs.github.com/enterprise-cloud@latest//articles/creating-a-personal-access-token-for-the-command-line/) or an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#get-an-app", + "parameters": [ + { + "name": "app_slug", + "description": "", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get an installation for the authenticated app", + "scope": "apps", + "id": "getInstallation", + "method": "GET", + "url": "/app/installations/{installation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables an authenticated GitHub App to find an installation's information using the installation id.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-an-installation-for-the-authenticated-app", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get an organization installation for the authenticated app", + "scope": "apps", + "id": "getOrgInstallation", + "method": "GET", + "url": "/orgs/{org}/installation", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables an authenticated GitHub App to find the organization's installation information.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-an-organization-installation-for-the-authenticated-app", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a repository installation for the authenticated app", + "scope": "apps", + "id": "getRepoInstallation", + "method": "GET", + "url": "/repos/{owner}/{repo}/installation", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables an authenticated GitHub App to find the repository's installation information. The installation's account type will be either an organization or a user account, depending which account the repository belongs to.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-repository-installation-for-the-authenticated-app", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get a subscription plan for an account", + "scope": "apps", + "id": "getSubscriptionPlanForAccount", + "method": "GET", + "url": "/marketplace_listing/accounts/{account_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Shows whether the user or organization account actively subscribes to a plan listed by the authenticated GitHub App. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-subscription-plan-for-an-account", + "parameters": [ + { + "name": "account_id", + "description": "account_id parameter", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { + "code": 404, + "description": "Not Found when the account has not purchased the listing" + } + ], + "renamed": null + }, + { + "name": "Get a subscription plan for an account (stubbed)", + "scope": "apps", + "id": "getSubscriptionPlanForAccountStubbed", + "method": "GET", + "url": "/marketplace_listing/stubbed/accounts/{account_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Shows whether the user or organization account actively subscribes to a plan listed by the authenticated GitHub App. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-subscription-plan-for-an-account-stubbed", + "parameters": [ + { + "name": "account_id", + "description": "account_id parameter", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { + "code": 404, + "description": "Not Found when the account has not purchased the listing" + } + ], + "renamed": null + }, + { + "name": "Get a user installation for the authenticated app", + "scope": "apps", + "id": "getUserInstallation", + "method": "GET", + "url": "/users/{username}/installation", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables an authenticated GitHub App to find the user’s installation information.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-user-installation-for-the-authenticated-app", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a webhook configuration for an app", + "scope": "apps", + "id": "getWebhookConfigForApp", + "method": "GET", + "url": "/app/hook/config", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see \"[Creating a GitHub App](/developers/apps/creating-a-github-app).\"\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-webhook-configuration-for-an-app", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a delivery for an app webhook", + "scope": "apps", + "id": "getWebhookDelivery", + "method": "GET", + "url": "/app/hook/deliveries/{delivery_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns a delivery for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-delivery-for-an-app-webhook", + "parameters": [ + { + "name": "delivery_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List accounts for a plan", + "scope": "apps", + "id": "listAccountsForPlan", + "method": "GET", + "url": "/marketplace_listing/plans/{plan_id}/accounts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns user and organization accounts associated with the specified plan, including free plans. For per-seat pricing, you see the list of accounts that have purchased the plan, including the number of seats purchased. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-accounts-for-a-plan", + "parameters": [ + { + "name": "plan_id", + "description": "The unique identifier of the plan.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List accounts for a plan (stubbed)", + "scope": "apps", + "id": "listAccountsForPlanStubbed", + "method": "GET", + "url": "/marketplace_listing/stubbed/plans/{plan_id}/accounts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns repository and organization accounts associated with the specified plan, including free plans. For per-seat pricing, you see the list of accounts that have purchased the plan, including the number of seats purchased. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-accounts-for-a-plan-stubbed", + "parameters": [ + { + "name": "plan_id", + "description": "The unique identifier of the plan.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" } + ], + "renamed": null + }, + { + "name": "List repositories accessible to the user access token", + "scope": "apps", + "id": "listInstallationReposForAuthenticatedUser", + "method": "GET", + "url": "/user/installations/{installation_id}/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "List repositories that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access for an installation.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.\n\nYou must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint.\n\nThe access the user has to each repository is included in the hash under the `permissions` key.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-repositories-accessible-to-the-user-access-token", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "The access the user has to each repository is included in the hash under the `permissions` key." + }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List installation requests for the authenticated app", + "scope": "apps", + "id": "listInstallationRequestsForAuthenticatedApp", + "method": "GET", + "url": "/app/installation-requests", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all the pending installation requests for the authenticated GitHub App.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-installation-requests-for-the-authenticated-app", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "List of integration installation requests" + }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" } + ], + "renamed": null + }, + { + "name": "List installations for the authenticated app", + "scope": "apps", + "id": "listInstallations", + "method": "GET", + "url": "/app/installations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.\n\nThe permissions the installation has are included under the `permissions` key.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-installations-for-the-authenticated-app", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "outdated", + "description": "", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "The permissions the installation has are included under the `permissions` key." + } + ], + "renamed": null + }, + { + "name": "List app installations accessible to the user access token", + "scope": "apps", + "id": "listInstallationsForAuthenticatedUser", + "method": "GET", + "url": "/user/installations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists installations of your GitHub App that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access.\n\nYou must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.\n\nYou can find the permissions for the installation under the `permissions` key.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-app-installations-accessible-to-the-user-access-token", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "You can find the permissions for the installation under the `permissions` key." + }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List plans", + "scope": "apps", + "id": "listPlans", + "method": "GET", + "url": "/marketplace_listing/plans", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all plans that are part of your GitHub Enterprise Cloud Marketplace listing.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-plans", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List plans (stubbed)", + "scope": "apps", + "id": "listPlansStubbed", + "method": "GET", + "url": "/marketplace_listing/stubbed/plans", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all plans that are part of your GitHub Enterprise Cloud Marketplace listing.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-plans-stubbed", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" } + ], + "renamed": null + }, + { + "name": "List repositories accessible to the app installation", + "scope": "apps", + "id": "listReposAccessibleToInstallation", + "method": "GET", + "url": "/installation/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "List repositories that an app installation can access.\n\nYou must use an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-repositories-accessible-to-the-app-installation", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List subscriptions for the authenticated user", + "scope": "apps", + "id": "listSubscriptionsForAuthenticatedUser", + "method": "GET", + "url": "/user/marketplace_purchases", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the active subscriptions for the authenticated user. You must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint. . OAuth Apps must authenticate using an [OAuth token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-subscriptions-for-the-authenticated-user", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List subscriptions for the authenticated user (stubbed)", + "scope": "apps", + "id": "listSubscriptionsForAuthenticatedUserStubbed", + "method": "GET", + "url": "/user/marketplace_purchases/stubbed", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the active subscriptions for the authenticated user. You must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint. . OAuth Apps must authenticate using an [OAuth token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-subscriptions-for-the-authenticated-user-stubbed", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" } + ], + "renamed": null + }, + { + "name": "List deliveries for an app webhook", + "scope": "apps", + "id": "listWebhookDeliveries", + "method": "GET", + "url": "/app/hook/deliveries", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns a list of webhook deliveries for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-deliveries-for-an-app-webhook", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cursor", + "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "redelivery", + "description": "", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Redeliver a delivery for an app webhook", + "scope": "apps", + "id": "redeliverWebhookDelivery", + "method": "POST", + "url": "/app/hook/deliveries/{delivery_id}/attempts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Redeliver a delivery for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#redeliver-a-delivery-for-an-app-webhook", + "parameters": [ + { + "name": "delivery_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Remove a repository from an app installation", + "scope": "apps", + "id": "removeRepoFromInstallation", + "method": "DELETE", + "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#remove-a-repository-from-an-app-installation", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Returned when the application is installed on `all` repositories in the organization, or if this request would remove the last repository that the application has access to in the organization." + } + ], + "renamed": { + "before": { "scope": "apps", "id": "removeRepoFromInstallation" }, + "after": { + "scope": "apps", + "id": "removeRepoFromInstallationForAuthenticatedUser" + }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "Remove a repository from an app installation", + "scope": "apps", + "id": "removeRepoFromInstallationForAuthenticatedUser", + "method": "DELETE", + "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Remove a single repository from an installation. The authenticated user must have admin access to the repository. The installation must have the `repository_selection` of `selected`.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#remove-a-repository-from-an-app-installation", + "parameters": [ + { + "name": "installation_id", + "description": "The unique identifier of the installation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_id", + "description": "The unique identifier of the repository.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Returned when the application is installed on `all` repositories in the organization, or if this request would remove the last repository that the application has access to in the organization." + } + ], + "renamed": null + }, + { + "name": "Reset a token", + "scope": "apps", + "id": "resetToken", + "method": "PATCH", + "url": "/applications/{client_id}/token", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "OAuth applications and GitHub applications with OAuth authorizations can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the \"token\" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#reset-a-token", + "parameters": [ + { + "name": "client_id", + "description": "The client ID of the GitHub app.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "access_token", + "description": "The access_token of the OAuth or GitHub application.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Revoke an installation access token", + "scope": "apps", + "id": "revokeInstallationAccessToken", + "method": "DELETE", + "url": "/installation/token", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Revokes the installation token you're using to authenticate as an installation and access this endpoint.\n\nOnce an installation token is revoked, the token is invalidated and cannot be used. Other endpoints that require the revoked installation token must have a new installation token to work. You can create a new token using the \"[Create an installation access token for an app](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#create-an-installation-access-token-for-an-app)\" endpoint.\n\nYou must use an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#revoke-an-installation-access-token", + "parameters": [], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Create a scoped access token", + "scope": "apps", + "id": "scopeToken", + "method": "POST", + "url": "/applications/{client_id}/token/scoped", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Use a non-scoped user-to-server access token to create a repository scoped and/or permission scoped user-to-server access token. You can specify which repositories the token can access and which permissions are granted to the token. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the `client_id` and `client_secret` of the GitHub App as the username and password. Invalid tokens will return `404 NOT FOUND`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#create-a-scoped-access-token", + "parameters": [ + { + "name": "client_id", + "description": "The client ID of the GitHub app.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "access_token", + "description": "The access token used to authenticate to the GitHub API.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "target", + "description": "The name of the user or organization to scope the user-to-server access token to. **Required** unless `target_id` is specified.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "target_id", + "description": "The ID of the user or organization to scope the user-to-server access token to. **Required** unless `target` is specified.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repositories", + "description": "The list of repository names to scope the user-to-server access token to. `repositories` may not be specified if `repository_ids` is specified.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repository_ids", + "description": "The list of repository IDs to scope the user-to-server access token to. `repository_ids` may not be specified if `repositories` is specified.", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions", + "description": "The permissions granted to the user-to-server access token.", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.actions", + "description": "The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.administration", + "description": "The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.checks", + "description": "The level of permission to grant the access token for checks on code.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.contents", + "description": "The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.deployments", + "description": "The level of permission to grant the access token for deployments and deployment statuses.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.environments", + "description": "The level of permission to grant the access token for managing repository environments.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.issues", + "description": "The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.metadata", + "description": "The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.packages", + "description": "The level of permission to grant the access token for packages published to GitHub Packages.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.pages", + "description": "The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.pull_requests", + "description": "The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.repository_hooks", + "description": "The level of permission to grant the access token to manage the post-receive hooks for a repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.repository_projects", + "description": "The level of permission to grant the access token to manage repository projects, columns, and cards.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write", "admin"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.secret_scanning_alerts", + "description": "The level of permission to grant the access token to view and manage secret scanning alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.secrets", + "description": "The level of permission to grant the access token to manage repository secrets.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.security_events", + "description": "The level of permission to grant the access token to view and manage security events like code scanning alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.single_file", + "description": "The level of permission to grant the access token to manage just a single file.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.statuses", + "description": "The level of permission to grant the access token for commit statuses.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.vulnerability_alerts", + "description": "The level of permission to grant the access token to manage Dependabot alerts.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.workflows", + "description": "The level of permission to grant the access token to update GitHub Actions workflow files.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { "name": "permissions.members", "description": "The level of permission to grant the access token for organization teams and members.", "in": "BODY", @@ -8372,7 +12767,20 @@ }, { "name": "permissions.organization_custom_roles", - "description": "The level of permission to grant the access token for custom roles management. This property is in beta and is subject to change.", + "description": "The level of permission to grant the access token for custom repository roles management. This property is in beta and is subject to change.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_announcement_banners", + "description": "The level of permission to grant the access token to view and manage announcement banners for an organization.", "in": "BODY", "type": "string", "required": false, @@ -8396,6 +12804,32 @@ "alias": null, "deprecated": null }, + { + "name": "permissions.organization_personal_access_tokens", + "description": "The level of permission to grant the access token for viewing and managing fine-grained personal access token requests to an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions.organization_personal_access_token_requests", + "description": "The level of permission to grant the access token for viewing and managing fine-grained personal access tokens that have been approved by an organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "permissions.organization_plan", "description": "The level of permission to grant the access token for viewing an organization's plan.", @@ -8489,7 +12923,7 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, + { "code": 200, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, @@ -8501,35 +12935,22 @@ "renamed": null }, { - "name": "Delete an app authorization", + "name": "Suspend an app installation", "scope": "apps", - "id": "deleteAuthorization", - "method": "DELETE", - "url": "/applications/{client_id}/grant", + "id": "suspendInstallation", + "method": "PUT", + "url": "/app/installations/{installation_id}/suspended", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "OAuth application owners can revoke a grant for their OAuth application and a specific user. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. You must also provide a valid OAuth `access_token` as an input parameter and the grant for the token's owner will be deleted.\nDeleting an OAuth application's grant will also delete all OAuth tokens associated with the application for the user. Once deleted, the application will have no access to the user's account and will no longer be listed on [the application authorizations settings screen within GitHub](https://github.com/settings/applications#authorized).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-app-authorization", + "description": "Suspends a GitHub App on a user, organization, or business account, which blocks the app from accessing the account's resources. When a GitHub App is suspended, the app's access to the GitHub Enterprise Cloud API or webhook events is blocked for that account.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#suspend-an-app-installation", "parameters": [ { - "name": "client_id", - "description": "The client ID of the GitHub app.", + "name": "installation_id", + "description": "The unique identifier of the installation.", "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "access_token", - "description": "The OAuth access token used to authenticate to the GitHub API.", - "in": "BODY", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -8541,24 +12962,21 @@ ], "responses": [ { "code": 204, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete an installation for the authenticated app", + "name": "Unsuspend an app installation", "scope": "apps", - "id": "deleteInstallation", + "id": "unsuspendInstallation", "method": "DELETE", - "url": "/app/installations/{installation_id}", + "url": "/app/installations/{installation_id}/suspended", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Uninstalls a GitHub App on a user, organization, or business account. If you prefer to temporarily suspend an app's access to your account's resources, then we recommend the \"[Suspend an app installation](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#suspend-an-app-installation)\" endpoint.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-installation-for-the-authenticated-app", + "description": "Removes a GitHub App installation suspension.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#unsuspend-an-app-installation", "parameters": [ { "name": "installation_id", @@ -8581,23 +12999,23 @@ "renamed": null }, { - "name": "Delete an app token", + "name": "Update a webhook configuration for an app", "scope": "apps", - "id": "deleteToken", - "method": "DELETE", - "url": "/applications/{client_id}/token", + "id": "updateWebhookConfigForApp", + "method": "PATCH", + "url": "/app/hook/config", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "OAuth application owners can revoke a single token for an OAuth application. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#delete-an-app-token", + "description": "Updates the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see \"[Creating a GitHub App](/developers/apps/creating-a-github-app).\"\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#update-a-webhook-configuration-for-an-app", "parameters": [ { - "name": "client_id", - "description": "The client ID of the GitHub app.", - "in": "PATH", + "name": "url", + "description": "The URL to which the payloads will be delivered.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -8606,94 +13024,37 @@ "deprecated": null }, { - "name": "access_token", - "description": "The OAuth access token used to authenticate to the GitHub API.", + "name": "content_type", + "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Get the authenticated app", - "scope": "apps", - "id": "getAuthenticated", - "method": "GET", - "url": "/app", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns the GitHub App associated with the authentication credentials used. To see how many app installations are associated with this GitHub App, see the `installations_count` in the response. For more details about your app's installations, see the \"[List installations for the authenticated app](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-installations-for-the-authenticated-app)\" endpoint.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-the-authenticated-app", - "parameters": [], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get an app", - "scope": "apps", - "id": "getBySlug", - "method": "GET", - "url": "/apps/{app_slug}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note**: The `:app_slug` is just the URL-friendly name of your GitHub App. You can find this on the settings page for your GitHub App (e.g., `https://github.com/settings/apps/:app_slug`).\n\nIf the GitHub App you specify is public, you can access this endpoint without authenticating. If the GitHub App you specify is private, you must authenticate with a [personal access token](https://docs.github.com/articles/creating-a-personal-access-token-for-the-command-line/) or an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps/#get-an-app", - "parameters": [ + }, { - "name": "app_slug", - "description": "", - "in": "PATH", + "name": "secret", + "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get an installation for the authenticated app", - "scope": "apps", - "id": "getInstallation", - "method": "GET", - "url": "/app/installations/{installation_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Enables an authenticated GitHub App to find an installation's information using the installation id.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-an-installation-for-the-authenticated-app", - "parameters": [ + }, { - "name": "installation_id", - "description": "The unique identifier of the installation.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "insecure_ssl", + "description": "", + "in": "BODY", + "type": null, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -8702,23 +13063,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, - { - "name": "Get an organization installation for the authenticated app", - "scope": "apps", - "id": "getOrgInstallation", + { + "name": "Get GitHub Actions billing for an organization", + "scope": "billing", + "id": "getGithubActionsBillingOrg", "method": "GET", - "url": "/orgs/{org}/installation", + "url": "/orgs/{org}/settings/billing/actions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables an authenticated GitHub App to find the organization's installation information.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-an-organization-installation-for-the-authenticated-app", + "description": "Gets the summary of the free and paid GitHub Actions minutes used.\n\nPaid minutes only apply to workflows in private repositories that use GitHub-hosted runners. Minutes used is listed for each GitHub-hosted runner operating system. Any job re-runs are also included in the usage. The usage returned includes any minute multipliers for macOS and Windows runners, and is rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAccess tokens must have the `repo` or `admin:org` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-actions-billing-for-an-organization", "parameters": [ { "name": "org", @@ -8738,20 +13096,20 @@ "renamed": null }, { - "name": "Get a repository installation for the authenticated app", - "scope": "apps", - "id": "getRepoInstallation", + "name": "Get GitHub Actions billing for a user", + "scope": "billing", + "id": "getGithubActionsBillingUser", "method": "GET", - "url": "/repos/{owner}/{repo}/installation", + "url": "/users/{username}/settings/billing/actions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables an authenticated GitHub App to find the repository's installation information. The installation's account type will be either an organization or a user account, depending which account the repository belongs to.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-repository-installation-for-the-authenticated-app", + "description": "Gets the summary of the free and paid GitHub Actions minutes used.\n\nPaid minutes only apply to workflows in private repositories that use GitHub-hosted runners. Minutes used is listed for each GitHub-hosted runner operating system. Any job re-runs are also included in the usage. The usage returned includes any minute multipliers for macOS and Windows runners, and is rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAccess tokens must have the `user` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-actions-billing-for-a-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -8761,10 +13119,26 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get GitHub Packages billing for an organization", + "scope": "billing", + "id": "getGithubPackagesBillingOrg", + "method": "GET", + "url": "/orgs/{org}/settings/billing/packages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the free and paid storage used for GitHub Packages in gigabytes.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `repo` or `admin:org` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-packages-billing-for-an-organization", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -8776,30 +13150,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a subscription plan for an account", - "scope": "apps", - "id": "getSubscriptionPlanForAccount", + "name": "Get GitHub Packages billing for a user", + "scope": "billing", + "id": "getGithubPackagesBillingUser", "method": "GET", - "url": "/marketplace_listing/accounts/{account_id}", + "url": "/users/{username}/settings/billing/packages", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Shows whether the user or organization account actively subscribes to a plan listed by the authenticated GitHub App. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-subscription-plan-for-an-account", + "description": "Gets the free and paid storage used for GitHub Packages in gigabytes.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `user` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-packages-billing-for-a-user", "parameters": [ { - "name": "account_id", - "description": "account_id parameter", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -8809,33 +13179,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { - "code": 404, - "description": "Not Found when the account has not purchased the listing" - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a subscription plan for an account (stubbed)", - "scope": "apps", - "id": "getSubscriptionPlanForAccountStubbed", + "name": "Get shared storage billing for an organization", + "scope": "billing", + "id": "getSharedStorageBillingOrg", "method": "GET", - "url": "/marketplace_listing/stubbed/accounts/{account_id}", + "url": "/orgs/{org}/settings/billing/shared-storage", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Shows whether the user or organization account actively subscribes to a plan listed by the authenticated GitHub App. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-subscription-plan-for-an-account-stubbed", + "description": "Gets the estimated paid and estimated total storage used for GitHub Actions and GitHub Packages.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `repo` or `admin:org` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-shared-storage-billing-for-an-organization", "parameters": [ { - "name": "account_id", - "description": "account_id parameter", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -8845,27 +13208,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { - "code": 404, - "description": "Not Found when the account has not purchased the listing" - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a user installation for the authenticated app", - "scope": "apps", - "id": "getUserInstallation", + "name": "Get shared storage billing for a user", + "scope": "billing", + "id": "getSharedStorageBillingUser", "method": "GET", - "url": "/users/{username}/installation", + "url": "/users/{username}/settings/billing/shared-storage", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables an authenticated GitHub App to find the user’s installation information.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-user-installation-for-the-authenticated-app", + "description": "Gets the estimated paid and estimated total storage used for GitHub Actions and GitHub Packages.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `user` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-shared-storage-billing-for-a-user", "parameters": [ { "name": "username", @@ -8885,37 +13241,22 @@ "renamed": null }, { - "name": "Get a webhook configuration for an app", - "scope": "apps", - "id": "getWebhookConfigForApp", - "method": "GET", - "url": "/app/hook/config", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see \"[Creating a GitHub App](/developers/apps/creating-a-github-app).\"\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-webhook-configuration-for-an-app", - "parameters": [], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a delivery for an app webhook", - "scope": "apps", - "id": "getWebhookDelivery", - "method": "GET", - "url": "/app/hook/deliveries/{delivery_id}", + "name": "Create a check run", + "scope": "checks", + "id": "create", + "method": "POST", + "url": "/repos/{owner}/{repo}/check-runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a delivery for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#get-a-delivery-for-an-app-webhook", + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nCreates a new check run for a specific commit in a repository. Your GitHub App must have the `checks:write` permission to create check runs.\n\nIn a check suite, GitHub limits the number of check runs with the same name to 1000. Once these check runs exceed 1000, GitHub will start to automatically delete older check runs.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-run", "parameters": [ { - "name": "delivery_id", - "description": "", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -8923,36 +13264,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "List accounts for a plan", - "scope": "apps", - "id": "listAccountsForPlan", - "method": "GET", - "url": "/marketplace_listing/plans/{plan_id}/accounts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns user and organization accounts associated with the specified plan, including free plans. For per-seat pricing, you see the list of accounts that have purchased the plan, including the number of seats purchased. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-accounts-for-a-plan", - "parameters": [ + }, { - "name": "plan_id", - "description": "The unique identifier of the plan.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -8962,12 +13279,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", - "type": "string", + "name": "status", + "description": "", + "in": "BODY", + "type": null, "required": false, - "enum": ["created", "updated"], + "enum": ["queued", "in_progress"], "allowNull": false, "mapToData": null, "validation": null, @@ -8975,12 +13292,41 @@ "deprecated": null }, { - "name": "direction", - "description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.", - "in": "QUERY", - "type": "string", + "name": "*", + "description": "", + "in": "BODY", + "type": "object", "required": false, - "enum": ["asc", "desc"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 201, "description": "Response" }], + "renamed": null + }, + { + "name": "Create a check suite", + "scope": "checks", + "id": "createSuite", + "method": "POST", + "url": "/repos/{owner}/{repo}/check-suites", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nBy default, check suites are automatically created when you create a [check run](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#check-runs). You only need to use this endpoint for manually creating check suites when you've disabled automatic creation using \"[Update repository preferences for check suites](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-repository-preferences-for-check-suites)\". Your GitHub App must have the `checks:write` permission to create check suites.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-suite", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -8988,11 +13334,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9001,11 +13347,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "head_sha", + "description": "The sha of the head commit.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9015,33 +13361,28 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response when the suite already exists" }, + { "code": 201, "description": "Response when the suite was created" } ], "renamed": null }, { - "name": "List accounts for a plan (stubbed)", - "scope": "apps", - "id": "listAccountsForPlanStubbed", + "name": "Get a check run", + "scope": "checks", + "id": "get", "method": "GET", - "url": "/marketplace_listing/stubbed/plans/{plan_id}/accounts", + "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns repository and organization accounts associated with the specified plan, including free plans. For per-seat pricing, you see the list of accounts that have purchased the plan, including the number of seats purchased. When someone submits a plan change that won't be processed until the end of their billing cycle, you will also see the upcoming pending change.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-accounts-for-a-plan-stubbed", + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nGets a single check run using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#get-a-check-run", "parameters": [ { - "name": "plan_id", - "description": "The unique identifier of the plan.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -9051,12 +13392,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9064,12 +13405,41 @@ "deprecated": null }, { - "name": "direction", - "description": "To return the oldest accounts first, set to `asc`. Ignored without the `sort` parameter.", - "in": "QUERY", + "name": "check_run_id", + "description": "The unique identifier of the check run.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a check suite", + "scope": "checks", + "id": "getSuite", + "method": "GET", + "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nGets a single check suite using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check suites. OAuth Apps and authenticated users must have the `repo` scope to get check suites in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#get-a-check-suite", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9077,11 +13447,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9090,11 +13460,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "check_suite_id", + "description": "The unique identifier of the check suite.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9103,27 +13473,50 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List repositories accessible to the user access token", - "scope": "apps", - "id": "listInstallationReposForAuthenticatedUser", + "name": "List check run annotations", + "scope": "checks", + "id": "listAnnotations", "method": "GET", - "url": "/user/installations/{installation_id}/repositories", + "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}/annotations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List repositories that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access for an installation.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.\n\nYou must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint.\n\nThe access the user has to each repository is included in the hash under the `permissions` key.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-repositories-accessible-to-the-user-access-token", + "description": "Lists annotations for a check run using the annotation `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get annotations for a check run. OAuth Apps and authenticated users must have the `repo` scope to get annotations for a check run in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-run-annotations", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "check_run_id", + "description": "The unique identifier of the check run.", "in": "PATH", "type": "integer", "required": true, @@ -9161,35 +13554,27 @@ "deprecated": null } ], - "responses": [ - { - "code": 200, - "description": "The access the user has to each repository is included in the hash under the `permissions` key." - }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List installations for the authenticated app", - "scope": "apps", - "id": "listInstallations", + "name": "List check runs for a Git reference", + "scope": "checks", + "id": "listForRef", "method": "GET", - "url": "/app/installations", + "url": "/repos/{owner}/{repo}/commits/{ref}/check-runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.\n\nThe permissions the installation has are included under the `permissions` key.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-installations-for-the-authenticated-app", + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nLists check runs for a commit ref. The `ref` can be a SHA, branch name, or a tag name. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-runs-for-a-git-reference", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9198,11 +13583,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9211,11 +13596,11 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "ref", + "description": "ref parameter", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9224,8 +13609,8 @@ "deprecated": null }, { - "name": "outdated", - "description": "", + "name": "check_name", + "description": "Returns check runs with the specified `name`.", "in": "QUERY", "type": "string", "required": false, @@ -9235,35 +13620,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 200, - "description": "The permissions the installation has are included under the `permissions` key." - } - ], - "renamed": null - }, - { - "name": "List app installations accessible to the user access token", - "scope": "apps", - "id": "listInstallationsForAuthenticatedUser", - "method": "GET", - "url": "/user/installations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists installations of your GitHub App that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access.\n\nYou must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.\n\nYou can find the permissions for the installation under the `permissions` key.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-app-installations-accessible-to-the-user-access-token", - "parameters": [ + }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "status", + "description": "Returns check runs with the specified `status`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["queued", "in_progress", "completed"], "allowNull": false, "mapToData": null, "validation": null, @@ -9271,42 +13635,18 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "filter", + "description": "Filters check runs by their `completed_at` timestamp. `latest` returns the most recent check runs.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["latest", "all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 200, - "description": "You can find the permissions for the installation under the `permissions` key." }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "List plans", - "scope": "apps", - "id": "listPlans", - "method": "GET", - "url": "/marketplace_listing/plans", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all plans that are part of your GitHub Enterprise Cloud Marketplace listing.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-plans", - "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -9321,8 +13661,21 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "app_id", + "description": "", "in": "QUERY", "type": "integer", "required": false, @@ -9334,31 +13687,53 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List plans (stubbed)", - "scope": "apps", - "id": "listPlansStubbed", + "name": "List check runs in a check suite", + "scope": "checks", + "id": "listForSuite", "method": "GET", - "url": "/marketplace_listing/stubbed/plans", + "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all plans that are part of your GitHub Enterprise Cloud Marketplace listing.\n\nGitHub Apps must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint. OAuth Apps must use [basic authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) with their client ID and client secret to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-plans-stubbed", + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nLists check runs for a check suite using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-runs-in-a-check-suite", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "check_suite_id", + "description": "The unique identifier of the check suite.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9367,10 +13742,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "check_name", + "description": "Returns check runs with the specified `name`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -9378,33 +13753,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" } - ], - "renamed": null - }, - { - "name": "List repositories accessible to the app installation", - "scope": "apps", - "id": "listReposAccessibleToInstallation", - "method": "GET", - "url": "/installation/repositories", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List repositories that an app installation can access.\n\nYou must use an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-repositories-accessible-to-the-app-installation", - "parameters": [ + }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "status", + "description": "Returns check runs with the specified `status`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["queued", "in_progress", "completed"], "allowNull": false, "mapToData": null, "validation": null, @@ -9412,39 +13768,18 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "filter", + "description": "Filters check runs by their `completed_at` timestamp. `latest` returns the most recent check runs.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["latest", "all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "List subscriptions for the authenticated user", - "scope": "apps", - "id": "listSubscriptionsForAuthenticatedUser", - "method": "GET", - "url": "/user/marketplace_purchases", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the active subscriptions for the authenticated user. You must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint. . OAuth Apps must authenticate using an [OAuth token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-subscriptions-for-the-authenticated-user", - "parameters": [ + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -9472,29 +13807,63 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List subscriptions for the authenticated user (stubbed)", - "scope": "apps", - "id": "listSubscriptionsForAuthenticatedUserStubbed", + "name": "List check suites for a Git reference", + "scope": "checks", + "id": "listSuitesForRef", "method": "GET", - "url": "/user/marketplace_purchases/stubbed", + "url": "/repos/{owner}/{repo}/commits/{ref}/check-suites", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the active subscriptions for the authenticated user. You must use a [user-to-server OAuth access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/identifying-and-authorizing-users-for-github-apps/#identifying-users-on-your-site), created for a user who has authorized your GitHub App, to access this endpoint. . OAuth Apps must authenticate using an [OAuth token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-subscriptions-for-the-authenticated-user-stubbed", + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nLists check suites for a commit `ref`. The `ref` can be a SHA, branch name, or a tag name. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to list check suites. OAuth Apps and authenticated users must have the `repo` scope to get check suites in a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-suites-for-a-git-reference", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ref", + "description": "ref parameter", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "app_id", + "description": "Filters check suites by GitHub App `id`.", "in": "QUERY", "type": "integer", "required": false, @@ -9506,10 +13875,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "check_name", + "description": "Returns check runs with the specified `name`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -9517,27 +13886,7 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" } - ], - "renamed": null - }, - { - "name": "List deliveries for an app webhook", - "scope": "apps", - "id": "listWebhookDeliveries", - "method": "GET", - "url": "/app/hook/deliveries", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns a list of webhook deliveries for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#list-deliveries-for-an-app-webhook", - "parameters": [ + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -9552,10 +13901,10 @@ "deprecated": null }, { - "name": "cursor", - "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -9565,34 +13914,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Redeliver a delivery for an app webhook", - "scope": "apps", - "id": "redeliverWebhookDelivery", + "name": "Rerequest a check run", + "scope": "checks", + "id": "rerequestRun", "method": "POST", - "url": "/app/hook/deliveries/{delivery_id}/attempts", + "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}/rerequest", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Redeliver a delivery for the webhook configured for a GitHub App.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#redeliver-a-delivery-for-an-app-webhook", + "description": "Triggers GitHub to rerequest an existing check run, without pushing new code to a repository. This endpoint will trigger the [`check_run` webhook](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#check_run) event with the action `rerequested`. When a check run is `rerequested`, its `status` is reset to `queued` and the `conclusion` is cleared.\n\nTo rerequest a check run, your GitHub App must have the `checks:read` permission on a private repository or pull access to a public repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#rerequest-a-check-run", "parameters": [ { - "name": "delivery_id", - "description": "", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -9600,36 +13941,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 202, "description": "Accepted" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Remove a repository from an app installation", - "scope": "apps", - "id": "removeRepoFromInstallation", - "method": "DELETE", - "url": "/user/installations/{installation_id}/repositories/{repository_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Remove a single repository from an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#remove-a-repository-from-an-app-installation", - "parameters": [ + }, { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -9639,8 +13956,8 @@ "deprecated": null }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "check_run_id", + "description": "The unique identifier of the check run.", "in": "PATH", "type": "integer", "required": true, @@ -9653,38 +13970,36 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": { - "before": { "scope": "apps", "id": "removeRepoFromInstallation" }, - "after": { - "scope": "apps", - "id": "removeRepoFromInstallationForAuthenticatedUser" + { "code": 201, "description": "Response" }, + { + "code": 403, + "description": "Forbidden if the check run is not rerequestable or doesn't belong to the authenticated GitHub App" }, - "date": "2021-10-05", - "note": null - } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation error if the check run is not rerequestable" + } + ], + "renamed": null }, { - "name": "Remove a repository from an app installation", - "scope": "apps", - "id": "removeRepoFromInstallationForAuthenticatedUser", - "method": "DELETE", - "url": "/user/installations/{installation_id}/repositories/{repository_id}", + "name": "Rerequest a check suite", + "scope": "checks", + "id": "rerequestSuite", + "method": "POST", + "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}/rerequest", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove a single repository from an installation. The authenticated user must have admin access to the repository.\n\nYou must use a personal access token (which you can create via the [command line](https://docs.github.com/enterprise-cloud@latest//github/authenticating-to-github/creating-a-personal-access-token) or [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication)) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#remove-a-repository-from-an-app-installation", + "description": "Triggers GitHub to rerequest an existing check suite, without pushing new code to a repository. This endpoint will trigger the [`check_suite` webhook](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#check_suite) event with the action `rerequested`. When a check suite is `rerequested`, its `status` is reset to `queued` and the `conclusion` is cleared.\n\nTo rerequest a check suite, your GitHub App must have the `checks:read` permission on a private repository or pull access to a public repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#rerequest-a-check-suite", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -9694,8 +14009,21 @@ "deprecated": null }, { - "name": "repository_id", - "description": "The unique identifier of the repository.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "check_suite_id", + "description": "The unique identifier of the check suite.", "in": "PATH", "type": "integer", "required": true, @@ -9707,29 +14035,24 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "Reset a token", - "scope": "apps", - "id": "resetToken", + "name": "Update repository preferences for check suites", + "scope": "checks", + "id": "setSuitesPreferences", "method": "PATCH", - "url": "/applications/{client_id}/token", + "url": "/repos/{owner}/{repo}/check-suites/preferences", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "OAuth applications can use this API method to reset a valid OAuth token without end-user involvement. Applications must save the \"token\" property in the response because changes take effect immediately. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#reset-a-token", + "description": "Changes the default automatic flow when creating check suites. By default, a check suite is automatically created each time code is pushed to a repository. When you disable the automatic creation of check suites, you can manually [Create a check suite](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-suite). You must have admin permissions in the repository to set preferences for check suites.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-repository-preferences-for-check-suites", "parameters": [ { - "name": "client_id", - "description": "The client ID of the GitHub app.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -9741,9 +14064,9 @@ "deprecated": null }, { - "name": "access_token", - "description": "The access_token of the OAuth application.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -9752,50 +14075,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Revoke an installation access token", - "scope": "apps", - "id": "revokeInstallationAccessToken", - "method": "DELETE", - "url": "/installation/token", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Revokes the installation token you're using to authenticate as an installation and access this endpoint.\n\nOnce an installation token is revoked, the token is invalidated and cannot be used. Other endpoints that require the revoked installation token must have a new installation token to work. You can create a new token using the \"[Create an installation access token for an app](https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#create-an-installation-access-token-for-an-app)\" endpoint.\n\nYou must use an [installation access token](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-an-installation) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#revoke-an-installation-access-token", - "parameters": [], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Create a scoped access token", - "scope": "apps", - "id": "scopeToken", - "method": "POST", - "url": "/applications/{client_id}/token/scoped", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Use a non-scoped user-to-server OAuth access token to create a repository scoped and/or permission scoped user-to-server OAuth access token. You can specify which repositories the token can access and which permissions are granted to the token. You must use [Basic Authentication](https://docs.github.com/enterprise-cloud@latest//rest/overview/other-authentication-methods#basic-authentication) when accessing this endpoint, using the OAuth application's `client_id` and `client_secret` as the username and password. Invalid tokens will return `404 NOT FOUND`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#create-a-scoped-access-token", - "parameters": [ + }, { - "name": "client_id", - "description": "The client ID of the GitHub app.", - "in": "PATH", - "type": "string", - "required": true, + "name": "auto_trigger_checks", + "description": "Enables or disables automatic creation of CheckSuite events upon pushes to the repository. Enabled by default.", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -9804,10 +14090,10 @@ "deprecated": null }, { - "name": "access_token", - "description": "The OAuth access token used to authenticate to the GitHub API.", + "name": "auto_trigger_checks[].app_id", + "description": "The `id` of the GitHub App.", "in": "BODY", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -9817,11 +14103,40 @@ "deprecated": null }, { - "name": "target", - "description": "The name of the user or organization to scope the user-to-server access token to. **Required** unless `target_id` is specified.", + "name": "auto_trigger_checks[].setting", + "description": "Set to `true` to enable automatic creation of CheckSuite events upon pushes to the repository, or `false` to disable them.", "in": "BODY", + "type": "boolean", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Update a check run", + "scope": "checks", + "id": "update", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nUpdates a check run for a specific commit in a repository. Your GitHub App must have the `checks:write` permission to edit check runs.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-a-check-run", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9830,11 +14145,11 @@ "deprecated": null }, { - "name": "target_id", - "description": "The ID of the user or organization to scope the user-to-server access token to. **Required** unless `target` is specified.", - "in": "BODY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9843,11 +14158,11 @@ "deprecated": null }, { - "name": "repositories", - "description": "The list of repository names to scope the user-to-server access token to. `repositories` may not be specified if `repository_ids` is specified.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "check_run_id", + "description": "The unique identifier of the check run.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -9856,10 +14171,10 @@ "deprecated": null }, { - "name": "repository_ids", - "description": "The list of repository IDs to scope the user-to-server access token to. `repository_ids` may not be specified if `repositories` is specified.", + "name": "name", + "description": "The name of the check. For example, \"code-coverage\".", "in": "BODY", - "type": "integer[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -9869,10 +14184,10 @@ "deprecated": null }, { - "name": "permissions", - "description": "The permissions granted to the user-to-server access token.", + "name": "details_url", + "description": "The URL of the integrator's site that has the full details of the check.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -9882,12 +14197,12 @@ "deprecated": null }, { - "name": "permissions.actions", - "description": "The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.", + "name": "external_id", + "description": "A reference for the run on the integrator's system.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9895,12 +14210,12 @@ "deprecated": null }, { - "name": "permissions.administration", - "description": "The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.", + "name": "started_at", + "description": "This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9908,12 +14223,12 @@ "deprecated": null }, { - "name": "permissions.checks", - "description": "The level of permission to grant the access token for checks on code.", + "name": "status", + "description": "The current status.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": ["queued", "in_progress", "completed"], "allowNull": false, "mapToData": null, "validation": null, @@ -9921,12 +14236,21 @@ "deprecated": null }, { - "name": "permissions.contents", - "description": "The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.", + "name": "conclusion", + "description": "**Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. \n**Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": [ + "action_required", + "cancelled", + "failure", + "neutral", + "success", + "skipped", + "stale", + "timed_out" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -9934,12 +14258,12 @@ "deprecated": null }, { - "name": "permissions.deployments", - "description": "The level of permission to grant the access token for deployments and deployment statuses.", + "name": "completed_at", + "description": "The time the check completed. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9947,12 +14271,12 @@ "deprecated": null }, { - "name": "permissions.environments", - "description": "The level of permission to grant the access token for managing repository environments.", + "name": "output", + "description": "Check runs can accept a variety of data in the `output` object, including a `title` and `summary` and can optionally provide descriptive details about the run.", "in": "BODY", - "type": "string", + "type": "object", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9960,12 +14284,12 @@ "deprecated": null }, { - "name": "permissions.issues", - "description": "The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.", + "name": "output.title", + "description": "**Required**.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9973,12 +14297,12 @@ "deprecated": null }, { - "name": "permissions.metadata", - "description": "The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.", + "name": "output.summary", + "description": "Can contain Markdown.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9986,12 +14310,12 @@ "deprecated": null }, { - "name": "permissions.packages", - "description": "The level of permission to grant the access token for packages published to GitHub Packages.", + "name": "output.text", + "description": "Can contain Markdown.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -9999,12 +14323,12 @@ "deprecated": null }, { - "name": "permissions.pages", - "description": "The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.", + "name": "output.annotations", + "description": "Adds information from your analysis to specific lines of code. Annotations are visible in GitHub's pull request UI. Annotations are visible in GitHub's pull request UI. The Checks API limits the number of annotations to a maximum of 50 per API request. To create more than 50 annotations, you have to make multiple requests to the [Update a check run](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-a-check-run) endpoint. Each time you update the check run, annotations are appended to the list of annotations that already exist for the check run. GitHub Actions are limited to 10 warning annotations and 10 error annotations per step. For details about annotations in the UI, see \"[About status checks](https://docs.github.com/enterprise-cloud@latest//articles/about-status-checks#checks)\".", "in": "BODY", - "type": "string", + "type": "object[]", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10012,12 +14336,12 @@ "deprecated": null }, { - "name": "permissions.pull_requests", - "description": "The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.", + "name": "output.annotations[].path", + "description": "The path of the file to add an annotation to. For example, `assets/css/main.css`.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10025,12 +14349,12 @@ "deprecated": null }, { - "name": "permissions.repository_hooks", - "description": "The level of permission to grant the access token to manage the post-receive hooks for a repository.", + "name": "output.annotations[].start_line", + "description": "The start line of the annotation. Line numbers start at 1.", "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write"], + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10038,12 +14362,12 @@ "deprecated": null }, { - "name": "permissions.repository_projects", - "description": "The level of permission to grant the access token to manage repository projects, columns, and cards.", + "name": "output.annotations[].end_line", + "description": "The end line of the annotation.", "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write", "admin"], + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10051,12 +14375,12 @@ "deprecated": null }, { - "name": "permissions.secret_scanning_alerts", - "description": "The level of permission to grant the access token to view and manage secret scanning alerts.", + "name": "output.annotations[].start_column", + "description": "The start column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values. Column numbers start at 1.", "in": "BODY", - "type": "string", + "type": "integer", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10064,12 +14388,12 @@ "deprecated": null }, { - "name": "permissions.secrets", - "description": "The level of permission to grant the access token to manage repository secrets.", + "name": "output.annotations[].end_column", + "description": "The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values.", "in": "BODY", - "type": "string", + "type": "integer", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10077,12 +14401,12 @@ "deprecated": null }, { - "name": "permissions.security_events", - "description": "The level of permission to grant the access token to view and manage security events like code scanning alerts.", + "name": "output.annotations[].annotation_level", + "description": "The level of the annotation.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": ["notice", "warning", "failure"], "allowNull": false, "mapToData": null, "validation": null, @@ -10090,12 +14414,12 @@ "deprecated": null }, { - "name": "permissions.single_file", - "description": "The level of permission to grant the access token to manage just a single file.", + "name": "output.annotations[].message", + "description": "A short description of the feedback for these lines of code. The maximum size is 64 KB.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10103,12 +14427,12 @@ "deprecated": null }, { - "name": "permissions.statuses", - "description": "The level of permission to grant the access token for commit statuses.", + "name": "output.annotations[].title", + "description": "The title that represents the annotation. The maximum size is 255 characters.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10116,12 +14440,12 @@ "deprecated": null }, { - "name": "permissions.vulnerability_alerts", - "description": "The level of permission to grant the access token to manage Dependabot alerts.", + "name": "output.annotations[].raw_details", + "description": "Details about this annotation. The maximum size is 64 KB.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10129,12 +14453,12 @@ "deprecated": null }, { - "name": "permissions.workflows", - "description": "The level of permission to grant the access token to update GitHub Actions workflow files.", + "name": "output.images", + "description": "Adds images to the output displayed in the GitHub pull request UI.", "in": "BODY", - "type": "string", + "type": "object[]", "required": false, - "enum": ["write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10142,12 +14466,12 @@ "deprecated": null }, { - "name": "permissions.members", - "description": "The level of permission to grant the access token for organization teams and members.", + "name": "output.images[].alt", + "description": "The alternative text for the image.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10155,12 +14479,12 @@ "deprecated": null }, { - "name": "permissions.organization_administration", - "description": "The level of permission to grant the access token to manage access to an organization.", + "name": "output.images[].image_url", + "description": "The full URL of the image.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10168,12 +14492,12 @@ "deprecated": null }, { - "name": "permissions.organization_custom_roles", - "description": "The level of permission to grant the access token for custom roles management. This property is in beta and is subject to change.", + "name": "output.images[].caption", + "description": "A short image description.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10181,12 +14505,12 @@ "deprecated": null }, { - "name": "permissions.organization_hooks", - "description": "The level of permission to grant the access token to manage the post-receive hooks for an organization.", + "name": "actions", + "description": "Possible further actions the integrator can perform, which a user may trigger. Each action includes a `label`, `identifier` and `description`. A maximum of three actions are accepted. See the [`actions` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#actions-object) description. To learn more about check runs and requested actions, see \"[Check runs and requested actions](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#check-runs-and-requested-actions).\"", "in": "BODY", - "type": "string", + "type": "object[]", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10194,12 +14518,12 @@ "deprecated": null }, { - "name": "permissions.organization_plan", - "description": "The level of permission to grant the access token for viewing an organization's plan.", + "name": "actions[].label", + "description": "The text to be displayed on a button in the web UI. The maximum size is 20 characters.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10207,12 +14531,12 @@ "deprecated": null }, { - "name": "permissions.organization_projects", - "description": "The level of permission to grant the access token to manage organization projects and projects beta (where available).", + "name": "actions[].description", + "description": "A short explanation of what this action would do. The maximum size is 40 characters.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write", "admin"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10220,25 +14544,41 @@ "deprecated": null }, { - "name": "permissions.organization_packages", - "description": "The level of permission to grant the access token for organization packages published to GitHub Packages.", + "name": "actions[].identifier", + "description": "A reference for the action on the integrator's system. The maximum size is 20 characters.", "in": "BODY", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a code scanning analysis from a repository", + "scope": "codeScanning", + "id": "deleteAnalysis", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}{?confirm_delete}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` scope.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `category`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set:\n`next_analysis_url` and `confirm_delete_url`.\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin a set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find an analysis that's identified as deletable.\nEach set of analyses always has one that's identified as deletable.\nHaving found the deletable analysis for one of the two sets,\ndelete this analysis and then continue deleting the next analysis in the set until they're all deleted.\nThen repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#delete-a-code-scanning-analysis-from-a-repository", + "parameters": [ { - "name": "permissions.organization_secrets", - "description": "The level of permission to grant the access token to manage organization secrets.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10246,12 +14586,12 @@ "deprecated": null }, { - "name": "permissions.organization_self_hosted_runners", - "description": "The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["read", "write"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10259,12 +14599,12 @@ "deprecated": null }, { - "name": "permissions.organization_user_blocking", - "description": "The level of permission to grant the access token to view and manage users blocked by the organization.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["read", "write"], + "name": "analysis_id", + "description": "The ID of the analysis, as returned from the `GET /repos/{owner}/{repo}/code-scanning/analyses` operation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10272,12 +14612,12 @@ "deprecated": null }, { - "name": "permissions.team_discussions", - "description": "The level of permission to grant the access token to manage team discussions and related comments.", - "in": "BODY", + "name": "confirm_delete", + "description": "Allow deletion if the specified analysis is the last in a set. If you attempt to delete the final analysis in a set without setting this parameter to `true`, you'll get a 400 response with the message: `Analysis is last of its type and deletion may result in the loss of historical alert data. Please specify confirm_delete.`", + "in": "QUERY", "type": "string", "required": false, - "enum": ["read", "write"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10287,31 +14627,58 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + "code": 403, + "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Suspend an app installation", - "scope": "apps", - "id": "suspendInstallation", - "method": "PUT", - "url": "/app/installations/{installation_id}/suspended", + "name": "Get a code scanning alert", + "scope": "codeScanning", + "id": "getAlert", + "method": "GET", + "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Suspends a GitHub App on a user, organization, or business account, which blocks the app from accessing the account's resources. When a GitHub App is suspended, the app's access to the GitHub Enterprise Cloud API or webhook events is blocked for that account.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#suspend-an-app-installation", + "description": "Gets a single code scanning alert. You must use an access token with the `security_events` scope to use this endpoint with private repos, the `public_repo` scope also grants permission to read security events on public repos only. GitHub Apps must have the `security_events` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-a-code-scanning-alert", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", "in": "PATH", "type": "integer", "required": true, @@ -10321,29 +14688,74 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "alert_id", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "in": "PATH", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": "alert_number", + "deprecated": true } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Unsuspend an app installation", - "scope": "apps", - "id": "unsuspendInstallation", - "method": "DELETE", - "url": "/app/installations/{installation_id}/suspended", + "name": "Get a code scanning analysis for a repository", + "scope": "codeScanning", + "id": "getAnalysis", + "method": "GET", + "url": "/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes a GitHub App installation suspension.\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#unsuspend-an-app-installation", + "description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-a-code-scanning-analysis-for-a-repository", "parameters": [ { - "name": "installation_id", - "description": "The unique identifier of the installation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "analysis_id", + "description": "The ID of the analysis, as returned from the `GET /repos/{owner}/{repo}/code-scanning/analyses` operation.", "in": "PATH", "type": "integer", "required": true, @@ -10356,29 +14768,35 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Update a webhook configuration for an app", - "scope": "apps", - "id": "updateWebhookConfigForApp", - "method": "PATCH", - "url": "/app/hook/config", + "name": "Get a CodeQL database for a repository", + "scope": "codeScanning", + "id": "getCodeqlDatabase", + "method": "GET", + "url": "/repos/{owner}/{repo}/code-scanning/codeql/databases/{language}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates the webhook configuration for a GitHub App. For more information about configuring a webhook for your app, see \"[Creating a GitHub App](/developers/apps/creating-a-github-app).\"\n\nYou must use a [JWT](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/apps#update-a-webhook-configuration-for-an-app", + "description": "Gets a CodeQL database for a language in a repository.\n\nBy default this endpoint returns JSON metadata about the CodeQL database. To\ndownload the CodeQL database binary content, set the `Accept` header of the request\nto [`application/zip`](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types), and make sure\nyour HTTP client is configured to follow redirects or use the `Location` header\nto make a second request to get the redirect URL.\n\nFor private repositories, you must use an access token with the `security_events` scope.\nFor public repositories, you can use tokens with the `security_events` or `public_repo` scope.\nGitHub Apps must have the `contents` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-a-codeql-database-for-a-repository", "parameters": [ { - "name": "url", - "description": "The URL to which the payloads will be delivered.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -10387,11 +14805,11 @@ "deprecated": null }, { - "name": "content_type", - "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -10400,24 +14818,11 @@ "deprecated": null }, { - "name": "secret", - "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", - "in": "BODY", + "name": "language", + "description": "The language of the CodeQL database.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "insecure_ssl", - "description": "", - "in": "BODY", - "type": null, - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -10426,24 +14831,46 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 302, "description": "Found" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Get GitHub Actions billing for an organization", - "scope": "billing", - "id": "getGithubActionsBillingOrg", + "name": "Get a code scanning default setup configuration", + "scope": "codeScanning", + "id": "getDefaultSetup", "method": "GET", - "url": "/orgs/{org}/settings/billing/actions", + "url": "/repos/{owner}/{repo}/code-scanning/default-setup", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the summary of the free and paid GitHub Actions minutes used.\n\nPaid minutes only apply to workflows in private repositories that use GitHub-hosted runners. Minutes used is listed for each GitHub-hosted runner operating system. Any job re-runs are also included in the usage. The usage returned includes any minute multipliers for macOS and Windows runners, and is rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAccess tokens must have the `repo` or `admin:org` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-actions-billing-for-an-organization", + "description": "Gets a code scanning default setup configuration.\nYou must use an access token with the `repo` scope to use this endpoint with private repos or the `public_repo`\nscope for public repos. GitHub Apps must have the `repo` write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/code-scanning#get-a-code-scanning-default-setup-configuration", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -10455,24 +14882,58 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Get GitHub Actions billing for a user", - "scope": "billing", - "id": "getGithubActionsBillingUser", + "name": "Get information about a SARIF upload", + "scope": "codeScanning", + "id": "getSarif", "method": "GET", - "url": "/users/{username}/settings/billing/actions", + "url": "/repos/{owner}/{repo}/code-scanning/sarifs/{sarif_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the summary of the free and paid GitHub Actions minutes used.\n\nPaid minutes only apply to workflows in private repositories that use GitHub-hosted runners. Minutes used is listed for each GitHub-hosted runner operating system. Any job re-runs are also included in the usage. The usage returned includes any minute multipliers for macOS and Windows runners, and is rounded up to the nearest whole minute. For more information, see \"[Managing billing for GitHub Actions](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-actions)\".\n\nAccess tokens must have the `user` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-actions-billing-for-a-user", + "description": "Gets information about a SARIF upload, including the status and the URL of the analysis that was uploaded so that you can retrieve details of the analysis. For more information, see \"[Get a code scanning analysis for a repository](/rest/reference/code-scanning#get-a-code-scanning-analysis-for-a-repository).\" You must use an access token with the `security_events` scope to use this endpoint with private repos, the `public_repo` scope also grants permission to read security events on public repos only. GitHub Apps must have the `security_events` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-information-about-a-sarif-upload", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sarif_id", + "description": "The SARIF ID obtained after uploading.", "in": "PATH", "type": "string", "required": true, @@ -10484,24 +14945,35 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { + "code": 404, + "description": "Not Found if the sarif id does not match any upload" + }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Get GitHub Advanced Security active committers for an enterprise", - "scope": "billing", - "id": "getGithubAdvancedSecurityBillingGhe", + "name": "List instances of a code scanning alert", + "scope": "codeScanning", + "id": "listAlertInstances", "method": "GET", - "url": "/enterprises/{enterprise}/settings/billing/advanced-security", + "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the GitHub Advanced Security active committers for an enterprise per repository.\n\nEach distinct user login across all repositories is counted as a single Advanced Security seat, so the `total_advanced_security_committers` is not the sum of active_users for each repository.\n\nThe total number of repositories with committer information is tracked by the `total_count` field.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#export-advanced-security-active-committers-data-for-enterprise", + "description": "Lists all instances of the specified code scanning alert.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-instances-of-a-code-scanning-alert", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -10513,11 +14985,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -10526,46 +14998,24 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Success" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - } - ], - "renamed": null - }, - { - "name": "Get GitHub Advanced Security active committers for an organization", - "scope": "billing", - "id": "getGithubAdvancedSecurityBillingOrg", - "method": "GET", - "url": "/orgs/{org}/settings/billing/advanced-security", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the GitHub Advanced Security active committers for an organization per repository.\n\nEach distinct user login across all repositories is counted as a single Advanced Security seat, so the `total_advanced_security_committers` is not the sum of advanced_security_committers for each repository.\n\nIf this organization defers to an enterprise for billing, the `total_advanced_security_committers` returned from the organization API may include some users that are in more than one organization, so they will only consume a single Advanced Security seat at the enterprise level.\n\nThe total number of repositories with committer information is tracked by the `total_count` field.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-advanced-security-active-committers-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10587,10 +15037,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "ref", + "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -10601,25 +15051,27 @@ } ], "responses": [ - { "code": 200, "description": "Success" }, + { "code": 200, "description": "Response" }, { "code": 403, "description": "Response if GitHub Advanced Security is not enabled for this repository" - } + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Get GitHub Packages billing for an organization", - "scope": "billing", - "id": "getGithubPackagesBillingOrg", + "name": "List code scanning alerts for an organization", + "scope": "codeScanning", + "id": "listAlertsForOrg", "method": "GET", - "url": "/orgs/{org}/settings/billing/packages", + "url": "/orgs/{org}/code-scanning/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the free and paid storage used for GitHub Packages in gigabytes.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `repo` or `admin:org` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-packages-billing-for-an-organization", + "description": "Lists code scanning alerts for the default branch for all eligible repositories in an organization. Eligible repositories are repositories that are owned by organizations that you own or for which you are a security manager. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nTo use this endpoint, you must be an owner or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.\n\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `security_events` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-alerts-for-an-organization", "parameters": [ { "name": "org", @@ -10633,116 +15085,52 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get GitHub Packages billing for a user", - "scope": "billing", - "id": "getGithubPackagesBillingUser", - "method": "GET", - "url": "/users/{username}/settings/billing/packages", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the free and paid storage used for GitHub Packages in gigabytes.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `user` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-github-packages-billing-for-a-user", - "parameters": [ + }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "tool_name", + "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get shared storage billing for an organization", - "scope": "billing", - "id": "getSharedStorageBillingOrg", - "method": "GET", - "url": "/orgs/{org}/settings/billing/shared-storage", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the estimated paid and estimated total storage used for GitHub Actions and GitHub Packages.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `repo` or `admin:org` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-shared-storage-billing-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "tool_guid", + "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get shared storage billing for a user", - "scope": "billing", - "id": "getSharedStorageBillingUser", - "method": "GET", - "url": "/users/{username}/settings/billing/shared-storage", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the estimated paid and estimated total storage used for GitHub Actions and GitHub Packages.\n\nPaid minutes only apply to packages stored for private repositories. For more information, see \"[Managing billing for GitHub Packages](https://docs.github.com/github/setting-up-and-managing-billing-and-payments-on-github/managing-billing-for-github-packages).\"\n\nAccess tokens must have the `user` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/billing#get-shared-storage-billing-for-a-user", - "parameters": [ + }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Create a check run", - "scope": "checks", - "id": "create", - "method": "POST", - "url": "/repos/{owner}/{repo}/check-runs", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nCreates a new check run for a specific commit in a repository. Your GitHub App must have the `checks:write` permission to create check runs.\n\nIn a check suite, GitHub limits the number of check runs with the same name to 1000. Once these check runs exceed 1000, GitHub will start to automatically delete older check runs.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-run", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10751,11 +15139,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10764,12 +15152,12 @@ "deprecated": null }, { - "name": "status", - "description": "", - "in": "BODY", - "type": null, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["queued", "in_progress"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -10777,41 +15165,25 @@ "deprecated": null }, { - "name": "*", - "description": "", - "in": "BODY", - "type": "object", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Create a check suite", - "scope": "checks", - "id": "createSuite", - "method": "POST", - "url": "/repos/{owner}/{repo}/check-suites", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nBy default, check suites are automatically created when you create a [check run](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#check-runs). You only need to use this endpoint for manually creating check suites when you've disabled automatic creation using \"[Update repository preferences for check suites](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-repository-preferences-for-check-suites)\". Your GitHub App must have the `checks:write` permission to create check suites.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-suite", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "state", + "description": "If specified, only code scanning alerts with this state will be returned.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["open", "closed", "dismissed", "fixed"], "allowNull": false, "mapToData": null, "validation": null, @@ -10819,12 +15191,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "sort", + "description": "The property by which to sort the results.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["created", "updated"], "allowNull": false, "mapToData": null, "validation": null, @@ -10832,12 +15204,20 @@ "deprecated": null }, { - "name": "head_sha", - "description": "The sha of the head commit.", - "in": "BODY", + "name": "severity", + "description": "If specified, only code scanning alerts with this severity will be returned.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": [ + "critical", + "high", + "medium", + "low", + "warning", + "note", + "error" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -10846,22 +15226,23 @@ } ], "responses": [ - { "code": 200, "description": "Response when the suite already exists" }, - { "code": 201, "description": "Response when the suite was created" } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Get a check run", - "scope": "checks", - "id": "get", + "name": "List code scanning alerts for a repository", + "scope": "codeScanning", + "id": "listAlertsForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}", + "url": "/repos/{owner}/{repo}/code-scanning/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nGets a single check run using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#get-a-check-run", + "description": "Lists code scanning alerts.\n\nTo use this endpoint, you must use an access token with the `security_events` scope or, for alerts from public repositories only, an access token with the `public_repo` scope.\n\nGitHub Apps must have the `security_events` read\npermission to use this endpoint.\n\nThe response includes a `most_recent_instance` object.\nThis provides details of the most recent instance of this alert\nfor the default branch (or for the specified Git reference if you used `ref` in the request).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-alerts-for-a-repository", "parameters": [ { "name": "owner", @@ -10878,7 +15259,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -10890,40 +15271,24 @@ "deprecated": null }, { - "name": "check_run_id", - "description": "The unique identifier of the check run.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "tool_name", + "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a check suite", - "scope": "checks", - "id": "getSuite", - "method": "GET", - "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nGets a single check suite using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check suites. OAuth Apps and authenticated users must have the `repo` scope to get check suites in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#get-a-check-suite", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "tool_guid", + "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10932,11 +15297,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10945,40 +15310,24 @@ "deprecated": null }, { - "name": "check_suite_id", - "description": "The unique identifier of the check suite.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List check run annotations", - "scope": "checks", - "id": "listAnnotations", - "method": "GET", - "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}/annotations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists annotations for a check run using the annotation `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get annotations for a check run. OAuth Apps and authenticated users must have the `repo` scope to get annotations for a check run in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-run-annotations", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "ref", + "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -10987,12 +15336,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -11000,12 +15349,12 @@ "deprecated": null }, { - "name": "check_run_id", - "description": "The unique identifier of the check run.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "sort", + "description": "The property by which to sort the results.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], "allowNull": false, "mapToData": null, "validation": null, @@ -11013,12 +15362,12 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "state", + "description": "If specified, only code scanning alerts with this state will be returned.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["open", "closed", "dismissed", "fixed"], "allowNull": false, "mapToData": null, "validation": null, @@ -11026,12 +15375,20 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "severity", + "description": "If specified, only code scanning alerts with this severity will be returned.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": [ + "critical", + "high", + "medium", + "low", + "warning", + "note", + "error" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -11039,20 +15396,29 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "List check runs for a Git reference", - "scope": "checks", - "id": "listForRef", + "name": "List instances of a code scanning alert", + "scope": "codeScanning", + "id": "listAlertsInstances", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{ref}/check-runs", + "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nLists check runs for a commit ref. The `ref` can be a SHA, branch name, or a tag name. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-runs-for-a-git-reference", + "description": "Lists all instances of the specified code scanning alert.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-instances-of-a-code-scanning-alert", "parameters": [ { "name": "owner", @@ -11069,7 +15435,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -11081,10 +15447,10 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -11094,10 +15460,10 @@ "deprecated": null }, { - "name": "check_name", - "description": "Returns check runs with the specified `name`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -11107,12 +15473,12 @@ "deprecated": null }, { - "name": "status", - "description": "Returns check runs with the specified `status`.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["queued", "in_progress", "completed"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -11120,37 +15486,53 @@ "deprecated": null }, { - "name": "filter", - "description": "Filters check runs by their `completed_at` timestamp. `latest` returns the most recent check runs.", + "name": "ref", + "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", "in": "QUERY", "type": "string", "required": false, - "enum": ["latest", "all"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": { + "before": { "scope": "codeScanning", "id": "listAlertsInstances" }, + "after": { "scope": "codeScanning", "id": "listAlertInstances" }, + "date": "2021-04-30", + "note": null + } + }, + { + "name": "List CodeQL databases for a repository", + "scope": "codeScanning", + "id": "listCodeqlDatabases", + "method": "GET", + "url": "/repos/{owner}/{repo}/code-scanning/codeql/databases", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the CodeQL databases that are available in a repository.\n\nFor private repositories, you must use an access token with the `security_events` scope.\nFor public repositories, you can use tokens with the `security_events` or `public_repo` scope.\nGitHub Apps must have the `contents` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-codeql-databases-for-a-repository", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11159,11 +15541,11 @@ "deprecated": null }, { - "name": "app_id", - "description": "", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11172,20 +15554,28 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "List check runs in a check suite", - "scope": "checks", - "id": "listForSuite", + "name": "List code scanning analyses for a repository", + "scope": "codeScanning", + "id": "listRecentAnalyses", "method": "GET", - "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}/check-runs", + "url": "/repos/{owner}/{repo}/code-scanning/analyses", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nLists check runs for a check suite using its `id`. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to get check runs. OAuth Apps and authenticated users must have the `repo` scope to get check runs in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-runs-in-a-check-suite", + "description": "Lists the details of all code scanning analyses for a repository,\nstarting with the most recent.\nThe response is paginated and you can use the `page` and `per_page` parameters\nto list the analyses you're interested in.\nBy default 30 analyses are listed per page.\n\nThe `rules_count` field in the response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-analyses-for-a-repository", "parameters": [ { "name": "owner", @@ -11202,7 +15592,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -11214,11 +15604,11 @@ "deprecated": null }, { - "name": "check_suite_id", - "description": "The unique identifier of the check suite.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "tool_name", + "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11227,8 +15617,8 @@ "deprecated": null }, { - "name": "check_name", - "description": "Returns check runs with the specified `name`.", + "name": "tool_guid", + "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", "in": "QUERY", "type": "string", "required": false, @@ -11240,12 +15630,12 @@ "deprecated": null }, { - "name": "status", - "description": "Returns check runs with the specified `status`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["queued", "in_progress", "completed"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -11253,12 +15643,12 @@ "deprecated": null }, { - "name": "filter", - "description": "Filters check runs by their `completed_at` timestamp. `latest` returns the most recent check runs.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["latest", "all"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -11266,10 +15656,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "ref", + "description": "The Git reference for the analyses you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11279,10 +15669,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "sarif_id", + "description": "Filter analyses belonging to the same SARIF upload.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11290,22 +15680,56 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property by which to sort the results.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "List check suites for a Git reference", - "scope": "checks", - "id": "listSuitesForRef", - "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{ref}/check-suites", + "name": "Update a code scanning alert", + "scope": "codeScanning", + "id": "updateAlert", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array and a `null` value for `head_branch`.\n\nLists check suites for a commit `ref`. The `ref` can be a SHA, branch name, or a tag name. GitHub Apps must have the `checks:read` permission on a private repository or pull access to a public repository to list check suites. OAuth Apps and authenticated users must have the `repo` scope to get check suites in a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#list-check-suites-for-a-git-reference", + "description": "Updates the status of a single code scanning alert. You must use an access token with the `security_events` scope to use this endpoint with private repositories. You can also use tokens with the `public_repo` scope for public repositories only. GitHub Apps must have the `security_events` write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#update-a-code-scanning-alert", "parameters": [ { "name": "owner", @@ -11322,7 +15746,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -11334,24 +15758,11 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "app_id", - "description": "Filters check suites by GitHub App `id`.", - "in": "QUERY", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11360,12 +15771,12 @@ "deprecated": null }, { - "name": "check_name", - "description": "Returns check runs with the specified `name`.", - "in": "QUERY", + "name": "state", + "description": "Sets the state of the code scanning alert. You must provide `dismissed_reason` when you set the state to `dismissed`.", + "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["open", "dismissed"], "allowNull": false, "mapToData": null, "validation": null, @@ -11373,46 +15784,54 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "dismissed_reason", + "description": "**Required when the state is dismissed.** The reason for dismissing or closing the alert.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, - "allowNull": false, + "enum": [null, "false positive", "won't fix", "used in tests"], + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "dismissed_comment", + "description": "The dismissal comment associated with the dismissal of the alert.", + "in": "BODY", + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 403, + "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Rerequest a check run", - "scope": "checks", - "id": "rerequestRun", - "method": "POST", - "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}/rerequest", + "name": "Update a code scanning default setup configuration", + "scope": "codeScanning", + "id": "updateDefaultSetup", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/code-scanning/default-setup", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Triggers GitHub to rerequest an existing check run, without pushing new code to a repository. This endpoint will trigger the [`check_run` webhook](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#check_run) event with the action `rerequested`. When a check run is `rerequested`, its `status` is reset to `queued` and the `conclusion` is cleared.\n\nTo rerequest a check run, your GitHub App must have the `checks:read` permission on a private repository or pull access to a public repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#rerequest-a-check-run", + "description": "Updates a code scanning default setup configuration.\nYou must use an access token with the `repo` scope to use this endpoint with private repos or the `public_repo`\nscope for public repos. GitHub Apps must have the `repo` write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/code-scanning#update-a-code-scanning-default-setup-configuration", "parameters": [ { "name": "owner", @@ -11429,7 +15848,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -11441,12 +15860,25 @@ "deprecated": null }, { - "name": "check_run_id", - "description": "The unique identifier of the check run.", - "in": "PATH", - "type": "integer", + "name": "state", + "description": "Whether code scanning default setup has been configured or not.", + "in": "BODY", + "type": "string", "required": true, - "enum": null, + "enum": ["configured", "not-configured"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "query_suite", + "description": "CodeQL query suite to be used.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["default", "extended"], "allowNull": false, "mapToData": null, "validation": null, @@ -11455,30 +15887,32 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 202, "description": "Response" }, { "code": 403, - "description": "Forbidden if the check run is not rerequestable or doesn't belong to the authenticated GitHub App" + "description": "Response if GitHub Advanced Security is not enabled for this repository" }, { "code": 404, "description": "Resource not found" }, { - "code": 422, - "description": "Validation error if the check run is not rerequestable" - } + "code": 409, + "description": "Response if there is already a validation run in progress with a different default setup configuration" + }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Rerequest a check suite", - "scope": "checks", - "id": "rerequestSuite", + "name": "Upload an analysis as SARIF data", + "scope": "codeScanning", + "id": "uploadSarif", "method": "POST", - "url": "/repos/{owner}/{repo}/check-suites/{check_suite_id}/rerequest", + "url": "/repos/{owner}/{repo}/code-scanning/sarifs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Triggers GitHub to rerequest an existing check suite, without pushing new code to a repository. This endpoint will trigger the [`check_suite` webhook](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#check_suite) event with the action `rerequested`. When a check suite is `rerequested`, its `status` is reset to `queued` and the `conclusion` is cleared.\n\nTo rerequest a check suite, your GitHub App must have the `checks:read` permission on a private repository or pull access to a public repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#rerequest-a-check-suite", + "description": "Uploads SARIF data containing the results of a code scanning analysis to make the results available in a repository. You must use an access token with the `security_events` scope to use this endpoint for private repositories. You can also use tokens with the `public_repo` scope for public repositories only. GitHub Apps must have the `security_events` write permission to use this endpoint.\n\nThere are two places where you can upload code scanning results.\n - If you upload to a pull request, for example `--ref refs/pull/42/merge` or `--ref refs/pull/42/head`, then the results appear as alerts in a pull request check. For more information, see \"[Triaging code scanning alerts in pull requests](/code-security/secure-coding/triaging-code-scanning-alerts-in-pull-requests).\"\n - If you upload to a branch, for example `--ref refs/heads/my-branch`, then the results appear in the **Security** tab for your repository. For more information, see \"[Managing code scanning alerts for your repository](/code-security/secure-coding/managing-code-scanning-alerts-for-your-repository#viewing-the-alerts-for-a-repository).\"\n\nYou must compress the SARIF-formatted analysis data that you want to upload, using `gzip`, and then encode it as a Base64 format string. For example:\n\n```\ngzip -c analysis-data.sarif | base64 -w0\n```\n
\nSARIF upload supports a maximum number of entries per the following data objects, and an analysis will be rejected if any of these objects is above its maximum value. For some objects, there are additional values over which the entries will be ignored while keeping the most important entries whenever applicable.\nTo get the most out of your analysis when it includes data above the supported limits, try to optimize the analysis configuration. For example, for the CodeQL tool, identify and remove the most noisy queries.\n\n\n| **SARIF data** | **Maximum values** | **Additional limits** |\n|----------------------------------|:------------------:|----------------------------------------------------------------------------------|\n| Runs per file | 20 | |\n| Results per run | 25,000 | Only the top 5,000 results will be included, prioritized by severity. |\n| Rules per run | 25,000 | |\n| Tool extensions per run | 100 | |\n| Thread Flow Locations per result | 10,000 | Only the top 1,000 Thread Flow Locations will be included, using prioritization. |\n| Location per result\t | 1,000 | Only 100 locations will be included. |\n| Tags per rule\t | 20 | Only 10 tags will be included. |\n\n\nThe `202 Accepted` response includes an `id` value.\nYou can use this ID to check the status of the upload by using it in the `/sarifs/{sarif_id}` endpoint.\nFor more information, see \"[Get information about a SARIF upload](/rest/reference/code-scanning#get-information-about-a-sarif-upload).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#upload-an-analysis-as-sarif-data", "parameters": [ { "name": "owner", @@ -11495,7 +15929,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -11507,38 +15941,22 @@ "deprecated": null }, { - "name": "check_suite_id", - "description": "The unique identifier of the check suite.", - "in": "PATH", - "type": "integer", + "name": "commit_sha", + "description": "The SHA of the commit to which the analysis you are uploading relates.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^[0-9a-fA-F]+$", "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Update repository preferences for check suites", - "scope": "checks", - "id": "setSuitesPreferences", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/check-suites/preferences", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Changes the default automatic flow when creating check suites. By default, a check suite is automatically created each time code is pushed to a repository. When you disable the automatic creation of check suites, you can manually [Create a check suite](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#create-a-check-suite). You must have admin permissions in the repository to set preferences for check suites.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-repository-preferences-for-check-suites", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "ref", + "description": "The full Git reference, formatted as `refs/heads/`,\n`refs/pull//merge`, or `refs/pull//head`.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -11549,9 +15967,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "sarif", + "description": "A Base64 string representing the SARIF file to upload. You must first compress your SARIF file using [`gzip`](http://www.gnu.org/software/gzip/manual/gzip.html) and then translate the contents of the file into a Base64 encoding string. For more information, see \"[SARIF support for code scanning](https://docs.github.com/enterprise-cloud@latest//code-security/secure-coding/sarif-support-for-code-scanning).\"", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -11562,10 +15980,10 @@ "deprecated": null }, { - "name": "auto_trigger_checks", - "description": "Enables or disables automatic creation of CheckSuite events upon pushes to the repository. Enabled by default. See the [`auto_trigger_checks` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#auto_trigger_checks-object) description for details.", + "name": "checkout_uri", + "description": "The base directory used in the analysis, as it appears in the SARIF file.\nThis property is used to convert file paths from absolute to relative, so that alerts can be mapped to their correct location in the repository.", "in": "BODY", - "type": "object[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11575,11 +15993,11 @@ "deprecated": null }, { - "name": "auto_trigger_checks[].app_id", - "description": "The `id` of the GitHub App.", + "name": "started_at", + "description": "The time that the analysis run began. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", - "type": "integer", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11588,11 +16006,24 @@ "deprecated": null }, { - "name": "auto_trigger_checks[].setting", - "description": "Set to `true` to enable automatic creation of CheckSuite events upon pushes to the repository, or `false` to disable them.", + "name": "tool_name", + "description": "The name of the tool used to generate the code scanning analysis. If this parameter is not used, the tool name defaults to \"API\". If the uploaded SARIF contains a tool GUID, this will be available for filtering using the `tool_guid` parameter of operations such as `GET /repos/{owner}/{repo}/code-scanning/alerts`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "validate", + "description": "Whether the SARIF file will be validated according to the code scanning specifications.\nThis parameter is intended to help integrators ensure that the uploaded SARIF files are correctly rendered by code scanning.", "in": "BODY", "type": "boolean", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11601,24 +16032,58 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 202, "description": "Response" }, + { + "code": 400, + "description": "Bad Request if the sarif field is invalid" + }, + { + "code": 403, + "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" + }, + { "code": 404, "description": "Resource not found" }, + { + "code": 413, + "description": "Payload Too Large if the sarif field is too large" + }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Update a check run", - "scope": "checks", - "id": "update", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/check-runs/{check_run_id}", + "name": "Get all codes of conduct", + "scope": "codesOfConduct", + "id": "getAllCodesOfConduct", + "method": "GET", + "url": "/codes_of_conduct", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** The Checks API only looks for pushes in the repository where the check suite or check run were created. Pushes to a branch in a forked repository are not detected and return an empty `pull_requests` array.\n\nUpdates a check run for a specific commit in a repository. Your GitHub App must have the `checks:write` permission to edit check runs.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-a-check-run", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codes-of-conduct#get-all-codes-of-conduct", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Get a code of conduct", + "scope": "codesOfConduct", + "id": "getConductCode", + "method": "GET", + "url": "/codes_of_conduct/{key}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codes-of-conduct#get-a-code-of-conduct", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "key", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -11628,10 +16093,30 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Add a selected repository to a user secret", + "scope": "codespaces", + "id": "addRepositoryForSecretForAuthenticatedUser", + "method": "PUT", + "url": "/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a repository to the selected repositories for a user's codespace secret.\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on the referenced repository to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-a-selected-repository-to-a-user-secret", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -11643,8 +16128,8 @@ "deprecated": null }, { - "name": "check_run_id", - "description": "The unique identifier of the check run.", + "name": "repository_id", + "description": "", "in": "PATH", "type": "integer", "required": true, @@ -11654,26 +16139,38 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ { - "name": "name", - "description": "The name of the check. For example, \"code-coverage\".", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 204, + "description": "No Content when repository was added to the selected list" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Add selected repository to an organization secret", + "scope": "codespaces", + "id": "addSelectedRepoToOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a repository to an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-selected-repository-to-an-organization-secret", + "parameters": [ { - "name": "details_url", - "description": "The URL of the integrator's site that has the full details of the check.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11682,11 +16179,11 @@ "deprecated": null }, { - "name": "external_id", - "description": "A reference for the run on the integrator's system.", - "in": "BODY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11695,59 +16192,90 @@ "deprecated": null }, { - "name": "started_at", - "description": "This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", - "type": "string", - "required": false, + "name": "repository_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 204, + "description": "No Content when repository was added to the selected list" }, + { "code": 404, "description": "Resource not found" }, { - "name": "status", - "description": "The current status.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["queued", "in_progress", "completed"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 409, + "description": "Conflict when visibility type is not set to selected" }, { - "name": "conclusion", - "description": "**Required if you provide `completed_at` or a `status` of `completed`**. The final conclusion of the check. \n**Note:** Providing `conclusion` will automatically set the `status` parameter to `completed`. You cannot change a check run conclusion to `stale`, only GitHub can set this.", - "in": "BODY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List machine types for a codespace", + "scope": "codespaces", + "id": "codespaceMachinesForAuthenticatedUser", + "method": "GET", + "url": "/user/codespaces/{codespace_name}/machines", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "List the machine types a codespace can transition to use.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_metadata` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-machine-types-for-a-codespace", + "parameters": [ + { + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, - "enum": [ - "action_required", - "cancelled", - "failure", - "neutral", - "success", - "skipped", - "stale", - "timed_out" - ], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Create a codespace for the authenticated user", + "scope": "codespaces", + "id": "createForAuthenticatedUser", + "method": "POST", + "url": "/user/codespaces", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a new codespace, owned by the authenticated user.\n\nThis endpoint requires either a `repository_id` OR a `pull_request` but not both.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-for-the-authenticated-user", + "parameters": [ { - "name": "completed_at", - "description": "The time the check completed. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "name": "repository_id", + "description": "Repository id for this codespace", "in": "BODY", - "type": "string", - "required": false, + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11756,10 +16284,10 @@ "deprecated": null }, { - "name": "output", - "description": "Check runs can accept a variety of data in the `output` object, including a `title` and `summary` and can optionally provide descriptive details about the run. See the [`output` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#output-object-1) description.", + "name": "ref", + "description": "Git ref (typically a branch name) for this codespace", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11769,8 +16297,8 @@ "deprecated": null }, { - "name": "output.title", - "description": "**Required**.", + "name": "location", + "description": "The requested location for a new codespace. Best efforts are made to respect this upon creation. Assigned by IP if not provided.", "in": "BODY", "type": "string", "required": false, @@ -11782,12 +16310,12 @@ "deprecated": null }, { - "name": "output.summary", - "description": "Can contain Markdown.", + "name": "geo", + "description": "The geographic area for this codespace. If not specified, the value is assigned by IP. This property replaces `location`, which is being deprecated.", "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["EuropeWest", "SoutheastAsia", "UsEast", "UsWest"], "allowNull": false, "mapToData": null, "validation": null, @@ -11795,8 +16323,8 @@ "deprecated": null }, { - "name": "output.text", - "description": "Can contain Markdown.", + "name": "client_ip", + "description": "IP for location auto-detection when proxying a request", "in": "BODY", "type": "string", "required": false, @@ -11808,10 +16336,10 @@ "deprecated": null }, { - "name": "output.annotations", - "description": "Adds information from your analysis to specific lines of code. Annotations are visible in GitHub's pull request UI. Annotations are visible in GitHub's pull request UI. The Checks API limits the number of annotations to a maximum of 50 per API request. To create more than 50 annotations, you have to make multiple requests to the [Update a check run](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#update-a-check-run) endpoint. Each time you update the check run, annotations are appended to the list of annotations that already exist for the check run. For details about annotations in the UI, see \"[About status checks](https://docs.github.com/articles/about-status-checks#checks)\". See the [`annotations` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#annotations-object-1) description for details.", + "name": "machine", + "description": "Machine type to use for this codespace", "in": "BODY", - "type": "object[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11821,11 +16349,11 @@ "deprecated": null }, { - "name": "output.annotations[].path", - "description": "The path of the file to add an annotation to. For example, `assets/css/main.css`.", + "name": "devcontainer_path", + "description": "Path to devcontainer.json config to use for this codespace", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11834,11 +16362,11 @@ "deprecated": null }, { - "name": "output.annotations[].start_line", - "description": "The start line of the annotation.", + "name": "multi_repo_permissions_opt_out", + "description": "Whether to authorize requested permissions from devcontainer.json", "in": "BODY", - "type": "integer", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11847,11 +16375,11 @@ "deprecated": null }, { - "name": "output.annotations[].end_line", - "description": "The end line of the annotation.", + "name": "working_directory", + "description": "Working directory for this codespace", "in": "BODY", - "type": "integer", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -11860,8 +16388,8 @@ "deprecated": null }, { - "name": "output.annotations[].start_column", - "description": "The start column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values.", + "name": "idle_timeout_minutes", + "description": "Time in minutes before codespace stops from inactivity", "in": "BODY", "type": "integer", "required": false, @@ -11873,10 +16401,10 @@ "deprecated": null }, { - "name": "output.annotations[].end_column", - "description": "The end column of the annotation. Annotations only support `start_column` and `end_column` on the same line. Omit this parameter if `start_line` and `end_line` have different values.", + "name": "display_name", + "description": "Display name for this codespace", "in": "BODY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -11886,12 +16414,12 @@ "deprecated": null }, { - "name": "output.annotations[].annotation_level", - "description": "The level of the annotation.", + "name": "retention_period_minutes", + "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", "in": "BODY", - "type": "string", - "required": true, - "enum": ["notice", "warning", "failure"], + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -11899,10 +16427,10 @@ "deprecated": null }, { - "name": "output.annotations[].message", - "description": "A short description of the feedback for these lines of code. The maximum size is 64 KB.", + "name": "pull_request", + "description": "Pull request number for this codespace", "in": "BODY", - "type": "string", + "type": "object", "required": true, "enum": null, "allowNull": false, @@ -11912,11 +16440,11 @@ "deprecated": null }, { - "name": "output.annotations[].title", - "description": "The title that represents the annotation. The maximum size is 255 characters.", + "name": "pull_request.pull_request_number", + "description": "Pull request number", "in": "BODY", - "type": "string", - "required": false, + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -11925,35 +16453,51 @@ "deprecated": null }, { - "name": "output.annotations[].raw_details", - "description": "Details about this annotation. The maximum size is 64 KB.", + "name": "pull_request.repository_id", + "description": "Repository id for this codespace", "in": "BODY", - "type": "string", - "required": false, + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 201, + "description": "Response when the codespace was successfully created" }, { - "name": "output.images", - "description": "Adds images to the output displayed in the GitHub pull request UI. See the [`images` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#annotations-object-1) description for details.", - "in": "BODY", - "type": "object[]", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 202, + "description": "Response when the codespace creation partially failed but is being retried in the background" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "Create or update an organization secret", + "scope": "codespaces", + "id": "createOrUpdateOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `admin:org` scope to use this endpoint.\n\n**Example encrypting a secret using Node.js**\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n**Example encrypting a secret using Python**\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n**Example encrypting a secret using C#**\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n**Example encrypting a secret using Ruby**\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret", + "parameters": [ { - "name": "output.images[].alt", - "description": "The alternative text for the image.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -11964,9 +16508,9 @@ "deprecated": null }, { - "name": "output.images[].image_url", - "description": "The full URL of the image.", - "in": "BODY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -11977,23 +16521,23 @@ "deprecated": null }, { - "name": "output.images[].caption", - "description": "A short image description.", + "name": "encrypted_value", + "description": "The value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get an organization public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-public-key) endpoint.", "in": "BODY", "type": "string", "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", "alias": null, "deprecated": null }, { - "name": "actions", - "description": "Possible further actions the integrator can perform, which a user may trigger. Each action includes a `label`, `identifier` and `description`. A maximum of three actions are accepted. See the [`actions` object](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#actions-object) description. To learn more about check runs and requested actions, see \"[Check runs and requested actions](https://docs.github.com/enterprise-cloud@latest//rest/reference/checks#check-runs-and-requested-actions).\"", + "name": "key_id", + "description": "The ID of the key you used to encrypt the secret.", "in": "BODY", - "type": "object[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -12003,12 +16547,12 @@ "deprecated": null }, { - "name": "actions[].label", - "description": "The text to be displayed on a button in the web UI. The maximum size is 20 characters.", + "name": "visibility", + "description": "Which type of organization repositories have access to the organization secret. `selected` means only the repositories specified by `selected_repository_ids` can access the secret.", "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["all", "private", "selected"], "allowNull": false, "mapToData": null, "validation": null, @@ -12016,46 +16560,41 @@ "deprecated": null }, { - "name": "actions[].description", - "description": "A short explanation of what this action would do. The maximum size is 40 characters.", + "name": "selected_repository_ids", + "description": "An array of repository IDs that can access the organization secret. You can only provide a list of repository IDs when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret) endpoints.", "in": "BODY", - "type": "string", - "required": true, + "type": "integer[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response when creating a secret" }, + { "code": 204, "description": "Response when updating a secret" }, + { "code": 404, "description": "Resource not found" }, { - "name": "actions[].identifier", - "description": "A reference for the action on the integrator's system. The maximum size is 20 characters.", - "in": "BODY", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Delete a code scanning analysis from a repository", - "scope": "codeScanning", - "id": "deleteAnalysis", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}{?confirm_delete}", + "name": "Create or update a repository secret", + "scope": "codespaces", + "id": "createOrUpdateRepoSecret", + "method": "PUT", + "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a specified code scanning analysis from a repository. For\nprivate repositories, you must use an access token with the `repo` scope. For public repositories,\nyou must use an access token with `public_repo` scope.\nGitHub Apps must have the `security_events` write permission to use this endpoint.\n\nYou can delete one analysis at a time.\nTo delete a series of analyses, start with the most recent analysis and work backwards.\nConceptually, the process is similar to the undo function in a text editor.\n\nWhen you list the analyses for a repository,\none or more will be identified as deletable in the response:\n\n```\n\"deletable\": true\n```\n\nAn analysis is deletable when it's the most recent in a set of analyses.\nTypically, a repository will have multiple sets of analyses\nfor each enabled code scanning tool,\nwhere a set is determined by a unique combination of analysis values:\n\n* `ref`\n* `tool`\n* `category`\n\nIf you attempt to delete an analysis that is not the most recent in a set,\nyou'll get a 400 response with the message:\n\n```\nAnalysis specified is not deletable.\n```\n\nThe response from a successful `DELETE` operation provides you with\ntwo alternative URLs for deleting the next analysis in the set:\n`next_analysis_url` and `confirm_delete_url`.\nUse the `next_analysis_url` URL if you want to avoid accidentally deleting the final analysis\nin a set. This is a useful option if you want to preserve at least one analysis\nfor the specified tool in your repository.\nUse the `confirm_delete_url` URL if you are content to remove all analyses for a tool.\nWhen you delete the last analysis in a set, the value of `next_analysis_url` and `confirm_delete_url`\nin the 200 response is `null`.\n\nAs an example of the deletion process,\nlet's imagine that you added a workflow that configured a particular code scanning tool\nto analyze the code in a repository. This tool has added 15 analyses:\n10 on the default branch, and another 5 on a topic branch.\nYou therefore have two separate sets of analyses for this tool.\nYou've now decided that you want to remove all of the analyses for the tool.\nTo do this you must make 15 separate deletion requests.\nTo start, you must find an analysis that's identified as deletable.\nEach set of analyses always has one that's identified as deletable.\nHaving found the deletable analysis for one of the two sets,\ndelete this analysis and then continue deleting the next analysis in the set until they're all deleted.\nThen repeat the process for the second set.\nThe procedure therefore consists of a nested loop:\n\n**Outer loop**:\n* List the analyses for the repository, filtered by tool.\n* Parse this list to find a deletable analysis. If found:\n\n **Inner loop**:\n * Delete the identified analysis.\n * Parse the response for the value of `confirm_delete_url` and, if found, use this in the next iteration.\n\nThe above process assumes that you want to remove all trace of the tool's analyses from the GitHub user interface, for the specified repository, and it therefore uses the `confirm_delete_url` value. Alternatively, you could use the `next_analysis_url` value, which would leave the last analysis in each set undeleted to avoid removing a tool's analysis entirely.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#delete-a-code-scanning-analysis-from-a-repository", + "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have write access to the `codespaces_secrets`\nrepository permission to use this endpoint.\n\n#### Example of encrypting a secret using Node.js\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n#### Example of encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example of encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example of encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-a-repository-secret", "parameters": [ { "name": "owner", @@ -12072,7 +16611,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -12084,10 +16623,10 @@ "deprecated": null }, { - "name": "analysis_id", - "description": "The ID of the analysis, as returned from the `GET /repos/{owner}/{repo}/code-scanning/analyses` operation.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -12097,9 +16636,22 @@ "deprecated": null }, { - "name": "confirm_delete", - "description": "Allow deletion if the specified analysis is the last in a set. If you attempt to delete the final analysis in a set without setting this parameter to `true`, you'll get a 400 response with the message: `Analysis is last of its type and deletion may result in the loss of historical alert data. Please specify confirm_delete.`", - "in": "QUERY", + "name": "encrypted_value", + "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get a repository public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-public-key) endpoint.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "alias": null, + "deprecated": null + }, + { + "name": "key_id", + "description": "ID of the key you used to encrypt the secret.", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -12111,33 +16663,26 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 403, - "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { "code": 201, "description": "Response when creating a secret" }, + { "code": 204, "description": "Response when updating a secret" } ], "renamed": null }, { - "name": "Get a code scanning alert", - "scope": "codeScanning", - "id": "getAlert", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}", + "name": "Create or update a secret for the authenticated user", + "scope": "codespaces", + "id": "createOrUpdateSecretForAuthenticatedUser", + "method": "PUT", + "url": "/user/codespaces/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single code scanning alert. You must use an access token with the `security_events` scope to use this endpoint with private repos, the `public_repo` scope also grants permission to read security events on public repos only. GitHub Apps must have the `security_events` read permission to use this endpoint.\n\n**Deprecation notice**:\nThe instances field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The same information can now be retrieved via a GET request to the URL specified by `instances_url`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-a-code-scanning-alert", + "description": "Creates or updates a secret for a user's codespace with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages).\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must also have Codespaces access to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission and `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.\n\n**Example encrypting a secret using Node.js**\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n**Example encrypting a secret using Python**\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n**Example encrypting a secret using C#**\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n**Example encrypting a secret using Ruby**\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-a-secret-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -12149,23 +16694,23 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "encrypted_value", + "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get the public key for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-the-public-key-for-the-authenticated-user) endpoint.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", "alias": null, "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", - "in": "PATH", - "type": "integer", + "name": "key_id", + "description": "ID of the key you used to encrypt the secret.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -12175,42 +16720,47 @@ "deprecated": null }, { - "name": "alert_id", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", - "in": "PATH", - "type": "integer", + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the user secret. You can manage the list of selected repositories using the [List selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret), [Set selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-a-user-secret), and [Remove a selected repository from a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret) endpoints.", + "in": "BODY", + "type": "undefined[]", "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, - "alias": "alert_number", - "deprecated": true + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" + "code": 201, + "description": "Response after successfully creating a secret" + }, + { + "code": 204, + "description": "Response after successfully updating a secret" }, { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get a code scanning analysis for a repository", - "scope": "codeScanning", - "id": "getAnalysis", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}", + "name": "Create a codespace from a pull request", + "scope": "codespaces", + "id": "createWithPrForAuthenticatedUser", + "method": "POST", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/codespaces", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specified code scanning analysis for a repository.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\nThe default JSON response contains fields that describe the analysis.\nThis includes the Git reference and commit SHA to which the analysis relates,\nthe datetime of the analysis, the name of the code scanning tool,\nand the number of alerts.\n\nThe `rules_count` field in the default response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nIf you use the Accept header `application/sarif+json`,\nthe response contains the analysis data that was uploaded.\nThis is formatted as\n[SARIF version 2.1.0](https://docs.oasis-open.org/sarif/sarif/v2.1.0/cs01/sarif-v2.1.0-cs01.html).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-a-code-scanning-analysis-for-a-repository", + "description": "Creates a codespace owned by the authenticated user for the specified pull request.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-from-a-pull-request", "parameters": [ { "name": "owner", @@ -12227,7 +16777,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -12239,8 +16789,8 @@ "deprecated": null }, { - "name": "analysis_id", - "description": "The ID of the analysis, as returned from the `GET /repos/{owner}/{repo}/code-scanning/analyses` operation.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", "type": "integer", "required": true, @@ -12250,38 +16800,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "Get a CodeQL database for a repository", - "scope": "codeScanning", - "id": "getCodeqlDatabase", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/codeql/databases/{language}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets a CodeQL database for a language in a repository.\n\nBy default this endpoint returns JSON metadata about the CodeQL database. To\ndownload the CodeQL database binary content, set the `Accept` header of the request\nto [`application/zip`](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types), and make sure\nyour HTTP client is configured to follow redirects or use the `Location` header\nto make a second request to get the redirect URL.\n\nFor private repositories, you must use an access token with the `security_events` scope.\nFor public repositories, you can use tokens with the `security_events` or `public_repo` scope.\nGitHub Apps must have the `contents` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#get-codeql-database", - "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "location", + "description": "The requested location for a new codespace. Best efforts are made to respect this upon creation. Assigned by IP if not provided.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12290,12 +16815,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "geo", + "description": "The geographic area for this codespace. If not specified, the value is assigned by IP. This property replaces `location`, which is being deprecated.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["EuropeWest", "SoutheastAsia", "UsEast", "UsWest"], "allowNull": false, "mapToData": null, "validation": null, @@ -12303,49 +16828,24 @@ "deprecated": null }, { - "name": "language", - "description": "The language of the CodeQL database.", - "in": "PATH", + "name": "client_ip", + "description": "IP for location auto-detection when proxying a request", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 302, "description": "Found" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "Get information about a SARIF upload", - "scope": "codeScanning", - "id": "getSarif", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/sarifs/{sarif_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets information about a SARIF upload, including the status and the URL of the analysis that was uploaded so that you can retrieve details of the analysis. For more information, see \"[Get a code scanning analysis for a repository](/rest/reference/code-scanning#get-a-code-scanning-analysis-for-a-repository).\" You must use an access token with the `security_events` scope to use this endpoint with private repos, the `public_repo` scope also grants permission to read security events on public repos only. GitHub Apps must have the `security_events` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-recent-code-scanning-analyses-for-a-repository", - "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "machine", + "description": "Machine type to use for this codespace", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12354,11 +16854,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "devcontainer_path", + "description": "Path to devcontainer.json config to use for this codespace", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12367,51 +16867,24 @@ "deprecated": null }, { - "name": "sarif_id", - "description": "The SARIF ID obtained after uploading.", - "in": "PATH", - "type": "string", - "required": true, + "name": "multi_repo_permissions_opt_out", + "description": "Whether to authorize requested permissions from devcontainer.json", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, - { - "code": 404, - "description": "Not Found if the sarif id does not match any upload" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "List instances of a code scanning alert", - "scope": "codeScanning", - "id": "listAlertInstances", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all instances of the specified code scanning alert.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-instances-of-a-code-scanning-alert", - "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "working_directory", + "description": "Working directory for this codespace", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12420,11 +16893,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "idle_timeout_minutes", + "description": "Time in minutes before codespace stops from inactivity", + "in": "BODY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12433,11 +16906,11 @@ "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "display_name", + "description": "Display name for this codespace", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12446,9 +16919,9 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "retention_period_minutes", + "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", + "in": "BODY", "type": "integer", "required": false, "enum": null, @@ -12457,13 +16930,55 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 201, + "description": "Response when the codespace was successfully created" }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "code": 202, + "description": "Response when the codespace creation partially failed but is being retried in the background" + }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "Create a codespace in a repository", + "scope": "codespaces", + "id": "createWithRepoForAuthenticatedUser", + "method": "POST", + "url": "/repos/{owner}/{repo}/codespaces", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a codespace owned by the authenticated user in the specified repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-in-a-repository", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -12473,8 +16988,8 @@ }, { "name": "ref", - "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", - "in": "QUERY", + "description": "Git ref (typically a branch name) for this codespace", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -12483,37 +16998,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "List code scanning alerts for an enterprise", - "scope": "codeScanning", - "id": "listAlertsForEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/code-scanning/alerts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists code scanning alerts for the default branch for all eligible repositories in an enterprise. Eligible repositories are repositories that are owned by organizations that you own or for which you are a security manager. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nTo use this endpoint, you must be a member of the enterprise,\nand you must use an access token with the `repo` scope or `security_events` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-alerts-for-an-enterprise", - "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", - "in": "PATH", + "name": "location", + "description": "The requested location for a new codespace. Best efforts are made to respect this upon creation. Assigned by IP if not provided.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -12522,12 +17013,12 @@ "deprecated": null }, { - "name": "tool_name", - "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", - "in": "QUERY", + "name": "geo", + "description": "The geographic area for this codespace. If not specified, the value is assigned by IP. This property replaces `location`, which is being deprecated.", + "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["EuropeWest", "SoutheastAsia", "UsEast", "UsWest"], "allowNull": false, "mapToData": null, "validation": null, @@ -12535,9 +17026,9 @@ "deprecated": null }, { - "name": "tool_guid", - "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", - "in": "QUERY", + "name": "client_ip", + "description": "IP for location auto-detection when proxying a request", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -12548,9 +17039,9 @@ "deprecated": null }, { - "name": "before", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor.", - "in": "QUERY", + "name": "machine", + "description": "Machine type to use for this codespace", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -12561,9 +17052,9 @@ "deprecated": null }, { - "name": "after", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor.", - "in": "QUERY", + "name": "devcontainer_path", + "description": "Path to devcontainer.json config to use for this codespace", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -12574,10 +17065,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "multi_repo_permissions_opt_out", + "description": "Whether to authorize requested permissions from devcontainer.json", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -12587,10 +17078,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "working_directory", + "description": "Working directory for this codespace", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -12600,12 +17091,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", + "name": "idle_timeout_minutes", + "description": "Time in minutes before codespace stops from inactivity", + "in": "BODY", + "type": "integer", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12613,12 +17104,12 @@ "deprecated": null }, { - "name": "state", - "description": "If specified, only code scanning alerts with this state will be returned.", - "in": "QUERY", + "name": "display_name", + "description": "Display name for this codespace", + "in": "BODY", "type": "string", "required": false, - "enum": ["open", "closed", "dismissed", "fixed"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12626,12 +17117,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property by which to sort the results.", - "in": "QUERY", - "type": "string", + "name": "retention_period_minutes", + "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", + "in": "BODY", + "type": "integer", "required": false, - "enum": ["created", "updated"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12640,27 +17131,34 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" + "code": 201, + "description": "Response when the codespace was successfully created" + }, + { + "code": 202, + "description": "Response when the codespace creation partially failed but is being retried in the background" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "List code scanning alerts for an organization", - "scope": "codeScanning", - "id": "listAlertsForOrg", - "method": "GET", - "url": "/orgs/{org}/code-scanning/alerts", + "name": "Removes users from Codespaces billing for an organization", + "scope": "codespaces", + "id": "deleteCodespacesBillingUsers", + "method": "DELETE", + "url": "/orgs/{org}/codespaces/billing/selected_users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists code scanning alerts for the default branch for all eligible repositories in an organization. Eligible repositories are repositories that are owned by organizations that you own or for which you are a security manager. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nTo use this endpoint, you must be an owner or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.\n\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `security_events` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-alerts-by-organization", + "description": "Codespaces for the specified users will no longer be billed to the organization.\nTo use this endpoint, the billing settings for the organization must be set to `selected_members`. For information on how to change this setting please see [these docs].(https://docs.github.com/enterprise-cloud@latest//rest/codespaces/organizations#manage-access-control-for-organization-codespaces) You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-codespaces-billing-users", "parameters": [ { "name": "org", @@ -12676,63 +17174,92 @@ "deprecated": null }, { - "name": "tool_name", - "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "selected_usernames", + "description": "The usernames of the organization members whose codespaces should not be billed to the organization.", + "in": "BODY", + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 204, + "description": "Response when successfully modifying permissions." }, + { "code": 304, "description": "Not modified" }, { - "name": "tool_guid", - "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 400, + "description": "Users are neither members nor collaborators of this organization." }, + { "code": 404, "description": "Resource not found" }, { - "name": "before", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Delete a codespace for the authenticated user", + "scope": "codespaces", + "id": "deleteForAuthenticatedUser", + "method": "DELETE", + "url": "/user/codespaces/{codespace_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-codespace-for-the-authenticated-user", + "parameters": [ { - "name": "after", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor.", - "in": "QUERY", + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Delete a codespace from the organization", + "scope": "codespaces", + "id": "deleteFromOrganization", + "method": "DELETE", + "url": "/orgs/{org}/members/{username}/codespaces/{codespace_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a user's codespace.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -12741,11 +17268,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -12754,25 +17281,48 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Delete an organization secret", + "scope": "codespaces", + "id": "deleteOrgSecret", + "method": "DELETE", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes an organization secret using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-an-organization-secret", + "parameters": [ { - "name": "state", - "description": "If specified, only code scanning alerts with this state will be returned.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "dismissed", "fixed"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12780,12 +17330,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property by which to sort the results.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12794,27 +17344,22 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List code scanning alerts for a repository", - "scope": "codeScanning", - "id": "listAlertsForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/alerts", + "name": "Delete a repository secret", + "scope": "codespaces", + "id": "deleteRepoSecret", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists code scanning alerts.\n\nTo use this endpoint, you must use an access token with the `security_events` scope or, for alerts from public repositories only, an access token with the `public_repo` scope.\n\nGitHub Apps must have the `security_events` read\npermission to use this endpoint.\n\nThe response includes a `most_recent_instance` object.\nThis provides details of the most recent instance of this alert\nfor the default branch (or for the specified Git reference if you used `ref` in the request).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-alerts-for-a-repository", + "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have write access to the `codespaces_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-repository-secret", "parameters": [ { "name": "owner", @@ -12831,7 +17376,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -12843,44 +17388,102 @@ "deprecated": null }, { - "name": "tool_name", - "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a secret for the authenticated user", + "scope": "codespaces", + "id": "deleteSecretForAuthenticatedUser", + "method": "DELETE", + "url": "/user/codespaces/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a secret from a user's codespaces using the secret name. Deleting the secret will remove access from all codespaces that were allowed to access the secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-secret-for-the-authenticated-user", + "parameters": [ { - "name": "tool_guid", - "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Export a codespace for the authenticated user", + "scope": "codespaces", + "id": "exportForAuthenticatedUser", + "method": "POST", + "url": "/user/codespaces/{codespace_name}/exports", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Triggers an export of the specified codespace and returns a URL and ID where the status of the export can be monitored.\n\nIf changes cannot be pushed to the codespace's repository, they will be pushed to a new or previously-existing fork instead.\n\nYou must authenticate using a personal access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/codespaces/codespaces#export-a-codespace-for-the-authenticated-user", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 202, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "List codespaces for a user in organization", + "scope": "codespaces", + "id": "getCodespacesForUserInOrg", + "method": "GET", + "url": "/orgs/{org}/members/{username}/codespaces", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the codespaces that a member of an organization has for repositories in that organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-codespaces-for-user-in-org", + "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -12895,10 +17498,10 @@ "deprecated": null }, { - "name": "ref", - "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -12908,12 +17511,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12921,12 +17524,48 @@ "deprecated": null }, { - "name": "sort", - "description": "The property by which to sort the results.", - "in": "QUERY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Get details about a codespace export", + "scope": "codespaces", + "id": "getExportDetailsForAuthenticatedUser", + "method": "GET", + "url": "/user/codespaces/{codespace_name}/exports/{export_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets information about an export of a codespace.\n\nYou must authenticate using a personal access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/codespaces/codespaces#get-details-about-a-codespace-export", + "parameters": [ + { + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12934,12 +17573,12 @@ "deprecated": null }, { - "name": "state", - "description": "If specified, only code scanning alerts with this state will be returned.", - "in": "QUERY", + "name": "export_id", + "description": "The ID of the export operation, or `latest`. Currently only `latest` is currently supported.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "dismissed", "fixed"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -12949,31 +17588,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List instances of a code scanning alert", - "scope": "codeScanning", - "id": "listAlertsInstances", + "name": "Get a codespace for the authenticated user", + "scope": "codespaces", + "id": "getForAuthenticatedUser", "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances", + "url": "/user/codespaces/{codespace_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all instances of the specified code scanning alert.\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-instances-of-a-code-scanning-alert", + "description": "Gets information about a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-codespace-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "codespace_name", + "description": "The name of the codespace.", "in": "PATH", "type": "string", "required": true, @@ -12983,10 +17616,33 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Get an organization public key", + "scope": "codespaces", + "id": "getOrgPublicKey", + "method": "GET", + "url": "/orgs/{org}/codespaces/secrets/public-key", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a public key for an organization, which is required in order to encrypt secrets. You need to encrypt the value of a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-public-key", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -12996,12 +17652,28 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get an organization secret", + "scope": "codespaces", + "id": "getOrgSecret", + "method": "GET", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets an organization secret without revealing its encrypted value.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-secret", + "parameters": [ { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -13011,37 +17683,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "ref", - "description": "The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13050,33 +17696,35 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": { - "before": { "scope": "codeScanning", "id": "listAlertsInstances" }, - "after": { "scope": "codeScanning", "id": "listAlertInstances" }, - "date": "2021-04-30", - "note": null - } + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null }, { - "name": "List CodeQL databases for a repository", - "scope": "codeScanning", - "id": "listCodeqlDatabases", + "name": "Get public key for the authenticated user", + "scope": "codespaces", + "id": "getPublicKeyForAuthenticatedUser", "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/codeql/databases", + "url": "/user/codespaces/secrets/public-key", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the CodeQL databases that are available in a repository.\n\nFor private repositories, you must use an access token with the `security_events` scope.\nFor public repositories, you can use tokens with the `security_events` or `public_repo` scope.\nGitHub Apps must have the `contents` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-codeql-databases", + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-public-key-for-the-authenticated-user", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a repository public key", + "scope": "codespaces", + "id": "getRepoPublicKey", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces/secrets/public-key", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have write access to the `codespaces_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-public-key", "parameters": [ { "name": "owner", @@ -13093,7 +17741,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -13105,28 +17753,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List code scanning analyses for a repository", - "scope": "codeScanning", - "id": "listRecentAnalyses", + "name": "Get a repository secret", + "scope": "codespaces", + "id": "getRepoSecret", "method": "GET", - "url": "/repos/{owner}/{repo}/code-scanning/analyses", + "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the details of all code scanning analyses for a repository,\nstarting with the most recent.\nThe response is paginated and you can use the `page` and `per_page` parameters\nto list the analyses you're interested in.\nBy default 30 analyses are listed per page.\n\nThe `rules_count` field in the response give the number of rules\nthat were run in the analysis.\nFor very old analyses this data is not available,\nand `0` is returned in this field.\n\nYou must use an access token with the `security_events` scope to use this endpoint with private repos,\nthe `public_repo` scope also grants permission to read security events on public repos only.\nGitHub Apps must have the `security_events` read permission to use this endpoint.\n\n**Deprecation notice**:\nThe `tool_name` field is deprecated and will, in future, not be included in the response for this endpoint. The example response reflects this change. The tool name can now be found inside the `tool` field.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#list-code-scanning-analyses-for-a-repository", + "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have write access to the `codespaces_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-secret", "parameters": [ { "name": "owner", @@ -13143,7 +17783,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -13155,44 +17795,63 @@ "deprecated": null }, { - "name": "tool_name", - "description": "The name of a code scanning tool. Only results by this tool will be listed. You can specify the tool by using either `tool_name` or `tool_guid`, but not both.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a secret for the authenticated user", + "scope": "codespaces", + "id": "getSecretForAuthenticatedUser", + "method": "GET", + "url": "/user/codespaces/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a secret available to a user's codespaces without revealing its encrypted value.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-secret-for-the-authenticated-user", + "parameters": [ { - "name": "tool_guid", - "description": "The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.", - "in": "QUERY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List devcontainer configurations in a repository for the authenticated user", + "scope": "codespaces", + "id": "listDevcontainersInRepositoryForAuthenticatedUser", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces/devcontainers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the devcontainer.json files associated with a specified repository and the authenticated user. These files\nspecify launchpoint configurations for codespaces created within the repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_metadata` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-devcontainers-in-a-repository-for-the-authenticated-user", + "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -13207,10 +17866,10 @@ "deprecated": null }, { - "name": "ref", - "description": "The Git reference for the analyses you want to list. The `ref` for a branch can be formatted either as `refs/heads/` or simply ``. To reference a pull request use `refs/pull//merge`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -13220,11 +17879,11 @@ "deprecated": null }, { - "name": "sarif_id", - "description": "Filter analyses belonging to the same SARIF upload.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13233,25 +17892,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "sort", - "description": "The property by which to sort the results.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -13261,46 +17907,33 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if GitHub Advanced Security is not enabled for this repository" - }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Update a code scanning alert", - "scope": "codeScanning", - "id": "updateAlert", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}", + "name": "List codespaces for the authenticated user", + "scope": "codespaces", + "id": "listForAuthenticatedUser", + "method": "GET", + "url": "/user/codespaces", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates the status of a single code scanning alert. You must use an access token with the `security_events` scope to use this endpoint with private repositories. You can also use tokens with the `public_repo` scope for public repositories only. GitHub Apps must have the `security_events` write permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#update-a-code-scanning-alert", + "description": "Lists the authenticated user's codespaces.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-codespaces-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13309,11 +17942,11 @@ "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13322,39 +17955,13 @@ "deprecated": null }, { - "name": "state", - "description": "Sets the state of the code scanning alert. You must provide `dismissed_reason` when you set the state to `dismissed`.", - "in": "BODY", - "type": "string", - "required": true, - "enum": ["open", "dismissed"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "dismissed_reason", - "description": "**Required when the state is dismissed.** The reason for dismissing or closing the alert.", - "in": "BODY", - "type": "string", - "required": false, - "enum": [null, "false positive", "won't fix", "used in tests"], - "allowNull": true, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "dismissed_comment", - "description": "The dismissal comment associated with the dismissal of the alert.", - "in": "BODY", - "type": "string", + "name": "repository_id", + "description": "ID of the Repository to filter on", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, @@ -13363,33 +17970,32 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 403, - "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" - }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Upload an analysis as SARIF data", - "scope": "codeScanning", - "id": "uploadSarif", - "method": "POST", - "url": "/repos/{owner}/{repo}/code-scanning/sarifs", + "name": "List codespaces for the organization", + "scope": "codespaces", + "id": "listInOrganization", + "method": "GET", + "url": "/orgs/{org}/codespaces", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Uploads SARIF data containing the results of a code scanning analysis to make the results available in a repository. You must use an access token with the `security_events` scope to use this endpoint for private repositories. You can also use tokens with the `public_repo` scope for public repositories only. GitHub Apps must have the `security_events` write permission to use this endpoint.\n\nThere are two places where you can upload code scanning results.\n - If you upload to a pull request, for example `--ref refs/pull/42/merge` or `--ref refs/pull/42/head`, then the results appear as alerts in a pull request check. For more information, see \"[Triaging code scanning alerts in pull requests](/code-security/secure-coding/triaging-code-scanning-alerts-in-pull-requests).\"\n - If you upload to a branch, for example `--ref refs/heads/my-branch`, then the results appear in the **Security** tab for your repository. For more information, see \"[Managing code scanning alerts for your repository](/code-security/secure-coding/managing-code-scanning-alerts-for-your-repository#viewing-the-alerts-for-a-repository).\"\n\nYou must compress the SARIF-formatted analysis data that you want to upload, using `gzip`, and then encode it as a Base64 format string. For example:\n\n```\ngzip -c analysis-data.sarif | base64 -w0\n```\n\nSARIF upload supports a maximum of 5000 results per analysis run. Any results over this limit are ignored and any SARIF uploads with more than 25,000 results are rejected. Typically, but not necessarily, a SARIF file contains a single run of a single tool. If a code scanning tool generates too many results, you should update the analysis configuration to run only the most important rules or queries.\n\nThe `202 Accepted`, response includes an `id` value.\nYou can use this ID to check the status of the upload by using this for the `/sarifs/{sarif_id}` endpoint.\nFor more information, see \"[Get information about a SARIF upload](/rest/reference/code-scanning#get-information-about-a-sarif-upload).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/code-scanning#upload-a-sarif-file", + "description": "Lists the codespaces associated to a specified organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-in-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13398,11 +18004,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13411,37 +18017,60 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit to which the analysis you are uploading relates.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^[0-9a-fA-F]+$", + "validation": null, "alias": null, "deprecated": null }, { - "name": "ref", - "description": "The full Git reference, formatted as `refs/heads/`,\n`refs/pull//merge`, or `refs/pull//head`.", - "in": "BODY", + "name": "org_id", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, - "alias": null, - "deprecated": null - }, + "alias": "org", + "deprecated": true + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "List codespaces in a repository for the authenticated user", + "scope": "codespaces", + "id": "listInRepositoryForAuthenticatedUser", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the codespaces associated to a specified repository and the authenticated user.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-codespaces-in-a-repository-for-the-authenticated-user", + "parameters": [ { - "name": "sarif", - "description": "A Base64 string representing the SARIF file to upload. You must first compress your SARIF file using [`gzip`](http://www.gnu.org/software/gzip/manual/gzip.html) and then translate the contents of the file into a Base64 encoding string. For more information, see \"[SARIF support for code scanning](https://docs.github.com/enterprise-cloud@latest//code-security/secure-coding/sarif-support-for-code-scanning).\"", - "in": "BODY", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13450,10 +18079,10 @@ "deprecated": null }, { - "name": "checkout_uri", - "description": "The base directory used in the analysis, as it appears in the SARIF file.\nThis property is used to convert file paths from absolute to relative, so that alerts can be mapped to their correct location in the repository.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -13463,11 +18092,11 @@ "deprecated": null }, { - "name": "started_at", - "description": "The time that the analysis run began. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13476,11 +18105,11 @@ "deprecated": null }, { - "name": "tool_name", - "description": "The name of the tool used to generate the code scanning analysis. If this parameter is not used, the tool name defaults to \"API\". If the uploaded SARIF contains a tool GUID, this will be available for filtering using the `tool_guid` parameter of operations such as `GET /repos/{owner}/{repo}/code-scanning/alerts`.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13489,58 +18118,30 @@ "deprecated": null } ], - "responses": [ - { "code": 202, "description": "Response" }, - { - "code": 400, - "description": "Bad Request if the sarif field is invalid" - }, - { - "code": 403, - "description": "Response if the repository is archived or if GitHub Advanced Security is not enabled for this repository" - }, - { "code": 404, "description": "Resource not found" }, - { - "code": 413, - "description": "Payload Too Large if the sarif field is too large" - }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "Get all codes of conduct", - "scope": "codesOfConduct", - "id": "getAllCodesOfConduct", - "method": "GET", - "url": "/codes_of_conduct", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codes-of-conduct#get-all-codes-of-conduct", - "parameters": [], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Get a code of conduct", - "scope": "codesOfConduct", - "id": "getConductCode", + "name": "List organization secrets", + "scope": "codespaces", + "id": "listOrgSecrets", "method": "GET", - "url": "/codes_of_conduct/{key}", + "url": "/orgs/{org}/codespaces/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codes-of-conduct#get-a-code-of-conduct", + "description": "Lists all Codespaces secrets available at the organization-level without revealing their encrypted values.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-organization-secrets", "parameters": [ { - "name": "key", - "description": "", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -13550,33 +18151,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Add a selected repository to a user secret", - "scope": "codespaces", - "id": "addRepositoryForSecretForAuthenticatedUser", - "method": "PUT", - "url": "/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Adds a repository to the selected repositories for a user's codespace secret.\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on the referenced repository to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-a-selected-repository-to-a-user-secret", - "parameters": [ + }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13585,11 +18166,11 @@ "deprecated": null }, { - "name": "repository_id", - "description": "", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13598,33 +18179,24 @@ "deprecated": null } ], - "responses": [ - { - "code": 204, - "description": "No Content when repository was added to the selected list" - }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Add selected repository to an organization secret", + "name": "List repository secrets", "scope": "codespaces", - "id": "addSelectedRepoToOrgSecret", - "method": "PUT", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", + "id": "listRepoSecrets", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Adds a repository to an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-selected-repository-to-an-organization-secret", + "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have write access to the `codespaces_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-repository-secrets", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -13636,8 +18208,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -13649,51 +18221,50 @@ "deprecated": null }, { - "name": "repository_id", - "description": "", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "No Content when repository was added to the selected list" - }, - { "code": 404, "description": "Resource not found" }, - { - "code": 409, - "description": "Conflict when visibility type is not set to selected" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List machine types for a codespace", + "name": "List selected repositories for a user secret", "scope": "codespaces", - "id": "codespaceMachinesForAuthenticatedUser", + "id": "listRepositoriesForSecretForAuthenticatedUser", "method": "GET", - "url": "/user/codespaces/{codespace_name}/machines", + "url": "/user/codespaces/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the machine types a codespace can transition to use.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_metadata` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-machine-types-for-a-codespace", + "description": "List the repositories that have been granted the ability to use a user's codespace secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret", "parameters": [ { - "name": "codespace_name", - "description": "The name of the codespace.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -13707,7 +18278,6 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, @@ -13716,35 +18286,22 @@ "renamed": null }, { - "name": "Create a codespace for the authenticated user", + "name": "List secrets for the authenticated user", "scope": "codespaces", - "id": "createForAuthenticatedUser", - "method": "POST", - "url": "/user/codespaces", + "id": "listSecretsForAuthenticatedUser", + "method": "GET", + "url": "/user/codespaces/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new codespace, owned by the authenticated user.\n\nThis endpoint requires either a `repository_id` OR a `pull_request` but not both.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-for-the-authenticated-user", + "description": "Lists all secrets available for a user's Codespaces without revealing their\nencrypted values.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-secrets-for-the-authenticated-user", "parameters": [ { - "name": "repository_id", - "description": "Repository id for this codespace", - "in": "BODY", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "ref", - "description": "Git ref (typically a branch name) for this codespace", - "in": "BODY", - "type": "string", "required": false, "enum": null, "allowNull": false, @@ -13754,10 +18311,10 @@ "deprecated": null }, { - "name": "location", - "description": "Location for this codespace. Assigned by IP if not provided", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -13765,13 +18322,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List selected repositories for an organization secret", + "scope": "codespaces", + "id": "listSelectedReposForOrgSecret", + "method": "GET", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-an-organization-secret", + "parameters": [ { - "name": "client_ip", - "description": "IP for location auto-detection when proxying a request", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13780,11 +18353,11 @@ "deprecated": null }, { - "name": "machine", - "description": "Machine type to use for this codespace", - "in": "BODY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13793,10 +18366,10 @@ "deprecated": null }, { - "name": "devcontainer_path", - "description": "Path to devcontainer.json config to use for this codespace", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -13806,10 +18379,10 @@ "deprecated": null }, { - "name": "multi_repo_permissions_opt_out", - "description": "Whether to authorize requested permissions from devcontainer.json", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -13817,13 +18390,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get default attributes for a codespace", + "scope": "codespaces", + "id": "preFlightWithRepoForAuthenticatedUser", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces/new", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets the default attributes for codespaces created by the user with the repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#preview-attributes-for-a-new-codespace", + "parameters": [ { - "name": "working_directory", - "description": "Working directory for this codespace", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13832,11 +18424,11 @@ "deprecated": null }, { - "name": "idle_timeout_minutes", - "description": "Time in minutes before codespace stops from inactivity", - "in": "BODY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13845,9 +18437,9 @@ "deprecated": null }, { - "name": "display_name", - "description": "Display name for this codespace", - "in": "BODY", + "name": "ref", + "description": "The branch or commit to check for a default devcontainer path. If not specified, the default branch will be checked.", + "in": "QUERY", "type": "string", "required": false, "enum": null, @@ -13858,10 +18450,10 @@ "deprecated": null }, { - "name": "retention_period_minutes", - "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", - "in": "BODY", - "type": "integer", + "name": "client_ip", + "description": "An alternative IP for default location auto-detection, such as when proxying a request.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -13869,12 +18461,36 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "Response when a user is able to create codespaces from the repository." }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Create a repository from an unpublished codespace", + "scope": "codespaces", + "id": "publishForAuthenticatedUser", + "method": "POST", + "url": "/user/codespaces/{codespace_name}/publish", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Publishes an unpublished codespace, creating a new repository and assigning it to the codespace.\n\nThe codespace's token is granted write permissions to the repository, allowing the user to push their changes.\n\nThis will fail for a codespace that is already published, meaning it has an associated repository.\n\nYou must authenticate using a personal access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces/codespaces#create-a-repository-from-an-unpublished-codespace", + "parameters": [ { - "name": "pull_request", - "description": "Pull request number for this codespace", - "in": "BODY", - "type": "object", + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -13884,11 +18500,11 @@ "deprecated": null }, { - "name": "pull_request.pull_request_number", - "description": "Pull request number", + "name": "name", + "description": "A name for the new repository.", "in": "BODY", - "type": "integer", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13897,11 +18513,11 @@ "deprecated": null }, { - "name": "pull_request.repository_id", - "description": "Repository id for this codespace", + "name": "private", + "description": "Whether the new repository should be private.", "in": "BODY", - "type": "integer", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -13911,35 +18527,32 @@ } ], "responses": [ - { - "code": 201, - "description": "Response when the codespace was successfully created" - }, - { - "code": 202, - "description": "Response when the codespace creation partially failed but is being retried in the background" - }, + { "code": 201, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Create or update an organization secret", + "name": "Remove a selected repository from a user secret", "scope": "codespaces", - "id": "createOrUpdateOrgSecret", - "method": "PUT", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}", + "id": "removeRepositoryForSecretForAuthenticatedUser", + "method": "DELETE", + "url": "/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `admin:org` scope to use this endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\n// Written with ❤️ by PSJ and free to use under The Unlicense.\nconst sodium=require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with secret before running the script.\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key.\n\n//Check if libsodium is ready and then proceed.\n\nsodium.ready.then( ()=>{\n\n// Convert Secret & Base64 key to Uint8Array.\nlet binkey= sodium.from_base64(key, sodium.base64_variants.ORIGINAL) //Equivalent of Buffer.from(key, 'base64')\nlet binsec= sodium.from_string(secret) // Equivalent of Buffer.from(secret)\n\n//Encrypt the secret using LibSodium\nlet encBytes= sodium.crypto_box_seal(binsec,binkey) // Similar to tweetsodium.seal(binsec,binkey)\n\n// Convert encrypted Uint8Array to Base64\nlet output=sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL) //Equivalent of Buffer.from(encBytes).toString('base64')\n\nconsole.log(output)\n});\n```\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret", + "description": "Removes a repository from the selected repositories for a user's codespace secret.\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -13951,10 +18564,10 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repository_id", + "description": "", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -13962,26 +18575,38 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ { - "name": "encrypted_value", - "description": "The value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get an organization public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-public-key) endpoint.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", - "alias": null, - "deprecated": null + "code": 204, + "description": "No Content when repository was removed from the selected list" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Remove selected repository from an organization secret", + "scope": "codespaces", + "id": "removeSelectedRepoFromOrgSecret", + "method": "DELETE", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret", + "parameters": [ { - "name": "key_id", - "description": "The ID of the key you used to encrypt the secret.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -13990,12 +18615,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "Which type of organization repositories have access to the organization secret. `selected` means only the repositories specified by `selected_repository_ids` can access the secret.", - "in": "BODY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", "required": true, - "enum": ["all", "private", "selected"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -14003,11 +18628,11 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "An array of repository IDs that can access the organization secret. You can only provide a list of repository IDs when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret) endpoints.", - "in": "BODY", - "type": "integer[]", - "required": false, + "name": "repository_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14017,9 +18642,15 @@ } ], "responses": [ - { "code": 201, "description": "Response when creating a secret" }, - { "code": 204, "description": "Response when updating a secret" }, + { + "code": 204, + "description": "Response when repository was removed from the selected list" + }, { "code": 404, "description": "Resource not found" }, + { + "code": 409, + "description": "Conflict when visibility type not set to selected" + }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -14028,16 +18659,16 @@ "renamed": null }, { - "name": "Create or update a repository secret", + "name": "List available machine types for a repository", "scope": "codespaces", - "id": "createOrUpdateRepoSecret", - "method": "PUT", - "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", + "id": "repoMachinesForAuthenticatedUser", + "method": "GET", + "url": "/repos/{owner}/{repo}/codespaces/machines", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `codespaces_secrets` repository\npermission to use this endpoint.\n\n#### Example of encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example of encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example of encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example of encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-a-repository-secret", + "description": "List the machine types available for a given repository based on its configuration.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_metadata` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-available-machine-types-for-a-repository", "parameters": [ { "name": "owner", @@ -14054,7 +18685,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14066,11 +18697,11 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", + "name": "location", + "description": "The location to check for available machines. Assigned by IP if not provided.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -14079,23 +18710,77 @@ "deprecated": null }, { - "name": "encrypted_value", - "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get a repository public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-public-key) endpoint.", - "in": "BODY", + "name": "client_ip", + "description": "IP for location auto-detection when proxying a request", + "in": "QUERY", "type": "string", "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Manage access control for organization codespaces", + "scope": "codespaces", + "id": "setCodespacesBilling", + "method": "PUT", + "url": "/orgs/{org}/codespaces/billing", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Sets which users can access codespaces in an organization. This is synonymous with granting or revoking codespaces billing permissions for users according to the visibility.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, "alias": null, "deprecated": null }, { - "name": "key_id", - "description": "ID of the key you used to encrypt the secret.", + "name": "visibility", + "description": "Which users can access codespaces in the organization. `disabled` means that no users can access codespaces in the organization.", "in": "BODY", "type": "string", + "required": true, + "enum": [ + "disabled", + "selected_members", + "all_members", + "all_members_and_outside_collaborators" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "selected_usernames", + "description": "The usernames of the organization members who should have access to codespaces in the organization. Required when `visibility` is `selected_members`. The provided list of usernames will replace any existing value.", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -14106,26 +18791,39 @@ } ], "responses": [ - { "code": 201, "description": "Response when creating a secret" }, - { "code": 204, "description": "Response when updating a secret" } + { + "code": 204, + "description": "Response when successfully modifying permissions." + }, + { "code": 304, "description": "Not modified" }, + { + "code": 400, + "description": "Users are neither members nor collaborators of this organization." + }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Create or update a secret for the authenticated user", + "name": "Add users to Codespaces billing for an organization", "scope": "codespaces", - "id": "createOrUpdateSecretForAuthenticatedUser", - "method": "PUT", - "url": "/user/codespaces/secrets/{secret_name}", + "id": "setCodespacesBillingUsers", + "method": "POST", + "url": "/orgs/{org}/codespaces/billing/selected_users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates a secret for a user's codespace with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages).\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must also have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission and `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-a-secret-for-the-authenticated-user", + "description": "Codespaces for the specified users will be billed to the organization.\nTo use this endpoint, the billing settings for the organization must be set to `selected_members`. For information on how to change this setting please see [these docs].(https://docs.github.com/enterprise-cloud@latest//rest/codespaces/organizations#manage-access-control-for-organization-codespaces) You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-codespaces-billing-users", "parameters": [ { - "name": "secret_name", - "description": "The name of the secret.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14137,22 +18835,54 @@ "deprecated": null }, { - "name": "encrypted_value", - "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get the public key for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-the-public-key-for-the-authenticated-user) endpoint.", + "name": "selected_usernames", + "description": "The usernames of the organization members whose codespaces be billed to the organization.", "in": "BODY", - "type": "string", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 204, + "description": "Response when successfully modifying permissions." }, + { "code": 304, "description": "Not modified" }, { - "name": "key_id", - "description": "ID of the key you used to encrypt the secret.", - "in": "BODY", + "code": 400, + "description": "Users are neither members nor collaborators of this organization." + }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Set selected repositories for a user secret", + "scope": "codespaces", + "id": "setRepositoriesForSecretForAuthenticatedUser", + "method": "PUT", + "url": "/user/codespaces/secrets/{secret_name}/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Select the repositories that will use a user's codespace secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-a-user-secret", + "parameters": [ + { + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -14164,10 +18894,10 @@ }, { "name": "selected_repository_ids", - "description": "An array of repository ids that can access the user secret. You can manage the list of selected repositories using the [List selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret), [Set selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-a-user-secret), and [Remove a selected repository from a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret) endpoints.", + "description": "An array of repository ids for which a codespace can access the secret. You can manage the list of selected repositories using the [List selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret), [Add a selected repository to a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-a-selected-repository-to-a-user-secret), and [Remove a selected repository from a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret) endpoints.", "in": "BODY", - "type": "string[]", - "required": false, + "type": "integer[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14177,37 +18907,32 @@ } ], "responses": [ - { - "code": 201, - "description": "Response after successfully creaing a secret" - }, { "code": 204, - "description": "Response after successfully updating a secret" + "description": "No Content when repositories were added to the selected list" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Create a codespace from a pull request", + "name": "Set selected repositories for an organization secret", "scope": "codespaces", - "id": "createWithPrForAuthenticatedUser", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/codespaces", + "id": "setSelectedReposForOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/codespaces/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a codespace owned by the authenticated user for the specified pull request.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-from-a-pull-request", + "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14219,8 +18944,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -14232,10 +18957,10 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", - "in": "PATH", - "type": "integer", + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret) endpoints.", + "in": "BODY", + "type": "integer[]", "required": true, "enum": null, "allowNull": false, @@ -14243,39 +18968,111 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { - "name": "location", - "description": "Location for this codespace. Assigned by IP if not provided", - "in": "BODY", + "code": 409, + "description": "Conflict when visibility type not set to selected" + } + ], + "renamed": null + }, + { + "name": "Start a codespace for the authenticated user", + "scope": "codespaces", + "id": "startForAuthenticatedUser", + "method": "POST", + "url": "/user/codespaces/{codespace_name}/start", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Starts a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#start-a-codespace-for-the-authenticated-user", + "parameters": [ + { + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 402, "description": "Payment required" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Stop a codespace for the authenticated user", + "scope": "codespaces", + "id": "stopForAuthenticatedUser", + "method": "POST", + "url": "/user/codespaces/{codespace_name}/stop", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Stops a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#stop-a-codespace-for-the-authenticated-user", + "parameters": [ { - "name": "client_ip", - "description": "IP for location auto-detection when proxying a request", - "in": "BODY", + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Stop a codespace for an organization user", + "scope": "codespaces", + "id": "stopInOrganization", + "method": "POST", + "url": "/orgs/{org}/members/{username}/codespaces/{codespace_name}/stop", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Stops a user's codespace.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces", + "parameters": [ { - "name": "machine", - "description": "Machine type to use for this codespace", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14284,11 +19081,11 @@ "deprecated": null }, { - "name": "devcontainer_path", - "description": "Path to devcontainer.json config to use for this codespace", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14297,24 +19094,47 @@ "deprecated": null }, { - "name": "multi_repo_permissions_opt_out", - "description": "Whether to authorize requested permissions from devcontainer.json", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Update a codespace for the authenticated user", + "scope": "codespaces", + "id": "updateForAuthenticatedUser", + "method": "PATCH", + "url": "/user/codespaces/{codespace_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates a codespace owned by the authenticated user. Currently only the codespace's machine type and recent folders can be modified using this endpoint.\n\nIf you specify a new machine type it will be applied the next time your codespace is started.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#update-a-codespace-for-the-authenticated-user", + "parameters": [ { - "name": "working_directory", - "description": "Working directory for this codespace", - "in": "BODY", + "name": "codespace_name", + "description": "The name of the codespace.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14323,10 +19143,10 @@ "deprecated": null }, { - "name": "idle_timeout_minutes", - "description": "Time in minutes before codespace stops from inactivity", + "name": "machine", + "description": "A valid machine to transition this codespace to.", "in": "BODY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -14349,10 +19169,10 @@ "deprecated": null }, { - "name": "retention_period_minutes", - "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", + "name": "recent_folders", + "description": "Recently opened folders inside the codespace. It is currently used by the clients to determine the folder path to load the codespace in.", "in": "BODY", - "type": "integer", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -14363,14 +19183,7 @@ } ], "responses": [ - { - "code": 201, - "description": "Response when the codespace was successfully created" - }, - { - "code": 202, - "description": "Response when the codespace creation partially failed but is being retried in the background" - }, + { "code": 200, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } @@ -14378,20 +19191,20 @@ "renamed": null }, { - "name": "Create a codespace in a repository", - "scope": "codespaces", - "id": "createWithRepoForAuthenticatedUser", - "method": "POST", - "url": "/repos/{owner}/{repo}/codespaces", + "name": "Add selected repository to an organization secret", + "scope": "dependabot", + "id": "addSelectedRepoToOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a codespace owned by the authenticated user in the specified repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-a-codespace-in-a-repository", + "description": "Adds a repository to an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#add-selected-repository-to-an-organization-secret", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14403,8 +19216,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -14416,50 +19229,49 @@ "deprecated": null }, { - "name": "ref", - "description": "Git ref (typically a branch name) for this codespace", - "in": "BODY", - "type": "string", - "required": false, + "name": "repository_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ { - "name": "location", - "description": "Location for this codespace. Assigned by IP if not provided", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 204, + "description": "No Content when repository was added to the selected list" }, { - "name": "client_ip", - "description": "IP for location auto-detection when proxying a request", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + "code": 409, + "description": "Conflict when visibility type is not set to selected" + } + ], + "renamed": null + }, + { + "name": "Create or update an organization secret", + "scope": "dependabot", + "id": "createOrUpdateOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization\npermission to use this endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "documentationUrl": "https://docs.github.com/rest/reference/dependabot#create-or-update-an-organization-secret", + "parameters": [ { - "name": "machine", - "description": "Machine type to use for this codespace", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14468,24 +19280,11 @@ "deprecated": null }, { - "name": "devcontainer_path", - "description": "Path to devcontainer.json config to use for this codespace", - "in": "BODY", + "name": "secret_name", + "description": "The name of the secret.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "multi_repo_permissions_opt_out", - "description": "Whether to authorize requested permissions from devcontainer.json", - "in": "BODY", - "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -14494,23 +19293,23 @@ "deprecated": null }, { - "name": "working_directory", - "description": "Working directory for this codespace", + "name": "encrypted_value", + "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get an organization public key](https://docs.github.com/rest/reference/dependabot#get-an-organization-public-key) endpoint.", "in": "BODY", "type": "string", "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", "alias": null, "deprecated": null }, { - "name": "idle_timeout_minutes", - "description": "Time in minutes before codespace stops from inactivity", + "name": "key_id", + "description": "ID of the key you used to encrypt the secret.", "in": "BODY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -14520,12 +19319,12 @@ "deprecated": null }, { - "name": "display_name", - "description": "Display name for this codespace", + "name": "visibility", + "description": "Which type of organization repositories have access to the organization secret. `selected` means only the repositories specified by `selected_repository_ids` can access the secret.", "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["all", "private", "selected"], "allowNull": false, "mapToData": null, "validation": null, @@ -14533,10 +19332,10 @@ "deprecated": null }, { - "name": "retention_period_minutes", - "description": "Duration in minutes after codespace has gone idle in which it will be deleted. Must be integer minutes between 0 and 43200 (30 days).", + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/rest/reference/dependabot#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/rest/reference/dependabot#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/rest/reference/dependabot#remove-selected-repository-from-an-organization-secret) endpoints.", "in": "BODY", - "type": "integer", + "type": "undefined[]", "required": false, "enum": null, "allowNull": false, @@ -14547,37 +19346,26 @@ } ], "responses": [ - { - "code": 201, - "description": "Response when the codespace was successfully created" - }, - { - "code": 202, - "description": "Response when the codespace creation partially failed but is being retried in the background" - }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 201, "description": "Response when creating a secret" }, + { "code": 204, "description": "Response when updating a secret" } ], "renamed": null }, { - "name": "Delete a codespace for the authenticated user", - "scope": "codespaces", - "id": "deleteForAuthenticatedUser", - "method": "DELETE", - "url": "/user/codespaces/{codespace_name}", + "name": "Create or update a repository secret", + "scope": "dependabot", + "id": "createOrUpdateRepoSecret", + "method": "PUT", + "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-codespace-for-the-authenticated-user", + "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository\npermission to use this endpoint.\n\n**Example encrypting a secret using Node.js**\n\nEncrypt your secret using the [libsodium-wrappers](https://www.npmjs.com/package/libsodium-wrappers) library.\n\n```\nconst sodium = require('libsodium-wrappers')\nconst secret = 'plain-text-secret' // replace with the secret you want to encrypt\nconst key = 'base64-encoded-public-key' // replace with the Base64 encoded public key\n\n//Check if libsodium is ready and then proceed.\nsodium.ready.then(() => {\n // Convert Secret & Base64 key to Uint8Array.\n let binkey = sodium.from_base64(key, sodium.base64_variants.ORIGINAL)\n let binsec = sodium.from_string(secret)\n\n //Encrypt the secret using LibSodium\n let encBytes = sodium.crypto_box_seal(binsec, binkey)\n\n // Convert encrypted Uint8Array to Base64\n let output = sodium.to_base64(encBytes, sodium.base64_variants.ORIGINAL)\n\n console.log(output)\n});\n```\n\n**Example encrypting a secret using Python**\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n**Example encrypting a secret using C#**\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n**Example encrypting a secret using Ruby**\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-a-repository-secret", "parameters": [ { - "name": "codespace_name", - "description": "The name of the codespace.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14587,33 +19375,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 202, "description": "Accepted" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Delete a codespace from the organization", - "scope": "codespaces", - "id": "deleteFromOrganization", - "method": "DELETE", - "url": "/orgs/{org}/members/{username}/codespaces/{codespace_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Deletes a user's codespace.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14625,8 +19390,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -14638,11 +19403,24 @@ "deprecated": null }, { - "name": "codespace_name", - "description": "The name of the codespace.", - "in": "PATH", + "name": "encrypted_value", + "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get a repository public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-public-key) endpoint.", + "in": "BODY", "type": "string", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "alias": null, + "deprecated": null + }, + { + "name": "key_id", + "description": "ID of the key you used to encrypt the secret.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -14652,26 +19430,22 @@ } ], "responses": [ - { "code": 202, "description": "Accepted" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } + { "code": 201, "description": "Response when creating a secret" }, + { "code": 204, "description": "Response when updating a secret" } ], "renamed": null }, { "name": "Delete an organization secret", - "scope": "codespaces", + "scope": "dependabot", "id": "deleteOrgSecret", "method": "DELETE", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes an organization secret using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-an-organization-secret", + "description": "Deletes a secret in an organization using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#delete-an-organization-secret", "parameters": [ { "name": "org", @@ -14700,23 +19474,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { "name": "Delete a repository secret", - "scope": "codespaces", + "scope": "dependabot", "id": "deleteRepoSecret", "method": "DELETE", - "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `codespaces_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-repository-secret", + "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#delete-a-repository-secret", "parameters": [ { "name": "owner", @@ -14732,50 +19503,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete a secret for the authenticated user", - "scope": "codespaces", - "id": "deleteSecretForAuthenticatedUser", - "method": "DELETE", - "url": "/user/codespaces/secrets/{secret_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Deletes a secret from a user's codespaces using the secret name. Deleting the secret will remove access from all codespaces that were allowed to access the secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#delete-a-secret-for-the-authenticated-user", - "parameters": [ - { - "name": "secret_name", - "description": "The name of the secret.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14785,26 +19514,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Export a codespace for the authenticated user", - "scope": "codespaces", - "id": "exportForAuthenticatedUser", - "method": "POST", - "url": "/user/codespaces/{codespace_name}/exports", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Triggers an export of the specified codespace and returns a URL and ID where the status of the export can be monitored.\n\nYou must authenticate using a personal access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", - "documentationUrl": "", - "parameters": [ + }, { - "name": "codespace_name", - "description": "The name of the codespace.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -14816,34 +19529,24 @@ "deprecated": null } ], - "responses": [ - { "code": 202, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 500, "description": "Internal Error" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get details about a codespace export", - "scope": "codespaces", - "id": "getExportDetailsForAuthenticatedUser", + "name": "Get a Dependabot alert", + "scope": "dependabot", + "id": "getAlert", "method": "GET", - "url": "/user/codespaces/{codespace_name}/exports/{export_id}", + "url": "/repos/{owner}/{repo}/dependabot/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets information about an export of a codespace.\n\nYou must authenticate using a personal access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", - "documentationUrl": "", + "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-dependabot-alert", "parameters": [ { - "name": "codespace_name", - "description": "The name of the codespace.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14855,8 +19558,8 @@ "deprecated": null }, { - "name": "export_id", - "description": "The ID of the export operation, or `latest`. Currently only `latest` is currently supported.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -14866,31 +19569,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get a codespace for the authenticated user", - "scope": "codespaces", - "id": "getForAuthenticatedUser", - "method": "GET", - "url": "/user/codespaces/{codespace_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets information about a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-codespace-for-the-authenticated-user", - "parameters": [ + }, { - "name": "codespace_name", - "description": "The name of the codespace.", + "name": "alert_number", + "description": "The number that identifies a Dependabot alert in its repository.\nYou can find this at the end of the URL for a Dependabot alert within GitHub,\nor in `number` fields in the response from the\n`GET /repos/{owner}/{repo}/dependabot/alerts` operation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -14903,24 +19587,22 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { "name": "Get an organization public key", - "scope": "codespaces", + "scope": "dependabot", "id": "getOrgPublicKey", "method": "GET", - "url": "/organizations/{org}/codespaces/secrets/public-key", + "url": "/orgs/{org}/dependabot/secrets/public-key", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a public key for an organization, which is required in order to encrypt secrets. You need to encrypt the value of a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-public-key", + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-an-organization-public-key", "parameters": [ { "name": "org", @@ -14941,15 +19623,15 @@ }, { "name": "Get an organization secret", - "scope": "codespaces", + "scope": "dependabot", "id": "getOrgSecret", "method": "GET", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets an organization secret without revealing its encrypted value.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-an-organization-secret", + "description": "Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-an-organization-secret", "parameters": [ { "name": "org", @@ -14981,32 +19663,17 @@ "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, - { - "name": "Get public key for the authenticated user", - "scope": "codespaces", - "id": "getPublicKeyForAuthenticatedUser", - "method": "GET", - "url": "/user/codespaces/secrets/public-key", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-public-key-for-the-authenticated-user", - "parameters": [], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, { "name": "Get a repository public key", - "scope": "codespaces", + "scope": "dependabot", "id": "getRepoPublicKey", "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/secrets/public-key", + "url": "/repos/{owner}/{repo}/dependabot/secrets/public-key", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `codespaces_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-public-key", + "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-public-key", "parameters": [ { "name": "owner", @@ -15023,7 +19690,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15040,15 +19707,15 @@ }, { "name": "Get a repository secret", - "scope": "codespaces", + "scope": "dependabot", "id": "getRepoSecret", "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", + "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `codespaces_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-repository-secret", + "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-secret", "parameters": [ { "name": "owner", @@ -15065,7 +19732,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15094,20 +19761,20 @@ "renamed": null }, { - "name": "Get a secret for the authenticated user", - "scope": "codespaces", - "id": "getSecretForAuthenticatedUser", + "name": "List Dependabot alerts for an enterprise", + "scope": "dependabot", + "id": "listAlertsForEnterprise", "method": "GET", - "url": "/user/codespaces/secrets/{secret_name}", + "url": "/enterprises/{enterprise}/dependabot/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a secret available to a user's codespaces without revealing its encrypted value.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#get-a-secret-for-the-authenticated-user", + "description": "Lists Dependabot alerts for repositories that are owned by the specified enterprise.\nTo use this endpoint, you must be a member of the enterprise, and you must use an\naccess token with the `repo` scope or `security_events` scope.\nAlerts are only returned for organizations in the enterprise for which you are an organization owner or a security manager. For more information about security managers, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/dependabot/alerts#list-dependabot-alerts-for-an-enterprise", "parameters": [ { - "name": "secret_name", - "description": "The name of the secret.", + "name": "enterprise", + "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", "in": "PATH", "type": "string", "required": true, @@ -15117,28 +19784,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List devcontainer configurations in a repository for the authenticated user", - "scope": "codespaces", - "id": "listDevcontainersInRepositoryForAuthenticatedUser", - "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/devcontainers", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the devcontainer.json files associated with a specified repository and the authenticated user. These files\nspecify launchpoint configurations for codespaces created within the repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_metadata` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-devcontainers-in-a-repository-for-the-authenticated-user", - "parameters": [ + }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "state", + "description": "A comma-separated list of states. If specified, only alerts with these states will be returned.\n\nCan be: `auto_dismissed`, `dismissed`, `fixed`, `open`", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -15148,10 +19799,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "severity", + "description": "A comma-separated list of severities. If specified, only alerts with these severities will be returned.\n\nCan be: `low`, `medium`, `high`, `critical`", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -15161,11 +19812,11 @@ "deprecated": null }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "ecosystem", + "description": "A comma-separated list of ecosystems. If specified, only alerts for these ecosystems will be returned.\n\nCan be: `composer`, `go`, `maven`, `npm`, `nuget`, `pip`, `pub`, `rubygems`, `rust`", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -15174,11 +19825,115 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "package", + "description": "A comma-separated list of package names. If specified, only alerts for these packages will be returned.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "scope", + "description": "The scope of the vulnerable dependency. If specified, only alerts with this scope will be returned.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["development", "runtime"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property by which to sort the results.\n`created` means when the alert was created.\n`updated` means when the alert's state last changed.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "first", + "description": "**Deprecated**. The number of results per page (max 100), starting from the first matching result.\nThis parameter must not be used in combination with `last`.\nInstead, use `per_page` in combination with `after` to fetch the first page of results.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "last", + "description": "**Deprecated**. The number of results per page (max 100), starting from the last matching result.\nThis parameter must not be used in combination with `first`.\nInstead, use `per_page` in combination with `before` to fetch the last page of results.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -15189,30 +19944,161 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 304, "description": "Not modified" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List codespaces for the authenticated user", - "scope": "codespaces", - "id": "listForAuthenticatedUser", + "name": "List Dependabot alerts for an organization", + "scope": "dependabot", + "id": "listAlertsForOrg", "method": "GET", - "url": "/user/codespaces", + "url": "/orgs/{org}/dependabot/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the authenticated user's codespaces.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-codespaces-for-the-authenticated-user", + "description": "Lists Dependabot alerts for an organization.\n\nTo use this endpoint, you must be an owner or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.\n\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have **Dependabot alerts** read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/dependabot/alerts#list-dependabot-alerts-for-an-organization", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "A comma-separated list of states. If specified, only alerts with these states will be returned.\n\nCan be: `auto_dismissed`, `dismissed`, `fixed`, `open`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "severity", + "description": "A comma-separated list of severities. If specified, only alerts with these severities will be returned.\n\nCan be: `low`, `medium`, `high`, `critical`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ecosystem", + "description": "A comma-separated list of ecosystems. If specified, only alerts for these ecosystems will be returned.\n\nCan be: `composer`, `go`, `maven`, `npm`, `nuget`, `pip`, `pub`, `rubygems`, `rust`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "package", + "description": "A comma-separated list of package names. If specified, only alerts for these packages will be returned.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "scope", + "description": "The scope of the vulnerable dependency. If specified, only alerts with this scope will be returned.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["development", "runtime"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property by which to sort the results.\n`created` means when the alert was created.\n`updated` means when the alert's state last changed.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "first", + "description": "**Deprecated**. The number of results per page (max 100), starting from the first matching result.\nThis parameter must not be used in combination with `last`.\nInstead, use `per_page` in combination with `after` to fetch the first page of results.", "in": "QUERY", "type": "integer", "required": false, @@ -15224,8 +20110,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "last", + "description": "**Deprecated**. The number of results per page (max 100), starting from the last matching result.\nThis parameter must not be used in combination with `first`.\nInstead, use `per_page` in combination with `before` to fetch the last page of results.", "in": "QUERY", "type": "integer", "required": false, @@ -15237,8 +20123,8 @@ "deprecated": null }, { - "name": "repository_id", - "description": "ID of the Repository to filter on", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -15253,30 +20139,99 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List codespaces for the organization", - "scope": "codespaces", - "id": "listInOrganization", + "name": "List Dependabot alerts for a repository", + "scope": "dependabot", + "id": "listAlertsForRepo", "method": "GET", - "url": "/orgs/{org}/codespaces", + "url": "/repos/{owner}/{repo}/dependabot/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the codespaces associated to a specified organization.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-in-organization", + "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-dependabot-alerts-for-a-repository", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "A comma-separated list of states. If specified, only alerts with these states will be returned.\n\nCan be: `auto_dismissed`, `dismissed`, `fixed`, `open`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "severity", + "description": "A comma-separated list of severities. If specified, only alerts with these severities will be returned.\n\nCan be: `low`, `medium`, `high`, `critical`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ecosystem", + "description": "A comma-separated list of ecosystems. If specified, only alerts for these ecosystems will be returned.\n\nCan be: `composer`, `go`, `maven`, `npm`, `nuget`, `pip`, `pub`, `rubygems`, `rust`", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "package", + "description": "A comma-separated list of package names. If specified, only alerts for these packages will be returned.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -15286,10 +20241,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "manifest", + "description": "A comma-separated list of full manifest paths. If specified, only alerts for these manifests will be returned.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -15299,12 +20254,12 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "scope", + "description": "The scope of the vulnerable dependency. If specified, only alerts with this scope will be returned.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["development", "runtime"], "allowNull": false, "mapToData": null, "validation": null, @@ -15312,41 +20267,44 @@ "deprecated": null }, { - "name": "org_id", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "sort", + "description": "The property by which to sort the results.\n`created` means when the alert was created.\n`updated` means when the alert's state last changed.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "**Deprecated**. Page number of the results to fetch. Use cursor-based pagination with `before` or `after` instead.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, - "alias": "org", - "deprecated": true - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "List codespaces in a repository for the authenticated user", - "scope": "codespaces", - "id": "listInRepositoryForAuthenticatedUser", - "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the codespaces associated to a specified repository and the authenticated user.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-codespaces-in-a-repository-for-the-authenticated-user", - "parameters": [ + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -15361,10 +20319,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -15374,11 +20332,11 @@ "deprecated": null }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -15387,11 +20345,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "first", + "description": "**Deprecated**. The number of results per page (max 100), starting from the first matching result.\nThis parameter must not be used in combination with `last`.\nInstead, use `per_page` in combination with `after` to fetch the first page of results.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "last", + "description": "**Deprecated**. The number of results per page (max 100), starting from the last matching result.\nThis parameter must not be used in combination with `first`.\nInstead, use `per_page` in combination with `before` to fetch the last page of results.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -15402,24 +20373,29 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 304, "description": "Not modified" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { "name": "List organization secrets", - "scope": "codespaces", + "scope": "dependabot", "id": "listOrgSecrets", "method": "GET", - "url": "/organizations/{org}/codespaces/secrets", + "url": "/orgs/{org}/dependabot/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all Codespaces secrets available at the organization-level without revealing their encrypted values.\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-organization-secrets", + "description": "Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-organization-secrets", "parameters": [ { "name": "org", @@ -15466,15 +20442,15 @@ }, { "name": "List repository secrets", - "scope": "codespaces", + "scope": "dependabot", "id": "listRepoSecrets", "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/secrets", + "url": "/repos/{owner}/{repo}/dependabot/secrets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `codespaces_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-repository-secrets", + "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-repository-secrets", "parameters": [ { "name": "owner", @@ -15491,7 +20467,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15533,17 +20509,30 @@ "renamed": null }, { - "name": "List selected repositories for a user secret", - "scope": "codespaces", - "id": "listRepositoriesForSecretForAuthenticatedUser", + "name": "List selected repositories for an organization secret", + "scope": "dependabot", + "id": "listSelectedReposForOrgSecret", "method": "GET", - "url": "/user/codespaces/secrets/{secret_name}/repositories", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the repositories that have been granted the ability to use a user's codespace secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret", + "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-selected-repositories-for-an-organization-secret", "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "secret_name", "description": "The name of the secret.", @@ -15556,32 +20545,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "List secrets for the authenticated user", - "scope": "codespaces", - "id": "listSecretsForAuthenticatedUser", - "method": "GET", - "url": "/user/codespaces/secrets", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all secrets available for a user's Codespaces without revealing their\nencrypted values.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have read access to the `codespaces_user_secrets` user permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-secrets-for-the-authenticated-user", - "parameters": [ + }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -15593,8 +20560,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -15610,16 +20577,16 @@ "renamed": null }, { - "name": "List selected repositories for an organization secret", - "scope": "codespaces", - "id": "listSelectedReposForOrgSecret", - "method": "GET", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}/repositories", + "name": "Remove selected repository from an organization secret", + "scope": "dependabot", + "id": "removeSelectedRepoFromOrgSecret", + "method": "DELETE", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-an-organization-secret", + "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#remove-selected-repository-from-an-organization-secret", "parameters": [ { "name": "org", @@ -15648,24 +20615,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "repository_id", + "description": "", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -15675,26 +20629,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 204, + "description": "Response when repository was removed from the selected list" + }, + { + "code": 409, + "description": "Conflict when visibility type not set to selected" + } ], "renamed": null }, { - "name": "Get default attributes for a codespace", - "scope": "codespaces", - "id": "preFlightWithRepoForAuthenticatedUser", - "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/new", + "name": "Set selected repositories for an organization secret", + "scope": "dependabot", + "id": "setSelectedReposForOrgSecret", + "method": "PUT", + "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the default attributes for codespaces created by the user with the repository.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#preview-attributes-for-a-new-codespace", + "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#set-selected-repositories-for-an-organization-secret", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15706,8 +20666,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "secret_name", + "description": "The name of the secret.", "in": "PATH", "type": "string", "required": true, @@ -15719,24 +20679,11 @@ "deprecated": null }, { - "name": "ref", - "description": "The branch or commit to check for a default devcontainer path. If not specified, the default branch will be checked.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "client_ip", - "description": "An alternative IP for default location auto-detection, such as when proxying a request.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "selected_repository_ids", + "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#set-selected-repositories-for-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#remove-selected-repository-from-an-organization-secret) endpoints.", + "in": "BODY", + "type": "integer[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -15745,32 +20692,24 @@ "deprecated": null } ], - "responses": [ - { - "code": 200, - "description": "Response when a user is able to create codespaces from the repository." - }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Remove a selected repository from a user secret", - "scope": "codespaces", - "id": "removeRepositoryForSecretForAuthenticatedUser", - "method": "DELETE", - "url": "/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", + "name": "Update a Dependabot alert", + "scope": "dependabot", + "id": "updateAlert", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/dependabot/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes a repository from the selected repositories for a user's codespace secret.\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret", + "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** write permission to use this endpoint.\n\nTo use this endpoint, you must have access to security alerts for the repository. For more information, see \"[Granting access to security alerts](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/enabling-features-for-your-repository/managing-security-and-analysis-settings-for-your-repository#granting-access-to-security-alerts).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#update-a-dependabot-alert", "parameters": [ { - "name": "secret_name", - "description": "The name of the secret.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15782,10 +20721,10 @@ "deprecated": null }, { - "name": "repository_id", - "description": "", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -15793,37 +20732,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "No Content when repository was removed from the selected list" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Remove selected repository from an organization secret", - "scope": "codespaces", - "id": "removeSelectedRepoFromOrgSecret", - "method": "DELETE", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret", - "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "alert_number", + "description": "The number that identifies a Dependabot alert in its repository.\nYou can find this at the end of the URL for a Dependabot alert within GitHub,\nor in `number` fields in the response from the\n`GET /repos/{owner}/{repo}/dependabot/alerts` operation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -15833,12 +20747,12 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", + "name": "state", + "description": "The state of the Dependabot alert.\nA `dismissed_reason` must be provided when setting the state to `dismissed`.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["dismissed", "open"], "allowNull": false, "mapToData": null, "validation": null, @@ -15846,11 +20760,30 @@ "deprecated": null }, { - "name": "repository_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "name": "dismissed_reason", + "description": "**Required when `state` is `dismissed`.** A reason for dismissing the alert.", + "in": "BODY", + "type": "string", + "required": false, + "enum": [ + "fix_started", + "inaccurate", + "no_bandwidth", + "not_used", + "tolerable_risk" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "dismissed_comment", + "description": "An optional comment associated with dismissing the alert.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -15860,15 +20793,12 @@ } ], "responses": [ - { - "code": 204, - "description": "Response when repository was removed from the selected list" - }, + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { - "code": 409, - "description": "Conflict when visibility type not set to selected" - }, + { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -15877,16 +20807,16 @@ "renamed": null }, { - "name": "List available machine types for a repository", - "scope": "codespaces", - "id": "repoMachinesForAuthenticatedUser", - "method": "GET", - "url": "/repos/{owner}/{repo}/codespaces/machines", + "name": "Create a snapshot of dependencies for a repository", + "scope": "dependencyGraph", + "id": "createRepositorySnapshot", + "method": "POST", + "url": "/repos/{owner}/{repo}/dependency-graph/snapshots", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the machine types available for a given repository based on its configuration.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_metadata` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-available-machine-types-for-a-repository", + "description": "Create a new snapshot of a repository's dependencies. You must authenticate using an access token with the `repo` scope to use this endpoint for a repository that the requesting user has access to.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependency-graph#create-a-snapshot-of-dependencies-for-a-repository", "parameters": [ { "name": "owner", @@ -15903,7 +20833,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -15915,11 +20845,11 @@ "deprecated": null }, { - "name": "location", - "description": "The location to check for available machines. Assigned by IP if not provided.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "version", + "description": "The version of the repository snapshot submission.", + "in": "BODY", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -15928,45 +20858,22 @@ "deprecated": null }, { - "name": "client_ip", - "description": "IP for location auto-detection when proxying a request", - "in": "QUERY", - "type": "string", - "required": false, + "name": "job", + "description": "", + "in": "BODY", + "type": "object", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Set selected repositories for a user secret", - "scope": "codespaces", - "id": "setRepositoriesForSecretForAuthenticatedUser", - "method": "PUT", - "url": "/user/codespaces/secrets/{secret_name}/repositories", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Select the repositories that will use a user's codespace secret.\n\nYou must authenticate using an access token with the `codespace` or `codespace:secrets` scope to use this endpoint. User must have Codespaces access to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_user_secrets` user permission and write access to the `codespaces_secrets` repository permission on all referenced repositories to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-a-user-secret", - "parameters": [ + }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", + "name": "job.id", + "description": "The external ID of the job.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -15977,10 +20884,10 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "An array of repository ids for which a codespace can access the secret. You can manage the list of selected repositories using the [List selected repositories for a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#list-selected-repositories-for-a-user-secret), [Add a selected repository to a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#add-a-selected-repository-to-a-user-secret), and [Remove a selected repository from a user secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-a-selected-repository-from-a-user-secret) endpoints.", + "name": "job.correlator", + "description": "Correlator provides a key that is used to group snapshots submitted over time. Only the \"latest\" submitted snapshot for a given combination of `job.correlator` and `detector.name` will be considered when calculating a repository's current dependencies. Correlator should be as unique as it takes to distinguish all detection runs for a given \"wave\" of CI workflow you run. If you're using GitHub Actions, a good default value for this could be the environment variables GITHUB_WORKFLOW and GITHUB_JOB concatenated together. If you're using a build matrix, then you'll also need to add additional key(s) to distinguish between each submission inside a matrix variation.", "in": "BODY", - "type": "integer[]", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -15988,50 +20895,51 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ + }, { - "code": 204, - "description": "No Content when repositories were added to the selected list" + "name": "job.html_url", + "description": "The url for the job.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Set selected repositories for an organization secret", - "scope": "codespaces", - "id": "setSelectedReposForOrgSecret", - "method": "PUT", - "url": "/organizations/{org}/codespaces/secrets/{secret_name}/repositories", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret", - "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "sha", + "description": "The commit SHA associated with this dependency snapshot. Maximum length: 40 characters.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ref", + "description": "The repository branch that triggered this snapshot.", + "in": "BODY", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^refs/", "alias": null, "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", + "name": "detector", + "description": "A description of the detector used.", + "in": "BODY", + "type": "object", "required": true, "enum": null, "allowNull": false, @@ -16041,10 +20949,10 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#set-selected-repositories-for-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#remove-selected-repository-from-an-organization-secret) endpoints.", + "name": "detector.name", + "description": "The name of the detector used.", "in": "BODY", - "type": "integer[]", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -16052,34 +20960,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 409, - "description": "Conflict when visibility type not set to selected" - } - ], - "renamed": null - }, - { - "name": "Start a codespace for the authenticated user", - "scope": "codespaces", - "id": "startForAuthenticatedUser", - "method": "POST", - "url": "/user/codespaces/{codespace_name}/start", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Starts a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#start-a-codespace-for-the-authenticated-user", - "parameters": [ + }, { - "name": "codespace_name", - "description": "The name of the codespace.", - "in": "PATH", + "name": "detector.version", + "description": "The version of the detector used.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -16088,38 +20973,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 402, "description": "Payment required" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Stop a codespace for the authenticated user", - "scope": "codespaces", - "id": "stopForAuthenticatedUser", - "method": "POST", - "url": "/user/codespaces/{codespace_name}/stop", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Stops a user's codespace.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces_lifecycle_admin` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#stop-a-codespace-for-the-authenticated-user", - "parameters": [ + }, { - "name": "codespace_name", - "description": "The name of the codespace.", - "in": "PATH", + "name": "detector.url", + "description": "The url of the detector used.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -16128,35 +20986,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Stop a codespace for an organization user", - "scope": "codespaces", - "id": "stopInOrganization", - "method": "POST", - "url": "/orgs/{org}/members/{username}/codespaces/{codespace_name}/stop", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Stops a user's codespace.\n\nYou must authenticate using an access token with the `admin:org` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "metadata", + "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16165,11 +21001,11 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, + "name": "metadata.*", + "description": "", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16178,45 +21014,35 @@ "deprecated": null }, { - "name": "codespace_name", - "description": "The name of the codespace.", - "in": "PATH", - "type": "string", - "required": true, + "name": "manifests", + "description": "A collection of package manifests, which are a collection of related dependencies declared in a file or representing a logical group of dependencies.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Update a codespace for the authenticated user", - "scope": "codespaces", - "id": "updateForAuthenticatedUser", - "method": "PATCH", - "url": "/user/codespaces/{codespace_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Updates a codespace owned by the authenticated user. Currently only the codespace's machine type and recent folders can be modified using this endpoint.\n\nIf you specify a new machine type it will be applied the next time your codespace is started.\n\nYou must authenticate using an access token with the `codespace` scope to use this endpoint.\n\nGitHub Apps must have write access to the `codespaces` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/codespaces#update-a-codespace-for-the-authenticated-user", - "parameters": [ + }, { - "name": "codespace_name", - "description": "The name of the codespace.", - "in": "PATH", + "name": "manifests.*", + "description": "", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "manifests.*.name", + "description": "The name of the manifest.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -16227,10 +21053,10 @@ "deprecated": null }, { - "name": "machine", - "description": "A valid machine to transition this codespace to.", + "name": "manifests.*.file", + "description": "", "in": "BODY", - "type": "string", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -16240,8 +21066,8 @@ "deprecated": null }, { - "name": "display_name", - "description": "Display name for this codespace", + "name": "manifests.*.file.source_location", + "description": "The path of the manifest file relative to the root of the Git repository.", "in": "BODY", "type": "string", "required": false, @@ -16253,10 +21079,10 @@ "deprecated": null }, { - "name": "recent_folders", - "description": "Recently opened folders inside the codespace. It is currently used by the clients to determine the folder path to load the codespace in.", + "name": "manifests.*.metadata", + "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", "in": "BODY", - "type": "string[]", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -16264,34 +21090,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Add selected repository to an organization secret", - "scope": "dependabot", - "id": "addSelectedRepoToOrgSecret", - "method": "PUT", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Adds a repository to an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#add-selected-repository-to-an-organization-secret", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "manifests.*.metadata.*", + "description": "", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16300,11 +21105,11 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, + "name": "manifests.*.resolved", + "description": "A collection of resolved package dependencies.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16313,62 +21118,37 @@ "deprecated": null }, { - "name": "repository_id", + "name": "manifests.*.resolved.*", "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "No Content when repository was added to the selected list" }, { - "code": 409, - "description": "Conflict when visibility type is not set to selected" - } - ], - "renamed": null - }, - { - "name": "Create or update an organization secret", - "scope": "dependabot", - "id": "createOrUpdateOrgSecret", - "method": "PUT", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Creates or updates an organization secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization\npermission to use this endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", - "documentationUrl": "https://docs.github.com/rest/reference/dependabot#create-or-update-an-organization-secret", - "parameters": [ - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "manifests.*.resolved.*.package_url", + "description": "Package-url (PURL) of dependency. See https://github.com/package-url/purl-spec for more details.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^pkg", "alias": null, "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, + "name": "manifests.*.resolved.*.metadata", + "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16377,25 +21157,25 @@ "deprecated": null }, { - "name": "encrypted_value", - "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get an organization public key](https://docs.github.com/rest/reference/dependabot#get-an-organization-public-key) endpoint.", + "name": "manifests.*.resolved.*.metadata.*", + "description": "", "in": "BODY", - "type": "string", + "type": "object", "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "validation": null, "alias": null, "deprecated": null }, { - "name": "key_id", - "description": "ID of the key you used to encrypt the secret.", + "name": "manifests.*.resolved.*.relationship", + "description": "A notation of whether a dependency is requested directly by this manifest or is a dependency of another dependency.", "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["direct", "indirect"], "allowNull": false, "mapToData": null, "validation": null, @@ -16403,12 +21183,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "Which type of organization repositories have access to the organization secret. `selected` means only the repositories specified by `selected_repository_ids` can access the secret.", + "name": "manifests.*.resolved.*.scope", + "description": "A notation of whether the dependency is required for the primary build artifact (runtime) or is only used for development. Future versions of this specification may allow for more granular scopes.", "in": "BODY", "type": "string", - "required": true, - "enum": ["all", "private", "selected"], + "required": false, + "enum": ["runtime", "development"], "allowNull": false, "mapToData": null, "validation": null, @@ -16416,10 +21196,10 @@ "deprecated": null }, { - "name": "selected_repository_ids", - "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can manage the list of selected repositories using the [List selected repositories for an organization secret](https://docs.github.com/rest/reference/dependabot#list-selected-repositories-for-an-organization-secret), [Set selected repositories for an organization secret](https://docs.github.com/rest/reference/dependabot#set-selected-repositories-for-an-organization-secret), and [Remove selected repository from an organization secret](https://docs.github.com/rest/reference/dependabot#remove-selected-repository-from-an-organization-secret) endpoints.", + "name": "manifests.*.resolved.*.dependencies", + "description": "Array of package-url (PURLs) of direct child dependencies.", "in": "BODY", - "type": "undefined[]", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -16427,25 +21207,35 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "scanned", + "description": "The time at which the snapshot was scanned.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response when creating a secret" }, - { "code": 204, "description": "Response when updating a secret" } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "Create or update a repository secret", - "scope": "dependabot", - "id": "createOrUpdateRepoSecret", - "method": "PUT", - "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", + "name": "Get a diff of the dependencies between commits", + "scope": "dependencyGraph", + "id": "diffRange", + "method": "GET", + "url": "/repos/{owner}/{repo}/dependency-graph/compare/{basehead}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates or updates a repository secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). You must authenticate using an access\ntoken with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository\npermission to use this endpoint.\n\n#### Example encrypting a secret using Node.js\n\nEncrypt your secret using the [tweetsodium](https://github.com/github/tweetsodium) library.\n\n```\nconst sodium = require('tweetsodium');\n\nconst key = \"base64-encoded-public-key\";\nconst value = \"plain-text-secret\";\n\n// Convert the message and key to Uint8Array's (Buffer implements that interface)\nconst messageBytes = Buffer.from(value);\nconst keyBytes = Buffer.from(key, 'base64');\n\n// Encrypt using LibSodium.\nconst encryptedBytes = sodium.seal(messageBytes, keyBytes);\n\n// Base64 the encrypted secret\nconst encrypted = Buffer.from(encryptedBytes).toString('base64');\n\nconsole.log(encrypted);\n```\n\n\n#### Example encrypting a secret using Python\n\nEncrypt your secret using [pynacl](https://pynacl.readthedocs.io/en/latest/public/#nacl-public-sealedbox) with Python 3.\n\n```\nfrom base64 import b64encode\nfrom nacl import encoding, public\n\ndef encrypt(public_key: str, secret_value: str) -> str:\n \"\"\"Encrypt a Unicode string using the public key.\"\"\"\n public_key = public.PublicKey(public_key.encode(\"utf-8\"), encoding.Base64Encoder())\n sealed_box = public.SealedBox(public_key)\n encrypted = sealed_box.encrypt(secret_value.encode(\"utf-8\"))\n return b64encode(encrypted).decode(\"utf-8\")\n```\n\n#### Example encrypting a secret using C#\n\nEncrypt your secret using the [Sodium.Core](https://www.nuget.org/packages/Sodium.Core/) package.\n\n```\nvar secretValue = System.Text.Encoding.UTF8.GetBytes(\"mySecret\");\nvar publicKey = Convert.FromBase64String(\"2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvvcCU=\");\n\nvar sealedPublicKeyBox = Sodium.SealedPublicKeyBox.Create(secretValue, publicKey);\n\nConsole.WriteLine(Convert.ToBase64String(sealedPublicKeyBox));\n```\n\n#### Example encrypting a secret using Ruby\n\nEncrypt your secret using the [rbnacl](https://github.com/RubyCrypto/rbnacl) gem.\n\n```ruby\nrequire \"rbnacl\"\nrequire \"base64\"\n\nkey = Base64.decode64(\"+ZYvJDZMHUfBkJdyq5Zm9SKqeuBQ4sj+6sfjlH4CgG0=\")\npublic_key = RbNaCl::PublicKey.new(key)\n\nbox = RbNaCl::Boxes::Sealed.from_public_key(public_key)\nencrypted_secret = box.encrypt(\"my_secret\")\n\n# Print the base64 encoded secret\nputs Base64.strict_encode64(encrypted_secret)\n```", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-a-repository-secret", + "description": "Gets the diff of the dependency changes between two commits of a repository, based on the changes to the dependency manifests made in those commits.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependency-graph#get-a-diff-of-the-dependencies-between-commits", "parameters": [ { "name": "owner", @@ -16462,7 +21252,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -16474,8 +21264,8 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "basehead", + "description": "The base and head Git revisions to compare. The Git revisions will be resolved to commit SHAs. Named revisions will be resolved to their corresponding HEAD commits, and an appropriate merge base will be determined. This parameter expects the format `{base}...{head}`.", "in": "PATH", "type": "string", "required": true, @@ -16487,24 +21277,57 @@ "deprecated": null }, { - "name": "encrypted_value", - "description": "Value for your secret, encrypted with [LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages) using the public key retrieved from the [Get a repository public key](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-public-key) endpoint.", - "in": "BODY", + "name": "name", + "description": "The full path, relative to the repository root, of the dependency manifest file.", + "in": "QUERY", "type": "string", "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{4})$", + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Export a software bill of materials (SBOM) for a repository.", + "scope": "dependencyGraph", + "id": "exportSbom", + "method": "GET", + "url": "/repos/{owner}/{repo}/dependency-graph/sbom", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Exports the software bill of materials (SBOM) for a repository in SPDX JSON format.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/dependency-graph/sboms#export-a-software-bill-of-materials-sbom-for-a-repository", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, "alias": null, "deprecated": null }, { - "name": "key_id", - "description": "ID of the key you used to encrypt the secret.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -16514,26 +21337,45 @@ } ], "responses": [ - { "code": 201, "description": "Response when creating a secret" }, - { "code": 204, "description": "Response when updating a secret" } + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete an organization secret", - "scope": "dependabot", - "id": "deleteOrgSecret", - "method": "DELETE", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}", + "name": "Get emojis", + "scope": "emojis", + "id": "get", + "method": "GET", + "url": "/emojis", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a secret in an organization using the secret name. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#delete-an-organization-secret", + "description": "Lists all the emojis available to use on GitHub Enterprise Cloud.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/emojis#get-emojis", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Check if a gist is starred", + "scope": "gists", + "id": "checkIsStarred", + "method": "GET", + "url": "/gists/{gist_id}/star", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#check-if-a-gist-is-starred", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16543,13 +21385,86 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response if gist is starred" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Not Found if gist is not starred" } + ], + "renamed": null + }, + { + "name": "Create a gist", + "scope": "gists", + "id": "create", + "method": "POST", + "url": "/gists", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Allows you to add a new gist with one or more files.\n\n**Note:** Don't name your files \"gistfile\" with a numerical suffix. This is the format of the automatic naming scheme that Gist uses internally.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#create-a-gist", + "parameters": [ + { + "name": "description", + "description": "Description of the gist", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "files", + "description": "Names and content for the files that make up the gist", + "in": "BODY", + "type": "object", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "files.*", + "description": "", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "files.*.content", + "description": "Content of the file", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, + "name": "public", + "description": "", + "in": "BODY", + "type": null, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16558,24 +21473,33 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Delete a repository secret", - "scope": "dependabot", - "id": "deleteRepoSecret", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", + "name": "Create a gist comment", + "scope": "gists", + "id": "createComment", + "method": "POST", + "url": "/gists/{gist_id}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a secret in a repository using the secret name. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#delete-a-repository-secret", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#create-a-gist-comment", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16587,9 +21511,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "body", + "description": "The comment text.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -16598,10 +21522,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete a gist", + "scope": "gists", + "id": "delete", + "method": "DELETE", + "url": "/gists/{gist_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#delete-a-gist", + "parameters": [ { - "name": "secret_name", - "description": "The name of the secret.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16613,24 +21558,29 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a Dependabot alert", - "scope": "dependabot", - "id": "getAlert", - "method": "GET", - "url": "/repos/{owner}/{repo}/dependabot/alerts/{alert_number}", + "name": "Delete a gist comment", + "scope": "gists", + "id": "deleteComment", + "method": "DELETE", + "url": "/gists/{gist_id}/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-dependabot-alert", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#delete-a-gist-comment", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16642,10 +21592,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -16653,12 +21603,33 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Fork a gist", + "scope": "gists", + "id": "fork", + "method": "POST", + "url": "/gists/{gist_id}/forks", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#fork-a-gist", + "parameters": [ { - "name": "alert_number", - "description": "The number that identifies a Dependabot alert in its repository. You can find this at the end of the URL for a Dependabot alert within GitHub, or in `number` fields in the response from the `GET /repos/{owner}/{repo}/dependabot/alerts` operation.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -16669,28 +21640,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, { "code": 304, "description": "Not modified" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get an organization public key", - "scope": "dependabot", - "id": "getOrgPublicKey", + "name": "Get a gist", + "scope": "gists", + "id": "get", "method": "GET", - "url": "/orgs/{org}/dependabot/secrets/public-key", + "url": "/gists/{gist_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-an-organization-public-key", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16702,24 +21677,29 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden Gist" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get an organization secret", - "scope": "dependabot", - "id": "getOrgSecret", + "name": "Get a gist comment", + "scope": "gists", + "id": "getComment", "method": "GET", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}", + "url": "/gists/{gist_id}/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single organization secret without revealing its encrypted value. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-an-organization-secret", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist-comment", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16731,10 +21711,10 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -16744,24 +21724,29 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden Gist" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a repository public key", - "scope": "dependabot", - "id": "getRepoPublicKey", + "name": "Get a gist revision", + "scope": "gists", + "id": "getRevision", "method": "GET", - "url": "/repos/{owner}/{repo}/dependabot/secrets/public-key", + "url": "/gists/{gist_id}/{sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets your public key, which you need to encrypt secrets. You need to encrypt a secret before you can create or update secrets. Anyone with read access to the repository can use this endpoint. If the repository is private you must use an access token with the `repo` scope. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-public-key", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist-revision", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16773,8 +21758,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "sha", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -16786,27 +21771,35 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get a repository secret", - "scope": "dependabot", - "id": "getRepoSecret", + "name": "List gists for the authenticated user", + "scope": "gists", + "id": "list", "method": "GET", - "url": "/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", + "url": "/gists", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single repository secret without revealing its encrypted value. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#get-a-repository-secret", + "description": "Lists the authenticated user's gists or if called anonymously, this endpoint returns all public gists:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gists-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16815,11 +21808,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16828,11 +21821,11 @@ "deprecated": null }, { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -16841,37 +21834,28 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" } + ], "renamed": null }, { - "name": "List Dependabot alerts for a repository", - "scope": "dependabot", - "id": "listAlertsForRepo", + "name": "List gist comments", + "scope": "gists", + "id": "listComments", "method": "GET", - "url": "/repos/{owner}/{repo}/dependabot/alerts", + "url": "/gists/{gist_id}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-dependabot-alerts-for-a-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-comments", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -16883,10 +21867,10 @@ "deprecated": null }, { - "name": "state", - "description": "A comma-separated list of states. If specified, only alerts with these states will be returned.\n\nCan be: `dismissed`, `fixed`, `open`", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -16896,10 +21880,10 @@ "deprecated": null }, { - "name": "severity", - "description": "A comma-separated list of severities. If specified, only alerts with these severities will be returned.\n\nCan be: `low`, `medium`, `high`, `critical`", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -16907,13 +21891,34 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List gist commits", + "scope": "gists", + "id": "listCommits", + "method": "GET", + "url": "/gists/{gist_id}/commits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-commits", + "parameters": [ { - "name": "ecosystem", - "description": "A comma-separated list of ecosystems. If specified, only alerts for these ecosystems will be returned.\n\nCan be: `composer`, `go`, `maven`, `npm`, `nuget`, `pip`, `rubygems`, `rust`", - "in": "QUERY", + "name": "gist_id", + "description": "The unique identifier of the gist.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -16922,10 +21927,10 @@ "deprecated": null }, { - "name": "package", - "description": "A comma-separated list of package names. If specified, only alerts for these packages will be returned.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -16935,10 +21940,10 @@ "deprecated": null }, { - "name": "manifest", - "description": "A comma-separated list of full manifest paths. If specified, only alerts for these manifests will be returned.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -16946,27 +21951,35 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "scope", - "description": "Scope of the dependency on a Dependabot alert.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["development", "runtime"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List gists for a user", + "scope": "gists", + "id": "listForUser", + "method": "GET", + "url": "/users/{username}/gists", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists public gists for the specified user:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gists-for-a-user", + "parameters": [ { - "name": "sort", - "description": "The property by which to sort the results.\n`created` means when the alert was created.\n`updated` means when the alert's state last changed.", - "in": "QUERY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -16974,12 +21987,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "QUERY", "type": "string", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -16987,8 +22000,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -17000,8 +22013,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -17015,9 +22028,6 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -17026,20 +22036,20 @@ "renamed": null }, { - "name": "List organization secrets", - "scope": "dependabot", - "id": "listOrgSecrets", + "name": "List gist forks", + "scope": "gists", + "id": "listForks", "method": "GET", - "url": "/orgs/{org}/dependabot/secrets", + "url": "/gists/{gist_id}/forks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in an organization without revealing their encrypted values. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-organization-secrets", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-forks", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -17077,40 +22087,32 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List repository secrets", - "scope": "dependabot", - "id": "listRepoSecrets", + "name": "List public gists", + "scope": "gists", + "id": "listPublic", "method": "GET", - "url": "/repos/{owner}/{repo}/dependabot/secrets", + "url": "/gists/public", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all secrets available in a repository without revealing their encrypted values. You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` repository permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-repository-secrets", + "description": "List public gists sorted by most recently updated to least recently updated.\n\nNote: With [pagination](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination), you can fetch up to 3000 gists. For example, you can fetch 100 pages with 30 gists per page or 30 pages with 100 gists per page.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-public-gists", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -17145,40 +22147,35 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List selected repositories for an organization secret", - "scope": "dependabot", - "id": "listSelectedReposForOrgSecret", + "name": "List starred gists", + "scope": "gists", + "id": "listStarred", "method": "GET", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories", + "url": "/gists/starred", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all repositories that have been selected when the `visibility` for repository access to a secret is set to `selected`. You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#list-selected-repositories-for-an-organization-secret", + "description": "List the authenticated user's starred gists:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-starred-gists", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_name", - "description": "The name of the secret.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -17187,8 +22184,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -17200,8 +22197,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -17213,37 +22210,29 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], "renamed": null }, { - "name": "Remove selected repository from an organization secret", - "scope": "dependabot", - "id": "removeSelectedRepoFromOrgSecret", - "method": "DELETE", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories/{repository_id}", + "name": "Star a gist", + "scope": "gists", + "id": "star", + "method": "PUT", + "url": "/gists/{gist_id}/star", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes a repository from an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#remove-selected-repository-from-an-organization-secret", + "description": "Note that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#star-a-gist", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_name", - "description": "The name of the secret.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -17253,61 +22242,31 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "repository_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ - { - "code": 204, - "description": "Response when repository was removed from the selected list" - }, - { - "code": 409, - "description": "Conflict when visibility type not set to selected" - } + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Set selected repositories for an organization secret", - "scope": "dependabot", - "id": "setSelectedReposForOrgSecret", - "method": "PUT", - "url": "/orgs/{org}/dependabot/secrets/{secret_name}/repositories", + "name": "Unstar a gist", + "scope": "gists", + "id": "unstar", + "method": "DELETE", + "url": "/gists/{gist_id}/star", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Replaces all repositories for an organization secret when the `visibility` for repository access is set to `selected`. The visibility is set when you [Create or update an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#create-or-update-an-organization-secret). You must authenticate using an access token with the `admin:org` scope to use this endpoint. GitHub Apps must have the `dependabot_secrets` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#set-selected-repositories-for-an-organization-secret", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#unstar-a-gist", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_name", - "description": "The name of the secret.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -17317,39 +22276,31 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "selected_repository_ids", - "description": "An array of repository ids that can access the organization secret. You can only provide a list of repository ids when the `visibility` is set to `selected`. You can add and remove individual repositories using the [Set selected repositories for an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#set-selected-repositories-for-an-organization-secret) and [Remove selected repository from an organization secret](https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#remove-selected-repository-from-an-organization-secret) endpoints.", - "in": "BODY", - "type": "integer[]", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Update a Dependabot alert", - "scope": "dependabot", - "id": "updateAlert", + "name": "Update a gist", + "scope": "gists", + "id": "update", "method": "PATCH", - "url": "/repos/{owner}/{repo}/dependabot/alerts/{alert_number}", + "url": "/gists/{gist_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must use an access token with the `security_events` scope to use this endpoint with private repositories.\nYou can also use tokens with the `public_repo` scope for public repositories only.\nGitHub Apps must have **Dependabot alerts** write permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependabot#update-a-dependabot-alert", + "description": "Allows you to update a gist's description and to update, delete, or rename gist files. Files from the previous version of the gist that aren't explicitly changed during an edit are unchanged.", + "documentationUrl": "https://docs.github.com/rest/reference/gists/#update-a-gist", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -17361,11 +22312,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "description", + "description": "The description of the gist.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -17374,11 +22325,11 @@ "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies a Dependabot alert in its repository. You can find this at the end of the URL for a Dependabot alert within GitHub, or in `number` fields in the response from the `GET /repos/{owner}/{repo}/dependabot/alerts` operation.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "files", + "description": "The gist files to be updated, renamed, or deleted. Each `key` must match the current filename\n(including extension) of the targeted gist file. For example: `hello.py`.\n\nTo delete a file, set the whole file to null. For example: `hello.py : null`.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -17387,12 +22338,12 @@ "deprecated": null }, { - "name": "state", - "description": "Sets the status of the dependabot alert. You must provide `dismissed_reason` when you set the state to `dismissed`.", + "name": "files.*", + "description": "", "in": "BODY", - "type": "string", - "required": true, - "enum": ["dismissed", "open"], + "type": "object", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -17400,27 +22351,21 @@ "deprecated": null }, { - "name": "dismissed_reason", - "description": "**Required when the `state` is `dismissed`.** The reason for dismissing the Dependabot alert.", + "name": "files.*.content", + "description": "The new content of the file.", "in": "BODY", "type": "string", "required": false, - "enum": [ - "fix_started", - "inaccurate", - "no_bandwidth", - "not_used", - "tolerable_risk" - ], - "allowNull": true, + "enum": null, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "dismissed_comment", - "description": "An optional comment associated with the alert's dismissal. The maximum size is 280 characters.", + "name": "files.*.filename", + "description": "The new filename for the file.", "in": "BODY", "type": "string", "required": false, @@ -17434,12 +22379,7 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -17448,20 +22388,20 @@ "renamed": null }, { - "name": "Create a snapshot of dependencies for a repository", - "scope": "dependencyGraph", - "id": "createRepositorySnapshot", - "method": "POST", - "url": "/repos/{owner}/{repo}/dependency-graph/snapshots", + "name": "Update a gist comment", + "scope": "gists", + "id": "updateComment", + "method": "PATCH", + "url": "/gists/{gist_id}/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a new snapshot of a repository's dependencies. You must authenticate using an access token with the `repo` scope to use this endpoint for a repository that the requesting user has access to.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependency-graph#create-a-snapshot-of-dependencies-for-a-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#update-a-gist-comment", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "gist_id", + "description": "The unique identifier of the gist.", "in": "PATH", "type": "string", "required": true, @@ -17473,10 +22413,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -17486,10 +22426,10 @@ "deprecated": null }, { - "name": "version", - "description": "The version of the repository snapshot submission.", + "name": "body", + "description": "The comment text.", "in": "BODY", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -17497,12 +22437,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Create a blob", + "scope": "git", + "id": "createBlob", + "method": "POST", + "url": "/repos/{owner}/{repo}/git/blobs", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-blob", + "parameters": [ { - "name": "job", - "description": "", - "in": "BODY", - "type": "object", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -17512,9 +22471,9 @@ "deprecated": null }, { - "name": "job.id", - "description": "The external ID of the job.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -17525,8 +22484,8 @@ "deprecated": null }, { - "name": "job.correlator", - "description": "Correlator provides a key that is used to group snapshots submitted over time. Only the \"latest\" submitted snapshot for a given combination of `job.correlator` and `detector.name` will be considered when calculating a repository's current dependencies. Correlator should be as unique as it takes to distinguish all detection runs for a given \"wave\" of CI workflow you run. If you're using GitHub Actions, a good default value for this could be the environment variables GITHUB_WORKFLOW and GITHUB_JOB concatenated together. If you're using a build matrix, then you'll also need to add additional key(s) to distinguish between each submission inside a matrix variation.", + "name": "content", + "description": "The new blob's content.", "in": "BODY", "type": "string", "required": true, @@ -17538,8 +22497,8 @@ "deprecated": null }, { - "name": "job.html_url", - "description": "The url for the job.", + "name": "encoding", + "description": "The encoding used for `content`. Currently, `\"utf-8\"` and `\"base64\"` are supported.", "in": "BODY", "type": "string", "required": false, @@ -17549,50 +22508,49 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, { - "name": "sha", - "description": "The commit SHA associated with this dependency snapshot.", - "in": "BODY", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a commit", + "scope": "git", + "id": "createCommit", + "method": "POST", + "url": "/repos/{owner}/{repo}/git/commits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a new Git [commit object](https://git-scm.com/book/en/v1/Git-Internals-Git-Objects#Commit-Objects).\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in the table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-commit", + "parameters": [ { - "name": "ref", - "description": "The repository branch that triggered this snapshot.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^refs/", - "alias": null, - "deprecated": null - }, - { - "name": "detector", - "description": "A description of the detector used.", - "in": "BODY", - "type": "object", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "detector.name", - "description": "The name of the detector used.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -17603,8 +22561,8 @@ "deprecated": null }, { - "name": "detector.version", - "description": "The version of the detector used.", + "name": "message", + "description": "The commit message", "in": "BODY", "type": "string", "required": true, @@ -17616,8 +22574,8 @@ "deprecated": null }, { - "name": "detector.url", - "description": "The url of the detector used.", + "name": "tree", + "description": "The SHA of the tree object this commit points to", "in": "BODY", "type": "string", "required": true, @@ -17629,10 +22587,10 @@ "deprecated": null }, { - "name": "metadata", - "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", + "name": "parents", + "description": "The SHAs of the commits that were the parents of this commit. If omitted or empty, the commit will be written as a root commit. For a single parent, an array of one SHA should be provided; for a merge commit, an array of more than one should be provided.", "in": "BODY", - "type": "object", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -17642,8 +22600,8 @@ "deprecated": null }, { - "name": "metadata.*", - "description": "", + "name": "author", + "description": "Information about the author of the commit. By default, the `author` will be the authenticated user and the current date. See the `author` and `committer` object below for details.", "in": "BODY", "type": "object", "required": false, @@ -17655,11 +22613,11 @@ "deprecated": null }, { - "name": "manifests", - "description": "A collection of package manifests, which are a collection of related dependencies declared in a file or representing a logical group of dependencies.", + "name": "author.name", + "description": "The name of the author (or committer) of the commit", "in": "BODY", - "type": "object", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -17668,11 +22626,11 @@ "deprecated": null }, { - "name": "manifests.*", - "description": "", + "name": "author.email", + "description": "The email of the author (or committer) of the commit", "in": "BODY", - "type": "object", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -17681,11 +22639,11 @@ "deprecated": null }, { - "name": "manifests.*.name", - "description": "The name of the manifest.", + "name": "author.date", + "description": "Indicates when this commit was authored (or committed). This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -17694,8 +22652,8 @@ "deprecated": null }, { - "name": "manifests.*.file", - "description": "", + "name": "committer", + "description": "Information about the person who is making the commit. By default, `committer` will use the information set in `author`. See the `author` and `committer` object below for details.", "in": "BODY", "type": "object", "required": false, @@ -17707,8 +22665,8 @@ "deprecated": null }, { - "name": "manifests.*.file.source_location", - "description": "The path of the manifest file relative to the root of the Git repository.", + "name": "committer.name", + "description": "The name of the author (or committer) of the commit", "in": "BODY", "type": "string", "required": false, @@ -17720,10 +22678,10 @@ "deprecated": null }, { - "name": "manifests.*.metadata", - "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", + "name": "committer.email", + "description": "The email of the author (or committer) of the commit", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -17733,10 +22691,10 @@ "deprecated": null }, { - "name": "manifests.*.metadata.*", - "description": "", + "name": "committer.date", + "description": "Indicates when this commit was authored (or committed). This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -17746,10 +22704,10 @@ "deprecated": null }, { - "name": "manifests.*.resolved", - "description": "A collection of resolved package dependencies.", + "name": "signature", + "description": "The [PGP signature](https://en.wikipedia.org/wiki/Pretty_Good_Privacy) of the commit. GitHub adds the signature to the `gpgsig` header of the created commit. For a commit signature to be verifiable by Git or GitHub, it must be an ASCII-armored detached PGP signature over the string commit as it would be written to the object database. To pass a `signature` parameter, you need to first manually create a valid PGP signature, which can be complicated. You may find it easier to [use the command line](https://git-scm.com/book/id/v2/Git-Tools-Signing-Your-Work) to create signed commits.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -17757,39 +22715,49 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { - "name": "manifests.*.resolved.*", - "description": "", - "in": "BODY", - "type": "object", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a reference", + "scope": "git", + "id": "createRef", + "method": "POST", + "url": "/repos/{owner}/{repo}/git/refs", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a reference for your repository. You are unable to create new references for empty repositories, even if the commit SHA-1 hash used exists. Empty repositories are repositories without branches.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference", + "parameters": [ { - "name": "manifests.*.resolved.*.package_url", - "description": "Package-url (PURL) of dependency. See https://github.com/package-url/purl-spec for more details.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^pkg", + "validation": null, "alias": null, "deprecated": null }, { - "name": "manifests.*.resolved.*.metadata", - "description": "User-defined metadata to store domain-specific information limited to 8 keys with scalar values.", - "in": "BODY", - "type": "object", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -17798,11 +22766,11 @@ "deprecated": null }, { - "name": "manifests.*.resolved.*.metadata.*", - "description": "", + "name": "ref", + "description": "The name of the fully qualified reference (ie: `refs/heads/master`). If it doesn't start with 'refs' and have at least two slashes, it will be rejected.", "in": "BODY", - "type": "object", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -17811,25 +22779,47 @@ "deprecated": null }, { - "name": "manifests.*.resolved.*.relationship", - "description": "A notation of whether a dependency is requested directly by this manifest or is a dependency of another dependency.", + "name": "sha", + "description": "The SHA1 value for this reference.", "in": "BODY", "type": "string", - "required": false, - "enum": ["direct", "indirect"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, { - "name": "manifests.*.resolved.*.scope", - "description": "A notation of whether the dependency is required for the primary build artifact (runtime) or is only used for development. Future versions of this specification may allow for more granular scopes.", - "in": "BODY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a tag object", + "scope": "git", + "id": "createTag", + "method": "POST", + "url": "/repos/{owner}/{repo}/git/tags", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Note that creating a tag object does not create the reference that makes a tag in Git. If you want to create an annotated tag in Git, you have to do this call to create the tag object, and then [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference) the `refs/tags/[tag]` reference. If you want to create a lightweight tag, you only have to [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference) the tag reference - this call would be unnecessary.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-tag-object", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["runtime", "development"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -17837,11 +22827,11 @@ "deprecated": null }, { - "name": "manifests.*.resolved.*.dependencies", - "description": "Array of package-url (PURLs) of direct child dependencies.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -17850,8 +22840,8 @@ "deprecated": null }, { - "name": "scanned", - "description": "The time at which the snapshot was scanned.", + "name": "tag", + "description": "The tag's name. This is typically a version (e.g., \"v0.0.1\").", "in": "BODY", "type": "string", "required": true, @@ -17860,28 +22850,12 @@ "mapToData": null, "validation": null, "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a diff of the dependencies between commits", - "scope": "dependencyGraph", - "id": "diffRange", - "method": "GET", - "url": "/repos/{owner}/{repo}/dependency-graph/compare/{basehead}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the diff of the dependency changes between two commits of a repository, based on the changes to the dependency manifests made in those commits.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/dependency-graph#get-a-diff-of-the-dependencies-between-commits", - "parameters": [ + "deprecated": null + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "message", + "description": "The tag message.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -17892,9 +22866,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "object", + "description": "The SHA of the git object this is tagging.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -17905,12 +22879,12 @@ "deprecated": null }, { - "name": "basehead", - "description": "The base and head Git revisions to compare. The Git revisions will be resolved to commit SHAs. Named revisions will be resolved to their corresponding HEAD commits, and an appropriate merge base will be determined. This parameter expects the format `{base}...{head}`.", - "in": "PATH", + "name": "type", + "description": "The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["commit", "tree", "blob"], "allowNull": false, "mapToData": null, "validation": null, @@ -17918,10 +22892,10 @@ "deprecated": null }, { - "name": "name", - "description": "The full path, relative to the repository root, of the dependency manifest file.", - "in": "QUERY", - "type": "string", + "name": "tagger", + "description": "An object with information about the individual creating the tag.", + "in": "BODY", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -17929,49 +22903,11 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get emojis", - "scope": "emojis", - "id": "get", - "method": "GET", - "url": "/emojis", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all the emojis available to use on GitHub Enterprise Cloud.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/emojis#get-emojis", - "parameters": [], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "Add custom labels to a self-hosted runner for an enterprise", - "scope": "enterpriseAdmin", - "id": "addCustomLabelsToSelfHostedRunnerForEnterprise", - "method": "POST", - "url": "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Add custom labels to a self-hosted runner configured in an enterprise.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#add-custom-labels-to-a-self-hosted-runner-for-an-enterprise", - "parameters": [ + }, { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", - "in": "PATH", + "name": "tagger.name", + "description": "The name of the author of the tag", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -17982,10 +22918,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", - "in": "PATH", - "type": "integer", + "name": "tagger.email", + "description": "The email of the author of the tag", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -17995,11 +22931,11 @@ "deprecated": null }, { - "name": "labels", - "description": "The names of the custom labels to add to the runner.", + "name": "tagger.date", + "description": "When this object was tagged. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", - "type": "string[]", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -18009,8 +22945,7 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, + { "code": 201, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -18019,20 +22954,20 @@ "renamed": null }, { - "name": "Disable a selected organization for GitHub Actions in an enterprise", - "scope": "enterpriseAdmin", - "id": "disableSelectedOrganizationGithubActionsEnterprise", - "method": "DELETE", - "url": "/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", + "name": "Create a tree", + "scope": "git", + "id": "createTree", + "method": "POST", + "url": "/repos/{owner}/{repo}/git/trees", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes an organization from the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#disable-a-selected-organization-for-github-actions-in-an-enterprise", + "description": "The tree creation API accepts nested entries. If you specify both a tree and a nested path modifying that tree, this endpoint will overwrite the contents of the tree with the new path contents, and create a new tree structure.\n\nIf you use this endpoint to add, delete, or modify the file contents in a tree, you will need to commit the tree and then update a branch to point to the commit. For more information see \"[Create a commit](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-commit)\" and \"[Update a reference](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#update-a-reference).\"\n\nReturns an error if you try to delete a file that does not exist.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-tree", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18044,10 +22979,10 @@ "deprecated": null }, { - "name": "org_id", - "description": "The unique identifier of the organization.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18055,28 +22990,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Enable a selected organization for GitHub Actions in an enterprise", - "scope": "enterpriseAdmin", - "id": "enableSelectedOrganizationGithubActionsEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Adds an organization to the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#enable-a-selected-organization-for-github-actions-in-an-enterprise", - "parameters": [ + }, { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", - "in": "PATH", - "type": "string", + "name": "tree", + "description": "Objects (of `path`, `mode`, `type`, and `sha`) specifying a tree structure.", + "in": "BODY", + "type": "object[]", "required": true, "enum": null, "allowNull": false, @@ -18086,109 +23005,61 @@ "deprecated": null }, { - "name": "org_id", - "description": "The unique identifier of the organization.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "tree[].path", + "description": "The file referenced in the tree.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Get allowed actions and reusable workflows for an enterprise", - "scope": "enterpriseAdmin", - "id": "getAllowedActionsEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/actions/permissions/selected-actions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the selected actions and reusable workflows that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-allowed-actions-for-an-enterprise", - "parameters": [ + }, { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", - "in": "PATH", + "name": "tree[].mode", + "description": "The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["100644", "100755", "040000", "160000", "120000"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get GitHub Actions permissions for an enterprise", - "scope": "enterpriseAdmin", - "id": "getGithubActionsPermissionsEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/actions/permissions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets the GitHub Actions permissions policy for organizations and allowed actions and reusable workflows in an enterprise.\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#get-github-actions-permissions-for-an-enterprise", - "parameters": [ + }, { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", - "in": "PATH", + "name": "tree[].type", + "description": "Either `blob`, `tree`, or `commit`.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["blob", "tree", "commit"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get GitHub Enterprise Server statistics", - "scope": "enterpriseAdmin", - "id": "getServerStatistics", - "method": "GET", - "url": "/enterprise-installation/{enterprise_or_org}/server-statistics", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns aggregate usage metrics for your GitHub Enterprise Server 3.5+ instance for a specified time period up to 365 days.\n\nTo use this endpoint, your GitHub Enterprise Server instance must be connected to GitHub Enterprise Cloud using GitHub Connect. You must enable Server Statistics, and for the API request provide your enterprise account name or organization name connected to the GitHub Enterprise Server. For more information, see \"[Enabling Server Statistics for your enterprise](/admin/configuration/configuring-github-connect/enabling-server-statistics-for-your-enterprise)\" in the GitHub Enterprise Server documentation.\n\nYou'll need to use a personal access token:\n - If you connected your GitHub Enterprise Server to an enterprise account and enabled Server Statistics, you'll need a personal access token with the `read:enterprise` permission.\n - If you connected your GitHub Enterprise Server to an organization account and enabled Server Statistics, you'll need a personal access token with the `read:org` permission.\n\nFor more information on creating a personal access token, see \"[Creating a personal access token](/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/enterprise-admin#get-github-enterprise-server-statistics", - "parameters": [ + }, { - "name": "enterprise_or_org", - "description": "The slug version of the enterprise name or the login of an organization.", - "in": "PATH", + "name": "tree[].sha", + "description": "The SHA1 checksum ID of the object in the tree. Also called `tree.sha`. If the value is `null` then the file will be deleted. \n \n**Note:** Use either `tree.sha` or `content` to specify the contents of the entry. Using both `tree.sha` and `content` will return an error.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "date_start", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor.", - "in": "QUERY", + "name": "tree[].content", + "description": "The content you want this file to have. GitHub will write this blob out and use that SHA for this entry. Use either this, or `tree.sha`. \n \n**Note:** Use either `tree.sha` or `content` to specify the contents of the entry. Using both `tree.sha` and `content` will return an error.", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -18199,9 +23070,9 @@ "deprecated": null }, { - "name": "date_end", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor.", - "in": "QUERY", + "name": "base_tree", + "description": "The SHA1 of an existing Git tree object which will be used as the base for the new tree. If provided, a new Git tree object will be created from entries in the Git tree object pointed to by `base_tree` and entries defined in the `tree` parameter. Entries defined in the `tree` parameter will overwrite items from `base_tree` with the same `path`. If you're creating new changes on a branch, then normally you'd set `base_tree` to the SHA1 of the Git tree object of the current latest commit on the branch you're working on.\nIf not provided, GitHub will create a new Git tree object from only the entries defined in the `tree` parameter. If you create a new commit pointing to such a tree, then all files which were a part of the parent commit's tree and were not defined in the `tree` parameter will be listed as deleted by the new commit.\n", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -18212,24 +23083,32 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List labels for a self-hosted runner for an enterprise", - "scope": "enterpriseAdmin", - "id": "listLabelsForSelfHostedRunnerForEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", + "name": "Delete a reference", + "scope": "git", + "id": "deleteRef", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/git/refs/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all labels for a self-hosted runner configured in an enterprise.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-labels-for-a-self-hosted-runner-for-an-enterprise", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#delete-a-reference", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18241,10 +23120,23 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ref", + "description": "ref parameter", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18255,26 +23147,29 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 204, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List selected organizations enabled for GitHub Actions in an enterprise", - "scope": "enterpriseAdmin", - "id": "listSelectedOrganizationsEnabledGithubActionsEnterprise", + "name": "Get a blob", + "scope": "git", + "id": "getBlob", "method": "GET", - "url": "/enterprises/{enterprise}/actions/permissions/organizations", + "url": "/repos/{owner}/{repo}/git/blobs/{file_sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the organizations that are selected to have GitHub Actions enabled in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#list-selected-organizations-enabled-for-github-actions-in-an-enterprise", + "description": "The `content` in the response will always be Base64 encoded.\n\n_Note_: This API supports blobs up to 100 megabytes in size.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-blob", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18286,50 +23181,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Remove all custom labels from a self-hosted runner for an enterprise", - "scope": "enterpriseAdmin", - "id": "removeAllCustomLabelsFromSelfHostedRunnerForEnterprise", - "method": "DELETE", - "url": "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Remove all custom labels from a self-hosted runner configured in an\nenterprise. Returns the remaining read-only labels from the runner.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-all-custom-labels-from-a-self-hosted-runner-for-an-enterprise", - "parameters": [ - { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18341,10 +23194,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "file_sha", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18356,6 +23209,7 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, { "code": 422, @@ -18365,20 +23219,20 @@ "renamed": null }, { - "name": "Remove a custom label from a self-hosted runner for an enterprise", - "scope": "enterpriseAdmin", - "id": "removeCustomLabelFromSelfHostedRunnerForEnterprise", - "method": "DELETE", - "url": "/enterprises/{enterprise}/actions/runners/{runner_id}/labels/{name}", + "name": "Get a commit", + "scope": "git", + "id": "getCommit", + "method": "GET", + "url": "/repos/{owner}/{repo}/git/commits/{commit_sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove a custom label from a self-hosted runner configured\nin an enterprise. Returns the remaining labels from the runner.\n\nThis endpoint returns a `404 Not Found` status if the custom label is not\npresent on the runner.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#remove-a-custom-label-from-a-self-hosted-runner-for-an-enterprise", + "description": "Gets a Git [commit object](https://git-scm.com/book/en/v1/Git-Internals-Git-Objects#Commit-Objects).\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in the table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-commit", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18390,10 +23244,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18403,8 +23257,8 @@ "deprecated": null }, { - "name": "name", - "description": "The name of a self-hosted runner's custom label.", + "name": "commit_sha", + "description": "The SHA of the commit.", "in": "PATH", "type": "string", "required": true, @@ -18418,29 +23272,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Set allowed actions and reusable workflows for an enterprise", - "scope": "enterpriseAdmin", - "id": "setAllowedActionsEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/permissions/selected-actions", + "name": "Get a reference", + "scope": "git", + "id": "getRef", + "method": "GET", + "url": "/repos/{owner}/{repo}/git/ref/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the actions and reusable workflows that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for `allowed_actions` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-allowed-actions-for-an-enterprise", + "description": "Returns a single reference from your Git database. The `:ref` in the URL must be formatted as `heads/` for branches and `tags/` for tags. If the `:ref` doesn't match an existing ref, a `404` is returned.\n\n**Note:** You need to explicitly [request a pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) to trigger a test merge commit, which checks the mergeability of pull requests. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-reference", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18452,24 +23302,11 @@ "deprecated": null }, { - "name": "github_owned_allowed", - "description": "Whether GitHub-owned actions are allowed. For example, this includes the actions in the `actions` organization.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "verified_allowed", - "description": "Whether actions from GitHub Marketplace verified creators are allowed. Set to `true` to allow all actions by GitHub Marketplace verified creators.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -18478,11 +23315,11 @@ "deprecated": null }, { - "name": "patterns_allowed", - "description": "Specifies a list of string-matching patterns to allow specific action(s) and reusable workflow(s). Wildcards, tags, and SHAs are allowed. For example, `monalisa/octocat@*`, `monalisa/octocat@v2`, `monalisa/*`.\"", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "ref", + "description": "ref parameter", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -18491,24 +23328,27 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Set custom labels for a self-hosted runner for an enterprise", - "scope": "enterpriseAdmin", - "id": "setCustomLabelsForSelfHostedRunnerForEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", + "name": "Get a tag", + "scope": "git", + "id": "getTag", + "method": "GET", + "url": "/repos/{owner}/{repo}/git/tags/{tag_sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Remove all previous custom labels and set the new custom labels for a specific\nself-hosted runner configured in an enterprise.\n\nYou must authenticate using an access token with the `manage_runners:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-custom-labels-for-a-self-hosted-runner-for-an-enterprise", + "description": "**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tag", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18520,10 +23360,10 @@ "deprecated": null }, { - "name": "runner_id", - "description": "Unique identifier of the self-hosted runner.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18533,10 +23373,10 @@ "deprecated": null }, { - "name": "labels", - "description": "The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.", - "in": "BODY", - "type": "string[]", + "name": "tag_sha", + "description": "", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18548,29 +23388,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Set GitHub Actions permissions for an enterprise", - "scope": "enterpriseAdmin", - "id": "setGithubActionsPermissionsEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/permissions", + "name": "Get a tree", + "scope": "git", + "id": "getTree", + "method": "GET", + "url": "/repos/{owner}/{repo}/git/trees/{tree_sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sets the GitHub Actions permissions policy for organizations and allowed actions and reusable workflows in an enterprise.\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-github-actions-permissions-for-an-enterprise", + "description": "Returns a single tree using the SHA1 value for that tree.\n\nIf `truncated` is `true` in the response then the number of items in the `tree` array exceeded our maximum limit. If you need to fetch more items, use the non-recursive method of fetching trees, and fetch one sub-tree at a time.\n\n\n**Note**: The limit for the `tree` array is 100,000 entries with a maximum size of 7 MB when using the `recursive` parameter.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tree", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18582,12 +23418,12 @@ "deprecated": null }, { - "name": "enabled_organizations", - "description": "The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, - "enum": ["all", "none", "selected"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -18595,12 +23431,25 @@ "deprecated": null }, { - "name": "allowed_actions", - "description": "The permissions policy that controls the actions and reusable workflows that are allowed to run.", - "in": "BODY", + "name": "tree_sha", + "description": "", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "recursive", + "description": "Setting this parameter to any value returns the objects or subtrees referenced by the tree specified in `:tree_sha`. For example, setting `recursive` to any of the following will enable returning objects or subtrees: `0`, `1`, `\"true\"`, and `\"false\"`. Omit this parameter to prevent recursively returning objects or subtrees.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["all", "local_only", "selected"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -18608,24 +23457,31 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Set selected organizations enabled for GitHub Actions in an enterprise", - "scope": "enterpriseAdmin", - "id": "setSelectedOrganizationsEnabledGithubActionsEnterprise", - "method": "PUT", - "url": "/enterprises/{enterprise}/actions/permissions/organizations", + "name": "List matching references", + "scope": "git", + "id": "listMatchingRefs", + "method": "GET", + "url": "/repos/{owner}/{repo}/git/matching-refs/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Replaces the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for `enabled_organizations` must be configured to `selected`. For more information, see \"[Set GitHub Actions permissions for an enterprise](#set-github-actions-permissions-for-an-enterprise).\"\n\nYou must authenticate using an access token with the `admin:enterprise` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/actions#set-selected-organizations-enabled-for-github-actions-in-an-enterprise", + "description": "Returns an array of references from your Git database that match the supplied name. The `:ref` in the URL must be formatted as `heads/` for branches and `tags/` for tags. If the `:ref` doesn't exist in the repository, but existing refs start with `:ref`, they will be returned as an array.\n\nWhen you use this endpoint without providing a `:ref`, it will return an array of all the references from your Git database, including notes and stashes if they exist on the server. Anything in the namespace is returned, not just `heads` and `tags`.\n\n**Note:** You need to explicitly [request a pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) to trigger a test merge commit, which checks the mergeability of pull requests. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".\n\nIf you request matching references for a branch named `feature` but the branch `feature` doesn't exist, the response can still include other matching head refs that start with the word `feature`, such as `featureA` and `featureB`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#list-matching-references", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18637,10 +23493,10 @@ "deprecated": null }, { - "name": "selected_organization_ids", - "description": "List of organization IDs to enable for GitHub Actions.", - "in": "BODY", - "type": "integer[]", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18648,26 +23504,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Check if a gist is starred", - "scope": "gists", - "id": "checkIsStarred", - "method": "GET", - "url": "/gists/{gist_id}/star", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#check-if-a-gist-is-starred", - "parameters": [ + }, { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "ref", + "description": "ref parameter", "in": "PATH", "type": "string", "required": true, @@ -18679,32 +23519,27 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response if gist is starred" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Not Found if gist is not starred" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Create a gist", - "scope": "gists", - "id": "create", - "method": "POST", - "url": "/gists", + "name": "Update a reference", + "scope": "git", + "id": "updateRef", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/git/refs/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Allows you to add a new gist with one or more files.\n\n**Note:** Don't name your files \"gistfile\" with a numerical suffix. This is the format of the automatic naming scheme that Gist uses internally.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#create-a-gist", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#update-a-reference", "parameters": [ { - "name": "description", - "description": "Description of the gist", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -18713,10 +23548,10 @@ "deprecated": null }, { - "name": "files", - "description": "Names and content for the files that make up the gist", - "in": "BODY", - "type": "object", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18726,11 +23561,11 @@ "deprecated": null }, { - "name": "files.*", - "description": "", - "in": "BODY", - "type": "object", - "required": false, + "name": "ref", + "description": "The name of the fully qualified reference to update. For example, `refs/heads/master`. If the value doesn't start with `refs` and have at least two slashes, it will be rejected.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -18739,8 +23574,8 @@ "deprecated": null }, { - "name": "files.*.content", - "description": "Content of the file", + "name": "sha", + "description": "The SHA1 value to set this reference to", "in": "BODY", "type": "string", "required": true, @@ -18752,10 +23587,10 @@ "deprecated": null }, { - "name": "public", - "description": "", + "name": "force", + "description": "Indicates whether to force the update or to make sure the update is a fast-forward update. Leaving this out or setting it to `false` will make sure you're not overwriting work.", "in": "BODY", - "type": null, + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -18766,10 +23601,7 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + { "code": 200, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -18778,20 +23610,38 @@ "renamed": null }, { - "name": "Create a gist comment", - "scope": "gists", - "id": "createComment", - "method": "POST", - "url": "/gists/{gist_id}/comments", + "name": "Get all gitignore templates", + "scope": "gitignore", + "id": "getAllTemplates", + "method": "GET", + "url": "/gitignore/templates", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#create-a-gist-comment", + "description": "List all templates available to pass as an option when [creating a repository](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-for-the-authenticated-user).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gitignore#get-all-gitignore-templates", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Get a gitignore template", + "scope": "gitignore", + "id": "getTemplate", + "method": "GET", + "url": "/gitignore/templates/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "The API also allows fetching the source of a single template.\nUse the raw [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) to get the raw contents.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gitignore#get-a-gitignore-template", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "name", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -18801,44 +23651,47 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "body", - "description": "The comment text.", - "in": "BODY", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } ], "renamed": null }, { - "name": "Delete a gist", - "scope": "gists", - "id": "delete", - "method": "DELETE", - "url": "/gists/{gist_id}", + "name": "Get interaction restrictions for your public repositories", + "scope": "interactions", + "id": "getRestrictionsForAuthenticatedUser", + "method": "GET", + "url": "/user/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#delete-a-gist", + "description": "Shows which type of GitHub user can interact with your public repositories and when the restriction expires.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-your-public-repositories", + "parameters": [], + "responses": [ + { "code": 200, "description": "Default response" }, + { "code": 204, "description": "Response when there are no restrictions" } + ], + "renamed": null + }, + { + "name": "Get interaction restrictions for an organization", + "scope": "interactions", + "id": "getRestrictionsForOrg", + "method": "GET", + "url": "/orgs/{org}/interaction-limits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Shows which type of GitHub user can interact with this organization and when the restriction expires. If there is no restrictions, you will see an empty response.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-an-organization", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18850,29 +23703,24 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Delete a gist comment", - "scope": "gists", - "id": "deleteComment", - "method": "DELETE", - "url": "/gists/{gist_id}/comments/{comment_id}", + "name": "Get interaction restrictions for a repository", + "scope": "interactions", + "id": "getRestrictionsForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#delete-a-gist-comment", + "description": "Shows which type of GitHub user can interact with this repository and when the restriction expires. If there are no restrictions, you will see an empty response.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-a-repository", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18884,10 +23732,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -18897,67 +23745,68 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Fork a gist", - "scope": "gists", - "id": "fork", - "method": "POST", - "url": "/gists/{gist_id}/forks", + "name": "Get interaction restrictions for your public repositories", + "scope": "interactions", + "id": "getRestrictionsForYourPublicRepos", + "method": "GET", + "url": "/user/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#fork-a-gist", - "parameters": [ - { - "name": "gist_id", - "description": "The unique identifier of the gist.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], + "description": "Shows which type of GitHub user can interact with your public repositories and when the restriction expires.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-your-public-repositories", + "parameters": [], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Default response" }, + { "code": 204, "description": "Response when there are no restrictions" } ], + "renamed": { + "before": { + "scope": "interactions", + "id": "getRestrictionsForYourPublicRepos" + }, + "after": { + "scope": "interactions", + "id": "getRestrictionsForAuthenticatedUser" + }, + "date": "2021-02-02", + "note": null + } + }, + { + "name": "Remove interaction restrictions from your public repositories", + "scope": "interactions", + "id": "removeRestrictionsForAuthenticatedUser", + "method": "DELETE", + "url": "/user/interaction-limits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Removes any interaction restrictions from your public repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-from-your-public-repositories", + "parameters": [], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get a gist", - "scope": "gists", - "id": "get", - "method": "GET", - "url": "/gists/{gist_id}", + "name": "Remove interaction restrictions for an organization", + "scope": "interactions", + "id": "removeRestrictionsForOrg", + "method": "DELETE", + "url": "/orgs/{org}/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist", + "description": "Removes all interaction restrictions from public repositories in the given organization. You must be an organization owner to remove restrictions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-for-an-organization", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -18969,29 +23818,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden Gist" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get a gist comment", - "scope": "gists", - "id": "getComment", - "method": "GET", - "url": "/gists/{gist_id}/comments/{comment_id}", + "name": "Remove interaction restrictions for a repository", + "scope": "interactions", + "id": "removeRestrictionsForRepo", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist-comment", + "description": "Removes all interaction restrictions from the given repository. You must have owner or admin access to remove restrictions. If the interaction limit is set for the user or organization that owns this repository, you will receive a `409 Conflict` response and will not be able to use this endpoint to change the interaction limit for a single repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-for-a-repository", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19003,10 +23847,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -19017,32 +23861,56 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden Gist" }, - { "code": 404, "description": "Resource not found" } + { "code": 204, "description": "Response" }, + { "code": 409, "description": "Response" } ], "renamed": null }, { - "name": "Get a gist revision", - "scope": "gists", - "id": "getRevision", - "method": "GET", - "url": "/gists/{gist_id}/{sha}", + "name": "Remove interaction restrictions from your public repositories", + "scope": "interactions", + "id": "removeRestrictionsForYourPublicRepos", + "method": "DELETE", + "url": "/user/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#get-a-gist-revision", + "description": "Removes any interaction restrictions from your public repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-from-your-public-repositories", + "parameters": [], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": { + "before": { + "scope": "interactions", + "id": "removeRestrictionsForYourPublicRepos" + }, + "after": { + "scope": "interactions", + "id": "removeRestrictionsForAuthenticatedUser" + }, + "date": "2021-02-02", + "note": null + } + }, + { + "name": "Set interaction restrictions for your public repositories", + "scope": "interactions", + "id": "setRestrictionsForAuthenticatedUser", + "method": "PUT", + "url": "/user/interaction-limits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Temporarily restricts which type of GitHub user can interact with your public repositories. Setting the interaction limit at the user level will overwrite any interaction limits that are set for individual repositories owned by the user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-your-public-repositories", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", - "in": "PATH", + "name": "limit", + "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["existing_users", "contributors_only", "collaborators_only"], "allowNull": false, "mapToData": null, "validation": null, @@ -19050,12 +23918,18 @@ "deprecated": null }, { - "name": "sha", - "description": "", - "in": "PATH", + "name": "expiry", + "description": "The duration of the interaction restriction. Default: `one_day`.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": [ + "one_day", + "three_days", + "one_week", + "one_month", + "six_months" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -19065,8 +23939,6 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -19075,23 +23947,23 @@ "renamed": null }, { - "name": "List gists for the authenticated user", - "scope": "gists", - "id": "list", - "method": "GET", - "url": "/gists", + "name": "Set interaction restrictions for an organization", + "scope": "interactions", + "id": "setRestrictionsForOrg", + "method": "PUT", + "url": "/orgs/{org}/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the authenticated user's gists or if called anonymously, this endpoint returns all public gists:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gists-for-the-authenticated-user", + "description": "Temporarily restricts interactions to a certain type of GitHub user in any public repository in the given organization. You must be an organization owner to set these restrictions. Setting the interaction limit at the organization level will overwrite any interaction limits that are set for individual repositories owned by the organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-an-organization", "parameters": [ { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19100,12 +23972,12 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, + "name": "limit", + "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["existing_users", "contributors_only", "collaborators_only"], "allowNull": false, "mapToData": null, "validation": null, @@ -19113,12 +23985,18 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "expiry", + "description": "The duration of the interaction restriction. Default: `one_day`.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": [ + "one_day", + "three_days", + "one_week", + "one_month", + "six_months" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -19128,26 +24006,28 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List gist comments", - "scope": "gists", - "id": "listComments", - "method": "GET", - "url": "/gists/{gist_id}/comments", + "name": "Set interaction restrictions for a repository", + "scope": "interactions", + "id": "setRestrictionsForRepo", + "method": "PUT", + "url": "/repos/{owner}/{repo}/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-comments", + "description": "Temporarily restricts interactions to a certain type of GitHub user within the given repository. You must have owner or admin access to set these restrictions. If an interaction limit is set for the user or organization that owns this repository, you will receive a `409 Conflict` response and will not be able to use this endpoint to change the interaction limit for a single repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-a-repository", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19159,11 +24039,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19172,12 +24052,31 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "limit", + "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["existing_users", "contributors_only", "collaborators_only"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "expiry", + "description": "The duration of the interaction restriction. Default: `one_day`.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": [ + "one_day", + "three_days", + "one_week", + "one_month", + "six_months" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -19187,44 +24086,29 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 409, "description": "Response" } ], "renamed": null }, { - "name": "List gist commits", - "scope": "gists", - "id": "listCommits", - "method": "GET", - "url": "/gists/{gist_id}/commits", + "name": "Set interaction restrictions for your public repositories", + "scope": "interactions", + "id": "setRestrictionsForYourPublicRepos", + "method": "PUT", + "url": "/user/interaction-limits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-commits", + "description": "Temporarily restricts which type of GitHub user can interact with your public repositories. Setting the interaction limit at the user level will overwrite any interaction limits that are set for individual repositories owned by the user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-your-public-repositories", "parameters": [ - { - "name": "gist_id", - "description": "The unique identifier of the gist.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, + { + "name": "limit", + "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["existing_users", "contributors_only", "collaborators_only"], "allowNull": false, "mapToData": null, "validation": null, @@ -19232,12 +24116,18 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "expiry", + "description": "The duration of the interaction restriction. Default: `one_day`.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": [ + "one_day", + "three_days", + "one_week", + "one_month", + "six_months" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -19247,27 +24137,39 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], - "renamed": null + "renamed": { + "before": { + "scope": "interactions", + "id": "setRestrictionsForYourPublicRepos" + }, + "after": { + "scope": "interactions", + "id": "setRestrictionsForAuthenticatedUser" + }, + "date": "2021-02-02", + "note": null + } }, { - "name": "List gists for a user", - "scope": "gists", - "id": "listForUser", - "method": "GET", - "url": "/users/{username}/gists", + "name": "Add assignees to an issue", + "scope": "issues", + "id": "addAssignees", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/assignees", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists public gists for the specified user:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gists-for-a-user", + "description": "Adds up to 10 assignees to an issue. Users already assigned to an issue are not replaced.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#add-assignees-to-an-issue", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19279,11 +24181,11 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19292,11 +24194,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "issue_number", + "description": "The number that identifies the issue.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19305,10 +24207,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "assignees", + "description": "Usernames of people to assign this issue to. _NOTE: Only users with push access can add assignees to an issue. Assignees are silently ignored otherwise._", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -19318,30 +24220,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "List gist forks", - "scope": "gists", - "id": "listForks", - "method": "GET", - "url": "/gists/{gist_id}/forks", + "name": "Add labels to an issue", + "scope": "issues", + "id": "addLabels", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-gist-forks", + "description": "Adds labels to an issue. If you provide an empty array of labels, all labels are removed from the issue. ", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#add-labels-to-an-issue", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19353,11 +24249,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19366,10 +24262,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "issue_number", + "description": "The number that identifies the issue.", + "in": "PATH", "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "labels", + "description": "", + "in": "BODY", + "type": "object[]", "required": false, "enum": null, "allowNull": false, @@ -19377,34 +24286,51 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "labels[].name", + "description": "", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 301, "description": "Moved permanently" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List public gists", - "scope": "gists", - "id": "listPublic", + "name": "Check if a user can be assigned", + "scope": "issues", + "id": "checkUserCanBeAssigned", "method": "GET", - "url": "/gists/public", + "url": "/repos/{owner}/{repo}/assignees/{assignee}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List public gists sorted by most recently updated to least recently updated.\n\nNote: With [pagination](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination), you can fetch up to 3000 gists. For example, you can fetch 100 pages with 30 gists per page or 30 pages with 100 gists per page.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-public-gists", + "description": "Checks if a user has permission to be assigned to an issue in this repository.\n\nIf the `assignee` can be assigned to issues in the repository, a `204` header with no content is returned.\n\nOtherwise a `404` status code is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#check-if-a-user-can-be-assigned", "parameters": [ { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19413,11 +24339,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19426,11 +24352,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "assignee", + "description": "", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19440,34 +24366,35 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 204, + "description": "If the `assignee` can be assigned to issues in the repository, a `204` header with no content is returned." + }, + { + "code": 404, + "description": "Otherwise a `404` status code is returned." } ], "renamed": null }, { - "name": "List starred gists", - "scope": "gists", - "id": "listStarred", + "name": "Check if a user can be assigned to a issue", + "scope": "issues", + "id": "checkUserCanBeAssignedToIssue", "method": "GET", - "url": "/gists/starred", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/assignees/{assignee}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the authenticated user's starred gists:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#list-starred-gists", + "description": "Checks if a user has permission to be assigned to a specific issue.\n\nIf the `assignee` can be assigned to this issue, a `204` status code with no content is returned.\n\nOtherwise a `404` status code is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#check-if-a-user-can-be-assigned-to-a-issue", "parameters": [ { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19476,11 +24403,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19489,42 +24416,21 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "issue_number", + "description": "The number that identifies the issue.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Star a gist", - "scope": "gists", - "id": "star", - "method": "PUT", - "url": "/gists/{gist_id}/star", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Note that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#star-a-gist", - "parameters": [ + }, { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "assignee", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -19537,28 +24443,32 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 204, + "description": "Response if `assignee` can be assigned to `issue_number`" + }, + { + "code": 404, + "description": "Response if `assignee` can not be assigned to `issue_number`" + } ], "renamed": null }, { - "name": "Unstar a gist", - "scope": "gists", - "id": "unstar", - "method": "DELETE", - "url": "/gists/{gist_id}/star", + "name": "Create an issue", + "scope": "issues", + "id": "create", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#unstar-a-gist", + "description": "Any user with pull access to a repository can create an issue. If [issues are disabled in the repository](https://docs.github.com/enterprise-cloud@latest//articles/disabling-issues/), the API returns a `410 Gone` status.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19568,31 +24478,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Update a gist", - "scope": "gists", - "id": "update", - "method": "PATCH", - "url": "/gists/{gist_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Allows you to update or delete a gist file and rename gist files. Files from the previous version of the gist that aren't explicitly changed during an edit are unchanged.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists/#update-a-gist", - "parameters": [ + }, { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19604,8 +24493,21 @@ "deprecated": null }, { - "name": "description", - "description": "Description of the gist", + "name": "title", + "description": "The title of the issue.", + "in": "BODY", + "type": null, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "body", + "description": "The contents of the issue.", "in": "BODY", "type": "string", "required": false, @@ -19617,36 +24519,36 @@ "deprecated": null }, { - "name": "files", - "description": "Names of files to be updated", + "name": "assignee", + "description": "Login for the user that this issue should be assigned to. _NOTE: Only users with push access can set the assignee for new issues. The assignee is silently dropped otherwise. **This field is deprecated.**_", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "files.*", + "name": "milestone", "description": "", "in": "BODY", - "type": "object", + "type": null, "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "files.*.content", - "description": "The new content of the file", + "name": "labels", + "description": "Labels to associate with this issue. _NOTE: Only users with push access can set labels for new issues. Labels are silently dropped otherwise._", "in": "BODY", - "type": "string", + "type": "undefined[]", "required": false, "enum": null, "allowNull": false, @@ -19656,13 +24558,13 @@ "deprecated": null }, { - "name": "files.*.filename", - "description": "The new filename for the file", + "name": "assignees", + "description": "Logins for Users to assign to this issue. _NOTE: Only users with push access can set assignees for new issues. Assignees are silently dropped otherwise._", "in": "BODY", - "type": "string", + "type": "string[]", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, @@ -19670,30 +24572,35 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Update a gist comment", - "scope": "gists", - "id": "updateComment", - "method": "PATCH", - "url": "/gists/{gist_id}/comments/{comment_id}", + "name": "Create an issue comment", + "scope": "issues", + "id": "createComment", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gists#update-a-gist-comment", + "description": "\nYou can use the REST API to create comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications).\nCreating content too quickly using this endpoint may result in secondary rate limiting.\nSee \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\"\nand \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\"\nfor details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue-comment", "parameters": [ { - "name": "gist_id", - "description": "The unique identifier of the gist.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19705,8 +24612,21 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -19719,7 +24639,7 @@ }, { "name": "body", - "description": "The comment text.", + "description": "The contents of the comment.", "in": "BODY", "type": "string", "required": true, @@ -19732,22 +24652,28 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Create a blob", - "scope": "git", - "id": "createBlob", + "name": "Create a label", + "scope": "issues", + "id": "createLabel", "method": "POST", - "url": "/repos/{owner}/{repo}/git/blobs", + "url": "/repos/{owner}/{repo}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-blob", + "description": "Creates a label for the specified repository with the given name and color. The name and color parameters are required. The color must be a valid [hexadecimal color code](http://www.color-hex.com/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-a-label", "parameters": [ { "name": "owner", @@ -19764,7 +24690,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19776,8 +24702,8 @@ "deprecated": null }, { - "name": "content", - "description": "The new blob's content.", + "name": "name", + "description": "The name of the label. Emoji can be added to label names, using either native emoji or colon-style markup. For example, typing `:strawberry:` will render the emoji ![:strawberry:](https://github.githubassets.com/images/icons/emoji/unicode/1f353.png \":strawberry:\"). For a full list of available emoji and codes, see \"[Emoji cheat sheet](https://github.com/ikatyang/emoji-cheat-sheet).\"", "in": "BODY", "type": "string", "required": true, @@ -19789,8 +24715,21 @@ "deprecated": null }, { - "name": "encoding", - "description": "The encoding used for `content`. Currently, `\"utf-8\"` and `\"base64\"` are supported.", + "name": "color", + "description": "The [hexadecimal color code](http://www.color-hex.com/) for the label, without the leading `#`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "description", + "description": "A short description of the label. Must be 100 characters or fewer.", "in": "BODY", "type": "string", "required": false, @@ -19804,9 +24743,7 @@ ], "responses": [ { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -19815,16 +24752,16 @@ "renamed": null }, { - "name": "Create a commit", - "scope": "git", - "id": "createCommit", + "name": "Create a milestone", + "scope": "issues", + "id": "createMilestone", "method": "POST", - "url": "/repos/{owner}/{repo}/git/commits", + "url": "/repos/{owner}/{repo}/milestones", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new Git [commit object](https://git-scm.com/book/en/v1/Git-Internals-Git-Objects#Commit-Objects).\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in the table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-commit", + "description": "Creates a milestone.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-a-milestone", "parameters": [ { "name": "owner", @@ -19841,7 +24778,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -19853,8 +24790,8 @@ "deprecated": null }, { - "name": "message", - "description": "The commit message", + "name": "title", + "description": "The title of the milestone.", "in": "BODY", "type": "string", "required": true, @@ -19866,12 +24803,12 @@ "deprecated": null }, { - "name": "tree", - "description": "The SHA of the tree object this commit points to", + "name": "state", + "description": "The state of the milestone. Either `open` or `closed`.", "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["open", "closed"], "allowNull": false, "mapToData": null, "validation": null, @@ -19879,10 +24816,10 @@ "deprecated": null }, { - "name": "parents", - "description": "The SHAs of the commits that were the parents of this commit. If omitted or empty, the commit will be written as a root commit. For a single parent, an array of one SHA should be provided; for a merge commit, an array of more than one should be provided.", + "name": "description", + "description": "A description of the milestone.", "in": "BODY", - "type": "string[]", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -19892,10 +24829,10 @@ "deprecated": null }, { - "name": "author", - "description": "Information about the author of the commit. By default, the `author` will be the authenticated user and the current date. See the `author` and `committer` object below for details.", + "name": "due_on", + "description": "The milestone due date. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -19903,11 +24840,47 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Delete an issue comment", + "scope": "issues", + "id": "deleteComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "You can use the REST API to delete comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-an-issue-comment", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "author.name", - "description": "The name of the author (or committer) of the commit", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -19918,10 +24891,10 @@ "deprecated": null }, { - "name": "author.email", - "description": "The email of the author (or committer) of the commit", - "in": "BODY", - "type": "string", + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -19929,13 +24902,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a label", + "scope": "issues", + "id": "deleteLabel", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/labels/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a label using the given label name.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-a-label", + "parameters": [ { - "name": "author.date", - "description": "Indicates when this commit was authored (or committed). This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19944,11 +24933,11 @@ "deprecated": null }, { - "name": "committer", - "description": "Information about the person who is making the commit. By default, `committer` will use the information set in `author`. See the `author` and `committer` object below for details.", - "in": "BODY", - "type": "object", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19957,24 +24946,40 @@ "deprecated": null }, { - "name": "committer.name", - "description": "The name of the author (or committer) of the commit", - "in": "BODY", + "name": "name", + "description": "", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a milestone", + "scope": "issues", + "id": "deleteMilestone", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a milestone using the given milestone number.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-a-milestone", + "parameters": [ { - "name": "committer.email", - "description": "The email of the author (or committer) of the commit", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19983,11 +24988,11 @@ "deprecated": null }, { - "name": "committer.date", - "description": "Indicates when this commit was authored (or committed). This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -19996,11 +25001,11 @@ "deprecated": null }, { - "name": "signature", - "description": "The [PGP signature](https://en.wikipedia.org/wiki/Pretty_Good_Privacy) of the commit. GitHub adds the signature to the `gpgsig` header of the created commit. For a commit signature to be verifiable by Git or GitHub, it must be an ASCII-armored detached PGP signature over the string commit as it would be written to the object database. To pass a `signature` parameter, you need to first manually create a valid PGP signature, which can be complicated. You may find it easier to [use the command line](https://git-scm.com/book/id/v2/Git-Tools-Signing-Your-Work) to create signed commits.", - "in": "BODY", - "type": "string", - "required": false, + "name": "milestone_number", + "description": "The number that identifies the milestone.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -20010,26 +25015,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a reference", - "scope": "git", - "id": "createRef", - "method": "POST", - "url": "/repos/{owner}/{repo}/git/refs", + "name": "Get an issue", + "scope": "issues", + "id": "get", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/{issue_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a reference for your repository. You are unable to create new references for empty repositories, even if the commit SHA-1 hash used exists. Empty repositories are repositories without branches.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference", + "description": "The API returns a [`301 Moved Permanently` status](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-redirects-redirects) if the issue was\n[transferred](https://docs.github.com/enterprise-cloud@latest//articles/transferring-an-issue-to-another-repository/) to another repository. If\nthe issue was transferred to or deleted from a repository where the authenticated user lacks read access, the API\nreturns a `404 Not Found` status. If the issue was deleted from a repository where the authenticated user has read\naccess, the API returns a `410 Gone` status. To receive webhook events for transferred and deleted issues, subscribe\nto the [`issues`](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#issues) webhook.\n\n**Note**: GitHub's REST API considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue", "parameters": [ { "name": "owner", @@ -20046,7 +25047,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20058,9 +25059,44 @@ "deprecated": null }, { - "name": "ref", - "description": "The name of the fully qualified reference (ie: `refs/heads/master`). If it doesn't start with 'refs' and have at least two slashes, it will be rejected.", - "in": "BODY", + "name": "issue_number", + "description": "The number that identifies the issue.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 304, "description": "Not modified" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } + ], + "renamed": null + }, + { + "name": "Get an issue comment", + "scope": "issues", + "id": "getComment", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "You can use the REST API to get comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue-comment", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20071,9 +25107,9 @@ "deprecated": null }, { - "name": "sha", - "description": "The SHA1 value for this reference.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20084,11 +25120,11 @@ "deprecated": null }, { - "name": "key", - "description": "", - "in": "BODY", - "type": "string", - "required": false, + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -20098,25 +25134,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a tag object", - "scope": "git", - "id": "createTag", - "method": "POST", - "url": "/repos/{owner}/{repo}/git/tags", + "name": "Get an issue event", + "scope": "issues", + "id": "getEvent", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/events/{event_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Note that creating a tag object does not create the reference that makes a tag in Git. If you want to create an annotated tag in Git, you have to do this call to create the tag object, and then [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference) the `refs/tags/[tag]` reference. If you want to create a lightweight tag, you only have to [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-reference) the tag reference - this call would be unnecessary.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-tag-object", + "description": "Gets a single event by the event id.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue-event", "parameters": [ { "name": "owner", @@ -20133,7 +25166,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20145,10 +25178,10 @@ "deprecated": null }, { - "name": "tag", - "description": "The tag's name. This is typically a version (e.g., \"v0.0.1\").", - "in": "BODY", - "type": "string", + "name": "event_id", + "description": "", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -20156,11 +25189,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } + ], + "renamed": null + }, + { + "name": "Get a label", + "scope": "issues", + "id": "getLabel", + "method": "GET", + "url": "/repos/{owner}/{repo}/labels/{name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a label using the given name.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-a-label", + "parameters": [ { - "name": "message", - "description": "The tag message.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20171,9 +25225,9 @@ "deprecated": null }, { - "name": "object", - "description": "The SHA of the git object this is tagging.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20184,35 +25238,41 @@ "deprecated": null }, { - "name": "type", - "description": "The type of the object we're tagging. Normally this is a `commit` but it can also be a `tree` or a `blob`.", - "in": "BODY", + "name": "name", + "description": "", + "in": "PATH", "type": "string", "required": true, - "enum": ["commit", "tree", "blob"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "tagger", - "description": "An object with information about the individual creating the tag.", - "in": "BODY", - "type": "object", - "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get a milestone", + "scope": "issues", + "id": "getMilestone", + "method": "GET", + "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a milestone using the given milestone number.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-a-milestone", + "parameters": [ { - "name": "tagger.name", - "description": "The name of the author of the tag", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20223,9 +25283,9 @@ "deprecated": null }, { - "name": "tagger.email", - "description": "The email of the author of the tag", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -20236,11 +25296,11 @@ "deprecated": null }, { - "name": "tagger.date", - "description": "When this object was tagged. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", - "type": "string", - "required": false, + "name": "milestone_number", + "description": "The number that identifies the milestone.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -20250,33 +25310,37 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a tree", - "scope": "git", - "id": "createTree", - "method": "POST", - "url": "/repos/{owner}/{repo}/git/trees", + "name": "List issues assigned to the authenticated user", + "scope": "issues", + "id": "list", + "method": "GET", + "url": "/issues", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The tree creation API accepts nested entries. If you specify both a tree and a nested path modifying that tree, this endpoint will overwrite the contents of the tree with the new path contents, and create a new tree structure.\n\nIf you use this endpoint to add, delete, or modify the file contents in a tree, you will need to commit the tree and then update a branch to point to the commit. For more information see \"[Create a commit](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-commit)\" and \"[Update a reference](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#update-a-reference).\"\n\nReturns an error if you try to delete a file that does not exist.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#create-a-tree", + "description": "List issues assigned to the authenticated user across all visible repositories including owned repositories, member\nrepositories, and organization repositories. You can use the `filter` query parameter to fetch issues that are not\nnecessarily assigned to you.\n\n\n**Note**: GitHub's REST API considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issues-assigned-to-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "filter", + "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": [ + "assigned", + "created", + "mentioned", + "subscribed", + "repos", + "all" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -20284,12 +25348,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "state", + "description": "Indicates the state of the issues to return.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -20297,11 +25361,11 @@ "deprecated": null }, { - "name": "tree", - "description": "Objects (of `path`, `mode`, `type`, and `sha`) specifying a tree structure.", - "in": "BODY", - "type": "object[]", - "required": true, + "name": "labels", + "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20310,12 +25374,12 @@ "deprecated": null }, { - "name": "tree[].path", - "description": "The file referenced in the tree.", - "in": "BODY", + "name": "sort", + "description": "What to sort results by.", + "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["created", "updated", "comments"], "allowNull": false, "mapToData": null, "validation": null, @@ -20323,12 +25387,12 @@ "deprecated": null }, { - "name": "tree[].mode", - "description": "The file mode; one of `100644` for file (blob), `100755` for executable (blob), `040000` for subdirectory (tree), `160000` for submodule (commit), or `120000` for a blob that specifies the path of a symlink.", - "in": "BODY", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["100644", "100755", "040000", "160000", "120000"], + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -20336,12 +25400,12 @@ "deprecated": null }, { - "name": "tree[].type", - "description": "Either `blob`, `tree`, or `commit`.", - "in": "BODY", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["blob", "tree", "commit"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -20349,23 +25413,23 @@ "deprecated": null }, { - "name": "tree[].sha", - "description": "The SHA1 checksum ID of the object in the tree. Also called `tree.sha`. If the value is `null` then the file will be deleted. \n \n**Note:** Use either `tree.sha` or `content` to specify the contents of the entry. Using both `tree.sha` and `content` will return an error.", - "in": "BODY", - "type": "string", + "name": "collab", + "description": "", + "in": "QUERY", + "type": "boolean", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "tree[].content", - "description": "The content you want this file to have. GitHub will write this blob out and use that SHA for this entry. Use either this, or `tree.sha`. \n \n**Note:** Use either `tree.sha` or `content` to specify the contents of the entry. Using both `tree.sha` and `content` will return an error.", - "in": "BODY", - "type": "string", + "name": "orgs", + "description": "", + "in": "QUERY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -20375,10 +25439,10 @@ "deprecated": null }, { - "name": "base_tree", - "description": "The SHA1 of an existing Git tree object which will be used as the base for the new tree. If provided, a new Git tree object will be created from entries in the Git tree object pointed to by `base_tree` and entries defined in the `tree` parameter. Entries defined in the `tree` parameter will overwrite items from `base_tree` with the same `path`. If you're creating new changes on a branch, then normally you'd set `base_tree` to the SHA1 of the Git tree object of the current latest commit on the branch you're working on.\nIf not provided, GitHub will create a new Git tree object from only the entries defined in the `tree` parameter. If you create a new commit pointing to such a tree, then all files which were a part of the parent commit's tree and were not defined in the `tree` parameter will be listed as deleted by the new commit.\n", - "in": "BODY", - "type": "string", + "name": "owned", + "description": "", + "in": "QUERY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -20386,37 +25450,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Delete a reference", - "scope": "git", - "id": "deleteRef", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/git/refs/{ref}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#delete-a-reference", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "pulls", + "description": "", + "in": "QUERY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20425,11 +25465,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20438,11 +25478,11 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20452,7 +25492,9 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -20461,16 +25503,16 @@ "renamed": null }, { - "name": "Get a blob", - "scope": "git", - "id": "getBlob", + "name": "List assignees", + "scope": "issues", + "id": "listAssignees", "method": "GET", - "url": "/repos/{owner}/{repo}/git/blobs/{file_sha}", + "url": "/repos/{owner}/{repo}/assignees", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The `content` in the response will always be Base64 encoded.\n\n_Note_: This API supports blobs up to 100 megabytes in size.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-blob", + "description": "Lists the [available assignees](https://docs.github.com/enterprise-cloud@latest//articles/assigning-issues-and-pull-requests-to-other-github-users/) for issues in a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-assignees", "parameters": [ { "name": "owner", @@ -20487,7 +25529,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20499,41 +25541,49 @@ "deprecated": null }, { - "name": "file_sha", - "description": "", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a commit", - "scope": "git", - "id": "getCommit", + "name": "List issue comments", + "scope": "issues", + "id": "listComments", "method": "GET", - "url": "/repos/{owner}/{repo}/git/commits/{commit_sha}", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a Git [commit object](https://git-scm.com/book/en/v1/Git-Internals-Git-Objects#Commit-Objects).\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in the table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-commit", + "description": "You can use the REST API to list comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.\n\nIssue comments are ordered by ascending ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-comments", "parameters": [ { "name": "owner", @@ -20550,7 +25600,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20562,10 +25612,10 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -20573,32 +25623,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get a reference", - "scope": "git", - "id": "getRef", - "method": "GET", - "url": "/repos/{owner}/{repo}/git/ref/{ref}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns a single reference from your Git database. The `:ref` in the URL must be formatted as `heads/` for branches and `tags/` for tags. If the `:ref` doesn't match an existing ref, a `404` is returned.\n\n**Note:** You need to explicitly [request a pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) to trigger a test merge commit, which checks the mergeability of pull requests. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-reference", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20607,11 +25638,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20620,11 +25651,11 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20635,21 +25666,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } ], "renamed": null }, { - "name": "Get a tag", - "scope": "git", - "id": "getTag", + "name": "List issue comments for a repository", + "scope": "issues", + "id": "listCommentsForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/git/tags/{tag_sha}", + "url": "/repos/{owner}/{repo}/issues/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tag", + "description": "You can use the REST API to list comments on issues and pull requests for a repository. Every pull request is an issue, but not every issue is a pull request.\n\nBy default, issue comments are ordered by ascending ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-comments-for-a-repository", "parameters": [ { "name": "owner", @@ -20666,7 +25698,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20678,44 +25710,25 @@ "deprecated": null }, { - "name": "tag_sha", - "description": "", - "in": "PATH", + "name": "sort", + "description": "The property to sort the results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["created", "updated"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get a tree", - "scope": "git", - "id": "getTree", - "method": "GET", - "url": "/repos/{owner}/{repo}/git/trees/{tree_sha}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns a single tree using the SHA1 value for that tree.\n\nIf `truncated` is `true` in the response then the number of items in the `tree` array exceeded our maximum limit. If you need to fetch more items, use the non-recursive method of fetching trees, and fetch one sub-tree at a time.\n\n\n**Note**: The limit for the `tree` array is 100,000 entries with a maximum size of 7 MB when using the `recursive` parameter.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tree", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "direction", + "description": "Either `asc` or `desc`. Ignored without the `sort` parameter.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -20723,11 +25736,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20736,11 +25749,11 @@ "deprecated": null }, { - "name": "tree_sha", - "description": "", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20749,10 +25762,10 @@ "deprecated": null }, { - "name": "recursive", - "description": "Setting this parameter to any value returns the objects or subtrees referenced by the tree specified in `:tree_sha`. For example, setting `recursive` to any of the following will enable returning objects or subtrees: `0`, `1`, `\"true\"`, and `\"false\"`. Omit this parameter to prevent recursively returning objects or subtrees.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -20773,16 +25786,16 @@ "renamed": null }, { - "name": "List matching references", - "scope": "git", - "id": "listMatchingRefs", + "name": "List issue events", + "scope": "issues", + "id": "listEvents", "method": "GET", - "url": "/repos/{owner}/{repo}/git/matching-refs/{ref}", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/events", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns an array of references from your Git database that match the supplied name. The `:ref` in the URL must be formatted as `heads/` for branches and `tags/` for tags. If the `:ref` doesn't exist in the repository, but existing refs start with `:ref`, they will be returned as an array.\n\nWhen you use this endpoint without providing a `:ref`, it will return an array of all the references from your Git database, including notes and stashes if they exist on the server. Anything in the namespace is returned, not just `heads` and `tags`.\n\n**Note:** You need to explicitly [request a pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) to trigger a test merge commit, which checks the mergeability of pull requests. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".\n\nIf you request matching references for a branch named `feature` but the branch `feature` doesn't exist, the response can still include other matching head refs that start with the word `feature`, such as `featureA` and `featureB`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#list-matching-references", + "description": "Lists all events for an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-events", "parameters": [ { "name": "owner", @@ -20799,7 +25812,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20811,10 +25824,10 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -20822,22 +25835,51 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 410, "description": "Gone" } + ], "renamed": null }, { - "name": "Update a reference", - "scope": "git", - "id": "updateRef", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/git/refs/{ref}", + "name": "List issue events for a repository", + "scope": "issues", + "id": "listEventsForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/events", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/git#update-a-reference", + "description": "Lists events for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-events-for-a-repository", "parameters": [ { "name": "owner", @@ -20854,20 +25896,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "ref", - "description": "The name of the fully qualified reference to update. For example, `refs/heads/master`. If the value doesn't start with `refs` and have at least two slashes, it will be rejected.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20879,11 +25908,11 @@ "deprecated": null }, { - "name": "sha", - "description": "The SHA1 value to set this reference to", - "in": "BODY", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -20892,10 +25921,10 @@ "deprecated": null }, { - "name": "force", - "description": "Indicates whether to force the update or to make sure the update is a fast-forward update. Leaving this out or setting it to `false` will make sure you're not overwriting work.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -20915,38 +25944,20 @@ "renamed": null }, { - "name": "Get all gitignore templates", - "scope": "gitignore", - "id": "getAllTemplates", - "method": "GET", - "url": "/gitignore/templates", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List all templates available to pass as an option when [creating a repository](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-for-the-authenticated-user).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gitignore#get-all-gitignore-templates", - "parameters": [], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "Get a gitignore template", - "scope": "gitignore", - "id": "getTemplate", + "name": "List timeline events for an issue", + "scope": "issues", + "id": "listEventsForTimeline", "method": "GET", - "url": "/gitignore/templates/{name}", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/timeline", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The API also allows fetching the source of a single template.\nUse the raw [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/) to get the raw contents.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/gitignore#get-a-gitignore-template", + "description": "List all timeline events for an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-timeline-events-for-an-issue", "parameters": [ { - "name": "name", - "description": "", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -20956,47 +25967,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "Get interaction restrictions for your public repositories", - "scope": "interactions", - "id": "getRestrictionsForAuthenticatedUser", - "method": "GET", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Shows which type of GitHub user can interact with your public repositories and when the restriction expires.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-your-public-repositories", - "parameters": [], - "responses": [ - { "code": 200, "description": "Default response" }, - { "code": 204, "description": "Response when there are no restrictions" } - ], - "renamed": null - }, - { - "name": "Get interaction restrictions for an organization", - "scope": "interactions", - "id": "getRestrictionsForOrg", - "method": "GET", - "url": "/orgs/{org}/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Shows which type of GitHub user can interact with this organization and when the restriction expires. If there is no restrictions, you will see an empty response.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -21006,28 +25980,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get interaction restrictions for a repository", - "scope": "interactions", - "id": "getRestrictionsForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Shows which type of GitHub user can interact with this repository and when the restriction expires. If there are no restrictions, you will see an empty response.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -21037,11 +25995,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21050,101 +26021,52 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get interaction restrictions for your public repositories", - "scope": "interactions", - "id": "getRestrictionsForYourPublicRepos", - "method": "GET", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Shows which type of GitHub user can interact with your public repositories and when the restriction expires.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#get-interaction-restrictions-for-your-public-repositories", - "parameters": [], "responses": [ - { "code": 200, "description": "Default response" }, - { "code": 204, "description": "Response when there are no restrictions" } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } ], - "renamed": { - "before": { - "scope": "interactions", - "id": "getRestrictionsForYourPublicRepos" - }, - "after": { - "scope": "interactions", - "id": "getRestrictionsForAuthenticatedUser" - }, - "date": "2021-02-02", - "note": null - } - }, - { - "name": "Remove interaction restrictions from your public repositories", - "scope": "interactions", - "id": "removeRestrictionsForAuthenticatedUser", - "method": "DELETE", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes any interaction restrictions from your public repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-from-your-public-repositories", - "parameters": [], - "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Remove interaction restrictions for an organization", - "scope": "interactions", - "id": "removeRestrictionsForOrg", - "method": "DELETE", - "url": "/orgs/{org}/interaction-limits", + "name": "List user account issues assigned to the authenticated user", + "scope": "issues", + "id": "listForAuthenticatedUser", + "method": "GET", + "url": "/user/issues", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes all interaction restrictions from public repositories in the given organization. You must be an organization owner to remove restrictions.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-for-an-organization", + "description": "List issues across owned and member repositories assigned to the authenticated user.\n\n**Note**: GitHub's REST API considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-user-account-issues-assigned-to-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "filter", + "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": [ + "assigned", + "created", + "mentioned", + "subscribed", + "repos", + "all" + ], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Remove interaction restrictions for a repository", - "scope": "interactions", - "id": "removeRestrictionsForRepo", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes all interaction restrictions from the given repository. You must have owner or admin access to remove restrictions. If the interaction limit is set for the user or organization that owns this repository, you will receive a `409 Conflict` response and will not be able to use this endpoint to change the interaction limit for a single repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "state", + "description": "Indicates the state of the issues to return.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -21152,70 +26074,38 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "labels", + "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 409, "description": "Response" } - ], - "renamed": null - }, - { - "name": "Remove interaction restrictions from your public repositories", - "scope": "interactions", - "id": "removeRestrictionsForYourPublicRepos", - "method": "DELETE", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes any interaction restrictions from your public repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#remove-interaction-restrictions-from-your-public-repositories", - "parameters": [], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": { - "before": { - "scope": "interactions", - "id": "removeRestrictionsForYourPublicRepos" }, - "after": { - "scope": "interactions", - "id": "removeRestrictionsForAuthenticatedUser" + { + "name": "sort", + "description": "What to sort results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated", "comments"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, - "date": "2021-02-02", - "note": null - } - }, - { - "name": "Set interaction restrictions for your public repositories", - "scope": "interactions", - "id": "setRestrictionsForAuthenticatedUser", - "method": "PUT", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Temporarily restricts which type of GitHub user can interact with your public repositories. Setting the interaction limit at the user level will overwrite any interaction limits that are set for individual repositories owned by the user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-your-public-repositories", - "parameters": [ { - "name": "limit", - "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", - "in": "BODY", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": ["existing_users", "contributors_only", "collaborators_only"], + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -21223,18 +26113,38 @@ "deprecated": null }, { - "name": "expiry", - "description": "The duration of the interaction restriction. Default: `one_day`.", - "in": "BODY", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", "required": false, - "enum": [ - "one_day", - "three_days", - "one_week", - "one_month", - "six_months" - ], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -21244,24 +26154,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 304, "description": "Not modified" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Set interaction restrictions for an organization", - "scope": "interactions", - "id": "setRestrictionsForOrg", - "method": "PUT", - "url": "/orgs/{org}/interaction-limits", + "name": "List organization issues assigned to the authenticated user", + "scope": "issues", + "id": "listForOrg", + "method": "GET", + "url": "/orgs/{org}/issues", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Temporarily restricts interactions to a certain type of GitHub user in any public repository in the given organization. You must be an organization owner to set these restrictions. Setting the interaction limit at the organization level will overwrite any interaction limits that are set for individual repositories owned by the organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-an-organization", + "description": "List issues in an organization assigned to the authenticated user.\n\n**Note**: GitHub's REST API considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-organization-issues-assigned-to-the-authenticated-user", "parameters": [ { "name": "org", @@ -21277,12 +26185,19 @@ "deprecated": null }, { - "name": "limit", - "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", - "in": "BODY", + "name": "filter", + "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", + "in": "QUERY", "type": "string", - "required": true, - "enum": ["existing_users", "contributors_only", "collaborators_only"], + "required": false, + "enum": [ + "assigned", + "created", + "mentioned", + "subscribed", + "repos", + "all" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -21290,52 +26205,24 @@ "deprecated": null }, { - "name": "expiry", - "description": "The duration of the interaction restriction. Default: `one_day`.", - "in": "BODY", + "name": "state", + "description": "Indicates the state of the issues to return.", + "in": "QUERY", "type": "string", "required": false, - "enum": [ - "one_day", - "three_days", - "one_week", - "one_month", - "six_months" - ], + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Set interaction restrictions for a repository", - "scope": "interactions", - "id": "setRestrictionsForRepo", - "method": "PUT", - "url": "/repos/{owner}/{repo}/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Temporarily restricts interactions to a certain type of GitHub user within the given repository. You must have owner or admin access to set these restrictions. If an interaction limit is set for the user or organization that owns this repository, you will receive a `409 Conflict` response and will not be able to use this endpoint to change the interaction limit for a single repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "labels", + "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21344,12 +26231,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "sort", + "description": "What to sort results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["created", "updated", "comments"], "allowNull": false, "mapToData": null, "validation": null, @@ -21357,12 +26244,12 @@ "deprecated": null }, { - "name": "limit", - "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", - "in": "BODY", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": ["existing_users", "contributors_only", "collaborators_only"], + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -21370,50 +26257,25 @@ "deprecated": null }, { - "name": "expiry", - "description": "The duration of the interaction restriction. Default: `one_day`.", - "in": "BODY", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", "required": false, - "enum": [ - "one_day", - "three_days", - "one_week", - "one_month", - "six_months" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 409, "description": "Response" } - ], - "renamed": null - }, - { - "name": "Set interaction restrictions for your public repositories", - "scope": "interactions", - "id": "setRestrictionsForYourPublicRepos", - "method": "PUT", - "url": "/user/interaction-limits", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Temporarily restricts which type of GitHub user can interact with your public repositories. Setting the interaction limit at the user level will overwrite any interaction limits that are set for individual repositories owned by the user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/interactions#set-interaction-restrictions-for-your-public-repositories", - "parameters": [ + }, { - "name": "limit", - "description": "The type of GitHub user that can comment, open issues, or create pull requests while the interaction limit is in effect.", - "in": "BODY", - "type": "string", - "required": true, - "enum": ["existing_users", "contributors_only", "collaborators_only"], + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -21421,18 +26283,12 @@ "deprecated": null }, { - "name": "expiry", - "description": "The duration of the interaction restriction. Default: `one_day`.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, - "enum": [ - "one_day", - "three_days", - "one_week", - "one_month", - "six_months" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -21442,35 +26298,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], - "renamed": { - "before": { - "scope": "interactions", - "id": "setRestrictionsForYourPublicRepos" - }, - "after": { - "scope": "interactions", - "id": "setRestrictionsForAuthenticatedUser" - }, - "date": "2021-02-02", - "note": null - } + "renamed": null }, { - "name": "Add assignees to an issue", + "name": "List repository issues", "scope": "issues", - "id": "addAssignees", - "method": "POST", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/assignees", + "id": "listForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Adds up to 10 assignees to an issue. Users already assigned to an issue are not replaced.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#add-assignees-to-an-issue", + "description": "List issues in a repository. Only open issues will be listed.\n\n**Note**: GitHub's REST API considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-repository-issues", "parameters": [ { "name": "owner", @@ -21487,7 +26329,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -21499,11 +26341,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "milestone", + "description": "If an `integer` is passed, it should refer to a milestone by its `number` field. If the string `*` is passed, issues with any milestone are accepted. If the string `none` is passed, issues without milestones are returned.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21512,40 +26354,24 @@ "deprecated": null }, { - "name": "assignees", - "description": "Usernames of people to assign this issue to. _NOTE: Only users with push access can add assignees to an issue. Assignees are silently ignored otherwise._", - "in": "BODY", - "type": "string[]", + "name": "state", + "description": "Indicates the state of the issues to return.", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Add labels to an issue", - "scope": "issues", - "id": "addLabels", - "method": "POST", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#add-labels-to-an-issue", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "assignee", + "description": "Can be the name of a user. Pass in `none` for issues with no assigned user, and `*` for issues assigned to any user.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21554,11 +26380,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "creator", + "description": "The user that created the issue.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21567,11 +26393,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "mentioned", + "description": "A user that's mentioned in the issue.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21581,9 +26407,9 @@ }, { "name": "labels", - "description": "", - "in": "BODY", - "type": "object[]", + "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -21593,49 +26419,37 @@ "deprecated": null }, { - "name": "labels[].name", - "description": "", - "in": "BODY", + "name": "sort", + "description": "What to sort results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["created", "updated", "comments"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Check if a user can be assigned", - "scope": "issues", - "id": "checkUserCanBeAssigned", - "method": "GET", - "url": "/repos/{owner}/{repo}/assignees/{assignee}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Checks if a user has permission to be assigned to an issue in this repository.\n\nIf the `assignee` can be assigned to issues in the repository, a `204` header with no content is returned.\n\nOtherwise a `404` status code is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#check-if-a-user-can-be-assigned", - "parameters": [ + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21644,11 +26458,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21657,11 +26471,11 @@ "deprecated": null }, { - "name": "assignee", - "description": "", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21671,28 +26485,27 @@ } ], "responses": [ + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 404, "description": "Resource not found" }, { - "code": 204, - "description": "If the `assignee` can be assigned to issues in the repository, a `204` header with no content is returned." - }, - { - "code": 404, - "description": "Otherwise a `404` status code is returned." + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], "renamed": null }, { - "name": "Create an issue", + "name": "List labels for issues in a milestone", "scope": "issues", - "id": "create", - "method": "POST", - "url": "/repos/{owner}/{repo}/issues", + "id": "listLabelsForMilestone", + "method": "GET", + "url": "/repos/{owner}/{repo}/milestones/{milestone_number}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Any user with pull access to a repository can create an issue. If [issues are disabled in the repository](https://docs.github.com/articles/disabling-issues/), the API returns a `410 Gone` status.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue", + "description": "Lists labels for issues in a milestone.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-issues-in-a-milestone", "parameters": [ { "name": "owner", @@ -21709,7 +26522,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -21721,10 +26534,10 @@ "deprecated": null }, { - "name": "title", - "description": "The title of the issue.", - "in": "BODY", - "type": null, + "name": "milestone_number", + "description": "The number that identifies the milestone.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -21734,49 +26547,10 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the issue.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "assignee", - "description": "Login for the user that this issue should be assigned to. _NOTE: Only users with push access can set the assignee for new issues. The assignee is silently dropped otherwise. **This field is deprecated.**_", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": true, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "milestone", - "description": "", - "in": "BODY", - "type": null, - "required": false, - "enum": null, - "allowNull": true, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "labels", - "description": "Labels to associate with this issue. _NOTE: Only users with push access can set labels for new issues. Labels are silently dropped otherwise._", - "in": "BODY", - "type": "undefined[]", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -21786,10 +26560,10 @@ "deprecated": null }, { - "name": "assignees", - "description": "Logins for Users to assign to this issue. _NOTE: Only users with push access can set assignees for new issues. Assignees are silently dropped otherwise._", - "in": "BODY", - "type": "string[]", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -21799,30 +26573,20 @@ "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 503, "description": "Service unavailable" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Create an issue comment", + "name": "List labels for a repository", "scope": "issues", - "id": "createComment", - "method": "POST", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/comments", + "id": "listLabelsForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue-comment", + "description": "Lists all labels for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-a-repository", "parameters": [ { "name": "owner", @@ -21839,7 +26603,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -21851,11 +26615,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21864,11 +26628,11 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the comment.", - "in": "BODY", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -21878,28 +26642,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a label", + "name": "List labels for an issue", "scope": "issues", - "id": "createLabel", - "method": "POST", - "url": "/repos/{owner}/{repo}/labels", + "id": "listLabelsOnIssue", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-a-label", + "description": "Lists all labels for an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-an-issue", "parameters": [ { "name": "owner", @@ -21916,7 +26674,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -21928,10 +26686,10 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the label. Emoji can be added to label names, using either native emoji or colon-style markup. For example, typing `:strawberry:` will render the emoji ![:strawberry:](https://github.githubassets.com/images/icons/emoji/unicode/1f353.png \":strawberry:\"). For a full list of available emoji and codes, see \"[Emoji cheat sheet](https://github.com/ikatyang/emoji-cheat-sheet).\"", - "in": "BODY", - "type": "string", + "name": "issue_number", + "description": "The number that identifies the issue.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -21941,10 +26699,10 @@ "deprecated": null }, { - "name": "color", - "description": "The [hexadecimal color code](http://www.color-hex.com/) for the label, without the leading `#`.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -21954,10 +26712,10 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the label. Must be 100 characters or fewer.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -21968,26 +26726,24 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 410, "description": "Gone" } ], "renamed": null }, { - "name": "Create a milestone", + "name": "List milestones", "scope": "issues", - "id": "createMilestone", - "method": "POST", + "id": "listMilestones", + "method": "GET", "url": "/repos/{owner}/{repo}/milestones", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-a-milestone", + "description": "Lists milestones for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-milestones", "parameters": [ { "name": "owner", @@ -22004,7 +26760,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22016,12 +26772,12 @@ "deprecated": null }, { - "name": "title", - "description": "The title of the milestone.", - "in": "BODY", + "name": "state", + "description": "The state of the milestone. Either `open`, `closed`, or `all`.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -22029,12 +26785,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the milestone. Either `open` or `closed`.", - "in": "BODY", + "name": "sort", + "description": "What to sort results by. Either `due_on` or `completeness`.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["open", "closed"], + "enum": ["due_on", "completeness"], "allowNull": false, "mapToData": null, "validation": null, @@ -22042,11 +26798,24 @@ "deprecated": null }, { - "name": "description", - "description": "A description of the milestone.", - "in": "BODY", + "name": "direction", + "description": "The direction of the sort. Either `asc` or `desc`.", + "in": "QUERY", "type": "string", "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -22055,10 +26824,10 @@ "deprecated": null }, { - "name": "due_on", - "description": "The milestone due date. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -22069,26 +26838,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete an issue comment", + "name": "Lock an issue", "scope": "issues", - "id": "deleteComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", + "id": "lock", + "method": "PUT", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/lock", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-an-issue-comment", + "description": "Users with push access can lock an issue or pull request's conversation.\n\nNote that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#lock-an-issue", "parameters": [ { "name": "owner", @@ -22105,7 +26870,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22117,8 +26882,8 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -22128,22 +26893,44 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "lock_reason", + "description": "The reason for locking the issue or pull request conversation. Lock will fail if you don't use one of these reasons: \n * `off-topic` \n * `too heated` \n * `resolved` \n * `spam`", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["off-topic", "too heated", "resolved", "spam"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete a label", + "name": "Remove all labels from an issue", "scope": "issues", - "id": "deleteLabel", + "id": "removeAllLabels", "method": "DELETE", - "url": "/repos/{owner}/{repo}/labels/{name}", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-a-label", + "description": "Removes all labels from an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#remove-all-labels-from-an-issue", "parameters": [ { "name": "owner", @@ -22160,7 +26947,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22172,10 +26959,10 @@ "deprecated": null }, { - "name": "name", - "description": "", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -22185,20 +26972,25 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } + ], "renamed": null }, { - "name": "Delete a milestone", + "name": "Remove assignees from an issue", "scope": "issues", - "id": "deleteMilestone", + "id": "removeAssignees", "method": "DELETE", - "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/assignees", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#delete-a-milestone", + "description": "Removes one or more assignees from an issue.", + "documentationUrl": "https://docs.github.com/rest/reference/issues#remove-assignees-from-an-issue", "parameters": [ { "name": "owner", @@ -22227,8 +27019,8 @@ "deprecated": null }, { - "name": "milestone_number", - "description": "The number that identifies the milestone.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -22238,25 +27030,35 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "assignees", + "description": "Usernames of assignees to remove from an issue. _NOTE: Only users with push access can remove assignees from an issue. Assignees are silently ignored otherwise._", + "in": "BODY", + "type": "string[]", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get an issue", + "name": "Remove a label from an issue", "scope": "issues", - "id": "get", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}", + "id": "removeLabel", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The API returns a [`301 Moved Permanently` status](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-redirects-redirects) if the issue was\n[transferred](https://docs.github.com/articles/transferring-an-issue-to-another-repository/) to another repository. If\nthe issue was transferred to or deleted from a repository where the authenticated user lacks read access, the API\nreturns a `404 Not Found` status. If the issue was deleted from a repository where the authenticated user has read\naccess, the API returns a `410 Gone` status. To receive webhook events for transferred and deleted issues, subscribe\nto the [`issues`](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#issues) webhook.\n\n**Note**: GitHub's REST API v3 considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue", + "description": "Removes the specified label from the issue, and returns the remaining labels on the issue. This endpoint returns a `404 Not Found` status if the label does not exist.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#remove-a-label-from-an-issue", "parameters": [ { "name": "owner", @@ -22273,7 +27075,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22296,28 +27098,40 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "name", + "description": "", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, { "code": 301, "description": "Moved permanently" }, - { "code": 304, "description": "Not modified" }, { "code": 404, "description": "Resource not found" }, { "code": 410, "description": "Gone" } ], "renamed": null }, { - "name": "Get an issue comment", + "name": "Set labels for an issue", "scope": "issues", - "id": "getComment", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", + "id": "setLabels", + "method": "PUT", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue-comment", + "description": "Removes any previous labels and sets the new labels for an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#set-labels-for-an-issue", "parameters": [ { "name": "owner", @@ -22334,7 +27148,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22346,8 +27160,8 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -22357,25 +27171,57 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "labels", + "description": "", + "in": "BODY", + "type": "object[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "labels[].name", + "description": "", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 301, "description": "Moved permanently" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get an issue event", + "name": "Unlock an issue", "scope": "issues", - "id": "getEvent", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/events/{event_id}", + "id": "unlock", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/lock", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-an-issue-event", + "description": "Users with push access can unlock an issue's conversation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#unlock-an-issue", "parameters": [ { "name": "owner", @@ -22392,7 +27238,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22404,8 +27250,8 @@ "deprecated": null }, { - "name": "event_id", - "description": "", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -22418,24 +27264,23 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 204, "description": "Response" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get a label", + "name": "Update an issue", "scope": "issues", - "id": "getLabel", - "method": "GET", - "url": "/repos/{owner}/{repo}/labels/{name}", + "id": "update", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/issues/{issue_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-a-label", + "description": "Issue owners and users with push access can edit an issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-an-issue", "parameters": [ { "name": "owner", @@ -22452,7 +27297,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22464,10 +27309,10 @@ "deprecated": null }, { - "name": "name", - "description": "", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -22475,25 +27320,137 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "title", + "description": "The title of the issue.", + "in": "BODY", + "type": null, + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "body", + "description": "The contents of the issue.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "assignee", + "description": "Username to assign to this issue. **This field is deprecated.**", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "The open or closed state of the issue.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["open", "closed"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state_reason", + "description": "The reason for the state change. Ignored unless `state` is changed.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["completed", "not_planned", "reopened"], + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "milestone", + "description": "", + "in": "BODY", + "type": null, + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "labels", + "description": "Labels to associate with this issue. Pass one or more labels to _replace_ the set of labels on this issue. Send an empty array (`[]`) to clear all labels from the issue. Only users with push access can set labels for issues. Without push access to the repository, label changes are silently dropped.", + "in": "BODY", + "type": "undefined[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "assignees", + "description": "Usernames to assign to this issue. Pass one or more user logins to _replace_ the set of assignees on this issue. Send an empty array (`[]`) to clear all assignees from the issue. Only users with push access can set assignees for new issues. Without push access to the repository, assignee changes are silently dropped.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 301, "description": "Moved permanently" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Get a milestone", + "name": "Update an issue comment", "scope": "issues", - "id": "getMilestone", - "method": "GET", - "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "id": "updateComment", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#get-a-milestone", + "description": "You can use the REST API to update comments on issues and pull requests. Every pull request is an issue, but not every issue is a pull request.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-an-issue-comment", "parameters": [ { "name": "owner", @@ -22510,7 +27467,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22522,8 +27479,8 @@ "deprecated": null }, { - "name": "milestone_number", - "description": "The number that identifies the milestone.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -22533,40 +27490,49 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "body", + "description": "The contents of the comment.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List issues assigned to the authenticated user", + "name": "Update a label", "scope": "issues", - "id": "list", - "method": "GET", - "url": "/issues", + "id": "updateLabel", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/labels/{name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List issues assigned to the authenticated user across all visible repositories including owned repositories, member\nrepositories, and organization repositories. You can use the `filter` query parameter to fetch issues that are not\nnecessarily assigned to you.\n\n\n**Note**: GitHub's REST API v3 considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issues-assigned-to-the-authenticated-user", + "description": "Updates a label using the given label name.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-a-label", "parameters": [ { - "name": "filter", - "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": [ - "assigned", - "created", - "mentioned", - "subscribed", - "repos", - "all" - ], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -22574,12 +27540,12 @@ "deprecated": null }, { - "name": "state", - "description": "Indicates the state of the issues to return.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "all"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -22587,11 +27553,11 @@ "deprecated": null }, { - "name": "labels", - "description": "A list of comma separated label names. Example: `bug,ui,@high`", - "in": "QUERY", + "name": "name", + "description": "", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -22600,12 +27566,12 @@ "deprecated": null }, { - "name": "sort", - "description": "What to sort results by.", - "in": "QUERY", + "name": "new_name", + "description": "The new name of the label. Emoji can be added to label names, using either native emoji or colon-style markup. For example, typing `:strawberry:` will render the emoji ![:strawberry:](https://github.githubassets.com/images/icons/emoji/unicode/1f353.png \":strawberry:\"). For a full list of available emoji and codes, see \"[Emoji cheat sheet](https://github.com/ikatyang/emoji-cheat-sheet).\"", + "in": "BODY", "type": "string", "required": false, - "enum": ["created", "updated", "comments"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -22613,12 +27579,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", + "name": "color", + "description": "The [hexadecimal color code](http://www.color-hex.com/) for the label, without the leading `#`.", + "in": "BODY", "type": "string", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -22626,9 +27592,9 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "description", + "description": "A short description of the label. Must be 100 characters or fewer.", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -22637,13 +27603,42 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Update a milestone", + "scope": "issues", + "id": "updateMilestone", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-a-milestone", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "collab", - "description": "", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -22652,11 +27647,11 @@ "deprecated": null }, { - "name": "orgs", - "description": "", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "milestone_number", + "description": "The number that identifies the milestone.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -22665,10 +27660,10 @@ "deprecated": null }, { - "name": "owned", - "description": "", - "in": "QUERY", - "type": "boolean", + "name": "title", + "description": "The title of the milestone.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -22678,12 +27673,12 @@ "deprecated": null }, { - "name": "pulls", - "description": "", - "in": "QUERY", - "type": "boolean", + "name": "state", + "description": "The state of the milestone. Either `open` or `closed`.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": ["open", "closed"], "allowNull": false, "mapToData": null, "validation": null, @@ -22691,10 +27686,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "description", + "description": "A description of the milestone.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -22704,10 +27699,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "due_on", + "description": "The milestone due date. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -22717,32 +27712,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List assignees", - "scope": "issues", - "id": "listAssignees", + "name": "Get a license", + "scope": "licenses", + "id": "get", "method": "GET", - "url": "/repos/{owner}/{repo}/assignees", + "url": "/licenses/{license}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the [available assignees](https://docs.github.com/articles/assigning-issues-and-pull-requests-to-other-github-users/) for issues in a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-assignees", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses#get-a-license", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "license", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -22752,13 +27739,34 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get all commonly used licenses", + "scope": "licenses", + "id": "getAllCommonlyUsed", + "method": "GET", + "url": "/licenses", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses#get-all-commonly-used-licenses", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "featured", + "description": "", + "in": "QUERY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -22795,21 +27803,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 304, "description": "Not modified" } ], "renamed": null }, { - "name": "List issue comments", - "scope": "issues", - "id": "listComments", + "name": "Get the license for a repository", + "scope": "licenses", + "id": "getForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/comments", + "url": "/repos/{owner}/{repo}/license", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Issue Comments are ordered by ascending ID.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-comments", + "description": "This method returns the contents of the repository's license file, if one is detected.\n\nSimilar to [Get repository content](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-repository-content), this method also supports [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types) for retrieving the raw license content or rendered license HTML.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses/#get-the-license-for-a-repository", "parameters": [ { "name": "owner", @@ -22826,7 +27834,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22836,12 +27844,28 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Render a Markdown document", + "scope": "markdown", + "id": "render", + "method": "POST", + "url": "/markdown", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/markdown#render-a-markdown-document", + "parameters": [ { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", + "name": "text", + "description": "The Markdown text to render in HTML.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -22851,12 +27875,12 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "mode", + "description": "The rendering mode.", + "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["markdown", "gfm"], "allowNull": false, "mapToData": null, "validation": null, @@ -22864,10 +27888,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "context", + "description": "The repository context to use when creating references in `gfm` mode. For example, setting `context` to `octo-org/octo-repo` will change the text `#42` into an HTML link to issue 42 in the `octo-org/octo-repo` repository.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -22875,16 +27899,35 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Render a Markdown document in raw mode", + "scope": "markdown", + "id": "renderRaw", + "method": "POST", + "url": "/markdown/raw", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "You must send Markdown as plain text (using a `Content-Type` header of `text/plain` or `text/x-markdown`) to this endpoint, rather than using JSON format. In raw mode, [GitHub Flavored Markdown](https://github.github.com/gfm/) is not supported and Markdown will be rendered in plain format like a README.md file. Markdown content must be 400 KB or less.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/markdown#render-a-markdown-document-in-raw-mode", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "data", + "description": "raw markdown text", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null @@ -22892,22 +27935,116 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 304, "description": "Not modified" } ], "renamed": null }, { - "name": "List issue comments for a repository", - "scope": "issues", - "id": "listCommentsForRepo", + "name": "Get GitHub Enterprise Cloud meta information", + "scope": "meta", + "id": "get", "method": "GET", - "url": "/repos/{owner}/{repo}/issues/comments", + "url": "/meta", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "By default, Issue Comments are ordered by ascending ID.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-comments-for-a-repository", + "description": "Returns meta information about GitHub, including a list of GitHub's IP addresses. For more information, see \"[About GitHub's IP addresses](https://docs.github.com/enterprise-cloud@latest//articles/about-github-s-ip-addresses/).\"\n\nThe API's response also includes a list of GitHub's domain names.\n\nThe values shown in the documentation's response are example values. You must always query the API directly to get the latest values.\n\n**Note:** This endpoint returns both IPv4 and IPv6 addresses. However, not all features support IPv6. You should refer to the specific documentation for each feature to determine if IPv6 is supported.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/meta#get-github-meta-information", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Get all API versions", + "scope": "meta", + "id": "getAllVersions", + "method": "GET", + "url": "/versions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Get all supported GitHub Enterprise Cloud API versions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/meta#get-all-api-versions", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get Octocat", + "scope": "meta", + "id": "getOctocat", + "method": "GET", + "url": "/octocat", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Get the octocat as ASCII art", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/meta#get-octocat", + "parameters": [ + { + "name": "s", + "description": "The words to show in Octocat's speech bubble", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get the Zen of GitHub", + "scope": "meta", + "id": "getZen", + "method": "GET", + "url": "/zen", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Get a random sentence from the Zen of GitHub", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/meta#get-the-zen-of-github", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "GitHub API Root", + "scope": "meta", + "id": "root", + "method": "GET", + "url": "/", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Get Hypermedia links to resources accessible in GitHub's REST API", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#root-endpoint", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Cancel an import", + "scope": "migrations", + "id": "cancelImport", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/import", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Stop an import for a repository.\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.\n", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#cancel-an-import", "parameters": [ { "name": "owner", @@ -22924,7 +28061,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -22934,27 +28071,71 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["created", "updated"], + "code": 503, + "description": "Unavailable due to service under maintenance." + } + ], + "renamed": null + }, + { + "name": "Delete a user migration archive", + "scope": "migrations", + "id": "deleteArchiveForAuthenticatedUser", + "method": "DELETE", + "url": "/user/migrations/{migration_id}/archive", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a previous migration archive. Downloadable migration archives are automatically deleted after seven days. Migration metadata, which is returned in the [List user migrations](https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#list-user-migrations) and [Get a user migration status](https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#get-a-user-migration-status) endpoints, will continue to be available even after an archive is deleted.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#delete-a-user-migration-archive", + "parameters": [ + { + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete an organization migration archive", + "scope": "migrations", + "id": "deleteArchiveForOrg", + "method": "DELETE", + "url": "/orgs/{org}/migrations/{migration_id}/archive", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a previous migration archive. Migration archives are automatically deleted after seven days.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#delete-an-organization-migration-archive", + "parameters": [ { - "name": "direction", - "description": "Either `asc` or `desc`. Ignored without the `sort` parameter.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -22962,11 +28143,43 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Download an organization migration archive", + "scope": "migrations", + "id": "downloadArchiveForOrg", + "method": "GET", + "url": "/orgs/{org}/migrations/{migration_id}/archive", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Fetches the URL to a migration archive.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#download-an-organization-migration-archive", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -22975,24 +28188,43 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 302, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Download a user migration archive", + "scope": "migrations", + "id": "getArchiveForAuthenticatedUser", + "method": "GET", + "url": "/user/migrations/{migration_id}/archive", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Fetches the URL to download the migration archive as a `tar.gz` file. Depending on the resources your repository uses, the migration archive can contain JSON files with data for these objects:\n\n* attachments\n* bases\n* commit\\_comments\n* issue\\_comments\n* issue\\_events\n* issues\n* milestones\n* organizations\n* projects\n* protected\\_branches\n* pull\\_request\\_reviews\n* pull\\_requests\n* releases\n* repositories\n* review\\_comments\n* schema\n* users\n\nThe archive will also contain an `attachments` directory that includes all attachment files uploaded to GitHub.com and a `repositories` directory that contains the repository's Git data.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#download-a-user-migration-archive", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23002,26 +28234,24 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 302, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "List issue events", - "scope": "issues", - "id": "listEvents", + "name": "Get commit authors", + "scope": "migrations", + "id": "getCommitAuthors", "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/events", + "url": "/repos/{owner}/{repo}/import/authors", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-events", + "description": "Each type of source control system represents authors in a different way. For example, a Git commit author has a display name and an email address, but a Subversion commit author just has a username. The GitHub Enterprise Cloud Importer will make the author information valid, but the author might not be correct. For example, it will change the bare Subversion username `hubot` into something like `hubot `.\n\nThis endpoint and the [Map a commit author](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#map-a-commit-author) endpoint allow you to provide correct Git author information.\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#get-commit-authors", "parameters": [ { "name": "owner", @@ -23038,7 +28268,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23050,24 +28280,47 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", + "name": "since", + "description": "A user ID. Only return users with an ID greater than this ID.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "code": 503, + "description": "Unavailable due to service under maintenance." + } + ], + "renamed": null + }, + { + "name": "Get an import status", + "scope": "migrations", + "id": "getImportStatus", + "method": "GET", + "url": "/repos/{owner}/{repo}/import", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "View the progress of an import.\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.\n\n**Import status**\n\nThis section includes details about the possible values of the `status` field of the Import Progress response.\n\nAn import that does not have errors will progress through these steps:\n\n* `detecting` - the \"detection\" step of the import is in progress because the request did not include a `vcs` parameter. The import is identifying the type of source control present at the URL.\n* `importing` - the \"raw\" step of the import is in progress. This is where commit data is fetched from the original repository. The import progress response will include `commit_count` (the total number of raw commits that will be imported) and `percent` (0 - 100, the current progress through the import).\n* `mapping` - the \"rewrite\" step of the import is in progress. This is where SVN branches are converted to Git branches, and where author updates are applied. The import progress response does not include progress information.\n* `pushing` - the \"push\" step of the import is in progress. This is where the importer updates the repository on GitHub Enterprise Cloud. The import progress response will include `push_percent`, which is the percent value reported by `git push` when it is \"Writing objects\".\n* `complete` - the import is complete, and the repository is ready on GitHub Enterprise Cloud.\n\nIf there are problems, you will see one of these in the `status` field:\n\n* `auth_failed` - the import requires authentication in order to connect to the original repository. To update authentication for the import, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#update-an-import) section.\n* `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api) for more information.\n* `detection_needs_auth` - the importer requires authentication for the originating repository to continue detection. To update authentication for the import, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#update-an-import) section.\n* `detection_found_nothing` - the importer didn't recognize any source control at the URL. To resolve, [Cancel the import](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#cancel-an-import) and [retry](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#start-an-import) with the correct URL.\n* `detection_found_multiple` - the importer found several projects or repositories at the provided URL. When this is the case, the Import Progress response will also include a `project_choices` field with the possible project choices as values. To update project choice, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#update-an-import) section.\n\n**The project_choices field**\n\nWhen multiple projects are found at the provided URL, the response hash will include a `project_choices` field, the value of which is an array of hashes each representing a project choice. The exact key/value pairs of the project hashes will differ depending on the version control type.\n\n**Git LFS related fields**\n\nThis section includes details about Git LFS related fields that may be present in the Import Progress response.\n\n* `use_lfs` - describes whether the import has been opted in or out of using Git LFS. The value can be `opt_in`, `opt_out`, or `undecided` if no action has been taken.\n* `has_large_files` - the boolean value describing whether files larger than 100MB were found during the `importing` step.\n* `large_files_size` - the total size in gigabytes of files larger than 100MB found in the originating repository.\n* `large_files_count` - the total number of files larger than 100MB found in the originating repository. To see a list of these files, make a \"Get Large Files\" request.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#get-an-import-status", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23076,11 +28329,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23091,21 +28344,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 410, "description": "Gone" } + { "code": 404, "description": "Resource not found" }, + { + "code": 503, + "description": "Unavailable due to service under maintenance." + } ], "renamed": null }, { - "name": "List issue events for a repository", - "scope": "issues", - "id": "listEventsForRepo", + "name": "Get large files", + "scope": "migrations", + "id": "getLargeFiles", "method": "GET", - "url": "/repos/{owner}/{repo}/issues/events", + "url": "/repos/{owner}/{repo}/import/large_files", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-issue-events-for-a-repository", + "description": "List files larger than 100MB found during the import\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.\n", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#get-large-files", "parameters": [ { "name": "owner", @@ -23122,7 +28379,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23132,13 +28389,35 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "code": 503, + "description": "Unavailable due to service under maintenance." + } + ], + "renamed": null + }, + { + "name": "Get a user migration status", + "scope": "migrations", + "id": "getStatusForAuthenticatedUser", + "method": "GET", + "url": "/user/migrations/{migration_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Fetches a single user migration. The response includes the `state` of the migration, which can be one of the following values:\n\n* `pending` - the migration hasn't started yet.\n* `exporting` - the migration is in progress.\n* `exported` - the migration finished successfully.\n* `failed` - the migration failed.\n\nOnce the migration has been `exported` you can [download the migration archive](https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#download-a-user-migration-archive).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#get-a-user-migration-status", + "parameters": [ + { + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23147,10 +28426,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "exclude", + "description": "", "in": "QUERY", - "type": "integer", + "type": "array", "required": false, "enum": null, "allowNull": false, @@ -23162,28 +28441,28 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List timeline events for an issue", - "scope": "issues", - "id": "listEventsForTimeline", + "name": "Get an organization migration status", + "scope": "migrations", + "id": "getStatusForOrg", "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/timeline", + "url": "/orgs/{org}/migrations/{migration_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-timeline-events-for-an-issue", + "description": "Fetches the status of a migration.\n\nThe `state` of a migration can be one of the following values:\n\n* `pending`, which means the migration hasn't started yet.\n* `exporting`, which means the migration is in progress.\n* `exported`, which means the migration finished successfully.\n* `failed`, which means the migration failed.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#get-an-organization-migration-status", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23195,10 +28474,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "migration_id", + "description": "The unique identifier of the migration.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -23208,18 +28487,40 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "exclude", + "description": "Exclude attributes from the API response to improve performance", + "in": "QUERY", + "type": "array", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "* `pending`, which means the migration hasn't started yet.\n* `exporting`, which means the migration is in progress.\n* `exported`, which means the migration finished successfully.\n* `failed`, which means the migration failed." }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List user migrations", + "scope": "migrations", + "id": "listForAuthenticatedUser", + "method": "GET", + "url": "/user/migrations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all migrations a user has started.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#list-user-migrations", + "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -23249,50 +28550,31 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "List user account issues assigned to the authenticated user", - "scope": "issues", - "id": "listForAuthenticatedUser", + "name": "List organization migrations", + "scope": "migrations", + "id": "listForOrg", "method": "GET", - "url": "/user/issues", + "url": "/orgs/{org}/migrations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List issues across owned and member repositories assigned to the authenticated user.\n\n**Note**: GitHub's REST API v3 considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-user-account-issues-assigned-to-the-authenticated-user", + "description": "Lists the most recent migrations, including both exports (which can be started through the REST API) and imports (which cannot be started using the REST API).\n\nA list of `repositories` is only returned for export migrations.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#list-organization-migrations", "parameters": [ { - "name": "filter", - "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": [ - "assigned", - "created", - "mentioned", - "subscribed", - "repos", - "all" - ], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "state", - "description": "Indicates the state of the issues to return.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "all"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23300,10 +28582,10 @@ "deprecated": null }, { - "name": "labels", - "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -23313,12 +28595,12 @@ "deprecated": null }, { - "name": "sort", - "description": "What to sort results by.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["created", "updated", "comments"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23326,24 +28608,40 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", + "name": "exclude", + "description": "Exclude attributes from the API response to improve performance", "in": "QUERY", - "type": "string", + "type": "array", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repositories for a user migration", + "scope": "migrations", + "id": "listReposForAuthenticatedUser", + "method": "GET", + "url": "/user/migrations/{migration_id}/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all the repositories for this user migration.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#list-repositories-for-a-user-migration", + "parameters": [ { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23380,22 +28678,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List organization issues assigned to the authenticated user", - "scope": "issues", - "id": "listForOrg", + "name": "List repositories in an organization migration", + "scope": "migrations", + "id": "listReposForOrg", "method": "GET", - "url": "/orgs/{org}/issues", + "url": "/orgs/{org}/migrations/{migration_id}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List issues in an organization assigned to the authenticated user.\n\n**Note**: GitHub's REST API v3 considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-organization-issues-assigned-to-the-authenticated-user", + "description": "List all the repositories for this organization migration.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#list-repositories-in-an-organization-migration", "parameters": [ { "name": "org", @@ -23411,19 +28708,12 @@ "deprecated": null }, { - "name": "filter", - "description": "Indicates which sorts of issues to return. `assigned` means issues assigned to you. `created` means issues created by you. `mentioned` means issues mentioning you. `subscribed` means issues you're subscribed to updates for. `all` or `repos` means all issues you can see, regardless of participation or creation.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": [ - "assigned", - "created", - "mentioned", - "subscribed", - "repos", - "all" - ], + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23431,12 +28721,12 @@ "deprecated": null }, { - "name": "state", - "description": "Indicates the state of the issues to return.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["open", "closed", "all"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23444,10 +28734,10 @@ "deprecated": null }, { - "name": "labels", - "description": "A list of comma separated label names. Example: `bug,ui,@high`", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -23455,14 +28745,46 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List repositories for a user migration", + "scope": "migrations", + "id": "listReposForUser", + "method": "GET", + "url": "/user/migrations/{migration_id}/repositories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all the repositories for this user migration.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#list-repositories-for-a-user-migration", + "parameters": [ + { + "name": "migration_id", + "description": "The unique identifier of the migration.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "sort", - "description": "What to sort results by.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["created", "updated", "comments"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23470,12 +28792,49 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["asc", "desc"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": { + "before": { "scope": "migrations", "id": "listReposForUser" }, + "after": { "scope": "migrations", "id": "listReposForAuthenticatedUser" }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "Map a commit author", + "scope": "migrations", + "id": "mapCommitAuthor", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/import/authors/{author_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Update an author's identity for the import. Your application can continue updating authors any time before you push\nnew commits to the repository.\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.\n", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#map-a-commit-author", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23483,11 +28842,11 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23496,10 +28855,23 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "author_id", + "description": "", + "in": "PATH", "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "email", + "description": "The new Git author email.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -23509,10 +28881,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "name", + "description": "The new Git author name.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -23524,21 +28896,29 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { + "code": 503, + "description": "Unavailable due to service under maintenance." + } ], "renamed": null }, { - "name": "List repository issues", - "scope": "issues", - "id": "listForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues", + "name": "Update Git LFS preference", + "scope": "migrations", + "id": "setLfsPreference", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/import/lfs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List issues in a repository.\n\n**Note**: GitHub's REST API v3 considers every pull request an issue, but not every issue is a pull request. For this\nreason, \"Issues\" endpoints may return both issues and pull requests in the response. You can identify pull requests by\nthe `pull_request` key. Be aware that the `id` of a pull request returned from \"Issues\" endpoints will be an _issue id_. To find out the pull\nrequest id, use the \"[List pull requests](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests)\" endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-repository-issues", + "description": "You can import repositories from Subversion, Mercurial, and TFS that include files larger than 100MB. This ability\nis powered by [Git LFS](https://git-lfs.com).\n\nYou can learn more about our LFS feature and working with large files [on our help\nsite](https://docs.github.com/enterprise-cloud@latest//repositories/working-with-files/managing-large-files).\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.\n", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#update-git-lfs-preference", "parameters": [ { "name": "owner", @@ -23555,7 +28935,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23567,36 +28947,49 @@ "deprecated": null }, { - "name": "milestone", - "description": "If an `integer` is passed, it should refer to a milestone by its `number` field. If the string `*` is passed, issues with any milestone are accepted. If the string `none` is passed, issues without milestones are returned.", - "in": "QUERY", + "name": "use_lfs", + "description": "Whether to store large files during the import. `opt_in` means large files will be stored using Git LFS. `opt_out` means large files will be removed during the import.", + "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["opt_in", "opt_out"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "state", - "description": "Indicates the state of the issues to return.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["open", "closed", "all"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." }, { - "name": "assignee", - "description": "Can be the name of a user. Pass in `none` for issues with no assigned user, and `*` for issues assigned to any user.", - "in": "QUERY", - "type": "string", + "code": 503, + "description": "Unavailable due to service under maintenance." + } + ], + "renamed": null + }, + { + "name": "Start a user migration", + "scope": "migrations", + "id": "startForAuthenticatedUser", + "method": "POST", + "url": "/user/migrations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Initiates the generation of a user migration archive.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#start-a-user-migration", + "parameters": [ + { + "name": "lock_repositories", + "description": "Lock the repositories being migrated at the start of the migration", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23606,10 +28999,10 @@ "deprecated": null }, { - "name": "creator", - "description": "The user that created the issue.", - "in": "QUERY", - "type": "string", + "name": "exclude_metadata", + "description": "Indicates whether metadata should be excluded and only git source should be included for the migration.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23619,10 +29012,10 @@ "deprecated": null }, { - "name": "mentioned", - "description": "A user that's mentioned in the issue.", - "in": "QUERY", - "type": "string", + "name": "exclude_git_data", + "description": "Indicates whether the repository git data should be excluded from the migration.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23632,10 +29025,10 @@ "deprecated": null }, { - "name": "labels", - "description": "A list of comma separated label names. Example: `bug,ui,@high`", - "in": "QUERY", - "type": "string", + "name": "exclude_attachments", + "description": "Do not include attachments in the migration", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23645,12 +29038,12 @@ "deprecated": null }, { - "name": "sort", - "description": "What to sort results by.", - "in": "QUERY", - "type": "string", + "name": "exclude_releases", + "description": "Do not include releases in the migration", + "in": "BODY", + "type": "boolean", "required": false, - "enum": ["created", "updated", "comments"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23658,12 +29051,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", - "type": "string", + "name": "exclude_owner_projects", + "description": "Indicates whether projects owned by the organization or users should be excluded.", + "in": "BODY", + "type": "boolean", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -23671,10 +29064,10 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", - "type": "string", + "name": "org_metadata_only", + "description": "Indicates whether this should only include organization metadata (repositories array should be empty and will ignore other flags).", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23684,10 +29077,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "exclude", + "description": "Exclude attributes from the API response to improve performance", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -23697,11 +29090,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repositories", + "description": "", + "in": "BODY", + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -23711,9 +29104,10 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" }, + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -23722,33 +29116,20 @@ "renamed": null }, { - "name": "List labels for issues in a milestone", - "scope": "issues", - "id": "listLabelsForMilestone", - "method": "GET", - "url": "/repos/{owner}/{repo}/milestones/{milestone_number}/labels", + "name": "Start an organization migration", + "scope": "migrations", + "id": "startForOrg", + "method": "POST", + "url": "/orgs/{org}/migrations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-issues-in-a-milestone", + "description": "Initiates the generation of a migration archive.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#start-an-organization-migration", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23760,10 +29141,10 @@ "deprecated": null }, { - "name": "milestone_number", - "description": "The number that identifies the milestone.", - "in": "PATH", - "type": "integer", + "name": "repositories", + "description": "A list of arrays indicating which repositories should be migrated.", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -23773,10 +29154,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "lock_repositories", + "description": "Indicates whether repositories should be locked (to prevent manipulation) while migrating data.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23786,10 +29167,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "exclude_metadata", + "description": "Indicates whether metadata should be excluded and only git source should be included for the migration.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23797,54 +29178,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List labels for a repository", - "scope": "issues", - "id": "listLabelsForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/labels", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-a-repository", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "exclude_git_data", + "description": "Indicates whether the repository git data should be excluded from the migration.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23854,10 +29193,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "exclude_attachments", + "description": "Indicates whether attachments should be excluded from the migration (to reduce migration archive file size).", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23865,45 +29204,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "List labels for an issue", - "scope": "issues", - "id": "listLabelsOnIssue", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-labels-for-an-issue", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "exclude_releases", + "description": "Indicates whether releases should be excluded from the migration (to reduce migration archive file size).", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -23912,11 +29219,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "exclude_owner_projects", + "description": "Indicates whether projects owned by the organization or users should be excluded. from the migration.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -23925,10 +29232,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "org_metadata_only", + "description": "Indicates whether this should only include organization metadata (repositories array should be empty and will ignore other flags).", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -23938,10 +29245,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "exclude", + "description": "Exclude related items from being returned in the response in order to improve performance of the request. The array can include any of: `\"repositories\"`.", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -23952,24 +29259,26 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, + { "code": 201, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List milestones", - "scope": "issues", - "id": "listMilestones", - "method": "GET", - "url": "/repos/{owner}/{repo}/milestones", + "name": "Start an import", + "scope": "migrations", + "id": "startImport", + "method": "PUT", + "url": "/repos/{owner}/{repo}/import", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#list-milestones", + "description": "Start a source import to a GitHub Enterprise Cloud repository using GitHub Enterprise Cloud Importer. Importing into a GitHub Enterprise Cloud repository with GitHub Actions enabled is not supported and will return a status `422 Unprocessable Entity` response.\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end on October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update these docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#start-an-import", "parameters": [ { "name": "owner", @@ -23986,7 +29295,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -23998,12 +29307,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the milestone. Either `open`, `closed`, or `all`.", - "in": "QUERY", + "name": "vcs_url", + "description": "The URL of the originating repository.", + "in": "BODY", "type": "string", - "required": false, - "enum": ["open", "closed", "all"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -24011,12 +29320,12 @@ "deprecated": null }, { - "name": "sort", - "description": "What to sort results by. Either `due_on` or `completeness`.", - "in": "QUERY", + "name": "vcs", + "description": "The originating VCS type. Without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response.", + "in": "BODY", "type": "string", "required": false, - "enum": ["due_on", "completeness"], + "enum": ["subversion", "git", "mercurial", "tfvc"], "allowNull": false, "mapToData": null, "validation": null, @@ -24024,12 +29333,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction of the sort. Either `asc` or `desc`.", - "in": "QUERY", + "name": "vcs_username", + "description": "If authentication is required, the username to provide to `vcs_url`.", + "in": "BODY", "type": "string", "required": false, - "enum": ["asc", "desc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -24037,10 +29346,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "vcs_password", + "description": "If authentication is required, the password to provide to `vcs_url`.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -24050,10 +29359,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "tfvc_project", + "description": "For a tfvc import, the name of the project that is being imported.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -24064,28 +29373,36 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { + "code": 503, + "description": "Unavailable due to service under maintenance." + } ], "renamed": null }, { - "name": "Lock an issue", - "scope": "issues", - "id": "lock", - "method": "PUT", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/lock", + "name": "Unlock a user repository", + "scope": "migrations", + "id": "unlockRepoForAuthenticatedUser", + "method": "DELETE", + "url": "/user/migrations/{migration_id}/repos/{repo_name}/lock", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with push access can lock an issue or pull request's conversation.\n\nNote that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#lock-an-issue", + "description": "Unlocks a repository. You can lock repositories when you [start a user migration](https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#start-a-user-migration). Once the migration is complete you can unlock each repository to begin using it again or [delete the repository](https://docs.github.com/enterprise-cloud@latest//rest/repos/repos#delete-a-repository) if you no longer need the source data. Returns a status of `404 Not Found` if the repository is not locked.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/users#unlock-a-user-repository", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "migration_id", + "description": "The unique identifier of the migration.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -24095,8 +29412,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "repo_name", + "description": "repo_name parameter", "in": "PATH", "type": "string", "required": true, @@ -24106,61 +29423,32 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "lock_reason", - "description": "The reason for locking the issue or pull request conversation. Lock will fail if you don't use one of these reasons: \n\\* `off-topic` \n\\* `too heated` \n\\* `resolved` \n\\* `spam`", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["off-topic", "too heated", "resolved", "spam"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Remove all labels from an issue", - "scope": "issues", - "id": "removeAllLabels", + "name": "Unlock an organization repository", + "scope": "migrations", + "id": "unlockRepoForOrg", "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", + "url": "/orgs/{org}/migrations/{migration_id}/repos/{repo_name}/lock", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#remove-all-labels-from-an-issue", + "description": "Unlocks a repository that was locked for migration. You should unlock each migrated repository and [delete them](https://docs.github.com/enterprise-cloud@latest//rest/repos/repos#delete-a-repository) when the migration is complete and you no longer need the source data.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/orgs#unlock-an-organization-repository", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24172,10 +29460,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "migration_id", + "description": "The unique identifier of the migration.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -24185,10 +29473,10 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", + "name": "repo_name", + "description": "repo_name parameter", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -24200,23 +29488,21 @@ ], "responses": [ { "code": 204, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Remove assignees from an issue", - "scope": "issues", - "id": "removeAssignees", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/assignees", + "name": "Update an import", + "scope": "migrations", + "id": "updateImport", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/import", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes one or more assignees from an issue.", - "documentationUrl": "https://docs.github.com/rest/reference/issues#remove-assignees-from-an-issue", + "description": "An import can be updated with credentials or a project choice by passing in the appropriate parameters in this API\nrequest. If no parameters are provided, the import will be restarted.\n\nSome servers (e.g. TFS servers) can have several projects at a single URL. In those cases the import progress will\nhave the status `detection_found_multiple` and the Import Progress response will include a `project_choices` array.\nYou can select the project to import by providing one of the objects in the `project_choices` array in the update request.\n\n**Warning:** Support for importing Mercurial, Subversion and Team Foundation Version Control repositories will end\non October 17, 2023. For more details, see [changelog](https://gh.io/github-importer-non-git-eol). In the coming weeks, we will update\nthese docs to reflect relevant changes to the API and will contact all integrators using the \"Source imports\" API.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/migrations/source-imports#update-an-import", "parameters": [ { "name": "owner", @@ -24233,7 +29519,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24245,11 +29531,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "vcs_username", + "description": "The username to provide to the originating repository.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -24258,41 +29544,25 @@ "deprecated": null }, { - "name": "assignees", - "description": "Usernames of assignees to remove from an issue. _NOTE: Only users with push access can remove assignees from an issue. Assignees are silently ignored otherwise._", + "name": "vcs_password", + "description": "The password to provide to the originating repository.", "in": "BODY", - "type": "string[]", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Remove a label from an issue", - "scope": "issues", - "id": "removeLabel", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels/{name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes the specified label from the issue, and returns the remaining labels on the issue. This endpoint returns a `404 Not Found` status if the label does not exist.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#remove-a-label-from-an-issue", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "vcs", + "description": "The type of version control system you are migrating from.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["subversion", "tfvc", "git", "mercurial"], "allowNull": false, "mapToData": null, "validation": null, @@ -24300,23 +29570,45 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "tfvc_project", + "description": "For a tfvc import, the name of the project that is being imported.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "issue_number", - "description": "The number that identifies the issue.", + "code": 503, + "description": "Unavailable due to service under maintenance." + } + ], + "renamed": null + }, + { + "name": "Add a security manager team", + "scope": "orgs", + "id": "addSecurityManagerTeam", + "method": "PUT", + "url": "/orgs/{org}/security-managers/teams/{team_slug}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a team as a security manager for an organization. For more information, see \"[Managing security for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) for an organization.\"\n\nTo use this endpoint, you must be an administrator for the organization, and you must use an access token with the `write:org` scope.\n\nGitHub Apps must have the `administration` organization read-write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#add-a-security-manager-team", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -24326,8 +29618,8 @@ "deprecated": null }, { - "name": "name", - "description": "", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -24340,28 +29632,29 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 204, "description": "Response" }, + { + "code": 409, + "description": "The organization has reached the maximum number of security manager teams." + } ], "renamed": null }, { - "name": "Set labels for an issue", - "scope": "issues", - "id": "setLabels", + "name": "Block a user from an organization", + "scope": "orgs", + "id": "blockUser", "method": "PUT", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/labels", + "url": "/orgs/{org}/blocks/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removes any previous labels and sets the new labels for an issue.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#set-labels-for-an-issue", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#block-a-user-from-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24373,8 +29666,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -24384,12 +29677,34 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, { - "name": "issue_number", - "description": "The number that identifies the issue.", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Cancel an organization invitation", + "scope": "orgs", + "id": "cancelInvitation", + "method": "DELETE", + "url": "/orgs/{org}/invitations/{invitation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Cancel an organization invitation. In order to cancel an organization invitation, the authenticated user must be an organization owner.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#cancel-an-organization-invitation", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -24399,23 +29714,10 @@ "deprecated": null }, { - "name": "labels", - "description": "", - "in": "BODY", - "type": "object[]", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "labels[].name", - "description": "", - "in": "BODY", - "type": "string", + "name": "invitation_id", + "description": "The unique identifier of the invitation.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -24426,10 +29728,8 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, + { "code": 204, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -24438,20 +29738,20 @@ "renamed": null }, { - "name": "Unlock an issue", - "scope": "issues", - "id": "unlock", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/lock", + "name": "Check if a user is blocked by an organization", + "scope": "orgs", + "id": "checkBlockedUser", + "method": "GET", + "url": "/orgs/{org}/blocks/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with push access can unlock an issue's conversation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#unlock-an-issue", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-if-a-user-is-blocked-by-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24463,8 +29763,40 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "If the user is blocked" }, + { "code": 404, "description": "If the user is not blocked" } + ], + "renamed": null + }, + { + "name": "Check organization membership for a user", + "scope": "orgs", + "id": "checkMembershipForUser", + "method": "GET", + "url": "/orgs/{org}/members/{username}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Check if a user is, publicly or privately, a member of the organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-organization-membership-for-a-user", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24476,10 +29808,10 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -24490,27 +29822,36 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 204, + "description": "Response if requester is an organization member and user is a member" + }, + { + "code": 302, + "description": "Response if requester is not an organization member" + }, + { + "code": 404, + "description": "Not Found if requester is an organization member and user is not a member" + } ], "renamed": null }, { - "name": "Update an issue", - "scope": "issues", - "id": "update", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/issues/{issue_number}", + "name": "Check public organization membership for a user", + "scope": "orgs", + "id": "checkPublicMembershipForUser", + "method": "GET", + "url": "/orgs/{org}/public_members/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Issue owners and users with push access can edit an issue.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues/#update-an-issue", + "description": "Check if the provided user is a public member of the organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-public-organization-membership-for-a-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24522,8 +29863,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -24533,12 +29874,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response if user is a public member" }, + { "code": 404, "description": "Not Found if user is not a public member" } + ], + "renamed": null + }, + { + "name": "Convert an organization member to outside collaborator", + "scope": "orgs", + "id": "convertMemberToOutsideCollaborator", + "method": "PUT", + "url": "/orgs/{org}/outside_collaborators/{username}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "When an organization member is converted to an outside collaborator, they'll only have access to the repositories that their current team membership allows. The user will no longer be a member of the organization. For more information, see \"[Converting an organization member to an outside collaborator](https://docs.github.com/enterprise-cloud@latest//articles/converting-an-organization-member-to-an-outside-collaborator/)\". Converting an organization member to an outside collaborator may be restricted by enterprise administrators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/enterprise-cloud@latest//admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#convert-an-organization-member-to-outside-collaborator", + "parameters": [ { - "name": "issue_number", - "description": "The number that identifies the issue.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -24548,51 +29908,65 @@ "deprecated": null }, { - "name": "title", - "description": "The title of the issue.", - "in": "BODY", - "type": null, - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "body", - "description": "The contents of the issue.", + "name": "async", + "description": "When set to `true`, the request will be performed asynchronously. Returns a 202 status code when the job is successfully queued.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 202, + "description": "User is getting converted asynchronously" }, + { "code": 204, "description": "User was converted" }, { - "name": "assignee", - "description": "Login for the user that this issue should be assigned to. **This field is deprecated.**", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": true, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 403, + "description": "Forbidden if user is the last owner of the organization, not a member of the organization, or if the enterprise enforces a policy for inviting outside collaborators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/enterprise-cloud@latest//admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Create an organization invitation", + "scope": "orgs", + "id": "createInvitation", + "method": "POST", + "url": "/orgs/{org}/invitations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Invite people to an organization by using their GitHub user ID or their email address. In order to create invitations in an organization, the authenticated user must be an organization owner.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-an-organization-invitation", + "parameters": [ { - "name": "state", - "description": "State of the issue. Either `open` or `closed`.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -24600,38 +29974,38 @@ "deprecated": null }, { - "name": "state_reason", - "description": "The reason for the current state", + "name": "invitee_id", + "description": "**Required unless you provide `email`**. GitHub user ID for the person you are inviting.", "in": "BODY", - "type": "string", + "type": "integer", "required": false, - "enum": ["completed", "not_planned", "reopened"], - "allowNull": true, + "enum": null, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "milestone", - "description": "", + "name": "email", + "description": "**Required unless you provide `invitee_id`**. Email address of the person you are inviting, which can be an existing GitHub user.", "in": "BODY", - "type": null, + "type": "string", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "labels", - "description": "Labels to associate with this issue. Pass one or more Labels to _replace_ the set of Labels on this Issue. Send an empty array (`[]`) to clear all Labels from the Issue. _NOTE: Only users with push access can set labels for issues. Labels are silently dropped otherwise._", + "name": "role", + "description": "The role for the new member. \n * `admin` - Organization owners with full administrative rights to the organization and complete access to all repositories and teams. \n * `direct_member` - Non-owner organization members with ability to see other members and join teams by invitation. \n * `billing_manager` - Non-owner organization members with ability to manage the billing settings of your organization.", "in": "BODY", - "type": "undefined[]", + "type": "string", "required": false, - "enum": null, + "enum": ["admin", "direct_member", "billing_manager"], "allowNull": false, "mapToData": null, "validation": null, @@ -24639,10 +30013,10 @@ "deprecated": null }, { - "name": "assignees", - "description": "Logins for Users to assign to this issue. Pass one or more user logins to _replace_ the set of assignees on this Issue. Send an empty array (`[]`) to clear all assignees from the Issue. _NOTE: Only users with push access can set assignees for new issues. Assignees are silently dropped otherwise._", + "name": "team_ids", + "description": "Specify IDs for the teams you want to invite new members to.", "in": "BODY", - "type": "string[]", + "type": "integer[]", "required": false, "enum": null, "allowNull": false, @@ -24653,34 +30027,30 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 403, "description": "Forbidden" }, + { "code": 201, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 503, "description": "Service unavailable" } + } ], "renamed": null }, { - "name": "Update an issue comment", - "scope": "issues", - "id": "updateComment", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}", + "name": "Create an organization webhook", + "scope": "orgs", + "id": "createWebhook", + "method": "POST", + "url": "/orgs/{org}/hooks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-an-issue-comment", + "description": "Here's how you can create a hook that posts payloads in JSON format:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-an-organization-webhook", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24692,9 +30062,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "Must be passed as \"web\".", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -24705,10 +30075,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", - "type": "integer", + "name": "config", + "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-hook-config-params).", + "in": "BODY", + "type": "object", "required": true, "enum": null, "allowNull": false, @@ -24718,8 +30088,8 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the comment.", + "name": "config.url", + "description": "The URL to which the payloads will be delivered.", "in": "BODY", "type": "string", "required": true, @@ -24729,35 +30099,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Update a label", - "scope": "issues", - "id": "updateLabel", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/labels/{name}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-a-label", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "config.content_type", + "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -24766,11 +30114,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "config.secret", + "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -24779,11 +30127,11 @@ "deprecated": null }, { - "name": "name", + "name": "config.insecure_ssl", "description": "", - "in": "PATH", - "type": "string", - "required": true, + "in": "BODY", + "type": null, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -24792,8 +30140,8 @@ "deprecated": null }, { - "name": "new_name", - "description": "The new name of the label. Emoji can be added to label names, using either native emoji or colon-style markup. For example, typing `:strawberry:` will render the emoji ![:strawberry:](https://github.githubassets.com/images/icons/emoji/unicode/1f353.png \":strawberry:\"). For a full list of available emoji and codes, see \"[Emoji cheat sheet](https://github.com/ikatyang/emoji-cheat-sheet).\"", + "name": "config.username", + "description": "", "in": "BODY", "type": "string", "required": false, @@ -24805,8 +30153,8 @@ "deprecated": null }, { - "name": "color", - "description": "The [hexadecimal color code](http://www.color-hex.com/) for the label, without the leading `#`.", + "name": "config.password", + "description": "", "in": "BODY", "type": "string", "required": false, @@ -24818,10 +30166,23 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the label. Must be 100 characters or fewer.", + "name": "events", + "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for. Set to `[\"*\"]` to receive all possible events.", "in": "BODY", - "type": "string", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "active", + "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -24831,24 +30192,31 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Update a milestone", - "scope": "issues", - "id": "updateMilestone", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/milestones/{milestone_number}", + "name": "Delete an organization", + "scope": "orgs", + "id": "delete", + "method": "DELETE", + "url": "/orgs/{org}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#update-a-milestone", + "description": "Deletes an organization and all its repositories.\n\nThe organization login will be unavailable for 90 days after deletion.\n\nPlease review the Terms of Service regarding account deletion before using this endpoint:\n\nhttps://docs.github.com/enterprise-cloud@latest//site-policy/github-terms/github-terms-of-service", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs/#delete-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24858,10 +30226,30 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete an organization webhook", + "scope": "orgs", + "id": "deleteWebhook", + "method": "DELETE", + "url": "/orgs/{org}/hooks/{hook_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#delete-an-organization-webhook", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24873,8 +30261,8 @@ "deprecated": null }, { - "name": "milestone_number", - "description": "The number that identifies the milestone.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", "type": "integer", "required": true, @@ -24884,13 +30272,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Enable or disable a security feature for an organization", + "scope": "orgs", + "id": "enableOrDisableSecurityProductOnAllOrgRepos", + "method": "POST", + "url": "/orgs/{org}/{security_product}/{enablement}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables or disables the specified security feature for all eligible repositories in an organization.\n\nTo use this endpoint, you must be an organization owner or be member of a team with the security manager role.\nA token with the 'write:org' scope is also required.\n\nGitHub Apps must have the `organization_administration:write` permission to use this endpoint.\n\nFor more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#enable-or-disable-security-product-on-all-org-repos", + "parameters": [ { - "name": "title", - "description": "The title of the milestone.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -24899,12 +30306,20 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the milestone. Either `open` or `closed`.", - "in": "BODY", + "name": "security_product", + "description": "The security feature to enable or disable.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed"], + "required": true, + "enum": [ + "dependency_graph", + "dependabot_alerts", + "dependabot_security_updates", + "advanced_security", + "code_scanning_default_setup", + "secret_scanning", + "secret_scanning_push_protection" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -24912,24 +30327,46 @@ "deprecated": null }, { - "name": "description", - "description": "A description of the milestone.", - "in": "BODY", + "name": "enablement", + "description": "The action to take.\n\n`enable_all` means to enable the specified security feature for all repositories in the organization.\n`disable_all` means to disable the specified security feature for all repositories in the organization.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["enable_all", "disable_all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Action started" }, { - "name": "due_on", - "description": "The milestone due date. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "BODY", + "code": 422, + "description": "The action could not be taken due to an in progress enablement, or a policy is preventing enablement" + } + ], + "renamed": null + }, + { + "name": "Get an organization", + "scope": "orgs", + "id": "get", + "method": "GET", + "url": "/orgs/{org}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "To see many of the organization response values, you need to be an authenticated organization owner with the `admin:org` scope. When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, and outside collaborators to enable [two-factor authentication](https://docs.github.com/enterprise-cloud@latest//articles/securing-your-account-with-two-factor-authentication-2fa/).\n\nGitHub Apps with the `Organization plan` permission can use this endpoint to retrieve information about an organization's GitHub Enterprise Cloud plan. See \"[Authenticating with GitHub Apps](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/)\" for details. For an example response, see 'Response with GitHub Enterprise Cloud plan information' below.\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -24938,24 +30375,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a license", - "scope": "licenses", - "id": "get", + "name": "Get an organization membership for the authenticated user", + "scope": "orgs", + "id": "getMembershipForAuthenticatedUser", "method": "GET", - "url": "/licenses/{license}", + "url": "/user/memberships/orgs/{org}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses#get-a-license", + "description": "If the authenticated user is an active or pending member of the organization, this endpoint will return the user's membership. If the authenticated user is not affiliated with the organization, a `404` is returned. This endpoint will return a `403` if the request is made by a GitHub App that is blocked by the organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization-membership-for-the-authenticated-user", "parameters": [ { - "name": "license", - "description": "", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -24969,30 +30409,29 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get all commonly used licenses", - "scope": "licenses", - "id": "getAllCommonlyUsed", + "name": "Get organization membership for a user", + "scope": "orgs", + "id": "getMembershipForUser", "method": "GET", - "url": "/licenses", + "url": "/orgs/{org}/memberships/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses#get-all-commonly-used-licenses", + "description": "In order to get a user's membership with an organization, the authenticated user must be an organization member. The `state` parameter in the response can be used to identify the user's membership status.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-organization-membership-for-a-user", "parameters": [ { - "name": "featured", - "description": "", - "in": "QUERY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -25001,11 +30440,44 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get an organization webhook", + "scope": "orgs", + "id": "getWebhook", + "method": "GET", + "url": "/orgs/{org}/hooks/{hook_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns a webhook configured in an organization. To get only the webhook `config` properties, see \"[Get a webhook configuration for an organization](/rest/reference/orgs#get-a-webhook-configuration-for-an-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization-webhook", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -25014,11 +30486,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -25029,25 +30501,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get the license for a repository", - "scope": "licenses", - "id": "getForRepo", + "name": "Get a webhook configuration for an organization", + "scope": "orgs", + "id": "getWebhookConfigForOrg", "method": "GET", - "url": "/repos/{owner}/{repo}/license", + "url": "/orgs/{org}/hooks/{hook_id}/config", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This method returns the contents of the repository's license file, if one is detected.\n\nSimilar to [Get repository content](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-repository-content), this method also supports [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types) for retrieving the raw license content or rendered license HTML.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/licenses/#get-the-license-for-a-repository", + "description": "Returns the webhook configuration for an organization. To get more information about the webhook, including the `active` state and `events`, use \"[Get an organization webhook ](/rest/reference/orgs#get-an-organization-webhook).\"\n\nAccess tokens must have the `admin:org_hook` scope, and GitHub Apps must have the `organization_hooks:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-configuration-for-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -25059,10 +30531,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -25076,21 +30548,21 @@ "renamed": null }, { - "name": "Render a Markdown document", - "scope": "markdown", - "id": "render", - "method": "POST", - "url": "/markdown", + "name": "Get a webhook delivery for an organization webhook", + "scope": "orgs", + "id": "getWebhookDelivery", + "method": "GET", + "url": "/orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/markdown#render-a-markdown-document", + "description": "Returns a delivery for a webhook configured in an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-delivery-for-an-organization-webhook", "parameters": [ { - "name": "text", - "description": "The Markdown text to render in HTML.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -25101,12 +30573,12 @@ "deprecated": null }, { - "name": "mode", - "description": "The rendering mode.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["markdown", "gfm"], + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -25114,11 +30586,11 @@ "deprecated": null }, { - "name": "context", - "description": "The repository context to use when creating references in `gfm` mode. For example, setting `context` to `octo-org/octo-repo` will change the text `#42` into an HTML link to issue 42 in the `octo-org/octo-repo` repository.", - "in": "BODY", - "type": "string", - "required": false, + "name": "delivery_id", + "description": "", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -25129,77 +30601,45 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Render a Markdown document in raw mode", - "scope": "markdown", - "id": "renderRaw", - "method": "POST", - "url": "/markdown/raw", + "name": "List organizations", + "scope": "orgs", + "id": "list", + "method": "GET", + "url": "/organizations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must send Markdown as plain text (using a `Content-Type` header of `text/plain` or `text/x-markdown`) to this endpoint, rather than using JSON format. In raw mode, [GitHub Flavored Markdown](https://github.github.com/gfm/) is not supported and Markdown will be rendered in plain format like a README.md file. Markdown content must be 400 KB or less.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/markdown#render-a-markdown-document-in-raw-mode", + "description": "Lists all organizations, in the order that they were created on GitHub Enterprise Cloud.\n\n**Note:** Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers) to get the URL for the next page of organizations.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations", "parameters": [ { - "name": "data", - "description": "raw markdown text", - "in": "BODY", - "type": "string", - "required": true, + "name": "since", + "description": "An organization ID. Only return organizations with an ID greater than this ID.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "Get GitHub Enterprise Cloud meta information", - "scope": "meta", - "id": "get", - "method": "GET", - "url": "/meta", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns meta information about GitHub, including a list of GitHub's IP addresses. For more information, see \"[About GitHub's IP addresses](https://docs.github.com/articles/about-github-s-ip-addresses/).\"\n\n**Note:** The IP addresses shown in the documentation's response are only example values. You must always query the API directly to get the latest list of IP addresses.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/meta#get-github-meta-information", - "parameters": [], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "Get Octocat", - "scope": "meta", - "id": "getOctocat", - "method": "GET", - "url": "/octocat", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Get the octocat as ASCII art", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/meta#get-octocat", - "parameters": [ + }, { - "name": "s", - "description": "The words to show in Octocat's speech bubble", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -25209,54 +30649,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get the Zen of GitHub", - "scope": "meta", - "id": "getZen", - "method": "GET", - "url": "/zen", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Get a random sentence from the Zen of GitHub", - "documentationUrl": "", - "parameters": [], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], "renamed": null }, { - "name": "GitHub API Root", - "scope": "meta", - "id": "root", + "name": "List app installations for an organization", + "scope": "orgs", + "id": "listAppInstallations", "method": "GET", - "url": "/", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Get Hypermedia links to resources accessible in GitHub's REST API", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#root-endpoint", - "parameters": [], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Cancel an import", - "scope": "migrations", - "id": "cancelImport", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/import", + "url": "/orgs/{org}/installations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Stop an import for a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#cancel-an-import", + "description": "Lists all GitHub Apps in an organization. The installation count includes all GitHub Apps installed on repositories in the organization. You must be an organization owner with `admin:read` scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-app-installations-for-an-organization", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -25268,40 +30681,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete a user migration archive", - "scope": "migrations", - "id": "deleteArchiveForAuthenticatedUser", - "method": "DELETE", - "url": "/user/migrations/{migration_id}/archive", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Deletes a previous migration archive. Downloadable migration archives are automatically deleted after seven days. Migration metadata, which is returned in the [List user migrations](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-user-migrations) and [Get a user migration status](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-a-user-migration-status) endpoints, will continue to be available even after an archive is deleted.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#delete-a-user-migration-archive", - "parameters": [ + }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25310,26 +30707,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Delete an organization migration archive", - "scope": "migrations", - "id": "deleteArchiveForOrg", - "method": "DELETE", - "url": "/orgs/{org}/migrations/{migration_id}/archive", + "name": "List users blocked by an organization", + "scope": "orgs", + "id": "listBlockedUsers", + "method": "GET", + "url": "/orgs/{org}/blocks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a previous migration archive. Migration archives are automatically deleted after seven days.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#delete-an-organization-migration-archive", + "description": "List the users blocked by an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-users-blocked-by-an-organization", "parameters": [ { "name": "org", @@ -25345,11 +30736,24 @@ "deprecated": null }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25358,23 +30762,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Download an organization migration archive", - "scope": "migrations", - "id": "downloadArchiveForOrg", + "name": "List failed organization invitations", + "scope": "orgs", + "id": "listFailedInvitations", "method": "GET", - "url": "/orgs/{org}/migrations/{migration_id}/archive", + "url": "/orgs/{org}/failed_invitations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Fetches the URL to a migration archive.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#download-an-organization-migration-archive", + "description": "The return hash contains `failed_at` and `failed_reason` fields which represent the time at which the invitation failed and the reason for the failure.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-failed-organization-invitations", "parameters": [ { "name": "org", @@ -25390,43 +30791,24 @@ "deprecated": null }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 302, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Download a user migration archive", - "scope": "migrations", - "id": "getArchiveForAuthenticatedUser", - "method": "GET", - "url": "/user/migrations/{migration_id}/archive", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Fetches the URL to download the migration archive as a `tar.gz` file. Depending on the resources your repository uses, the migration archive can contain JSON files with data for these objects:\n\n* attachments\n* bases\n* commit\\_comments\n* issue\\_comments\n* issue\\_events\n* issues\n* milestones\n* organizations\n* projects\n* protected\\_branches\n* pull\\_request\\_reviews\n* pull\\_requests\n* releases\n* repositories\n* review\\_comments\n* schema\n* users\n\nThe archive will also contain an `attachments` directory that includes all attachment files uploaded to GitHub.com and a `repositories` directory that contains the repository's Git data.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#download-a-user-migration-archive", - "parameters": [ + }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25436,44 +30818,29 @@ } ], "responses": [ - { "code": 302, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get commit authors", - "scope": "migrations", - "id": "getCommitAuthors", + "name": "List organizations for the authenticated user", + "scope": "orgs", + "id": "listForAuthenticatedUser", "method": "GET", - "url": "/repos/{owner}/{repo}/import/authors", + "url": "/user/orgs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Each type of source control system represents authors in a different way. For example, a Git commit author has a display name and an email address, but a Subversion commit author just has a username. The GitHub Enterprise Cloud Importer will make the author information valid, but the author might not be correct. For example, it will change the bare Subversion username `hubot` into something like `hubot `.\n\nThis endpoint and the [Map a commit author](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#map-a-commit-author) endpoint allow you to provide correct Git author information.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-commit-authors", + "description": "List organizations for the authenticated user.\n\n**OAuth scope requirements**\n\nThis only lists organizations that your authorization allows you to operate on in some way (e.g., you can list teams with `read:org` scope, you can publicize your organization membership with `user` scope, etc.). Therefore, this API requires at least `user` or `read:org` scope. OAuth requests with insufficient scope receive a `403 Forbidden` response.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25482,8 +30849,8 @@ "deprecated": null }, { - "name": "since", - "description": "A user ID. Only return users with an ID greater than this ID.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -25497,25 +30864,27 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "Get an import status", - "scope": "migrations", - "id": "getImportStatus", + "name": "List organizations for a user", + "scope": "orgs", + "id": "listForUser", "method": "GET", - "url": "/repos/{owner}/{repo}/import", + "url": "/users/{username}/orgs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "View the progress of an import.\n\n**Import status**\n\nThis section includes details about the possible values of the `status` field of the Import Progress response.\n\nAn import that does not have errors will progress through these steps:\n\n* `detecting` - the \"detection\" step of the import is in progress because the request did not include a `vcs` parameter. The import is identifying the type of source control present at the URL.\n* `importing` - the \"raw\" step of the import is in progress. This is where commit data is fetched from the original repository. The import progress response will include `commit_count` (the total number of raw commits that will be imported) and `percent` (0 - 100, the current progress through the import).\n* `mapping` - the \"rewrite\" step of the import is in progress. This is where SVN branches are converted to Git branches, and where author updates are applied. The import progress response does not include progress information.\n* `pushing` - the \"push\" step of the import is in progress. This is where the importer updates the repository on GitHub Enterprise Cloud. The import progress response will include `push_percent`, which is the percent value reported by `git push` when it is \"Writing objects\".\n* `complete` - the import is complete, and the repository is ready on GitHub Enterprise Cloud.\n\nIf there are problems, you will see one of these in the `status` field:\n\n* `auth_failed` - the import requires authentication in order to connect to the original repository. To update authentication for the import, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#update-an-import) section.\n* `error` - the import encountered an error. The import progress response will include the `failed_step` and an error message. Contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api) for more information.\n* `detection_needs_auth` - the importer requires authentication for the originating repository to continue detection. To update authentication for the import, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#update-an-import) section.\n* `detection_found_nothing` - the importer didn't recognize any source control at the URL. To resolve, [Cancel the import](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#cancel-an-import) and [retry](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#start-an-import) with the correct URL.\n* `detection_found_multiple` - the importer found several projects or repositories at the provided URL. When this is the case, the Import Progress response will also include a `project_choices` field with the possible project choices as values. To update project choice, please see the [Update an import](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#update-an-import) section.\n\n**The project_choices field**\n\nWhen multiple projects are found at the provided URL, the response hash will include a `project_choices` field, the value of which is an array of hashes each representing a project choice. The exact key/value pairs of the project hashes will differ depending on the version control type.\n\n**Git LFS related fields**\n\nThis section includes details about Git LFS related fields that may be present in the Import Progress response.\n\n* `use_lfs` - describes whether the import has been opted in or out of using Git LFS. The value can be `opt_in`, `opt_out`, or `undecided` if no action has been taken.\n* `has_large_files` - the boolean value describing whether files larger than 100MB were found during the `importing` step.\n* `large_files_size` - the total size in gigabytes of files larger than 100MB found in the originating repository.\n* `large_files_count` - the total number of files larger than 100MB found in the originating repository. To see a list of these files, make a \"Get Large Files\" request.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-an-import-status", + "description": "List [public organization memberships](https://docs.github.com/enterprise-cloud@latest//articles/publicizing-or-concealing-organization-membership) for the specified user.\n\nThis method only lists _public_ memberships, regardless of authentication. If you need to fetch all of the organization memberships (public and private) for the authenticated user, use the [List organizations for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-the-authenticated-user) API instead.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-a-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -25527,11 +30896,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25540,27 +30922,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get large files", - "scope": "migrations", - "id": "getLargeFiles", + "name": "List organization invitation teams", + "scope": "orgs", + "id": "listInvitationTeams", "method": "GET", - "url": "/repos/{owner}/{repo}/import/large_files", + "url": "/orgs/{org}/invitations/{invitation_id}/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List files larger than 100MB found during the import", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-large-files", + "description": "List all teams associated with an invitation. In order to see invitations in an organization, the authenticated user must be an organization owner.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-invitation-teams", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -25572,10 +30951,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "invitation_id", + "description": "The unique identifier of the invitation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -25583,29 +30962,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a user migration status", - "scope": "migrations", - "id": "getStatusForAuthenticatedUser", - "method": "GET", - "url": "/user/migrations/{migration_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Fetches a single user migration. The response includes the `state` of the migration, which can be one of the following values:\n\n* `pending` - the migration hasn't started yet.\n* `exporting` - the migration is in progress.\n* `exported` - the migration finished successfully.\n* `failed` - the migration failed.\n\nOnce the migration has been `exported` you can [download the migration archive](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#download-a-user-migration-archive).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-a-user-migration-status", - "parameters": [ + }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25614,10 +30977,10 @@ "deprecated": null }, { - "name": "exclude", - "description": "", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "array", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -25629,24 +30992,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get an organization migration status", - "scope": "migrations", - "id": "getStatusForOrg", + "name": "List organization members", + "scope": "orgs", + "id": "listMembers", "method": "GET", - "url": "/orgs/{org}/migrations/{migration_id}", + "url": "/orgs/{org}/members", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Fetches the status of a migration.\n\nThe `state` of a migration can be one of the following values:\n\n* `pending`, which means the migration hasn't started yet.\n* `exporting`, which means the migration is in progress.\n* `exported`, which means the migration finished successfully.\n* `failed`, which means the migration failed.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#get-an-organization-migration-status", + "description": "List all users who are members of an organization. If the authenticated user is also a member of this organization then both concealed and public members will be returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-members", "parameters": [ { "name": "org", @@ -25662,11 +31022,37 @@ "deprecated": null }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", - "in": "PATH", + "name": "filter", + "description": "Filter members returned in the list. `2fa_disabled` means that only members without [two-factor authentication](https://github.com/blog/1614-two-factor-authentication) enabled will be returned. This options is only available for organization owners.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["2fa_disabled", "all"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "role", + "description": "Filter members returned by their role.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["all", "admin", "member"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -25675,10 +31061,10 @@ "deprecated": null }, { - "name": "exclude", - "description": "Exclude attributes from the API response to improve performance", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "array", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -25689,26 +31075,39 @@ } ], "responses": [ + { "code": 200, "description": "Response" }, { - "code": 200, - "description": "* `pending`, which means the migration hasn't started yet.\n* `exporting`, which means the migration is in progress.\n* `exported`, which means the migration finished successfully.\n* `failed`, which means the migration failed." - }, - { "code": 404, "description": "Resource not found" } + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List user migrations", - "scope": "migrations", - "id": "listForAuthenticatedUser", + "name": "List organization memberships for the authenticated user", + "scope": "orgs", + "id": "listMembershipsForAuthenticatedUser", "method": "GET", - "url": "/user/migrations", + "url": "/user/memberships/orgs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all migrations a user has started.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-user-migrations", + "description": "Lists all of the authenticated user's organization memberships.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-memberships-for-the-authenticated-user", "parameters": [ + { + "name": "state", + "description": "Indicates the state of the memberships to return. If not specified, the API returns both active and pending memberships.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["active", "pending"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -25740,21 +31139,25 @@ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List organization migrations", - "scope": "migrations", - "id": "listForOrg", + "name": "List outside collaborators for an organization", + "scope": "orgs", + "id": "listOutsideCollaborators", "method": "GET", - "url": "/orgs/{org}/migrations", + "url": "/orgs/{org}/outside_collaborators", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the most recent migrations.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-organization-migrations", + "description": "List all users who are outside collaborators of an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-outside-collaborators-for-an-organization", "parameters": [ { "name": "org", @@ -25770,12 +31173,12 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "filter", + "description": "Filter the list of outside collaborators. `2fa_disabled` means that only outside collaborators without [two-factor authentication](https://github.com/blog/1614-two-factor-authentication) enabled will be returned.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["2fa_disabled", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -25783,8 +31186,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -25796,10 +31199,10 @@ "deprecated": null }, { - "name": "exclude", - "description": "Exclude attributes from the API response to improve performance", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "array", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -25813,20 +31216,33 @@ "renamed": null }, { - "name": "List repositories for a user migration", - "scope": "migrations", - "id": "listReposForAuthenticatedUser", + "name": "List repositories a fine-grained personal access token has access to", + "scope": "orgs", + "id": "listPatGrantRepositories", "method": "GET", - "url": "/user/migrations/{migration_id}/repositories", + "url": "/organizations/{org}/personal-access-tokens/{pat_id}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all the repositories for this user migration.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-repositories-for-a-user-migration", + "description": "Lists the repositories a fine-grained personal access token has access to. Only GitHub Apps can call this API,\nusing the `organization_personal_access_tokens: read` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#list-repositories-a-fine-grained-personal-access-token-has-access-to", "parameters": [ { - "name": "migration_id", - "description": "The unique identifier of the migration.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "pat_id", + "description": "Unique identifier of the fine-grained personal access token.", "in": "PATH", "type": "integer", "required": true, @@ -25866,21 +31282,23 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "List repositories in an organization migration", - "scope": "migrations", - "id": "listReposForOrg", + "name": "List repositories requested to be accessed by a fine-grained personal access token", + "scope": "orgs", + "id": "listPatGrantRequestRepositories", "method": "GET", - "url": "/orgs/{org}/migrations/{migration_id}/repositories", + "url": "/organizations/{org}/personal-access-token-requests/{pat_request_id}/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all the repositories for this organization migration.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-repositories-in-an-organization-migration", + "description": "Lists the repositories a fine-grained personal access token request is requesting access to. Only GitHub Apps can call this API,\nusing the `organization_personal_access_token_requests: read` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#list-repositories-requested-to-be-accessed-by-a-fine-grained-personal-access-token", "parameters": [ { "name": "org", @@ -25896,8 +31314,8 @@ "deprecated": null }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", + "name": "pat_request_id", + "description": "Unique identifier of the request for access via fine-grained personal access token.", "in": "PATH", "type": "integer", "required": true, @@ -25937,27 +31355,29 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "List repositories for a user migration", - "scope": "migrations", - "id": "listReposForUser", + "name": "List requests to access organization resources with fine-grained personal access tokens", + "scope": "orgs", + "id": "listPatGrantRequests", "method": "GET", - "url": "/user/migrations/{migration_id}/repositories", + "url": "/organizations/{org}/personal-access-token-requests", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all the repositories for this user migration.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#list-repositories-for-a-user-migration", + "description": "Lists requests from organization members to access organization resources with a fine-grained personal access token. Only GitHub Apps can call this API,\nusing the `organization_personal_access_token_requests: read` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#list-requests-to-access-organization-resources-with-fine-grained-personal-access-tokens", "parameters": [ { - "name": "migration_id", - "description": "The unique identifier of the migration.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -25991,38 +31411,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": { - "before": { "scope": "migrations", "id": "listReposForUser" }, - "after": { "scope": "migrations", "id": "listReposForAuthenticatedUser" }, - "date": "2021-10-05", - "note": null - } - }, - { - "name": "Map a commit author", - "scope": "migrations", - "id": "mapCommitAuthor", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/import/authors/{author_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Update an author's identity for the import. Your application can continue updating authors any time before you push new commits to the repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#map-a-commit-author", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "sort", + "description": "The property by which to sort the results.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["created_at"], "allowNull": false, "mapToData": null, "validation": null, @@ -26030,12 +31426,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -26043,11 +31439,11 @@ "deprecated": null }, { - "name": "author_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "name": "owner", + "description": "A list of owner usernames to use to filter the results.", + "in": "QUERY", + "type": "array", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -26056,9 +31452,9 @@ "deprecated": null }, { - "name": "email", - "description": "The new Git author email.", - "in": "BODY", + "name": "repository", + "description": "The name of the repository to use to filter the results.", + "in": "QUERY", "type": "string", "required": false, "enum": null, @@ -26069,9 +31465,9 @@ "deprecated": null }, { - "name": "name", - "description": "The new Git author name.", - "in": "BODY", + "name": "permission", + "description": "The permission to use to filter the results.", + "in": "QUERY", "type": "string", "required": false, "enum": null, @@ -26080,49 +31476,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Update Git LFS preference", - "scope": "migrations", - "id": "setLfsPreference", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/import/lfs", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "You can import repositories from Subversion, Mercurial, and TFS that include files larger than 100MB. This ability is powered by [Git LFS](https://git-lfs.github.com). You can learn more about our LFS feature and working with large files [on our help site](https://docs.github.com/articles/versioning-large-files/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#update-git-lfs-preference", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "last_used_before", + "description": "Only show fine-grained personal access tokens used before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -26131,12 +31491,12 @@ "deprecated": null }, { - "name": "use_lfs", - "description": "Whether to store large files during the import. `opt_in` means large files will be stored using Git LFS. `opt_out` means large files will be removed during the import.", - "in": "BODY", + "name": "last_used_after", + "description": "Only show fine-grained personal access tokens used after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, - "enum": ["opt_in", "opt_out"], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -26146,31 +31506,34 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Start a user migration", - "scope": "migrations", - "id": "startForAuthenticatedUser", - "method": "POST", - "url": "/user/migrations", + "name": "List fine-grained personal access tokens with access to organization resources", + "scope": "orgs", + "id": "listPatGrants", + "method": "GET", + "url": "/organizations/{org}/personal-access-tokens", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Initiates the generation of a user migration archive.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#start-a-user-migration", + "description": "Lists approved fine-grained personal access tokens owned by organization members that can access organization resources. Only GitHub Apps can call this API,\nusing the `organization_personal_access_tokens: read` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#list-fine-grained-personal-access-tokens-with-access-to-organization-resources", "parameters": [ { - "name": "lock_repositories", - "description": "Lock the repositories being migrated at the start of the migration", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -26179,10 +31542,10 @@ "deprecated": null }, { - "name": "exclude_metadata", - "description": "Indicates whether metadata should be excluded and only git source should be included for the migration.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26192,10 +31555,10 @@ "deprecated": null }, { - "name": "exclude_git_data", - "description": "Indicates whether the repository git data should be excluded from the migration.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26205,12 +31568,12 @@ "deprecated": null }, { - "name": "exclude_attachments", - "description": "Do not include attachments in the migration", - "in": "BODY", - "type": "boolean", + "name": "sort", + "description": "The property by which to sort the results.", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["created_at"], "allowNull": false, "mapToData": null, "validation": null, @@ -26218,10 +31581,23 @@ "deprecated": null }, { - "name": "exclude_releases", - "description": "Do not include releases in the migration", - "in": "BODY", - "type": "boolean", + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "owner", + "description": "A list of owner usernames to use to filter the results.", + "in": "QUERY", + "type": "array", "required": false, "enum": null, "allowNull": false, @@ -26231,10 +31607,10 @@ "deprecated": null }, { - "name": "exclude_owner_projects", - "description": "Indicates whether projects owned by the organization or users should be excluded.", - "in": "BODY", - "type": "boolean", + "name": "repository", + "description": "The name of the repository to use to filter the results.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -26244,10 +31620,10 @@ "deprecated": null }, { - "name": "org_metadata_only", - "description": "Indicates whether this should only include organization metadata (repositories array should be empty and will ignore other flags).", - "in": "BODY", - "type": "boolean", + "name": "permission", + "description": "The permission to use to filter the results.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -26257,10 +31633,10 @@ "deprecated": null }, { - "name": "exclude", - "description": "Exclude attributes from the API response to improve performance", - "in": "BODY", - "type": "string[]", + "name": "last_used_before", + "description": "Only show fine-grained personal access tokens used before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -26270,11 +31646,11 @@ "deprecated": null }, { - "name": "repositories", - "description": "", - "in": "BODY", - "type": "string[]", - "required": true, + "name": "last_used_after", + "description": "Only show fine-grained personal access tokens used after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -26284,28 +31660,28 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 200, "description": "Response" }, { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Start an organization migration", - "scope": "migrations", - "id": "startForOrg", - "method": "POST", - "url": "/orgs/{org}/migrations", + "name": "List pending organization invitations", + "scope": "orgs", + "id": "listPendingInvitations", + "method": "GET", + "url": "/orgs/{org}/invitations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Initiates the generation of a migration archive.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#start-an-organization-migration", + "description": "The return hash contains a `role` field which refers to the Organization Invitation role and will be one of the following values: `direct_member`, `admin`, `billing_manager`, or `hiring_manager`. If the invitee is not a GitHub Enterprise Cloud member, the `login` field in the return hash will be `null`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-pending-organization-invitations", "parameters": [ { "name": "org", @@ -26321,23 +31697,10 @@ "deprecated": null }, { - "name": "repositories", - "description": "A list of arrays indicating which repositories should be migrated.", - "in": "BODY", - "type": "string[]", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "lock_repositories", - "description": "Indicates whether repositories should be locked (to prevent manipulation) while migrating data.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26347,10 +31710,10 @@ "deprecated": null }, { - "name": "exclude_metadata", - "description": "Indicates whether metadata should be excluded and only git source should be included for the migration.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26360,12 +31723,18 @@ "deprecated": null }, { - "name": "exclude_git_data", - "description": "Indicates whether the repository git data should be excluded from the migration.", - "in": "BODY", - "type": "boolean", + "name": "role", + "description": "Filter invitations by their member role.", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": [ + "all", + "admin", + "direct_member", + "billing_manager", + "hiring_manager" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -26373,24 +31742,43 @@ "deprecated": null }, { - "name": "exclude_attachments", - "description": "Indicates whether attachments should be excluded from the migration (to reduce migration archive file size).", - "in": "BODY", - "type": "boolean", + "name": "invitation_source", + "description": "Filter invitations by their invitation source.", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["all", "member", "scim"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List public organization members", + "scope": "orgs", + "id": "listPublicMembers", + "method": "GET", + "url": "/orgs/{org}/public_members", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Members of an organization can choose to have their membership publicized or not.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-public-organization-members", + "parameters": [ { - "name": "exclude_releases", - "description": "Indicates whether releases should be excluded from the migration (to reduce migration archive file size).", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -26399,10 +31787,10 @@ "deprecated": null }, { - "name": "exclude_owner_projects", - "description": "Indicates whether projects owned by the organization or users should be excluded. from the migration.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26412,10 +31800,10 @@ "deprecated": null }, { - "name": "org_metadata_only", - "description": "Indicates whether this should only include organization metadata (repositories array should be empty and will ignore other flags).", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26423,13 +31811,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List security manager teams", + "scope": "orgs", + "id": "listSecurityManagerTeams", + "method": "GET", + "url": "/orgs/{org}/security-managers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists teams that are security managers for an organization. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nTo use this endpoint, you must be an administrator or security manager for the organization, and you must use an access token with the `read:org` scope.\n\nGitHub Apps must have the `administration` organization read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-security-manager-teams", + "parameters": [ { - "name": "exclude", - "description": "Exclude related items from being returned in the response in order to improve performance of the request. The array can include any of: `\"repositories\"`.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -26438,31 +31842,24 @@ "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Start an import", - "scope": "migrations", - "id": "startImport", - "method": "PUT", - "url": "/repos/{owner}/{repo}/import", + "name": "List deliveries for an organization webhook", + "scope": "orgs", + "id": "listWebhookDeliveries", + "method": "GET", + "url": "/orgs/{org}/hooks/{hook_id}/deliveries", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Start a source import to a GitHub Enterprise Cloud repository using GitHub Enterprise Cloud Importer.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#start-an-import", + "description": "Returns a list of webhook deliveries for a webhook configured in an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-deliveries-for-an-organization-webhook", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -26474,10 +31871,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -26487,11 +31884,11 @@ "deprecated": null }, { - "name": "vcs_url", - "description": "The URL of the originating repository.", - "in": "BODY", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -26500,12 +31897,12 @@ "deprecated": null }, { - "name": "vcs", - "description": "The originating VCS type. Without this parameter, the import job will take additional time to detect the VCS type before beginning the import. This detection step will be reflected in the response.", - "in": "BODY", + "name": "cursor", + "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["subversion", "git", "mercurial", "tfvc"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -26513,10 +31910,10 @@ "deprecated": null }, { - "name": "vcs_username", - "description": "If authentication is required, the username to provide to `vcs_url`.", - "in": "BODY", - "type": "string", + "name": "redelivery", + "description": "", + "in": "QUERY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -26524,12 +31921,49 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { - "name": "vcs_password", - "description": "If authentication is required, the password to provide to `vcs_url`.", - "in": "BODY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List organization webhooks", + "scope": "orgs", + "id": "listWebhooks", + "method": "GET", + "url": "/orgs/{org}/hooks", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-webhooks", + "parameters": [ + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26539,10 +31973,10 @@ "deprecated": null }, { - "name": "tfvc_project", - "description": "For a tfvc import, the name of the project that is being imported.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -26553,32 +31987,28 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Unlock a user repository", - "scope": "migrations", - "id": "unlockRepoForAuthenticatedUser", - "method": "DELETE", - "url": "/user/migrations/{migration_id}/repos/{repo_name}/lock", + "name": "Ping an organization webhook", + "scope": "orgs", + "id": "pingWebhook", + "method": "POST", + "url": "/orgs/{org}/hooks/{hook_id}/pings", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Unlocks a repository. You can lock repositories when you [start a user migration](https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#start-a-user-migration). Once the migration is complete you can unlock each repository to begin using it again or [delete the repository](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-repository) if you no longer need the source data. Returns a status of `404 Not Found` if the repository is not locked.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#unlock-a-user-repository", + "description": "This will trigger a [ping event](https://docs.github.com/enterprise-cloud@latest//webhooks/#ping-event) to be sent to the hook.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#ping-an-organization-webhook", "parameters": [ { - "name": "migration_id", - "description": "The unique identifier of the migration.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -26588,10 +32018,10 @@ "deprecated": null }, { - "name": "repo_name", - "description": "repo_name parameter", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -26603,24 +32033,21 @@ ], "responses": [ { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Unlock an organization repository", - "scope": "migrations", - "id": "unlockRepoForOrg", - "method": "DELETE", - "url": "/orgs/{org}/migrations/{migration_id}/repos/{repo_name}/lock", + "name": "Redeliver a delivery for an organization webhook", + "scope": "orgs", + "id": "redeliverWebhookDelivery", + "method": "POST", + "url": "/orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}/attempts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Unlocks a repository that was locked for migration. You should unlock each migrated repository and [delete them](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-repository) when the migration is complete and you no longer need the source data.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#unlock-an-organization-repository", + "description": "Redeliver a delivery for a webhook configured in an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#redeliver-a-delivery-for-an-organization-webhook", "parameters": [ { "name": "org", @@ -26636,8 +32063,8 @@ "deprecated": null }, { - "name": "migration_id", - "description": "The unique identifier of the migration.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", "type": "integer", "required": true, @@ -26649,10 +32076,10 @@ "deprecated": null }, { - "name": "repo_name", - "description": "repo_name parameter", + "name": "delivery_id", + "description": "", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -26663,26 +32090,31 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 202, "description": "Accepted" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Update an import", - "scope": "migrations", - "id": "updateImport", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/import", + "name": "Remove an organization member", + "scope": "orgs", + "id": "removeMember", + "method": "DELETE", + "url": "/orgs/{org}/members/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "An import can be updated with credentials or a project choice by passing in the appropriate parameters in this API\nrequest. If no parameters are provided, the import will be restarted.\n\nSome servers (e.g. TFS servers) can have several projects at a single URL. In those cases the import progress will\nhave the status `detection_found_multiple` and the Import Progress response will include a `project_choices` array.\nYou can select the project to import by providing one of the objects in the `project_choices` array in the update request.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/migrations#update-an-import", + "description": "Removing a user from this list will remove them from all teams and they will no longer have any access to the organization's repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-an-organization-member", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -26694,8 +32126,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -26705,13 +32137,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Remove organization membership for a user", + "scope": "orgs", + "id": "removeMembershipForUser", + "method": "DELETE", + "url": "/orgs/{org}/memberships/{username}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "In order to remove a user's membership with an organization, the authenticated user must be an organization owner.\n\nIf the specified user is an active member of the organization, this will remove them from the organization. If the specified user has been invited to the organization, this will cancel their invitation. The specified user will receive an email notification in both cases.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-organization-membership-for-a-user", + "parameters": [ { - "name": "vcs_username", - "description": "The username to provide to the originating repository.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -26720,25 +32171,45 @@ "deprecated": null }, { - "name": "vcs_password", - "description": "The password to provide to the originating repository.", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Remove outside collaborator from an organization", + "scope": "orgs", + "id": "removeOutsideCollaborator", + "method": "DELETE", + "url": "/orgs/{org}/outside_collaborators/{username}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Removing a user from this list will remove them from all the organization's repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-outside-collaborator-from-an-organization", + "parameters": [ { - "name": "vcs", - "description": "The type of version control system you are migrating from.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["subversion", "tfvc", "git", "mercurial"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -26746,11 +32217,11 @@ "deprecated": null }, { - "name": "tfvc_project", - "description": "For a tfvc import, the name of the project that is being imported.", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -26759,20 +32230,26 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { + "code": 422, + "description": "Unprocessable Entity if user is a member of the organization" + } + ], "renamed": null }, { - "name": "Add a security manager team", + "name": "Remove public organization membership for the authenticated user", "scope": "orgs", - "id": "addSecurityManagerTeam", - "method": "PUT", - "url": "/orgs/{org}/security-managers/teams/{team_slug}", + "id": "removePublicMembershipForAuthenticatedUser", + "method": "DELETE", + "url": "/orgs/{org}/public_members/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Adds a team as a security manager for an organization. For more information, see \"[Managing security for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) for an organization.\"\n\nTo use this endpoint, you must be an administrator for the organization, and you must use an access token with the `write:org` scope.\n\nGitHub Apps must have the `administration` organization read-write permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#add-a-security-manager-team", + "description": "Removes the public membership for the authenticated user from the specified organization, unless public visibility is enforced by default.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-public-organization-membership-for-the-authenticated-user", "parameters": [ { "name": "org", @@ -26788,8 +32265,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -26801,26 +32278,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { - "code": 409, - "description": "The organization has reached the maximum number of security manager teams." - } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Block a user from an organization", + "name": "Remove a security manager team", "scope": "orgs", - "id": "blockUser", - "method": "PUT", - "url": "/orgs/{org}/blocks/{username}", + "id": "removeSecurityManagerTeam", + "method": "DELETE", + "url": "/orgs/{org}/security-managers/teams/{team_slug}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#block-a-user-from-an-organization", + "description": "Removes the security manager role from a team for an organization. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) team from an organization.\"\n\nTo use this endpoint, you must be an administrator for the organization, and you must use an access token with the `admin:org` scope.\n\nGitHub Apps must have the `administration` organization read-write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-a-security-manager-team", "parameters": [ { "name": "org", @@ -26836,8 +32307,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -26849,26 +32320,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Cancel an organization invitation", + "name": "Review a request to access organization resources with a fine-grained personal access token", "scope": "orgs", - "id": "cancelInvitation", - "method": "DELETE", - "url": "/orgs/{org}/invitations/{invitation_id}", + "id": "reviewPatGrantRequest", + "method": "POST", + "url": "/organizations/{org}/personal-access-token-requests/{pat_request_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Cancel an organization invitation. In order to cancel an organization invitation, the authenticated user must be an organization owner.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#cancel-an-organization-invitation", + "description": "Approves or denies a pending request to access organization resources via a fine-grained personal access token. Only GitHub Apps can call this API,\nusing the `organization_personal_access_token_requests: write` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#review-a-request-to-access-organization-resources-with-a-fine-grained-personal-access-token", "parameters": [ { "name": "org", @@ -26884,8 +32349,8 @@ "deprecated": null }, { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "pat_request_id", + "description": "Unique identifier of the request for access via fine-grained personal access token.", "in": "PATH", "type": "integer", "required": true, @@ -26895,29 +32360,57 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "action", + "description": "Action to apply to the request.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["approve", "deny"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "reason", + "description": "Reason for approving or denying the request. Max 1024 characters.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 204, "description": "A header with no content is returned." }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Check if a user is blocked by an organization", + "name": "Review requests to access organization resources with fine-grained personal access tokens", "scope": "orgs", - "id": "checkBlockedUser", - "method": "GET", - "url": "/orgs/{org}/blocks/{username}", + "id": "reviewPatGrantRequestsInBulk", + "method": "POST", + "url": "/organizations/{org}/personal-access-token-requests", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-if-a-user-is-blocked-by-an-organization", + "description": "Approves or denies multiple pending requests to access organization resources via a fine-grained personal access token. Only GitHub Apps can call this API,\nusing the `organization_personal_access_token_requests: write` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#review-requests-to-access-organization-resources-with-a-fine-grained-personal-access-token", "parameters": [ { "name": "org", @@ -26933,36 +32426,68 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "pat_request_ids", + "description": "Unique identifiers of the requests for access via fine-grained personal access token. Must be formed of between 1 and 100 `pat_request_id` values.", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "action", + "description": "Action to apply to the requests.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["approve", "deny"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + }, + { + "name": "reason", + "description": "Reason for approving or denying the requests. Max 1024 characters.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 204, "description": "If the user is blocked" }, - { "code": 404, "description": "If the user is not blocked" } + { "code": 202, "description": "Accepted" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Check organization membership for a user", + "name": "Set organization membership for a user", "scope": "orgs", - "id": "checkMembershipForUser", - "method": "GET", - "url": "/orgs/{org}/members/{username}", + "id": "setMembershipForUser", + "method": "PUT", + "url": "/orgs/{org}/memberships/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Check if a user is, publicly or privately, a member of the organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-organization-membership-for-a-user", + "description": "Only authenticated organization owners can add a member to the organization or update the member's role.\n\n* If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-organization-membership-for-a-user) will be `pending` until they accept the invitation.\n \n* Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent.\n\n**Rate limits**\n\nTo prevent abuse, the authenticated user is limited to 50 organization invitations per 24 hour period. If the organization is more than one month old or on a paid plan, the limit is 500 invitations per 24 hour period.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#set-organization-membership-for-a-user", "parameters": [ { "name": "org", @@ -26982,8 +32507,21 @@ "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", - "required": true, - "enum": null, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "role", + "description": "The role to give the user in the organization. Can be one of: \n * `admin` - The user will become an owner of the organization. \n * `member` - The user will become a non-owner member of the organization.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["admin", "member"], "allowNull": false, "mapToData": null, "validation": null, @@ -26992,32 +32530,26 @@ } ], "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { - "code": 204, - "description": "Response if requester is an organization member and user is a member" - }, - { - "code": 302, - "description": "Response if requester is not an organization member" - }, - { - "code": 404, - "description": "Not Found if requester is an organization member and user is not a member" + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], "renamed": null }, { - "name": "Check public organization membership for a user", + "name": "Set public organization membership for the authenticated user", "scope": "orgs", - "id": "checkPublicMembershipForUser", - "method": "GET", + "id": "setPublicMembershipForAuthenticatedUser", + "method": "PUT", "url": "/orgs/{org}/public_members/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#check-public-organization-membership-for-a-user", + "description": "The user can publicize their own membership. (A user cannot publicize the membership for another user.)\n\nNote that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#set-public-organization-membership-for-the-authenticated-user", "parameters": [ { "name": "org", @@ -27047,22 +32579,22 @@ } ], "responses": [ - { "code": 204, "description": "Response if user is a public member" }, - { "code": 404, "description": "Not Found if user is not a public member" } + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "Convert an organization member to outside collaborator", + "name": "Unblock a user from an organization", "scope": "orgs", - "id": "convertMemberToOutsideCollaborator", - "method": "PUT", - "url": "/orgs/{org}/outside_collaborators/{username}", + "id": "unblockUser", + "method": "DELETE", + "url": "/orgs/{org}/blocks/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "When an organization member is converted to an outside collaborator, they'll only have access to the repositories that their current team membership allows. The user will no longer be a member of the organization. For more information, see \"[Converting an organization member to an outside collaborator](https://docs.github.com/enterprise-cloud@latest//articles/converting-an-organization-member-to-an-outside-collaborator/)\". Converting an organization member to an outside collaborator may be restricted by enterprise administrators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/enterprise-cloud@latest/admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#convert-an-organization-member-to-outside-collaborator", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#unblock-a-user-from-an-organization", "parameters": [ { "name": "org", @@ -27089,46 +32621,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "async", - "description": "When set to `true`, the request will be performed asynchronously. Returns a 202 status code when the job is successfully queued.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [ - { - "code": 202, - "description": "User is getting converted asynchronously" - }, - { "code": 204, "description": "User was converted" }, - { - "code": 403, - "description": "Forbidden if user is the last owner of the organization, not a member of the organization, or if the enterprise enforces a policy for inviting outside collaborators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/en/enterprise-cloud@latest/admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"" - }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Create a custom role", + "name": "Update an organization", "scope": "orgs", - "id": "createCustomRole", - "method": "POST", - "url": "/orgs/{org}/custom_roles", + "id": "update", + "method": "PATCH", + "url": "/orgs/{org}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note**: This operation is in beta and is subject to change.\n\nCreates a custom repository role that can be used by all repositories owned by the organization.\n\nTo use this endpoint the authenticated user must be an administrator for the organization and must use an access token with `admin:org` scope.\nGitHub Apps must have the `organization_custom_roles:write` organization permission to use this endpoint.\n\nFor more information on custom repository roles, see \"[Managing custom repository roles for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-a-custom-role", + "description": "**Parameter Deprecation Notice:** GitHub Enterprise Cloud will replace and discontinue `members_allowed_repository_creation_type` in favor of more granular permissions. The new input parameters are `members_can_create_public_repositories`, `members_can_create_private_repositories` for all organizations and `members_can_create_internal_repositories` for organizations associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+. For more information, see the [blog post](https://developer.github.com/changes/2019-12-03-internal-visibility-changes).\n\nEnables an authenticated organization owner with the `admin:org` scope or the `repo` scope to update the organization's profile and member privileges.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization", "parameters": [ { "name": "org", @@ -27144,11 +32652,11 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the custom role.", + "name": "billing_email", + "description": "Billing email address. This address is not publicized.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27157,8 +32665,8 @@ "deprecated": null }, { - "name": "description", - "description": "A short description about the intended usage of this role or what permissions it grants.", + "name": "company", + "description": "The company name.", "in": "BODY", "type": "string", "required": false, @@ -27170,12 +32678,12 @@ "deprecated": null }, { - "name": "base_role", - "description": "The system role from which this role inherits permissions.", + "name": "email", + "description": "The publicly visible email address.", "in": "BODY", "type": "string", - "required": true, - "enum": ["read", "triage", "write", "maintain"], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -27183,47 +32691,24 @@ "deprecated": null }, { - "name": "permissions", - "description": "A list of additional permissions included in this role.", + "name": "twitter_username", + "description": "The Twitter username of the company.", "in": "BODY", - "type": "string[]", - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create an organization invitation", - "scope": "orgs", - "id": "createInvitation", - "method": "POST", - "url": "/orgs/{org}/invitations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Invite people to an organization by using their GitHub user ID or their email address. In order to create invitations in an organization, the authenticated user must be an organization owner.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-an-organization-invitation", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "location", + "description": "The location.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27232,10 +32717,10 @@ "deprecated": null }, { - "name": "invitee_id", - "description": "**Required unless you provide `email`**. GitHub user ID for the person you are inviting.", + "name": "name", + "description": "The shorthand name of the company.", "in": "BODY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -27245,8 +32730,8 @@ "deprecated": null }, { - "name": "email", - "description": "**Required unless you provide `invitee_id`**. Email address of the person you are inviting, which can be an existing GitHub user.", + "name": "description", + "description": "The description of the company.", "in": "BODY", "type": "string", "required": false, @@ -27258,12 +32743,12 @@ "deprecated": null }, { - "name": "role", - "description": "The role for the new member. \n\\* `admin` - Organization owners with full administrative rights to the organization and complete access to all repositories and teams. \n\\* `direct_member` - Non-owner organization members with ability to see other members and join teams by invitation. \n\\* `billing_manager` - Non-owner organization members with ability to manage the billing settings of your organization.", + "name": "has_organization_projects", + "description": "Whether an organization can use organization projects.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, - "enum": ["admin", "direct_member", "billing_manager"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -27271,10 +32756,10 @@ "deprecated": null }, { - "name": "team_ids", - "description": "Specify IDs for the teams you want to invite new members to.", + "name": "has_repository_projects", + "description": "Whether repositories that belong to the organization can use repository projects.", "in": "BODY", - "type": "integer[]", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27282,37 +32767,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create an organization webhook", - "scope": "orgs", - "id": "createWebhook", - "method": "POST", - "url": "/orgs/{org}/hooks", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Here's how you can create a hook that posts payloads in JSON format:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-an-organization-webhook", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "default_repository_permission", + "description": "Default permission level members have for organization repositories.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["read", "write", "admin", "none"], "allowNull": false, "mapToData": null, "validation": null, @@ -27320,11 +32782,11 @@ "deprecated": null }, { - "name": "name", - "description": "Must be passed as \"web\".", + "name": "members_can_create_repositories", + "description": "Whether of non-admin organization members can create repositories. **Note:** A parameter can override this parameter. See `members_allowed_repository_creation_type` in this table for details.", "in": "BODY", - "type": "string", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27333,11 +32795,11 @@ "deprecated": null }, { - "name": "config", - "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#create-hook-config-params).", + "name": "members_can_create_internal_repositories", + "description": "Whether organization members can create internal repositories, which are visible to all enterprise members. You can only allow members to create internal repositories if your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", "in": "BODY", - "type": "object", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27346,11 +32808,11 @@ "deprecated": null }, { - "name": "config.url", - "description": "The URL to which the payloads will be delivered.", + "name": "members_can_create_private_repositories", + "description": "Whether organization members can create private repositories, which are visible to organization members with permission. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", "in": "BODY", - "type": "string", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27359,10 +32821,10 @@ "deprecated": null }, { - "name": "config.content_type", - "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", + "name": "members_can_create_public_repositories", + "description": "Whether organization members can create public repositories, which are visible to anyone. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27372,12 +32834,12 @@ "deprecated": null }, { - "name": "config.secret", - "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "name": "members_allowed_repository_creation_type", + "description": "Specifies which types of repositories non-admin organization members can create. `private` is only available to repositories that are part of an organization on GitHub Enterprise Cloud. \n**Note:** This parameter is deprecated and will be removed in the future. Its return value ignores internal repositories. Using this parameter overrides values set in `members_can_create_repositories`. See the parameter deprecation notice in the operation description for details.", "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["all", "private", "none"], "allowNull": false, "mapToData": null, "validation": null, @@ -27385,10 +32847,10 @@ "deprecated": null }, { - "name": "config.insecure_ssl", - "description": "", + "name": "members_can_create_pages", + "description": "Whether organization members can create GitHub Pages sites. Existing published sites will not be impacted.", "in": "BODY", - "type": null, + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27398,10 +32860,10 @@ "deprecated": null }, { - "name": "config.username", - "description": "", + "name": "members_can_create_public_pages", + "description": "Whether organization members can create public GitHub Pages sites. Existing published sites will not be impacted.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27411,10 +32873,10 @@ "deprecated": null }, { - "name": "config.password", - "description": "", + "name": "members_can_create_private_pages", + "description": "Whether organization members can create private GitHub Pages sites. Existing published sites will not be impacted.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27424,10 +32886,10 @@ "deprecated": null }, { - "name": "events", - "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for.", + "name": "members_can_fork_private_repositories", + "description": "Whether organization members can fork private organization repositories.", "in": "BODY", - "type": "string[]", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -27437,8 +32899,8 @@ "deprecated": null }, { - "name": "active", - "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", + "name": "web_commit_signoff_required", + "description": "Whether contributors to organization repositories are required to sign off on commits they make through GitHub's web interface.", "in": "BODY", "type": "boolean", "required": false, @@ -27448,36 +32910,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Delete a custom role", - "scope": "orgs", - "id": "deleteCustomRole", - "method": "DELETE", - "url": "/orgs/{org}/custom_roles/{role_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note**: This operation is in beta and is subject to change.\n\nDeletes a custom role from an organization. Once the custom role has been deleted, any\nuser, team, or invitation with the deleted custom role will be reassigned the inherited role.\n\nTo use this endpoint the authenticated user must be an administrator for the organization and must use an access token with `admin:org` scope.\nGitHub Apps must have the `organization_custom_roles:write` organization permission to use this endpoint.\n\nFor more information about custom repository roles, see \"[Managing custom repository roles for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#delete-a-custom-role", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "blog", + "description": "", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27486,40 +32925,24 @@ "deprecated": null }, { - "name": "role_id", - "description": "The unique identifier of the role.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "advanced_security_enabled_for_new_repositories", + "description": "Whether GitHub Advanced Security is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete an organization webhook", - "scope": "orgs", - "id": "deleteWebhook", - "method": "DELETE", - "url": "/orgs/{org}/hooks/{hook_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#delete-an-organization-webhook", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "dependabot_alerts_enabled_for_new_repositories", + "description": "Whether Dependabot alerts is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27528,43 +32951,24 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "dependabot_security_updates_enabled_for_new_repositories", + "description": "Whether Dependabot security updates is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Enable or disable a security feature for an organization", - "scope": "orgs", - "id": "enableOrDisableSecurityProductOnAllOrgRepos", - "method": "POST", - "url": "/orgs/{org}/{security_product}/{enablement}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Enables or disables the specified security feature for all repositories in an organization.\n\nTo use this endpoint, you must be an organization owner or be member of a team with the security manager role.\nA token with the 'write:org' scope is also required.\n\nGitHub Apps must have the `organization_administration:write` permission to use this endpoint.\n\nFor more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#enable-or-disable-security-product-on-all-org-repos", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "dependency_graph_enabled_for_new_repositories", + "description": "Whether dependency graph is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27573,19 +32977,12 @@ "deprecated": null }, { - "name": "security_product", - "description": "The security feature to enable or disable.", - "in": "PATH", - "type": "string", - "required": true, - "enum": [ - "dependency_graph", - "dependabot_alerts", - "dependabot_security_updates", - "advanced_security", - "secret_scanning", - "secret_scanning_push_protection" - ], + "name": "secret_scanning_enabled_for_new_repositories", + "description": "Whether secret scanning is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -27593,78 +32990,37 @@ "deprecated": null }, { - "name": "enablement", - "description": "The action to take.\n\n`enable_all` means to enable the specified security feature for all repositories in the organization.\n`disable_all` means to disable the specified security feature for all repositories in the organization.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["enable_all", "disable_all"], + "name": "secret_scanning_push_protection_enabled_for_new_repositories", + "description": "Whether secret scanning push protection is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Action started" }, - { - "code": 422, - "description": "The action could not be taken due to an in progress enablement, or a policy is preventing enablement" - } - ], - "renamed": null - }, - { - "name": "Get an organization", - "scope": "orgs", - "id": "get", - "method": "GET", - "url": "/orgs/{org}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "To see many of the organization response values, you need to be an authenticated organization owner with the `admin:org` scope. When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, and outside collaborators to enable [two-factor authentication](https://docs.github.com/articles/securing-your-account-with-two-factor-authentication-2fa/).\n\nGitHub Apps with the `Organization plan` permission can use this endpoint to retrieve information about an organization's GitHub Enterprise Cloud plan. See \"[Authenticating with GitHub Apps](https://docs.github.com/enterprise-cloud@latest//apps/building-github-apps/authenticating-with-github-apps/)\" for details. For an example response, see 'Response with GitHub Enterprise Cloud plan information' below.\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "secret_scanning_push_protection_custom_link_enabled", + "description": "Whether a custom link is shown to contributors who are blocked from pushing a secret by push protection.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get an organization membership for the authenticated user", - "scope": "orgs", - "id": "getMembershipForAuthenticatedUser", - "method": "GET", - "url": "/user/memberships/orgs/{org}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization-membership-for-the-authenticated-user", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "secret_scanning_push_protection_custom_link", + "description": "If `secret_scanning_push_protection_custom_link_enabled` is true, the URL that will be displayed to contributors who are blocked from pushing a secret.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27675,22 +33031,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 409, "description": "Conflict" }, + { "code": 422, "description": "Validation failed" } ], "renamed": null }, { - "name": "Get organization membership for a user", + "name": "Update an organization membership for the authenticated user", "scope": "orgs", - "id": "getMembershipForUser", - "method": "GET", - "url": "/orgs/{org}/memberships/{username}", + "id": "updateMembershipForAuthenticatedUser", + "method": "PATCH", + "url": "/user/memberships/orgs/{org}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "In order to get a user's membership with an organization, the authenticated user must be an organization member. The `state` parameter in the response can be used to identify the user's membership status.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-organization-membership-for-a-user", + "description": "Converts the authenticated user to an active member of the organization, if that user has a pending invitation from the organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization-membership-for-the-authenticated-user", "parameters": [ { "name": "org", @@ -27706,12 +33062,12 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "state", + "description": "The state that the membership should be in. Only `\"active\"` will be accepted.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["active"], "allowNull": false, "mapToData": null, "validation": null, @@ -27722,21 +33078,25 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get an organization webhook", + "name": "Update the access a fine-grained personal access token has to organization resources", "scope": "orgs", - "id": "getWebhook", - "method": "GET", - "url": "/orgs/{org}/hooks/{hook_id}", + "id": "updatePatAccess", + "method": "POST", + "url": "/organizations/{org}/personal-access-tokens/{pat_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a webhook configured in an organization. To get only the webhook `config` properties, see \"[Get a webhook configuration for an organization](/rest/reference/orgs#get-a-webhook-configuration-for-an-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-an-organization-webhook", + "description": "Updates the access an organization member has to organization resources via a fine-grained personal access token. Limited to revoking the token's existing access. Limited to revoking a token's existing access. Only GitHub Apps can call this API,\nusing the `organization_personal_access_tokens: write` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#update-the-access-a-fine-grained-personal-access-token-has-to-organization-resources", "parameters": [ { "name": "org", @@ -27752,8 +33112,8 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "pat_id", + "description": "The unique identifier of the fine-grained personal access token.", "in": "PATH", "type": "integer", "required": true, @@ -27763,25 +33123,44 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "action", + "description": "Action to apply to the fine-grained personal access token.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["revoke"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 204, "description": "A header with no content is returned." }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Get a webhook configuration for an organization", + "name": "Update the access to organization resources via fine-grained personal access tokens", "scope": "orgs", - "id": "getWebhookConfigForOrg", - "method": "GET", - "url": "/orgs/{org}/hooks/{hook_id}/config", + "id": "updatePatAccesses", + "method": "POST", + "url": "/organizations/{org}/personal-access-tokens", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the webhook configuration for an organization. To get more information about the webhook, including the `active` state and `events`, use \"[Get an organization webhook ](/rest/reference/orgs#get-an-organization-webhook).\"\n\nAccess tokens must have the `admin:org_hook` scope, and GitHub Apps must have the `organization_hooks:read` permission.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-configuration-for-an-organization", + "description": "Updates the access organization members have to organization resources via fine-grained personal access tokens. Limited to revoking a token's existing access. Only GitHub Apps can call this API,\nusing the `organization_personal_access_tokens: write` permission.\n\n**Note**: Fine-grained PATs are in public beta. Related APIs, events, and functionality are subject to change.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/orgs/orgs#update-the-access-to-organization-resources-via-fine-grained-personal-access-tokens", "parameters": [ { "name": "org", @@ -27789,7 +33168,20 @@ "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "action", + "description": "Action to apply to the fine-grained personal access token.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["revoke"], "allowNull": false, "mapToData": null, "validation": null, @@ -27797,10 +33189,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", - "type": "integer", + "name": "pat_ids", + "description": "The IDs of the fine-grained personal access tokens.", + "in": "BODY", + "type": "integer[]", "required": true, "enum": null, "allowNull": false, @@ -27810,20 +33202,29 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { - "name": "Get a webhook delivery for an organization webhook", + "name": "Update an organization webhook", "scope": "orgs", - "id": "getWebhookDelivery", - "method": "GET", - "url": "/orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}", + "id": "updateWebhook", + "method": "PATCH", + "url": "/orgs/{org}/hooks/{hook_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a delivery for a webhook configured in an organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-a-webhook-delivery-for-an-organization-webhook", + "description": "Updates a webhook configured in an organization. When you update a webhook, the `secret` will be overwritten. If you previously had a `secret` set, you must provide the same `secret` or set a new `secret` or the secret will be removed. If you are only updating individual webhook `config` properties, use \"[Update a webhook configuration for an organization](/rest/reference/orgs#update-a-webhook-configuration-for-an-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization-webhook", "parameters": [ { "name": "org", @@ -27852,48 +33253,24 @@ "deprecated": null }, { - "name": "delivery_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "name": "config", + "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-hook-config-params).", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "List organizations", - "scope": "orgs", - "id": "list", - "method": "GET", - "url": "/organizations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all organizations, in the order that they were created on GitHub Enterprise Cloud.\n\n**Note:** Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header) to get the URL for the next page of organizations.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations", - "parameters": [ + }, { - "name": "since", - "description": "An organization ID. Only return organizations with an ID greater than this ID.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "config.url", + "description": "The URL to which the payloads will be delivered.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -27902,10 +33279,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "config.content_type", + "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -27913,32 +33290,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } - ], - "renamed": null - }, - { - "name": "List app installations for an organization", - "scope": "orgs", - "id": "listAppInstallations", - "method": "GET", - "url": "/orgs/{org}/installations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all GitHub Apps in an organization. The installation count includes all GitHub Apps installed on repositories in the organization. You must be an organization owner with `admin:read` scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-app-installations-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "config.secret", + "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -27947,10 +33305,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "config.insecure_ssl", + "description": "", + "in": "BODY", + "type": null, "required": false, "enum": null, "allowNull": false, @@ -27960,10 +33318,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "events", + "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for.", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -27971,58 +33329,26 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List users blocked by an organization", - "scope": "orgs", - "id": "listBlockedUsers", - "method": "GET", - "url": "/orgs/{org}/blocks", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List the users blocked by an organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-users-blocked-by-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "active", + "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List custom repository roles in an organization", - "scope": "orgs", - "id": "listCustomRoles", - "method": "GET", - "url": "/organizations/{organization_id}/custom_roles", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List the custom repository roles available in this organization. In order to see custom\nrepository roles in an organization, the authenticated user must be an organization owner.\n\nTo use this endpoint the authenticated user must be an administrator for the organization or of an repository of the organizaiton and must use an access token with `admin:org repo` scope.\nGitHub Apps must have the `organization_custom_roles:read` organization permission to use this endpoint.\n\nFor more information on custom repository roles, see \"[Managing custom repository roles for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-custom-repository-roles-in-an-organization", - "parameters": [ + }, { - "name": "organization_id", - "description": "The unique identifier of the organization.", - "in": "PATH", + "name": "name", + "description": "", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -28032,21 +33358,26 @@ } ], "responses": [ - { "code": 200, "description": "Response - list of custom role names" } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List failed organization invitations", + "name": "Update a webhook configuration for an organization", "scope": "orgs", - "id": "listFailedInvitations", - "method": "GET", - "url": "/orgs/{org}/failed_invitations", + "id": "updateWebhookConfigForOrg", + "method": "PATCH", + "url": "/orgs/{org}/hooks/{hook_id}/config", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The return hash contains `failed_at` and `failed_reason` fields which represent the time at which the invitation failed and the reason for the failure.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-failed-organization-invitations", + "description": "Updates the webhook configuration for an organization. To update more information about the webhook, including the `active` state and `events`, use \"[Update an organization webhook ](/rest/reference/orgs#update-an-organization-webhook).\"\n\nAccess tokens must have the `admin:org_hook` scope, and GitHub Apps must have the `organization_hooks:write` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-a-webhook-configuration-for-an-organization", "parameters": [ { "name": "org", @@ -28062,10 +33393,23 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "url", + "description": "The URL to which the payloads will be delivered.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -28075,10 +33419,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "content_type", + "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -28086,32 +33430,26 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "List fine-grained permissions for an organization", - "scope": "orgs", - "id": "listFineGrainedPermissions", - "method": "GET", - "url": "/orgs/{org}/fine_grained_permissions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note**: This operation is in beta and subject to change.\n\nLists the fine-grained permissions available for an organization.\n\nTo use this endpoint the authenticated user must be an administrator for the organization or of an repository of the organizaiton and must use an access token with `admin:org repo` scope.\nGitHub Apps must have the `organization_custom_roles:read` organization permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-fine-grained-permissions-for-an-organization", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "secret", + "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "in": "BODY", "type": "string", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "insecure_ssl", + "description": "", + "in": "BODY", + "type": null, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -28124,24 +33462,24 @@ "renamed": null }, { - "name": "List organizations for the authenticated user", - "scope": "orgs", - "id": "listForAuthenticatedUser", - "method": "GET", - "url": "/user/orgs", + "name": "Delete a package for the authenticated user", + "scope": "packages", + "id": "deletePackageForAuthenticatedUser", + "method": "DELETE", + "url": "/user/packages/{package_type}/{package_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List organizations for the authenticated user.\n\n**OAuth scope requirements**\n\nThis only lists organizations that your authorization allows you to operate on in some way (e.g., you can list teams with `read:org` scope, you can publicize your organization membership with `user` scope, etc.). Therefore, this API requires at least `user` or `read:org` scope. OAuth requests with insufficient scope receive a `403 Forbidden` response.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-the-authenticated-user", + "description": "Deletes a package owned by the authenticated user. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `delete:packages` scopes.\nIf the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-the-authenticated-user", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", + "type": "string", + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28149,11 +33487,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28163,32 +33501,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, + { "code": 204, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List organizations for a user", - "scope": "orgs", - "id": "listForUser", - "method": "GET", - "url": "/users/{username}/orgs", + "name": "Delete a package for an organization", + "scope": "packages", + "id": "deletePackageForOrg", + "method": "DELETE", + "url": "/orgs/{org}/packages/{package_type}/{package_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List [public organization memberships](https://docs.github.com/articles/publicizing-or-concealing-organization-membership) for the specified user.\n\nThis method only lists _public_ memberships, regardless of authentication. If you need to fetch all of the organization memberships (public and private) for the authenticated user, use the [List organizations for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-the-authenticated-user) API instead.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organizations-for-a-user", + "description": "Deletes an entire package in an organization. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `read:packages` and `delete:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package you want to delete. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-an-organization", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28196,11 +33534,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28209,11 +33547,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28222,28 +33560,33 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List organization invitation teams", - "scope": "orgs", - "id": "listInvitationTeams", - "method": "GET", - "url": "/orgs/{org}/invitations/{invitation_id}/teams", + "name": "Delete a package for a user", + "scope": "packages", + "id": "deletePackageForUser", + "method": "DELETE", + "url": "/users/{username}/packages/{package_type}/{package_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all teams associated with an invitation. In order to see invitations in an organization, the authenticated user must be an organization owner.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-invitation-teams", + "description": "Deletes an entire package for a user. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `delete:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package you want to delete. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-a-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28251,10 +33594,10 @@ "deprecated": null }, { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -28264,24 +33607,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28291,43 +33621,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List organization members", - "scope": "orgs", - "id": "listMembers", - "method": "GET", - "url": "/orgs/{org}/members", + "name": "Delete a package version for the authenticated user", + "scope": "packages", + "id": "deletePackageVersionForAuthenticatedUser", + "method": "DELETE", + "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all users who are members of an organization. If the authenticated user is also a member of this organization then both concealed and public members will be returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-members", + "description": "Deletes a specific package version for a package owned by the authenticated user. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `read:packages` and `delete:packages` scopes.\nIf the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "filter", - "description": "Filter members returned in the list. `2fa_disabled` means that only members without [two-factor authentication](https://github.com/blog/1614-two-factor-authentication) enabled will be returned. This options is only available for organization owners.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["2fa_disabled", "all"], + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28335,24 +33654,11 @@ "deprecated": null }, { - "name": "role", - "description": "Filter members returned by their role.", - "in": "QUERY", + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["all", "admin", "member"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28361,11 +33667,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28375,33 +33681,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List organization memberships for the authenticated user", - "scope": "orgs", - "id": "listMembershipsForAuthenticatedUser", - "method": "GET", - "url": "/user/memberships/orgs", + "name": "Delete package version for an organization", + "scope": "packages", + "id": "deletePackageVersionForOrg", + "method": "DELETE", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-memberships-for-the-authenticated-user", + "description": "Deletes a specific package version in an organization. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `read:packages` and `delete:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package whose version you want to delete. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-an-organization", "parameters": [ { - "name": "state", - "description": "Indicates the state of the memberships to return. If not specified, the API returns both active and pending memberships.", - "in": "QUERY", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["active", "pending"], + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28409,11 +33714,24 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28422,11 +33740,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28436,36 +33754,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, + { "code": 204, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List outside collaborators for an organization", - "scope": "orgs", - "id": "listOutsideCollaborators", - "method": "GET", - "url": "/orgs/{org}/outside_collaborators", + "name": "Delete package version for a user", + "scope": "packages", + "id": "deletePackageVersionForUser", + "method": "DELETE", + "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all users who are outside collaborators of an organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-outside-collaborators-for-an-organization", + "description": "Deletes a specific package version for a user. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `delete:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package whose version you want to delete. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-a-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28473,12 +33787,12 @@ "deprecated": null }, { - "name": "filter", - "description": "Filter the list of outside collaborators. `2fa_disabled` means that only outside collaborators without [two-factor authentication](https://github.com/blog/1614-two-factor-authentication) enabled will be returned.", - "in": "QUERY", + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["2fa_disabled", "all"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -28486,11 +33800,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28499,11 +33813,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28512,28 +33826,33 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List pending organization invitations", - "scope": "orgs", - "id": "listPendingInvitations", + "name": "List package versions for a package owned by an organization", + "scope": "packages", + "id": "getAllPackageVersionsForAPackageOwnedByAnOrg", "method": "GET", - "url": "/orgs/{org}/invitations", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The return hash contains a `role` field which refers to the Organization Invitation role and will be one of the following values: `direct_member`, `admin`, `billing_manager`, `hiring_manager`, or `reinstate`. If the invitee is not a GitHub Enterprise Cloud member, the `login` field in the return hash will be `null`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-pending-organization-invitations", + "description": "Lists package versions for a package owned by an organization.\n\nIf the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-an-organization", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28541,11 +33860,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -28554,43 +33873,24 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "List public organization members", - "scope": "orgs", - "id": "listPublicMembers", - "method": "GET", - "url": "/orgs/{org}/public_members", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Members of an organization can choose to have their membership publicized or not.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-public-organization-members", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -28612,12 +33912,12 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "state", + "description": "The state of the package, either active or deleted.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["active", "deleted"], "allowNull": false, "mapToData": null, "validation": null, @@ -28625,53 +33925,53 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": { + "before": { + "scope": "packages", + "id": "getAllPackageVersionsForAPackageOwnedByAnOrg" + }, + "after": { + "scope": "packages", + "id": "getAllPackageVersionsForPackageOwnedByOrg" + }, + "date": "2021-03-24", + "note": null + } }, { - "name": "List security manager teams", - "scope": "orgs", - "id": "listSecurityManagerTeams", + "name": "List package versions for a package owned by the authenticated user", + "scope": "packages", + "id": "getAllPackageVersionsForAPackageOwnedByTheAuthenticatedUser", "method": "GET", - "url": "/orgs/{org}/security-managers", + "url": "/user/packages/{package_type}/{package_name}/versions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists teams that are security managers for an organization. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nTo use this endpoint, you must be an administrator or security manager for the organization, and you must use an access token with the `read:org` scope.\n\nGitHub Apps must have the `administration` organization read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-security-manager-teams", + "description": "Lists package versions for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List deliveries for an organization webhook", - "scope": "orgs", - "id": "listWebhookDeliveries", - "method": "GET", - "url": "/orgs/{org}/hooks/{hook_id}/deliveries", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns a list of webhook deliveries for a webhook configured in an organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-deliveries-for-an-organization-webhook", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -28683,11 +33983,11 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -28709,12 +34009,12 @@ "deprecated": null }, { - "name": "cursor", - "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", + "name": "state", + "description": "The state of the package, either active or deleted.", "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["active", "deleted"], "allowNull": false, "mapToData": null, "validation": null, @@ -28724,30 +34024,51 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], - "renamed": null + "renamed": { + "before": { + "scope": "packages", + "id": "getAllPackageVersionsForAPackageOwnedByTheAuthenticatedUser" + }, + "after": { + "scope": "packages", + "id": "getAllPackageVersionsForPackageOwnedByAuthenticatedUser" + }, + "date": "2021-03-24", + "note": null + } }, { - "name": "List organization webhooks", - "scope": "orgs", - "id": "listWebhooks", + "name": "List package versions for a package owned by the authenticated user", + "scope": "packages", + "id": "getAllPackageVersionsForPackageOwnedByAuthenticatedUser", "method": "GET", - "url": "/orgs/{org}/hooks", + "url": "/user/packages/{package_type}/{package_name}/versions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#list-organization-webhooks", + "description": "Lists package versions for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", + "type": "string", + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -28759,8 +34080,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -28772,8 +34093,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -28783,33 +34104,48 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "state", + "description": "The state of the package, either active or deleted.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["active", "deleted"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Ping an organization webhook", - "scope": "orgs", - "id": "pingWebhook", - "method": "POST", - "url": "/orgs/{org}/hooks/{hook_id}/pings", + "name": "List package versions for a package owned by an organization", + "scope": "packages", + "id": "getAllPackageVersionsForPackageOwnedByOrg", + "method": "GET", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This will trigger a [ping event](https://docs.github.com/enterprise-cloud@latest//webhooks/#ping-event) to be sent to the hook.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#ping-an-organization-webhook", + "description": "Lists package versions for a package owned by an organization.\n\nIf the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-an-organization", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28817,10 +34153,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -28828,26 +34164,7 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Redeliver a delivery for an organization webhook", - "scope": "orgs", - "id": "redeliverWebhookDelivery", - "method": "POST", - "url": "/orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}/attempts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Redeliver a delivery for a webhook configured in an organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#redeliver-a-delivery-for-an-organization-webhook", - "parameters": [ + }, { "name": "org", "description": "The organization name. The name is not case sensitive.", @@ -28862,11 +34179,11 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -28875,45 +34192,68 @@ "deprecated": null }, { - "name": "delivery_id", - "description": "", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + }, + { + "name": "state", + "description": "The state of the package, either active or deleted.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["active", "deleted"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 202, "description": "Accepted" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Remove an organization member", - "scope": "orgs", - "id": "removeMember", - "method": "DELETE", - "url": "/orgs/{org}/members/{username}", + "name": "List package versions for a package owned by a user", + "scope": "packages", + "id": "getAllPackageVersionsForPackageOwnedByUser", + "method": "GET", + "url": "/users/{username}/packages/{package_type}/{package_name}/versions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removing a user from this list will remove them from all teams and they will no longer have any access to the organization's repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-an-organization-member", + "description": "Lists package versions for a public package owned by a specified user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-a-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", + "type": "string", + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -28939,30 +34279,32 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" } + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Remove organization membership for a user", - "scope": "orgs", - "id": "removeMembershipForUser", - "method": "DELETE", - "url": "/orgs/{org}/memberships/{username}", + "name": "Get a package for the authenticated user", + "scope": "packages", + "id": "getPackageForAuthenticatedUser", + "method": "GET", + "url": "/user/packages/{package_type}/{package_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "In order to remove a user's membership with an organization, the authenticated user must be an organization owner.\n\nIf the specified user is an active member of the organization, this will remove them from the organization. If the specified user has been invited to the organization, this will cancel their invitation. The specified user will receive an email notification in both cases.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-organization-membership-for-a-user", + "description": "Gets a specific package for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -28970,8 +34312,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -28983,32 +34325,28 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Remove outside collaborator from an organization", - "scope": "orgs", - "id": "removeOutsideCollaborator", - "method": "DELETE", - "url": "/orgs/{org}/outside_collaborators/{username}", + "name": "Get a package for an organization", + "scope": "packages", + "id": "getPackageForOrganization", + "method": "GET", + "url": "/orgs/{org}/packages/{package_type}/{package_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Removing a user from this list will remove them from all the organization's repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-outside-collaborator-from-an-organization", + "description": "Gets a specific package in an organization.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-an-organization", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29016,8 +34354,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -29027,29 +34365,7 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { - "code": 422, - "description": "Unprocessable Entity if user is a member of the organization" - } - ], - "renamed": null - }, - { - "name": "Remove public organization membership for the authenticated user", - "scope": "orgs", - "id": "removePublicMembershipForAuthenticatedUser", - "method": "DELETE", - "url": "/orgs/{org}/public_members/{username}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-public-organization-membership-for-the-authenticated-user", - "parameters": [ + }, { "name": "org", "description": "The organization name. The name is not case sensitive.", @@ -29062,39 +34378,39 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get a package for a user", + "scope": "packages", + "id": "getPackageForUser", + "method": "GET", + "url": "/users/{username}/packages/{package_type}/{package_name}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a specific package metadata for a public package owned by a user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-a-user", + "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Remove a security manager team", - "scope": "orgs", - "id": "removeSecurityManagerTeam", - "method": "DELETE", - "url": "/orgs/{org}/security-managers/teams/{team_slug}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes the security manager role from a team for an organization. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization) team from an organization.\"\n\nTo use this endpoint, you must be an administrator for the organization, and you must use an access token with the `admin:org` scope.\n\nGitHub Apps must have the `administration` organization read-write permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#remove-a-security-manager-team", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -29106,8 +34422,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -29119,28 +34435,28 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set organization membership for a user", - "scope": "orgs", - "id": "setMembershipForUser", - "method": "PUT", - "url": "/orgs/{org}/memberships/{username}", + "name": "Get a package version for the authenticated user", + "scope": "packages", + "id": "getPackageVersionForAuthenticatedUser", + "method": "GET", + "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Only authenticated organization owners can add a member to the organization or update the member's role.\n\n* If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#get-organization-membership-for-a-user) will be `pending` until they accept the invitation.\n \n* Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent.\n\n**Rate limits**\n\nTo prevent abuse, the authenticated user is limited to 50 organization invitations per 24 hour period. If the organization is more than one month old or on a paid plan, the limit is 500 invitations per 24 hour period.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#set-organization-membership-for-a-user", + "description": "Gets a specific package version for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29148,8 +34464,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -29161,12 +34477,12 @@ "deprecated": null }, { - "name": "role", - "description": "The role to give the user in the organization. Can be one of: \n\\* `admin` - The user will become an owner of the organization. \n\\* `member` - The user will become a non-owner member of the organization.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["admin", "member"], + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -29174,35 +34490,28 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Set public organization membership for the authenticated user", - "scope": "orgs", - "id": "setPublicMembershipForAuthenticatedUser", - "method": "PUT", - "url": "/orgs/{org}/public_members/{username}", + "name": "Get a package version for an organization", + "scope": "packages", + "id": "getPackageVersionForOrganization", + "method": "GET", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The user can publicize their own membership. (A user cannot publicize the membership for another user.)\n\nNote that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#set-public-organization-membership-for-the-authenticated-user", + "description": "Gets a specific package version in an organization.\n\nYou must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-an-organization", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29210,8 +34519,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", "type": "string", "required": true, @@ -29221,26 +34530,7 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Unblock a user from an organization", - "scope": "orgs", - "id": "unblockUser", - "method": "DELETE", - "url": "/orgs/{org}/blocks/{username}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#unblock-a-user-from-an-organization", - "parameters": [ + }, { "name": "org", "description": "The organization name. The name is not case sensitive.", @@ -29255,10 +34545,10 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "package_version_id", + "description": "Unique identifier of the package version.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -29268,28 +34558,28 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update an organization", - "scope": "orgs", - "id": "update", - "method": "PATCH", - "url": "/orgs/{org}", + "name": "Get a package version for a user", + "scope": "packages", + "id": "getPackageVersionForUser", + "method": "GET", + "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Parameter Deprecation Notice:** GitHub Enterprise Cloud will replace and discontinue `members_allowed_repository_creation_type` in favor of more granular permissions. The new input parameters are `members_can_create_public_repositories`, `members_can_create_private_repositories` for all organizations and `members_can_create_internal_repositories` for organizations associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+. For more information, see the [blog post](https://developer.github.com/changes/2019-12-03-internal-visibility-changes).\n\nEnables an authenticated organization owner with the `admin:org` scope to update the organization's profile and member privileges.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs/#update-an-organization", + "description": "Gets a specific package version for a public package owned by a specified user.\n\nAt this time, to use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-a-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29297,11 +34587,11 @@ "deprecated": null }, { - "name": "billing_email", - "description": "Billing email address. This address is not publicized.", - "in": "BODY", + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29310,11 +34600,11 @@ "deprecated": null }, { - "name": "company", - "description": "The company name.", - "in": "BODY", - "type": "string", - "required": false, + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29323,51 +34613,122 @@ "deprecated": null }, { - "name": "email", - "description": "The publicly visible email address.", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get list of conflicting packages during Docker migration for authenticated-user", + "scope": "packages", + "id": "listDockerMigrationConflictingPackagesForAuthenticatedUser", + "method": "GET", + "url": "/user/docker/conflicts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all packages that are owned by the authenticated user within the user's namespace, and that encountered a conflict during a Docker migration.\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#list-docker-migration-conflicting-packages-for-authenticated-user", + "parameters": [], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get list of conflicting packages during Docker migration for organization", + "scope": "packages", + "id": "listDockerMigrationConflictingPackagesForOrganization", + "method": "GET", + "url": "/orgs/{org}/docker/conflicts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all packages that are in a specific organization, are readable by the requesting user, and that encountered a conflict during a Docker migration.\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-docker-migration-conflicting-packages-for-organization", + "parameters": [ { - "name": "twitter_username", - "description": "The Twitter username of the company.", - "in": "BODY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Get list of conflicting packages during Docker migration for user", + "scope": "packages", + "id": "listDockerMigrationConflictingPackagesForUser", + "method": "GET", + "url": "/users/{username}/docker/conflicts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all packages that are in a specific user's namespace, that the requesting user has access to, and that encountered a conflict during Docker migration.\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-docker-migration-conflicting-packages-for-user", + "parameters": [ { - "name": "location", - "description": "The location.", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List packages for the authenticated user's namespace", + "scope": "packages", + "id": "listPackagesForAuthenticatedUser", + "method": "GET", + "url": "/user/packages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists packages owned by the authenticated user within the user's namespace.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-the-authenticated-user", + "parameters": [ { - "name": "name", - "description": "The shorthand name of the company.", - "in": "BODY", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "QUERY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29375,12 +34736,12 @@ "deprecated": null }, { - "name": "description", - "description": "The description of the company.", - "in": "BODY", + "name": "visibility", + "description": "The selected visibility of the packages. This parameter is optional and only filters an existing result set.\n\nThe `internal` visibility is only supported for GitHub Packages registries that allow for granular permissions. For other ecosystems `internal` is synonymous with `private`.\nFor the list of GitHub Packages registries that support granular permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["public", "private", "internal"], "allowNull": false, "mapToData": null, "validation": null, @@ -29388,10 +34749,10 @@ "deprecated": null }, { - "name": "has_organization_projects", - "description": "Whether an organization can use organization projects.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29401,10 +34762,10 @@ "deprecated": null }, { - "name": "has_repository_projects", - "description": "Whether repositories that belong to the organization can use repository projects.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29412,14 +34773,36 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "default_repository_permission", - "description": "Default permission level members have for organization repositories.", - "in": "BODY", + "code": 400, + "description": "The value of `per_page` multiplied by `page` cannot be greater than 10000." + } + ], + "renamed": null + }, + { + "name": "List packages for an organization", + "scope": "packages", + "id": "listPackagesForOrganization", + "method": "GET", + "url": "/orgs/{org}/packages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists packages in an organization readable by the user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-an-organization", + "parameters": [ + { + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "QUERY", "type": "string", - "required": false, - "enum": ["read", "write", "admin", "none"], + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29427,11 +34810,11 @@ "deprecated": null }, { - "name": "members_can_create_repositories", - "description": "Whether of non-admin organization members can create repositories. **Note:** A parameter can override this parameter. See `members_allowed_repository_creation_type` in this table for details.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29440,12 +34823,12 @@ "deprecated": null }, { - "name": "members_can_create_internal_repositories", - "description": "Whether organization members can create internal repositories, which are visible to all enterprise members. You can only allow members to create internal repositories if your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", - "in": "BODY", - "type": "boolean", + "name": "visibility", + "description": "The selected visibility of the packages. This parameter is optional and only filters an existing result set.\n\nThe `internal` visibility is only supported for GitHub Packages registries that allow for granular permissions. For other ecosystems `internal` is synonymous with `private`.\nFor the list of GitHub Packages registries that support granular permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["public", "private", "internal"], "allowNull": false, "mapToData": null, "validation": null, @@ -29453,10 +34836,10 @@ "deprecated": null }, { - "name": "members_can_create_private_repositories", - "description": "Whether organization members can create private repositories, which are visible to organization members with permission. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29466,10 +34849,10 @@ "deprecated": null }, { - "name": "members_can_create_public_repositories", - "description": "Whether organization members can create public repositories, which are visible to anyone. For more information, see \"[Restricting repository creation in your organization](https://docs.github.com/github/setting-up-and-managing-organizations-and-teams/restricting-repository-creation-in-your-organization)\" in the GitHub Help documentation.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29477,14 +34860,38 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 400, + "description": "The value of `per_page` multiplied by `page` cannot be greater than 10000." }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List packages for a user", + "scope": "packages", + "id": "listPackagesForUser", + "method": "GET", + "url": "/users/{username}/packages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists all packages in a user's namespace for which the requesting user has access.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-user", + "parameters": [ { - "name": "members_allowed_repository_creation_type", - "description": "Specifies which types of repositories non-admin organization members can create. `private` is only available to repositories that are part of an organization on GitHub Enterprise Cloud. \n**Note:** This parameter is deprecated and will be removed in the future. Its return value ignores internal repositories. Using this parameter overrides values set in `members_can_create_repositories`. See the parameter deprecation notice in the operation description for details.", - "in": "BODY", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "QUERY", "type": "string", - "required": false, - "enum": ["all", "private", "none"], + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29492,12 +34899,12 @@ "deprecated": null }, { - "name": "members_can_create_pages", - "description": "Whether organization members can create GitHub Pages sites. Existing published sites will not be impacted.", - "in": "BODY", - "type": "boolean", + "name": "visibility", + "description": "The selected visibility of the packages. This parameter is optional and only filters an existing result set.\n\nThe `internal` visibility is only supported for GitHub Packages registries that allow for granular permissions. For other ecosystems `internal` is synonymous with `private`.\nFor the list of GitHub Packages registries that support granular permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "in": "QUERY", + "type": "string", "required": false, - "enum": null, + "enum": ["public", "private", "internal"], "allowNull": false, "mapToData": null, "validation": null, @@ -29505,11 +34912,11 @@ "deprecated": null }, { - "name": "members_can_create_public_pages", - "description": "Whether organization members can create public GitHub Pages sites. Existing published sites will not be impacted.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29518,10 +34925,10 @@ "deprecated": null }, { - "name": "members_can_create_private_pages", - "description": "Whether organization members can create private GitHub Pages sites. Existing published sites will not be impacted.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29531,10 +34938,10 @@ "deprecated": null }, { - "name": "members_can_fork_private_repositories", - "description": "Whether organization members can fork private organization repositories.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -29542,27 +34949,38 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "web_commit_signoff_required", - "description": "Whether contributors to organization repositories are required to sign off on commits they make through GitHub's web interface.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 400, + "description": "The value of `per_page` multiplied by `page` cannot be greater than 10000." }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Restore a package for the authenticated user", + "scope": "packages", + "id": "restorePackageForAuthenticatedUser", + "method": "POST", + "url": "/user/packages/{package_type}/{package_name}/restore{?token}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Restores a package owned by the authenticated user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `write:packages` scopes. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-the-authenticated-user", + "parameters": [ { - "name": "blog", - "description": "", - "in": "BODY", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29570,11 +34988,11 @@ "deprecated": null }, { - "name": "advanced_security_enabled_for_new_repositories", - "description": "Whether GitHub Advanced Security is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29583,10 +35001,10 @@ "deprecated": null }, { - "name": "dependabot_alerts_enabled_for_new_repositories", - "description": "Whether Dependabot alerts is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", + "name": "token", + "description": "package token", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -29594,14 +35012,35 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Restore a package for an organization", + "scope": "packages", + "id": "restorePackageForOrg", + "method": "POST", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/restore{?token}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Restores an entire package in an organization.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `read:packages` and `write:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package you want to restore. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-an-organization", + "parameters": [ { - "name": "dependabot_security_updates_enabled_for_new_repositories", - "description": "Whether Dependabot security updates is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", + "type": "string", + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29609,11 +35048,11 @@ "deprecated": null }, { - "name": "dependency_graph_enabled_for_new_repositories", - "description": "Whether dependency graph is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29622,11 +35061,11 @@ "deprecated": null }, { - "name": "secret_scanning_enabled_for_new_repositories", - "description": "Whether secret scanning is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29635,10 +35074,10 @@ "deprecated": null }, { - "name": "secret_scanning_push_protection_enabled_for_new_repositories", - "description": "Whether secret scanning push protection is automatically enabled for new repositories.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nYou can check which security and analysis features are currently enabled by using a `GET /orgs/{org}` request.", - "in": "BODY", - "type": "boolean", + "name": "token", + "description": "package token", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -29649,31 +35088,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 409, "description": "Conflict" }, - { "code": 422, "description": "Validation failed" } + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Update a custom role", - "scope": "orgs", - "id": "updateCustomRole", - "method": "PATCH", - "url": "/orgs/{org}/custom_roles/{role_id}", + "name": "Restore a package for a user", + "scope": "packages", + "id": "restorePackageForUser", + "method": "POST", + "url": "/users/{username}/packages/{package_type}/{package_name}/restore{?token}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note**: This operation is in beta and subject to change.\n\nUpdates a custom repository role that can be used by all repositories owned by the organization.\n\nTo use this endpoint the authenticated user must be an administrator for the organization and must use an access token with `admin:org` scope.\nGitHub Apps must have the `organization_custom_roles:write` organization permission to use this endpoint.\n\nFor more information about custom repository roles, see \"[Managing custom repository roles for an organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-custom-repository-roles-for-an-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-a-custom-role", + "description": "Restores an entire package for a user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `write:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package you want to restore. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-a-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29681,24 +35121,11 @@ "deprecated": null }, { - "name": "role_id", - "description": "The unique identifier of the role.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "name", - "description": "The name of the custom role.", - "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29707,11 +35134,11 @@ "deprecated": null }, { - "name": "description", - "description": "A short description about who this role is for or what permissions it grants.", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29720,24 +35147,11 @@ "deprecated": null }, { - "name": "base_role", - "description": "The system role from which this role inherits permissions.", - "in": "BODY", + "name": "token", + "description": "package token", + "in": "QUERY", "type": "string", "required": false, - "enum": ["read", "triage", "write", "maintain"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "permissions", - "description": "A list of additional permissions included in this role. If specified, these permissions will replace any currently set on the role.", - "in": "BODY", - "type": "string[]", - "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -29747,34 +35161,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Update an organization membership for the authenticated user", - "scope": "orgs", - "id": "updateMembershipForAuthenticatedUser", - "method": "PATCH", - "url": "/user/memberships/orgs/{org}", + "name": "Restore a package version for the authenticated user", + "scope": "packages", + "id": "restorePackageVersionForAuthenticatedUser", + "method": "POST", + "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization-membership-for-the-authenticated-user", + "description": "Restores a package version owned by the authenticated user.\n\nYou can restore a deleted package version under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `write:packages` scopes. If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-the-authenticated-user", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29782,12 +35194,25 @@ "deprecated": null }, { - "name": "state", - "description": "The state that the membership should be in. Only `\"active\"` will be accepted.", - "in": "BODY", + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", "type": "string", "required": true, - "enum": ["active"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -29796,35 +35221,32 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Update an organization webhook", - "scope": "orgs", - "id": "updateWebhook", - "method": "PATCH", - "url": "/orgs/{org}/hooks/{hook_id}", + "name": "Restore package version for an organization", + "scope": "packages", + "id": "restorePackageVersionForOrg", + "method": "POST", + "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates a webhook configured in an organization. When you update a webhook, the `secret` will be overwritten. If you previously had a `secret` set, you must provide the same `secret` or set a new `secret` or the secret will be removed. If you are only updating individual webhook `config` properties, use \"[Update a webhook configuration for an organization](/rest/reference/orgs#update-a-webhook-configuration-for-an-organization).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-an-organization-webhook", + "description": "Restores a specific package version in an organization.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `read:packages` and `write:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package whose version you want to restore. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-an-organization", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", "in": "PATH", "type": "string", "required": true, - "enum": null, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], "allowNull": false, "mapToData": null, "validation": null, @@ -29832,10 +35254,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "package_name", + "description": "The name of the package.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -29845,11 +35267,11 @@ "deprecated": null }, { - "name": "config", - "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-hook-config-params).", - "in": "BODY", - "type": "object", - "required": false, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29858,10 +35280,10 @@ "deprecated": null }, { - "name": "config.url", - "description": "The URL to which the payloads will be delivered.", - "in": "BODY", - "type": "string", + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -29869,13 +35291,47 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Restore package version for a user", + "scope": "packages", + "id": "restorePackageVersionForUser", + "method": "POST", + "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Restores a specific package version for a user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` and `write:packages` scopes. In addition:\n- If the `package_type` belongs to a GitHub Packages registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"\n- If the `package_type` belongs to a GitHub Packages registry that supports granular permissions, you must have admin permissions to the package whose version you want to restore. For the list of these registries, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-a-user", + "parameters": [ + { + "name": "package_type", + "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "in": "PATH", + "type": "string", + "required": true, + "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "config.content_type", - "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", - "in": "BODY", + "name": "package_name", + "description": "The name of the package.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29884,11 +35340,11 @@ "deprecated": null }, { - "name": "config.secret", - "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", - "in": "BODY", + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29897,24 +35353,45 @@ "deprecated": null }, { - "name": "config.insecure_ssl", - "description": "", - "in": "BODY", - "type": null, - "required": false, + "name": "package_version_id", + "description": "Unique identifier of the package version.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Add project collaborator", + "scope": "projects", + "id": "addCollaborator", + "method": "PUT", + "url": "/projects/{project_id}/collaborators/{username}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Adds a collaborator to an organization project and sets their permission level. You must be an organization owner or a project `admin` to add a collaborator.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#add-project-collaborator", + "parameters": [ { - "name": "events", - "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "project_id", + "description": "The unique identifier of the project.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29923,11 +35400,11 @@ "deprecated": null }, { - "name": "active", - "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -29936,12 +35413,12 @@ "deprecated": null }, { - "name": "name", - "description": "", + "name": "permission", + "description": "The permission to grant the collaborator.", "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["read", "write", "admin"], "allowNull": false, "mapToData": null, "validation": null, @@ -29950,7 +35427,10 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, { "code": 422, @@ -29960,22 +35440,22 @@ "renamed": null }, { - "name": "Update a webhook configuration for an organization", - "scope": "orgs", - "id": "updateWebhookConfigForOrg", - "method": "PATCH", - "url": "/orgs/{org}/hooks/{hook_id}/config", + "name": "Create a project card", + "scope": "projects", + "id": "createCard", + "method": "POST", + "url": "/projects/columns/{column_id}/cards", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates the webhook configuration for an organization. To update more information about the webhook, including the `active` state and `events`, use \"[Update an organization webhook ](/rest/reference/orgs#update-an-organization-webhook).\"\n\nAccess tokens must have the `admin:org_hook` scope, and GitHub Apps must have the `organization_hooks:write` permission.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/orgs#update-a-webhook-configuration-for-an-organization", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-project-card", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "column_id", + "description": "The unique identifier of the column.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -29985,9 +35465,22 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", + "name": "note", + "description": "The project card's note", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "content_id", + "description": "The unique identifier of the content associated with the card", + "in": "BODY", "type": "integer", "required": true, "enum": null, @@ -29998,11 +35491,47 @@ "deprecated": null }, { - "name": "url", - "description": "The URL to which the payloads will be delivered.", + "name": "content_type", + "description": "The piece of content associated with the card", "in": "BODY", "type": "string", - "required": false, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 422, "description": "Validation failed" }, + { "code": 503, "description": "Response" } + ], + "renamed": null + }, + { + "name": "Create a project column", + "scope": "projects", + "id": "createColumn", + "method": "POST", + "url": "/projects/{project_id}/columns", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a new project column.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-project-column", + "parameters": [ + { + "name": "project_id", + "description": "The unique identifier of the project.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -30011,24 +35540,49 @@ "deprecated": null }, { - "name": "content_type", - "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", + "name": "name", + "description": "Name of the project column", "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { - "name": "secret", - "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a user project", + "scope": "projects", + "id": "createForAuthenticatedUser", + "method": "POST", + "url": "/user/projects", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a user project board. Returns a `410 Gone` status if the user does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-user-project", + "parameters": [ + { + "name": "name", + "description": "Name of the project", "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -30037,41 +35591,50 @@ "deprecated": null }, { - "name": "insecure_ssl", - "description": "", + "name": "body", + "description": "Body of the project", "in": "BODY", - "type": null, + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Delete a package for the authenticated user", - "scope": "packages", - "id": "deletePackageForAuthenticatedUser", - "method": "DELETE", - "url": "/user/packages/{package_type}/{package_name}", + "name": "Create an organization project", + "scope": "projects", + "id": "createForOrg", + "method": "POST", + "url": "/orgs/{org}/projects", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a package owned by the authenticated user. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:delete` scopes.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-the-authenticated-user", + "description": "Creates an organization project board. Returns a `410 Gone` status if projects are disabled in the organization or if the organization does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-an-organization-project", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30079,9 +35642,9 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "name", + "description": "The name of the project.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -30090,35 +35653,53 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "body", + "description": "The description of the project.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 201, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Delete a package for an organization", - "scope": "packages", - "id": "deletePackageForOrg", - "method": "DELETE", - "url": "/orgs/{org}/packages/{package_type}/{package_name}", + "name": "Create a repository project", + "scope": "projects", + "id": "createForRepo", + "method": "POST", + "url": "/repos/{owner}/{repo}/projects", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes an entire package in an organization. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `packages:read` and `packages:delete` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container you want to delete.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-an-organization", + "description": "Creates a repository project board. Returns a `410 Gone` status if projects are disabled in the repository or if the repository does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-repository-project", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30126,8 +35707,8 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -30139,11 +35720,24 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the project.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "body", + "description": "The description of the project.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -30153,43 +35747,35 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 201, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Delete a package for a user", - "scope": "packages", - "id": "deletePackageForUser", + "name": "Delete a project", + "scope": "projects", + "id": "delete", "method": "DELETE", - "url": "/users/{username}/packages/{package_type}/{package_name}", + "url": "/projects/{project_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes an entire package for a user. You cannot delete a public package if any version of the package has more than 5,000 downloads. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:delete` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container you want to delete.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-for-a-user", + "description": "Deletes a project board. Returns a `404 Not Found` status if projects are disabled.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30197,12 +35783,35 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Delete Success" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" } + ], + "renamed": null + }, + { + "name": "Delete a project card", + "scope": "projects", + "id": "deleteCard", + "method": "DELETE", + "url": "/projects/columns/cards/{card_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a project card", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project-card", + "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "card_id", + "description": "The unique identifier of the card.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30214,6 +35823,7 @@ ], "responses": [ { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } @@ -30221,35 +35831,56 @@ "renamed": null }, { - "name": "Delete a package version for the authenticated user", - "scope": "packages", - "id": "deletePackageVersionForAuthenticatedUser", + "name": "Delete a project column", + "scope": "projects", + "id": "deleteColumn", "method": "DELETE", - "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}", + "url": "/projects/columns/{column_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a specific package version for a package owned by the authenticated user. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `packages:read` and `packages:delete` scopes.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-the-authenticated-user", + "description": "Deletes a project column.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project-column", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "column_id", + "description": "The unique identifier of the column.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Get a project", + "scope": "projects", + "id": "get", + "method": "GET", + "url": "/projects/{project_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets a project by its `id`. Returns a `404 Not Found` status if projects are disabled. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project", + "parameters": [ { - "name": "package_name", - "description": "The name of the package.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30257,10 +35888,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Get a project card", + "scope": "projects", + "id": "getCard", + "method": "GET", + "url": "/projects/columns/cards/{card_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets information about a project card.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project-card", + "parameters": [ { - "name": "package_version_id", - "description": "Unique identifier of the package version.", + "name": "card_id", + "description": "The unique identifier of the card.", "in": "PATH", "type": "integer", "required": true, @@ -30273,7 +35925,8 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } @@ -30281,35 +35934,22 @@ "renamed": null }, { - "name": "Delete package version for an organization", - "scope": "packages", - "id": "deletePackageVersionForOrg", - "method": "DELETE", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}", + "name": "Get a project column", + "scope": "projects", + "id": "getColumn", + "method": "GET", + "url": "/projects/columns/{column_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a specific package version in an organization. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `packages:read` and `packages:delete` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container you want to delete.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-an-organization", + "description": "Gets information about a project column.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project-column", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "column_id", + "description": "The unique identifier of the column.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30317,12 +35957,34 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get project permission for a user", + "scope": "projects", + "id": "getPermissionForUser", + "method": "GET", + "url": "/projects/{project_id}/collaborators/{username}/permission", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns the collaborator's permission level for an organization project. Possible values for the `permission` key: `admin`, `write`, `read`, `none`. You must be an organization owner or a project `admin` to review a user's permission level.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-project-permission-for-a-user", + "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30332,10 +35994,10 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -30346,32 +36008,37 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Delete package version for a user", - "scope": "packages", - "id": "deletePackageVersionForUser", - "method": "DELETE", - "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}", + "name": "List project cards", + "scope": "projects", + "id": "listCards", + "method": "GET", + "url": "/projects/columns/{column_id}/cards", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a specific package version for a user. If the package is public and the package version has more than 5,000 downloads, you cannot delete the package version. In this scenario, contact GitHub support for further assistance.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:delete` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container you want to delete.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#delete-a-package-version-for-a-user", + "description": "Lists the project cards in a project.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-cards", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "column_id", + "description": "The unique identifier of the column.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30379,12 +36046,12 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "archived_state", + "description": "Filters the project cards that are returned by the card's state.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["all", "archived", "not_archived"], "allowNull": false, "mapToData": null, "validation": null, @@ -30392,11 +36059,11 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -30405,11 +36072,11 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -30419,56 +36086,30 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "List package versions for a package owned by an organization", - "scope": "packages", - "id": "getAllPackageVersionsForAPackageOwnedByAnOrg", + "name": "List project collaborators", + "scope": "projects", + "id": "listCollaborators", "method": "GET", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions", + "url": "/projects/{project_id}/collaborators", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists package versions for a package owned by an organization.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-an-organization", + "description": "Lists the collaborators for an organization project. For a project, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners. You must be an organization owner or a project `admin` to list collaborators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-collaborators", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30478,12 +36119,12 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "affiliation", + "description": "Filters the collaborators by their affiliation. `outside` means outside collaborators of a project that are not a member of the project's organization. `direct` means collaborators with permissions to a project, regardless of organization membership status. `all` means all collaborators the authenticated user can see.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["outside", "direct", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -30504,12 +36145,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the package, either active or deleted.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["active", "deleted"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30519,67 +36160,35 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], - "renamed": { - "before": { - "scope": "packages", - "id": "getAllPackageVersionsForAPackageOwnedByAnOrg" - }, - "after": { - "scope": "packages", - "id": "getAllPackageVersionsForPackageOwnedByOrg" - }, - "date": "2021-03-24", - "note": null - } + "renamed": null }, { - "name": "List package versions for a package owned by the authenticated user", - "scope": "packages", - "id": "getAllPackageVersionsForAPackageOwnedByTheAuthenticatedUser", + "name": "List project columns", + "scope": "projects", + "id": "listColumns", "method": "GET", - "url": "/user/packages/{package_type}/{package_name}/versions", + "url": "/projects/{project_id}/columns", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists package versions for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-the-authenticated-user", + "description": "Lists the project columns in a project.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-columns", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -30601,12 +36210,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the package, either active or deleted.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["active", "deleted"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30616,51 +36225,27 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 403, "description": "Forbidden" } ], - "renamed": { - "before": { - "scope": "packages", - "id": "getAllPackageVersionsForAPackageOwnedByTheAuthenticatedUser" - }, - "after": { - "scope": "packages", - "id": "getAllPackageVersionsForPackageOwnedByAuthenticatedUser" - }, - "date": "2021-03-24", - "note": null - } + "renamed": null }, { - "name": "List package versions for a package owned by the authenticated user", - "scope": "packages", - "id": "getAllPackageVersionsForPackageOwnedByAuthenticatedUser", + "name": "List organization projects", + "scope": "projects", + "id": "listForOrg", "method": "GET", - "url": "/user/packages/{package_type}/{package_name}/versions", + "url": "/orgs/{org}/projects", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists package versions for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-the-authenticated-user", + "description": "Lists the projects in an organization. Returns a `404 Not Found` status if projects are disabled in the organization. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-organization-projects", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -30672,12 +36257,12 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "state", + "description": "Indicates the state of the projects to return.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -30698,12 +36283,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the package, either active or deleted.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["active", "deleted"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30713,40 +36298,28 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List package versions for a package owned by an organization", - "scope": "packages", - "id": "getAllPackageVersionsForPackageOwnedByOrg", + "name": "List repository projects", + "scope": "projects", + "id": "listForRepo", "method": "GET", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions", + "url": "/repos/{owner}/{repo}/projects", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists package versions for a package owned by an organization.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-an-organization", + "description": "Lists the projects in a repository. Returns a `404 Not Found` status if projects are disabled in the repository. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-repository-projects", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -30758,8 +36331,8 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -30771,12 +36344,12 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "state", + "description": "Indicates the state of the projects to return.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -30797,12 +36370,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the package, either active or deleted.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": ["active", "deleted"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30814,29 +36387,34 @@ { "code": 200, "description": "Response" }, { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List package versions for a package owned by a user", - "scope": "packages", - "id": "getAllPackageVersionsForPackageOwnedByUser", + "name": "List user projects", + "scope": "projects", + "id": "listForUser", "method": "GET", - "url": "/users/{username}/packages/{package_type}/{package_name}/versions", + "url": "/users/{username}/projects", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists package versions for a public package owned by a specified user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/packages#get-all-package-versions-for-a-package-owned-by-a-user", + "description": "Lists projects for a user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-user-projects", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30844,11 +36422,24 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "state", + "description": "Indicates the state of the projects to return.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, + "enum": ["open", "closed", "all"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -30857,11 +36448,11 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -30872,31 +36463,32 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get a package for the authenticated user", - "scope": "packages", - "id": "getPackageForAuthenticatedUser", - "method": "GET", - "url": "/user/packages/{package_type}/{package_name}", + "name": "Move a project card", + "scope": "projects", + "id": "moveCard", + "method": "POST", + "url": "/projects/columns/cards/{card_id}/moves", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific package for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-the-authenticated-user", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#move-a-project-card", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "card_id", + "description": "The unique identifier of the card.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -30904,52 +36496,62 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "position", + "description": "The position of the card in a column. Can be one of: `top`, `bottom`, or `after:` to place after the specified card.", + "in": "BODY", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, + "validation": "^(?:top|bottom|after:\\d+)$", + "alias": null, + "deprecated": null + }, + { + "name": "column_id", + "description": "The unique identifier of the column the card should be moved to", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, "validation": null, "alias": null, "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 503, "description": "Response" } + ], "renamed": null }, { - "name": "Get a package for an organization", - "scope": "packages", - "id": "getPackageForOrganization", - "method": "GET", - "url": "/orgs/{org}/packages/{package_type}/{package_name}", + "name": "Move a project column", + "scope": "projects", + "id": "moveColumn", + "method": "POST", + "url": "/projects/columns/{column_id}/moves", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific package in an organization.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-an-organization", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#move-a-project-column", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "column_id", + "description": "The unique identifier of the column.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -30959,52 +36561,48 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "position", + "description": "The position of the column in a project. Can be one of: `first`, `last`, or `after:` to place after the specified column.", + "in": "BODY", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": null, + "validation": "^(?:first|last|after:\\d+)$", "alias": null, "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get a package for a user", - "scope": "packages", - "id": "getPackageForUser", - "method": "GET", - "url": "/users/{username}/packages/{package_type}/{package_name}", + "name": "Remove user as a collaborator", + "scope": "projects", + "id": "removeCollaborator", + "method": "DELETE", + "url": "/projects/{project_id}/collaborators/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific package metadata for a public package owned by a user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-for-a-user", + "description": "Removes a collaborator from an organization project. You must be an organization owner or a project `admin` to remove a collaborator.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#remove-project-collaborator", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", - "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "package_name", - "description": "The name of the package.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -31027,28 +36625,38 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get a package version for the authenticated user", - "scope": "packages", - "id": "getPackageVersionForAuthenticatedUser", - "method": "GET", - "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}", + "name": "Update a project", + "scope": "projects", + "id": "update", + "method": "PATCH", + "url": "/projects/{project_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific package version for a package owned by the authenticated user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-the-authenticated-user", + "description": "Updates a project board's information. Returns a `404 Not Found` status if projects are disabled. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "project_id", + "description": "The unique identifier of the project.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31056,11 +36664,11 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "name", + "description": "Name of the project", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31069,53 +36677,24 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a package version for an organization", - "scope": "packages", - "id": "getPackageVersionForOrganization", - "method": "GET", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets a specific package version in an organization.\n\nYou must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-an-organization", - "parameters": [ - { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", + "name": "body", + "description": "Body of the project", + "in": "BODY", "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], - "allowNull": false, + "required": false, + "enum": null, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "state", + "description": "State of the project; either 'open' or 'closed'", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31124,12 +36703,12 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "organization_permission", + "description": "The baseline permission that all organization members have on this project", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["read", "write", "admin", "none"], "allowNull": false, "mapToData": null, "validation": null, @@ -31137,11 +36716,11 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "private", + "description": "Whether or not this project can be seen by everyone.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31150,28 +36729,42 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 404, + "description": "Not Found if the authenticated user does not have access to the project" + }, + { "code": 410, "description": "Gone" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Get a package version for a user", - "scope": "packages", - "id": "getPackageVersionForUser", - "method": "GET", - "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}", + "name": "Update an existing project card", + "scope": "projects", + "id": "updateCard", + "method": "PATCH", + "url": "/projects/columns/cards/{card_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a specific package version for a public package owned by a specified user.\n\nAt this time, to use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#get-a-package-version-for-a-user", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project-card", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "card_id", + "description": "The unique identifier of the card.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31179,67 +36772,64 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "note", + "description": "The project card's note", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "archived", + "description": "Whether or not the card is archived", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List packages for the authenticated user's namespace", - "scope": "packages", - "id": "listPackagesForAuthenticatedUser", - "method": "GET", - "url": "/user/packages", + "name": "Update an existing project column", + "scope": "projects", + "id": "updateColumn", + "method": "PATCH", + "url": "/projects/columns/{column_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists packages owned by the authenticated user within the user's namespace.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-the-authenticated-user", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project-column", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "QUERY", - "type": "string", + "name": "column_id", + "description": "The unique identifier of the column.", + "in": "PATH", + "type": "integer", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31247,12 +36837,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "The selected visibility of the packages. Only `container` package_types currently support `internal` visibility properly. For other ecosystems `internal` is synonymous with `private`. This parameter is optional and only filters an existing result set.", - "in": "QUERY", + "name": "name", + "description": "Name of the project column", + "in": "BODY", "type": "string", - "required": false, - "enum": ["public", "private", "internal"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31260,28 +36850,33 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], "renamed": null }, { - "name": "List packages for an organization", - "scope": "packages", - "id": "listPackagesForOrganization", + "name": "Check if a pull request has been merged", + "scope": "pulls", + "id": "checkIfMerged", "method": "GET", - "url": "/orgs/{org}/packages", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/merge", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all packages in an organization readable by the user.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-an-organization", + "description": "Checks if a pull request has been merged into the base branch. The HTTP status of the response indicates whether or not the pull request has been merged; the response body is empty.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#check-if-a-pull-request-has-been-merged", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31289,8 +36884,8 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -31302,12 +36897,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "The selected visibility of the packages. Only `container` package_types currently support `internal` visibility properly. For other ecosystems `internal` is synonymous with `private`. This parameter is optional and only filters an existing result set.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["public", "private", "internal"], + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31316,31 +36911,49 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { + "code": 204, + "description": "Response if pull request has been merged" + }, + { + "code": 404, + "description": "Not Found if pull request has not been merged" + } ], "renamed": null }, { - "name": "List packages for a user", - "scope": "packages", - "id": "listPackagesForUser", - "method": "GET", - "url": "/users/{username}/packages", + "name": "Create a pull request", + "scope": "pulls", + "id": "create", + "method": "POST", + "url": "/repos/{owner}/{repo}/pulls", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all packages in a user's namespace for which the requesting user has access.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` scope.\nIf `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-user", + "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-pull-request", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31348,12 +36961,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "The selected visibility of the packages. Only `container` package_types currently support `internal` visibility properly. For other ecosystems `internal` is synonymous with `private`. This parameter is optional and only filters an existing result set.", - "in": "QUERY", + "name": "title", + "description": "The title of the new pull request. Required unless `issue` is specified.", + "in": "BODY", "type": "string", "required": false, - "enum": ["public", "private", "internal"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31361,9 +36974,9 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "head", + "description": "The name of the branch where your changes are implemented. For cross-repository pull requests in the same network, namespace `head` with a user like this: `username:branch`.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -31372,34 +36985,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Restore a package for the authenticated user", - "scope": "packages", - "id": "restorePackageForAuthenticatedUser", - "method": "POST", - "url": "/user/packages/{package_type}/{package_name}/restore{?token}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Restores a package owned by the authenticated user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:write` scopes. If `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-the-authenticated-user", - "parameters": [ + }, { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", + "name": "head_repo", + "description": "The name of the repository where the changes in the pull request were made. This field is required for cross-repository pull requests if both repositories are owned by the same organization.", + "in": "BODY", "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31407,9 +37000,9 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "base", + "description": "The name of the branch you want the changes pulled into. This should be an existing branch on the current repository. You cannot submit a pull request to one repository that requests a merge to a base of another repository.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -31420,9 +37013,9 @@ "deprecated": null }, { - "name": "token", - "description": "package token", - "in": "QUERY", + "name": "body", + "description": "The contents of the pull request.", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -31431,35 +37024,76 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "maintainer_can_modify", + "description": "Indicates whether [maintainers can modify](https://docs.github.com/enterprise-cloud@latest//articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork/) the pull request.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "draft", + "description": "Indicates whether the pull request is a draft. See \"[Draft Pull Requests](https://docs.github.com/enterprise-cloud@latest//articles/about-pull-requests#draft-pull-requests)\" in the GitHub Help documentation to learn more.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "issue", + "description": "An issue in the repository to convert to a pull request. The issue title, body, and comments will become the title, body, and comments on the new pull request. Required unless `title` is specified.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 201, "description": "Response" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Restore a package for an organization", - "scope": "packages", - "id": "restorePackageForOrg", + "name": "Create a reply for a review comment", + "scope": "pulls", + "id": "createReplyForReviewComment", "method": "POST", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/restore{?token}", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments/{comment_id}/replies", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Restores an entire package in an organization.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `packages:read` and `packages:write` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container that you want to restore.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-an-organization", + "description": "Creates a reply to a review comment for a pull request. For the `comment_id`, provide the ID of the review comment you are replying to. This must be the ID of a _top-level review comment_, not a reply to that comment. Replies to replies are not supported.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-reply-for-a-review-comment", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31467,8 +37101,8 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -31480,10 +37114,10 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -31493,11 +37127,24 @@ "deprecated": null }, { - "name": "token", - "description": "package token", - "in": "QUERY", + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "body", + "description": "The text of the review comment.", + "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -31507,32 +37154,30 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, + { "code": 201, "description": "Response" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Restore a package for a user", - "scope": "packages", - "id": "restorePackageForUser", + "name": "Create a review for a pull request", + "scope": "pulls", + "id": "createReview", "method": "POST", - "url": "/users/{username}/packages/{package_type}/{package_name}/restore{?token}", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Restores an entire package for a user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:write` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container that you want to restore.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-for-a-user", + "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\nPull request reviews created in the `PENDING` state are not submitted and therefore do not include the `submitted_at` property in the response. To create a pending review for a pull request, leave the `event` parameter blank. For more information about submitting a `PENDING` review, see \"[Submit a review for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls#submit-a-review-for-a-pull-request).\"\n\n**Note:** To comment on a specific line in a file, you need to first determine the _position_ of that line in the diff. The GitHub REST API offers the `application/vnd.github.v3.diff` [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types#commits-commit-comparison-and-pull-requests). To see a pull request diff, add this media type to the `Accept` header of a call to the [single pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) endpoint.\n\nThe `position` value equals the number of lines down from the first \"@@\" hunk header in the file you want to add a comment. The line just below the \"@@\" line is position 1, the next line is position 2, and so on. The position in the diff continues to increase through lines of whitespace and additional hunks until the beginning of a new file.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-review-for-a-pull-request", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31540,8 +37185,8 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -31553,10 +37198,10 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -31566,9 +37211,9 @@ "deprecated": null }, { - "name": "token", - "description": "package token", - "in": "QUERY", + "name": "commit_id", + "description": "The SHA of the commit that needs a review. Not using the latest commit SHA may render your review comment outdated if a subsequent commit modifies the line you specify as the `position`. Defaults to the most recent commit in the pull request when you do not specify a value.", + "in": "BODY", "type": "string", "required": false, "enum": null, @@ -31577,35 +37222,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Restore a package version for the authenticated user", - "scope": "packages", - "id": "restorePackageVersionForAuthenticatedUser", - "method": "POST", - "url": "/user/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Restores a package version owned by the authenticated user.\n\nYou can restore a deleted package version under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:write` scopes. If `package_type` is not `container`, your token must also include the `repo` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-the-authenticated-user", - "parameters": [ + }, { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", + "name": "body", + "description": "**Required** when using `REQUEST_CHANGES` or `COMMENT` for the `event` parameter. The body text of the pull request review.", + "in": "BODY", "type": "string", - "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31613,9 +37237,35 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", + "name": "event", + "description": "The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/enterprise-cloud@latest//rest/pulls#submit-a-review-for-a-pull-request) when you are ready.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["APPROVE", "REQUEST_CHANGES", "COMMENT"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "comments", + "description": "Use the following table to specify the location, destination, and contents of the draft review comment.", + "in": "BODY", + "type": "object[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "comments[].path", + "description": "The relative path to the file that necessitates a review comment.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -31626,46 +37276,25 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", + "name": "comments[].position", + "description": "The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note below.", + "in": "BODY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Restore package version for an organization", - "scope": "packages", - "id": "restorePackageVersionForOrg", - "method": "POST", - "url": "/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Restores a specific package version in an organization.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must have admin permissions in the organization and authenticate using an access token with the `packages:read` and `packages:write` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container that you want to restore.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-an-organization", - "parameters": [ + }, { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", - "in": "PATH", + "name": "comments[].body", + "description": "Text of the review comment.", + "in": "BODY", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31673,11 +37302,11 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", - "in": "PATH", - "type": "string", - "required": true, + "name": "comments[].line", + "description": "", + "in": "BODY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31686,11 +37315,11 @@ "deprecated": null }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "comments[].side", + "description": "", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31699,11 +37328,24 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", + "name": "comments[].start_line", + "description": "", + "in": "BODY", "type": "integer", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "comments[].start_side", + "description": "", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31713,32 +37355,34 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, + { "code": 200, "description": "Response" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Restore package version for a user", - "scope": "packages", - "id": "restorePackageVersionForUser", + "name": "Create a review comment for a pull request", + "scope": "pulls", + "id": "createReviewComment", "method": "POST", - "url": "/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}/restore", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Restores a specific package version for a user.\n\nYou can restore a deleted package under the following conditions:\n - The package was deleted within the last 30 days.\n - The same package namespace and version is still available and not reused for a new package. If the same package namespace is not available, you will not be able to restore your package. In this scenario, to restore the deleted package, you must delete the new package that uses the deleted package's namespace first.\n\nTo use this endpoint, you must authenticate using an access token with the `packages:read` and `packages:write` scopes. In addition:\n- If `package_type` is not `container`, your token must also include the `repo` scope.\n- If `package_type` is `container`, you must also have admin permissions to the container that you want to restore.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#restore-a-package-version-for-a-user", + "description": "\nCreates a review comment in the pull request diff. To add a regular comment to a pull request timeline, see \"[Create an issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue-comment).\" We recommend creating a review comment using `line`, `side`, and optionally `start_line` and `start_side` if your comment applies to more than one line in the pull request diff.\n\nThe `position` parameter is deprecated. If you use `position`, the `line`, `side`, `start_line`, and `start_side` parameters are not required.\n\n**Note:** The position value equals the number of lines down from the first \"@@\" hunk header in the file you want to add a comment. The line just below the \"@@\" line is position 1, the next line is position 2, and so on. The position in the diff continues to increase through lines of whitespace and additional hunks until the beginning of a new file.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-review-comment-for-a-pull-request", "parameters": [ { - "name": "package_type", - "description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, - "enum": ["npm", "maven", "rubygems", "docker", "nuget", "container"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -31746,8 +37390,8 @@ "deprecated": null }, { - "name": "package_name", - "description": "The name of the package.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -31759,10 +37403,10 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -31772,10 +37416,10 @@ "deprecated": null }, { - "name": "package_version_id", - "description": "Unique identifier of the package version.", - "in": "PATH", - "type": "integer", + "name": "body", + "description": "The text of the review comment.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -31783,33 +37427,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Add project collaborator", - "scope": "projects", - "id": "addCollaborator", - "method": "PUT", - "url": "/projects/{project_id}/collaborators/{username}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Adds a collaborator to an organization project and sets their permission level. You must be an organization owner or a project `admin` to add a collaborator.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#add-project-collaborator", - "parameters": [ + }, { - "name": "project_id", - "description": "The unique identifier of the project.", - "in": "PATH", - "type": "integer", + "name": "commit_id", + "description": "The SHA of the commit needing a comment. Not using the latest commit SHA may render your comment outdated if a subsequent commit modifies the line you specify as the `position`.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -31819,9 +37442,9 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "path", + "description": "The relative path to the file that necessitates a comment.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -31832,50 +37455,50 @@ "deprecated": null }, { - "name": "permission", - "description": "The permission to grant the collaborator.", + "name": "position", + "description": "**This parameter is deprecated. Use `line` instead**. The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note above.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "side", + "description": "In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see \"[Diff view options](https://docs.github.com/enterprise-cloud@latest//articles/about-comparing-branches-in-pull-requests#diff-view-options)\" in the GitHub Help documentation.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write", "admin"], + "enum": ["LEFT", "RIGHT"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a project card", - "scope": "projects", - "id": "createCard", - "method": "POST", - "url": "/projects/columns/{column_id}/cards", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-project-card", - "parameters": [ + "name": "line", + "description": "**Required unless using `subject_type:file`**. The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { - "name": "column_id", - "description": "The unique identifier of the column.", - "in": "PATH", + "name": "start_line", + "description": "**Required when using multi-line comments unless using `in_reply_to`**. The `start_line` is the first line in the pull request diff that your multi-line comment applies to. To learn more about multi-line comments, see \"[Commenting on a pull request](https://docs.github.com/enterprise-cloud@latest//articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)\" in the GitHub Help documentation.", + "in": "BODY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31884,24 +37507,24 @@ "deprecated": null }, { - "name": "note", - "description": "The project card's note", + "name": "start_side", + "description": "**Required when using multi-line comments unless using `in_reply_to`**. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see \"[Commenting on a pull request](https://docs.github.com/enterprise-cloud@latest//articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)\" in the GitHub Help documentation. See `side` in this table for additional context.", "in": "BODY", "type": "string", - "required": true, - "enum": null, - "allowNull": true, + "required": false, + "enum": ["LEFT", "RIGHT", "side"], + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "content_id", - "description": "The unique identifier of the content associated with the card", + "name": "in_reply_to", + "description": "The ID of the review comment to reply to. To find the ID of a review comment with [\"List review comments on a pull request\"](#list-review-comments-on-a-pull-request). When specified, all parameters other than `body` in the request body are ignored.", "in": "BODY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -31910,12 +37533,12 @@ "deprecated": null }, { - "name": "content_type", - "description": "The piece of content associated with the card", + "name": "subject_type", + "description": "The level at which the comment is targeted.", "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["LINE", "FILE"], "allowNull": false, "mapToData": null, "validation": null, @@ -31925,31 +37548,31 @@ ], "responses": [ { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, - { "code": 422, "description": "Validation failed" }, - { "code": 503, "description": "Response" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Create a project column", - "scope": "projects", - "id": "createColumn", - "method": "POST", - "url": "/projects/{project_id}/columns", + "name": "Delete a pending review for a pull request", + "scope": "pulls", + "id": "deletePendingReview", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-project-column", + "description": "Deletes a pull request review that has not been submitted. Submitted reviews cannot be deleted.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#delete-a-pending-review-for-a-pull-request", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -31959,9 +37582,9 @@ "deprecated": null }, { - "name": "name", - "description": "Name of the project column", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -31970,37 +37593,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a user project", - "scope": "projects", - "id": "createForAuthenticatedUser", - "method": "POST", - "url": "/user/projects", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Creates a user project board. Returns a `410 Gone` status if the user does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-user-project", - "parameters": [ + }, { - "name": "name", - "description": "Name of the project", - "in": "BODY", - "type": "string", + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -32010,13 +37608,13 @@ "deprecated": null }, { - "name": "body", - "description": "Body of the project", - "in": "BODY", - "type": "string", - "required": false, + "name": "review_id", + "description": "The unique identifier of the review.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, @@ -32024,10 +37622,8 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -32036,20 +37632,20 @@ "renamed": null }, { - "name": "Create an organization project", - "scope": "projects", - "id": "createForOrg", - "method": "POST", - "url": "/orgs/{org}/projects", + "name": "Delete a review comment for a pull request", + "scope": "pulls", + "id": "deleteReviewComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates an organization project board. Returns a `410 Gone` status if projects are disabled in the organization or if the organization does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-an-organization-project", + "description": "Deletes a review comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#delete-a-review-comment-for-a-pull-request", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32061,9 +37657,9 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the project.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -32074,11 +37670,11 @@ "deprecated": null }, { - "name": "body", - "description": "The description of the project.", - "in": "BODY", - "type": "string", - "required": false, + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -32088,29 +37684,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a repository project", - "scope": "projects", - "id": "createForRepo", - "method": "POST", - "url": "/repos/{owner}/{repo}/projects", + "name": "Dismiss a review for a pull request", + "scope": "pulls", + "id": "dismissReview", + "method": "PUT", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/dismissals", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a repository project board. Returns a `410 Gone` status if projects are disabled in the repository or if the repository does not have existing classic projects. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#create-a-repository-project", + "description": "**Note:** To dismiss a pull request review on a [protected branch](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#branches), you must be a repository administrator or be included in the list of people or teams who can dismiss pull request reviews.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#dismiss-a-review-for-a-pull-request", "parameters": [ { "name": "owner", @@ -32127,7 +37716,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32139,8 +37728,34 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the project.", + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "review_id", + "description": "The unique identifier of the review.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "message", + "description": "The message for the pull request review dismissal", "in": "BODY", "type": "string", "required": true, @@ -32152,12 +37767,12 @@ "deprecated": null }, { - "name": "body", - "description": "The description of the project.", + "name": "event", + "description": "", "in": "BODY", "type": "string", "required": false, - "enum": null, + "enum": ["DISMISS"], "allowNull": false, "mapToData": null, "validation": null, @@ -32166,11 +37781,8 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, + { "code": 200, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -32179,22 +37791,22 @@ "renamed": null }, { - "name": "Delete a project", - "scope": "projects", - "id": "delete", - "method": "DELETE", - "url": "/projects/{project_id}", + "name": "Get a pull request", + "scope": "pulls", + "id": "get", + "method": "GET", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a project board. Returns a `404 Not Found` status if projects are disabled.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project", + "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists details of a pull request by providing its number.\n\nWhen you get, [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls/#create-a-pull-request), or [edit](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-pull-request) a pull request, GitHub Enterprise Cloud creates a merge commit to test whether the pull request can be automatically merged into the base branch. This test commit is not added to the base branch or the head branch. You can review the status of the test commit using the `mergeable` key. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".\n\nThe value of the `mergeable` attribute can be `true`, `false`, or `null`. If the value is `null`, then GitHub Enterprise Cloud has started a background job to compute the mergeability. After giving the job time to complete, resubmit the request. When the job finishes, you will see a non-`null` value for the `mergeable` attribute in the response. If `mergeable` is `true`, then `merge_commit_sha` will be the SHA of the _test_ merge commit.\n\nThe value of the `merge_commit_sha` attribute changes depending on the state of the pull request. Before merging a pull request, the `merge_commit_sha` attribute holds the SHA of the _test_ merge commit. After merging a pull request, the `merge_commit_sha` attribute changes depending on how you merged the pull request:\n\n* If merged as a [merge commit](https://docs.github.com/enterprise-cloud@latest//articles/about-merge-methods-on-github/), `merge_commit_sha` represents the SHA of the merge commit.\n* If merged via a [squash](https://docs.github.com/enterprise-cloud@latest//articles/about-merge-methods-on-github/#squashing-your-merge-commits), `merge_commit_sha` represents the SHA of the squashed commit on the base branch.\n* If [rebased](https://docs.github.com/enterprise-cloud@latest//articles/about-merge-methods-on-github/#rebasing-and-merging-your-commits), `merge_commit_sha` represents the commit that the base branch was updated to.\n\nPass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32202,35 +37814,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Delete Success" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } - ], - "renamed": null - }, - { - "name": "Delete a project card", - "scope": "projects", - "id": "deleteCard", - "method": "DELETE", - "url": "/projects/columns/cards/{card_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project-card", - "parameters": [ + }, { - "name": "card_id", - "description": "The unique identifier of the card.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32238,32 +37827,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Delete a project column", - "scope": "projects", - "id": "deleteColumn", - "method": "DELETE", - "url": "/projects/columns/{column_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#delete-a-project-column", - "parameters": [ + }, { - "name": "column_id", - "description": "The unique identifier of the column.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", "type": "integer", "required": true, @@ -32276,30 +37843,34 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { + "code": 200, + "description": "Pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats." + }, { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Get a project", - "scope": "projects", - "id": "get", + "name": "Get a review for a pull request", + "scope": "pulls", + "id": "getReview", "method": "GET", - "url": "/projects/{project_id}", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a project by its `id`. Returns a `404 Not Found` status if projects are disabled. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project", + "description": "Retrieves a pull request review by its ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-review-for-a-pull-request", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32307,31 +37878,23 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Get a project card", - "scope": "projects", - "id": "getCard", - "method": "GET", - "url": "/projects/columns/cards/{card_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project-card", - "parameters": [ + }, { - "name": "card_id", - "description": "The unique identifier of the card.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", "type": "integer", "required": true, @@ -32341,32 +37904,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get a project column", - "scope": "projects", - "id": "getColumn", - "method": "GET", - "url": "/projects/columns/{column_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-a-project-column", - "parameters": [ + }, { - "name": "column_id", - "description": "The unique identifier of the column.", + "name": "review_id", + "description": "The unique identifier of the review.", "in": "PATH", "type": "integer", "required": true, @@ -32380,30 +37921,27 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get project permission for a user", - "scope": "projects", - "id": "getPermissionForUser", + "name": "Get a review comment for a pull request", + "scope": "pulls", + "id": "getReviewComment", "method": "GET", - "url": "/projects/{project_id}/collaborators/{username}/permission", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the collaborator's permission level for an organization project. Possible values for the `permission` key: `admin`, `write`, `read`, `none`. You must be an organization owner or a project `admin` to review a user's permission level.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#get-project-permission-for-a-user", + "description": "Provides details for a review comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-review-comment-for-a-pull-request", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32413,8 +37951,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32424,38 +37962,44 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List project cards", - "scope": "projects", - "id": "listCards", + "name": "List pull requests", + "scope": "pulls", + "id": "list", "method": "GET", - "url": "/projects/columns/{column_id}/cards", + "url": "/repos/{owner}/{repo}/pulls", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-cards", + "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests", "parameters": [ { - "name": "column_id", - "description": "The unique identifier of the column.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32465,12 +38009,25 @@ "deprecated": null }, { - "name": "archived_state", - "description": "Filters the project cards that are returned by the card's state.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "Either `open`, `closed`, or `all` to filter by state.", "in": "QUERY", "type": "string", "required": false, - "enum": ["all", "archived", "not_archived"], + "enum": ["open", "closed", "all"], "allowNull": false, "mapToData": null, "validation": null, @@ -32478,10 +38035,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "head", + "description": "Filter pulls by head user or head organization and branch name in the format of `user:ref-name` or `organization:ref-name`. For example: `github:new-script-format` or `octocat:test-branch`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -32491,10 +38048,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "base", + "description": "Filter pulls by base branch name. Example: `gh-pages`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -32502,35 +38059,14 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "List project collaborators", - "scope": "projects", - "id": "listCollaborators", - "method": "GET", - "url": "/projects/{project_id}/collaborators", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the collaborators for an organization project. For a project, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners. You must be an organization owner or a project `admin` to list collaborators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-collaborators", - "parameters": [ + }, { - "name": "project_id", - "description": "The unique identifier of the project.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "sort", + "description": "What to sort results by. `popularity` will sort by the number of comments. `long-running` will sort by date created and will limit the results to pull requests that have been open for more than a month and have had activity within the past month.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated", "popularity", "long-running"], "allowNull": false, "mapToData": null, "validation": null, @@ -32538,12 +38074,12 @@ "deprecated": null }, { - "name": "affiliation", - "description": "Filters the collaborators by their affiliation. `outside` means outside collaborators of a project that are not a member of the project's organization. `direct` means collaborators with permissions to a project, regardless of organization membership status. `all` means all collaborators the authenticated user can see.", + "name": "direction", + "description": "The direction of the sort. Default: `desc` when sort is `created` or sort is not specified, otherwise `asc`.", "in": "QUERY", "type": "string", "required": false, - "enum": ["outside", "direct", "all"], + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -32580,9 +38116,6 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -32591,20 +38124,59 @@ "renamed": null }, { - "name": "List project columns", - "scope": "projects", - "id": "listColumns", + "name": "List comments for a pull request review", + "scope": "pulls", + "id": "listCommentsForReview", "method": "GET", - "url": "/projects/{project_id}/columns", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-project-columns", + "description": "List comments for a specific pull request review.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-comments-for-a-pull-request-review", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "review_id", + "description": "The unique identifier of the review.", "in": "PATH", "type": "integer", "required": true, @@ -32644,27 +38216,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List organization projects", - "scope": "projects", - "id": "listForOrg", + "name": "List commits on a pull request", + "scope": "pulls", + "id": "listCommits", "method": "GET", - "url": "/orgs/{org}/projects", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/commits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the projects in an organization. Returns a `404 Not Found` status if projects are disabled in the organization. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-organization-projects", + "description": "Lists a maximum of 250 commits for a pull request. To receive a complete commit list for pull requests with more than 250 commits, use the [List commits](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-commits) endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-commits-on-a-pull-request", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32676,12 +38246,25 @@ "deprecated": null }, { - "name": "state", - "description": "Indicates the state of the projects to return.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "all"], + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -32715,26 +38298,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List repository projects", - "scope": "projects", - "id": "listForRepo", + "name": "List pull requests files", + "scope": "pulls", + "id": "listFiles", "method": "GET", - "url": "/repos/{owner}/{repo}/projects", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/files", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the projects in a repository. Returns a `404 Not Found` status if projects are disabled in the repository. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-repository-projects", + "description": "**Note:** Responses include a maximum of 3000 files. The paginated response returns 30 files per page by default.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests-files", "parameters": [ { "name": "owner", @@ -32751,7 +38328,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32763,12 +38340,12 @@ "deprecated": null }, { - "name": "state", - "description": "Indicates the state of the projects to return.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["open", "closed", "all"], + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -32804,32 +38381,30 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 500, "description": "Internal Error" }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "List user projects", - "scope": "projects", - "id": "listForUser", + "name": "Get all requested reviewers for a pull request", + "scope": "pulls", + "id": "listRequestedReviewers", "method": "GET", - "url": "/users/{username}/projects", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#list-user-projects", + "description": "Gets the users or teams whose review is requested for a pull request. Once a requested reviewer submits a review, they are no longer considered a requested reviewer. Their review will instead be returned by the [List reviews for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls/reviews#list-reviews-for-a-pull-request) operation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-all-requested-reviewers-for-a-pull-request", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -32841,24 +38416,11 @@ "deprecated": null }, { - "name": "state", - "description": "Indicates the state of the projects to return.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "closed", "all"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -32867,11 +38429,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -32880,32 +38442,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Move a project card", - "scope": "projects", - "id": "moveCard", - "method": "POST", - "url": "/projects/columns/cards/{card_id}/moves", + "name": "List review comments on a pull request", + "scope": "pulls", + "id": "listReviewComments", + "method": "GET", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#move-a-project-card", + "description": "Lists all review comments for a pull request. By default, review comments are in ascending order by ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-review-comments-on-a-pull-request", "parameters": [ { - "name": "card_id", - "description": "The unique identifier of the card.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -32915,64 +38471,51 @@ "deprecated": null }, { - "name": "position", - "description": "The position of the card in a column. Can be one of: `top`, `bottom`, or `after:` to place after the specified card.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:top|bottom|after:\\d+)$", + "validation": null, "alias": null, "deprecated": null }, { - "name": "column_id", - "description": "The unique identifier of the column the card should be moved to", - "in": "BODY", + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "sort", + "description": "The property to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, - { "code": 503, "description": "Response" } - ], - "renamed": null - }, - { - "name": "Move a project column", - "scope": "projects", - "id": "moveColumn", - "method": "POST", - "url": "/projects/columns/{column_id}/moves", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#move-a-project-column", - "parameters": [ { - "name": "column_id", - "description": "The unique identifier of the column.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "direction", + "description": "The direction to sort results. Ignored without `sort` parameter.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -32980,49 +38523,24 @@ "deprecated": null }, { - "name": "position", - "description": "The position of the column in a project. Can be one of: `first`, `last`, or `after:` to place after the specified column.", - "in": "BODY", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, - "validation": "^(?:first|last|after:\\d+)$", + "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Remove user as a collaborator", - "scope": "projects", - "id": "removeCollaborator", - "method": "DELETE", - "url": "/projects/{project_id}/collaborators/{username}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Removes a collaborator from an organization project. You must be an organization owner or a project `admin` to remove a collaborator.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#remove-project-collaborator", - "parameters": [ + }, { - "name": "project_id", - "description": "The unique identifier of the project.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -33031,11 +38549,11 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -33044,36 +38562,26 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update a project", - "scope": "projects", - "id": "update", - "method": "PATCH", - "url": "/projects/{project_id}", + "name": "List review comments in a repository", + "scope": "pulls", + "id": "listReviewCommentsForRepo", + "method": "GET", + "url": "/repos/{owner}/{repo}/pulls/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates a project board's information. Returns a `404 Not Found` status if projects are disabled. If you do not have sufficient privileges to perform this action, a `401 Unauthorized` or `410 Gone` status is returned.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project", + "description": "Lists review comments for all pull requests in a repository. By default, review comments are in ascending order by ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-review-comments-in-a-repository", "parameters": [ { - "name": "project_id", - "description": "The unique identifier of the project.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -33083,11 +38591,11 @@ "deprecated": null }, { - "name": "name", - "description": "Name of the project", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33096,25 +38604,25 @@ "deprecated": null }, { - "name": "body", - "description": "Body of the project", - "in": "BODY", + "name": "sort", + "description": "", + "in": "QUERY", "type": "string", "required": false, - "enum": null, - "allowNull": true, + "enum": ["created", "updated", "created_at"], + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "state", - "description": "State of the project; either 'open' or 'closed'", - "in": "BODY", + "name": "direction", + "description": "The direction to sort results. Ignored without `sort` parameter.", + "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -33122,12 +38630,12 @@ "deprecated": null }, { - "name": "organization_permission", - "description": "The baseline permission that all organization members have on this project", - "in": "BODY", + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["read", "write", "admin", "none"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -33135,10 +38643,10 @@ "deprecated": null }, { - "name": "private", - "description": "Whether or not this project can be seen by everyone.", - "in": "BODY", - "type": "boolean", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -33146,42 +38654,41 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 404, - "description": "Not Found if the authenticated user does not have access to the project" }, - { "code": 410, "description": "Gone" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update an existing project card", - "scope": "projects", - "id": "updateCard", - "method": "PATCH", - "url": "/projects/columns/cards/{card_id}", + "name": "List reviews for a pull request", + "scope": "pulls", + "id": "listReviews", + "method": "GET", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project-card", + "description": "The list of reviews returns in chronological order.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-reviews-for-a-pull-request", "parameters": [ { - "name": "card_id", - "description": "The unique identifier of the card.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -33191,23 +38698,49 @@ "deprecated": null }, { - "name": "note", - "description": "The project card's note", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "archived", - "description": "Whether or not the card is archived", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -33218,35 +38751,30 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 200, + "description": "The list of reviews returns in chronological order." } ], "renamed": null }, { - "name": "Update an existing project column", - "scope": "projects", - "id": "updateColumn", - "method": "PATCH", - "url": "/projects/columns/{column_id}", + "name": "Merge a pull request", + "scope": "pulls", + "id": "merge", + "method": "PUT", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/merge", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/projects#update-a-project-column", + "description": "Merges a pull request into the base branch.\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#merge-a-pull-request", "parameters": [ { - "name": "column_id", - "description": "The unique identifier of the column.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -33256,9 +38784,9 @@ "deprecated": null }, { - "name": "name", - "description": "Name of the project column", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -33267,34 +38795,26 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Check if a pull request has been merged", - "scope": "pulls", - "id": "checkIfMerged", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/merge", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#check-if-a-pull-request-has-been-merged", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "pull_number", + "description": "The number that identifies the pull request.", "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "commit_title", + "description": "Title for the automatic commit message.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -33303,11 +38823,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "commit_message", + "description": "Extra detail to append to automatic commit message.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -33316,42 +38836,62 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "sha", + "description": "SHA that pull request head must match to allow merge.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + }, + { + "name": "merge_method", + "description": "The merge method to use.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["merge", "squash", "rebase"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ + { "code": 200, "description": "if merge was successful" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { - "code": 204, - "description": "Response if pull request has been merged" + "code": 405, + "description": "Method Not Allowed if merge cannot be performed" }, { - "code": 404, - "description": "Not Found if pull request has not been merged" + "code": 409, + "description": "Conflict if sha was provided and pull request head did not match" + }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], "renamed": null }, { - "name": "Create a pull request", + "name": "Remove requested reviewers from a pull request", "scope": "pulls", - "id": "create", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls", + "id": "removeRequestedReviewers", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-pull-request", + "description": "Removes review requests from a pull request for a given set of users and/or teams.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#remove-requested-reviewers-from-a-pull-request", "parameters": [ { "name": "owner", @@ -33368,7 +38908,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -33380,11 +38920,11 @@ "deprecated": null }, { - "name": "title", - "description": "The title of the new pull request. Required unless `issue` is specified.", - "in": "BODY", - "type": "string", - "required": false, + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33393,10 +38933,10 @@ "deprecated": null }, { - "name": "head", - "description": "The name of the branch where your changes are implemented. For cross-repository pull requests in the same network, namespace `head` with a user like this: `username:branch`.", + "name": "reviewers", + "description": "An array of user `login`s that will be removed.", "in": "BODY", - "type": "string", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -33406,9 +38946,44 @@ "deprecated": null }, { - "name": "base", - "description": "The name of the branch you want the changes pulled into. This should be an existing branch on the current repository. You cannot submit a pull request to one repository that requests a merge to a base of another repository.", + "name": "team_reviewers", + "description": "An array of team `slug`s that will be removed.", "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Request reviewers for a pull request", + "scope": "pulls", + "id": "requestReviewers", + "method": "POST", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This endpoint triggers [notifications](https://docs.github.com/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/rest/reference/pulls#request-reviewers-for-a-pull-request", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -33419,11 +38994,11 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the pull request.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33432,11 +39007,11 @@ "deprecated": null }, { - "name": "maintainer_can_modify", - "description": "Indicates whether [maintainers can modify](https://docs.github.com/articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork/) the pull request.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33445,10 +39020,10 @@ "deprecated": null }, { - "name": "draft", - "description": "Indicates whether the pull request is a draft. See \"[Draft Pull Requests](https://docs.github.com/en/articles/about-pull-requests#draft-pull-requests)\" in the GitHub Help documentation to learn more.", + "name": "reviewers", + "description": "An array of user `login`s that will be requested.", "in": "BODY", - "type": "boolean", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -33458,10 +39033,10 @@ "deprecated": null }, { - "name": "issue", - "description": "An issue in the repository to convert to a pull request. The issue title, body, and comments will become the title, body, and comments on the new pull request. Required unless `title` is specified.", + "name": "team_reviewers", + "description": "An array of team `slug`s that will be requested.", "in": "BODY", - "type": "integer", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -33476,22 +39051,22 @@ { "code": 403, "description": "Forbidden" }, { "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "description": "Unprocessable Entity if user is not a collaborator" } ], "renamed": null }, { - "name": "Create a reply for a review comment", + "name": "Submit a review for a pull request", "scope": "pulls", - "id": "createReplyForReviewComment", + "id": "submitReview", "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments/{comment_id}/replies", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/events", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a reply to a review comment for a pull request. For the `comment_id`, provide the ID of the review comment you are replying to. This must be the ID of a _top-level review comment_, not a reply to that comment. Replies to replies are not supported.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-reply-for-a-review-comment", + "description": "Submits a pending review for a pull request. For more information about creating a pending review for a pull request, see \"[Create a review for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls#create-a-review-for-a-pull-request).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#submit-a-review-for-a-pull-request", "parameters": [ { "name": "owner", @@ -33508,7 +39083,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -33533,8 +39108,8 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "review_id", + "description": "The unique identifier of the review.", "in": "PATH", "type": "integer", "required": true, @@ -33547,35 +39122,53 @@ }, { "name": "body", - "description": "The text of the review comment.", + "description": "The body text of the pull request review", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + }, + { + "name": "event", + "description": "The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["APPROVE", "REQUEST_CHANGES", "COMMENT"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Create a review for a pull request", + "name": "Update a pull request", "scope": "pulls", - "id": "createReview", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews", + "id": "update", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\nPull request reviews created in the `PENDING` state are not submitted and therefore do not include the `submitted_at` property in the response. To create a pending review for a pull request, leave the `event` parameter blank. For more information about submitting a `PENDING` review, see \"[Submit a review for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls#submit-a-review-for-a-pull-request).\"\n\n**Note:** To comment on a specific line in a file, you need to first determine the _position_ of that line in the diff. The GitHub REST API v3 offers the `application/vnd.github.v3.diff` [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types#commits-commit-comparison-and-pull-requests). To see a pull request diff, add this media type to the `Accept` header of a call to the [single pull request](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request) endpoint.\n\nThe `position` value equals the number of lines down from the first \"@@\" hunk header in the file you want to add a comment. The line just below the \"@@\" line is position 1, the next line is position 2, and so on. The position in the diff continues to increase through lines of whitespace and additional hunks until the beginning of a new file.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-review-for-a-pull-request", + "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls/#update-a-pull-request", "parameters": [ { "name": "owner", @@ -33592,7 +39185,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -33617,8 +39210,8 @@ "deprecated": null }, { - "name": "commit_id", - "description": "The SHA of the commit that needs a review. Not using the latest commit SHA may render your review comment outdated if a subsequent commit modifies the line you specify as the `position`. Defaults to the most recent commit in the pull request when you do not specify a value.", + "name": "title", + "description": "The title of the pull request.", "in": "BODY", "type": "string", "required": false, @@ -33631,7 +39224,7 @@ }, { "name": "body", - "description": "**Required** when using `REQUEST_CHANGES` or `COMMENT` for the `event` parameter. The body text of the pull request review.", + "description": "The contents of the pull request.", "in": "BODY", "type": "string", "required": false, @@ -33643,25 +39236,12 @@ "deprecated": null }, { - "name": "event", - "description": "The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. By leaving this blank, you set the review action state to `PENDING`, which means you will need to [submit the pull request review](https://docs.github.com/enterprise-cloud@latest//rest/pulls#submit-a-review-for-a-pull-request) when you are ready.", + "name": "state", + "description": "State of this Pull Request. Either `open` or `closed`.", "in": "BODY", "type": "string", "required": false, - "enum": ["APPROVE", "REQUEST_CHANGES", "COMMENT"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "comments", - "description": "Use the following table to specify the location, destination, and contents of the draft review comment.", - "in": "BODY", - "type": "object[]", - "required": false, - "enum": null, + "enum": ["open", "closed"], "allowNull": false, "mapToData": null, "validation": null, @@ -33669,11 +39249,11 @@ "deprecated": null }, { - "name": "comments[].path", - "description": "The relative path to the file that necessitates a review comment.", + "name": "base", + "description": "The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -33682,10 +39262,10 @@ "deprecated": null }, { - "name": "comments[].position", - "description": "The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note below.", + "name": "maintainer_can_modify", + "description": "Indicates whether [maintainers can modify](https://docs.github.com/enterprise-cloud@latest//articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork/) the pull request.", "in": "BODY", - "type": "integer", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -33693,11 +39273,34 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { - "name": "comments[].body", - "description": "Text of the review comment.", - "in": "BODY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Update a pull request branch", + "scope": "pulls", + "id": "updateBranch", + "method": "PUT", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/update-branch", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates the pull request branch with the latest upstream changes by merging HEAD from the base branch into the pull request branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-pull-request-branch", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -33708,24 +39311,11 @@ "deprecated": null }, { - "name": "comments[].line", - "description": "", - "in": "BODY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "comments[].side", - "description": "", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33734,11 +39324,11 @@ "deprecated": null }, { - "name": "comments[].start_line", - "description": "", - "in": "BODY", + "name": "pull_number", + "description": "The number that identifies the pull request.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33747,8 +39337,8 @@ "deprecated": null }, { - "name": "comments[].start_side", - "description": "", + "name": "expected_head_sha", + "description": "The expected SHA of the pull request's HEAD ref. This is the most recent commit on the pull request's branch. If the expected SHA does not match the pull request's HEAD, you will receive a `422 Unprocessable Entity` status. You can use the \"[List commits](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-commits)\" endpoint to find the most recent commit SHA. Default: SHA of the pull request's current HEAD ref.", "in": "BODY", "type": "string", "required": false, @@ -33761,7 +39351,7 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 202, "description": "Response" }, { "code": 403, "description": "Forbidden" }, { "code": 422, @@ -33771,16 +39361,16 @@ "renamed": null }, { - "name": "Create a review comment for a pull request", + "name": "Update a review for a pull request", "scope": "pulls", - "id": "createReviewComment", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments", + "id": "updateReview", + "method": "PUT", + "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "\nCreates a review comment in the pull request diff. To add a regular comment to a pull request timeline, see \"[Create an issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#create-an-issue-comment).\" We recommend creating a review comment using `line`, `side`, and optionally `start_line` and `start_side` if your comment applies to more than one line in the pull request diff.\n\nThe `position` parameter is deprecated. If you use `position`, the `line`, `side`, `start_line`, and `start_side` parameters are not required.\n\n**Note:** The position value equals the number of lines down from the first \"@@\" hunk header in the file you want to add a comment. The line just below the \"@@\" line is position 1, the next line is position 2, and so on. The position in the diff continues to increase through lines of whitespace and additional hunks until the beginning of a new file.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#create-a-review-comment-for-a-pull-request", + "description": "Update the review summary comment with new text.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-review-for-a-pull-request", "parameters": [ { "name": "owner", @@ -33797,7 +39387,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -33821,9 +39411,22 @@ "alias": null, "deprecated": null }, + { + "name": "review_id", + "description": "The unique identifier of the review.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "body", - "description": "The text of the review comment.", + "description": "The body text of the pull request review.", "in": "BODY", "type": "string", "required": true, @@ -33833,11 +39436,33 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, { - "name": "commit_id", - "description": "The SHA of the commit needing a comment. Not using the latest commit SHA may render your comment outdated if a subsequent commit modifies the line you specify as the `position`.", - "in": "BODY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Update a review comment for a pull request", + "scope": "pulls", + "id": "updateReviewComment", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables you to edit a review comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-review-comment-for-a-pull-request", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -33848,9 +39473,9 @@ "deprecated": null }, { - "name": "path", - "description": "The relative path to the file that necessitates a comment.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -33861,11 +39486,11 @@ "deprecated": null }, { - "name": "position", - "description": "**This parameter is deprecated. Use `line` instead**. The position in the diff where you want to add a review comment. Note this value is not the same as the line number in the file. For help finding the position value, read the note above.", - "in": "BODY", + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33874,23 +39499,58 @@ "deprecated": null }, { - "name": "side", - "description": "In a split diff view, the side of the diff that the pull request's changes appear on. Can be `LEFT` or `RIGHT`. Use `LEFT` for deletions that appear in red. Use `RIGHT` for additions that appear in green or unchanged lines that appear in white and are shown for context. For a multi-line comment, side represents whether the last line of the comment range is a deletion or addition. For more information, see \"[Diff view options](https://docs.github.com/en/articles/about-comparing-branches-in-pull-requests#diff-view-options)\" in the GitHub Help documentation.", + "name": "body", + "description": "The text of the reply to the review comment.", "in": "BODY", "type": "string", - "required": false, - "enum": ["LEFT", "RIGHT"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Get rate limit status for the authenticated user", + "scope": "rateLimit", + "id": "get", + "method": "GET", + "url": "/rate_limit", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note:** Accessing this endpoint does not count against your REST API rate limit.\n\n**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.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/rate-limit#get-rate-limit-status-for-the-authenticated-user", + "parameters": [], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Create reaction for a commit comment", + "scope": "reactions", + "id": "createForCommitComment", + "method": "POST", + "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Create a reaction to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments). A response with an HTTP `200` status means that you already added the reaction type to this commit comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-commit-comment", + "parameters": [ { - "name": "line", - "description": "The line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to.", - "in": "BODY", - "type": "integer", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -33900,11 +39560,11 @@ "deprecated": null }, { - "name": "start_line", - "description": "**Required when using multi-line comments unless using `in_reply_to`**. The `start_line` is the first line in the pull request diff that your multi-line comment applies to. To learn more about multi-line comments, see \"[Commenting on a pull request](https://docs.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)\" in the GitHub Help documentation.", - "in": "BODY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -33913,12 +39573,12 @@ "deprecated": null }, { - "name": "start_side", - "description": "**Required when using multi-line comments unless using `in_reply_to`**. The `start_side` is the starting side of the diff that the comment applies to. Can be `LEFT` or `RIGHT`. To learn more about multi-line comments, see \"[Commenting on a pull request](https://docs.github.com/en/articles/commenting-on-a-pull-request#adding-line-comments-to-a-pull-request)\" in the GitHub Help documentation. See `side` in this table for additional context.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["LEFT", "RIGHT", "side"], + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -33926,12 +39586,21 @@ "deprecated": null }, { - "name": "in_reply_to", - "description": "The ID of the review comment to reply to. To find the ID of a review comment with [\"List review comments on a pull request\"](#list-review-comments-on-a-pull-request). When specified, all parameters other than `body` in the request body are ignored.", + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the commit comment.", "in": "BODY", - "type": "integer", - "required": false, - "enum": null, + "type": "string", + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -33940,8 +39609,8 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, + { "code": 200, "description": "Reaction exists" }, + { "code": 201, "description": "Reaction created" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -33950,16 +39619,16 @@ "renamed": null }, { - "name": "Delete a pending review for a pull request", - "scope": "pulls", - "id": "deletePendingReview", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", + "name": "Create reaction for an issue", + "scope": "reactions", + "id": "createForIssue", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#delete-a-pending-review-for-a-pull-request", + "description": "Create a reaction to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues/). A response with an HTTP `200` status means that you already added the reaction type to this issue.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-an-issue", "parameters": [ { "name": "owner", @@ -33976,7 +39645,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -33988,8 +39657,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -34001,12 +39670,21 @@ "deprecated": null }, { - "name": "review_id", - "description": "The unique identifier of the review.", - "in": "PATH", - "type": "integer", + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the issue.", + "in": "BODY", + "type": "string", "required": true, - "enum": null, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -34016,7 +39694,7 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, + { "code": 201, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -34025,16 +39703,16 @@ "renamed": null }, { - "name": "Delete a review comment for a pull request", - "scope": "pulls", - "id": "deleteReviewComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", + "name": "Create reaction for an issue comment", + "scope": "reactions", + "id": "createForIssueComment", + "method": "POST", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a review comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#delete-a-review-comment-for-a-pull-request", + "description": "Create a reaction to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments). A response with an HTTP `200` status means that you already added the reaction type to this issue comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-an-issue-comment", "parameters": [ { "name": "owner", @@ -34051,7 +39729,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34074,25 +39752,51 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the issue comment.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Reaction exists" }, + { "code": 201, "description": "Reaction created" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Dismiss a review for a pull request", - "scope": "pulls", - "id": "dismissReview", - "method": "PUT", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/dismissals", + "name": "Create reaction for a pull request review comment", + "scope": "reactions", + "id": "createForPullRequestReviewComment", + "method": "POST", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** To dismiss a pull request review on a [protected branch](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#branches), you must be a repository administrator or be included in the list of people or teams who can dismiss pull request reviews.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#dismiss-a-review-for-a-pull-request", + "description": "Create a reaction to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#comments). A response with an HTTP `200` status means that you already added the reaction type to this pull request review comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-pull-request-review-comment", "parameters": [ { "name": "owner", @@ -34109,7 +39813,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34121,21 +39825,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "review_id", - "description": "The unique identifier of the review.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -34147,25 +39838,21 @@ "deprecated": null }, { - "name": "message", - "description": "The message for the pull request review dismissal", + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the pull request review comment.", "in": "BODY", "type": "string", "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "event", - "description": "", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["DISMISS"], + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -34174,8 +39861,8 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, + { "code": 200, "description": "Reaction exists" }, + { "code": 201, "description": "Reaction created" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -34184,16 +39871,16 @@ "renamed": null }, { - "name": "Get a pull request", - "scope": "pulls", - "id": "get", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}", + "name": "Create reaction for a release", + "scope": "reactions", + "id": "createForRelease", + "method": "POST", + "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists details of a pull request by providing its number.\n\nWhen you get, [create](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls/#create-a-pull-request), or [edit](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-pull-request) a pull request, GitHub Enterprise Cloud creates a merge commit to test whether the pull request can be automatically merged into the base branch. This test commit is not added to the base branch or the head branch. You can review the status of the test commit using the `mergeable` key. For more information, see \"[Checking mergeability of pull requests](https://docs.github.com/enterprise-cloud@latest//rest/guides/getting-started-with-the-git-database-api#checking-mergeability-of-pull-requests)\".\n\nThe value of the `mergeable` attribute can be `true`, `false`, or `null`. If the value is `null`, then GitHub Enterprise Cloud has started a background job to compute the mergeability. After giving the job time to complete, resubmit the request. When the job finishes, you will see a non-`null` value for the `mergeable` attribute in the response. If `mergeable` is `true`, then `merge_commit_sha` will be the SHA of the _test_ merge commit.\n\nThe value of the `merge_commit_sha` attribute changes depending on the state of the pull request. Before merging a pull request, the `merge_commit_sha` attribute holds the SHA of the _test_ merge commit. After merging a pull request, the `merge_commit_sha` attribute changes depending on how you merged the pull request:\n\n* If merged as a [merge commit](https://docs.github.com/articles/about-merge-methods-on-github/), `merge_commit_sha` represents the SHA of the merge commit.\n* If merged via a [squash](https://docs.github.com/articles/about-merge-methods-on-github/#squashing-your-merge-commits), `merge_commit_sha` represents the SHA of the squashed commit on the base branch.\n* If [rebased](https://docs.github.com/articles/about-merge-methods-on-github/#rebasing-and-merging-your-commits), `merge_commit_sha` represents the commit that the base branch was updated to.\n\nPass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-pull-request", + "description": "Create a reaction to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases). A response with a `Status: 200 OK` means that you already added the reaction type to this release.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-release", "parameters": [ { "name": "owner", @@ -34210,7 +39897,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34222,8 +39909,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", "type": "integer", "required": true, @@ -34233,35 +39920,46 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the release.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["+1", "laugh", "heart", "hooray", "rocket", "eyes"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ + { "code": 200, "description": "Reaction exists" }, + { "code": 201, "description": "Reaction created" }, { - "code": 200, - "description": "Pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats." - }, - { "code": 304, "description": "Not modified" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" }, - { "code": 503, "description": "Service unavailable" } + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get a review for a pull request", - "scope": "pulls", - "id": "getReview", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", + "name": "Create reaction for a team discussion comment", + "scope": "reactions", + "id": "createForTeamDiscussionCommentInOrg", + "method": "POST", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-review-for-a-pull-request", + "description": "Create a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion comment.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion-comment", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34273,8 +39971,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -34286,8 +39984,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", "type": "integer", "required": true, @@ -34299,8 +39997,8 @@ "deprecated": null }, { - "name": "review_id", - "description": "The unique identifier of the review.", + "name": "comment_number", + "description": "The number that identifies the comment.", "in": "PATH", "type": "integer", "required": true, @@ -34310,31 +40008,56 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion comment.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 200, + "description": "Response when the reaction type has already been added to this team discussion comment" + }, + { "code": 201, "description": "Response" } ], "renamed": null }, { - "name": "Get a review comment for a pull request", - "scope": "pulls", - "id": "getReviewComment", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Provides details for a review comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-a-review-comment-for-a-pull-request", + "name": "Create reaction for a team discussion comment (Legacy)", + "scope": "reactions", + "id": "createForTeamDiscussionCommentLegacy", + "method": "POST", + "url": "/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions", + "isDeprecated": true, + "deprecationDate": "2020-02-26", + "removalDate": "2021-02-21", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new \"[Create reaction for a team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion-comment)\" endpoint.\n\nCreate a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion comment.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-team-discussion-comment-legacy", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "team_id", + "description": "The unique identifier of the team.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -34344,10 +40067,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -34357,8 +40080,8 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "comment_number", + "description": "The number that identifies the comment.", "in": "PATH", "type": "integer", "required": true, @@ -34368,29 +40091,48 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion comment.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "List pull requests", - "scope": "pulls", - "id": "list", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls", + "name": "Create reaction for a team discussion", + "scope": "reactions", + "id": "createForTeamDiscussionInOrg", + "method": "POST", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests", + "description": "Create a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34402,8 +40144,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -34415,37 +40157,11 @@ "deprecated": null }, { - "name": "state", - "description": "Either `open`, `closed`, or `all` to filter by state.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["open", "closed", "all"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "head", - "description": "Filter pulls by head user or head organization and branch name in the format of `user:ref-name` or `organization:ref-name`. For example: `github:new-script-format` or `octocat:test-branch`.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "base", - "description": "Filter pulls by base branch name. Example: `gh-pages`.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "discussion_number", + "description": "The number that identifies the discussion.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34454,25 +40170,53 @@ "deprecated": null }, { - "name": "sort", - "description": "What to sort results by. `popularity` will sort by the number of comments. `long-running` will sort by date created and will limit the results to pull requests that have been open for more than a month and have had activity within the past month.", - "in": "QUERY", + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion.", + "in": "BODY", "type": "string", - "required": false, - "enum": ["created", "updated", "popularity", "long-running"], + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" } + ], + "renamed": null + }, + { + "name": "Create reaction for a team discussion (Legacy)", + "scope": "reactions", + "id": "createForTeamDiscussionLegacy", + "method": "POST", + "url": "/teams/{team_id}/discussions/{discussion_number}/reactions", + "isDeprecated": true, + "deprecationDate": "2020-02-26", + "removalDate": "2021-02-21", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`Create reaction for a team discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion) endpoint.\n\nCreate a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-team-discussion-legacy", + "parameters": [ { - "name": "direction", - "description": "The direction of the sort. Default: `desc` when sort is `created` or sort is not specified, otherwise `asc`.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], + "name": "team_id", + "description": "The unique identifier of the team.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -34480,11 +40224,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "discussion_number", + "description": "The number that identifies the discussion.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34493,12 +40237,21 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, + "name": "content", + "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -34506,27 +40259,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "List comments for a pull request review", - "scope": "pulls", - "id": "listCommentsForReview", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/comments", + "name": "Delete a commit comment reaction", + "scope": "reactions", + "id": "deleteForCommitComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List comments for a specific pull request review.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-comments-for-a-pull-request-review", + "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/comments/:comment_id/reactions/:reaction_id`.\n\nDelete a reaction to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-a-commit-comment-reaction", "parameters": [ { "name": "owner", @@ -34543,7 +40289,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34555,8 +40301,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -34568,8 +40314,8 @@ "deprecated": null }, { - "name": "review_id", - "description": "The unique identifier of the review.", + "name": "reaction_id", + "description": "The unique identifier of the reaction.", "in": "PATH", "type": "integer", "required": true, @@ -34579,51 +40325,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List commits on a pull request", - "scope": "pulls", - "id": "listCommits", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/commits", + "name": "Delete an issue reaction", + "scope": "reactions", + "id": "deleteForIssue", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists a maximum of 250 commits for a pull request. To receive a complete commit list for pull requests with more than 250 commits, use the [List commits](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-commits) endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-commits-on-a-pull-request", + "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/issues/:issue_number/reactions/:reaction_id`.\n\nDelete a reaction to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-an-issue-reaction", "parameters": [ { "name": "owner", @@ -34640,7 +40357,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34652,8 +40369,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -34665,24 +40382,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "reaction_id", + "description": "The unique identifier of the reaction.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34691,20 +40395,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null - }, - { - "name": "List pull requests files", - "scope": "pulls", - "id": "listFiles", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/files", + }, + { + "name": "Delete an issue comment reaction", + "scope": "reactions", + "id": "deleteForIssueComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** Responses include a maximum of 3000 files. The paginated response returns 30 files per page by default.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-pull-requests-files", + "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE delete /repositories/:repository_id/issues/comments/:comment_id/reactions/:reaction_id`.\n\nDelete a reaction to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-an-issue-comment-reaction", "parameters": [ { "name": "owner", @@ -34721,7 +40425,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34733,8 +40437,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -34746,24 +40450,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "reaction_id", + "description": "The unique identifier of the reaction.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34772,28 +40463,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 500, "description": "Internal Error" }, - { "code": 503, "description": "Service unavailable" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Get all requested reviewers for a pull request", - "scope": "pulls", - "id": "listRequestedReviewers", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", + "name": "Delete a pull request comment reaction", + "scope": "reactions", + "id": "deleteForPullRequestComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the users or teams whose review is requested for a pull request. Once a requested reviewer submits a review, they are no longer considered a requested reviewer. Their review will instead be returned by the [List reviews for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls/reviews#list-reviews-for-a-pull-request) operation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#get-all-requested-reviewers-for-a-pull-request", + "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/pulls/comments/:comment_id/reactions/:reaction_id.`\n\nDelete a reaction to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#review-comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-a-pull-request-comment-reaction", "parameters": [ { "name": "owner", @@ -34810,7 +40493,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34822,8 +40505,21 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "reaction_id", + "description": "The unique identifier of the reaction.", "in": "PATH", "type": "integer", "required": true, @@ -34835,20 +40531,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List review comments on a pull request", - "scope": "pulls", - "id": "listReviewComments", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/comments", + "name": "Delete a release reaction", + "scope": "reactions", + "id": "deleteForRelease", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all review comments for a pull request. By default, review comments are in ascending order by ID.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-review-comments-on-a-pull-request", + "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE delete /repositories/:repository_id/releases/:release_id/reactions/:reaction_id`.\n\nDelete a reaction to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#delete-a-release-reaction", "parameters": [ { "name": "owner", @@ -34865,7 +40561,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34877,8 +40573,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", "type": "integer", "required": true, @@ -34890,25 +40586,41 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the repository was starred. `updated` means when the repository was last pushed to.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["created", "updated"], + "name": "reaction_id", + "description": "The unique identifier of the reaction.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete team discussion reaction", + "scope": "reactions", + "id": "deleteForTeamDiscussion", + "method": "DELETE", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions/{reaction_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "**Note:** You can also specify a team or organization with `team_id` and `org_id` using the route `DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions/:reaction_id`.\n\nDelete a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-team-discussion-reaction", + "parameters": [ { - "name": "direction", - "description": "The direction to sort results. Ignored without `sort` parameter.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -34916,11 +40628,11 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "team_slug", + "description": "The slug of the team name.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34929,11 +40641,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "discussion_number", + "description": "The number that identifies the discussion.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34942,11 +40654,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "reaction_id", + "description": "The unique identifier of the reaction.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -34955,24 +40667,24 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List review comments in a repository", - "scope": "pulls", - "id": "listReviewCommentsForRepo", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/comments", + "name": "Delete team discussion comment reaction", + "scope": "reactions", + "id": "deleteForTeamDiscussionComment", + "method": "DELETE", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions/{reaction_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists review comments for all pull requests in a repository. By default, review comments are in ascending order by ID.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-review-comments-in-a-repository", + "description": "**Note:** You can also specify a team or organization with `team_id` and `org_id` using the route `DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions/:reaction_id`.\n\nDelete a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-team-discussion-comment-reaction", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -34984,8 +40696,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -34997,37 +40709,11 @@ "deprecated": null }, { - "name": "sort", - "description": "", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["created", "updated", "created_at"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "direction", - "description": "The direction to sort results. Ignored without `sort` parameter.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["asc", "desc"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "discussion_number", + "description": "The number that identifies the discussion.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -35036,11 +40722,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "comment_number", + "description": "The number that identifies the comment.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -35049,11 +40735,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "reaction_id", + "description": "The unique identifier of the reaction.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -35062,20 +40748,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List reviews for a pull request", - "scope": "pulls", - "id": "listReviews", + "name": "List reactions for a commit comment", + "scope": "reactions", + "id": "listForCommitComment", "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews", + "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The list of reviews returns in chronological order.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#list-reviews-for-a-pull-request", + "description": "List the reactions to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-commit-comment", "parameters": [ { "name": "owner", @@ -35092,7 +40778,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35104,8 +40790,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -35116,6 +40802,28 @@ "alias": null, "deprecated": null }, + { + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a commit comment.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -35144,24 +40852,22 @@ } ], "responses": [ - { - "code": 200, - "description": "The list of reviews returns in chronological order." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Merge a pull request", - "scope": "pulls", - "id": "merge", - "method": "PUT", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/merge", + "name": "List reactions for an issue", + "scope": "reactions", + "id": "listForIssue", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#merge-a-pull-request", + "description": "List the reactions to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-an-issue", "parameters": [ { "name": "owner", @@ -35178,7 +40884,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35190,8 +40896,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "issue_number", + "description": "The number that identifies the issue.", "in": "PATH", "type": "integer", "required": true, @@ -35203,12 +40909,21 @@ "deprecated": null }, { - "name": "commit_title", - "description": "Title for the automatic commit message.", - "in": "BODY", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to an issue.", + "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -35216,10 +40931,10 @@ "deprecated": null }, { - "name": "commit_message", - "description": "Extra detail to append to automatic commit message.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35229,10 +40944,10 @@ "deprecated": null }, { - "name": "sha", - "description": "SHA that pull request head must match to allow merge.", - "in": "BODY", - "type": "string", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35240,51 +40955,26 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "merge_method", - "description": "Merge method to use. Possible values are `merge`, `squash` or `rebase`. Default is `merge`.", - "in": "BODY", - "type": "string", - "required": false, - "enum": ["merge", "squash", "rebase"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ - { "code": 200, "description": "if merge was successful" }, - { "code": 403, "description": "Forbidden" }, + { "code": 200, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { - "code": 405, - "description": "Method Not Allowed if merge cannot be performed" - }, - { - "code": 409, - "description": "Conflict if sha was provided and pull request head did not match" - }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 410, "description": "Gone" } ], "renamed": null }, { - "name": "Remove requested reviewers from a pull request", - "scope": "pulls", - "id": "removeRequestedReviewers", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", + "name": "List reactions for an issue comment", + "scope": "reactions", + "id": "listForIssueComment", + "method": "GET", + "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#remove-requested-reviewers-from-a-pull-request", + "description": "List the reactions to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-an-issue-comment", "parameters": [ { "name": "owner", @@ -35301,7 +40991,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35313,8 +41003,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -35326,11 +41016,33 @@ "deprecated": null }, { - "name": "reviewers", - "description": "An array of user `login`s that will be removed.", - "in": "BODY", - "type": "string[]", - "required": true, + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to an issue comment.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -35339,10 +41051,10 @@ "deprecated": null }, { - "name": "team_reviewers", - "description": "An array of team `slug`s that will be removed.", - "in": "BODY", - "type": "string[]", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35354,24 +41066,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Request reviewers for a pull request", - "scope": "pulls", - "id": "requestReviewers", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/requested_reviewers", + "name": "List reactions for a pull request review comment", + "scope": "reactions", + "id": "listForPullRequestReviewComment", + "method": "GET", + "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#request-reviewers-for-a-pull-request", + "description": "List the reactions to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#review-comments).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-pull-request-review-comment", "parameters": [ { "name": "owner", @@ -35388,7 +41097,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35400,8 +41109,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_id", + "description": "The unique identifier of the comment.", "in": "PATH", "type": "integer", "required": true, @@ -35413,10 +41122,32 @@ "deprecated": null }, { - "name": "reviewers", - "description": "An array of user `login`s that will be requested.", - "in": "BODY", - "type": "string[]", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a pull request review comment.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35426,10 +41157,10 @@ "deprecated": null }, { - "name": "team_reviewers", - "description": "An array of team `slug`s that will be requested.", - "in": "BODY", - "type": "string[]", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35440,26 +41171,22 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Unprocessable Entity if user is not a collaborator" - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Submit a review for a pull request", - "scope": "pulls", - "id": "submitReview", - "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}/events", + "name": "List reactions for a release", + "scope": "reactions", + "id": "listForRelease", + "method": "GET", + "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Submits a pending review for a pull request. For more information about creating a pending review for a pull request, see \"[Create a review for a pull request](https://docs.github.com/enterprise-cloud@latest//rest/pulls#create-a-review-for-a-pull-request).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#submit-a-review-for-a-pull-request", + "description": "List the reactions to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-release", "parameters": [ { "name": "owner", @@ -35476,7 +41203,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35488,8 +41215,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", "type": "integer", "required": true, @@ -35501,12 +41228,12 @@ "deprecated": null }, { - "name": "review_id", - "description": "The unique identifier of the review.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a release.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["+1", "laugh", "heart", "hooray", "rocket", "eyes"], "allowNull": false, "mapToData": null, "validation": null, @@ -35514,10 +41241,10 @@ "deprecated": null }, { - "name": "body", - "description": "The body text of the pull request review", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35527,12 +41254,12 @@ "deprecated": null }, { - "name": "event", - "description": "The review action you want to perform. The review actions include: `APPROVE`, `REQUEST_CHANGES`, or `COMMENT`. When you leave this blank, the API returns _HTTP 422 (Unrecognizable entity)_ and sets the review action state to `PENDING`, which means you will need to re-submit the pull request review using a review action.", - "in": "BODY", - "type": "string", - "required": true, - "enum": ["APPROVE", "REQUEST_CHANGES", "COMMENT"], + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -35542,30 +41269,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Update a pull request", - "scope": "pulls", - "id": "update", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}", + "name": "List reactions for a team discussion comment", + "scope": "reactions", + "id": "listForTeamDiscussionCommentInOrg", + "method": "GET", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Draft pull requests are available in public repositories with GitHub Free and GitHub Free for organizations, GitHub Pro, and legacy per-repository billing plans, and in public and private repositories with GitHub Team and GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo open or update a pull request in a public repository, you must have write access to the head or the source branch. For organization-owned repositories, you must be a member of the organization that owns the repository to open or update a pull request.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls/#update-a-pull-request", + "description": "List the reactions to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments/). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion-comment", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35577,8 +41299,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -35590,8 +41312,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", "type": "integer", "required": true, @@ -35603,24 +41325,11 @@ "deprecated": null }, { - "name": "title", - "description": "The title of the pull request.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "body", - "description": "The contents of the pull request.", - "in": "BODY", - "type": "string", - "required": false, + "name": "comment_number", + "description": "The number that identifies the comment.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -35629,12 +41338,21 @@ "deprecated": null }, { - "name": "state", - "description": "State of this Pull Request. Either `open` or `closed`.", - "in": "BODY", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion comment.", + "in": "QUERY", "type": "string", "required": false, - "enum": ["open", "closed"], + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -35642,10 +41360,10 @@ "deprecated": null }, { - "name": "base", - "description": "The name of the branch you want your changes pulled into. This should be an existing branch on the current repository. You cannot update the base branch on a pull request to point to another repository.", - "in": "BODY", - "type": "string", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35655,10 +41373,10 @@ "deprecated": null }, { - "name": "maintainer_can_modify", - "description": "Indicates whether [maintainers can modify](https://docs.github.com/articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork/) the pull request.", - "in": "BODY", - "type": "boolean", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -35668,33 +41386,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update a pull request branch", - "scope": "pulls", - "id": "updateBranch", - "method": "PUT", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/update-branch", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Updates the pull request branch with the latest upstream changes by merging HEAD from the base branch into the pull request branch.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-pull-request-branch", + "name": "List reactions for a team discussion comment (Legacy)", + "scope": "reactions", + "id": "listForTeamDiscussionCommentLegacy", + "method": "GET", + "url": "/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions", + "isDeprecated": true, + "deprecationDate": "2020-02-26", + "removalDate": "2021-02-21", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`List reactions for a team discussion comment`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion-comment) endpoint.\n\nList the reactions to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-team-discussion-comment-legacy", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "team_id", + "description": "The unique identifier of the team.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -35704,10 +41415,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -35717,8 +41428,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "comment_number", + "description": "The number that identifies the comment.", "in": "PATH", "type": "integer", "required": true, @@ -35730,44 +41441,72 @@ "deprecated": null }, { - "name": "expected_head_sha", - "description": "The expected SHA of the pull request's HEAD ref. This is the most recent commit on the pull request's branch. If the expected SHA does not match the pull request's HEAD, you will receive a `422 Unprocessable Entity` status. You can use the \"[List commits](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-commits)\" endpoint to find the most recent commit SHA. Default: SHA of the pull request's current HEAD ref.", - "in": "BODY", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion comment.", + "in": "QUERY", "type": "string", "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 202, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update a review for a pull request", - "scope": "pulls", - "id": "updateReview", - "method": "PUT", - "url": "/repos/{owner}/{repo}/pulls/{pull_number}/reviews/{review_id}", + "name": "List reactions for a team discussion", + "scope": "reactions", + "id": "listForTeamDiscussionInOrg", + "method": "GET", + "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Update the review summary comment with new text.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-review-for-a-pull-request", + "description": "List the reactions to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35779,8 +41518,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "team_slug", + "description": "The slug of the team name.", "in": "PATH", "type": "string", "required": true, @@ -35792,8 +41531,8 @@ "deprecated": null }, { - "name": "pull_number", - "description": "The number that identifies the pull request.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", "type": "integer", "required": true, @@ -35805,11 +41544,33 @@ "deprecated": null }, { - "name": "review_id", - "description": "The unique identifier of the review.", - "in": "PATH", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -35818,11 +41579,11 @@ "deprecated": null }, { - "name": "body", - "description": "The body text of the pull request review.", - "in": "BODY", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -35831,32 +41592,26 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Update a review comment for a pull request", - "scope": "pulls", - "id": "updateReviewComment", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Enables you to edit a review comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#update-a-review-comment-for-a-pull-request", + "name": "List reactions for a team discussion (Legacy)", + "scope": "reactions", + "id": "listForTeamDiscussionLegacy", + "method": "GET", + "url": "/teams/{team_id}/discussions/{discussion_number}/reactions", + "isDeprecated": true, + "deprecationDate": "2020-02-26", + "removalDate": "2021-02-21", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`List reactions for a team discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion) endpoint.\n\nList the reactions to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-team-discussion-legacy", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "team_id", + "description": "The unique identifier of the team.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -35866,10 +41621,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "discussion_number", + "description": "The number that identifies the discussion.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -35879,11 +41634,33 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", + "name": "content", + "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "+1", + "-1", + "laugh", + "confused", + "heart", + "hooray", + "rocket", + "eyes" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -35892,11 +41669,11 @@ "deprecated": null }, { - "name": "body", - "description": "The text of the reply to the review comment.", - "in": "BODY", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -35909,35 +41686,94 @@ "renamed": null }, { - "name": "Get rate limit status for the authenticated user", - "scope": "rateLimit", - "id": "get", - "method": "GET", - "url": "/rate_limit", + "name": "Accept a repository invitation", + "scope": "repos", + "id": "acceptInvitation", + "method": "PATCH", + "url": "/user/repository_invitations/{invitation_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** Accessing this endpoint does not count against your REST API rate limit.\n\n**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.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/rate-limit#get-rate-limit-status-for-the-authenticated-user", - "parameters": [], + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#accept-a-repository-invitation", + "parameters": [ + { + "name": "invitation_id", + "description": "The unique identifier of the invitation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 204, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 404, "description": "Resource not found" } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" } + ], + "renamed": { + "before": { "scope": "repos", "id": "acceptInvitation" }, + "after": { + "scope": "repos", + "id": "acceptInvitationForAuthenticatedUser" + }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "Accept a repository invitation", + "scope": "repos", + "id": "acceptInvitationForAuthenticatedUser", + "method": "PATCH", + "url": "/user/repository_invitations/{invitation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#accept-a-repository-invitation", + "parameters": [ + { + "name": "invitation_id", + "description": "The unique identifier of the invitation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" } ], "renamed": null }, { - "name": "Create reaction for a commit comment", - "scope": "reactions", - "id": "createForCommitComment", + "name": "Add app access restrictions", + "scope": "repos", + "id": "addAppAccessRestrictions", "method": "POST", - "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments). A response with an HTTP `200` status means that you already added the reaction type to this commit comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-commit-comment", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified apps push access for this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#add-app-access-restrictions", "parameters": [ { "name": "owner", @@ -35954,7 +41790,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -35966,10 +41802,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -35979,31 +41815,21 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the commit comment.", + "name": "apps", + "description": "", "in": "BODY", - "type": "string", + "type": null, "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Reaction exists" }, - { "code": 201, "description": "Reaction created" }, + { "code": 200, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -36012,16 +41838,16 @@ "renamed": null }, { - "name": "Create reaction for an issue", - "scope": "reactions", - "id": "createForIssue", - "method": "POST", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions", + "name": "Add a repository collaborator", + "scope": "repos", + "id": "addCollaborator", + "method": "PUT", + "url": "/repos/{owner}/{repo}/collaborators/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues/). A response with an HTTP `200` status means that you already added the reaction type to this issue.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-an-issue", + "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\nAdding an outside collaborator may be restricted by enterprise administrators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/enterprise-cloud@latest//admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"\n\nFor more information on permission levels, see \"[Repository permission levels for an organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/repository-permission-levels-for-an-organization#permission-levels-for-repositories-owned-by-an-organization)\". There are restrictions on which permissions can be granted to organization members when an organization base role is in place. In this case, the permission being given must be equal to or higher than the org base permission. Otherwise, the request will fail with:\n\n```\nCannot assign {member} permission of {role name}\n```\n\nNote that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"\n\nThe invitee will receive a notification that they have been invited to the repository, which they must accept or decline. They may do this via the notifications page, the email they receive, or by using the [repository invitations API endpoints](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#invitations).\n\n**Updating an existing collaborator's permission level**\n\nThe endpoint can also be used to change the permissions of an existing collaborator without first removing and re-adding the collaborator. To change the permissions, use the same endpoint and pass a different `permission` parameter. The response will be a `204`, with no other indication that the permission level changed.\n\n**Rate limits**\n\nYou are limited to sending 50 invitations to a repository per 24 hour period. Note there is no limit if you are inviting organization members to an organization repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#add-a-repository-collaborator", "parameters": [ { "name": "owner", @@ -36038,7 +41864,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36050,10 +41876,10 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36063,21 +41889,12 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the issue.", - "in": "BODY", - "type": "string", - "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "name": "permission", + "description": "The permission to grant the collaborator. **Only valid on organization-owned repositories.** We accept the following permissions to be set: `pull`, `triage`, `push`, `maintain`, `admin` and you can also specify a custom repository role name, if the owning organization has defined any.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -36086,8 +41903,15 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 201, "description": "Response" }, + { + "code": 201, + "description": "Response when a new invitation is created" + }, + { + "code": 204, + "description": "Response when:\n- an existing collaborator is added as a collaborator\n- an organization member is added as an individual collaborator\n- an existing team member (whose team is also a repository collaborator) is added as an individual collaborator" + }, + { "code": 403, "description": "Forbidden" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -36096,16 +41920,16 @@ "renamed": null }, { - "name": "Create reaction for an issue comment", - "scope": "reactions", - "id": "createForIssueComment", + "name": "Add status check contexts", + "scope": "repos", + "id": "addStatusCheckContexts", "method": "POST", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments). A response with an HTTP `200` status means that you already added the reaction type to this issue comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-an-issue-comment", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#add-status-check-contexts", "parameters": [ { "name": "owner", @@ -36122,7 +41946,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36134,10 +41958,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36147,31 +41971,23 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the issue comment.", + "name": "contexts", + "description": "", "in": "BODY", - "type": "string", + "type": null, "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Reaction exists" }, - { "code": 201, "description": "Reaction created" }, + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -36180,16 +41996,16 @@ "renamed": null }, { - "name": "Create reaction for a pull request review comment", - "scope": "reactions", - "id": "createForPullRequestReviewComment", + "name": "Add team access restrictions", + "scope": "repos", + "id": "addTeamAccessRestrictions", "method": "POST", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#comments). A response with an HTTP `200` status means that you already added the reaction type to this pull request review comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-pull-request-review-comment", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified teams push access for this branch. You can also give push access to child teams.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#add-team-access-restrictions", "parameters": [ { "name": "owner", @@ -36206,7 +42022,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36218,10 +42034,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36231,31 +42047,21 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the pull request review comment.", + "name": "teams", + "description": "", "in": "BODY", - "type": "string", + "type": null, "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Reaction exists" }, - { "code": 201, "description": "Reaction created" }, + { "code": 200, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -36264,16 +42070,16 @@ "renamed": null }, { - "name": "Create reaction for a release", - "scope": "reactions", - "id": "createForRelease", + "name": "Add user access restrictions", + "scope": "repos", + "id": "addUserAccessRestrictions", "method": "POST", - "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases). A response with a `Status: 200 OK` means that you already added the reaction type to this release.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-release", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified people push access for this branch.\n\n| Type | Description |\n| ------- | ----------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames for people who can have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#add-user-access-restrictions", "parameters": [ { "name": "owner", @@ -36290,7 +42096,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36302,10 +42108,10 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36315,22 +42121,21 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the release.", + "name": "users", + "description": "", "in": "BODY", - "type": "string", + "type": null, "required": true, - "enum": ["+1", "laugh", "heart", "hooray", "rocket", "eyes"], + "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Reaction exists" }, - { "code": 201, "description": "Reaction created" }, + { "code": 200, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -36339,20 +42144,20 @@ "renamed": null }, { - "name": "Create reaction for a team discussion comment", - "scope": "reactions", - "id": "createForTeamDiscussionCommentInOrg", - "method": "POST", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions", + "name": "Check if a user is a repository collaborator", + "scope": "repos", + "id": "checkCollaborator", + "method": "GET", + "url": "/repos/{owner}/{repo}/collaborators/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion comment.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion-comment", + "description": "For organization-owned repositories, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners.\n\nTeam members will include the members of child teams.\n\nYou must authenticate using an access token with the `read:org` and `repo` scopes with push access to use this\nendpoint. GitHub Apps must have the `members` organization permission and `metadata` repository permission to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#check-if-a-user-is-a-repository-collaborator", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36364,8 +42169,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36377,10 +42182,10 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36388,12 +42193,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response if user is a collaborator" }, + { "code": 404, "description": "Not Found if user is not a collaborator" } + ], + "renamed": null + }, + { + "name": "Check if vulnerability alerts are enabled for a repository", + "scope": "repos", + "id": "checkVulnerabilityAlerts", + "method": "GET", + "url": "/repos/{owner}/{repo}/vulnerability-alerts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Shows whether dependency alerts are enabled or disabled for a repository. The authenticated user must have admin read access to the repository. For more information, see \"[About security alerts for vulnerable dependencies](https://docs.github.com/enterprise-cloud@latest//articles/about-security-alerts-for-vulnerable-dependencies)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#check-if-vulnerability-alerts-are-enabled-for-a-repository", + "parameters": [ { - "name": "comment_number", - "description": "The number that identifies the comment.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36403,21 +42227,12 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion comment.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -36427,43 +42242,33 @@ ], "responses": [ { - "code": 200, - "description": "Response when the reaction type has already been added to this team discussion comment" + "code": 204, + "description": "Response if repository is enabled with vulnerability alerts" }, - { "code": 201, "description": "Response" } + { + "code": 404, + "description": "Not Found if repository is not enabled with vulnerability alerts" + } ], "renamed": null }, { - "name": "Create reaction for a team discussion comment (Legacy)", - "scope": "reactions", - "id": "createForTeamDiscussionCommentLegacy", - "method": "POST", - "url": "/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions", - "isDeprecated": true, - "deprecationDate": "2020-02-26", - "removalDate": "2021-02-21", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new \"[Create reaction for a team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion-comment)\" endpoint.\n\nCreate a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion comment.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-team-discussion-comment-legacy", + "name": "List CODEOWNERS errors", + "scope": "repos", + "id": "codeownersErrors", + "method": "GET", + "url": "/repos/{owner}/{repo}/codeowners/errors", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "List any syntax errors that are detected in the CODEOWNERS\nfile.\n\nFor more information about the correct CODEOWNERS syntax,\nsee \"[About code owners](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-codeowners-errors", "parameters": [ { - "name": "team_id", - "description": "The unique identifier of the team.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "discussion_number", - "description": "The number that identifies the discussion.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36473,10 +42278,10 @@ "deprecated": null }, { - "name": "comment_number", - "description": "The number that identifies the comment.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36486,21 +42291,12 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion comment.", - "in": "BODY", + "name": "ref", + "description": "A branch, tag or commit name used to determine which version of the CODEOWNERS file to use. Default: the repository's default branch (e.g. `main`)", + "in": "QUERY", "type": "string", - "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -36508,24 +42304,27 @@ "deprecated": null } ], - "responses": [{ "code": 201, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Create reaction for a team discussion", - "scope": "reactions", - "id": "createForTeamDiscussionInOrg", - "method": "POST", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions", + "name": "Compare two commits", + "scope": "repos", + "id": "compareCommits", + "method": "GET", + "url": "/repos/{owner}/{repo}/compare/{base}...{head}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion", + "description": "**Deprecated**: Use `repos.compareCommitsWithBasehead()` (`GET /repos/{owner}/{repo}/compare/{basehead}`) instead. Both `:base` and `:head` must be branch names in `:repo`. To compare branches across other repositories in the same network as `:repo`, use the format `:branch`.\n\nThe response from the API is equivalent to running the `git log base..head` command; however, commits are returned in chronological order. Pass the appropriate [media type](https://docs.github.com/rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.\n\nThe response also includes details on the files that were changed between the two commits. This includes the status of the change (for example, if a file was added, removed, modified, or renamed), and details of the change itself. For example, files with a `renamed` status have a `previous_filename` field showing the previous filename of the file, and files with a `modified` status have a `patch` field showing the changes made to the file.\n\n**Working with large comparisons**\n\nTo process a response with a large number of commits, you can use (`per_page` or `page`) to paginate the results. When using paging, the list of changed files is only returned with page 1, but includes all changed files for the entire comparison. For more information on working with pagination, see \"[Traversing with pagination](/rest/guides/traversing-with-pagination).\"\n\nWhen calling this API without any paging parameters (`per_page` or `page`), the returned list is limited to 250 commits and the last commit in the list is the most recent of the entire comparison. When a paging parameter is specified, the first commit in the returned list of each page is the earliest.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/rest/reference/repos#compare-two-commits", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -36537,8 +42336,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "repo", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -36550,10 +42349,10 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", + "name": "base", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36563,51 +42362,10 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion.", - "in": "BODY", - "type": "string", - "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 201, "description": "Response" } - ], - "renamed": null - }, - { - "name": "Create reaction for a team discussion (Legacy)", - "scope": "reactions", - "id": "createForTeamDiscussionLegacy", - "method": "POST", - "url": "/teams/{team_id}/discussions/{discussion_number}/reactions", - "isDeprecated": true, - "deprecationDate": "2020-02-26", - "removalDate": "2021-02-21", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`Create reaction for a team discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#create-reaction-for-a-team-discussion) endpoint.\n\nCreate a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/). A response with an HTTP `200` status means that you already added the reaction type to this team discussion.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#create-reaction-for-a-team-discussion-legacy", - "parameters": [ - { - "name": "team_id", - "description": "The unique identifier of the team.", + "name": "head", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36617,11 +42375,11 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", + "name": "per_page", + "description": "Results per page.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -36630,21 +42388,12 @@ "deprecated": null }, { - "name": "content", - "description": "The [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types) to add to the team discussion.", - "in": "BODY", - "type": "string", - "required": true, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -36652,20 +42401,24 @@ "deprecated": null } ], - "responses": [{ "code": 201, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { - "name": "Delete a commit comment reaction", - "scope": "reactions", - "id": "deleteForCommitComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions/{reaction_id}", + "name": "Compare two commits", + "scope": "repos", + "id": "compareCommitsWithBasehead", + "method": "GET", + "url": "/repos/{owner}/{repo}/compare/{basehead}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/comments/:comment_id/reactions/:reaction_id`.\n\nDelete a reaction to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-a-commit-comment-reaction", + "description": "Compares two commits against one another. You can compare branches in the same repository, or you can compare branches that exist in different repositories within the same repository network, including fork branches. For more information about how to view a repository's network, see \"[Understanding connections between repositories](https://docs.github.com/enterprise-cloud@latest//repositories/viewing-activity-and-data-for-your-repository/understanding-connections-between-repositories).\"\n\nThis endpoint is equivalent to running the `git log BASE..HEAD` command, but it returns commits in a different order. The `git log BASE..HEAD` command returns commits in reverse chronological order, whereas the API returns commits in chronological order. You can pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.\n\nThe API response includes details about the files that were changed between the two commits. This includes the status of the change (if a file was added, removed, modified, or renamed), and details of the change itself. For example, files with a `renamed` status have a `previous_filename` field showing the previous filename of the file, and files with a `modified` status have a `patch` field showing the changes made to the file.\n\nWhen calling this endpoint without any paging parameter (`per_page` or `page`), the returned list is limited to 250 commits, and the last commit in the list is the most recent of the entire comparison.\n\n**Working with large comparisons**\n\nTo process a response with a large number of commits, use a query parameter (`per_page` or `page`) to paginate the results. When using pagination:\n\n- The list of changed files is only shown on the first page of results, but it includes all changed files for the entire comparison.\n- The results are returned in chronological order, but the last commit in the returned list may not be the most recent one in the entire set if there are more pages of results.\n\nFor more information on working with pagination, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api).\"\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The `verification` object includes the following fields:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#compare-two-commits", "parameters": [ { "name": "owner", @@ -36682,7 +42435,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36694,11 +42447,11 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -36707,10 +42460,23 @@ "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "basehead", + "description": "The base branch and head branch to compare. This parameter expects the format `BASE...HEAD`. Both must be branch names in `repo`. To compare with a branch that exists in a different repository in the same network as `repo`, the `basehead` parameter expects the format `USERNAME:BASE...USERNAME:HEAD`.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36720,20 +42486,25 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" }, + { "code": 503, "description": "Service unavailable" } + ], "renamed": null }, { - "name": "Delete an issue reaction", - "scope": "reactions", - "id": "deleteForIssue", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions/{reaction_id}", + "name": "Create an autolink reference for a repository", + "scope": "repos", + "id": "createAutolink", + "method": "POST", + "url": "/repos/{owner}/{repo}/autolinks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/issues/:issue_number/reactions/:reaction_id`.\n\nDelete a reaction to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-an-issue-reaction", + "description": "Users with admin access to the repository can create an autolink.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/autolinks#create-an-autolink-reference-for-a-repository", "parameters": [ { "name": "owner", @@ -36750,7 +42521,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36762,10 +42533,10 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", + "name": "key_prefix", + "description": "This prefix appended by certain characters will generate a link any time it is found in an issue, pull request, or commit.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36775,10 +42546,10 @@ "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", - "type": "integer", + "name": "url_template", + "description": "The URL must contain `` for the reference number. `` matches different characters depending on the value of `is_alphanumeric`.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36786,22 +42557,41 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "is_alphanumeric", + "description": "Whether this autolink reference matches alphanumeric characters. If true, the `` parameter of the `url_template` matches alphanumeric characters `A-Z` (case insensitive), `0-9`, and `-`. If false, this autolink reference only matches numeric characters.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete an issue comment reaction", - "scope": "reactions", - "id": "deleteForIssueComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions/{reaction_id}", + "name": "Create a commit comment", + "scope": "repos", + "id": "createCommitComment", + "method": "POST", + "url": "/repos/{owner}/{repo}/commits/{commit_sha}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE delete /repositories/:repository_id/issues/comments/:comment_id/reactions/:reaction_id`.\n\nDelete a reaction to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-an-issue-comment-reaction", + "description": "Create a comment for a commit using its `:commit_sha`.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#create-a-commit-comment", "parameters": [ { "name": "owner", @@ -36817,9 +42607,35 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "commit_sha", + "description": "The SHA of the commit.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "body", + "description": "The contents of the comment.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -36830,11 +42646,24 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", + "name": "path", + "description": "Relative path of the file to comment on.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "position", + "description": "Line index in the diff to comment on.", + "in": "BODY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -36843,11 +42672,11 @@ "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", + "name": "line", + "description": "**Deprecated**. Use **position** parameter instead. Line number in the file to comment on.", + "in": "BODY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -36856,20 +42685,27 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "Delete a pull request comment reaction", - "scope": "reactions", - "id": "deleteForPullRequestComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions/{reaction_id}", + "name": "Create commit signature protection", + "scope": "repos", + "id": "createCommitSignatureProtection", + "method": "POST", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE /repositories/:repository_id/pulls/comments/:comment_id/reactions/:reaction_id.`\n\nDelete a reaction to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#review-comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-a-pull-request-comment-reaction", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to require signed commits on a branch. You must enable branch protection to require signed commits.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#create-commit-signature-protection", "parameters": [ { "name": "owner", @@ -36886,7 +42722,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36898,23 +42734,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36924,20 +42747,23 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Delete a release reaction", - "scope": "reactions", - "id": "deleteForRelease", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions/{reaction_id}", + "name": "Create a commit status", + "scope": "repos", + "id": "createCommitStatus", + "method": "POST", + "url": "/repos/{owner}/{repo}/statuses/{sha}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a repository by `repository_id` using the route `DELETE delete /repositories/:repository_id/releases/:release_id/reactions/:reaction_id`.\n\nDelete a reaction to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#delete-a-release-reaction", + "description": "Users with push access in a repository can create commit statuses for a given SHA.\n\nNote: there is a limit of 1000 statuses per `sha` and `context` within a repository. Attempts to create more than 1000 statuses will result in a validation error.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#create-a-commit-status", "parameters": [ { "name": "owner", @@ -36954,7 +42780,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -36966,10 +42792,10 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", + "name": "sha", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -36979,41 +42805,12 @@ "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Delete team discussion reaction", - "scope": "reactions", - "id": "deleteForTeamDiscussion", - "method": "DELETE", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions/{reaction_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note:** You can also specify a team or organization with `team_id` and `org_id` using the route `DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions/:reaction_id`.\n\nDelete a reaction to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-team-discussion-reaction", - "parameters": [ - { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", + "name": "state", + "description": "The state of the status.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["error", "failure", "pending", "success"], "allowNull": false, "mapToData": null, "validation": null, @@ -37021,37 +42818,37 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", - "in": "PATH", + "name": "target_url", + "description": "The target URL to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the source of the status. \nFor example, if your continuous integration system is posting build status, you would want to provide the deep link for the build output for this specific SHA: \n`http://ci.example.com/user/repo/build/sha`", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "description", + "description": "A short description of the status.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "context", + "description": "A string label to differentiate this status from the status of other systems. This field is case-insensitive.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37060,24 +42857,24 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "Delete team discussion comment reaction", - "scope": "reactions", - "id": "deleteForTeamDiscussionComment", - "method": "DELETE", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions/{reaction_id}", + "name": "Create a deploy key", + "scope": "repos", + "id": "createDeployKey", + "method": "POST", + "url": "/repos/{owner}/{repo}/keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** You can also specify a team or organization with `team_id` and `org_id` using the route `DELETE /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions/:reaction_id`.\n\nDelete a reaction to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#delete-team-discussion-comment-reaction", + "description": "You can create a read-only deploy key.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deploy-keys#create-a-deploy-key", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37089,8 +42886,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37102,11 +42899,11 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "title", + "description": "A name for the key.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37115,10 +42912,10 @@ "deprecated": null }, { - "name": "comment_number", - "description": "The number that identifies the comment.", - "in": "PATH", - "type": "integer", + "name": "key", + "description": "The contents of the key.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -37128,11 +42925,11 @@ "deprecated": null }, { - "name": "reaction_id", - "description": "The unique identifier of the reaction.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "read_only", + "description": "If `true`, the key will only be able to read repository contents. Otherwise, the key will be able to read and write. \n \nDeploy keys with write access can perform the same actions as an organization member with admin access, or a collaborator on a personal repository. For more information, see \"[Repository permission levels for an organization](https://docs.github.com/enterprise-cloud@latest//articles/repository-permission-levels-for-an-organization/)\" and \"[Permission levels for a user account repository](https://docs.github.com/enterprise-cloud@latest//articles/permission-levels-for-a-user-account-repository/).\"", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37141,20 +42938,26 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 201, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List reactions for a commit comment", - "scope": "reactions", - "id": "listForCommitComment", - "method": "GET", - "url": "/repos/{owner}/{repo}/comments/{comment_id}/reactions", + "name": "Create a deployment", + "scope": "repos", + "id": "createDeployment", + "method": "POST", + "url": "/repos/{owner}/{repo}/deployments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the reactions to a [commit comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-commit-comment", + "description": "Deployments offer a few configurable parameters with certain defaults.\n\nThe `ref` parameter can be any named branch, tag, or SHA. At GitHub Enterprise Cloud we often deploy branches and verify them\nbefore we merge a pull request.\n\nThe `environment` parameter allows deployments to be issued to different runtime environments. Teams often have\nmultiple environments for verifying their applications, such as `production`, `staging`, and `qa`. This parameter\nmakes it easier to track which environments have requested deployments. The default environment is `production`.\n\nThe `auto_merge` parameter is used to ensure that the requested ref is not behind the repository's default branch. If\nthe ref _is_ behind the default branch for the repository, we will attempt to merge it for you. If the merge succeeds,\nthe API will return a successful merge commit. If merge conflicts prevent the merge from succeeding, the API will\nreturn a failure response.\n\nBy default, [commit statuses](https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses) for every submitted context must be in a `success`\nstate. The `required_contexts` parameter allows you to specify a subset of contexts that must be `success`, or to\nspecify contexts that have not yet been submitted. You are not required to use commit statuses to deploy. If you do\nnot require any contexts or create any commit statuses, the deployment will always succeed.\n\nThe `payload` parameter is available for any extra information that a deployment system might need. It is a JSON text\nfield that will be passed on when a deployment event is dispatched.\n\nThe `task` parameter is used by the deployment system to allow different execution paths. In the web world this might\nbe `deploy:migrations` to run schema changes on the system. In the compiled world this could be a flag to compile an\napplication with debugging enabled.\n\nUsers with `repo` or `repo_deployment` scopes can create a deployment for a given ref.\n\n#### Merged branch response\nYou will see this response when GitHub automatically merges the base branch into the topic branch instead of creating\na deployment. This auto-merge happens when:\n* Auto-merge option is enabled in the repository\n* Topic branch does not include the latest changes on the base branch, which is `master` in the response example\n* There are no merge conflicts\n\nIf there are no new commits in the base branch, a new request to create a deployment should give a successful\nresponse.\n\n#### Merge conflict response\nThis error happens when the `auto_merge` option is enabled and when the default branch (in this case `master`), can't\nbe merged into the branch that's being deployed (in this case `topic-branch`), due to merge conflicts.\n\n#### Failed commit status checks\nThis error happens when the `required_contexts` parameter indicates that one or more contexts need to have a `success`\nstatus for the commit to be deployed, but one or more of the required contexts do not have a state of `success`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployments#create-a-deployment", "parameters": [ { "name": "owner", @@ -37171,7 +42974,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37183,10 +42986,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", - "type": "integer", + "name": "ref", + "description": "The ref to deploy. This can be a branch, tag, or SHA.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -37196,21 +42999,12 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a commit comment.", - "in": "QUERY", + "name": "task", + "description": "Specifies a task to execute (e.g., `deploy` or `deploy:migrations`).", + "in": "BODY", "type": "string", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -37218,10 +43012,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "auto_merge", + "description": "Attempts to automatically merge the default branch into the requested ref, if it's behind the default branch.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37231,10 +43025,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "required_contexts", + "description": "The [status](https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses) contexts to verify against commit status checks. If you omit this parameter, GitHub verifies all unique contexts before creating a deployment. To bypass checking entirely, pass an empty array. Defaults to all unique contexts.", + "in": "BODY", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -37242,45 +43036,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "List reactions for an issue", - "scope": "reactions", - "id": "listForIssue", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/{issue_number}/reactions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List the reactions to an [issue](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-an-issue", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "payload", + "description": "", + "in": "BODY", + "type": null, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37289,11 +43051,11 @@ "deprecated": null }, { - "name": "issue_number", - "description": "The number that identifies the issue.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "environment", + "description": "Name for the target deployment environment (e.g., `production`, `staging`, `qa`).", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37302,32 +43064,23 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to an issue.", - "in": "QUERY", + "name": "description", + "description": "Short description of the deployment.", + "in": "BODY", "type": "string", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], - "allowNull": false, + "enum": null, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "transient_environment", + "description": "Specifies if the given environment is specific to the deployment and will no longer exist at some point in the future. Default: `false`", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37337,10 +43090,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "production_environment", + "description": "Specifies if the given environment is one that end-users directly interact with. Default: `true` when `environment` is `production` and `false` otherwise.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37351,23 +43104,30 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 410, "description": "Gone" } + { "code": 201, "description": "Response" }, + { "code": 202, "description": "Merged branch response" }, + { + "code": 409, + "description": "Conflict when there is a merge conflict or the commit's status checks failed" + }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List reactions for an issue comment", - "scope": "reactions", - "id": "listForIssueComment", - "method": "GET", - "url": "/repos/{owner}/{repo}/issues/comments/{comment_id}/reactions", + "name": "Create a deployment branch policy", + "scope": "repos", + "id": "createDeploymentBranchPolicy", + "method": "POST", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the reactions to an [issue comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/issues#comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-an-issue-comment", + "description": "Creates a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#create-deployment-branch-policy", "parameters": [ { "name": "owner", @@ -37384,7 +43144,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37396,10 +43156,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -37409,46 +43169,11 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to an issue comment.", - "in": "QUERY", + "name": "name", + "description": "The name pattern that branches must match in order to deploy to the environment.\n\nWildcard characters will not match `/`. For example, to match branches that begin with `release/` and contain an additional single slash, use `release/*/*`.\nFor more information about pattern matching syntax, see the [Ruby File.fnmatch documentation](https://ruby-doc.org/core-2.5.1/File.html#method-c-fnmatch).", + "in": "BODY", "type": "string", - "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -37459,25 +43184,32 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 303, + "description": "Response if the same branch name pattern already exists" + }, + { + "code": 404, + "description": "Not Found or `deployment_branch_policy.custom_branch_policies` property for the environment is set to false" + } ], "renamed": null }, { - "name": "List reactions for a pull request review comment", - "scope": "reactions", - "id": "listForPullRequestReviewComment", - "method": "GET", - "url": "/repos/{owner}/{repo}/pulls/comments/{comment_id}/reactions", + "name": "Create a custom deployment protection rule on an environment", + "scope": "repos", + "id": "createDeploymentProtectionRule", + "method": "POST", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the reactions to a [pull request review comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/pulls#review-comments).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-pull-request-review-comment", + "description": "Enable a custom deployment protection rule for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. Enabling a custom protection rule requires admin or owner permissions to the repository. GitHub Apps must have the `actions:write` permission to use this endpoint.\n\nFor more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#get-an-app).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployment-protection-rules#create-a-deployment-protection-rule", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -37490,7 +43222,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37502,46 +43234,11 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a pull request review comment.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -37550,9 +43247,9 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "integration_id", + "description": "The ID of the custom app that will be enabled on the environment.", + "in": "BODY", "type": "integer", "required": false, "enum": null, @@ -37564,22 +43261,24 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 201, + "description": "The enabled custom deployment protection rule" + } ], "renamed": null }, { - "name": "List reactions for a release", - "scope": "reactions", - "id": "listForRelease", - "method": "GET", - "url": "/repos/{owner}/{repo}/releases/{release_id}/reactions", + "name": "Create a deployment status", + "scope": "repos", + "id": "createDeploymentStatus", + "method": "POST", + "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the reactions to a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-release", + "description": "Users with `push` access can create deployment statuses for a given deployment.\n\nGitHub Apps require `read & write` access to \"Deployments\" and `read-only` access to \"Repo contents\" (for private repos). OAuth Apps require the `repo_deployment` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/statuses#create-a-deployment-status", "parameters": [ { "name": "owner", @@ -37596,7 +43295,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37608,8 +43307,8 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", + "name": "deployment_id", + "description": "deployment_id parameter", "in": "PATH", "type": "integer", "required": true, @@ -37621,12 +43320,33 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a release.", - "in": "QUERY", + "name": "state", + "description": "The state of the status. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "error", + "failure", + "inactive", + "in_progress", + "queued", + "pending", + "success" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "target_url", + "description": "The target URL to associate with this status. This URL should contain output to keep the user updated while the task is running or serve as historical information for what happened in the deployment. **Note:** It's recommended to use the `log_url` parameter, which replaces `target_url`.", + "in": "BODY", "type": "string", "required": false, - "enum": ["+1", "laugh", "heart", "hooray", "rocket", "eyes"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -37634,10 +43354,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "log_url", + "description": "The full URL of the deployment's output. This parameter replaces `target_url`. We will continue to accept `target_url` to support legacy uses, but we recommend replacing `target_url` with `log_url`. Setting `log_url` will automatically set `target_url` to the same value. Default: `\"\"`", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -37647,10 +43367,49 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "description", + "description": "A short description of the status. The maximum description length is 140 characters.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "environment", + "description": "Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["production", "staging", "qa"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "environment_url", + "description": "Sets the URL for accessing your environment. Default: `\"\"`", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "auto_inactive", + "description": "Adds a new `inactive` status to all prior non-transient, non-production environment deployments with the same repository and `environment` name as the created status's deployment. An `inactive` status is only added to deployments that had a `success` state. Default: `true`", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37661,26 +43420,29 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 201, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List reactions for a team discussion comment", - "scope": "reactions", - "id": "listForTeamDiscussionCommentInOrg", - "method": "GET", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/comments/{comment_number}/reactions", + "name": "Create a repository dispatch event", + "scope": "repos", + "id": "createDispatchEvent", + "method": "POST", + "url": "/repos/{owner}/{repo}/dispatches", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List the reactions to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments/). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/:org_id/team/:team_id/discussions/:discussion_number/comments/:comment_number/reactions`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion-comment", + "description": "You can use this endpoint to trigger a webhook event called `repository_dispatch` when you want activity that happens outside of GitHub Enterprise Cloud to trigger a GitHub Actions workflow or GitHub App webhook. You must configure your GitHub Actions workflow or GitHub App to run when the `repository_dispatch` event occurs. For an example `repository_dispatch` webhook payload, see \"[RepositoryDispatchEvent](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#repository_dispatch).\"\n\nThe `client_payload` parameter is available for any extra information that your workflow might need. This parameter is a JSON payload that will be passed on when the webhook event is dispatched. For example, the `client_payload` can include a message that a user would like to send using a GitHub Actions workflow. Or the `client_payload` can be used as a test to debug your workflow.\n\nThis endpoint requires write access to the repository by providing either:\n\n - Personal access tokens with `repo` scope. For more information, see \"[Creating a personal access token for the command line](https://docs.github.com/enterprise-cloud@latest//articles/creating-a-personal-access-token-for-the-command-line)\" in the GitHub Help documentation.\n - GitHub Apps with both `metadata:read` and `contents:read&write` permissions.\n\nThis input example shows how you can use the `client_payload` as a test to debug your workflow.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-dispatch-event", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37692,8 +43454,8 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -37705,10 +43467,10 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", + "name": "event_type", + "description": "A custom webhook event name. Must be 100 characters or fewer.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -37718,11 +43480,11 @@ "deprecated": null }, { - "name": "comment_number", - "description": "The number that identifies the comment.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "client_payload", + "description": "JSON payload with extra information about the webhook event that your action or workflow may use. The maximum number of top-level properties is 10.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37731,21 +43493,47 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion comment.", - "in": "QUERY", - "type": "string", + "name": "client_payload.*", + "description": "", + "in": "BODY", + "type": "object", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Create a repository for the authenticated user", + "scope": "repos", + "id": "createForAuthenticatedUser", + "method": "POST", + "url": "/user/repos", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a new repository for the authenticated user.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-for-the-authenticated-user", + "parameters": [ + { + "name": "name", + "description": "The name of the repository.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -37753,10 +43541,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "description", + "description": "A short description of the repository.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -37766,10 +43554,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "homepage", + "description": "A URL with more information about the repository.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -37777,29 +43565,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List reactions for a team discussion comment (Legacy)", - "scope": "reactions", - "id": "listForTeamDiscussionCommentLegacy", - "method": "GET", - "url": "/teams/{team_id}/discussions/{discussion_number}/comments/{comment_number}/reactions", - "isDeprecated": true, - "deprecationDate": "2020-02-26", - "removalDate": "2021-02-21", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`List reactions for a team discussion comment`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion-comment) endpoint.\n\nList the reactions to a [team discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussion-comments). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-team-discussion-comment-legacy", - "parameters": [ + }, { - "name": "team_id", - "description": "The unique identifier of the team.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "private", + "description": "Whether the repository is private.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37808,11 +43580,11 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "has_issues", + "description": "Whether issues are enabled.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37821,11 +43593,11 @@ "deprecated": null }, { - "name": "comment_number", - "description": "The number that identifies the comment.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "has_projects", + "description": "Whether projects are enabled.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37834,21 +43606,12 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion comment.", - "in": "QUERY", - "type": "string", + "name": "has_wiki", + "description": "Whether the wiki is enabled.", + "in": "BODY", + "type": "boolean", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -37856,10 +43619,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "has_discussions", + "description": "Whether discussions are enabled.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37869,9 +43632,9 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "team_id", + "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repository in an organization.", + "in": "BODY", "type": "integer", "required": false, "enum": null, @@ -37880,29 +43643,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List reactions for a team discussion", - "scope": "reactions", - "id": "listForTeamDiscussionInOrg", - "method": "GET", - "url": "/orgs/{org}/teams/{team_slug}/discussions/{discussion_number}/reactions", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List the reactions to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/:org_id/team/:team_id/discussions/:discussion_number/reactions`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "auto_init", + "description": "Whether the repository is initialized with a minimal README.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37911,11 +43658,11 @@ "deprecated": null }, { - "name": "team_slug", - "description": "The slug of the team name.", - "in": "PATH", + "name": "gitignore_template", + "description": "The desired language or platform to apply to the .gitignore.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37924,11 +43671,11 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "license_template", + "description": "The license keyword of the open source license for this repository.", + "in": "BODY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -37937,21 +43684,12 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion.", - "in": "QUERY", - "type": "string", + "name": "allow_squash_merge", + "description": "Whether to allow squash merges for pull requests.", + "in": "BODY", + "type": "boolean", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -37959,10 +43697,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "allow_merge_commit", + "description": "Whether to allow merge commits for pull requests.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37972,10 +43710,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "allow_rebase_merge", + "description": "Whether to allow rebase merges for pull requests.", + "in": "BODY", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -37983,29 +43721,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List reactions for a team discussion (Legacy)", - "scope": "reactions", - "id": "listForTeamDiscussionLegacy", - "method": "GET", - "url": "/teams/{team_id}/discussions/{discussion_number}/reactions", - "isDeprecated": true, - "deprecationDate": "2020-02-26", - "removalDate": "2021-02-21", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`List reactions for a team discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#list-reactions-for-a-team-discussion) endpoint.\n\nList the reactions to a [team discussion](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#discussions). OAuth access tokens require the `read:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions/#list-reactions-for-a-team-discussion-legacy", - "parameters": [ + }, { - "name": "team_id", - "description": "The unique identifier of the team.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "allow_auto_merge", + "description": "Whether to allow Auto-merge to be used on pull requests.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38014,11 +43736,11 @@ "deprecated": null }, { - "name": "discussion_number", - "description": "The number that identifies the discussion.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "delete_branch_on_merge", + "description": "Whether to delete head branches when pull requests are merged", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38027,21 +43749,12 @@ "deprecated": null }, { - "name": "content", - "description": "Returns a single [reaction type](https://docs.github.com/enterprise-cloud@latest//rest/reference/reactions#reaction-types). Omit this parameter to list all reactions to a team discussion.", - "in": "QUERY", + "name": "squash_merge_commit_title", + "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", + "in": "BODY", "type": "string", "required": false, - "enum": [ - "+1", - "-1", - "laugh", - "confused", - "heart", - "hooray", - "rocket", - "eyes" - ], + "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], "allowNull": false, "mapToData": null, "validation": null, @@ -38049,12 +43762,12 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "squash_merge_commit_message", + "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], "allowNull": false, "mapToData": null, "validation": null, @@ -38062,83 +43775,50 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "merge_commit_title", + "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", + "in": "BODY", + "type": "string", "required": false, - "enum": null, + "enum": ["PR_TITLE", "MERGE_MESSAGE"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Accept a repository invitation", - "scope": "repos", - "id": "acceptInvitation", - "method": "PATCH", - "url": "/user/repository_invitations/{invitation_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#accept-a-repository-invitation", - "parameters": [ + }, { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "merge_commit_message", + "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["PR_BODY", "PR_TITLE", "BLANK"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "has_downloads", + "description": "Whether downloads are enabled.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" } - ], - "renamed": { - "before": { "scope": "repos", "id": "acceptInvitation" }, - "after": { - "scope": "repos", - "id": "acceptInvitationForAuthenticatedUser" }, - "date": "2021-10-05", - "note": null - } - }, - { - "name": "Accept a repository invitation", - "scope": "repos", - "id": "acceptInvitationForAuthenticatedUser", - "method": "PATCH", - "url": "/user/repository_invitations/{invitation_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#accept-a-repository-invitation", - "parameters": [ { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "is_template", + "description": "Whether this repository acts as a template that can be used to generate new repositories.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38148,25 +43828,31 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 201, "description": "Response" }, { "code": 304, "description": "Not modified" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 401, "description": "Requires authentication" }, { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Add app access restrictions", + "name": "Create a fork", "scope": "repos", - "id": "addAppAccessRestrictions", + "id": "createFork", "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", + "url": "/repos/{owner}/{repo}/forks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified apps push access for this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.\n\n| Type | Description |\n| ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | The GitHub Apps that have push access to this branch. Use the app's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#add-app-access-restrictions", + "description": "Create a fork for the authenticated user.\n\n**Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api).\n\n**Note**: Although this endpoint works with GitHub Apps, the GitHub App must be installed on the destination account with access to all repositories and on the source account with access to the source repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-fork", "parameters": [ { "name": "owner", @@ -38183,7 +43869,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -38195,11 +43881,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "organization", + "description": "Optional parameter to specify the organization name if forking into an organization.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38208,21 +43894,38 @@ "deprecated": null }, { - "name": "apps", - "description": "", + "name": "name", + "description": "When forking from an existing repository, a new name for the fork.", "in": "BODY", - "type": null, - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "default_branch_only", + "description": "When forking from an existing repository, fork with only the default branch.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 202, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -38231,20 +43934,20 @@ "renamed": null }, { - "name": "Add a repository collaborator", + "name": "Create an organization repository", "scope": "repos", - "id": "addCollaborator", - "method": "PUT", - "url": "/repos/{owner}/{repo}/collaborators/{username}", + "id": "createInOrg", + "method": "POST", + "url": "/orgs/{org}/repos", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\nAdding an outside collaborator may be restricted by enterprise administrators. For more information, see \"[Enforcing repository management policies in your enterprise](https://docs.github.com/enterprise-cloud@latest/admin/policies/enforcing-policies-for-your-enterprise/enforcing-repository-management-policies-in-your-enterprise#enforcing-a-policy-for-inviting-outside-collaborators-to-repositories).\"\n\nFor more information on permission levels, see \"[Repository permission levels for an organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/repository-permission-levels-for-an-organization#permission-levels-for-repositories-owned-by-an-organization)\". There are restrictions on which permissions can be granted to organization members when an organization base role is in place. In this case, the permission being given must be equal to or higher than the org base permission. Otherwise, the request will fail with:\n\n```\nCannot assign {member} permission of {role name}\n```\n\nNote that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"\n\nThe invitee will receive a notification that they have been invited to the repository, which they must accept or decline. They may do this via the notifications page, the email they receive, or by using the [repository invitations API endpoints](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#invitations).\n\n**Updating an existing collaborator's permission level**\n\nThe endpoint can also be used to change the permissions of an existing collaborator without first removing and re-adding the collaborator. To change the permissions, use the same endpoint and pass a different `permission` parameter. The response will be a `204`, with no other indication that the permission level changed.\n\n**Rate limits**\n\nYou are limited to sending 50 invitations to a repository per 24 hour period. Note there is no limit if you are inviting organization members to an organization repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#add-a-repository-collaborator", + "description": "Creates a new repository in the specified organization. The authenticated user must be a member of the organization.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-an-organization-repository", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -38256,9 +43959,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the repository.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -38269,11 +43972,11 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", + "name": "description", + "description": "A short description of the repository.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38282,8 +43985,8 @@ "deprecated": null }, { - "name": "permission", - "description": "The permission to grant the collaborator. **Only valid on organization-owned repositories.** We accept the following permissions to be set: `pull`, `triage`, `push`, `maintain`, `admin` and you can also specify a custom repository role name, if the owning organization has defined any.", + "name": "homepage", + "description": "A URL with more information about the repository.", "in": "BODY", "type": "string", "required": false, @@ -38293,43 +43996,52 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ + }, { - "code": 201, - "description": "Response when a new invitation is created" + "name": "private", + "description": "Whether the repository is private.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "code": 204, - "description": "Response when:\n- an existing collaborator is added as a collaborator\n- an organization member is added as an individual collaborator\n- an existing team member (whose team is also a repository collaborator) is added as an individual collaborator" + "name": "visibility", + "description": "The visibility of the repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["public", "private", "internal"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, - { "code": 403, "description": "Forbidden" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Add status check contexts", - "scope": "repos", - "id": "addStatusCheckContexts", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#add-status-check-contexts", - "parameters": [ + "name": "has_issues", + "description": "Either `true` to enable issues for this repository or `false` to disable them.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "has_projects", + "description": "Either `true` to enable projects for this repository or `false` to disable them. **Note:** If you're creating a repository in an organization that has disabled repository projects, the default is `false`, and if you pass `true`, the API returns an error.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38338,11 +44050,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "has_wiki", + "description": "Either `true` to enable the wiki for this repository or `false` to disable it.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38351,11 +44063,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "has_downloads", + "description": "Whether downloads are enabled.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38364,48 +44076,37 @@ "deprecated": null }, { - "name": "contexts", - "description": "", + "name": "is_template", + "description": "Either `true` to make this repo available as a template repository or `false` to prevent it.", "in": "BODY", - "type": null, - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Add team access restrictions", - "scope": "repos", - "id": "addTeamAccessRestrictions", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified teams push access for this branch. You can also give push access to child teams.\n\n| Type | Description |\n| ------- | ------------------------------------------------------------------------------------------------------------------------------------------ |\n| `array` | The teams that can have push access. Use the team's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#add-team-access-restrictions", - "parameters": [ + "name": "team_id", + "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repository in an organization.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "auto_init", + "description": "Pass `true` to create an initial commit with empty README.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38414,11 +44115,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "gitignore_template", + "description": "Desired language or platform [.gitignore template](https://github.com/github/gitignore) to apply. Use the name of the template without the extension. For example, \"Haskell\".", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38427,11 +44128,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "license_template", + "description": "Choose an [open source license template](https://choosealicense.com/) that best suits your needs, and then use the [license keyword](https://docs.github.com/enterprise-cloud@latest//articles/licensing-a-repository/#searching-github-by-license-type) as the `license_template` string. For example, \"mit\" or \"mpl-2.0\".", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38440,46 +44141,37 @@ "deprecated": null }, { - "name": "teams", - "description": "", + "name": "allow_squash_merge", + "description": "Either `true` to allow squash-merging pull requests, or `false` to prevent squash-merging.", "in": "BODY", - "type": null, - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Add user access restrictions", - "scope": "repos", - "id": "addUserAccessRestrictions", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nGrants the specified people push access for this branch.\n\n| Type | Description |\n| ------- | ----------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames for people who can have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#add-user-access-restrictions", - "parameters": [ + "name": "allow_merge_commit", + "description": "Either `true` to allow merging pull requests with a merge commit, or `false` to prevent merging pull requests with merge commits.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_rebase_merge", + "description": "Either `true` to allow rebase-merging pull requests, or `false` to prevent rebase-merging.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38488,11 +44180,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_auto_merge", + "description": "Either `true` to allow auto-merge on pull requests, or `false` to disallow auto-merge.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38501,11 +44193,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "delete_branch_on_merge", + "description": "Either `true` to allow automatically deleting head branches when pull requests are merged, or `false` to prevent automatic deletion. **The authenticated user must be an organization owner to set this property to `true`.**", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38514,21 +44206,74 @@ "deprecated": null }, { - "name": "users", - "description": "", + "name": "use_squash_pr_title_as_default", + "description": "Either `true` to allow squash-merge commits to use pull request title, or `false` to use commit message. **This property has been deprecated. Please use `squash_merge_commit_title` instead.", "in": "BODY", - "type": null, - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "squash_merge_commit_title", + "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "squash_merge_commit_message", + "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "merge_commit_title", + "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["PR_TITLE", "MERGE_MESSAGE"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "merge_commit_message", + "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["PR_BODY", "PR_TITLE", "BLANK"], + "allowNull": false, + "mapToData": null, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -38537,16 +44282,16 @@ "renamed": null }, { - "name": "Check if a user is a repository collaborator", + "name": "Create or update an environment", "scope": "repos", - "id": "checkCollaborator", - "method": "GET", - "url": "/repos/{owner}/{repo}/collaborators/{username}", + "id": "createOrUpdateEnvironment", + "method": "PUT", + "url": "/repos/{owner}/{repo}/environments/{environment_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "For organization-owned repositories, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners.\n\nTeam members will include the members of child teams.\n\nYou must authenticate using an access token with the `read:org` and `repo` scopes with push access to use this\nendpoint. GitHub Apps must have the `members` organization permission and `metadata` repository permission to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#check-if-a-user-is-a-repository-collaborator", + "description": "Create or update an environment with protection rules, such as required reviewers. For more information about environment protection rules, see \"[Environments](/actions/reference/environments#environment-protection-rules).\"\n\n**Note:** To create or update name patterns that branches must match in order to deploy to this environment, see \"[Deployment branch policies](/rest/deployments/branch-policies).\"\n\n**Note:** To create or update secrets for an environment, see \"[Secrets](/rest/reference/actions#secrets).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/environments#create-or-update-an-environment", "parameters": [ { "name": "owner", @@ -38563,7 +44308,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -38575,8 +44320,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -38586,32 +44331,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response if user is a collaborator" }, - { "code": 404, "description": "Not Found if user is not a collaborator" } - ], - "renamed": null - }, - { - "name": "Check if vulnerability alerts are enabled for a repository", - "scope": "repos", - "id": "checkVulnerabilityAlerts", - "method": "GET", - "url": "/repos/{owner}/{repo}/vulnerability-alerts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Shows whether dependency alerts are enabled or disabled for a repository. The authenticated user must have admin read access to the repository. For more information, see \"[About security alerts for vulnerable dependencies](https://docs.github.com/en/articles/about-security-alerts-for-vulnerable-dependencies)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#check-if-vulnerability-alerts-are-enabled-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "wait_timer", + "description": "The amount of time to delay a job after the job is initially triggered. The time (in minutes) must be an integer between 0 and 43,200 (30 days).", + "in": "BODY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38620,49 +44346,37 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "reviewers", + "description": "The people or teams that may review jobs that reference the environment. You can list up to six users or teams as reviewers. The reviewers must have at least read access to the repository. Only one of the required reviewers needs to approve the job for it to proceed.", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { - "code": 204, - "description": "Response if repository is enabled with vulnerability alerts" }, { - "code": 404, - "description": "Not Found if repository is not enabled with vulnerability alerts" - } - ], - "renamed": null - }, - { - "name": "List CODEOWNERS errors", - "scope": "repos", - "id": "codeownersErrors", - "method": "GET", - "url": "/repos/{owner}/{repo}/codeowners/errors", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "List any syntax errors that are detected in the CODEOWNERS\nfile.\n\nFor more information about the correct CODEOWNERS syntax,\nsee \"[About code owners](https://docs.github.com/enterprise-cloud@latest//repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-codeowners-errors", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "reviewers[].type", + "description": "The type of reviewer.", + "in": "BODY", "type": "string", - "required": true, + "required": false, + "enum": ["User", "Team"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "reviewers[].id", + "description": "The id of the user or team who can review the deployment", + "in": "BODY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38671,10 +44385,23 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "deployment_branch_policy", + "description": "The type of deployment branch policy for this environment. To allow all branches to deploy, set to `null`.", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "deployment_branch_policy.protected_branches", + "description": "Whether only branches with branch protection rules can deploy to this environment. If `protected_branches` is `true`, `custom_branch_policies` must be `false`; if `protected_branches` is `false`, `custom_branch_policies` must be `true`.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -38684,11 +44411,11 @@ "deprecated": null }, { - "name": "ref", - "description": "A branch, tag or commit name used to determine which version of the CODEOWNERS file to use. Default: the repository's default branch (e.g. `main`)", - "in": "QUERY", - "type": "string", - "required": false, + "name": "deployment_branch_policy.custom_branch_policies", + "description": "Whether only branches that match the specified name patterns can deploy to this environment. If `custom_branch_policies` is `true`, `protected_branches` must be `false`; if `custom_branch_policies` is `false`, `protected_branches` must be `true`.", + "in": "BODY", + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -38699,25 +44426,28 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation error when the environment name is invalid or when `protected_branches` and `custom_branch_policies` in `deployment_branch_policy` are set to the same value" + } ], "renamed": null }, { - "name": "Compare two commits", + "name": "Create or update file contents", "scope": "repos", - "id": "compareCommits", - "method": "GET", - "url": "/repos/{owner}/{repo}/compare/{base}...{head}", + "id": "createOrUpdateFileContents", + "method": "PUT", + "url": "/repos/{owner}/{repo}/contents/{path}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Deprecated**: Use `repos.compareCommitsWithBasehead()` (`GET /repos/{owner}/{repo}/compare/{basehead}`) instead. Both `:base` and `:head` must be branch names in `:repo`. To compare branches across other repositories in the same network as `:repo`, use the format `:branch`.\n\nThe response from the API is equivalent to running the `git log base..head` command; however, commits are returned in chronological order. Pass the appropriate [media type](https://docs.github.com/rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.\n\nThe response also includes details on the files that were changed between the two commits. This includes the status of the change (for example, if a file was added, removed, modified, or renamed), and details of the change itself. For example, files with a `renamed` status have a `previous_filename` field showing the previous filename of the file, and files with a `modified` status have a `patch` field showing the changes made to the file.\n\n**Working with large comparisons**\n\nTo process a response with a large number of commits, you can use (`per_page` or `page`) to paginate the results. When using paging, the list of changed files is only returned with page 1, but includes all changed files for the entire comparison. For more information on working with pagination, see \"[Traversing with pagination](/rest/guides/traversing-with-pagination).\"\n\nWhen calling this API without any paging parameters (`per_page` or `page`), the returned list is limited to 250 commits and the last commit in the list is the most recent of the entire comparison. When a paging parameter is specified, the first commit in the returned list of each page is the earliest.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/rest/reference/repos#compare-two-commits", + "description": "Creates a new file or replaces an existing file in a repository. You must authenticate using an access token with the `workflow` scope to use this endpoint.\n\n**Note:** If you use this endpoint and the \"[Delete a file](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#delete-file)\" endpoint in parallel, the concurrent requests will conflict and you will receive errors. You must use these endpoints serially instead.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-or-update-file-contents", "parameters": [ { "name": "owner", - "description": "", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -38730,7 +44460,7 @@ }, { "name": "repo", - "description": "", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -38742,8 +44472,8 @@ "deprecated": null }, { - "name": "base", - "description": "", + "name": "path", + "description": "path parameter", "in": "PATH", "type": "string", "required": true, @@ -38755,9 +44485,9 @@ "deprecated": null }, { - "name": "head", - "description": "", - "in": "PATH", + "name": "message", + "description": "The commit message.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -38768,11 +44498,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "Results per page.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "content", + "description": "The new file content, using Base64 encoding.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -38781,44 +44511,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" } - ], - "renamed": null - }, - { - "name": "Compare two commits", - "scope": "repos", - "id": "compareCommitsWithBasehead", - "method": "GET", - "url": "/repos/{owner}/{repo}/compare/{basehead}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "The `basehead` param is comprised of two parts: `base` and `head`. Both must be branch names in `repo`. To compare branches across other repositories in the same network as `repo`, use the format `:branch`.\n\nThe response from the API is equivalent to running the `git log base..head` command; however, commits are returned in chronological order. Pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch diff and patch formats.\n\nThe response also includes details on the files that were changed between the two commits. This includes the status of the change (for example, if a file was added, removed, modified, or renamed), and details of the change itself. For example, files with a `renamed` status have a `previous_filename` field showing the previous filename of the file, and files with a `modified` status have a `patch` field showing the changes made to the file.\n\n**Working with large comparisons**\n\nTo process a response with a large number of commits, you can use (`per_page` or `page`) to paginate the results. When using paging, the list of changed files is only returned with page 1, but includes all changed files for the entire comparison. For more information on working with pagination, see \"[Traversing with pagination](/rest/guides/traversing-with-pagination).\"\n\nWhen calling this API without any paging parameters (`per_page` or `page`), the returned list is limited to 250 commits and the last commit in the list is the most recent of the entire comparison. When a paging parameter is specified, the first commit in the returned list of each page is the earliest.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#compare-two-commits", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "sha", + "description": "**Required if you are updating a file**. The blob SHA of the file being replaced.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38827,11 +44524,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "branch", + "description": "The branch name. Default: the repository’s default branch.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38840,10 +44537,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "committer", + "description": "The person that committed the file. Default: the authenticated user.", + "in": "BODY", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -38853,11 +44550,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "committer.name", + "description": "The name of the author or committer of the commit. You'll receive a `422` status code if `name` is omitted.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -38866,9 +44563,9 @@ "deprecated": null }, { - "name": "basehead", - "description": "The base branch and head branch to compare. This parameter expects the format `{base}...{head}`.", - "in": "PATH", + "name": "committer.email", + "description": "The email of the author or committer of the commit. You'll receive a `422` status code if `email` is omitted.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -38877,34 +44574,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 500, "description": "Internal Error" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "Create an autolink reference for a repository", - "scope": "repos", - "id": "createAutolink", - "method": "POST", - "url": "/repos/{owner}/{repo}/autolinks", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Users with admin access to the repository can create an autolink.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//v3/repos#create-an-autolink", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "committer.date", + "description": "", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38913,11 +44589,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "author", + "description": "The author of the file. Default: The `committer` or the authenticated user if you omit `committer`.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -38926,8 +44602,8 @@ "deprecated": null }, { - "name": "key_prefix", - "description": "This prefix appended by certain characters will generate a link any time it is found in an issue, pull request, or commit.", + "name": "author.name", + "description": "The name of the author or committer of the commit. You'll receive a `422` status code if `name` is omitted.", "in": "BODY", "type": "string", "required": true, @@ -38939,8 +44615,8 @@ "deprecated": null }, { - "name": "url_template", - "description": "The URL must contain `` for the reference number. `` matches different characters depending on the value of `is_alphanumeric`.", + "name": "author.email", + "description": "The email of the author or committer of the commit. You'll receive a `422` status code if `email` is omitted.", "in": "BODY", "type": "string", "required": true, @@ -38952,10 +44628,10 @@ "deprecated": null }, { - "name": "is_alphanumeric", - "description": "Whether this autolink reference matches alphanumeric characters. If true, the `` parameter of the `url_template` matches alphanumeric characters `A-Z` (case insensitive), `0-9`, and `-`. If false, this autolink reference only matches numeric characters.", + "name": "author.date", + "description": "", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -38966,7 +44642,10 @@ } ], "responses": [ - { "code": 201, "description": "response" }, + { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -38975,20 +44654,20 @@ "renamed": null }, { - "name": "Create a commit comment", + "name": "Create an organization repository ruleset", "scope": "repos", - "id": "createCommitComment", + "id": "createOrgRuleset", "method": "POST", - "url": "/repos/{owner}/{repo}/commits/{commit_sha}/comments", + "url": "/orgs/{org}/rulesets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a comment for a commit using its `:commit_sha`.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#create-a-commit-comment", + "description": "Create a repository ruleset for an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#create-organization-repository-ruleset", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -39000,9 +44679,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the ruleset.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -39013,12 +44692,12 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit.", - "in": "PATH", + "name": "target", + "description": "The target of the ruleset.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["branch", "tag"], "allowNull": false, "mapToData": null, "validation": null, @@ -39026,12 +44705,12 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the comment.", + "name": "enforcement", + "description": "The enforcement level of the ruleset. `evaluate` allows admins to test rules before enforcing them. Admins can view insights on the Rule Insights page.", "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["disabled", "active", "evaluate"], "allowNull": false, "mapToData": null, "validation": null, @@ -39039,10 +44718,10 @@ "deprecated": null }, { - "name": "path", - "description": "Relative path of the file to comment on.", + "name": "bypass_actors", + "description": "The actors that can bypass the rules in this ruleset", "in": "BODY", - "type": "string", + "type": "object[]", "required": false, "enum": null, "allowNull": false, @@ -39052,8 +44731,8 @@ "deprecated": null }, { - "name": "position", - "description": "Line index in the diff to comment on.", + "name": "bypass_actors[].actor_id", + "description": "The ID of the actor that can bypass a ruleset", "in": "BODY", "type": "integer", "required": false, @@ -39065,47 +44744,24 @@ "deprecated": null }, { - "name": "line", - "description": "**Deprecated**. Use **position** parameter instead. Line number in the file to comment on.", + "name": "bypass_actors[].actor_type", + "description": "The type of actor that can bypass a ruleset", "in": "BODY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["Team", "Integration"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create commit signature protection", - "scope": "repos", - "id": "createCommitSignatureProtection", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to require signed commits on a branch. You must enable branch protection to require signed commits.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-commit-signature-protection", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "conditions", + "description": "Conditions for a organization ruleset", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39114,11 +44770,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "rules", + "description": "An array of rules within the ruleset.", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39127,43 +44783,24 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "rules[].type", + "description": "", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["tag_name_pattern"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Create a commit status", - "scope": "repos", - "id": "createCommitStatus", - "method": "POST", - "url": "/repos/{owner}/{repo}/statuses/{sha}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Users with push access in a repository can create commit statuses for a given SHA.\n\nNote: there is a limit of 1000 statuses per `sha` and `context` within a repository. Attempts to create more than 1000 statuses will result in a validation error.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#create-a-commit-status", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "rules[].parameters", + "description": "", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39172,10 +44809,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "rules[].parameters.update_allows_fetch_and_merge", + "description": "Branch can pull changes from its upstream repository", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -39185,10 +44822,10 @@ "deprecated": null }, { - "name": "sha", - "description": "", - "in": "PATH", - "type": "string", + "name": "rules[].parameters.required_deployment_environments", + "description": "The environments that must be successfully deployed to before branches can be merged.", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -39198,12 +44835,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the status.", + "name": "rules[].parameters.dismiss_stale_reviews_on_push", + "description": "New, reviewable commits pushed will dismiss previous pull request review approvals.", "in": "BODY", - "type": "string", + "type": "boolean", "required": true, - "enum": ["error", "failure", "pending", "success"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -39211,65 +44848,36 @@ "deprecated": null }, { - "name": "target_url", - "description": "The target URL to associate with this status. This URL will be linked from the GitHub UI to allow users to easily see the source of the status. \nFor example, if your continuous integration system is posting build status, you would want to provide the deep link for the build output for this specific SHA: \n`http://ci.example.com/user/repo/build/sha`", + "name": "rules[].parameters.require_code_owner_review", + "description": "Require an approving review in pull requests that modify files that have a designated code owner.", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "description", - "description": "A short description of the status.", + "name": "rules[].parameters.require_last_push_approval", + "description": "Whether the most recent reviewable push must be approved by someone other than the person who pushed it.", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "context", - "description": "A string label to differentiate this status from the status of other systems. This field is case-insensitive.", + "name": "rules[].parameters.required_approving_review_count", + "description": "The number of approving reviews that are required before a pull request can be merged.", "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Create a deploy key", - "scope": "repos", - "id": "createDeployKey", - "method": "POST", - "url": "/repos/{owner}/{repo}/keys", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "You can create a read-only deploy key.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-deploy-key", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -39279,10 +44887,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "rules[].parameters.required_review_thread_resolution", + "description": "All conversations on code must be resolved before a pull request can be merged.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -39292,11 +44900,11 @@ "deprecated": null }, { - "name": "title", - "description": "A name for the key.", + "name": "rules[].parameters.required_status_checks", + "description": "Status checks that are required.", "in": "BODY", - "type": "string", - "required": false, + "type": "object[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39305,8 +44913,8 @@ "deprecated": null }, { - "name": "key", - "description": "The contents of the key.", + "name": "rules[].parameters.required_status_checks[].context", + "description": "The status check context name that must be present on the commit.", "in": "BODY", "type": "string", "required": true, @@ -39318,10 +44926,10 @@ "deprecated": null }, { - "name": "read_only", - "description": "If `true`, the key will only be able to read repository contents. Otherwise, the key will be able to read and write. \n \nDeploy keys with write access can perform the same actions as an organization member with admin access, or a collaborator on a personal repository. For more information, see \"[Repository permission levels for an organization](https://docs.github.com/articles/repository-permission-levels-for-an-organization/)\" and \"[Permission levels for a user account repository](https://docs.github.com/articles/permission-levels-for-a-user-account-repository/).\"", + "name": "rules[].parameters.required_status_checks[].integration_id", + "description": "The optional integration ID that this status check must originate from.", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -39329,34 +44937,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a deployment", - "scope": "repos", - "id": "createDeployment", - "method": "POST", - "url": "/repos/{owner}/{repo}/deployments", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Deployments offer a few configurable parameters with certain defaults.\n\nThe `ref` parameter can be any named branch, tag, or SHA. At GitHub Enterprise Cloud we often deploy branches and verify them\nbefore we merge a pull request.\n\nThe `environment` parameter allows deployments to be issued to different runtime environments. Teams often have\nmultiple environments for verifying their applications, such as `production`, `staging`, and `qa`. This parameter\nmakes it easier to track which environments have requested deployments. The default environment is `production`.\n\nThe `auto_merge` parameter is used to ensure that the requested ref is not behind the repository's default branch. If\nthe ref _is_ behind the default branch for the repository, we will attempt to merge it for you. If the merge succeeds,\nthe API will return a successful merge commit. If merge conflicts prevent the merge from succeeding, the API will\nreturn a failure response.\n\nBy default, [commit statuses](https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses) for every submitted context must be in a `success`\nstate. The `required_contexts` parameter allows you to specify a subset of contexts that must be `success`, or to\nspecify contexts that have not yet been submitted. You are not required to use commit statuses to deploy. If you do\nnot require any contexts or create any commit statuses, the deployment will always succeed.\n\nThe `payload` parameter is available for any extra information that a deployment system might need. It is a JSON text\nfield that will be passed on when a deployment event is dispatched.\n\nThe `task` parameter is used by the deployment system to allow different execution paths. In the web world this might\nbe `deploy:migrations` to run schema changes on the system. In the compiled world this could be a flag to compile an\napplication with debugging enabled.\n\nUsers with `repo` or `repo_deployment` scopes can create a deployment for a given ref.\n\n#### Merged branch response\nYou will see this response when GitHub automatically merges the base branch into the topic branch instead of creating\na deployment. This auto-merge happens when:\n* Auto-merge option is enabled in the repository\n* Topic branch does not include the latest changes on the base branch, which is `master` in the response example\n* There are no merge conflicts\n\nIf there are no new commits in the base branch, a new request to create a deployment should give a successful\nresponse.\n\n#### Merge conflict response\nThis error happens when the `auto_merge` option is enabled and when the default branch (in this case `master`), can't\nbe merged into the branch that's being deployed (in this case `topic-branch`), due to merge conflicts.\n\n#### Failed commit status checks\nThis error happens when the `required_contexts` parameter indicates that one or more contexts need to have a `success`\nstatus for the commit to be deployed, but one or more of the required contexts do not have a state of `success`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-deployment", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "rules[].parameters.strict_required_status_checks_policy", + "description": "Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -39366,11 +44952,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "rules[].parameters.name", + "description": "How this rule will appear to users.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39379,11 +44965,11 @@ "deprecated": null }, { - "name": "ref", - "description": "The ref to deploy. This can be a branch, tag, or SHA.", + "name": "rules[].parameters.negate", + "description": "If true, the rule will fail if the pattern matches.", "in": "BODY", - "type": "string", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39392,12 +44978,12 @@ "deprecated": null }, { - "name": "task", - "description": "Specifies a task to execute (e.g., `deploy` or `deploy:migrations`).", + "name": "rules[].parameters.operator", + "description": "The operator to use for matching.", "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["starts_with", "ends_with", "contains", "regex"], "allowNull": false, "mapToData": null, "validation": null, @@ -39405,24 +44991,44 @@ "deprecated": null }, { - "name": "auto_merge", - "description": "Attempts to automatically merge the default branch into the requested ref, if it's behind the default branch.", + "name": "rules[].parameters.pattern", + "description": "The pattern to match with.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Create a GitHub Pages deployment", + "scope": "repos", + "id": "createPagesDeployment", + "method": "POST", + "url": "/repos/{owner}/{repo}/pages/deployment", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Create a GitHub Pages deployment for a repository.\n\nUsers must have write permissions. GitHub Apps must have the `pages:write` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#create-a-github-pages-deployment", + "parameters": [ { - "name": "required_contexts", - "description": "The [status](https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses) contexts to verify against commit status checks. If you omit this parameter, GitHub verifies all unique contexts before creating a deployment. To bypass checking entirely, pass an empty array. Defaults to all unique contexts.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39431,11 +45037,11 @@ "deprecated": null }, { - "name": "payload", - "description": "", - "in": "BODY", - "type": null, - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39444,11 +45050,11 @@ "deprecated": null }, { - "name": "environment", - "description": "Name for the target deployment environment (e.g., `production`, `staging`, `qa`).", + "name": "artifact_url", + "description": "The URL of an artifact that contains the .zip or .tar of static assets to deploy. The artifact belongs to the repository.", "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39457,24 +45063,24 @@ "deprecated": null }, { - "name": "description", - "description": "Short description of the deployment.", + "name": "environment", + "description": "The target environment for this GitHub Pages deployment.", "in": "BODY", "type": "string", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "transient_environment", - "description": "Specifies if the given environment is specific to the deployment and will no longer exist at some point in the future. Default: `false`", + "name": "pages_build_version", + "description": "A unique string that represents the version of the build for this deployment.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39482,12 +45088,12 @@ "alias": null, "deprecated": null }, - { - "name": "production_environment", - "description": "Specifies if the given environment is one that end-users directly interact with. Default: `true` when `environment` is `production` and `false` otherwise.", + { + "name": "oidc_token", + "description": "The OIDC token issued by GitHub Actions certifying the origin of the deployment.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -39497,12 +45103,10 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 202, "description": "Merged branch response" }, - { - "code": 409, - "description": "Conflict when there is a merge conflict or the commit's status checks failed" - }, + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -39511,16 +45115,16 @@ "renamed": null }, { - "name": "Create a deployment branch policy", + "name": "Create a GitHub Enterprise Cloud Pages site", "scope": "repos", - "id": "createDeploymentBranchPolicy", + "id": "createPagesSite", "method": "POST", - "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies", + "url": "/repos/{owner}/{repo}/pages", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#create-deployment-branch-policy", + "description": "Configures a GitHub Enterprise Cloud Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).\"\n\nTo use this endpoint, you must be a repository administrator, maintainer, or have the 'manage GitHub Pages settings' permission. A token with the `repo` scope or Pages write permission is required. GitHub Apps must have the `administration:write` and `pages:write` permissions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#create-a-github-pages-site", "parameters": [ { "name": "owner", @@ -39537,7 +45141,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -39549,11 +45153,24 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", - "in": "PATH", + "name": "build_type", + "description": "The process in which the Page will be built. Possible values are `\"legacy\"` and `\"workflow\"`.", + "in": "BODY", "type": "string", - "required": true, + "required": false, + "enum": ["legacy", "workflow"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "source", + "description": "The source branch and directory used to publish your Pages site.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -39562,8 +45179,8 @@ "deprecated": null }, { - "name": "name", - "description": "The name pattern that branches must match in order to deploy to the environment.\n\nWildcard characters will not match `/`. For example, to match branches that begin with `release/` and contain an additional single slash, use `release/*/*`.\nFor more information about pattern matching syntax, see the [Ruby File.fnmatch documentation](https://ruby-doc.org/core-2.5.1/File.html#method-c-fnmatch).", + "name": "source.branch", + "description": "The repository branch used to publish your site's source files.", "in": "BODY", "type": "string", "required": true, @@ -39573,32 +45190,42 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "source.path", + "description": "The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. Default: `/`", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["/", "/docs"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 303, - "description": "Response if the same branch name pattern already exists" - }, + { "code": 201, "description": "Response" }, + { "code": 409, "description": "Conflict" }, { - "code": 404, - "description": "Not Found or `deployment_branch_policy.custom_branch_policies` property for the environment is set to false" + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], "renamed": null }, { - "name": "Create a deployment status", + "name": "Create a release", "scope": "repos", - "id": "createDeploymentStatus", + "id": "createRelease", "method": "POST", - "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", + "url": "/repos/{owner}/{repo}/releases", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with `push` access can create deployment statuses for a given deployment.\n\nGitHub Apps require `read & write` access to \"Deployments\" and `read-only` access to \"Repo contents\" (for private repos). OAuth Apps require the `repo_deployment` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-deployment-status", + "description": "Users with push access to the repository can create a release.\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/releases/releases#create-a-release", "parameters": [ { "name": "owner", @@ -39615,7 +45242,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -39627,10 +45254,10 @@ "deprecated": null }, { - "name": "deployment_id", - "description": "deployment_id parameter", - "in": "PATH", - "type": "integer", + "name": "tag_name", + "description": "The name of the tag.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -39640,20 +45267,12 @@ "deprecated": null }, { - "name": "state", - "description": "The state of the status. When you set a transient deployment to `inactive`, the deployment will be shown as `destroyed` in GitHub.", + "name": "target_commitish", + "description": "Specifies the commitish value that determines where the Git tag is created from. Can be any branch or commit SHA. Unused if the Git tag already exists. Default: the repository's default branch.", "in": "BODY", "type": "string", - "required": true, - "enum": [ - "error", - "failure", - "inactive", - "in_progress", - "queued", - "pending", - "success" - ], + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -39661,8 +45280,8 @@ "deprecated": null }, { - "name": "target_url", - "description": "The target URL to associate with this status. This URL should contain output to keep the user updated while the task is running or serve as historical information for what happened in the deployment. **Note:** It's recommended to use the `log_url` parameter, which replaces `target_url`.", + "name": "name", + "description": "The name of the release.", "in": "BODY", "type": "string", "required": false, @@ -39674,8 +45293,8 @@ "deprecated": null }, { - "name": "log_url", - "description": "The full URL of the deployment's output. This parameter replaces `target_url`. We will continue to accept `target_url` to support legacy uses, but we recommend replacing `target_url` with `log_url`. Setting `log_url` will automatically set `target_url` to the same value. Default: `\"\"`", + "name": "body", + "description": "Text describing the contents of the tag.", "in": "BODY", "type": "string", "required": false, @@ -39687,10 +45306,10 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the status. The maximum description length is 140 characters.", + "name": "draft", + "description": "`true` to create a draft (unpublished) release, `false` to create a published one.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -39700,12 +45319,12 @@ "deprecated": null }, { - "name": "environment", - "description": "Name for the target deployment environment, which can be changed when setting a deploy status. For example, `production`, `staging`, or `qa`.", + "name": "prerelease", + "description": "`true` to identify the release as a prerelease. `false` to identify the release as a full release.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, - "enum": ["production", "staging", "qa"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -39713,8 +45332,8 @@ "deprecated": null }, { - "name": "environment_url", - "description": "Sets the URL for accessing your environment. Default: `\"\"`", + "name": "discussion_category_name", + "description": "If specified, a discussion of the specified category is created and linked to the release. The value must be a category that already exists in the repository. For more information, see \"[Managing categories for discussions in your repository](https://docs.github.com/enterprise-cloud@latest//discussions/managing-discussions-for-your-community/managing-categories-for-discussions-in-your-repository).\"", "in": "BODY", "type": "string", "required": false, @@ -39726,8 +45345,8 @@ "deprecated": null }, { - "name": "auto_inactive", - "description": "Adds a new `inactive` status to all prior non-transient, non-production environment deployments with the same repository and `environment` name as the created status's deployment. An `inactive` status is only added to deployments that had a `success` state. Default: `true`", + "name": "generate_release_notes", + "description": "Whether to automatically generate the name and body for this release. If `name` is specified, the specified name will be used; otherwise, a name will be automatically generated. If `body` is specified, the body will be pre-pended to the automatically generated notes.", "in": "BODY", "type": "boolean", "required": false, @@ -39737,10 +45356,27 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "make_latest", + "description": "Specifies whether this release should be set as the latest release for the repository. Drafts and prereleases cannot be set as latest. Defaults to `true` for newly published releases. `legacy` specifies that the latest release should be determined based on the release creation date and higher semantic version.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["true", "false", "legacy"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 201, "description": "Response" }, + { + "code": 404, + "description": "Not Found if the discussion category name is invalid" + }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -39749,16 +45385,16 @@ "renamed": null }, { - "name": "Create a repository dispatch event", + "name": "Create a repository ruleset", "scope": "repos", - "id": "createDispatchEvent", + "id": "createRepoRuleset", "method": "POST", - "url": "/repos/{owner}/{repo}/dispatches", + "url": "/repos/{owner}/{repo}/rulesets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You can use this endpoint to trigger a webhook event called `repository_dispatch` when you want activity that happens outside of GitHub Enterprise Cloud to trigger a GitHub Actions workflow or GitHub App webhook. You must configure your GitHub Actions workflow or GitHub App to run when the `repository_dispatch` event occurs. For an example `repository_dispatch` webhook payload, see \"[RepositoryDispatchEvent](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#repository_dispatch).\"\n\nThe `client_payload` parameter is available for any extra information that your workflow might need. This parameter is a JSON payload that will be passed on when the webhook event is dispatched. For example, the `client_payload` can include a message that a user would like to send using a GitHub Actions workflow. Or the `client_payload` can be used as a test to debug your workflow.\n\nThis endpoint requires write access to the repository by providing either:\n\n - Personal access tokens with `repo` scope. For more information, see \"[Creating a personal access token for the command line](https://docs.github.com/articles/creating-a-personal-access-token-for-the-command-line)\" in the GitHub Help documentation.\n - GitHub Apps with both `metadata:read` and `contents:read&write` permissions.\n\nThis input example shows how you can use the `client_payload` as a test to debug your workflow.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-dispatch-event", + "description": "Create a ruleset for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#create-repository-ruleset", "parameters": [ { "name": "owner", @@ -39775,7 +45411,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -39787,8 +45423,8 @@ "deprecated": null }, { - "name": "event_type", - "description": "A custom webhook event name. Must be 100 characters or fewer.", + "name": "name", + "description": "The name of the ruleset.", "in": "BODY", "type": "string", "required": true, @@ -39800,12 +45436,12 @@ "deprecated": null }, { - "name": "client_payload", - "description": "JSON payload with extra information about the webhook event that your action or workflow may use.", + "name": "target", + "description": "The target of the ruleset.", "in": "BODY", - "type": "object", + "type": "string", "required": false, - "enum": null, + "enum": ["branch", "tag"], "allowNull": false, "mapToData": null, "validation": null, @@ -39813,47 +45449,25 @@ "deprecated": null }, { - "name": "client_payload.*", - "description": "", + "name": "enforcement", + "description": "The enforcement level of the ruleset. `evaluate` allows admins to test rules before enforcing them. Admins can view insights on the Rule Insights page.", "in": "BODY", - "type": "object", - "required": false, - "enum": null, + "type": "string", + "required": true, + "enum": ["disabled", "active", "evaluate"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a repository for the authenticated user", - "scope": "repos", - "id": "createForAuthenticatedUser", - "method": "POST", - "url": "/user/repos", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Creates a new repository for the authenticated user.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-for-the-authenticated-user", - "parameters": [ + }, { - "name": "name", - "description": "The name of the repository.", + "name": "bypass_mode", + "description": "The permission level required to bypass this ruleset. \"repository\" allows those with bypass permission at the repository level to bypass. \"organization\" allows those with bypass permission at the organization level to bypass. \"none\" prevents anyone from bypassing.", "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["none", "repository", "organization"], "allowNull": false, "mapToData": null, "validation": null, @@ -39861,10 +45475,10 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the repository.", + "name": "bypass_actors", + "description": "The actors that can bypass the rules in this ruleset", "in": "BODY", - "type": "string", + "type": "object[]", "required": false, "enum": null, "allowNull": false, @@ -39874,10 +45488,10 @@ "deprecated": null }, { - "name": "homepage", - "description": "A URL with more information about the repository.", + "name": "bypass_actors[].actor_id", + "description": "The ID of the actor that can bypass a ruleset", "in": "BODY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -39887,12 +45501,12 @@ "deprecated": null }, { - "name": "private", - "description": "Whether the repository is private.", + "name": "bypass_actors[].actor_type", + "description": "The type of actor that can bypass a ruleset", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, - "enum": null, + "enum": ["Team", "Integration"], "allowNull": false, "mapToData": null, "validation": null, @@ -39900,10 +45514,10 @@ "deprecated": null }, { - "name": "has_issues", - "description": "Whether issues are enabled.", + "name": "conditions", + "description": "Parameters for a repository ruleset ref name condition", "in": "BODY", - "type": "boolean", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -39913,10 +45527,10 @@ "deprecated": null }, { - "name": "has_projects", - "description": "Whether projects are enabled.", + "name": "conditions.ref_name", + "description": "", "in": "BODY", - "type": "boolean", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -39926,10 +45540,10 @@ "deprecated": null }, { - "name": "has_wiki", - "description": "Whether the wiki is enabled.", + "name": "conditions.ref_name.include", + "description": "Array of ref names or patterns to include. One of these patterns must match for the condition to pass. Also accepts `~DEFAULT_BRANCH` to include the default branch or `~ALL` to include all branches.", "in": "BODY", - "type": "boolean", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -39939,10 +45553,10 @@ "deprecated": null }, { - "name": "team_id", - "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repository in an organization.", + "name": "conditions.ref_name.exclude", + "description": "Array of ref names or patterns to exclude. The condition will not pass if any of these patterns match.", "in": "BODY", - "type": "integer", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -39952,10 +45566,10 @@ "deprecated": null }, { - "name": "auto_init", - "description": "Whether the repository is initialized with a minimal README.", + "name": "rules", + "description": "An array of rules within the ruleset.", "in": "BODY", - "type": "boolean", + "type": "object[]", "required": false, "enum": null, "allowNull": false, @@ -39965,12 +45579,12 @@ "deprecated": null }, { - "name": "gitignore_template", - "description": "The desired language or platform to apply to the .gitignore.", + "name": "rules[].type", + "description": "", "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["tag_name_pattern"], "allowNull": false, "mapToData": null, "validation": null, @@ -39978,10 +45592,10 @@ "deprecated": null }, { - "name": "license_template", - "description": "The license keyword of the open source license for this repository.", + "name": "rules[].parameters", + "description": "", "in": "BODY", - "type": "string", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -39991,11 +45605,11 @@ "deprecated": null }, { - "name": "allow_squash_merge", - "description": "Whether to allow squash merges for pull requests.", + "name": "rules[].parameters.update_allows_fetch_and_merge", + "description": "Branch can pull changes from its upstream repository", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40004,11 +45618,11 @@ "deprecated": null }, { - "name": "allow_merge_commit", - "description": "Whether to allow merge commits for pull requests.", + "name": "rules[].parameters.required_deployment_environments", + "description": "The environments that must be successfully deployed to before branches can be merged.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40017,11 +45631,11 @@ "deprecated": null }, { - "name": "allow_rebase_merge", - "description": "Whether to allow rebase merges for pull requests.", + "name": "rules[].parameters.dismiss_stale_reviews_on_push", + "description": "New, reviewable commits pushed will dismiss previous pull request review approvals.", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40030,11 +45644,11 @@ "deprecated": null }, { - "name": "allow_auto_merge", - "description": "Whether to allow Auto-merge to be used on pull requests.", + "name": "rules[].parameters.require_code_owner_review", + "description": "Require an approving review in pull requests that modify files that have a designated code owner.", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40043,11 +45657,11 @@ "deprecated": null }, { - "name": "delete_branch_on_merge", - "description": "Whether to delete head branches when pull requests are merged", + "name": "rules[].parameters.require_last_push_approval", + "description": "Whether the most recent reviewable push must be approved by someone other than the person who pushed it.", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40056,12 +45670,12 @@ "deprecated": null }, { - "name": "squash_merge_commit_title", - "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", + "name": "rules[].parameters.required_approving_review_count", + "description": "The number of approving reviews that are required before a pull request can be merged.", "in": "BODY", - "type": "string", - "required": false, - "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40069,12 +45683,12 @@ "deprecated": null }, { - "name": "squash_merge_commit_message", - "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "name": "rules[].parameters.required_review_thread_resolution", + "description": "All conversations on code must be resolved before a pull request can be merged.", "in": "BODY", - "type": "string", - "required": false, - "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], + "type": "boolean", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40082,12 +45696,12 @@ "deprecated": null }, { - "name": "merge_commit_title", - "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", + "name": "rules[].parameters.required_status_checks", + "description": "Status checks that are required.", "in": "BODY", - "type": "string", - "required": false, - "enum": ["PR_TITLE", "MERGE_MESSAGE"], + "type": "object[]", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40095,12 +45709,12 @@ "deprecated": null }, { - "name": "merge_commit_message", - "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "name": "rules[].parameters.required_status_checks[].context", + "description": "The status check context name that must be present on the commit.", "in": "BODY", "type": "string", - "required": false, - "enum": ["PR_BODY", "PR_TITLE", "BLANK"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40108,10 +45722,10 @@ "deprecated": null }, { - "name": "has_downloads", - "description": "Whether downloads are enabled.", + "name": "rules[].parameters.required_status_checks[].integration_id", + "description": "The optional integration ID that this status check must originate from.", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -40121,51 +45735,10 @@ "deprecated": null }, { - "name": "is_template", - "description": "Whether this repository acts as a template that can be used to generate new repositories.", + "name": "rules[].parameters.strict_required_status_checks_policy", + "description": "Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled.", "in": "BODY", "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a fork", - "scope": "repos", - "id": "createFork", - "method": "POST", - "url": "/repos/{owner}/{repo}/forks", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Create a fork for the authenticated user.\n\n**Note**: Forking a Repository happens asynchronously. You may have to wait a short period of time before you can access the git objects. If this takes longer than 5 minutes, be sure to contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-fork", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", "required": true, "enum": null, "allowNull": false, @@ -40175,11 +45748,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "rules[].parameters.name", + "description": "How this rule will appear to users.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -40188,10 +45761,10 @@ "deprecated": null }, { - "name": "organization", - "description": "Optional parameter to specify the organization name if forking into an organization.", + "name": "rules[].parameters.negate", + "description": "If true, the rule will fail if the pattern matches.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -40201,12 +45774,12 @@ "deprecated": null }, { - "name": "name", - "description": "When forking from an existing repository, a new name for the fork.", + "name": "rules[].parameters.operator", + "description": "The operator to use for matching.", "in": "BODY", "type": "string", - "required": false, - "enum": null, + "required": true, + "enum": ["starts_with", "ends_with", "contains", "regex"], "allowNull": false, "mapToData": null, "validation": null, @@ -40214,11 +45787,11 @@ "deprecated": null }, { - "name": "default_branch_only", - "description": "When forking from an existing repository, fork with only the default branch.", + "name": "rules[].parameters.pattern", + "description": "The pattern to match with.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40228,33 +45801,27 @@ } ], "responses": [ - { "code": 202, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 403, "description": "Forbidden" }, + { "code": 201, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Create an organization repository", + "name": "Create a tag protection state for a repository", "scope": "repos", - "id": "createInOrg", + "id": "createTagProtection", "method": "POST", - "url": "/orgs/{org}/repos", + "url": "/repos/{owner}/{repo}/tags/protection", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new repository in the specified organization. The authenticated user must be a member of the organization.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-an-organization-repository", + "description": "This creates a tag protection state for a repository.\nThis endpoint is only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-tag-protection-state-for-a-repository", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -40266,9 +45833,9 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the repository.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40279,24 +45846,44 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the repository.", + "name": "pattern", + "description": "An optional glob pattern to match against when enforcing tag protection.", "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Create a repository using a template", + "scope": "repos", + "id": "createUsingTemplate", + "method": "POST", + "url": "/repos/{template_owner}/{template_repo}/generate", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Creates a new repository using a repository template. Use the `template_owner` and `template_repo` route parameters to specify the repository to use as the template. If the repository is not public, the authenticated user must own or be a member of an organization that owns the repository. To check if a repository is available to use as a template, get the repository's information using the [Get a repository](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository) endpoint and check that the `is_template` key is `true`.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-using-a-template", + "parameters": [ { - "name": "homepage", - "description": "A URL with more information about the repository.", - "in": "BODY", + "name": "template_owner", + "description": "", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40305,11 +45892,11 @@ "deprecated": null }, { - "name": "private", - "description": "Whether the repository is private.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "template_repo", + "description": "", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40318,24 +45905,11 @@ "deprecated": null }, { - "name": "visibility", - "description": "Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`. Note: For GitHub Enterprise Server and GitHub AE, this endpoint will only list repositories available to all users on the enterprise. For more information, see \"[Creating an internal repository](https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/about-repository-visibility#about-internal-repositories)\" in the GitHub Help documentation.", + "name": "owner", + "description": "The organization or person who will own the new repository. To create a new repository in an organization, the authenticated user must be a member of the specified organization.", "in": "BODY", "type": "string", "required": false, - "enum": ["public", "private", "internal"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "has_issues", - "description": "Either `true` to enable issues for this repository or `false` to disable them.", - "in": "BODY", - "type": "boolean", - "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -40344,11 +45918,11 @@ "deprecated": null }, { - "name": "has_projects", - "description": "Either `true` to enable projects for this repository or `false` to disable them. **Note:** If you're creating a repository in an organization that has disabled repository projects, the default is `false`, and if you pass `true`, the API returns an error.", + "name": "name", + "description": "The name of the new repository.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40357,10 +45931,10 @@ "deprecated": null }, { - "name": "has_wiki", - "description": "Either `true` to enable the wiki for this repository or `false` to disable it.", + "name": "description", + "description": "A short description of the new repository.", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -40370,8 +45944,8 @@ "deprecated": null }, { - "name": "is_template", - "description": "Either `true` to make this repo available as a template repository or `false` to prevent it.", + "name": "include_all_branches", + "description": "Set to `true` to include the directory structure and files from all branches in the template repository, and not just the default branch. Default: `false`.", "in": "BODY", "type": "boolean", "required": false, @@ -40383,21 +45957,8 @@ "deprecated": null }, { - "name": "team_id", - "description": "The id of the team that will be granted access to this repository. This is only valid when creating a repository in an organization.", - "in": "BODY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "auto_init", - "description": "Pass `true` to create an initial commit with empty README.", + "name": "private", + "description": "Either `true` to create a new private repository or `false` to create a new public one.", "in": "BODY", "type": "boolean", "required": false, @@ -40407,13 +45968,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 201, "description": "Response" }], + "renamed": null + }, + { + "name": "Create a repository webhook", + "scope": "repos", + "id": "createWebhook", + "method": "POST", + "url": "/repos/{owner}/{repo}/hooks", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Repositories can have multiple webhooks installed. Each webhook should have a unique `config`. Multiple webhooks can\nshare the same `config` as long as those webhooks do not have any `events` that overlap.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#create-a-repository-webhook", + "parameters": [ { - "name": "gitignore_template", - "description": "Desired language or platform [.gitignore template](https://github.com/github/gitignore) to apply. Use the name of the template without the extension. For example, \"Haskell\".", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40422,11 +45999,11 @@ "deprecated": null }, { - "name": "license_template", - "description": "Choose an [open source license template](https://choosealicense.com/) that best suits your needs, and then use the [license keyword](https://docs.github.com/articles/licensing-a-repository/#searching-github-by-license-type) as the `license_template` string. For example, \"mit\" or \"mpl-2.0\".", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40435,10 +46012,10 @@ "deprecated": null }, { - "name": "allow_squash_merge", - "description": "Either `true` to allow squash-merging pull requests, or `false` to prevent squash-merging.", + "name": "name", + "description": "Use `web` to create a webhook. Default: `web`. This parameter only accepts the value `web`.", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -40448,10 +46025,10 @@ "deprecated": null }, { - "name": "allow_merge_commit", - "description": "Either `true` to allow merging pull requests with a merge commit, or `false` to prevent merging pull requests with merge commits.", + "name": "config", + "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-hook-config-params).", "in": "BODY", - "type": "boolean", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -40461,10 +46038,10 @@ "deprecated": null }, { - "name": "allow_rebase_merge", - "description": "Either `true` to allow rebase-merging pull requests, or `false` to prevent rebase-merging.", + "name": "config.url", + "description": "The URL to which the payloads will be delivered.", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -40474,10 +46051,10 @@ "deprecated": null }, { - "name": "allow_auto_merge", - "description": "Either `true` to allow auto-merge on pull requests, or `false` to disallow auto-merge.", + "name": "config.content_type", + "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -40487,10 +46064,10 @@ "deprecated": null }, { - "name": "delete_branch_on_merge", - "description": "Either `true` to allow automatically deleting head branches when pull requests are merged, or `false` to prevent automatic deletion.", + "name": "config.secret", + "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -40500,10 +46077,10 @@ "deprecated": null }, { - "name": "use_squash_pr_title_as_default", - "description": "Either `true` to allow squash-merge commits to use pull request title, or `false` to use commit message. **This property has been deprecated. Please use `squash_merge_commit_title` instead.", + "name": "config.insecure_ssl", + "description": "", "in": "BODY", - "type": "boolean", + "type": null, "required": false, "enum": null, "allowNull": false, @@ -40513,12 +46090,12 @@ "deprecated": null }, { - "name": "squash_merge_commit_title", - "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", + "name": "config.token", + "description": "", "in": "BODY", "type": "string", "required": false, - "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40526,12 +46103,12 @@ "deprecated": null }, { - "name": "squash_merge_commit_message", - "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "name": "config.digest", + "description": "", "in": "BODY", "type": "string", "required": false, - "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40539,12 +46116,12 @@ "deprecated": null }, { - "name": "merge_commit_title", - "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", + "name": "events", + "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for.", "in": "BODY", - "type": "string", + "type": "string[]", "required": false, - "enum": ["PR_TITLE", "MERGE_MESSAGE"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40552,12 +46129,12 @@ "deprecated": null }, { - "name": "merge_commit_message", - "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "name": "active", + "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, - "enum": ["PR_BODY", "PR_TITLE", "BLANK"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40568,6 +46145,7 @@ "responses": [ { "code": 201, "description": "Response" }, { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -40576,22 +46154,22 @@ "renamed": null }, { - "name": "Create or update an environment", + "name": "Decline a repository invitation", "scope": "repos", - "id": "createOrUpdateEnvironment", - "method": "PUT", - "url": "/repos/{owner}/{repo}/environments/{environment_name}", + "id": "declineInvitation", + "method": "DELETE", + "url": "/user/repository_invitations/{invitation_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create or update an environment with protection rules, such as required reviewers. For more information about environment protection rules, see \"[Environments](/actions/reference/environments#environment-protection-rules).\"\n\n**Note:** To create or update name patterns that branches must match in order to deploy to this environment, see \"[Deployment branch policies](/rest/deployments/branch-policies).\"\n\n**Note:** To create or update secrets for an environment, see \"[Secrets](/rest/reference/actions#secrets).\"\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-or-update-an-environment", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#decline-a-repository-invitation", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "invitation_id", + "description": "The unique identifier of the invitation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -40599,12 +46177,42 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" } + ], + "renamed": { + "before": { "scope": "repos", "id": "declineInvitation" }, + "after": { + "scope": "repos", + "id": "declineInvitationForAuthenticatedUser" }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "Decline a repository invitation", + "scope": "repos", + "id": "declineInvitationForAuthenticatedUser", + "method": "DELETE", + "url": "/user/repository_invitations/{invitation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#decline-a-repository-invitation", + "parameters": [ { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "invitation_id", + "description": "The unique identifier of the invitation.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -40612,10 +46220,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" } + ], + "renamed": null + }, + { + "name": "Delete a repository", + "scope": "repos", + "id": "delete", + "method": "DELETE", + "url": "/repos/{owner}/{repo}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deleting a repository requires admin access. If OAuth is used, the `delete_repo` scope is required.\n\nIf an organization owner has configured the organization to prevent members from deleting organization-owned\nrepositories, you will get a `403 Forbidden` response.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-repository", + "parameters": [ { - "name": "environment_name", - "description": "The name of the environment.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -40627,38 +46257,62 @@ "deprecated": null }, { - "name": "wait_timer", - "description": "The amount of time to delay a job after the job is initially triggered. The time (in minutes) must be an integer between 0 and 43,200 (30 days).", - "in": "BODY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 307, "description": "Temporary Redirect" }, + { + "code": 403, + "description": "If an organization owner has configured the organization to prevent members from deleting organization-owned repositories, a member will get this response:" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete access restrictions", + "scope": "repos", + "id": "deleteAccessRestrictions", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nDisables the ability to restrict who can push to this branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#delete-access-restrictions", + "parameters": [ { - "name": "reviewers", - "description": "The people or teams that may review jobs that reference the environment. You can list up to six users or teams as reviewers. The reviewers must have at least read access to the repository. Only one of the required reviewers needs to approve the job for it to proceed.", - "in": "BODY", - "type": "object[]", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "reviewers[].type", - "description": "The type of reviewer.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["User", "Team"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -40666,36 +46320,52 @@ "deprecated": null }, { - "name": "reviewers[].id", - "description": "The id of the user or team who can review the deployment", - "in": "BODY", - "type": "integer", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete admin branch protection", + "scope": "repos", + "id": "deleteAdminBranchProtection", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoving admin enforcement requires admin or owner permissions to the repository and branch protection to be enabled.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#delete-admin-branch-protection", + "parameters": [ { - "name": "deployment_branch_policy", - "description": "The type of deployment branch policy for this environment. To allow all branches to deploy, set to `null`.", - "in": "BODY", - "type": "object", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "deployment_branch_policy.protected_branches", - "description": "Whether only branches with branch protection rules can deploy to this environment. If `protected_branches` is `true`, `custom_branch_policies` must be `false`; if `protected_branches` is `false`, `custom_branch_policies` must be `true`.", - "in": "BODY", - "type": "boolean", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -40705,10 +46375,10 @@ "deprecated": null }, { - "name": "deployment_branch_policy.custom_branch_policies", - "description": "Whether only branches that match the specified name patterns can deploy to this environment. If `custom_branch_policies` is `true`, `protected_branches` must be `false`; if `custom_branch_policies` is `false`, `protected_branches` must be `true`.", - "in": "BODY", - "type": "boolean", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -40719,25 +46389,22 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation error when the environment name is invalid or when `protected_branches` and `custom_branch_policies` in `deployment_branch_policy` are set to the same value" - } + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create or update file contents", + "name": "Delete an environment", "scope": "repos", - "id": "createOrUpdateFileContents", - "method": "PUT", - "url": "/repos/{owner}/{repo}/contents/{path}", + "id": "deleteAnEnvironment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/environments/{environment_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new file or replaces an existing file in a repository. You must authenticate using an access token with the `workflow` scope to use this endpoint.\n\n**Note:** If you use this endpoint and the \"[Delete a file](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#delete-file)\" endpoint in parallel, the concurrent requests will conflict and you will receive errors. You must use these endpoints serially instead.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-or-update-file-contents", + "description": "You must authenticate using an access token with the repo scope to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/environments#delete-an-environment", "parameters": [ { "name": "owner", @@ -40754,7 +46421,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -40766,8 +46433,8 @@ "deprecated": null }, { - "name": "path", - "description": "path parameter", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -40777,11 +46444,27 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Default response" }], + "renamed": null + }, + { + "name": "Delete an autolink reference from a repository", + "scope": "repos", + "id": "deleteAutolink", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/autolinks/{autolink_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This deletes a single autolink reference by ID that was configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/autolinks#delete-an-autolink-reference-from-a-repository", + "parameters": [ { - "name": "message", - "description": "The commit message.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40792,9 +46475,9 @@ "deprecated": null }, { - "name": "content", - "description": "The new file content, using Base64 encoding.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40805,24 +46488,43 @@ "deprecated": null }, { - "name": "sha", - "description": "**Required if you are updating a file**. The blob SHA of the file being replaced.", - "in": "BODY", - "type": "string", - "required": false, + "name": "autolink_id", + "description": "The unique identifier of the autolink.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete branch protection", + "scope": "repos", + "id": "deleteBranchProtection", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#delete-branch-protection", + "parameters": [ { - "name": "branch", - "description": "The branch name. Default: the repository’s default branch (usually `master`)", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40831,11 +46533,11 @@ "deprecated": null }, { - "name": "committer", - "description": "The person that committed the file. Default: the authenticated user.", - "in": "BODY", - "type": "object", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40844,9 +46546,9 @@ "deprecated": null }, { - "name": "committer.name", - "description": "The name of the author or committer of the commit. You'll receive a `422` status code if `name` is omitted.", - "in": "BODY", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40855,11 +46557,30 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "Delete a commit comment", + "scope": "repos", + "id": "deleteCommitComment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/comments/{comment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#delete-a-commit-comment", + "parameters": [ { - "name": "committer.email", - "description": "The email of the author or committer of the commit. You'll receive a `422` status code if `email` is omitted.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40870,11 +46591,11 @@ "deprecated": null }, { - "name": "committer.date", - "description": "", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40883,22 +46604,41 @@ "deprecated": null }, { - "name": "author", - "description": "The author of the file. Default: The `committer` or the authenticated user if you omit `committer`.", - "in": "BODY", - "type": "object", - "required": false, + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete commit signature protection", + "scope": "repos", + "id": "deleteCommitSignatureProtection", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to disable required signed commits on a branch. You must enable branch protection to require signed commits.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#delete-commit-signature-protection", + "parameters": [ { - "name": "author.name", - "description": "The name of the author or committer of the commit. You'll receive a `422` status code if `name` is omitted.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40909,9 +46649,9 @@ "deprecated": null }, { - "name": "author.email", - "description": "The email of the author or committer of the commit. You'll receive a `422` status code if `email` is omitted.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -40922,11 +46662,11 @@ "deprecated": null }, { - "name": "author.date", - "description": "", - "in": "BODY", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -40936,28 +46676,22 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 201, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Create a GitHub Pages deployment", + "name": "Delete a deploy key", "scope": "repos", - "id": "createPagesDeployment", - "method": "POST", - "url": "/repos/{owner}/{repo}/pages/deployment", + "id": "deleteDeployKey", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/keys/{key_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Create a GitHub Pages deployment for a repository.\n\nUsers must have write permissions. GitHub Apps must have the `pages:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#create-a-github-pages-deployment", + "description": "Deploy keys are immutable. If you need to update a key, remove the key and create a new one instead.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deploy-keys#delete-a-deploy-key", "parameters": [ { "name": "owner", @@ -40974,7 +46708,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -40986,10 +46720,10 @@ "deprecated": null }, { - "name": "artifact_url", - "description": "The URL of an artifact that contains the .zip or .tar of static assets to deploy. The artifact belongs to the repository.", - "in": "BODY", - "type": "string", + "name": "key_id", + "description": "The unique identifier of the key.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -40997,13 +46731,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a deployment", + "scope": "repos", + "id": "deleteDeployment", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/deployments/{deployment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "If the repository only has one deployment, you can delete the deployment regardless of its status. If the repository has more than one deployment, you can only delete inactive deployments. This ensures that repositories with multiple deployments will always have an active deployment. Anyone with `repo` or `repo_deployment` scopes can delete a deployment.\n\nTo set a deployment as inactive, you must:\n\n* Create a new deployment that is active so that the system has a record of the current state, then delete the previously active deployment.\n* Mark the active deployment as inactive by adding any non-successful deployment status.\n\nFor more information, see \"[Create a deployment](https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployments/#create-a-deployment)\" and \"[Create a deployment status](https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployment-statuses#create-a-deployment-status).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployments#delete-a-deployment", + "parameters": [ { - "name": "environment", - "description": "The target environment for this GitHub Pages deployment.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41012,9 +46762,9 @@ "deprecated": null }, { - "name": "pages_build_version", - "description": "A unique string that represents the version of the build for this deployment.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -41025,10 +46775,10 @@ "deprecated": null }, { - "name": "oidc_token", - "description": "The OIDC token issued by GitHub Actions certifying the origin of the deployment.", - "in": "BODY", - "type": "string", + "name": "deployment_id", + "description": "deployment_id parameter", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -41039,9 +46789,7 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, + { "code": 204, "description": "Response" }, { "code": 404, "description": "Resource not found" }, { "code": 422, @@ -41051,16 +46799,16 @@ "renamed": null }, { - "name": "Create a GitHub Enterprise Cloud Pages site", + "name": "Delete a deployment branch policy", "scope": "repos", - "id": "createPagesSite", - "method": "POST", - "url": "/repos/{owner}/{repo}/pages", + "id": "deleteDeploymentBranchPolicy", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Configures a GitHub Enterprise Cloud Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#create-a-github-pages-site", + "description": "Deletes a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#delete-deployment-branch-policy", "parameters": [ { "name": "owner", @@ -41077,7 +46825,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41089,12 +46837,12 @@ "deprecated": null }, { - "name": "build_type", - "description": "The process in which the Page will be built. Possible values are `\"legacy\"` and `\"workflow\"`.", - "in": "BODY", + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["legacy", "workflow"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -41102,22 +46850,38 @@ "deprecated": null }, { - "name": "source", - "description": "The source branch and directory used to publish your Pages site.", - "in": "BODY", - "type": "object", - "required": false, + "name": "branch_policy_id", + "description": "The unique identifier of the branch policy.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a file", + "scope": "repos", + "id": "deleteFile", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/contents/{path}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a file in a repository.\n\nYou can provide an additional `committer` parameter, which is an object containing information about the committer. Or, you can provide an `author` parameter, which is an object containing information about the author.\n\nThe `author` section is optional and is filled in with the `committer` information if omitted. If the `committer` information is omitted, the authenticated user's information is used.\n\nYou must provide values for both `name` and `email`, whether you choose to use `author` or `committer`. Otherwise, you'll receive a `422` status code.\n\n**Note:** If you use this endpoint and the \"[Create or update file contents](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#create-or-update-file-contents)\" endpoint in parallel, the concurrent requests will conflict and you will receive errors. You must use these endpoints serially instead.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-file", + "parameters": [ { - "name": "source.branch", - "description": "The repository branch used to publish your site's source files.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -41128,44 +46892,21 @@ "deprecated": null }, { - "name": "source.path", - "description": "The repository directory that includes the source files for the Pages site. Allowed paths are `/` or `/docs`. Default: `/`", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["/", "/docs"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 409, "description": "Conflict" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Create a release", - "scope": "repos", - "id": "createRelease", - "method": "POST", - "url": "/repos/{owner}/{repo}/releases", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Users with push access to the repository can create a release.\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-release", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "path", + "description": "path parameter", "in": "PATH", "type": "string", "required": true, @@ -41177,9 +46918,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "message", + "description": "The commit message.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -41190,8 +46931,8 @@ "deprecated": null }, { - "name": "tag_name", - "description": "The name of the tag.", + "name": "sha", + "description": "The blob SHA of the file being deleted.", "in": "BODY", "type": "string", "required": true, @@ -41203,8 +46944,8 @@ "deprecated": null }, { - "name": "target_commitish", - "description": "Specifies the commitish value that determines where the Git tag is created from. Can be any branch or commit SHA. Unused if the Git tag already exists. Default: the repository's default branch (usually `master`).", + "name": "branch", + "description": "The branch name. Default: the repository’s default branch", "in": "BODY", "type": "string", "required": false, @@ -41216,10 +46957,10 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the release.", + "name": "committer", + "description": "object containing information about the committer.", "in": "BODY", - "type": "string", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -41229,8 +46970,8 @@ "deprecated": null }, { - "name": "body", - "description": "Text describing the contents of the tag.", + "name": "committer.name", + "description": "The name of the author (or committer) of the commit", "in": "BODY", "type": "string", "required": false, @@ -41242,10 +46983,10 @@ "deprecated": null }, { - "name": "draft", - "description": "`true` to create a draft (unpublished) release, `false` to create a published one.", + "name": "committer.email", + "description": "The email of the author (or committer) of the commit", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -41255,10 +46996,10 @@ "deprecated": null }, { - "name": "prerelease", - "description": "`true` to identify the release as a prerelease. `false` to identify the release as a full release.", + "name": "author", + "description": "object containing information about the author.", "in": "BODY", - "type": "boolean", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -41268,8 +47009,8 @@ "deprecated": null }, { - "name": "discussion_category_name", - "description": "If specified, a discussion of the specified category is created and linked to the release. The value must be a category that already exists in the repository. For more information, see \"[Managing categories for discussions in your repository](https://docs.github.com/enterprise-cloud@latest//discussions/managing-discussions-for-your-community/managing-categories-for-discussions-in-your-repository).\"", + "name": "author.name", + "description": "The name of the author (or committer) of the commit", "in": "BODY", "type": "string", "required": false, @@ -41281,10 +47022,10 @@ "deprecated": null }, { - "name": "generate_release_notes", - "description": "Whether to automatically generate the name and body for this release. If `name` is specified, the specified name will be used; otherwise, a name will be automatically generated. If `body` is specified, the body will be pre-pended to the automatically generated notes.", + "name": "author.email", + "description": "The email of the author (or committer) of the commit", "in": "BODY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -41295,29 +47036,28 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { - "code": 404, - "description": "Not Found if the discussion category name is invalid" - }, + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." - } + }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Create a tag protection state for a repository", + "name": "Delete a repository invitation", "scope": "repos", - "id": "createTagProtection", - "method": "POST", - "url": "/repos/{owner}/{repo}/tags/protection", + "id": "deleteInvitation", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/invitations/{invitation_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This creates a tag protection state for a repository.\nThis endpoint is only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-tag-protection-state-for-a-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#delete-a-repository-invitation", "parameters": [ { "name": "owner", @@ -41334,7 +47074,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41346,10 +47086,10 @@ "deprecated": null }, { - "name": "pattern", - "description": "An optional glob pattern to match against when enforcing tag protection.", - "in": "BODY", - "type": "string", + "name": "invitation_id", + "description": "The unique identifier of the invitation.", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -41359,28 +47099,24 @@ "deprecated": null } ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Create a repository using a template", + "name": "Delete an organization repository ruleset", "scope": "repos", - "id": "createUsingTemplate", - "method": "POST", - "url": "/repos/{template_owner}/{template_repo}/generate", + "id": "deleteOrgRuleset", + "method": "DELETE", + "url": "/orgs/{org}/rulesets/{ruleset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new repository using a repository template. Use the `template_owner` and `template_repo` route parameters to specify the repository to use as the template. If the repository is not public, the authenticated user must own or be a member of an organization that owns the repository. To check if a repository is available to use as a template, get the repository's information using the [Get a repository](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository) endpoint and check that the `is_template` key is `true`.\n\n**OAuth scope requirements**\n\nWhen using [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/), authorizations must include:\n\n* `public_repo` scope or `repo` scope to create a public repository. Note: For GitHub AE, use `repo` scope to create an internal repository.\n* `repo` scope to create a private repository", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-repository-using-a-template", + "description": "Delete a ruleset for an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#delete-organization-ruleset", "parameters": [ { - "name": "template_owner", - "description": "", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41392,10 +47128,10 @@ "deprecated": null }, { - "name": "template_repo", - "description": "", + "name": "ruleset_id", + "description": "The ID of the ruleset.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -41403,24 +47139,31 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Delete a GitHub Enterprise Cloud Pages site", + "scope": "repos", + "id": "deletePagesSite", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/pages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes a GitHub Enterprise Cloud Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).\n\nTo use this endpoint, you must be a repository administrator, maintainer, or have the 'manage GitHub Pages settings' permission. A token with the `repo` scope or Pages write permission is required. GitHub Apps must have the `administration:write` and `pages:write` permissions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#delete-a-github-pages-site", + "parameters": [ { "name": "owner", - "description": "The organization or person who will own the new repository. To create a new repository in an organization, the authenticated user must be a member of the specified organization.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "name", - "description": "The name of the new repository.", - "in": "BODY", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -41431,59 +47174,41 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the new repository.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "include_all_branches", - "description": "Set to `true` to include the directory structure and files from all branches in the template repository, and not just the default branch. Default: `false`.", - "in": "BODY", - "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, { - "name": "private", - "description": "Either `true` to create a new private repository or `false` to create a new public one.", - "in": "BODY", - "type": "boolean", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "Create a repository webhook", + "name": "Delete pull request review protection", "scope": "repos", - "id": "createWebhook", - "method": "POST", - "url": "/repos/{owner}/{repo}/hooks", + "id": "deletePullRequestReviewProtection", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Repositories can have multiple webhooks installed. Each webhook should have a unique `config`. Multiple webhooks can\nshare the same `config` as long as those webhooks do not have any `events` that overlap.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#create-a-repository-webhook", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#delete-pull-request-review-protection", "parameters": [ { "name": "owner", @@ -41500,7 +47225,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41512,24 +47237,43 @@ "deprecated": null }, { - "name": "name", - "description": "Use `web` to create a webhook. Default: `web`. This parameter only accepts the value `web`.", - "in": "BODY", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Delete a release", + "scope": "repos", + "id": "deleteRelease", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/releases/{release_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Users with push access to the repository can delete a release.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-release", + "parameters": [ { - "name": "config", - "description": "Key/value pairs to provide settings for this webhook. [These are defined below](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-hook-config-params).", - "in": "BODY", - "type": "object", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41538,11 +47282,11 @@ "deprecated": null }, { - "name": "config.url", - "description": "The URL to which the payloads will be delivered.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41551,24 +47295,40 @@ "deprecated": null }, { - "name": "config.content_type", - "description": "The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.", - "in": "BODY", - "type": "string", - "required": false, + "name": "release_id", + "description": "The unique identifier of the release.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a release asset", + "scope": "repos", + "id": "deleteReleaseAsset", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-release-asset", + "parameters": [ { - "name": "config.secret", - "description": "If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads/#delivery-headers).", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41577,11 +47337,11 @@ "deprecated": null }, { - "name": "config.insecure_ssl", - "description": "", - "in": "BODY", - "type": null, - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41590,24 +47350,40 @@ "deprecated": null }, { - "name": "config.token", - "description": "", - "in": "BODY", - "type": "string", - "required": false, + "name": "asset_id", + "description": "The unique identifier of the asset.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 204, "description": "Response" }], + "renamed": null + }, + { + "name": "Delete a repository ruleset", + "scope": "repos", + "id": "deleteRepoRuleset", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/rulesets/{ruleset_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Delete a ruleset for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#delete-repository-ruleset", + "parameters": [ { - "name": "config.digest", - "description": "", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41616,11 +47392,11 @@ "deprecated": null }, { - "name": "events", - "description": "Determines what [events](https://docs.github.com/enterprise-cloud@latest//webhooks/event-payloads) the hook is triggered for.", - "in": "BODY", - "type": "string[]", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41629,11 +47405,11 @@ "deprecated": null }, { - "name": "active", - "description": "Determines if notifications are sent when the webhook is triggered. Set to `true` to send notifications.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "ruleset_id", + "description": "The ID of the ruleset.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -41643,33 +47419,29 @@ } ], "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, + { "code": 204, "description": "Response" }, { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Decline a repository invitation", + "name": "Delete a tag protection state for a repository", "scope": "repos", - "id": "declineInvitation", + "id": "deleteTagProtection", "method": "DELETE", - "url": "/user/repository_invitations/{invitation_id}", + "url": "/repos/{owner}/{repo}/tags/protection/{tag_protection_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#decline-a-repository-invitation", + "description": "This deletes a tag protection state for a repository.\nThis endpoint is only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-tag-protection-state-for-a-repository", "parameters": [ { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -41677,40 +47449,23 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" } - ], - "renamed": { - "before": { "scope": "repos", "id": "declineInvitation" }, - "after": { - "scope": "repos", - "id": "declineInvitationForAuthenticatedUser" }, - "date": "2021-10-05", - "note": null - } - }, - { - "name": "Decline a repository invitation", - "scope": "repos", - "id": "declineInvitationForAuthenticatedUser", - "method": "DELETE", - "url": "/user/repository_invitations/{invitation_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#decline-a-repository-invitation", - "parameters": [ { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "tag_protection_id", + "description": "The unique identifier of the tag protection.", "in": "PATH", "type": "integer", "required": true, @@ -41724,24 +47479,22 @@ ], "responses": [ { "code": 204, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete a repository", + "name": "Delete a repository webhook", "scope": "repos", - "id": "delete", + "id": "deleteWebhook", "method": "DELETE", - "url": "/repos/{owner}/{repo}", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deleting a repository requires admin access. If OAuth is used, the `delete_repo` scope is required.\n\nIf an organization owner has configured the organization to prevent members from deleting organization-owned\nrepositories, you will get a `403 Forbidden` response.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#delete-a-repository-webhook", "parameters": [ { "name": "owner", @@ -41757,10 +47510,23 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -41772,26 +47538,21 @@ ], "responses": [ { "code": 204, "description": "Response" }, - { "code": 307, "description": "Temporary Redirect" }, - { - "code": 403, - "description": "If an organization owner has configured the organization to prevent members from deleting organization-owned repositories, a member will get this response:" - }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete access restrictions", + "name": "Disable automated security fixes", "scope": "repos", - "id": "deleteAccessRestrictions", + "id": "disableAutomatedSecurityFixes", "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions", + "url": "/repos/{owner}/{repo}/automated-security-fixes", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nDisables the ability to restrict who can push to this branch.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-access-restrictions", + "description": "Disables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see \"[Configuring automated security fixes](https://docs.github.com/enterprise-cloud@latest//articles/configuring-automated-security-fixes)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-automated-security-fixes", "parameters": [ { "name": "owner", @@ -41808,20 +47569,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "branch", - "description": "The name of the branch.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41837,20 +47585,20 @@ "renamed": null }, { - "name": "Delete admin branch protection", + "name": "Disable a custom protection rule for an environment", "scope": "repos", - "id": "deleteAdminBranchProtection", + "id": "disableDeploymentProtectionRule", "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoving admin enforcement requires admin or owner permissions to the repository and branch protection to be enabled.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-admin-branch-protection", + "description": "Disables a custom deployment protection rule for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. Removing a custom protection rule requires admin or owner permissions to the repository. GitHub Apps must have the `actions:write` permission to use this endpoint. For more information, see \"[Get an app](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#get-an-app)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/protection-rules#disable-deployment-protection-rule", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -41863,7 +47611,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41875,8 +47623,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41886,25 +47634,35 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "protection_rule_id", + "description": "The unique identifier of the protection rule.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete an environment", + "name": "Disable Git LFS for a repository", "scope": "repos", - "id": "deleteAnEnvironment", + "id": "disableLfsForRepo", "method": "DELETE", - "url": "/repos/{owner}/{repo}/environments/{environment_name}", + "url": "/repos/{owner}/{repo}/lfs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "You must authenticate using an access token with the repo scope to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-an-environment", + "description": "Disables Git LFS for a repository. Access tokens must have the `admin:enterprise` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-git-lfs-for-a-repository", "parameters": [ { "name": "owner", @@ -41921,20 +47679,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "environment_name", - "description": "The name of the environment.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41946,20 +47691,20 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Default response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete an autolink reference from a repository", + "name": "Disable vulnerability alerts", "scope": "repos", - "id": "deleteAutolink", + "id": "disableVulnerabilityAlerts", "method": "DELETE", - "url": "/repos/{owner}/{repo}/autolinks/{autolink_id}", + "url": "/repos/{owner}/{repo}/vulnerability-alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This deletes a single autolink reference by ID that was configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//v3/repos#delete-autolink", + "description": "Disables dependency alerts and the dependency graph for a repository.\nThe authenticated user must have admin access to the repository. For more information,\nsee \"[About security alerts for vulnerable dependencies](https://docs.github.com/enterprise-cloud@latest//articles/about-security-alerts-for-vulnerable-dependencies)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-vulnerability-alerts", "parameters": [ { "name": "owner", @@ -41976,7 +47721,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -41986,38 +47731,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "autolink_id", - "description": "The unique identifier of the autolink.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete branch protection", + "name": "Download a repository archive (tar)", "scope": "repos", - "id": "deleteBranchProtection", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection", + "id": "downloadArchive", + "method": "GET", + "url": "/repos/{owner}/{repo}/tarball/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-branch-protection", + "description": "Gets a redirect URL to download a tar archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`main`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n**Note**: For private repositories, these links are temporary and expire after five minutes.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", "parameters": [ { "name": "owner", @@ -42034,7 +47763,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42046,8 +47775,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "ref", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -42059,23 +47788,25 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null + "responses": [{ "code": 302, "description": "Response" }], + "renamed": { + "before": { "scope": "repos", "id": "downloadArchive" }, + "after": { "scope": "repos", "id": "downloadTarballArchive" }, + "date": "2020-09-17", + "note": null + } }, { - "name": "Delete a commit comment", + "name": "Download a repository archive (zip)", "scope": "repos", - "id": "deleteCommitComment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/comments/{comment_id}", + "id": "downloadArchive", + "method": "GET", + "url": "/repos/{owner}/{repo}/zipball/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#delete-a-commit-comment", + "description": "Gets a redirect URL to download a zip archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`main`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n\n**Note**: For private repositories, these links are temporary and expire after five minutes. If the repository is empty, you will receive a 404 when you follow the redirect.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", "parameters": [ { "name": "owner", @@ -42092,7 +47823,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42104,10 +47835,10 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", + "name": "ref", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42117,23 +47848,25 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null + "responses": [{ "code": 302, "description": "Response" }], + "renamed": { + "before": { "scope": "repos", "id": "downloadArchive" }, + "after": { "scope": "repos", "id": "downloadZipballArchive" }, + "date": "2020-09-17", + "note": null + } }, { - "name": "Delete commit signature protection", + "name": "Download a repository archive (tar)", "scope": "repos", - "id": "deleteCommitSignatureProtection", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", + "id": "downloadTarballArchive", + "method": "GET", + "url": "/repos/{owner}/{repo}/tarball/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to disable required signed commits on a branch. You must enable branch protection to require signed commits.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-commit-signature-protection", + "description": "Gets a redirect URL to download a tar archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`main`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n**Note**: For private repositories, these links are temporary and expire after five minutes.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", "parameters": [ { "name": "owner", @@ -42150,7 +47883,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42162,8 +47895,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "ref", + "description": "", "in": "PATH", "type": "string", "required": true, @@ -42175,23 +47908,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 302, "description": "Response" }], "renamed": null }, { - "name": "Delete a deploy key", + "name": "Download a repository archive (zip)", "scope": "repos", - "id": "deleteDeployKey", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/keys/{key_id}", + "id": "downloadZipballArchive", + "method": "GET", + "url": "/repos/{owner}/{repo}/zipball/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deploy keys are immutable. If you need to update a key, remove the key and create a new one instead.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-deploy-key", + "description": "Gets a redirect URL to download a zip archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`main`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n\n**Note**: For private repositories, these links are temporary and expire after five minutes. If the repository is empty, you will receive a 404 when you follow the redirect.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", "parameters": [ { "name": "owner", @@ -42208,7 +47938,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42220,10 +47950,10 @@ "deprecated": null }, { - "name": "key_id", - "description": "The unique identifier of the key.", + "name": "ref", + "description": "", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42233,20 +47963,20 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [{ "code": 302, "description": "Response" }], "renamed": null }, { - "name": "Delete a deployment", + "name": "Enable automated security fixes", "scope": "repos", - "id": "deleteDeployment", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/deployments/{deployment_id}", + "id": "enableAutomatedSecurityFixes", + "method": "PUT", + "url": "/repos/{owner}/{repo}/automated-security-fixes", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "If the repository only has one deployment, you can delete the deployment regardless of its status. If the repository has more than one deployment, you can only delete inactive deployments. This ensures that repositories with multiple deployments will always have an active deployment. Anyone with `repo` or `repo_deployment` scopes can delete a deployment.\n\nTo set a deployment as inactive, you must:\n\n* Create a new deployment that is active so that the system has a record of the current state, then delete the previously active deployment.\n* Mark the active deployment as inactive by adding any non-successful deployment status.\n\nFor more information, see \"[Create a deployment](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#create-a-deployment)\" and \"[Create a deployment status](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-deployment-status).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-deployment", + "description": "Enables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see \"[Configuring automated security fixes](https://docs.github.com/enterprise-cloud@latest//articles/configuring-automated-security-fixes)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-automated-security-fixes", "parameters": [ { "name": "owner", @@ -42263,7 +47993,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42273,42 +48003,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "deployment_id", - "description": "deployment_id parameter", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." } ], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Delete a deployment branch policy", + "name": "Enable Git LFS for a repository", "scope": "repos", - "id": "deleteDeploymentBranchPolicy", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", + "id": "enableLfsForRepo", + "method": "PUT", + "url": "/repos/{owner}/{repo}/lfs", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#delete-deployment-branch-policy", + "description": "Enables Git LFS for a repository. Access tokens must have the `admin:enterprise` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-git-lfs-for-a-repository", "parameters": [ { "name": "owner", @@ -42325,7 +48035,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42335,10 +48045,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, { - "name": "environment_name", - "description": "The name of the environment.", + "code": 403, + "description": "We will return a 403 with one of the following messages:\n\n- Git LFS support not enabled because Git LFS is globally disabled.\n- Git LFS support not enabled because Git LFS is disabled for the root repository in the network.\n- Git LFS support not enabled because Git LFS is disabled for ." + } + ], + "renamed": null + }, + { + "name": "Enable vulnerability alerts", + "scope": "repos", + "id": "enableVulnerabilityAlerts", + "method": "PUT", + "url": "/repos/{owner}/{repo}/vulnerability-alerts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Enables dependency alerts and the dependency graph for a repository. The authenticated user must have admin access to the repository. For more information, see \"[About security alerts for vulnerable dependencies](https://docs.github.com/enterprise-cloud@latest//articles/about-security-alerts-for-vulnerable-dependencies)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-vulnerability-alerts", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42350,10 +48082,10 @@ "deprecated": null }, { - "name": "branch_policy_id", - "description": "The unique identifier of the branch policy.", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42367,16 +48099,16 @@ "renamed": null }, { - "name": "Delete a file", + "name": "Generate release notes content for a release", "scope": "repos", - "id": "deleteFile", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/contents/{path}", + "id": "generateReleaseNotes", + "method": "POST", + "url": "/repos/{owner}/{repo}/releases/generate-notes", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Deletes a file in a repository.\n\nYou can provide an additional `committer` parameter, which is an object containing information about the committer. Or, you can provide an `author` parameter, which is an object containing information about the author.\n\nThe `author` section is optional and is filled in with the `committer` information if omitted. If the `committer` information is omitted, the authenticated user's information is used.\n\nYou must provide values for both `name` and `email`, whether you choose to use `author` or `committer`. Otherwise, you'll receive a `422` status code.\n\n**Note:** If you use this endpoint and the \"[Create or update file contents](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#create-or-update-file-contents)\" endpoint in parallel, the concurrent requests will conflict and you will receive errors. You must use these endpoints serially instead.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-file", + "description": "Generate a name and body describing a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases). The body content will be markdown formatted and contain information like the changes since last release and users who contributed. The generated release notes are not saved anywhere. They are intended to be generated and used when creating a new release.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#generate-release-notes", "parameters": [ { "name": "owner", @@ -42393,7 +48125,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42405,9 +48137,9 @@ "deprecated": null }, { - "name": "path", - "description": "path parameter", - "in": "PATH", + "name": "tag_name", + "description": "The tag name for the release. This can be an existing tag or a new one.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -42418,11 +48150,11 @@ "deprecated": null }, { - "name": "message", - "description": "The commit message.", + "name": "target_commitish", + "description": "Specifies the commitish value that will be the target for the release's tag. Required if the supplied tag_name does not reference an existing tag. Ignored if the tag_name already exists.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -42431,11 +48163,11 @@ "deprecated": null }, { - "name": "sha", - "description": "The blob SHA of the file being deleted.", + "name": "previous_tag_name", + "description": "The name of the previous tag to use as the starting point for the release notes. Use to manually specify the range for the set of changes considered as part this release.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -42444,8 +48176,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The branch name. Default: the repository’s default branch (usually `master`)", + "name": "configuration_file_path", + "description": "Specifies a path to a file in the repository containing configuration settings used for generating the release notes. If unspecified, the configuration file located in the repository at '.github/release.yml' or '.github/release.yaml' will be used. If that is not present, the default configuration will be used.", "in": "BODY", "type": "string", "required": false, @@ -42455,13 +48187,35 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "Name and body of generated release notes" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get a repository", + "scope": "repos", + "id": "get", + "method": "GET", + "url": "/repos/{owner}/{repo}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "The `parent` and `source` objects are present when the repository is a fork. `parent` is the repository this repository was forked from, `source` is the ultimate source for the network.\n\n**Note:** In order to see the `security_and_analysis` block for a repository you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository", + "parameters": [ { - "name": "committer", - "description": "object containing information about the committer.", - "in": "BODY", - "type": "object", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42470,11 +48224,45 @@ "deprecated": null }, { - "name": "committer.name", - "description": "The name of the author (or committer) of the commit", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get access restrictions", + "scope": "repos", + "id": "getAccessRestrictions", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists who has access to this protected branch.\n\n**Note**: Users, apps, and teams `restrictions` are only available for organization-owned repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-access-restrictions", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42483,11 +48271,11 @@ "deprecated": null }, { - "name": "committer.email", - "description": "The email of the author (or committer) of the commit", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42496,11 +48284,43 @@ "deprecated": null }, { - "name": "author", - "description": "object containing information about the author.", - "in": "BODY", - "type": "object", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get admin branch protection", + "scope": "repos", + "id": "getAdminBranchProtection", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-admin-branch-protection", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42509,11 +48329,11 @@ "deprecated": null }, { - "name": "author.name", - "description": "The name of the author (or committer) of the commit", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42522,11 +48342,11 @@ "deprecated": null }, { - "name": "author.email", - "description": "The email of the author (or committer) of the commit", - "in": "BODY", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -42535,33 +48355,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 503, "description": "Service unavailable" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Delete a repository invitation", + "name": "Get all deployment protection rules for an environment", "scope": "repos", - "id": "deleteInvitation", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/invitations/{invitation_id}", + "id": "getAllDeploymentProtectionRules", + "method": "GET", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#delete-a-repository-invitation", + "description": "Gets all custom deployment protection rules that are enabled for an environment. Anyone with read access to the repository can use this endpoint. If the repository is private and you want to use a personal access token (classic), you must use an access token with the `repo` scope. GitHub Apps and fine-grained personal access tokens must have the `actions:read` permission to use this endpoint. For more information about environments, see \"[Using environments for deployment](https://docs.github.com/enterprise-cloud@latest//en/actions/deployment/targeting-different-environments/using-environments-for-deployment).\"\n\nFor more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#get-an-app).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/protection-rules#get-all-deployment-protection-rules", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -42574,7 +48385,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42586,10 +48397,10 @@ "deprecated": null }, { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42599,20 +48410,22 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "List of deployment protection rules" } + ], "renamed": null }, { - "name": "Delete a GitHub Enterprise Cloud Pages site", + "name": "List environments", "scope": "repos", - "id": "deletePagesSite", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/pages", + "id": "getAllEnvironments", + "method": "GET", + "url": "/repos/{owner}/{repo}/environments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#delete-a-github-pages-site", + "description": "Lists the environments for a repository.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/environments#list-environments", "parameters": [ { "name": "owner", @@ -42629,7 +48442,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42639,30 +48452,48 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Delete pull request review protection", + "name": "Get all status check contexts", "scope": "repos", - "id": "deletePullRequestReviewProtection", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", + "id": "getAllStatusCheckContexts", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-pull-request-review-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-all-status-check-contexts", "parameters": [ { "name": "owner", @@ -42679,7 +48510,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42692,7 +48523,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -42705,22 +48536,22 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete a release", + "name": "Get all repository topics", "scope": "repos", - "id": "deleteRelease", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/releases/{release_id}", + "id": "getAllTopics", + "method": "GET", + "url": "/repos/{owner}/{repo}/topics", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with push access to the repository can delete a release.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-release", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-all-repository-topics", "parameters": [ { "name": "owner", @@ -42737,7 +48568,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42749,11 +48580,24 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -42762,20 +48606,23 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Delete a release asset", + "name": "Get apps with access to the protected branch", "scope": "repos", - "id": "deleteReleaseAsset", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", + "id": "getAppsWithAccessToProtectedBranch", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-a-release-asset", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the GitHub Apps that have push access to this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#list-apps-with-access-to-the-protected-branch", "parameters": [ { "name": "owner", @@ -42792,7 +48639,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42804,10 +48651,10 @@ "deprecated": null }, { - "name": "asset_id", - "description": "The unique identifier of the asset.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42817,20 +48664,23 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Delete a tag protection state for a repository", + "name": "Get an autolink reference of a repository", "scope": "repos", - "id": "deleteTagProtection", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/tags/protection/{tag_protection_id}", + "id": "getAutolink", + "method": "GET", + "url": "/repos/{owner}/{repo}/autolinks/{autolink_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This deletes a tag protection state for a repository.\nThis endpoint is only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#delete-tag-protection-state-for-a-repository", + "description": "This returns a single autolink reference by ID that was configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/autolinks#get-an-autolink-reference-of-a-repository", "parameters": [ { "name": "owner", @@ -42847,7 +48697,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42859,8 +48709,8 @@ "deprecated": null }, { - "name": "tag_protection_id", - "description": "The unique identifier of the tag protection.", + "name": "autolink_id", + "description": "The unique identifier of the autolink.", "in": "PATH", "type": "integer", "required": true, @@ -42873,23 +48723,22 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, + { "code": 200, "description": "Response" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Delete a repository webhook", + "name": "Get a branch", "scope": "repos", - "id": "deleteWebhook", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}", + "id": "getBranch", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#delete-a-repository-webhook", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branches#get-a-branch", "parameters": [ { "name": "owner", @@ -42906,7 +48755,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -42918,10 +48767,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -42932,22 +48781,23 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 301, "description": "Moved permanently" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Disable automated security fixes", + "name": "Get branch protection", "scope": "repos", - "id": "disableAutomatedSecurityFixes", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/automated-security-fixes", + "id": "getBranchProtection", + "method": "GET", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Disables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see \"[Configuring automated security fixes](https://docs.github.com/en/articles/configuring-automated-security-fixes)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-automated-security-fixes", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-branch-protection", "parameters": [ { "name": "owner", @@ -42964,36 +48814,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Disable Git LFS for a repository", - "scope": "repos", - "id": "disableLfsForRepo", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/lfs", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-git-lfs-for-a-repository", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43005,8 +48826,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -43018,20 +48839,23 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Disable vulnerability alerts", + "name": "Get rules for a branch", "scope": "repos", - "id": "disableVulnerabilityAlerts", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/vulnerability-alerts", + "id": "getBranchRules", + "method": "GET", + "url": "/repos/{owner}/{repo}/rules/branches/{branch}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Disables dependency alerts and the dependency graph for a repository. The authenticated user must have admin access to the repository. For more information, see \"[About security alerts for vulnerable dependencies](https://docs.github.com/en/articles/about-security-alerts-for-vulnerable-dependencies)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#disable-vulnerability-alerts", + "description": "Returns all rules that apply to the specified branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#get-rules-for-a-branch", "parameters": [ { "name": "owner", @@ -43048,7 +48872,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43058,26 +48882,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Download a repository archive (tar)", - "scope": "repos", - "id": "downloadArchive", - "method": "GET", - "url": "/repos/{owner}/{repo}/tarball/{ref}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Gets a redirect URL to download a tar archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`master`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n**Note**: For private repositories, these links are temporary and expire after five minutes.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -43089,11 +48897,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -43102,11 +48910,11 @@ "deprecated": null }, { - "name": "ref", - "description": "", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -43115,25 +48923,20 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], - "renamed": { - "before": { "scope": "repos", "id": "downloadArchive" }, - "after": { "scope": "repos", "id": "downloadTarballArchive" }, - "date": "2020-09-17", - "note": null - } + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null }, { - "name": "Download a repository archive (zip)", + "name": "Get repository clones", "scope": "repos", - "id": "downloadArchive", + "id": "getClones", "method": "GET", - "url": "/repos/{owner}/{repo}/zipball/{ref}", + "url": "/repos/{owner}/{repo}/traffic/clones", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download a zip archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`master`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n\n**Note**: For private repositories, these links are temporary and expire after five minutes. If the repository is empty, you will receive a 404 when you follow the redirect.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", + "description": "Get the total number of clones and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-repository-clones", "parameters": [ { "name": "owner", @@ -43150,7 +48953,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43162,12 +48965,12 @@ "deprecated": null }, { - "name": "ref", - "description": "", - "in": "PATH", + "name": "per", + "description": "The time frame to display results for.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["day", "week"], "allowNull": false, "mapToData": null, "validation": null, @@ -43175,25 +48978,23 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], - "renamed": { - "before": { "scope": "repos", "id": "downloadArchive" }, - "after": { "scope": "repos", "id": "downloadZipballArchive" }, - "date": "2020-09-17", - "note": null - } + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null }, { - "name": "Download a repository archive (tar)", + "name": "Get the weekly commit activity", "scope": "repos", - "id": "downloadTarballArchive", + "id": "getCodeFrequencyStats", "method": "GET", - "url": "/repos/{owner}/{repo}/tarball/{ref}", + "url": "/repos/{owner}/{repo}/stats/code_frequency", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download a tar archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`master`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n**Note**: For private repositories, these links are temporary and expire after five minutes.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", + "description": "Returns a weekly aggregate of the number of additions and deletions pushed to a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-weekly-commit-activity", "parameters": [ { "name": "owner", @@ -43210,20 +49011,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "ref", - "description": "", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43235,20 +49023,27 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], + "responses": [ + { + "code": 200, + "description": "Returns a weekly aggregate of the number of additions and deletions pushed to a repository." + }, + { "code": 202, "description": "Accepted" }, + { "code": 204, "description": "A header with no content is returned." } + ], "renamed": null }, { - "name": "Download a repository archive (zip)", + "name": "Get repository permissions for a user", "scope": "repos", - "id": "downloadZipballArchive", + "id": "getCollaboratorPermissionLevel", "method": "GET", - "url": "/repos/{owner}/{repo}/zipball/{ref}", + "url": "/repos/{owner}/{repo}/collaborators/{username}/permission", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a redirect URL to download a zip archive for a repository. If you omit `:ref`, the repository’s default branch (usually\n`master`) will be used. Please make sure your HTTP framework is configured to follow redirects or you will need to use\nthe `Location` header to make a second `GET` request.\n\n**Note**: For private repositories, these links are temporary and expire after five minutes. If the repository is empty, you will receive a 404 when you follow the redirect.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#download-a-repository-archive", + "description": "Checks the repository permission of a collaborator. The possible repository permissions are `admin`, `write`, `read`, and `none`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#get-repository-permissions-for-a-user", "parameters": [ { "name": "owner", @@ -43265,7 +49060,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43277,8 +49072,8 @@ "deprecated": null }, { - "name": "ref", - "description": "", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -43290,20 +49085,23 @@ "deprecated": null } ], - "responses": [{ "code": 302, "description": "Response" }], + "responses": [ + { "code": 200, "description": "if user has admin permissions" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Enable automated security fixes", + "name": "Get the combined status for a specific reference", "scope": "repos", - "id": "enableAutomatedSecurityFixes", - "method": "PUT", - "url": "/repos/{owner}/{repo}/automated-security-fixes", + "id": "getCombinedStatusForRef", + "method": "GET", + "url": "/repos/{owner}/{repo}/commits/{ref}/status", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables automated security fixes for a repository. The authenticated user must have admin access to the repository. For more information, see \"[Configuring automated security fixes](https://docs.github.com/en/articles/configuring-automated-security-fixes)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-automated-security-fixes", + "description": "Users with pull access in a repository can access a combined view of commit statuses for a given ref. The ref can be a SHA, a branch name, or a tag name.\n\n\nAdditionally, a combined `state` is returned. The `state` is one of:\n\n* **failure** if any of the contexts report as `error` or `failure`\n* **pending** if there are no statuses or a context is `pending`\n* **success** if the latest status for all contexts is `success`", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#get-the-combined-status-for-a-specific-reference", "parameters": [ { "name": "owner", @@ -43320,7 +49118,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43330,26 +49128,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Enable Git LFS for a repository", - "scope": "repos", - "id": "enableLfsForRepo", - "method": "PUT", - "url": "/repos/{owner}/{repo}/lfs", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-git-lfs-for-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "ref", + "description": "ref parameter", "in": "PATH", "type": "string", "required": true, @@ -43361,11 +49143,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -43375,25 +49170,22 @@ } ], "responses": [ - { "code": 202, "description": "Accepted" }, - { - "code": 403, - "description": "We will return a 403 with one of the following messages:\n\n- Git LFS support not enabled because Git LFS is globally disabled.\n- Git LFS support not enabled because Git LFS is disabled for the root repository in the network.\n- Git LFS support not enabled because Git LFS is disabled for ." - } + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Enable vulnerability alerts", + "name": "Get a commit", "scope": "repos", - "id": "enableVulnerabilityAlerts", - "method": "PUT", - "url": "/repos/{owner}/{repo}/vulnerability-alerts", + "id": "getCommit", + "method": "GET", + "url": "/repos/{owner}/{repo}/commits/{ref}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Enables dependency alerts and the dependency graph for a repository. The authenticated user must have admin access to the repository. For more information, see \"[About security alerts for vulnerable dependencies](https://docs.github.com/en/articles/about-security-alerts-for-vulnerable-dependencies)\".", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#enable-vulnerability-alerts", + "description": "Returns the contents of a single commit reference. You must have `read` access for the repository to use this endpoint.\n\n**Note:** If there are more than 300 files in the commit diff, the response will include pagination link headers for the remaining files, up to a limit of 3000 files. Each page contains the static commit information, and the only changes are to the file listing.\n\nYou can pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch `diff` and `patch` formats. Diffs with binary data will have no `patch` property.\n\nTo return only the SHA-1 hash of the commit reference, you can provide the `sha` custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) in the `Accept` header. You can use this endpoint to check if a remote reference's SHA-1 hash is the same as your local reference's SHA-1 hash by providing the local SHA-1 reference as the ETag.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#get-a-commit", "parameters": [ { "name": "owner", @@ -43410,7 +49202,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43420,29 +49212,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 204, "description": "Response" }], - "renamed": null - }, - { - "name": "Generate release notes content for a release", - "scope": "repos", - "id": "generateReleaseNotes", - "method": "POST", - "url": "/repos/{owner}/{repo}/releases/generate-notes", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Generate a name and body describing a [release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#releases). The body content will be markdown formatted and contain information like the changes since last release and users who contributed. The generated release notes are not saved anywhere. They are intended to be generated and used when creating a new release.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#generate-release-notes", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -43451,11 +49227,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -43464,9 +49240,9 @@ "deprecated": null }, { - "name": "tag_name", - "description": "The tag name for the release. This can be an existing tag or a new one.", - "in": "BODY", + "name": "ref", + "description": "ref parameter", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -43475,26 +49251,38 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { - "name": "target_commitish", - "description": "Specifies the commitish value that will be the target for the release's tag. Required if the supplied tag_name does not reference an existing tag. Ignored if the tag_name already exists.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." }, + { "code": 500, "description": "Internal Error" }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "Get the last year of commit activity", + "scope": "repos", + "id": "getCommitActivityStats", + "method": "GET", + "url": "/repos/{owner}/{repo}/stats/commit_activity", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Returns the last year of commit activity grouped by week. The `days` array is a group of commits per day, starting on `Sunday`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-last-year-of-commit-activity", + "parameters": [ { - "name": "previous_tag_name", - "description": "The name of the previous tag to use as the starting point for the release notes. Use to manually specify the range for the set of changes considered as part this release.", - "in": "BODY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -43503,11 +49291,11 @@ "deprecated": null }, { - "name": "configuration_file_path", - "description": "Specifies a path to a file in the repository containing configuration settings used for generating the release notes. If unspecified, the configuration file located in the repository at '.github/release.yml' or '.github/release.yaml' will be used. If that is not present, the default configuration will be used.", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -43517,25 +49305,23 @@ } ], "responses": [ - { - "code": 200, - "description": "Name and body of generated release notes" - }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 202, "description": "Accepted" }, + { "code": 204, "description": "A header with no content is returned." } ], "renamed": null }, { - "name": "Get a repository", + "name": "Get a commit comment", "scope": "repos", - "id": "get", + "id": "getCommitComment", "method": "GET", - "url": "/repos/{owner}/{repo}", + "url": "/repos/{owner}/{repo}/comments/{comment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "The `parent` and `source` objects are present when the repository is a fork. `parent` is the repository this repository was forked from, `source` is the ultimate source for the network.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#get-a-commit-comment", "parameters": [ { "name": "owner", @@ -43552,7 +49338,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43562,27 +49348,38 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get access restrictions", + "name": "Get commit signature protection", "scope": "repos", - "id": "getAccessRestrictions", + "id": "getCommitSignatureProtection", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists who has access to this protected branch.\n\n**Note**: Users, apps, and teams `restrictions` are only available for organization-owned repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-access-restrictions", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to check whether a branch requires signed commits. An enabled status of `true` indicates you must sign commits on this branch. For more information, see [Signing commits with GPG](https://docs.github.com/enterprise-cloud@latest//articles/signing-commits-with-gpg) in GitHub Help.\n\n**Note**: You must enable branch protection to require signed commits.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-commit-signature-protection", "parameters": [ { "name": "owner", @@ -43599,7 +49396,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43612,7 +49409,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -43631,16 +49428,16 @@ "renamed": null }, { - "name": "Get admin branch protection", + "name": "Get community profile metrics", "scope": "repos", - "id": "getAdminBranchProtection", + "id": "getCommunityProfileMetrics", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", + "url": "/repos/{owner}/{repo}/community/profile", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-admin-branch-protection", + "description": "Returns all community profile metrics for a repository. The repository cannot be a fork.\n\nThe returned metrics include an overall health score, the repository description, the presence of documentation, the\ndetected code of conduct, the detected license, and the presence of ISSUE\\_TEMPLATE, PULL\\_REQUEST\\_TEMPLATE,\nREADME, and CONTRIBUTING files.\n\nThe `health_percentage` score is defined as a percentage of how many of\nthese four documents are present: README, CONTRIBUTING, LICENSE, and\nCODE_OF_CONDUCT. For example, if all four documents are present, then\nthe `health_percentage` is `100`. If only one is present, then the\n`health_percentage` is `25`.\n\n`content_reports_enabled` is only returned for organization-owned repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/community#get-community-profile-metrics", "parameters": [ { "name": "owner", @@ -43657,20 +49454,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "branch", - "description": "The name of the branch.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43686,16 +49470,16 @@ "renamed": null }, { - "name": "List environments", + "name": "Get repository content", "scope": "repos", - "id": "getAllEnvironments", + "id": "getContent", "method": "GET", - "url": "/repos/{owner}/{repo}/environments", + "url": "/repos/{owner}/{repo}/contents/{path}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the environments for a repository.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/environments#list-environments", + "description": "Gets the contents of a file or directory in a repository. Specify the file path or directory in `:path`. If you omit\n`:path`, you will receive the contents of the repository's root directory. See the description below regarding what the API response includes for directories. \n\nFiles and symlinks support [a custom media type](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for\nretrieving the raw content or rendered HTML (when supported). All content types support [a custom media\ntype](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) to ensure the content is returned in a consistent\nobject format.\n\n**Notes**:\n* To get a repository's contents recursively, you can [recursively get the tree](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#trees).\n* This API has an upper limit of 1,000 files for a directory. If you need to retrieve more files, use the [Git Trees\nAPI](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tree).\n * Download URLs expire and are meant to be used just once. To ensure the download URL does not expire, please use the contents API to obtain a fresh download URL for each download.\n#### Size limits\nIf the requested file's size is:\n* 1 MB or smaller: All features of this endpoint are supported.\n* Between 1-100 MB: Only the `raw` or `object` [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/repos/contents#custom-media-types-for-repository-contents) are supported. Both will work as normal, except that when using the `object` media type, the `content` field will be an empty string and the `encoding` field will be `\"none\"`. To get the contents of these larger files, use the `raw` media type.\n * Greater than 100 MB: This endpoint is not supported.\n\n#### If the content is a directory\nThe response will be an array of objects, one object for each item in the directory.\nWhen listing the contents of a directory, submodules have their \"type\" specified as \"file\". Logically, the value\n_should_ be \"submodule\". This behavior exists in API v3 [for backwards compatibility purposes](https://git.io/v1YCW).\nIn the next major version of the API, the type will be returned as \"submodule\".\n\n#### If the content is a symlink \nIf the requested `:path` points to a symlink, and the symlink's target is a normal file in the repository, then the\nAPI responds with the content of the file (in the format shown in the example. Otherwise, the API responds with an object \ndescribing the symlink itself.\n\n#### If the content is a submodule\nThe `submodule_git_url` identifies the location of the submodule repository, and the `sha` identifies a specific\ncommit within the submodule repository. Git uses the given URL when cloning the submodule repository, and checks out\nthe submodule at that specific commit.\n\nIf the submodule repository is not hosted on github.com, the Git URLs (`git_url` and `_links[\"git\"]`) and the\ngithub.com URLs (`html_url` and `_links[\"html\"]`) will have null values.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-repository-content", "parameters": [ { "name": "owner", @@ -43712,7 +49496,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43724,11 +49508,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "path", + "description": "path parameter", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -43737,10 +49521,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "ref", + "description": "The name of the commit/branch/tag. Default: the repository’s default branch.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -43750,20 +49534,26 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 200, "description": "Response" }, + { "code": 302, "description": "Found" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get all status check contexts", + "name": "Get all contributor commit activity", "scope": "repos", - "id": "getAllStatusCheckContexts", + "id": "getContributorsStats", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", + "url": "/repos/{owner}/{repo}/stats/contributors", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-all-status-check-contexts", + "description": "\nReturns the `total` number of commits authored by the contributor. In addition, the response includes a Weekly Hash (`weeks` array) with the following information:\n\n* `w` - Start of the week, given as a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time).\n* `a` - Number of additions\n* `d` - Number of deletions\n* `c` - Number of commits", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-all-contributor-commit-activity", "parameters": [ { "name": "owner", @@ -43780,20 +49570,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "branch", - "description": "The name of the branch.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43807,21 +49584,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 202, "description": "Accepted" }, + { "code": 204, "description": "A header with no content is returned." } ], "renamed": null }, { - "name": "Get all repository topics", + "name": "Get a custom deployment protection rule", "scope": "repos", - "id": "getAllTopics", + "id": "getCustomDeploymentProtectionRule", "method": "GET", - "url": "/repos/{owner}/{repo}/topics", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-all-repository-topics", + "description": "Gets an enabled custom deployment protection rule for an environment. Anyone with read access to the repository can use this endpoint. If the repository is private and you want to use a personal access token (classic), you must use an access token with the `repo` scope. GitHub Apps and fine-grained personal access tokens must have the `actions:read` permission to use this endpoint. For more information about environments, see \"[Using environments for deployment](https://docs.github.com/enterprise-cloud@latest//en/actions/deployment/targeting-different-environments/using-environments-for-deployment).\"\n\nFor more information about the app that is providing this custom deployment rule, see [`GET /apps/{app_slug}`](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#get-an-app).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/protection-rules#get-a-deployment-protection-rule", "parameters": [ { "name": "owner", @@ -43838,7 +49616,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43850,11 +49628,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -43863,11 +49641,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "protection_rule_id", + "description": "The unique identifier of the protection rule.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -43876,23 +49654,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get apps with access to the protected branch", + "name": "Get a deploy key", "scope": "repos", - "id": "getAppsWithAccessToProtectedBranch", + "id": "getDeployKey", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", + "url": "/repos/{owner}/{repo}/keys/{key_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the GitHub Apps that have push access to this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-apps-with-access-to-the-protected-branch", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deploy-keys#get-a-deploy-key", "parameters": [ { "name": "owner", @@ -43909,7 +49684,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43921,10 +49696,10 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "key_id", + "description": "The unique identifier of the key.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -43941,16 +49716,16 @@ "renamed": null }, { - "name": "Get an autolink reference of a repository", + "name": "Get a deployment", "scope": "repos", - "id": "getAutolink", + "id": "getDeployment", "method": "GET", - "url": "/repos/{owner}/{repo}/autolinks/{autolink_id}", + "url": "/repos/{owner}/{repo}/deployments/{deployment_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This returns a single autolink reference by ID that was configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//v3/repos#get-autolink", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployments#get-a-deployment", "parameters": [ { "name": "owner", @@ -43967,7 +49742,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -43979,8 +49754,8 @@ "deprecated": null }, { - "name": "autolink_id", - "description": "The unique identifier of the autolink.", + "name": "deployment_id", + "description": "deployment_id parameter", "in": "PATH", "type": "integer", "required": true, @@ -43999,16 +49774,16 @@ "renamed": null }, { - "name": "Get a branch", + "name": "Get a deployment branch policy", "scope": "repos", - "id": "getBranch", + "id": "getDeploymentBranchPolicy", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-branch", + "description": "Gets a deployment branch policy for an environment.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#get-deployment-branch-policy", "parameters": [ { "name": "owner", @@ -44025,7 +49800,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44037,8 +49812,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -44048,26 +49823,35 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "branch_policy_id", + "description": "The unique identifier of the branch policy.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get branch protection", + "name": "Get a deployment status", "scope": "repos", - "id": "getBranchProtection", + "id": "getDeploymentStatus", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection", + "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses/{status_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-branch-protection", + "description": "Users with pull access can view a deployment status for a deployment:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/statuses#get-a-deployment-status", "parameters": [ { "name": "owner", @@ -44084,7 +49868,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44096,10 +49880,23 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "deployment_id", + "description": "deployment_id parameter", "in": "PATH", - "type": "string", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "status_id", + "description": "", + "in": "PATH", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -44116,16 +49913,16 @@ "renamed": null }, { - "name": "Get repository clones", + "name": "Get an environment", "scope": "repos", - "id": "getClones", + "id": "getEnvironment", "method": "GET", - "url": "/repos/{owner}/{repo}/traffic/clones", + "url": "/repos/{owner}/{repo}/environments/{environment_name}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Get the total number of clones and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-repository-clones", + "description": "**Note:** To get information about name patterns that branches must match in order to deploy to this environment, see \"[Get a deployment branch policy](/rest/deployments/branch-policies#get-a-deployment-branch-policy).\"\n\nAnyone with read access to the repository can use this endpoint. If the\nrepository is private, you must use an access token with the `repo` scope. GitHub\nApps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/environments#get-an-environment", "parameters": [ { "name": "owner", @@ -44142,7 +49939,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44154,12 +49951,12 @@ "deprecated": null }, { - "name": "per", - "description": "The time frame to display results for.", - "in": "QUERY", + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["", "day", "week"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -44167,23 +49964,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get the weekly commit activity", + "name": "Get latest Pages build", "scope": "repos", - "id": "getCodeFrequencyStats", + "id": "getLatestPagesBuild", "method": "GET", - "url": "/repos/{owner}/{repo}/stats/code_frequency", + "url": "/repos/{owner}/{repo}/pages/builds/latest", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a weekly aggregate of the number of additions and deletions pushed to a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-weekly-commit-activity", + "description": "Gets information about the single most recent build of a GitHub Enterprise Cloud Pages site.\n\nA token with the `repo` scope is required. GitHub Apps must have the `pages:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-latest-pages-build", "parameters": [ { "name": "owner", @@ -44200,7 +49994,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44212,27 +50006,20 @@ "deprecated": null } ], - "responses": [ - { - "code": 200, - "description": "Returns a weekly aggregate of the number of additions and deletions pushed to a repository." - }, - { "code": 202, "description": "Accepted" }, - { "code": 204, "description": "A header with no content is returned." } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get repository permissions for a user", + "name": "Get the latest release", "scope": "repos", - "id": "getCollaboratorPermissionLevel", + "id": "getLatestRelease", "method": "GET", - "url": "/repos/{owner}/{repo}/collaborators/{username}/permission", + "url": "/repos/{owner}/{repo}/releases/latest", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Checks the repository permission of a collaborator. The possible repository permissions are `admin`, `write`, `read`, and `none`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#get-repository-permissions-for-a-user", + "description": "View the latest published full release for the repository.\n\nThe latest release is the most recent non-prerelease, non-draft release, sorted by the `created_at` attribute. The `created_at` attribute is the date of the commit used for the release, and not the date when the release was drafted or published.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-the-latest-release", "parameters": [ { "name": "owner", @@ -44249,20 +50036,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "username", - "description": "The handle for the GitHub user account.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44274,27 +50048,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "if user has admin permissions" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get the combined status for a specific reference", + "name": "Get an organization repository ruleset", "scope": "repos", - "id": "getCombinedStatusForRef", + "id": "getOrgRuleset", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{ref}/status", + "url": "/orgs/{org}/rulesets/{ruleset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with pull access in a repository can access a combined view of commit statuses for a given ref. The ref can be a SHA, a branch name, or a tag name.\n\n\nAdditionally, a combined `state` is returned. The `state` is one of:\n\n* **failure** if any of the contexts report as `error` or `failure`\n* **pending** if there are no statuses or a context is `pending`\n* **success** if the latest status for all contexts is `success`", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#get-the-combined-status-for-a-specific-reference", + "description": "Get a repository ruleset for an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#get-organization-ruleset", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44306,10 +50077,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "ruleset_id", + "description": "The ID of the ruleset.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -44317,10 +50088,30 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Get all organization repository rulesets", + "scope": "repos", + "id": "getOrgRulesets", + "method": "GET", + "url": "/orgs/{org}/rulesets", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Get all the repository rulesets for an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#get-organization-rulesets", + "parameters": [ { - "name": "ref", - "description": "ref parameter", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44360,21 +50151,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Get a commit", + "name": "Get a GitHub Enterprise Cloud Pages site", "scope": "repos", - "id": "getCommit", + "id": "getPages", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{ref}", + "url": "/repos/{owner}/{repo}/pages", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the contents of a single commit reference. You must have `read` access for the repository to use this endpoint.\n\n**Note:** If there are more than 300 files in the commit diff, the response will include pagination link headers for the remaining files, up to a limit of 3000 files. Each page contains the static commit information, and the only changes are to the file listing.\n\nYou can pass the appropriate [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) to fetch `diff` and `patch` formats. Diffs with binary data will have no `patch` property.\n\nTo return only the SHA-1 hash of the commit reference, you can provide the `sha` custom [media type](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/#commits-commit-comparison-and-pull-requests) in the `Accept` header. You can use this endpoint to check if a remote reference's SHA-1 hash is the same as your local reference's SHA-1 hash by providing the local SHA-1 reference as the ETag.\n\n**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#get-a-commit", + "description": "Gets information about a GitHub Enterprise Cloud Pages site.\n\nA token with the `repo` scope is required. GitHub Apps must have the `pages:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-a-github-pages-site", "parameters": [ { "name": "owner", @@ -44391,7 +50183,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44401,13 +50193,32 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Get GitHub Enterprise Cloud Pages build", + "scope": "repos", + "id": "getPagesBuild", + "method": "GET", + "url": "/repos/{owner}/{repo}/pages/builds/{build_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Gets information about a GitHub Enterprise Cloud Pages build.\n\nA token with the `repo` scope is required. GitHub Apps must have the `pages:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-github-pages-build", + "parameters": [ { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -44416,11 +50227,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -44429,10 +50240,10 @@ "deprecated": null }, { - "name": "ref", - "description": "ref parameter", + "name": "build_id", + "description": "", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -44442,29 +50253,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, - { "code": 500, "description": "Internal Error" }, - { "code": 503, "description": "Service unavailable" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get the last year of commit activity", + "name": "Get a DNS health check for GitHub Pages", "scope": "repos", - "id": "getCommitActivityStats", + "id": "getPagesHealthCheck", "method": "GET", - "url": "/repos/{owner}/{repo}/stats/commit_activity", + "url": "/repos/{owner}/{repo}/pages/health", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the last year of commit activity grouped by week. The `days` array is a group of commits per day, starting on `Sunday`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-last-year-of-commit-activity", + "description": "Gets a health check of the DNS settings for the `CNAME` record configured for a repository's GitHub Pages.\n\nThe first request to this endpoint returns a `202 Accepted` status and starts an asynchronous background task to get the results for the domain. After the background task completes, subsequent requests to this endpoint return a `200 OK` status with the health check results in the response.\n\nTo use this endpoint, you must be a repository administrator, maintainer, or have the 'manage GitHub Pages settings' permission. A token with the `repo` scope or Pages write permission is required. GitHub Apps must have the `administrative:write` and `pages:write` permissions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-a-dns-health-check-for-github-pages", "parameters": [ { "name": "owner", @@ -44481,7 +50283,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44495,22 +50297,27 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 202, "description": "Accepted" }, - { "code": 204, "description": "A header with no content is returned." } + { "code": 202, "description": "Empty response" }, + { + "code": 400, + "description": "Custom domains are not available for GitHub Pages" + }, + { "code": 404, "description": "Resource not found" }, + { "code": 422, "description": "There isn't a CNAME for this page" } ], "renamed": null }, { - "name": "Get a commit comment", + "name": "Get the weekly commit count", "scope": "repos", - "id": "getCommitComment", + "id": "getParticipationStats", "method": "GET", - "url": "/repos/{owner}/{repo}/comments/{comment_id}", + "url": "/repos/{owner}/{repo}/stats/participation", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#get-a-commit-comment", + "description": "Returns the total commit counts for the `owner` and total commit counts in `all`. `all` is everyone combined, including the `owner` in the last 52 weeks. If you'd like to get the commit counts for non-owners, you can subtract `owner` from `all`.\n\nThe array order is oldest week (index 0) to most recent week.\n\nThe most recent week is seven days ago at UTC midnight to today at UTC midnight.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-weekly-commit-count", "parameters": [ { "name": "owner", @@ -44527,7 +50334,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44537,38 +50344,28 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, + { + "code": 200, + "description": "The array order is oldest week (index 0) to most recent week." + }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get commit signature protection", + "name": "Get pull request review protection", "scope": "repos", - "id": "getCommitSignatureProtection", + "id": "getPullRequestReviewProtection", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_signatures", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nWhen authenticated with admin or owner permissions to the repository, you can use this endpoint to check whether a branch requires signed commits. An enabled status of `true` indicates you must sign commits on this branch. For more information, see [Signing commits with GPG](https://docs.github.com/articles/signing-commits-with-gpg) in GitHub Help.\n\n**Note**: You must enable branch protection to require signed commits.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-commit-signature-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-pull-request-review-protection", "parameters": [ { "name": "owner", @@ -44585,7 +50382,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44598,7 +50395,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -44610,23 +50407,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get community profile metrics", + "name": "Get the hourly commit count for each day", "scope": "repos", - "id": "getCommunityProfileMetrics", + "id": "getPunchCardStats", "method": "GET", - "url": "/repos/{owner}/{repo}/community/profile", + "url": "/repos/{owner}/{repo}/stats/punch_card", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns all community profile metrics for a repository. The repository must be public, and cannot be a fork.\n\nThe returned metrics include an overall health score, the repository description, the presence of documentation, the\ndetected code of conduct, the detected license, and the presence of ISSUE\\_TEMPLATE, PULL\\_REQUEST\\_TEMPLATE,\nREADME, and CONTRIBUTING files.\n\nThe `health_percentage` score is defined as a percentage of how many of\nthese four documents are present: README, CONTRIBUTING, LICENSE, and\nCODE_OF_CONDUCT. For example, if all four documents are present, then\nthe `health_percentage` is `100`. If only one is present, then the\n`health_percentage` is `25`.\n\n`content_reports_enabled` is only returned for organization-owned repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/community#get-community-profile-metrics", + "description": "Each array contains the day number, hour number, and number of commits:\n\n* `0-6`: Sunday - Saturday\n* `0-23`: Hour of day\n* Number of commits\n\nFor example, `[2, 14, 25]` indicates that there were 25 total commits, during the 2:00pm hour on Tuesdays. All times are based on the time zone of individual commits.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-hourly-commit-count-for-each-day", "parameters": [ { "name": "owner", @@ -44643,7 +50437,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44655,20 +50449,26 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { + "code": 200, + "description": "For example, `[2, 14, 25]` indicates that there were 25 total commits, during the 2:00pm hour on Tuesdays. All times are based on the time zone of individual commits." + }, + { "code": 204, "description": "A header with no content is returned." } + ], "renamed": null }, { - "name": "Get repository content", + "name": "Get a repository README", "scope": "repos", - "id": "getContent", + "id": "getReadme", "method": "GET", - "url": "/repos/{owner}/{repo}/contents/{path}", + "url": "/repos/{owner}/{repo}/readme", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the contents of a file or directory in a repository. Specify the file path or directory in `:path`. If you omit\n`:path`, you will receive the contents of the repository's root directory. See the description below regarding what the API response includes for directories. \n\nFiles and symlinks support [a custom media type](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for\nretrieving the raw content or rendered HTML (when supported). All content types support [a custom media\ntype](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) to ensure the content is returned in a consistent\nobject format.\n\n**Notes**:\n* To get a repository's contents recursively, you can [recursively get the tree](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#trees).\n* This API has an upper limit of 1,000 files for a directory. If you need to retrieve more files, use the [Git Trees\nAPI](https://docs.github.com/enterprise-cloud@latest//rest/reference/git#get-a-tree).\n * Download URLs expire and are meant to be used just once. To ensure the download URL does not expire, please use the contents API to obtain a fresh download URL for each download.\n#### Size limits\nIf the requested file's size is:\n* 1 MB or smaller: All features of this endpoint are supported.\n* Between 1-100 MB: Only the `raw` or `object` [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/repos/contents#custom-media-types-for-repository-contents) are supported. Both will work as normal, except that when using the `object` media type, the `content` field will be an empty string and the `encoding` field will be `\"none\"`. To get the contents of these larger files, use the `raw` media type.\n * Greater than 100 MB: This endpoint is not supported.\n\n#### If the content is a directory\nThe response will be an array of objects, one object for each item in the directory.\nWhen listing the contents of a directory, submodules have their \"type\" specified as \"file\". Logically, the value\n_should_ be \"submodule\". This behavior exists in API v3 [for backwards compatibility purposes](https://git.io/v1YCW).\nIn the next major version of the API, the type will be returned as \"submodule\".\n\n#### If the content is a symlink \nIf the requested `:path` points to a symlink, and the symlink's target is a normal file in the repository, then the\nAPI responds with the content of the file (in the format shown in the example. Otherwise, the API responds with an object \ndescribing the symlink itself.\n\n#### If the content is a submodule\nThe `submodule_git_url` identifies the location of the submodule repository, and the `sha` identifies a specific\ncommit within the submodule repository. Git uses the given URL when cloning the submodule repository, and checks out\nthe submodule at that specific commit.\n\nIf the submodule repository is not hosted on github.com, the Git URLs (`git_url` and `_links[\"git\"]`) and the\ngithub.com URLs (`html_url` and `_links[\"html\"]`) will have null values.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-repository-content", + "description": "Gets the preferred README for a repository.\n\nREADMEs support [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for retrieving the raw content or rendered HTML.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository-readme", "parameters": [ { "name": "owner", @@ -44685,20 +50485,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "path", - "description": "path parameter", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44711,7 +50498,7 @@ }, { "name": "ref", - "description": "The name of the commit/branch/tag. Default: the repository’s default branch (usually `master`)", + "description": "The name of the commit/branch/tag. Default: the repository’s default branch.", "in": "QUERY", "type": "string", "required": false, @@ -44725,24 +50512,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 200, "description": "Response" }, - { "code": 302, "description": "Found" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get all contributor commit activity", + "name": "Get a repository README for a directory", "scope": "repos", - "id": "getContributorsStats", + "id": "getReadmeInDirectory", "method": "GET", - "url": "/repos/{owner}/{repo}/stats/contributors", + "url": "/repos/{owner}/{repo}/readme/{dir}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "\nReturns the `total` number of commits authored by the contributor. In addition, the response includes a Weekly Hash (`weeks` array) with the following information:\n\n* `w` - Start of the week, given as a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time).\n* `a` - Number of additions\n* `d` - Number of deletions\n* `c` - Number of commits", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-all-contributor-commit-activity", + "description": "Gets the README from a repository directory.\n\nREADMEs support [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for retrieving the raw content or rendered HTML.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository-directory-readme", "parameters": [ { "name": "owner", @@ -44759,7 +50547,20 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "dir", + "description": "The alternate path to look for a README file", "in": "PATH", "type": "string", "required": true, @@ -44769,26 +50570,42 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "ref", + "description": "The name of the commit/branch/tag. Default: the repository’s default branch.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 202, "description": "Accepted" }, - { "code": 204, "description": "A header with no content is returned." } + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get a deploy key", + "name": "Get a release", "scope": "repos", - "id": "getDeployKey", + "id": "getRelease", "method": "GET", - "url": "/repos/{owner}/{repo}/keys/{key_id}", + "url": "/repos/{owner}/{repo}/releases/{release_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-deploy-key", + "description": "**Note:** This returns an `upload_url` key corresponding to the endpoint for uploading release assets. This key is a [hypermedia resource](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release", "parameters": [ { "name": "owner", @@ -44805,7 +50622,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44817,8 +50634,8 @@ "deprecated": null }, { - "name": "key_id", - "description": "The unique identifier of the key.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", "type": "integer", "required": true, @@ -44831,22 +50648,25 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { + "code": 200, + "description": "**Note:** This returns an `upload_url` key corresponding to the endpoint for uploading release assets. This key is a [hypermedia resource](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia)." + }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get a deployment", + "name": "Get a release asset", "scope": "repos", - "id": "getDeployment", + "id": "getReleaseAsset", "method": "GET", - "url": "/repos/{owner}/{repo}/deployments/{deployment_id}", + "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-deployment", + "description": "To download the asset's binary content, set the `Accept` header of the request to [`application/octet-stream`](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types). The API will either redirect the client to the location, or stream it directly if possible. API clients should handle both a `200` or `302` response.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release-asset", "parameters": [ { "name": "owner", @@ -44863,7 +50683,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44875,8 +50695,8 @@ "deprecated": null }, { - "name": "deployment_id", - "description": "deployment_id parameter", + "name": "asset_id", + "description": "The unique identifier of the asset.", "in": "PATH", "type": "integer", "required": true, @@ -44890,21 +50710,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 302, "description": "Found" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get a deployment branch policy", + "name": "Get a release by tag name", "scope": "repos", - "id": "getDeploymentBranchPolicy", + "id": "getReleaseByTag", "method": "GET", - "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", + "url": "/repos/{owner}/{repo}/releases/tags/{tag}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a deployment branch policy for an environment.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#get-deployment-branch-policy", + "description": "Get a published release with the specified tag.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release-by-tag-name", "parameters": [ { "name": "owner", @@ -44921,7 +50742,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -44933,8 +50754,8 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", + "name": "tag", + "description": "tag parameter", "in": "PATH", "type": "string", "required": true, @@ -44944,35 +50765,25 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "branch_policy_id", - "description": "The unique identifier of the branch policy.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a deployment status", + "name": "Get a repository ruleset", "scope": "repos", - "id": "getDeploymentStatus", + "id": "getRepoRuleset", "method": "GET", - "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses/{status_id}", + "url": "/repos/{owner}/{repo}/rulesets/{ruleset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with pull access can view a deployment status for a deployment:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-deployment-status", + "description": "Get a ruleset for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#get-repository-ruleset", "parameters": [ { "name": "owner", @@ -44989,7 +50800,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45001,8 +50812,8 @@ "deprecated": null }, { - "name": "deployment_id", - "description": "deployment_id parameter", + "name": "ruleset_id", + "description": "The ID of the ruleset.", "in": "PATH", "type": "integer", "required": true, @@ -45014,11 +50825,11 @@ "deprecated": null }, { - "name": "status_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "name": "includes_parents", + "description": "Include rulesets configured at higher levels that apply to this repository", + "in": "QUERY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45029,21 +50840,22 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } ], "renamed": null }, { - "name": "Get an environment", + "name": "Get all repository rulesets", "scope": "repos", - "id": "getEnvironment", + "id": "getRepoRulesets", "method": "GET", - "url": "/repos/{owner}/{repo}/environments/{environment_name}", + "url": "/repos/{owner}/{repo}/rulesets", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** To get information about name patterns that branches must match in order to deploy to this environment, see \"[Get a deployment branch policy](/rest/deployments/branch-policies#get-a-deployment-branch-policy).\"\n\nAnyone with read access to the repository can use this endpoint. If the\nrepository is private, you must use an access token with the `repo` scope. GitHub\nApps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-an-environment", + "description": "Get all the rulesets for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#get-repository-rulesets", "parameters": [ { "name": "owner", @@ -45060,7 +50872,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45072,40 +50884,24 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get latest Pages build", - "scope": "repos", - "id": "getLatestPagesBuild", - "method": "GET", - "url": "/repos/{owner}/{repo}/pages/builds/latest", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-latest-pages-build", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45114,11 +50910,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "includes_parents", + "description": "Include rulesets configured at higher levels that apply to this repository", + "in": "QUERY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45127,20 +50923,24 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { - "name": "Get the latest release", + "name": "Get status checks protection", "scope": "repos", - "id": "getLatestRelease", + "id": "getStatusChecksProtection", "method": "GET", - "url": "/repos/{owner}/{repo}/releases/latest", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "View the latest published full release for the repository.\n\nThe latest release is the most recent non-prerelease, non-draft release, sorted by the `created_at` attribute. The `created_at` attribute is the date of the commit used for the release, and not the date when the release was drafted or published.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-the-latest-release", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#get-status-checks-protection", "parameters": [ { "name": "owner", @@ -45157,36 +50957,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a GitHub Enterprise Cloud Pages site", - "scope": "repos", - "id": "getPages", - "method": "GET", - "url": "/repos/{owner}/{repo}/pages", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-a-github-pages-site", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45198,8 +50969,8 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -45218,16 +50989,16 @@ "renamed": null }, { - "name": "Get GitHub Enterprise Cloud Pages build", + "name": "Get teams with access to the protected branch", "scope": "repos", - "id": "getPagesBuild", + "id": "getTeamsWithAccessToProtectedBranch", "method": "GET", - "url": "/repos/{owner}/{repo}/pages/builds/{build_id}", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-github-pages-build", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the teams who have push access to this branch. The list includes child teams.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#list-teams-with-access-to-the-protected-branch", "parameters": [ { "name": "owner", @@ -45244,7 +51015,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45256,10 +51027,10 @@ "deprecated": null }, { - "name": "build_id", - "description": "", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -45269,20 +51040,23 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get a DNS health check for GitHub Pages", + "name": "Get top referral paths", "scope": "repos", - "id": "getPagesHealthCheck", + "id": "getTopPaths", "method": "GET", - "url": "/repos/{owner}/{repo}/pages/health", + "url": "/repos/{owner}/{repo}/traffic/popular/paths", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a health check of the DNS settings for the `CNAME` record configured for a repository's GitHub Pages.\n\nThe first request to this endpoint returns a `202 Accepted` status and starts an asynchronous background task to get the results for the domain. After the background task completes, subsequent requests to this endpoint return a `200 OK` status with the health check results in the response.\n\nUsers must have admin or owner permissions. GitHub Apps must have the `pages:write` and `administration:write` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#get-a-dns-health-check-for-github-pages", + "description": "Get the top 10 popular contents over the last 14 days.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-top-referral-paths", "parameters": [ { "name": "owner", @@ -45299,7 +51073,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45313,27 +51087,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 202, "description": "Empty response" }, - { - "code": 400, - "description": "Custom domains are not available for GitHub Pages" - }, - { "code": 404, "description": "Resource not found" }, - { "code": 422, "description": "There isn't a CNAME for this page" } + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "Get the weekly commit count", + "name": "Get top referral sources", "scope": "repos", - "id": "getParticipationStats", + "id": "getTopReferrers", "method": "GET", - "url": "/repos/{owner}/{repo}/stats/participation", + "url": "/repos/{owner}/{repo}/traffic/popular/referrers", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the total commit counts for the `owner` and total commit counts in `all`. `all` is everyone combined, including the `owner` in the last 52 weeks. If you'd like to get the commit counts for non-owners, you can subtract `owner` from `all`.\n\nThe array order is oldest week (index 0) to most recent week.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/statistics#get-the-weekly-commit-count", + "description": "Get the top 10 referrers over the last 14 days.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-top-referral-sources", "parameters": [ { "name": "owner", @@ -45350,7 +51118,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45363,25 +51131,22 @@ } ], "responses": [ - { - "code": 200, - "description": "The array order is oldest week (index 0) to most recent week." - }, - { "code": 404, "description": "Resource not found" } + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "Get pull request review protection", + "name": "Get users with access to the protected branch", "scope": "repos", - "id": "getPullRequestReviewProtection", + "id": "getUsersWithAccessToProtectedBranch", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-pull-request-review-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the people who have push access to this branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#list-users-with-access-to-the-protected-branch", "parameters": [ { "name": "owner", @@ -45398,7 +51163,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45411,7 +51176,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -45423,20 +51188,23 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Get the hourly commit count for each day", + "name": "Get page views", "scope": "repos", - "id": "getPunchCardStats", + "id": "getViews", "method": "GET", - "url": "/repos/{owner}/{repo}/stats/punch_card", + "url": "/repos/{owner}/{repo}/traffic/views", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Each array contains the day number, hour number, and number of commits:\n\n* `0-6`: Sunday - Saturday\n* `0-23`: Hour of day\n* Number of commits\n\nFor example, `[2, 14, 25]` indicates that there were 25 total commits, during the 2:00pm hour on Tuesdays. All times are based on the time zone of individual commits.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/statistics/repos#get-the-hourly-commit-count-for-each-day", + "description": "Get the total number of views and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-page-views", "parameters": [ { "name": "owner", @@ -45453,7 +51221,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45463,28 +51231,38 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per", + "description": "The time frame to display results for.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["day", "week"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { - "code": 200, - "description": "For example, `[2, 14, 25]` indicates that there were 25 total commits, during the 2:00pm hour on Tuesdays. All times are based on the time zone of individual commits." - }, - { "code": 204, "description": "A header with no content is returned." } + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" } ], "renamed": null }, { - "name": "Get a repository README", + "name": "Get a repository webhook", "scope": "repos", - "id": "getReadme", + "id": "getWebhook", "method": "GET", - "url": "/repos/{owner}/{repo}/readme", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the preferred README for a repository.\n\nREADMEs support [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for retrieving the raw content or rendered HTML.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository-readme", + "description": "Returns a webhook configured in a repository. To get only the webhook `config` properties, see \"[Get a webhook configuration for a repository](/rest/reference/repos#get-a-webhook-configuration-for-a-repository).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#get-a-repository-webhook", "parameters": [ { "name": "owner", @@ -45501,7 +51279,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45513,11 +51291,11 @@ "deprecated": null }, { - "name": "ref", - "description": "The name of the commit/branch/tag. Default: the repository’s default branch (usually `master`)", - "in": "QUERY", - "type": "string", - "required": false, + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -45528,25 +51306,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get a repository README for a directory", + "name": "Get a webhook configuration for a repository", "scope": "repos", - "id": "getReadmeInDirectory", + "id": "getWebhookConfigForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/readme/{dir}", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/config", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets the README from a repository directory.\n\nREADMEs support [custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types) for retrieving the raw content or rendered HTML.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-repository-directory-readme", + "description": "Returns the webhook configuration for a repository. To get more information about the webhook, including the `active` state and `events`, use \"[Get a repository webhook](/rest/reference/orgs#get-a-repository-webhook).\"\n\nAccess tokens must have the `read:repo_hook` or `repo` scope, and GitHub Apps must have the `repository_hooks:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-config#get-a-webhook-configuration-for-a-repository", "parameters": [ { "name": "owner", @@ -45563,7 +51337,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45575,10 +51349,10 @@ "deprecated": null }, { - "name": "dir", - "description": "The alternate path to look for a README file", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -45586,42 +51360,22 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "ref", - "description": "The name of the commit/branch/tag. Default: the repository’s default branch (usually `master`)", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." } ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a release", + "name": "Get a delivery for a repository webhook", "scope": "repos", - "id": "getRelease", + "id": "getWebhookDelivery", "method": "GET", - "url": "/repos/{owner}/{repo}/releases/{release_id}", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Note:** This returns an `upload_url` key corresponding to the endpoint for uploading release assets. This key is a [hypermedia resource](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release", + "description": "Returns a delivery for a webhook configured in a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#get-a-delivery-for-a-repository-webhook", "parameters": [ { "name": "owner", @@ -45638,7 +51392,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45650,8 +51404,21 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "delivery_id", + "description": "", "in": "PATH", "type": "integer", "required": true, @@ -45664,25 +51431,27 @@ } ], "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { - "code": 200, - "description": "**Note:** This returns an `upload_url` key corresponding to the endpoint for uploading release assets. This key is a [hypermedia resource](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia)." - }, - { "code": 404, "description": "Resource not found" } + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get a release asset", + "name": "List all autolinks of a repository", "scope": "repos", - "id": "getReleaseAsset", + "id": "listAutolinks", "method": "GET", - "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", + "url": "/repos/{owner}/{repo}/autolinks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "To download the asset's binary content, set the `Accept` header of the request to [`application/octet-stream`](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types). The API will either redirect the client to the location, or stream it directly if possible. API clients should handle both a `200` or `302` response.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release-asset", + "description": "This returns a list of autolinks configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/autolinks#list-all-autolinks-of-a-repository", "parameters": [ { "name": "owner", @@ -45699,7 +51468,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45711,11 +51480,11 @@ "deprecated": null }, { - "name": "asset_id", - "description": "The unique identifier of the asset.", - "in": "PATH", + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45724,24 +51493,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 302, "description": "Found" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a release by tag name", + "name": "List branches", "scope": "repos", - "id": "getReleaseByTag", + "id": "listBranches", "method": "GET", - "url": "/repos/{owner}/{repo}/releases/tags/{tag}", + "url": "/repos/{owner}/{repo}/branches", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Get a published release with the specified tag.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-a-release-by-tag-name", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branches#list-branches", "parameters": [ { "name": "owner", @@ -45758,7 +51523,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45770,11 +51535,37 @@ "deprecated": null }, { - "name": "tag", - "description": "tag parameter", - "in": "PATH", - "type": "string", - "required": true, + "name": "protected", + "description": "Setting to `true` returns only protected branches. When set to `false`, only unprotected branches are returned. Omitting this parameter returns all branches.", + "in": "QUERY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45790,16 +51581,16 @@ "renamed": null }, { - "name": "Get status checks protection", + "name": "List branches for HEAD commit", "scope": "repos", - "id": "getStatusChecksProtection", + "id": "listBranchesForHeadCommit", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", + "url": "/repos/{owner}/{repo}/commits/{commit_sha}/branches-where-head", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#get-status-checks-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReturns all branches where the given commit SHA is the HEAD, or latest commit for the branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-branches-for-head-commit", "parameters": [ { "name": "owner", @@ -45816,7 +51607,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45828,8 +51619,8 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "commit_sha", + "description": "The SHA of the commit.", "in": "PATH", "type": "string", "required": true, @@ -45843,21 +51634,24 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Get teams with access to the protected branch", + "name": "List repository collaborators", "scope": "repos", - "id": "getTeamsWithAccessToProtectedBranch", + "id": "listCollaborators", "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", + "url": "/repos/{owner}/{repo}/collaborators", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the teams who have push access to this branch. The list includes child teams.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-teams-with-access-to-the-protected-branch", + "description": "For organization-owned repositories, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners.\nOrganization members with write, maintain, or admin privileges on the organization-owned repository can use this endpoint.\n\nTeam members will include the members of child teams.\n\nYou must authenticate using an access token with the `read:org` and `repo` scopes with push access to use this\nendpoint. GitHub Apps must have the `members` organization permission and `metadata` repository permission to use this\nendpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#list-repository-collaborators", "parameters": [ { "name": "owner", @@ -45874,7 +51668,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45886,43 +51680,37 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "affiliation", + "description": "Filter collaborators returned by their affiliation. `outside` means all outside collaborators of an organization-owned repository. `direct` means all collaborators with permissions to an organization-owned repository, regardless of organization membership status. `all` means all collaborators the authenticated user can see.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["outside", "direct", "all"], "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Get top referral paths", - "scope": "repos", - "id": "getTopPaths", - "method": "GET", - "url": "/repos/{owner}/{repo}/traffic/popular/paths", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Get the top 10 popular contents over the last 14 days.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-top-referral-paths", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "permission", + "description": "Filter collaborators by the permissions they have on the repository. If not specified, all collaborators will be returned.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, + "enum": ["pull", "triage", "push", "maintain", "admin"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45931,11 +51719,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -45946,21 +51734,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "Get top referral sources", + "name": "List commit comments", "scope": "repos", - "id": "getTopReferrers", + "id": "listCommentsForCommit", "method": "GET", - "url": "/repos/{owner}/{repo}/traffic/popular/referrers", + "url": "/repos/{owner}/{repo}/commits/{commit_sha}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Get the top 10 referrers over the last 14 days.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-top-referral-sources", + "description": "Use the `:commit_sha` to specify the commit that will have its comments listed.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#list-commit-comments", "parameters": [ { "name": "owner", @@ -45977,7 +51765,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -45987,29 +51775,10 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "Get users with access to the protected branch", - "scope": "repos", - "id": "getUsersWithAccessToProtectedBranch", - "method": "GET", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nLists the people who have push access to this branch.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-users-with-access-to-the-protected-branch", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "commit_sha", + "description": "The SHA of the commit.", "in": "PATH", "type": "string", "required": true, @@ -46021,11 +51790,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46034,11 +51803,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46047,23 +51816,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get page views", + "name": "List commit comments for a repository", "scope": "repos", - "id": "getViews", + "id": "listCommitCommentsForRepo", "method": "GET", - "url": "/repos/{owner}/{repo}/traffic/views", + "url": "/repos/{owner}/{repo}/comments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Get the total number of views and breakdown per day or week for the last 14 days. Timestamps are aligned to UTC midnight of the beginning of the day or week. Week begins on Monday.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/metrics/traffic#get-page-views", + "description": "Commit Comments use [these custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types). You can read more about the use of media types in the API [here](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/).\n\nComments are ordered by ascending ID.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#list-commit-comments-for-a-repository", "parameters": [ { "name": "owner", @@ -46080,7 +51846,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46092,12 +51858,25 @@ "deprecated": null }, { - "name": "per", - "description": "The time frame to display results for.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", "required": false, - "enum": ["", "day", "week"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -46105,23 +51884,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Get a repository webhook", + "name": "List commit statuses for a reference", "scope": "repos", - "id": "getWebhook", + "id": "listCommitStatusesForRef", "method": "GET", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}", + "url": "/repos/{owner}/{repo}/commits/{ref}/statuses", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a webhook configured in a repository. To get only the webhook `config` properties, see \"[Get a webhook configuration for a repository](/rest/reference/repos#get-a-webhook-configuration-for-a-repository).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#get-a-repository-webhook", + "description": "Users with pull access in a repository can view commit statuses for a given ref. The ref can be a SHA, a branch name, or a tag name. Statuses are returned in reverse chronological order. The first status in the list will be the latest one.\n\nThis resource is also available via a legacy route: `GET /repos/:owner/:repo/statuses/:ref`.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#list-commit-statuses-for-a-reference", "parameters": [ { "name": "owner", @@ -46138,7 +51914,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46150,10 +51926,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "ref", + "description": "ref parameter", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -46161,25 +51937,51 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { "code": 301, "description": "Moved permanently" } ], "renamed": null }, { - "name": "Get a webhook configuration for a repository", + "name": "List commits", "scope": "repos", - "id": "getWebhookConfigForRepo", + "id": "listCommits", "method": "GET", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/config", + "url": "/repos/{owner}/{repo}/commits", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns the webhook configuration for a repository. To get more information about the webhook, including the `active` state and `events`, use \"[Get a repository webhook](/rest/reference/orgs#get-a-repository-webhook).\"\n\nAccess tokens must have the `read:repo_hook` or `repo` scope, and GitHub Apps must have the `repository_hooks:read` permission.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-config#get-a-webhook-configuration-for-a-repository", + "description": "**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on their account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-commits", "parameters": [ { "name": "owner", @@ -46196,7 +51998,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46208,40 +52010,24 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "sha", + "description": "SHA or branch to start listing commits from. Default: the repository’s default branch (usually `main`).", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Get a delivery for a repository webhook", - "scope": "repos", - "id": "getWebhookDelivery", - "method": "GET", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Returns a delivery for a webhook configured in a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#get-a-delivery-for-a-repository-webhook", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "path", + "description": "Only commits containing this file path will be returned.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46250,11 +52036,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "author", + "description": "GitHub username or email address to use to filter by commit author.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46263,11 +52049,11 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "committer", + "description": "GitHub username or email address to use to filter by commit committer.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46276,48 +52062,24 @@ "deprecated": null }, { - "name": "delivery_id", - "description": "", - "in": "PATH", - "type": "integer", - "required": true, + "name": "since", + "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "List all autolinks of a repository", - "scope": "repos", - "id": "listAutolinks", - "method": "GET", - "url": "/repos/{owner}/{repo}/autolinks", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "This returns a list of autolinks configured for the given repository.\n\nInformation about autolinks are only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//v3/repos#list-autolinks", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "until", + "description": "Only commits before this date will be returned. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46326,11 +52088,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46352,20 +52114,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 404, "description": "Resource not found" }, + { "code": 409, "description": "Conflict" }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { - "name": "List branches", + "name": "List repository contributors", "scope": "repos", - "id": "listBranches", + "id": "listContributors", "method": "GET", - "url": "/repos/{owner}/{repo}/branches", + "url": "/repos/{owner}/{repo}/contributors", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-branches", + "description": "Lists contributors to the specified repository and sorts them by the number of commits per contributor in descending order. This endpoint may return information that is a few hours old because the GitHub REST API caches contributor data to improve performance.\n\nGitHub identifies contributors by author email address. This endpoint groups contribution counts by GitHub user, which includes all associated email addresses. To improve performance, only the first 500 author email addresses in the repository link to GitHub users. The rest will appear as anonymous contributors without associated GitHub user information.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-contributors", "parameters": [ { "name": "owner", @@ -46382,7 +52151,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46394,10 +52163,10 @@ "deprecated": null }, { - "name": "protected", - "description": "Setting to `true` returns only protected branches. When set to `false`, only unprotected branches are returned. Omitting this parameter returns all branches.", + "name": "anon", + "description": "Set to `1` or `true` to include anonymous contributors in results.", "in": "QUERY", - "type": "boolean", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -46434,26 +52203,28 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 200, "description": "if repository contains content" }, + { "code": 204, "description": "Response if repository is empty" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List branches for HEAD commit", + "name": "List custom deployment rule integrations available for an environment", "scope": "repos", - "id": "listBranchesForHeadCommit", + "id": "listCustomDeploymentRuleIntegrations", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{commit_sha}/branches-where-head", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/apps", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReturns all branches where the given commit SHA is the HEAD, or latest commit for the branch.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-branches-for-head-commit", + "description": "Gets all custom deployment protection rule integrations that are available for an environment. Anyone with read access to the repository can use this endpoint. If the repository is private and you want to use a personal access token (classic), you must use an access token with the `repo` scope. GitHub Apps and fine-grained personal access tokens must have the `actions:read` permission to use this endpoint.\n\nFor more information about environments, see \"[Using environments for deployment](https://docs.github.com/enterprise-cloud@latest//en/actions/deployment/targeting-different-environments/using-environments-for-deployment).\"\n\nFor more information about the app that is providing this custom deployment rule, see \"[GET an app](https://docs.github.com/enterprise-cloud@latest//rest/apps/apps#get-an-app)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/protection-rules#list-custom-deployment-rule-integrations", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -46466,7 +52237,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46478,8 +52249,8 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46489,28 +52260,53 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ - { "code": 200, "description": "Response" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 200, + "description": "A list of custom deployment rule integrations available for this environment." } ], "renamed": null }, { - "name": "List repository collaborators", + "name": "List deploy keys", "scope": "repos", - "id": "listCollaborators", + "id": "listDeployKeys", "method": "GET", - "url": "/repos/{owner}/{repo}/collaborators", + "url": "/repos/{owner}/{repo}/keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "For organization-owned repositories, the list of collaborators includes outside collaborators, organization members that are direct collaborators, organization members with access through team memberships, organization members with access through default organization permissions, and organization owners.\nOrganization members with write, maintain, or admin privileges on the organization-owned repository can use this endpoint.\n\nTeam members will include the members of child teams.\n\nYou must authenticate using an access token with the `read:org` and `repo` scopes with push access to use this\nendpoint. GitHub Apps must have the `members` organization permission and `metadata` repository permission to use this\nendpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#list-repository-collaborators", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deploy-keys#list-deploy-keys", "parameters": [ { "name": "owner", @@ -46527,7 +52323,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46538,32 +52334,6 @@ "alias": null, "deprecated": null }, - { - "name": "affiliation", - "description": "Filter collaborators returned by their affiliation. `outside` means all outside collaborators of an organization-owned repository. `direct` means all collaborators with permissions to an organization-owned repository, regardless of organization membership status. `all` means all collaborators the authenticated user can see.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["outside", "direct", "all"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "permission", - "description": "Filter collaborators by the permissions they have on the repository. If not specified, all collaborators will be returned.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["pull", "triage", "push", "maintain", "admin"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -46591,23 +52361,20 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List commit comments", + "name": "List deployment branch policies", "scope": "repos", - "id": "listCommentsForCommit", + "id": "listDeploymentBranchPolicies", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{commit_sha}/comments", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Use the `:commit_sha` to specify the commit that will have its comments listed.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#list-commit-comments", + "description": "Lists the deployment branch policies for an environment.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#list-deployment-branch-policies", "parameters": [ { "name": "owner", @@ -46624,7 +52391,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46636,8 +52403,8 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit.", + "name": "environment_name", + "description": "The name of the environment.", "in": "PATH", "type": "string", "required": true, @@ -46679,16 +52446,16 @@ "renamed": null }, { - "name": "List commit comments for a repository", + "name": "List deployment statuses", "scope": "repos", - "id": "listCommitCommentsForRepo", + "id": "listDeploymentStatuses", "method": "GET", - "url": "/repos/{owner}/{repo}/comments", + "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Commit Comments use [these custom media types](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#custom-media-types). You can read more about the use of media types in the API [here](https://docs.github.com/enterprise-cloud@latest//rest/overview/media-types/).\n\nComments are ordered by ascending ID.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#list-commit-comments-for-a-repository", + "description": "Users with pull access can view deployment statuses for a deployment:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/statuses#list-deployment-statuses", "parameters": [ { "name": "owner", @@ -46705,7 +52472,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46716,6 +52483,19 @@ "alias": null, "deprecated": null }, + { + "name": "deployment_id", + "description": "deployment_id parameter", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -46743,20 +52523,23 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List commit statuses for a reference", + "name": "List deployments", "scope": "repos", - "id": "listCommitStatusesForRef", + "id": "listDeployments", "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{ref}/statuses", + "url": "/repos/{owner}/{repo}/deployments", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with pull access in a repository can view commit statuses for a given ref. The ref can be a SHA, a branch name, or a tag name. Statuses are returned in reverse chronological order. The first status in the list will be the latest one.\n\nThis resource is also available via a legacy route: `GET /repos/:owner/:repo/statuses/:ref`.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/statuses#list-commit-statuses-for-a-reference", + "description": "Simple filtering of deployments is available via query parameters:", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/deployments#list-deployments", "parameters": [ { "name": "owner", @@ -46772,11 +52555,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sha", + "description": "The SHA recorded at creation time.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46786,10 +52582,36 @@ }, { "name": "ref", - "description": "ref parameter", - "in": "PATH", + "description": "The name of the ref. This can be a branch, tag, or SHA.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "task", + "description": "The name of the task for the deployment (e.g., `deploy` or `deploy:migrations`).", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "environment", + "description": "The name of the environment that was deployed to (e.g., `staging` or `production`).", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46824,31 +52646,28 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 301, "description": "Moved permanently" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List commits", + "name": "List repositories for the authenticated user", "scope": "repos", - "id": "listCommits", + "id": "listForAuthenticatedUser", "method": "GET", - "url": "/repos/{owner}/{repo}/commits", + "url": "/user/repos", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "**Signature verification object**\n\nThe response will include a `verification` object that describes the result of verifying the commit's signature. The following fields are included in the `verification` object:\n\n| Name | Type | Description |\n| ---- | ---- | ----------- |\n| `verified` | `boolean` | Indicates whether GitHub considers the signature in this commit to be verified. |\n| `reason` | `string` | The reason for verified value. Possible values and their meanings are enumerated in table below. |\n| `signature` | `string` | The signature that was extracted from the commit. |\n| `payload` | `string` | The value that was signed. |\n\nThese are the possible values for `reason` in the `verification` object:\n\n| Value | Description |\n| ----- | ----------- |\n| `expired_key` | The key that made the signature is expired. |\n| `not_signing_key` | The \"signing\" flag is not among the usage flags in the GPG key that made the signature. |\n| `gpgverify_error` | There was an error communicating with the signature verification service. |\n| `gpgverify_unavailable` | The signature verification service is currently unavailable. |\n| `unsigned` | The object does not include a signature. |\n| `unknown_signature_type` | A non-PGP signature was found in the commit. |\n| `no_user` | No user was associated with the `committer` email address in the commit. |\n| `unverified_email` | The `committer` email address in the commit was associated with a user, but the email address is not verified on her/his account. |\n| `bad_email` | The `committer` email address in the commit is not included in the identities of the PGP key that made the signature. |\n| `unknown_key` | The key that made the signature has not been registered with any user's account. |\n| `malformed_signature` | There was an error parsing the signature. |\n| `invalid` | The signature could not be cryptographically verified using the key whose key-id was found in the signature. |\n| `valid` | None of the above errors applied, so the signature is considered to be verified. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-commits", + "description": "Lists repositories that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repositories-for-the-authenticated-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "visibility", + "description": "Limit results to repositories with the specified visibility.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["all", "public", "private"], "allowNull": false, "mapToData": null, "validation": null, @@ -46856,11 +52675,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "affiliation", + "description": "Comma-separated list of values. Can include: \n * `owner`: Repositories that are owned by the authenticated user. \n * `collaborator`: Repositories that the user has been added to as a collaborator. \n * `organization_member`: Repositories that the user has access to through being a member of an organization. This includes every repository on every team that the user is on.", + "in": "QUERY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -46869,12 +52688,12 @@ "deprecated": null }, { - "name": "sha", - "description": "SHA or branch to start listing commits from. Default: the repository’s default branch (usually `master`).", + "name": "type", + "description": "Limit results to repositories of the specified type. Will cause a `422` error if used in the same request as **visibility** or **affiliation**.", "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["all", "owner", "public", "private", "member"], "allowNull": false, "mapToData": null, "validation": null, @@ -46882,12 +52701,12 @@ "deprecated": null }, { - "name": "path", - "description": "Only commits containing this file path will be returned.", + "name": "sort", + "description": "The property to sort the results by.", "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["created", "updated", "pushed", "full_name"], "allowNull": false, "mapToData": null, "validation": null, @@ -46895,12 +52714,12 @@ "deprecated": null }, { - "name": "author", - "description": "GitHub login or email address by which to filter by commit author.", + "name": "direction", + "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -46908,10 +52727,10 @@ "deprecated": null }, { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -46921,10 +52740,10 @@ "deprecated": null }, { - "name": "until", - "description": "Only commits before this date will be returned. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -46934,10 +52753,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "since", + "description": "Only show repositories updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -46947,10 +52766,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "before", + "description": "Only show repositories updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -46962,29 +52781,31 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 404, "description": "Resource not found" }, - { "code": 409, "description": "Conflict" }, - { "code": 500, "description": "Internal Error" } + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List repository contributors", + "name": "List organization repositories", "scope": "repos", - "id": "listContributors", + "id": "listForOrg", "method": "GET", - "url": "/repos/{owner}/{repo}/contributors", + "url": "/orgs/{org}/repos", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists contributors to the specified repository and sorts them by the number of commits per contributor in descending order. This endpoint may return information that is a few hours old because the GitHub REST API v3 caches contributor data to improve performance.\n\nGitHub identifies contributors by author email address. This endpoint groups contribution counts by GitHub user, which includes all associated email addresses. To improve performance, only the first 500 author email addresses in the repository link to GitHub users. The rest will appear as anonymous contributors without associated GitHub user information.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-contributors", + "description": "Lists repositories for the specified organization.\n\n**Note:** In order to see the `security_and_analysis` block for a repository you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-organization-repositories", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "org", + "description": "The organization name. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -46996,12 +52817,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "type", + "description": "Specifies the types of repositories you want returned. `internal` is not yet supported when a GitHub App calls this endpoint with an installation access token.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["all", "private", "forks", "sources", "member", "internal"], "allowNull": false, "mapToData": null, "validation": null, @@ -47009,12 +52830,25 @@ "deprecated": null }, { - "name": "anon", - "description": "Set to `1` or `true` to include anonymous contributors in results.", + "name": "sort", + "description": "The property to sort the results by.", "in": "QUERY", "type": "string", "required": false, - "enum": null, + "enum": ["created", "updated", "pushed", "full_name"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -47048,29 +52882,24 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "if repository contains content" }, - { "code": 204, "description": "Response if repository is empty" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List deploy keys", + "name": "List repositories for a user", "scope": "repos", - "id": "listDeployKeys", + "id": "listForUser", "method": "GET", - "url": "/repos/{owner}/{repo}/keys", + "url": "/users/{username}/repos", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-deploy-keys", + "description": "Lists public repositories for the specified user. Note: For GitHub AE, this endpoint will list internal repositories for the specified user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repositories-for-a-user", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -47082,12 +52911,38 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "type", + "description": "Limit results to repositories of the specified type.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["all", "owner", "member"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated", "pushed", "full_name"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -47125,16 +52980,16 @@ "renamed": null }, { - "name": "List deployment branch policies", + "name": "List forks", "scope": "repos", - "id": "listDeploymentBranchPolicies", + "id": "listForks", "method": "GET", - "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies", + "url": "/repos/{owner}/{repo}/forks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the deployment branch policies for an environment.\n\nAnyone with read access to the repository can use this endpoint. If the repository is private, you must use an access token with the `repo` scope. GitHub Apps must have the `actions:read` permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#list-deployment-branch-policies", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-forks", "parameters": [ { "name": "owner", @@ -47151,7 +53006,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47163,12 +53018,12 @@ "deprecated": null }, { - "name": "environment_name", - "description": "The name of the environment.", - "in": "PATH", + "name": "sort", + "description": "The sort order. `stargazers` will sort by star count.", + "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["newest", "oldest", "stargazers", "watchers"], "allowNull": false, "mapToData": null, "validation": null, @@ -47202,20 +53057,24 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" } + ], "renamed": null }, { - "name": "List deployment statuses", + "name": "List repository invitations", "scope": "repos", - "id": "listDeploymentStatuses", + "id": "listInvitations", "method": "GET", - "url": "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", + "url": "/repos/{owner}/{repo}/invitations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Users with pull access can view deployment statuses for a deployment:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-deployment-statuses", + "description": "When authenticating as a user with admin rights to a repository, this endpoint will list all currently open repository invitations.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#list-repository-invitations", "parameters": [ { "name": "owner", @@ -47232,7 +53091,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47244,11 +53103,11 @@ "deprecated": null }, { - "name": "deployment_id", - "description": "deployment_id parameter", - "in": "PATH", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", "type": "integer", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -47256,6 +53115,35 @@ "alias": null, "deprecated": null }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List repository invitations for the authenticated user", + "scope": "repos", + "id": "listInvitationsForAuthenticatedUser", + "method": "GET", + "url": "/user/repository_invitations", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "When authenticating as a user, this endpoint will list all currently open repository invitations for that user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#list-repository-invitations-for-the-authenticated-user", + "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -47285,21 +53173,24 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List deployments", + "name": "List repository languages", "scope": "repos", - "id": "listDeployments", + "id": "listLanguages", "method": "GET", - "url": "/repos/{owner}/{repo}/deployments", + "url": "/repos/{owner}/{repo}/languages", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Simple filtering of deployments is available via query parameters:", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-deployments", + "description": "Lists languages for the specified repository. The value shown for each language is the number of bytes of code written in that language.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-languages", "parameters": [ { "name": "owner", @@ -47316,7 +53207,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47326,39 +53217,29 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "sha", - "description": "The SHA recorded at creation time.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "ref", - "description": "The name of the ref. This can be a branch, tag, or SHA.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List GitHub Enterprise Cloud Pages builds", + "scope": "repos", + "id": "listPagesBuilds", + "method": "GET", + "url": "/repos/{owner}/{repo}/pages/builds", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists builts of a GitHub Enterprise Cloud Pages site.\n\nA token with the `repo` scope is required. GitHub Apps must have the `pages:read` permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#list-github-pages-builds", + "parameters": [ { - "name": "task", - "description": "The name of the task for the deployment (e.g., `deploy` or `deploy:migrations`).", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -47367,11 +53248,11 @@ "deprecated": null }, { - "name": "environment", - "description": "The name of the environment that was deployed to (e.g., `staging` or `production`).", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -47410,35 +53291,22 @@ "renamed": null }, { - "name": "List repositories for the authenticated user", + "name": "List public repositories", "scope": "repos", - "id": "listForAuthenticatedUser", + "id": "listPublic", "method": "GET", - "url": "/user/repos", + "url": "/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists repositories that the authenticated user has explicit permission (`:read`, `:write`, or `:admin`) to access.\n\nThe authenticated user has explicit permission to access repositories they own, repositories where they are a collaborator, and repositories that they can access through an organization membership.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repositories-for-the-authenticated-user", + "description": "Lists all public repositories in the order that they were created.\n\nNote:\n- For GitHub Enterprise Server, this endpoint will only list repositories available to all users on the enterprise.\n- Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers) to get the URL for the next page of repositories.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-public-repositories", "parameters": [ { - "name": "visibility", - "description": "Limit results to repositories with the specified visibility.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["all", "public", "private"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "affiliation", - "description": "Comma-separated list of values. Can include: \n\\* `owner`: Repositories that are owned by the authenticated user. \n\\* `collaborator`: Repositories that the user has been added to as a collaborator. \n\\* `organization_member`: Repositories that the user has access to through being a member of an organization. This includes every repository on every team that the user is on.", + "name": "since", + "description": "A repository ID. Only return repositories with an ID greater than this ID.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -47446,14 +53314,37 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, { - "name": "type", - "description": "Limit results to repositories of the specified type. Will cause a `422` error if used in the same request as **visibility** or **affiliation**.", - "in": "QUERY", + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "List pull requests associated with a commit", + "scope": "repos", + "id": "listPullRequestsAssociatedWithCommit", + "method": "GET", + "url": "/repos/{owner}/{repo}/commits/{commit_sha}/pulls", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the merged pull request that introduced the commit to the repository. If the commit is not present in the default branch, will only return open pull requests associated with the commit.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-pull-requests-associated-with-a-commit", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["all", "owner", "public", "private", "member"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47461,12 +53352,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated", "pushed", "full_name"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47474,12 +53365,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", - "in": "QUERY", + "name": "commit_sha", + "description": "The SHA of the commit.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47511,13 +53402,29 @@ "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List release assets", + "scope": "repos", + "id": "listReleaseAssets", + "method": "GET", + "url": "/repos/{owner}/{repo}/releases/{release_id}/assets", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-release-assets", + "parameters": [ { - "name": "since", - "description": "Only show notifications updated after the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -47526,48 +53433,23 @@ "deprecated": null }, { - "name": "before", - "description": "Only show notifications updated before the given time. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "List organization repositories", - "scope": "repos", - "id": "listForOrg", - "method": "GET", - "url": "/orgs/{org}/repos", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists repositories for the specified organization.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-organization-repositories", - "parameters": [ + }, { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -47577,33 +53459,54 @@ "deprecated": null }, { - "name": "type", - "description": "Specifies the types of repositories you want returned. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `type` can also be `internal`. However, the `internal` value is not yet supported when a GitHub App calls this API with an installation access token.", + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, - "enum": [ - "all", - "public", - "private", - "forks", - "sources", - "member", - "internal" - ], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List releases", + "scope": "repos", + "id": "listReleases", + "method": "GET", + "url": "/repos/{owner}/{repo}/releases", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This returns a list of releases, which does not include regular Git tags that have not been associated with a release. To get a list of Git tags, use the [Repository Tags API](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-tags).\n\nInformation about published releases are available to everyone. Only users with push access will receive listings for draft releases.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-releases", + "parameters": [ { - "name": "sort", - "description": "The property to sort the results by.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated", "pushed", "full_name"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47611,12 +53514,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47650,24 +53553,27 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List repositories for a user", + "name": "List tag protection states for a repository", "scope": "repos", - "id": "listForUser", + "id": "listTagProtection", "method": "GET", - "url": "/users/{username}/repos", + "url": "/repos/{owner}/{repo}/tags/protection", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists public repositories for the specified user. Note: For GitHub AE, this endpoint will list internal repositories for the specified user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repositories-for-a-user", + "description": "This returns the tag protection states of a repository.\n\nThis information is only available to repository administrators.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-tag-protection-state-of-a-repository", "parameters": [ { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47679,25 +53585,45 @@ "deprecated": null }, { - "name": "type", - "description": "Limit results to repositories of the specified type.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["all", "owner", "member"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List repository tags", + "scope": "repos", + "id": "listTags", + "method": "GET", + "url": "/repos/{owner}/{repo}/tags", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-tags", + "parameters": [ { - "name": "sort", - "description": "The property to sort the results by.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated", "pushed", "full_name"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47705,12 +53631,12 @@ "deprecated": null }, { - "name": "direction", - "description": "The order to sort by. Default: `asc` when using `full_name`, otherwise `desc`.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -47748,16 +53674,16 @@ "renamed": null }, { - "name": "List forks", + "name": "List repository teams", "scope": "repos", - "id": "listForks", + "id": "listTeams", "method": "GET", - "url": "/repos/{owner}/{repo}/forks", + "url": "/repos/{owner}/{repo}/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-forks", + "description": "Lists the teams that have access to the specified repository and that are also visible to the authenticated user.\n\nFor a public repository, a team is listed only if that team added the public repository explicitly.\n\nPersonal access tokens require the following scopes:\n* `public_repo` to call this endpoint on a public repository\n* `repo` to call this endpoint on a private repository (this scope also includes public repositories)\n\nThis endpoint is not compatible with fine-grained personal access tokens.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-teams", "parameters": [ { "name": "owner", @@ -47774,7 +53700,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47785,19 +53711,6 @@ "alias": null, "deprecated": null }, - { - "name": "sort", - "description": "The sort order. `stargazers` will sort by star count.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["newest", "oldest", "stargazers", "watchers"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -47827,22 +53740,21 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" } + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List repository invitations", + "name": "List deliveries for a repository webhook", "scope": "repos", - "id": "listInvitations", + "id": "listWebhookDeliveries", "method": "GET", - "url": "/repos/{owner}/{repo}/invitations", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "When authenticating as a user with admin rights to a repository, this endpoint will list all currently open repository invitations.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#list-repository-invitations", + "description": "Returns a list of webhook deliveries for a webhook configured in a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#list-deliveries-for-a-repository-webhook", "parameters": [ { "name": "owner", @@ -47859,7 +53771,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47871,11 +53783,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -47884,8 +53796,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -47895,28 +53807,12 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List repository invitations for the authenticated user", - "scope": "repos", - "id": "listInvitationsForAuthenticatedUser", - "method": "GET", - "url": "/user/repository_invitations", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "When authenticating as a user, this endpoint will list all currently open repository invitations for that user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#list-repository-invitations-for-the-authenticated-user", - "parameters": [ + }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "cursor", + "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -47926,10 +53822,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "redelivery", + "description": "", "in": "QUERY", - "type": "integer", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -47941,24 +53837,26 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List repository languages", + "name": "List repository webhooks", "scope": "repos", - "id": "listLanguages", + "id": "listWebhooks", "method": "GET", - "url": "/repos/{owner}/{repo}/languages", + "url": "/repos/{owner}/{repo}/hooks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists languages for the specified repository. The value shown for each language is the number of bytes of code written in that language.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-languages", + "description": "Lists webhooks for a repository. `last response` may return null if there have not been any deliveries within 30 days.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#list-repository-webhooks", "parameters": [ { "name": "owner", @@ -47975,7 +53873,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -47985,22 +53883,51 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List GitHub Enterprise Cloud Pages builds", + "name": "Merge a branch", "scope": "repos", - "id": "listPagesBuilds", - "method": "GET", - "url": "/repos/{owner}/{repo}/pages/builds", + "id": "merge", + "method": "POST", + "url": "/repos/{owner}/{repo}/merges", "isDeprecated": false, "deprecationDate": null, "removalDate": null, "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#list-github-pages-builds", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branches#merge-a-branch", "parameters": [ { "name": "owner", @@ -48017,7 +53944,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48029,11 +53956,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "base", + "description": "The name of the base branch that the head will be merged into.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48042,39 +53969,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "head", + "description": "The head to merge. This can be a branch name or a commit SHA1.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "List public repositories", - "scope": "repos", - "id": "listPublic", - "method": "GET", - "url": "/repositories", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists all public repositories in the order that they were created.\n\nNote:\n- For GitHub Enterprise Server, this endpoint will only list repositories available to all users on the enterprise.\n- Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header) to get the URL for the next page of repositories.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-public-repositories", - "parameters": [ + }, { - "name": "since", - "description": "A repository ID. Only return repositories with an ID greater than this ID.", - "in": "QUERY", - "type": "integer", + "name": "commit_message", + "description": "Commit message to use for the merge commit. If omitted, a default message will be used.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -48085,8 +53996,17 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, + { + "code": 201, + "description": "Successful Response (The resulting merge commit)" + }, + { "code": 204, "description": "Response when already merged" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 404, + "description": "Not Found when the base or head does not exist" + }, + { "code": 409, "description": "Conflict when there is a merge conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -48095,16 +54015,16 @@ "renamed": null }, { - "name": "List pull requests associated with a commit", + "name": "Sync a fork branch with the upstream repository", "scope": "repos", - "id": "listPullRequestsAssociatedWithCommit", - "method": "GET", - "url": "/repos/{owner}/{repo}/commits/{commit_sha}/pulls", + "id": "mergeUpstream", + "method": "POST", + "url": "/repos/{owner}/{repo}/merge-upstream", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the merged pull request that introduced the commit to the repository. If the commit is not present in the default branch, additionally returns open pull requests associated with the commit. The results may include open and closed pull requests.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/commits#list-pull-requests-associated-with-a-commit", + "description": "Sync a branch of a forked repository to keep it up-to-date with the upstream repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branches#sync-a-fork-branch-with-the-upstream-repository", "parameters": [ { "name": "owner", @@ -48121,7 +54041,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48133,8 +54053,50 @@ "deprecated": null }, { - "name": "commit_sha", - "description": "The SHA of the commit.", + "name": "branch", + "description": "The name of the branch which should be updated to match upstream.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { + "code": 200, + "description": "The branch has been successfully synced with the upstream repository" + }, + { + "code": 409, + "description": "The branch could not be synced because of a merge conflict" + }, + { + "code": 422, + "description": "The branch could not be synced for some other reason" + } + ], + "renamed": null + }, + { + "name": "Ping a repository webhook", + "scope": "repos", + "id": "pingWebhook", + "method": "POST", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/pings", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "This will trigger a [ping event](https://docs.github.com/enterprise-cloud@latest//webhooks/#ping-event) to be sent to the hook.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#ping-a-repository-webhook", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48146,11 +54108,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48159,11 +54121,11 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", + "name": "hook_id", + "description": "The unique identifier of the hook.", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48172,20 +54134,23 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List release assets", + "name": "Redeliver a delivery for a repository webhook", "scope": "repos", - "id": "listReleaseAssets", - "method": "GET", - "url": "/repos/{owner}/{repo}/releases/{release_id}/assets", + "id": "redeliverWebhookDelivery", + "method": "POST", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}/attempts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-release-assets", + "description": "Redeliver a webhook delivery for a webhook configured in a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#redeliver-a-delivery-for-a-repository-webhook", "parameters": [ { "name": "owner", @@ -48202,7 +54167,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48214,8 +54179,8 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", "type": "integer", "required": true, @@ -48227,46 +54192,41 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", + "name": "delivery_id", + "description": "", + "in": "PATH", "type": "integer", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 202, "description": "Accepted" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List releases", + "name": "Remove app access restrictions", "scope": "repos", - "id": "listReleases", - "method": "GET", - "url": "/repos/{owner}/{repo}/releases", + "id": "removeAppAccessRestrictions", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This returns a list of releases, which does not include regular Git tags that have not been associated with a release. To get a list of Git tags, use the [Repository Tags API](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-tags).\n\nInformation about published releases are available to everyone. Only users with push access will receive listings for draft releases.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-releases", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of an app to push to this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#remove-app-access-restrictions", "parameters": [ { "name": "owner", @@ -48283,7 +54243,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48295,11 +54255,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48308,14 +54268,14 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "apps", + "description": "", + "in": "BODY", + "type": null, + "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null @@ -48323,21 +54283,24 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List tag protection states for a repository", + "name": "Remove a repository collaborator", "scope": "repos", - "id": "listTagProtection", - "method": "GET", - "url": "/repos/{owner}/{repo}/tags/protection", + "id": "removeCollaborator", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/collaborators/{username}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This returns the tag protection states of a repository.\n\nThis information is only available to repository administrators.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-tag-protection-state-of-a-repository", + "description": "Removes a collaborator from a repository.\n\nTo use this endpoint, the authenticated user must either be an administrator of the repository or target themselves for removal.\n\nThis endpoint also:\n- Cancels any outstanding invitations\n- Unasigns the user from any issues\n- Removes access to organization projects if the user is not an organization member and is not a collaborator on any other organization repositories.\n- Unstars the repository\n- Updates access permissions to packages\n\nRemoving a user as a collaborator has the following effects on forks:\n - If the user had access to a fork through their membership to this repository, the user will also be removed from the fork.\n - If the user had their own fork of the repository, the fork will be deleted.\n - If the user still has read access to the repository, open pull requests by this user from a fork will be denied.\n\n**Note**: A user can still have access to the repository through organization permissions like base repository permissions.\n\nAlthough the API responds immediately, the additional permission updates might take some extra time to complete in the background.\n\nFor more information on fork permissions, see \"[About permissions and visibility of forks](https://docs.github.com/enterprise-cloud@latest//pull-requests/collaborating-with-pull-requests/working-with-forks/about-permissions-and-visibility-of-forks)\".", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#remove-a-repository-collaborator", "parameters": [ { "name": "owner", @@ -48354,7 +54317,20 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "username", + "description": "The handle for the GitHub user account.", "in": "PATH", "type": "string", "required": true, @@ -48367,23 +54343,29 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { + "code": 204, + "description": "No Content when collaborator was removed from the repository." + }, { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List repository tags", + "name": "Remove status check contexts", "scope": "repos", - "id": "listTags", - "method": "GET", - "url": "/repos/{owner}/{repo}/tags", + "id": "removeStatusCheckContexts", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-tags", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#remove-status-check-contexts", "parameters": [ { "name": "owner", @@ -48400,7 +54382,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48412,11 +54394,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48425,33 +54407,40 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "contexts", + "description": "", + "in": "BODY", + "type": null, + "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], "renamed": null }, { - "name": "List repository teams", + "name": "Remove status check protection", "scope": "repos", - "id": "listTeams", - "method": "GET", - "url": "/repos/{owner}/{repo}/teams", + "id": "removeStatusCheckProtection", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-repository-teams", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#remove-status-check-protection", "parameters": [ { "name": "owner", @@ -48468,7 +54457,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48480,24 +54469,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48506,20 +54482,20 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "List deliveries for a repository webhook", + "name": "Remove team access restrictions", "scope": "repos", - "id": "listWebhookDeliveries", - "method": "GET", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries", + "id": "removeTeamAccessRestrictions", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Returns a list of webhook deliveries for a webhook configured in a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#list-deliveries-for-a-repository-webhook", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of a team to push to this branch. You can also remove push access for child teams.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#remove-team-access-restrictions", "parameters": [ { "name": "owner", @@ -48536,7 +54512,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48548,10 +54524,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -48561,27 +54537,14 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "cursor", - "description": "Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.", - "in": "QUERY", - "type": "string", - "required": false, + "name": "teams", + "description": "", + "in": "BODY", + "type": null, + "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null @@ -48589,8 +54552,6 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -48599,16 +54560,16 @@ "renamed": null }, { - "name": "List repository webhooks", + "name": "Remove user access restrictions", "scope": "repos", - "id": "listWebhooks", - "method": "GET", - "url": "/repos/{owner}/{repo}/hooks", + "id": "removeUserAccessRestrictions", + "method": "DELETE", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists webhooks for a repository. `last response` may return null if there have not been any deliveries within 30 days.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#list-repository-webhooks", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of a user to push to this branch.\n\n| Type | Description |\n| ------- | --------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames of the people who should no longer have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#remove-user-access-restrictions", "parameters": [ { "name": "owner", @@ -48625,7 +54586,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48637,11 +54598,11 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -48650,14 +54611,14 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "users", + "description": "", + "in": "BODY", + "type": null, + "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null @@ -48665,21 +54626,24 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Merge a branch", + "name": "Rename a branch", "scope": "repos", - "id": "merge", + "id": "renameBranch", "method": "POST", - "url": "/repos/{owner}/{repo}/merges", + "url": "/repos/{owner}/{repo}/branches/{branch}/rename", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#merge-a-branch", + "description": "Renames a branch in a repository.\n\n**Note:** Although the API responds immediately, the branch rename process might take some extra time to complete in the background. You won't be able to push to the old branch name while the rename process is in progress. For more information, see \"[Renaming a branch](https://docs.github.com/enterprise-cloud@latest//github/administering-a-repository/renaming-a-branch)\".\n\nThe permissions required to use this endpoint depends on whether you are renaming the default branch.\n\nTo rename a non-default branch:\n\n* Users must have push access.\n* GitHub Apps must have the `contents:write` repository permission.\n\nTo rename the default branch:\n\n* Users must have admin or owner permissions.\n* GitHub Apps must have the `administration:write` repository permission.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branches#rename-a-branch", "parameters": [ { "name": "owner", @@ -48696,7 +54660,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48708,9 +54672,9 @@ "deprecated": null }, { - "name": "base", - "description": "The name of the base branch that the head will be merged into.", - "in": "BODY", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -48721,8 +54685,8 @@ "deprecated": null }, { - "name": "head", - "description": "The head to merge. This can be a branch name or a commit SHA1.", + "name": "new_name", + "description": "The new name of the branch.", "in": "BODY", "type": "string", "required": true, @@ -48732,33 +54696,12 @@ "validation": null, "alias": null, "deprecated": null - }, - { - "name": "commit_message", - "description": "Commit message to use for the merge commit. If omitted, a default message will be used.", - "in": "BODY", - "type": "string", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null } ], "responses": [ - { - "code": 201, - "description": "Successful Response (The resulting merge commit)" - }, - { "code": 204, "description": "Response when already merged" }, + { "code": 201, "description": "Response" }, { "code": 403, "description": "Forbidden" }, - { - "code": 404, - "description": "Not Found when the base or head does not exist" - }, - { "code": 409, "description": "Conflict when there is a merge conflict" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -48767,16 +54710,16 @@ "renamed": null }, { - "name": "Sync a fork branch with the upstream repository", + "name": "Replace all repository topics", "scope": "repos", - "id": "mergeUpstream", - "method": "POST", - "url": "/repos/{owner}/{repo}/merge-upstream", + "id": "replaceAllTopics", + "method": "PUT", + "url": "/repos/{owner}/{repo}/topics", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Sync a branch of a forked repository to keep it up-to-date with the upstream repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#sync-a-fork-branch-with-the-upstream-repository", + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#replace-all-repository-topics", "parameters": [ { "name": "owner", @@ -48793,7 +54736,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48805,10 +54748,10 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch which should be updated to match upstream.", + "name": "names", + "description": "An array of topics to add to the repository. Pass one or more topics to _replace_ the set of existing topics. Send an empty array (`[]`) to clear all topics from the repository. **Note:** Topic `names` cannot contain uppercase letters.", "in": "BODY", - "type": "string", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -48819,32 +54762,68 @@ } ], "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { - "code": 200, - "description": "The branch has been successfully synced with the upstream repository" - }, + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Request a GitHub Enterprise Cloud Pages build", + "scope": "repos", + "id": "requestPagesBuild", + "method": "POST", + "url": "/repos/{owner}/{repo}/pages/builds", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "You can request that your site be built from the latest revision on the default branch. This has the same effect as pushing a commit to your default branch, but does not require an additional commit. Manually triggering page builds can be helpful when diagnosing build warnings and failures.\n\nBuild requests are limited to one concurrent build per repository and one concurrent build per requester. If you request a build while another is still in progress, the second request will be queued until the first completes.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#request-a-github-pages-build", + "parameters": [ { - "code": 409, - "description": "The branch could not be synced because of a merge conflict" + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "code": 422, - "description": "The branch could not be synced for some other reason" + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 201, "description": "Response" }], "renamed": null }, { - "name": "Ping a repository webhook", + "name": "Set admin branch protection", "scope": "repos", - "id": "pingWebhook", + "id": "setAdminBranchProtection", "method": "POST", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/pings", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This will trigger a [ping event](https://docs.github.com/enterprise-cloud@latest//webhooks/#ping-event) to be sent to the hook.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#ping-a-repository-webhook", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nAdding admin enforcement requires admin or owner permissions to the repository and branch protection to be enabled.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#set-admin-branch-protection", "parameters": [ { "name": "owner", @@ -48861,7 +54840,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48873,10 +54852,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -48886,23 +54865,20 @@ "deprecated": null } ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "Redeliver a delivery for a repository webhook", + "name": "Set app access restrictions", "scope": "repos", - "id": "redeliverWebhookDelivery", - "method": "POST", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}/attempts", + "id": "setAppAccessRestrictions", + "method": "PUT", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Redeliver a webhook delivery for a webhook configured in a repository.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repo-deliveries#redeliver-a-delivery-for-a-repository-webhook", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of apps that have push access to this branch. This removes all apps that previously had push access and grants push access to the new list of apps. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#set-app-access-restrictions", "parameters": [ { "name": "owner", @@ -48919,7 +54895,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -48931,10 +54907,10 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -48944,23 +54920,21 @@ "deprecated": null }, { - "name": "delivery_id", + "name": "apps", "description": "", - "in": "PATH", - "type": "integer", + "in": "BODY", + "type": null, "required": true, "enum": null, "allowNull": false, - "mapToData": null, + "mapToData": true, "validation": null, "alias": null, "deprecated": null } ], "responses": [ - { "code": 202, "description": "Accepted" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, + { "code": 200, "description": "Response" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -48969,16 +54943,16 @@ "renamed": null }, { - "name": "Remove app access restrictions", + "name": "Set status check contexts", "scope": "repos", - "id": "removeAppAccessRestrictions", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", + "id": "setStatusCheckContexts", + "method": "PUT", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of an app to push to this branch. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.\n\n| Type | Description |\n| ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | The GitHub Apps that have push access to this branch. Use the app's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#remove-app-access-restrictions", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#set-status-check-contexts", "parameters": [ { "name": "owner", @@ -48995,7 +54969,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49008,7 +54982,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -49020,7 +54994,7 @@ "deprecated": null }, { - "name": "apps", + "name": "contexts", "description": "", "in": "BODY", "type": null, @@ -49035,6 +55009,7 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -49043,16 +55018,16 @@ "renamed": null }, { - "name": "Remove a repository collaborator", + "name": "Set team access restrictions", "scope": "repos", - "id": "removeCollaborator", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/collaborators/{username}", + "id": "setTeamAccessRestrictions", + "method": "PUT", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/collaborators#remove-a-repository-collaborator", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of teams that have push access to this branch. This removes all teams that previously had push access and grants push access to the new list of teams. Team restrictions include child teams.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#set-team-access-restrictions", "parameters": [ { "name": "owner", @@ -49069,7 +55044,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49081,8 +55056,8 @@ "deprecated": null }, { - "name": "username", - "description": "The handle for the GitHub user account.", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -49092,22 +55067,41 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "teams", + "description": "", + "in": "BODY", + "type": null, + "required": true, + "enum": null, + "allowNull": false, + "mapToData": true, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." } ], - "responses": [{ "code": 204, "description": "Response" }], "renamed": null }, { - "name": "Remove status check contexts", + "name": "Set user access restrictions", "scope": "repos", - "id": "removeStatusCheckContexts", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", + "id": "setUserAccessRestrictions", + "method": "PUT", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#remove-status-check-contexts", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of people that have push access to this branch. This removes all people that previously had push access and grants push access to the new list of people.\n\n| Type | Description |\n| ------- | ----------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames for people who can have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#set-user-access-restrictions", "parameters": [ { "name": "owner", @@ -49124,7 +55118,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49137,7 +55131,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -49149,7 +55143,7 @@ "deprecated": null }, { - "name": "contexts", + "name": "users", "description": "", "in": "BODY", "type": null, @@ -49164,7 +55158,6 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -49173,16 +55166,16 @@ "renamed": null }, { - "name": "Remove status check protection", + "name": "Test the push repository webhook", "scope": "repos", - "id": "removeStatusCheckProtection", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", + "id": "testPushWebhook", + "method": "POST", + "url": "/repos/{owner}/{repo}/hooks/{hook_id}/tests", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#remove-status-check-protection", + "description": "This will trigger the hook with the latest push to the current repository if the hook is subscribed to `push` events. If the hook is not subscribed to `push` events, the server will respond with 204 but no test POST will be generated.\n\n**Note**: Previously `/repos/:owner/:repo/hooks/:hook_id/test`", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#test-the-push-repository-webhook", "parameters": [ { "name": "owner", @@ -49199,7 +55192,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49211,10 +55204,10 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "hook_id", + "description": "The unique identifier of the hook.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -49224,20 +55217,23 @@ "deprecated": null } ], - "responses": [{ "code": 204, "description": "Response" }], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "Remove team access restrictions", + "name": "Transfer a repository", "scope": "repos", - "id": "removeTeamAccessRestrictions", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", + "id": "transfer", + "method": "POST", + "url": "/repos/{owner}/{repo}/transfer", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of a team to push to this branch. You can also remove push access for child teams.\n\n| Type | Description |\n| ------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Teams that should no longer have push access. Use the team's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#remove-team-access-restrictions", + "description": "A transfer request will need to be accepted by the new owner when transferring a personal repository to another user. The response will contain the original `owner`, and the transfer will continue asynchronously. For more details on the requirements to transfer personal and organization-owned repositories, see [about repository transfers](https://docs.github.com/enterprise-cloud@latest//articles/about-repository-transfers/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#transfer-a-repository", "parameters": [ { "name": "owner", @@ -49254,7 +55250,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49266,9 +55262,9 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "new_owner", + "description": "The username or organization name the repository will be transferred to.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -49279,39 +55275,46 @@ "deprecated": null }, { - "name": "teams", - "description": "", + "name": "new_name", + "description": "The new name to be given to the repository.", "in": "BODY", - "type": null, - "required": true, + "type": "string", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, + }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "name": "team_ids", + "description": "ID of the team or teams to add to the repository. Teams can only be added to organization-owned repositories.", + "in": "BODY", + "type": "integer[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], + "responses": [{ "code": 202, "description": "Response" }], "renamed": null }, { - "name": "Remove user access restrictions", + "name": "Update a repository", "scope": "repos", - "id": "removeUserAccessRestrictions", - "method": "DELETE", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", + "id": "update", + "method": "PATCH", + "url": "/repos/{owner}/{repo}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nRemoves the ability of a user to push to this branch.\n\n| Type | Description |\n| ------- | --------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames of the people who should no longer have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#remove-user-access-restrictions", + "description": "**Note**: To edit a repository's topics, use the [Replace all repository topics](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#replace-all-repository-topics) endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/repos#update-a-repository", "parameters": [ { "name": "owner", @@ -49327,12 +55330,77 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "description", + "description": "A short description of the repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "homepage", + "description": "A URL with more information about the repository.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "private", + "description": "Either `true` to make the repository private or `false` to make it public. Default: `false`. \n**Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://docs.github.com/enterprise-cloud@latest//articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private.", + "in": "BODY", + "type": "boolean", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "visibility", + "description": "The visibility of the repository.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["public", "private", "internal"], "allowNull": false, "mapToData": null, "validation": null, @@ -49340,59 +55408,37 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "security_and_analysis", + "description": "Specify which security and analysis features to enable or disable for the repository.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nFor example, to enable GitHub Advanced Security, use this data in the body of the `PATCH` request:\n`{ \"security_and_analysis\": {\"advanced_security\": { \"status\": \"enabled\" } } }`.\n\nYou can check which security and analysis features are currently enabled by using a `GET /repos/{owner}/{repo}` request.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "users", - "description": "", + "name": "security_and_analysis.advanced_security", + "description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\"", "in": "BODY", - "type": null, - "required": true, + "type": "object", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Rename a branch", - "scope": "repos", - "id": "renameBranch", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/rename", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Renames a branch in a repository.\n\n**Note:** Although the API responds immediately, the branch rename process might take some extra time to complete in the background. You won't be able to push to the old branch name while the rename process is in progress. For more information, see \"[Renaming a branch](https://docs.github.com/enterprise-cloud@latest//github/administering-a-repository/renaming-a-branch)\".\n\nThe permissions required to use this endpoint depends on whether you are renaming the default branch.\n\nTo rename a non-default branch:\n\n* Users must have push access.\n* GitHub Apps must have the `contents:write` repository permission.\n\nTo rename the default branch:\n\n* Users must have admin or owner permissions.\n* GitHub Apps must have the `administration:write` repository permission.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#rename-a-branch", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "security_and_analysis.advanced_security.status", + "description": "Can be `enabled` or `disabled`.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49401,11 +55447,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "security_and_analysis.secret_scanning", + "description": "Use the `status` property to enable or disable secret scanning for this repository. For more information, see \"[About secret scanning](/code-security/secret-security/about-secret-scanning).\"", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49414,11 +55460,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "security_and_analysis.secret_scanning.status", + "description": "Can be `enabled` or `disabled`.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49427,48 +55473,24 @@ "deprecated": null }, { - "name": "new_name", - "description": "The new name of the branch.", + "name": "security_and_analysis.secret_scanning_push_protection", + "description": "Use the `status` property to enable or disable secret scanning push protection for this repository. For more information, see \"[Protecting pushes with secret scanning](/code-security/secret-scanning/protecting-pushes-with-secret-scanning).\"", "in": "BODY", - "type": "string", - "required": true, + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 201, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Replace all repository topics", - "scope": "repos", - "id": "replaceAllTopics", - "method": "PUT", - "url": "/repos/{owner}/{repo}/topics", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#replace-all-repository-topics", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "security_and_analysis.secret_scanning_push_protection.status", + "description": "Can be `enabled` or `disabled`.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49477,11 +55499,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "has_issues", + "description": "Either `true` to enable issues for this repository or `false` to disable them.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49490,47 +55512,24 @@ "deprecated": null }, { - "name": "names", - "description": "An array of topics to add to the repository. Pass one or more topics to _replace_ the set of existing topics. Send an empty array (`[]`) to clear all topics from the repository. **Note:** Topic `names` cannot contain uppercase letters.", + "name": "has_projects", + "description": "Either `true` to enable projects for this repository or `false` to disable them. **Note:** If you're creating a repository in an organization that has disabled repository projects, the default is `false`, and if you pass `true`, the API returns an error.", "in": "BODY", - "type": "string[]", - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Request a GitHub Enterprise Cloud Pages build", - "scope": "repos", - "id": "requestPagesBuild", - "method": "POST", - "url": "/repos/{owner}/{repo}/pages/builds", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "You can request that your site be built from the latest revision on the default branch. This has the same effect as pushing a commit to your default branch, but does not require an additional commit. Manually triggering page builds can be helpful when diagnosing build warnings and failures.\n\nBuild requests are limited to one concurrent build per repository and one concurrent build per requester. If you request a build while another is still in progress, the second request will be queued until the first completes.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#request-a-github-pages-build", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "has_wiki", + "description": "Either `true` to enable the wiki for this repository or `false` to disable it.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49539,40 +55538,24 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "is_template", + "description": "Either `true` to make this repo available as a template repository or `false` to prevent it.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 201, "description": "Response" }], - "renamed": null - }, - { - "name": "Set admin branch protection", - "scope": "repos", - "id": "setAdminBranchProtection", - "method": "POST", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nAdding admin enforcement requires admin or owner permissions to the repository and branch protection to be enabled.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#set-admin-branch-protection", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "default_branch", + "description": "Updates the default branch for this repository.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49581,11 +55564,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_squash_merge", + "description": "Either `true` to allow squash-merging pull requests, or `false` to prevent squash-merging.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49594,40 +55577,24 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_merge_commit", + "description": "Either `true` to allow merging pull requests with a merge commit, or `false` to prevent merging pull requests with merge commits.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Set app access restrictions", - "scope": "repos", - "id": "setAppAccessRestrictions", - "method": "PUT", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/apps", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of apps that have push access to this branch. This removes all apps that previously had push access and grants push access to the new list of apps. Only installed GitHub Apps with `write` access to the `contents` permission can be added as authorized actors on a protected branch.\n\n| Type | Description |\n| ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `array` | The GitHub Apps that have push access to this branch. Use the app's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#set-app-access-restrictions", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_rebase_merge", + "description": "Either `true` to allow rebase-merging pull requests, or `false` to prevent rebase-merging.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49636,11 +55603,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_auto_merge", + "description": "Either `true` to allow auto-merge on pull requests, or `false` to disallow auto-merge.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49649,11 +55616,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "delete_branch_on_merge", + "description": "Either `true` to allow automatically deleting head branches when pull requests are merged, or `false` to prevent automatic deletion.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49662,46 +55629,24 @@ "deprecated": null }, { - "name": "apps", - "description": "", + "name": "allow_update_branch", + "description": "Either `true` to always allow a pull request head branch that is behind its base branch to be updated even if it is not required to be up to date before merging, or false otherwise.", "in": "BODY", - "type": null, - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Set status check contexts", - "scope": "repos", - "id": "setStatusCheckContexts", - "method": "PUT", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks/contexts", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#set-status-check-contexts", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "use_squash_pr_title_as_default", + "description": "Either `true` to allow squash-merge commits to use pull request title, or `false` to use commit message. **This property has been deprecated. Please use `squash_merge_commit_title` instead.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49710,12 +55655,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "squash_merge_commit_title", + "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], "allowNull": false, "mapToData": null, "validation": null, @@ -49723,12 +55668,12 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "squash_merge_commit_message", + "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], "allowNull": false, "mapToData": null, "validation": null, @@ -49736,48 +55681,25 @@ "deprecated": null }, { - "name": "contexts", - "description": "", + "name": "merge_commit_title", + "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", "in": "BODY", - "type": null, - "required": true, - "enum": null, + "type": "string", + "required": false, + "enum": ["PR_TITLE", "MERGE_MESSAGE"], "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Set team access restrictions", - "scope": "repos", - "id": "setTeamAccessRestrictions", - "method": "PUT", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/teams", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of teams that have push access to this branch. This removes all teams that previously had push access and grants push access to the new list of teams. Team restrictions include child teams.\n\n| Type | Description |\n| ------- | ------------------------------------------------------------------------------------------------------------------------------------------ |\n| `array` | The teams that can have push access. Use the team's `slug`. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#set-team-access-restrictions", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "merge_commit_message", + "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["PR_BODY", "PR_TITLE", "BLANK"], "allowNull": false, "mapToData": null, "validation": null, @@ -49785,11 +55707,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "archived", + "description": "Whether to archive this repository. `false` will unarchive a previously archived repository.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49798,11 +55720,11 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", - "type": "string", - "required": true, + "name": "allow_forking", + "description": "Either `true` to allow private forks, or `false` to prevent private forks.", + "in": "BODY", + "type": "boolean", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -49811,14 +55733,14 @@ "deprecated": null }, { - "name": "teams", - "description": "", + "name": "web_commit_signoff_required", + "description": "Either `true` to require contributors to sign off on web-based commits, or `false` to not require contributors to sign off on web-based commits.", "in": "BODY", - "type": null, - "required": true, + "type": "boolean", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null @@ -49826,6 +55748,9 @@ ], "responses": [ { "code": 200, "description": "Response" }, + { "code": 307, "description": "Temporary Redirect" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -49834,16 +55759,16 @@ "renamed": null }, { - "name": "Set user access restrictions", + "name": "Update branch protection", "scope": "repos", - "id": "setUserAccessRestrictions", + "id": "updateBranchProtection", "method": "PUT", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/restrictions/users", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nReplaces the list of people that have push access to this branch. This removes all people that previously had push access and grants push access to the new list of people.\n\n| Type | Description |\n| ------- | ----------------------------------------------------------------------------------------------------------------------------- |\n| `array` | Usernames for people who can have push access. **Note**: The list of users, apps, and teams in total is limited to 100 items. |", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#set-user-access-restrictions", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nProtecting a branch requires admin or owner permissions to the repository.\n\n**Note**: Passing new arrays of `users` and `teams` replaces their previous values.\n\n**Note**: The list of users, apps, and teams in total is limited to 100 items.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#update-branch-protection", "parameters": [ { "name": "owner", @@ -49860,7 +55785,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -49873,7 +55798,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -49885,45 +55810,23 @@ "deprecated": null }, { - "name": "users", - "description": "", + "name": "required_status_checks", + "description": "Require status checks to pass before merging. Set to `null` to disable.", "in": "BODY", - "type": null, + "type": "object", "required": true, "enum": null, - "allowNull": false, - "mapToData": true, + "allowNull": true, + "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Test the push repository webhook", - "scope": "repos", - "id": "testPushWebhook", - "method": "POST", - "url": "/repos/{owner}/{repo}/hooks/{hook_id}/tests", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "This will trigger the hook with the latest push to the current repository if the hook is subscribed to `push` events. If the hook is not subscribed to `push` events, the server will respond with 204 but no test POST will be generated.\n\n**Note**: Previously `/repos/:owner/:repo/hooks/:hook_id/test`", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/webhooks/repos#test-the-push-repository-webhook", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "required_status_checks.strict", + "description": "Require branches to be up to date before merging.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -49933,10 +55836,10 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "required_status_checks.contexts", + "description": "**Deprecated**: The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.\n", + "in": "BODY", + "type": "string[]", "required": true, "enum": null, "allowNull": false, @@ -49946,41 +55849,22 @@ "deprecated": null }, { - "name": "hook_id", - "description": "The unique identifier of the hook.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "required_status_checks.checks", + "description": "The list of status checks to require in order to merge into this branch.", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 204, "description": "Response" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": null - }, - { - "name": "Transfer a repository", - "scope": "repos", - "id": "transfer", - "method": "POST", - "url": "/repos/{owner}/{repo}/transfer", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "A transfer request will need to be accepted by the new owner when transferring a personal repository to another user. The response will contain the original `owner`, and the transfer will continue asynchronously. For more details on the requirements to transfer personal and organization-owned repositories, see [about repository transfers](https://docs.github.com/articles/about-repository-transfers/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#transfer-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "required_status_checks.checks[].context", + "description": "The name of the required check", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -49991,36 +55875,49 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "required_status_checks.checks[].app_id", + "description": "The ID of the GitHub App that must provide this check. Omit this field to automatically select the GitHub App that has recently provided this check, or any app if it was not set by a GitHub App. Pass -1 to explicitly allow any app to set the status.", + "in": "BODY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "enforce_admins", + "description": "Enforce all configured restrictions for administrators. Set to `true` to enforce required status checks for repository administrators. Set to `null` to disable.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "new_owner", - "description": "The username or organization name the repository will be transferred to.", + "name": "required_pull_request_reviews", + "description": "Require at least one approving review on a pull request, before merging. Set to `null` to disable.", "in": "BODY", - "type": "string", + "type": "object", "required": true, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "team_ids", - "description": "ID of the team or teams to add to the repository. Teams can only be added to organization-owned repositories.", + "name": "required_pull_request_reviews.dismissal_restrictions", + "description": "Specify which users, teams, and apps can dismiss pull request reviews. Pass an empty `dismissal_restrictions` object to disable. User and team `dismissal_restrictions` are only available for organization-owned repositories. Omit this parameter for personal repositories.", "in": "BODY", - "type": "integer[]", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -50028,29 +55925,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 202, "description": "Response" }], - "renamed": null - }, - { - "name": "Update a repository", - "scope": "repos", - "id": "update", - "method": "PATCH", - "url": "/repos/{owner}/{repo}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "**Note**: To edit a repository's topics, use the [Replace all repository topics](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#replace-all-repository-topics) endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos/#update-a-repository", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "required_pull_request_reviews.dismissal_restrictions.users", + "description": "The list of user `login`s with dismissal access", + "in": "BODY", + "type": "string[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50059,11 +55940,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "required_pull_request_reviews.dismissal_restrictions.teams", + "description": "The list of team `slug`s with dismissal access", + "in": "BODY", + "type": "string[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50072,10 +55953,10 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the repository.", + "name": "required_pull_request_reviews.dismissal_restrictions.apps", + "description": "The list of app `slug`s with dismissal access", "in": "BODY", - "type": "string", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50085,10 +55966,10 @@ "deprecated": null }, { - "name": "description", - "description": "A short description of the repository.", + "name": "required_pull_request_reviews.dismiss_stale_reviews", + "description": "Set to `true` if you want to automatically dismiss approving reviews when someone pushes a new commit.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -50098,10 +55979,10 @@ "deprecated": null }, { - "name": "homepage", - "description": "A URL with more information about the repository.", + "name": "required_pull_request_reviews.require_code_owner_reviews", + "description": "Blocks merging pull requests until [code owners](https://docs.github.com/enterprise-cloud@latest//articles/about-code-owners/) review them.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -50111,10 +55992,10 @@ "deprecated": null }, { - "name": "private", - "description": "Either `true` to make the repository private or `false` to make it public. Default: `false`. \n**Note**: You will get a `422` error if the organization restricts [changing repository visibility](https://docs.github.com/articles/repository-permission-levels-for-an-organization#changing-the-visibility-of-repositories) to organization owners and a non-owner tries to change the value of private.", + "name": "required_pull_request_reviews.required_approving_review_count", + "description": "Specify the number of reviewers required to approve pull requests. Use a number between 1 and 6 or 0 to not require reviewers.", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -50124,12 +56005,12 @@ "deprecated": null }, { - "name": "visibility", - "description": "Can be `public` or `private`. If your organization is associated with an enterprise account using GitHub Enterprise Cloud or GitHub Enterprise Server 2.20+, `visibility` can also be `internal`.\"", + "name": "required_pull_request_reviews.require_last_push_approval", + "description": "Whether the most recent push must be approved by someone other than the person who pushed it. Default: `false`.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, - "enum": ["public", "private", "internal"], + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -50137,23 +56018,23 @@ "deprecated": null }, { - "name": "security_and_analysis", - "description": "Specify which security and analysis features to enable or disable for the repository.\n\nTo use this parameter, you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see \"[Managing security managers in your organization](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).\"\n\nFor example, to enable GitHub Advanced Security, use this data in the body of the `PATCH` request:\n`{ \"security_and_analysis\": {\"advanced_security\": { \"status\": \"enabled\" } } }`.\n\nYou can check which security and analysis features are currently enabled by using a `GET /repos/{owner}/{repo}` request.", + "name": "required_pull_request_reviews.bypass_pull_request_allowances", + "description": "Allow specific users, teams, or apps to bypass pull request requirements.", "in": "BODY", "type": "object", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "security_and_analysis.advanced_security", - "description": "Use the `status` property to enable or disable GitHub Advanced Security for this repository. For more information, see \"[About GitHub Advanced Security](/github/getting-started-with-github/learning-about-github/about-github-advanced-security).\"", + "name": "required_pull_request_reviews.bypass_pull_request_allowances.users", + "description": "The list of user `login`s allowed to bypass pull request requirements.", "in": "BODY", - "type": "object", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50163,10 +56044,10 @@ "deprecated": null }, { - "name": "security_and_analysis.advanced_security.status", - "description": "Can be `enabled` or `disabled`.", + "name": "required_pull_request_reviews.bypass_pull_request_allowances.teams", + "description": "The list of team `slug`s allowed to bypass pull request requirements.", "in": "BODY", - "type": "string", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50176,10 +56057,10 @@ "deprecated": null }, { - "name": "security_and_analysis.secret_scanning", - "description": "Use the `status` property to enable or disable secret scanning for this repository. For more information, see \"[About secret scanning](/code-security/secret-security/about-secret-scanning).\"", + "name": "required_pull_request_reviews.bypass_pull_request_allowances.apps", + "description": "The list of app `slug`s allowed to bypass pull request requirements.", "in": "BODY", - "type": "object", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50189,24 +56070,24 @@ "deprecated": null }, { - "name": "security_and_analysis.secret_scanning.status", - "description": "Can be `enabled` or `disabled`.", + "name": "restrictions", + "description": "Restrict who can push to the protected branch. User, app, and team `restrictions` are only available for organization-owned repositories. Set to `null` to disable.", "in": "BODY", - "type": "string", - "required": false, + "type": "object", + "required": true, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "security_and_analysis.secret_scanning_push_protection", - "description": "Use the `status` property to enable or disable secret scanning push protection for this repository. For more information, see \"[Protecting pushes with secret scanning](/code-security/secret-scanning/protecting-pushes-with-secret-scanning).\"", + "name": "restrictions.users", + "description": "The list of user `login`s with push access", "in": "BODY", - "type": "object", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50215,11 +56096,11 @@ "deprecated": null }, { - "name": "security_and_analysis.secret_scanning_push_protection.status", - "description": "Can be `enabled` or `disabled`.", + "name": "restrictions.teams", + "description": "The list of team `slug`s with push access", "in": "BODY", - "type": "string", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50228,10 +56109,10 @@ "deprecated": null }, { - "name": "has_issues", - "description": "Either `true` to enable issues for this repository or `false` to disable them.", + "name": "restrictions.apps", + "description": "The list of app `slug`s with push access", "in": "BODY", - "type": "boolean", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50241,8 +56122,8 @@ "deprecated": null }, { - "name": "has_projects", - "description": "Either `true` to enable projects for this repository or `false` to disable them. **Note:** If you're creating a repository in an organization that has disabled repository projects, the default is `false`, and if you pass `true`, the API returns an error.", + "name": "required_linear_history", + "description": "Enforces a linear commit Git history, which prevents anyone from pushing merge commits to a branch. Set to `true` to enforce a linear commit history. Set to `false` to disable a linear commit Git history. Your repository must allow squash merging or rebase merging before you can enable a linear commit history. Default: `false`. For more information, see \"[Requiring a linear commit history](https://docs.github.com/enterprise-cloud@latest//github/administering-a-repository/requiring-a-linear-commit-history)\" in the GitHub Help documentation.", "in": "BODY", "type": "boolean", "required": false, @@ -50254,21 +56135,21 @@ "deprecated": null }, { - "name": "has_wiki", - "description": "Either `true` to enable the wiki for this repository or `false` to disable it.", + "name": "allow_force_pushes", + "description": "Permits force pushes to the protected branch by anyone with write access to the repository. Set to `true` to allow force pushes. Set to `false` or `null` to block force pushes. Default: `false`. For more information, see \"[Enabling force pushes to a protected branch](https://docs.github.com/enterprise-cloud@latest//github/administering-a-repository/enabling-force-pushes-to-a-protected-branch)\" in the GitHub Help documentation.\"", "in": "BODY", "type": "boolean", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "is_template", - "description": "Either `true` to make this repo available as a template repository or `false` to prevent it.", + "name": "allow_deletions", + "description": "Allows deletion of the protected branch by anyone with write access to the repository. Set to `false` to prevent deletion of the protected branch. Default: `false`. For more information, see \"[Enabling force pushes to a protected branch](https://docs.github.com/enterprise-cloud@latest//github/administering-a-repository/enabling-force-pushes-to-a-protected-branch)\" in the GitHub Help documentation.", "in": "BODY", "type": "boolean", "required": false, @@ -50280,10 +56161,10 @@ "deprecated": null }, { - "name": "default_branch", - "description": "Updates the default branch for this repository.", + "name": "block_creations", + "description": "If set to `true`, the `restrictions` branch protection settings which limits who can push will also block pushes which create new branches, unless the push is initiated by a user, team, or app which has the ability to push. Set to `true` to restrict new branch creation. Default: `false`.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -50293,8 +56174,8 @@ "deprecated": null }, { - "name": "allow_squash_merge", - "description": "Either `true` to allow squash-merging pull requests, or `false` to prevent squash-merging.", + "name": "required_conversation_resolution", + "description": "Requires all conversations on code to be resolved before a pull request can be merged into a branch that matches this rule. Set to `false` to disable. Default: `false`.", "in": "BODY", "type": "boolean", "required": false, @@ -50306,8 +56187,8 @@ "deprecated": null }, { - "name": "allow_merge_commit", - "description": "Either `true` to allow merging pull requests with a merge commit, or `false` to prevent merging pull requests with merge commits.", + "name": "lock_branch", + "description": "Whether to set the branch as read-only. If this is true, users will not be able to push to the branch. Default: `false`.", "in": "BODY", "type": "boolean", "required": false, @@ -50319,8 +56200,8 @@ "deprecated": null }, { - "name": "allow_rebase_merge", - "description": "Either `true` to allow rebase-merging pull requests, or `false` to prevent rebase-merging.", + "name": "allow_fork_syncing", + "description": "Whether users can pull changes from upstream when the branch is locked. Set to `true` to allow fork syncing. Set to `false` to prevent fork syncing. Default: `false`.", "in": "BODY", "type": "boolean", "required": false, @@ -50330,13 +56211,50 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, + { + "name": "Update a commit comment", + "scope": "repos", + "id": "updateCommitComment", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/comments/{comment_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#update-a-commit-comment", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "allow_auto_merge", - "description": "Either `true` to allow auto-merge on pull requests, or `false` to disallow auto-merge.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50345,11 +56263,11 @@ "deprecated": null }, { - "name": "delete_branch_on_merge", - "description": "Either `true` to allow automatically deleting head branches when pull requests are merged, or `false` to prevent automatic deletion.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "comment_id", + "description": "The unique identifier of the comment.", + "in": "PATH", + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50358,11 +56276,43 @@ "deprecated": null }, { - "name": "allow_update_branch", - "description": "Either `true` to always allow a pull request head branch that is behind its base branch to be updated even if it is not required to be up to date before merging, or false otherwise.", + "name": "body", + "description": "The contents of the comment", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "Update a deployment branch policy", + "scope": "repos", + "id": "updateDeploymentBranchPolicy", + "method": "PUT", + "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#update-deployment-branch-policy", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50371,11 +56321,11 @@ "deprecated": null }, { - "name": "use_squash_pr_title_as_default", - "description": "Either `true` to allow squash-merge commits to use pull request title, or `false` to use commit message. **This property has been deprecated. Please use `squash_merge_commit_title` instead.", - "in": "BODY", - "type": "boolean", - "required": false, + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50384,12 +56334,12 @@ "deprecated": null }, { - "name": "squash_merge_commit_title", - "description": "The default value for a squash merge commit title:\n\n- `PR_TITLE` - default to the pull request's title.\n- `COMMIT_OR_PR_TITLE` - default to the commit's title (if only one commit) or the pull request's title (when more than one commit).", - "in": "BODY", + "name": "environment_name", + "description": "The name of the environment.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["PR_TITLE", "COMMIT_OR_PR_TITLE"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -50397,12 +56347,54 @@ "deprecated": null }, { - "name": "squash_merge_commit_message", - "description": "The default value for a squash merge commit message:\n\n- `PR_BODY` - default to the pull request's body.\n- `COMMIT_MESSAGES` - default to the branch's commit messages.\n- `BLANK` - default to a blank commit message.", + "name": "branch_policy_id", + "description": "The unique identifier of the branch policy.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name pattern that branches must match in order to deploy to the environment.\n\nWildcard characters will not match `/`. For example, to match branches that begin with `release/` and contain an additional single slash, use `release/*/*`.\nFor more information about pattern matching syntax, see the [Ruby File.fnmatch documentation](https://ruby-doc.org/core-2.5.1/File.html#method-c-fnmatch).", "in": "BODY", "type": "string", - "required": false, - "enum": ["PR_BODY", "COMMIT_MESSAGES", "BLANK"], + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Update information about a GitHub Enterprise Cloud Pages site", + "scope": "repos", + "id": "updateInformationAboutPagesSite", + "method": "PUT", + "url": "/repos/{owner}/{repo}/pages", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Updates information for a GitHub Enterprise Cloud Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).\n\nTo use this endpoint, you must be a repository administrator, maintainer, or have the 'manage GitHub Pages settings' permission. A token with the `repo` scope or Pages write permission is required. GitHub Apps must have the `administration:write` and `pages:write` permissions.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#update-information-about-a-github-pages-site", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -50410,12 +56402,12 @@ "deprecated": null }, { - "name": "merge_commit_title", - "description": "The default value for a merge commit title.\n\n- `PR_TITLE` - default to the pull request's title.\n- `MERGE_MESSAGE` - default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).", - "in": "BODY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["PR_TITLE", "MERGE_MESSAGE"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -50423,21 +56415,21 @@ "deprecated": null }, { - "name": "merge_commit_message", - "description": "The default value for a merge commit message.\n\n- `PR_TITLE` - default to the pull request's title.\n- `PR_BODY` - default to the pull request's body.\n- `BLANK` - default to a blank commit message.", + "name": "cname", + "description": "Specify a custom domain for the repository. Sending a `null` value will remove the custom domain. For more about custom domains, see \"[Using a custom domain with GitHub Pages](https://docs.github.com/enterprise-cloud@latest//articles/using-a-custom-domain-with-github-pages/).\"", "in": "BODY", "type": "string", "required": false, - "enum": ["PR_BODY", "PR_TITLE", "BLANK"], - "allowNull": false, + "enum": null, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "archived", - "description": "`true` to archive this repository. **Note**: You cannot unarchive repositories through the API.", + "name": "https_enforced", + "description": "Specify whether HTTPS should be enforced for the repository.", "in": "BODY", "type": "boolean", "required": false, @@ -50449,10 +56441,23 @@ "deprecated": null }, { - "name": "allow_forking", - "description": "Either `true` to allow private forks, or `false` to prevent private forks.", + "name": "build_type", + "description": "The process by which the GitHub Pages site will be built. `workflow` means that the site is built by a custom GitHub Actions workflow. `legacy` means that the site is built by GitHub when changes are pushed to a specific branch.", "in": "BODY", - "type": "boolean", + "type": "string", + "required": false, + "enum": ["legacy", "workflow"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "source", + "description": "", + "in": "BODY", + "type": null, "required": false, "enum": null, "allowNull": false, @@ -50462,8 +56467,8 @@ "deprecated": null }, { - "name": "web_commit_signoff_required", - "description": "Either `true` to require contributors to sign off on web-based commits, or `false` to not require contributors to sign off on web-based commits.", + "name": "public", + "description": "Configures access controls for the GitHub Pages site. If public is set to `true`, the site is accessible to anyone on the internet. If set to `false`, the site will only be accessible to users who have at least `read` access to the repository that published the site. This includes anyone in your Enterprise if the repository is set to `internal` visibility.", "in": "BODY", "type": "boolean", "required": false, @@ -50476,10 +56481,10 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, - { "code": 307, "description": "Temporary Redirect" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, + { "code": 204, "description": "Response" }, + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 409, "description": "Conflict" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -50488,23 +56493,156 @@ "renamed": null }, { - "name": "Update branch protection", + "name": "Update a repository invitation", "scope": "repos", - "id": "updateBranchProtection", + "id": "updateInvitation", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/invitations/{invitation_id}", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#update-a-repository-invitation", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "invitation_id", + "description": "The unique identifier of the invitation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "permissions", + "description": "The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["read", "write", "maintain", "triage", "admin"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "Update an organization repository ruleset", + "scope": "repos", + "id": "updateOrgRuleset", "method": "PUT", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection", + "url": "/orgs/{org}/rulesets/{ruleset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nProtecting a branch requires admin or owner permissions to the repository.\n\n**Note**: Passing new arrays of `users` and `teams` replaces their previous values.\n\n**Note**: The list of users, apps, and teams in total is limited to 100 items.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-branch-protection", + "description": "Update a ruleset for an organization.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#update-organization-ruleset", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "ruleset_id", + "description": "The ID of the ruleset.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "The name of the ruleset.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "target", + "description": "The target of the ruleset.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["branch", "tag"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "enforcement", + "description": "The enforcement level of the ruleset. `evaluate` allows admins to test rules before enforcing them. Admins can view insights on the Rule Insights page.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["disabled", "active", "evaluate"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "bypass_actors", + "description": "The actors that can bypass the rules in this ruleset", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50513,11 +56651,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "bypass_actors[].actor_id", + "description": "The ID of the actor that can bypass a ruleset", + "in": "BODY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50526,12 +56664,12 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", - "in": "PATH", + "name": "bypass_actors[].actor_type", + "description": "The type of actor that can bypass a ruleset", + "in": "BODY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["Team", "Integration"], "allowNull": false, "mapToData": null, "validation": null, @@ -50539,24 +56677,24 @@ "deprecated": null }, { - "name": "required_status_checks", - "description": "Require status checks to pass before merging. Set to `null` to disable.", + "name": "conditions", + "description": "Conditions for a organization ruleset", "in": "BODY", "type": "object", - "required": true, + "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "required_status_checks.strict", - "description": "Require branches to be up to date before merging.", + "name": "rules", + "description": "An array of rules within the ruleset.", "in": "BODY", - "type": "boolean", - "required": true, + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50565,12 +56703,12 @@ "deprecated": null }, { - "name": "required_status_checks.contexts", - "description": "**Deprecated**: The list of status checks to require in order to merge into this branch. If any of these checks have recently been set by a particular GitHub App, they will be required to come from that app in future for the branch to merge. Use `checks` instead of `contexts` for more fine-grained control.\n", + "name": "rules[].type", + "description": "", "in": "BODY", - "type": "string[]", + "type": "string", "required": true, - "enum": null, + "enum": ["tag_name_pattern"], "allowNull": false, "mapToData": null, "validation": null, @@ -50578,10 +56716,10 @@ "deprecated": null }, { - "name": "required_status_checks.checks", - "description": "The list of status checks to require in order to merge into this branch.", + "name": "rules[].parameters", + "description": "", "in": "BODY", - "type": "object[]", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -50591,10 +56729,10 @@ "deprecated": null }, { - "name": "required_status_checks.checks[].context", - "description": "The name of the required check", + "name": "rules[].parameters.update_allows_fetch_and_merge", + "description": "Branch can pull changes from its upstream repository", "in": "BODY", - "type": "string", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -50604,11 +56742,11 @@ "deprecated": null }, { - "name": "required_status_checks.checks[].app_id", - "description": "The ID of the GitHub App that must provide this check. Omit this field to automatically select the GitHub App that has recently provided this check, or any app if it was not set by a GitHub App. Pass -1 to explicitly allow any app to set the status.", + "name": "rules[].parameters.required_deployment_environments", + "description": "The environments that must be successfully deployed to before branches can be merged.", "in": "BODY", - "type": "integer", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50617,37 +56755,37 @@ "deprecated": null }, { - "name": "enforce_admins", - "description": "Enforce all configured restrictions for administrators. Set to `true` to enforce required status checks for repository administrators. Set to `null` to disable.", + "name": "rules[].parameters.dismiss_stale_reviews_on_push", + "description": "New, reviewable commits pushed will dismiss previous pull request review approvals.", "in": "BODY", "type": "boolean", "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "required_pull_request_reviews", - "description": "Require at least one approving review on a pull request, before merging. Set to `null` to disable.", + "name": "rules[].parameters.require_code_owner_review", + "description": "Require an approving review in pull requests that modify files that have a designated code owner.", "in": "BODY", - "type": "object", + "type": "boolean", "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "required_pull_request_reviews.dismissal_restrictions", - "description": "Specify which users, teams, and apps can dismiss pull request reviews. Pass an empty `dismissal_restrictions` object to disable. User and team `dismissal_restrictions` are only available for organization-owned repositories. Omit this parameter for personal repositories.", + "name": "rules[].parameters.require_last_push_approval", + "description": "Whether the most recent reviewable push must be approved by someone other than the person who pushed it.", "in": "BODY", - "type": "object", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50656,11 +56794,11 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.dismissal_restrictions.users", - "description": "The list of user `login`s with dismissal access", + "name": "rules[].parameters.required_approving_review_count", + "description": "The number of approving reviews that are required before a pull request can be merged.", "in": "BODY", - "type": "string[]", - "required": false, + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50669,11 +56807,11 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.dismissal_restrictions.teams", - "description": "The list of team `slug`s with dismissal access", + "name": "rules[].parameters.required_review_thread_resolution", + "description": "All conversations on code must be resolved before a pull request can be merged.", "in": "BODY", - "type": "string[]", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50682,11 +56820,11 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.dismissal_restrictions.apps", - "description": "The list of app `slug`s with dismissal access", + "name": "rules[].parameters.required_status_checks", + "description": "Status checks that are required.", "in": "BODY", - "type": "string[]", - "required": false, + "type": "object[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50695,11 +56833,11 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.dismiss_stale_reviews", - "description": "Set to `true` if you want to automatically dismiss approving reviews when someone pushes a new commit.", + "name": "rules[].parameters.required_status_checks[].context", + "description": "The status check context name that must be present on the commit.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50708,10 +56846,10 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.require_code_owner_reviews", - "description": "Blocks merging pull requests until [code owners](https://docs.github.com/articles/about-code-owners/) review them.", + "name": "rules[].parameters.required_status_checks[].integration_id", + "description": "The optional integration ID that this status check must originate from.", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -50721,11 +56859,11 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.required_approving_review_count", - "description": "Specify the number of reviewers required to approve pull requests. Use a number between 1 and 6 or 0 to not require reviewers.", + "name": "rules[].parameters.strict_required_status_checks_policy", + "description": "Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled.", "in": "BODY", - "type": "integer", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50734,10 +56872,10 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.bypass_pull_request_allowances", - "description": "Allow specific users, teams, or apps to bypass pull request requirements.", + "name": "rules[].parameters.name", + "description": "How this rule will appear to users.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -50747,10 +56885,10 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.bypass_pull_request_allowances.users", - "description": "The list of user `login`s allowed to bypass pull request requirements.", + "name": "rules[].parameters.negate", + "description": "If true, the rule will fail if the pattern matches.", "in": "BODY", - "type": "string[]", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -50760,12 +56898,12 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.bypass_pull_request_allowances.teams", - "description": "The list of team `slug`s allowed to bypass pull request requirements.", + "name": "rules[].parameters.operator", + "description": "The operator to use for matching.", "in": "BODY", - "type": "string[]", - "required": false, - "enum": null, + "type": "string", + "required": true, + "enum": ["starts_with", "ends_with", "contains", "regex"], "allowNull": false, "mapToData": null, "validation": null, @@ -50773,11 +56911,44 @@ "deprecated": null }, { - "name": "required_pull_request_reviews.bypass_pull_request_allowances.apps", - "description": "The list of app `slug`s allowed to bypass pull request requirements.", + "name": "rules[].parameters.pattern", + "description": "The pattern to match with.", "in": "BODY", - "type": "string[]", - "required": false, + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], + "renamed": null + }, + { + "name": "Update pull request review protection", + "scope": "repos", + "id": "updatePullRequestReviewProtection", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating pull request review enforcement requires admin or owner permissions to the repository and branch protection to be enabled.\n\n**Note**: Passing new arrays of `users` and `teams` replaces their previous values.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#update-pull-request-review-protection", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -50786,23 +56957,23 @@ "deprecated": null }, { - "name": "restrictions", - "description": "Restrict who can push to the protected branch. User, app, and team `restrictions` are only available for organization-owned repositories. Set to `null` to disable.", - "in": "BODY", - "type": "object", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", "required": true, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "restrictions.users", - "description": "The list of user `login`s with push access", - "in": "BODY", - "type": "string[]", + "name": "branch", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", + "in": "PATH", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -50812,11 +56983,24 @@ "deprecated": null }, { - "name": "restrictions.teams", - "description": "The list of team `slug`s with push access", + "name": "dismissal_restrictions", + "description": "Specify which users, teams, and apps can dismiss pull request reviews. Pass an empty `dismissal_restrictions` object to disable. User and team `dismissal_restrictions` are only available for organization-owned repositories. Omit this parameter for personal repositories.", + "in": "BODY", + "type": "object", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "dismissal_restrictions.users", + "description": "The list of user `login`s with dismissal access", "in": "BODY", "type": "string[]", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50825,8 +57009,8 @@ "deprecated": null }, { - "name": "restrictions.apps", - "description": "The list of app `slug`s with push access", + "name": "dismissal_restrictions.teams", + "description": "The list of team `slug`s with dismissal access", "in": "BODY", "type": "string[]", "required": false, @@ -50838,10 +57022,10 @@ "deprecated": null }, { - "name": "required_linear_history", - "description": "Enforces a linear commit Git history, which prevents anyone from pushing merge commits to a branch. Set to `true` to enforce a linear commit history. Set to `false` to disable a linear commit Git history. Your repository must allow squash merging or rebase merging before you can enable a linear commit history. Default: `false`. For more information, see \"[Requiring a linear commit history](https://docs.github.com/github/administering-a-repository/requiring-a-linear-commit-history)\" in the GitHub Help documentation.", + "name": "dismissal_restrictions.apps", + "description": "The list of app `slug`s with dismissal access", "in": "BODY", - "type": "boolean", + "type": "string[]", "required": false, "enum": null, "allowNull": false, @@ -50851,21 +57035,21 @@ "deprecated": null }, { - "name": "allow_force_pushes", - "description": "Permits force pushes to the protected branch by anyone with write access to the repository. Set to `true` to allow force pushes. Set to `false` or `null` to block force pushes. Default: `false`. For more information, see \"[Enabling force pushes to a protected branch](https://docs.github.com/en/github/administering-a-repository/enabling-force-pushes-to-a-protected-branch)\" in the GitHub Help documentation.\"", + "name": "dismiss_stale_reviews", + "description": "Set to `true` if you want to automatically dismiss approving reviews when someone pushes a new commit.", "in": "BODY", "type": "boolean", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "allow_deletions", - "description": "Allows deletion of the protected branch by anyone with write access to the repository. Set to `false` to prevent deletion of the protected branch. Default: `false`. For more information, see \"[Enabling force pushes to a protected branch](https://docs.github.com/en/github/administering-a-repository/enabling-force-pushes-to-a-protected-branch)\" in the GitHub Help documentation.", + "name": "require_code_owner_reviews", + "description": "Blocks merging pull requests until [code owners](https://docs.github.com/enterprise-cloud@latest//articles/about-code-owners/) have reviewed.", "in": "BODY", "type": "boolean", "required": false, @@ -50877,10 +57061,10 @@ "deprecated": null }, { - "name": "block_creations", - "description": "If set to `true`, the `restrictions` branch protection settings which limits who can push will also block pushes which create new branches, unless the push is initiated by a user, team, or app which has the ability to push. Set to `true` to restrict new branch creation. Default: `false`.", + "name": "required_approving_review_count", + "description": "Specifies the number of reviewers required to approve pull requests. Use a number between 1 and 6 or 0 to not require reviewers.", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -50890,8 +57074,8 @@ "deprecated": null }, { - "name": "required_conversation_resolution", - "description": "Requires all conversations on code to be resolved before a pull request can be merged into a branch that matches this rule. Set to `false` to disable. Default: `false`.", + "name": "require_last_push_approval", + "description": "Whether the most recent push must be approved by someone other than the person who pushed it. Default: `false`", "in": "BODY", "type": "boolean", "required": false, @@ -50901,37 +57085,13 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Update a commit comment", - "scope": "repos", - "id": "updateCommitComment", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/comments/{comment_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/commits/comments#update-a-commit-comment", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "bypass_pull_request_allowances", + "description": "Allow specific users, teams, or apps to bypass pull request requirements.", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50940,11 +57100,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "name": "bypass_pull_request_allowances.users", + "description": "The list of user `login`s allowed to bypass pull request requirements.", + "in": "BODY", + "type": "string[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50953,11 +57113,11 @@ "deprecated": null }, { - "name": "comment_id", - "description": "The unique identifier of the comment.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "bypass_pull_request_allowances.teams", + "description": "The list of team `slug`s allowed to bypass pull request requirements.", + "in": "BODY", + "type": "string[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50966,11 +57126,11 @@ "deprecated": null }, { - "name": "body", - "description": "The contents of the comment", + "name": "bypass_pull_request_allowances.apps", + "description": "The list of app `slug`s allowed to bypass pull request requirements.", "in": "BODY", - "type": "string", - "required": true, + "type": "string[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -50981,21 +57141,24 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 404, "description": "Resource not found" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "Update a deployment branch policy", + "name": "Update a release", "scope": "repos", - "id": "updateDeploymentBranchPolicy", - "method": "PUT", - "url": "/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies/{branch_policy_id}", + "id": "updateRelease", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/releases/{release_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Updates a deployment branch policy for an environment.\n\nYou must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `administration:write` permission for the repository to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/deployments/branch-policies#update-deployment-branch-policy", + "description": "Users with push access to the repository can edit a release.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-a-release", "parameters": [ { "name": "owner", @@ -51012,20 +57175,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "environment_name", - "description": "The name of the environment.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -51037,8 +57187,8 @@ "deprecated": null }, { - "name": "branch_policy_id", - "description": "The unique identifier of the branch policy.", + "name": "release_id", + "description": "The unique identifier of the release.", "in": "PATH", "type": "integer", "required": true, @@ -51050,40 +57200,24 @@ "deprecated": null }, { - "name": "name", - "description": "The name pattern that branches must match in order to deploy to the environment.\n\nWildcard characters will not match `/`. For example, to match branches that begin with `release/` and contain an additional single slash, use `release/*/*`.\nFor more information about pattern matching syntax, see the [Ruby File.fnmatch documentation](https://ruby-doc.org/core-2.5.1/File.html#method-c-fnmatch).", + "name": "tag_name", + "description": "The name of the tag.", "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [{ "code": 200, "description": "Response" }], - "renamed": null - }, - { - "name": "Update information about a GitHub Enterprise Cloud Pages site", - "scope": "repos", - "id": "updateInformationAboutPagesSite", - "method": "PUT", - "url": "/repos/{owner}/{repo}/pages", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Updates information for a GitHub Enterprise Cloud Pages site. For more information, see \"[About GitHub Pages](/github/working-with-github-pages/about-github-pages).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/pages#update-information-about-a-github-pages-site", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "target_commitish", + "description": "Specifies the commitish value that determines where the Git tag is created from. Can be any branch or commit SHA. Unused if the Git tag already exists. Default: the repository's default branch.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -51092,11 +57226,11 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "name", + "description": "The name of the release.", + "in": "BODY", "type": "string", - "required": true, + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -51105,21 +57239,21 @@ "deprecated": null }, { - "name": "cname", - "description": "Specify a custom domain for the repository. Sending a `null` value will remove the custom domain. For more about custom domains, see \"[Using a custom domain with GitHub Pages](https://docs.github.com/articles/using-a-custom-domain-with-github-pages/).\"", + "name": "body", + "description": "Text describing the contents of the tag.", "in": "BODY", "type": "string", "required": false, "enum": null, - "allowNull": true, + "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "https_enforced", - "description": "Specify whether HTTPS should be enforced for the repository.", + "name": "draft", + "description": "`true` makes the release a draft, and `false` publishes the release.", "in": "BODY", "type": "boolean", "required": false, @@ -51131,8 +57265,8 @@ "deprecated": null }, { - "name": "public", - "description": "Configures access controls for the GitHub Pages site. If public is set to `true`, the site is accessible to anyone on the internet. If set to `false`, the site will only be accessible to users who have at least `read` access to the repository that published the site. This includes anyone in your Enterprise if the repository is set to `internal` visibility. This feature is only available to repositories in an organization on an Enterprise plan.", + "name": "prerelease", + "description": "`true` to identify the release as a prerelease, `false` to identify the release as a full release.", "in": "BODY", "type": "boolean", "required": false, @@ -51144,12 +57278,12 @@ "deprecated": null }, { - "name": "build_type", - "description": "The process by which the GitHub Pages site will be built. `workflow` means that the site is built by a custom GitHub Actions workflow. `legacy` means that the site is built by GitHub when changes are pushed to a specific branch.", + "name": "make_latest", + "description": "Specifies whether this release should be set as the latest release for the repository. Drafts and prereleases cannot be set as latest. Defaults to `true` for newly published releases. `legacy` specifies that the latest release should be determined based on the release creation date and higher semantic version.", "in": "BODY", "type": "string", "required": false, - "enum": ["legacy", "workflow"], + "enum": ["true", "false", "legacy"], "allowNull": false, "mapToData": null, "validation": null, @@ -51157,10 +57291,10 @@ "deprecated": null }, { - "name": "source", - "description": "", + "name": "discussion_category_name", + "description": "If specified, a discussion of the specified category is created and linked to the release. The value must be a category that already exists in the repository. If there is already a discussion linked to the release, this parameter is ignored. For more information, see \"[Managing categories for discussions in your repository](https://docs.github.com/enterprise-cloud@latest//discussions/managing-discussions-for-your-community/managing-categories-for-discussions-in-your-repository).\"", "in": "BODY", - "type": null, + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -51171,28 +57305,25 @@ } ], "responses": [ - { "code": 204, "description": "Response" }, - { "code": 400, "description": "Bad Request" }, - { "code": 400, "description": "Bad Request" }, - { "code": 409, "description": "Conflict" }, + { "code": 200, "description": "Response" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 404, + "description": "Not Found if the discussion category name is invalid" } ], "renamed": null }, { - "name": "Update a repository invitation", + "name": "Update a release asset", "scope": "repos", - "id": "updateInvitation", + "id": "updateReleaseAsset", "method": "PATCH", - "url": "/repos/{owner}/{repo}/invitations/{invitation_id}", + "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/collaborators/invitations#update-a-repository-invitation", + "description": "Users with push access to the repository can edit a release asset.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-a-release-asset", "parameters": [ { "name": "owner", @@ -51209,7 +57340,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -51221,8 +57352,8 @@ "deprecated": null }, { - "name": "invitation_id", - "description": "The unique identifier of the invitation.", + "name": "asset_id", + "description": "The unique identifier of the asset.", "in": "PATH", "type": "integer", "required": true, @@ -51234,12 +57365,38 @@ "deprecated": null }, { - "name": "permissions", - "description": "The permissions that the associated user will have on the repository. Valid values are `read`, `write`, `maintain`, `triage`, and `admin`.", + "name": "name", + "description": "The file name of the asset.", "in": "BODY", "type": "string", "required": false, - "enum": ["read", "write", "maintain", "triage", "admin"], + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "label", + "description": "An alternate short description of the asset. Used in place of the filename.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -51251,16 +57408,16 @@ "renamed": null }, { - "name": "Update pull request review protection", + "name": "Update a repository ruleset", "scope": "repos", - "id": "updatePullRequestReviewProtection", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", + "id": "updateRepoRuleset", + "method": "PUT", + "url": "/repos/{owner}/{repo}/rulesets/{ruleset_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating pull request review enforcement requires admin or owner permissions to the repository and branch protection to be enabled.\n\n**Note**: Passing new arrays of `users` and `teams` replaces their previous values.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-pull-request-review-protection", + "description": "Update a ruleset for a repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/repos/rules#update-repository-ruleset", "parameters": [ { "name": "owner", @@ -51277,7 +57434,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -51289,10 +57446,10 @@ "deprecated": null }, { - "name": "branch", - "description": "The name of the branch.", + "name": "ruleset_id", + "description": "The ID of the ruleset.", "in": "PATH", - "type": "string", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -51302,10 +57459,10 @@ "deprecated": null }, { - "name": "dismissal_restrictions", - "description": "Specify which users, teams, and apps can dismiss pull request reviews. Pass an empty `dismissal_restrictions` object to disable. User and team `dismissal_restrictions` are only available for organization-owned repositories. Omit this parameter for personal repositories.", + "name": "name", + "description": "The name of the ruleset.", "in": "BODY", - "type": "object", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -51315,12 +57472,12 @@ "deprecated": null }, { - "name": "dismissal_restrictions.users", - "description": "The list of user `login`s with dismissal access", + "name": "target", + "description": "The target of the ruleset.", "in": "BODY", - "type": "string[]", + "type": "string", "required": false, - "enum": null, + "enum": ["branch", "tag"], "allowNull": false, "mapToData": null, "validation": null, @@ -51328,12 +57485,12 @@ "deprecated": null }, { - "name": "dismissal_restrictions.teams", - "description": "The list of team `slug`s with dismissal access", + "name": "enforcement", + "description": "The enforcement level of the ruleset. `evaluate` allows admins to test rules before enforcing them. Admins can view insights on the Rule Insights page.", "in": "BODY", - "type": "string[]", + "type": "string", "required": false, - "enum": null, + "enum": ["disabled", "active", "evaluate"], "allowNull": false, "mapToData": null, "validation": null, @@ -51341,12 +57498,12 @@ "deprecated": null }, { - "name": "dismissal_restrictions.apps", - "description": "The list of app `slug`s with dismissal access", + "name": "bypass_mode", + "description": "The permission level required to bypass this ruleset. \"repository\" allows those with bypass permission at the repository level to bypass. \"organization\" allows those with bypass permission at the organization level to bypass. \"none\" prevents anyone from bypassing.", "in": "BODY", - "type": "string[]", + "type": "string", "required": false, - "enum": null, + "enum": ["none", "repository", "organization"], "allowNull": false, "mapToData": null, "validation": null, @@ -51354,10 +57511,10 @@ "deprecated": null }, { - "name": "dismiss_stale_reviews", - "description": "Set to `true` if you want to automatically dismiss approving reviews when someone pushes a new commit.", + "name": "bypass_actors", + "description": "The actors that can bypass the rules in this ruleset", "in": "BODY", - "type": "boolean", + "type": "object[]", "required": false, "enum": null, "allowNull": false, @@ -51367,10 +57524,10 @@ "deprecated": null }, { - "name": "require_code_owner_reviews", - "description": "Blocks merging pull requests until [code owners](https://docs.github.com/articles/about-code-owners/) have reviewed.", + "name": "bypass_actors[].actor_id", + "description": "The ID of the actor that can bypass a ruleset", "in": "BODY", - "type": "boolean", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -51380,12 +57537,12 @@ "deprecated": null }, { - "name": "required_approving_review_count", - "description": "Specifies the number of reviewers required to approve pull requests. Use a number between 1 and 6 or 0 to not require reviewers.", + "name": "bypass_actors[].actor_type", + "description": "The type of actor that can bypass a ruleset", "in": "BODY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["Team", "Integration"], "allowNull": false, "mapToData": null, "validation": null, @@ -51393,8 +57550,8 @@ "deprecated": null }, { - "name": "bypass_pull_request_allowances", - "description": "Allow specific users, teams, or apps to bypass pull request requirements.", + "name": "conditions", + "description": "Parameters for a repository ruleset ref name condition", "in": "BODY", "type": "object", "required": false, @@ -51406,10 +57563,10 @@ "deprecated": null }, { - "name": "bypass_pull_request_allowances.users", - "description": "The list of user `login`s allowed to bypass pull request requirements.", + "name": "conditions.ref_name", + "description": "", "in": "BODY", - "type": "string[]", + "type": "object", "required": false, "enum": null, "allowNull": false, @@ -51419,8 +57576,8 @@ "deprecated": null }, { - "name": "bypass_pull_request_allowances.teams", - "description": "The list of team `slug`s allowed to bypass pull request requirements.", + "name": "conditions.ref_name.include", + "description": "Array of ref names or patterns to include. One of these patterns must match for the condition to pass. Also accepts `~DEFAULT_BRANCH` to include the default branch or `~ALL` to include all branches.", "in": "BODY", "type": "string[]", "required": false, @@ -51432,8 +57589,8 @@ "deprecated": null }, { - "name": "bypass_pull_request_allowances.apps", - "description": "The list of app `slug`s allowed to bypass pull request requirements.", + "name": "conditions.ref_name.exclude", + "description": "Array of ref names or patterns to exclude. The condition will not pass if any of these patterns match.", "in": "BODY", "type": "string[]", "required": false, @@ -51442,36 +57599,14 @@ "mapToData": null, "validation": null, "alias": null, - "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } - ], - "renamed": null - }, - { - "name": "Update a release", - "scope": "repos", - "id": "updateRelease", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/releases/{release_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Users with push access to the repository can edit a release.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-a-release", - "parameters": [ - { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", - "required": true, + "deprecated": null + }, + { + "name": "rules", + "description": "An array of rules within the ruleset.", + "in": "BODY", + "type": "object[]", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -51480,12 +57615,12 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "rules[].type", + "description": "", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": ["tag_name_pattern"], "allowNull": false, "mapToData": null, "validation": null, @@ -51493,11 +57628,11 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", - "in": "PATH", - "type": "integer", - "required": true, + "name": "rules[].parameters", + "description": "", + "in": "BODY", + "type": "object", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -51506,11 +57641,11 @@ "deprecated": null }, { - "name": "tag_name", - "description": "The name of the tag.", + "name": "rules[].parameters.update_allows_fetch_and_merge", + "description": "Branch can pull changes from its upstream repository", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51519,11 +57654,11 @@ "deprecated": null }, { - "name": "target_commitish", - "description": "Specifies the commitish value that determines where the Git tag is created from. Can be any branch or commit SHA. Unused if the Git tag already exists. Default: the repository's default branch (usually `master`).", + "name": "rules[].parameters.required_deployment_environments", + "description": "The environments that must be successfully deployed to before branches can be merged.", "in": "BODY", - "type": "string", - "required": false, + "type": "string[]", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51532,11 +57667,11 @@ "deprecated": null }, { - "name": "name", - "description": "The name of the release.", + "name": "rules[].parameters.dismiss_stale_reviews_on_push", + "description": "New, reviewable commits pushed will dismiss previous pull request review approvals.", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51545,11 +57680,11 @@ "deprecated": null }, { - "name": "body", - "description": "Text describing the contents of the tag.", + "name": "rules[].parameters.require_code_owner_review", + "description": "Require an approving review in pull requests that modify files that have a designated code owner.", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51558,11 +57693,11 @@ "deprecated": null }, { - "name": "draft", - "description": "`true` makes the release a draft, and `false` publishes the release.", + "name": "rules[].parameters.require_last_push_approval", + "description": "Whether the most recent reviewable push must be approved by someone other than the person who pushed it.", "in": "BODY", "type": "boolean", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51571,11 +57706,11 @@ "deprecated": null }, { - "name": "prerelease", - "description": "`true` to identify the release as a prerelease, `false` to identify the release as a full release.", + "name": "rules[].parameters.required_approving_review_count", + "description": "The number of approving reviews that are required before a pull request can be merged.", "in": "BODY", - "type": "boolean", - "required": false, + "type": "integer", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51584,45 +57719,23 @@ "deprecated": null }, { - "name": "discussion_category_name", - "description": "If specified, a discussion of the specified category is created and linked to the release. The value must be a category that already exists in the repository. If there is already a discussion linked to the release, this parameter is ignored. For more information, see \"[Managing categories for discussions in your repository](https://docs.github.com/enterprise-cloud@latest//discussions/managing-discussions-for-your-community/managing-categories-for-discussions-in-your-repository).\"", + "name": "rules[].parameters.required_review_thread_resolution", + "description": "All conversations on code must be resolved before a pull request can be merged.", "in": "BODY", - "type": "string", - "required": false, + "type": "boolean", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 404, - "description": "Not Found if the discussion category name is invalid" - } - ], - "renamed": null - }, - { - "name": "Update a release asset", - "scope": "repos", - "id": "updateReleaseAsset", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/releases/assets/{asset_id}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Users with push access to the repository can edit a release asset.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-a-release-asset", - "parameters": [ + }, { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "rules[].parameters.required_status_checks", + "description": "Status checks that are required.", + "in": "BODY", + "type": "object[]", "required": true, "enum": null, "allowNull": false, @@ -51632,9 +57745,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "rules[].parameters.required_status_checks[].context", + "description": "The status check context name that must be present on the commit.", + "in": "BODY", "type": "string", "required": true, "enum": null, @@ -51645,10 +57758,23 @@ "deprecated": null }, { - "name": "asset_id", - "description": "The unique identifier of the asset.", - "in": "PATH", + "name": "rules[].parameters.required_status_checks[].integration_id", + "description": "The optional integration ID that this status check must originate from.", + "in": "BODY", "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "rules[].parameters.strict_required_status_checks_policy", + "description": "Whether pull requests targeting a matching branch must be tested with the latest code. This setting will not take effect unless at least one status check is enabled.", + "in": "BODY", + "type": "boolean", "required": true, "enum": null, "allowNull": false, @@ -51658,8 +57784,8 @@ "deprecated": null }, { - "name": "name", - "description": "The file name of the asset.", + "name": "rules[].parameters.name", + "description": "How this rule will appear to users.", "in": "BODY", "type": "string", "required": false, @@ -51671,10 +57797,10 @@ "deprecated": null }, { - "name": "label", - "description": "An alternate short description of the asset. Used in place of the filename.", + "name": "rules[].parameters.negate", + "description": "If true, the rule will fail if the pattern matches.", "in": "BODY", - "type": "string", + "type": "boolean", "required": false, "enum": null, "allowNull": false, @@ -51684,11 +57810,24 @@ "deprecated": null }, { - "name": "state", - "description": "", + "name": "rules[].parameters.operator", + "description": "The operator to use for matching.", "in": "BODY", "type": "string", - "required": false, + "required": true, + "enum": ["starts_with", "ends_with", "contains", "regex"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "rules[].parameters.pattern", + "description": "The pattern to match with.", + "in": "BODY", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -51697,7 +57836,11 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 404, "description": "Resource not found" }, + { "code": 500, "description": "Internal Error" } + ], "renamed": null }, { @@ -51709,8 +57852,8 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating required status checks requires admin or owner permissions to the repository and branch protection to be enabled.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-status-check-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating required status checks requires admin or owner permissions to the repository and branch protection to be enabled.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#update-status-check-protection", "parameters": [ { "name": "owner", @@ -51727,7 +57870,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -51740,7 +57883,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -51841,8 +57984,8 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating required status checks requires admin or owner permissions to the repository and branch protection to be enabled.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#update-status-check-protection", + "description": "Protected branches are available in public repositories with GitHub Free and GitHub Free for organizations, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nUpdating required status checks requires admin or owner permissions to the repository and branch protection to be enabled.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/branches/branch-protection#update-status-check-protection", "parameters": [ { "name": "owner", @@ -51859,7 +58002,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -51872,7 +58015,7 @@ }, { "name": "branch", - "description": "The name of the branch.", + "description": "The name of the branch. Cannot contain wildcard characters. To use wildcard characters in branch names, use [the GraphQL API](https://docs.github.com/enterprise-cloud@latest//graphql).", "in": "PATH", "type": "string", "required": true, @@ -51986,7 +58129,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -52191,7 +58334,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -52280,14 +58423,403 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "This endpoint makes use of [a Hypermedia relation](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia) to determine which URL to access. The endpoint you call to upload release assets is specific to your release. Use the `upload_url` returned in\nthe response of the [Create a release endpoint](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#create-a-release) to upload a release asset.\n\nYou need to use an HTTP client which supports [SNI](http://en.wikipedia.org/wiki/Server_Name_Indication) to make calls to this endpoint.\n\nMost libraries will set the required `Content-Length` header automatically. Use the required `Content-Type` header to provide the media type of the asset. For a list of media types, see [Media Types](https://www.iana.org/assignments/media-types/media-types.xhtml). For example: \n\n`application/zip`\n\nGitHub Enterprise Cloud expects the asset data in its raw binary form, rather than JSON. You will send the raw binary content of the asset as the request body. Everything else about the endpoint is the same as the rest of the API. For example,\nyou'll still need to pass your authentication to be able to upload an asset.\n\nWhen an upstream failure occurs, you will receive a `502 Bad Gateway` status. This may leave an empty asset with a state of `starter`. It can be safely deleted.\n\n**Notes:**\n* GitHub Enterprise Cloud renames asset filenames that have special characters, non-alphanumeric characters, and leading or trailing periods. The \"[List assets for a release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-assets-for-a-release)\"\nendpoint lists the renamed filenames. For more information and help, contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api).\n* If you upload an asset with the same filename as another uploaded asset, you'll receive an error and must delete the old file before you can re-upload the new asset.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#upload-a-release-asset", + "description": "This endpoint makes use of [a Hypermedia relation](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#hypermedia) to determine which URL to access. The endpoint you call to upload release assets is specific to your release. Use the `upload_url` returned in\nthe response of the [Create a release endpoint](https://docs.github.com/enterprise-cloud@latest//rest/releases/releases#create-a-release) to upload a release asset.\n\nYou need to use an HTTP client which supports [SNI](http://en.wikipedia.org/wiki/Server_Name_Indication) to make calls to this endpoint.\n\nMost libraries will set the required `Content-Length` header automatically. Use the required `Content-Type` header to provide the media type of the asset. For a list of media types, see [Media Types](https://www.iana.org/assignments/media-types/media-types.xhtml). For example: \n\n`application/zip`\n\nGitHub Enterprise Cloud expects the asset data in its raw binary form, rather than JSON. You will send the raw binary content of the asset as the request body. Everything else about the endpoint is the same as the rest of the API. For example,\nyou'll still need to pass your authentication to be able to upload an asset.\n\nWhen an upstream failure occurs, you will receive a `502 Bad Gateway` status. This may leave an empty asset with a state of `starter`. It can be safely deleted.\n\n**Notes:**\n* GitHub Enterprise Cloud renames asset filenames that have special characters, non-alphanumeric characters, and leading or trailing periods. The \"[List assets for a release](https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#list-assets-for-a-release)\"\nendpoint lists the renamed filenames. For more information and help, contact [GitHub Enterprise Cloud Support](https://support.github.com/contact?tags=dotcom-rest-api).\n* To find the `release_id` query the [`GET /repos/{owner}/{repo}/releases/latest` endpoint](https://docs.github.com/enterprise-cloud@latest//rest/releases/releases#get-the-latest-release). \n* If you upload an asset with the same filename as another uploaded asset, you'll receive an error and must delete the old file before you can re-upload the new asset.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/repos#upload-a-release-asset", + "parameters": [ + { + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "release_id", + "description": "The unique identifier of the release.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "name", + "description": "", + "in": "QUERY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "label", + "description": "", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "data", + "description": "The raw file data", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": true, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "origin", + "description": "The URL origin (protocol + host name + port) is included in `upload_url` returned in the response of the \"Create a release\" endpoint", + "in": "PATH", + "type": "string", + "required": null, + "enum": null, + "allowNull": null, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response for successful upload" }, + { + "code": 422, + "description": "Response if you upload an asset with the same filename as another uploaded asset" + } + ], + "renamed": null + }, + { + "name": "Search code", + "scope": "search", + "id": "code", + "method": "GET", + "url": "/search/code", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Searches for query terms inside of a file. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for code, you can get text match metadata for the file **content** and file **path** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find the definition of the `addClass` function inside [jQuery](https://github.com/jquery/jquery) repository, your query would look something like this:\n\n`q=addClass+in:file+language:js+repo:jquery/jquery`\n\nThis query searches for the keyword `addClass` within a file's contents. The query limits the search to files where the language is JavaScript in the `jquery/jquery` repository.\n\n#### Considerations for code search\n\nDue to the complexity of searching code, there are a few restrictions on how searches are performed:\n\n* Only the _default branch_ is considered. In most cases, this will be the `master` branch.\n* Only files smaller than 384 KB are searchable.\n* You must always include at least one search term when searching source code. For example, searching for [`language:go`](https://github.com/search?utf8=%E2%9C%93&q=language%3Ago&type=Code) is not valid, while [`amazing\nlanguage:go`](https://github.com/search?utf8=%E2%9C%93&q=amazing+language%3Ago&type=Code) is.\n\nThis endpoint requires you to authenticate and limits you to 10 requests per minute.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-code", + "parameters": [ + { + "name": "q", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching code](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-code)\" for a detailed list of qualifiers.", + "in": "QUERY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "**This field is deprecated.** Sorts the results of your query. Can only be `indexed`, which indicates how recently a file has been indexed by the GitHub Enterprise Cloud search infrastructure. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["indexed"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "order", + "description": "**This field is deprecated.** Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`. ", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["desc", "asc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "Search commits", + "scope": "search", + "id": "commits", + "method": "GET", + "url": "/search/commits", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Find commits via various criteria on the default branch (usually `main`). This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for commits, you can get text match metadata for the **message** field when you provide the `text-match` media type. For more details about how to receive highlighted search results, see [Text match\nmetadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find commits related to CSS in the [octocat/Spoon-Knife](https://github.com/octocat/Spoon-Knife) repository. Your query would look something like this:\n\n`q=repo:octocat/Spoon-Knife+css`", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-commits", + "parameters": [ + { + "name": "q", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching commits](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-commits)\" for a detailed list of qualifiers.", + "in": "QUERY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "Sorts the results of your query by `author-date` or `committer-date`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["author-date", "committer-date"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "order", + "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["desc", "asc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" } + ], + "renamed": null + }, + { + "name": "Search issues and pull requests", + "scope": "search", + "id": "issuesAndPullRequests", + "method": "GET", + "url": "/search/issues", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Find issues by state and keyword. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for issues, you can get text match metadata for the issue **title**, issue **body**, and issue **comment body** fields when you pass the `text-match` media type. For more details about how to receive highlighted\nsearch results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find the oldest unresolved Python bugs on Windows. Your query might look something like this.\n\n`q=windows+label:bug+language:python+state:open&sort=created&order=asc`\n\nThis query searches for the keyword `windows`, within any open issue that is labeled as `bug`. The search runs across repositories whose primary language is Python. The results are sorted by creation date in ascending order, which means the oldest issues appear first in the search results.\n\n**Note:** For [user-to-server](https://docs.github.com/enterprise-cloud@latest//developers/apps/identifying-and-authorizing-users-for-github-apps#user-to-server-requests) GitHub App requests, you can't retrieve a combination of issues and pull requests in a single query. Requests that don't include the `is:issue` or `is:pull-request` qualifier will receive an HTTP `422 Unprocessable Entity` response. To get results for both issues and pull requests, you must send separate queries for issues and pull requests. For more information about the `is` qualifier, see \"[Searching only issues or pull requests](https://docs.github.com/enterprise-cloud@latest//github/searching-for-information-on-github/searching-issues-and-pull-requests#search-only-issues-or-pull-requests).\"", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-issues-and-pull-requests", + "parameters": [ + { + "name": "q", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching issues and pull requests](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-issues-and-pull-requests)\" for a detailed list of qualifiers.", + "in": "QUERY", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "Sorts the results of your query by the number of `comments`, `reactions`, `reactions-+1`, `reactions--1`, `reactions-smile`, `reactions-thinking_face`, `reactions-heart`, `reactions-tada`, or `interactions`. You can also sort results by how recently the items were `created` or `updated`, Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "in": "QUERY", + "type": "string", + "required": false, + "enum": [ + "comments", + "reactions", + "reactions-+1", + "reactions--1", + "reactions-smile", + "reactions-thinking_face", + "reactions-heart", + "reactions-tada", + "interactions", + "created", + "updated" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "order", + "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["desc", "asc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "Search labels", + "scope": "search", + "id": "labels", + "method": "GET", + "url": "/search/labels", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Find labels in a repository with names or descriptions that match search keywords. Returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for labels, you can get text match metadata for the label **name** and **description** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find labels in the `linguist` repository that match `bug`, `defect`, or `enhancement`. Your query might look like this:\n\n`q=bug+defect+enhancement&repository_id=64778136`\n\nThe labels that best match the query appear first in the search results.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-labels", "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", - "type": "string", + "name": "repository_id", + "description": "The id of the repository.", + "in": "QUERY", + "type": "integer", "required": true, "enum": null, "allowNull": false, @@ -52297,9 +58829,9 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "q", + "description": "The search keywords. This endpoint does not accept qualifiers in the query. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query).", + "in": "QUERY", "type": "string", "required": true, "enum": null, @@ -52310,12 +58842,12 @@ "deprecated": null }, { - "name": "release_id", - "description": "The unique identifier of the release.", - "in": "PATH", - "type": "integer", - "required": true, - "enum": null, + "name": "sort", + "description": "Sorts the results of your query by when the label was `created` or `updated`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], "allowNull": false, "mapToData": null, "validation": null, @@ -52323,12 +58855,12 @@ "deprecated": null }, { - "name": "name", - "description": "", + "name": "order", + "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", "in": "QUERY", "type": "string", - "required": true, - "enum": null, + "required": false, + "enum": ["desc", "asc"], "allowNull": false, "mapToData": null, "validation": null, @@ -52336,10 +58868,10 @@ "deprecated": null }, { - "name": "label", - "description": "", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", - "type": "string", + "type": "integer", "required": false, "enum": null, "allowNull": false, @@ -52349,26 +58881,13 @@ "deprecated": null }, { - "name": "data", - "description": "The raw file data", - "in": "BODY", - "type": "string", - "required": true, + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, "enum": null, "allowNull": false, - "mapToData": true, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "origin", - "description": "The URL origin (protocol + host name + port) is included in `upload_url` returned in the response of the \"Create a release\" endpoint", - "in": "PATH", - "type": "string", - "required": null, - "enum": null, - "allowNull": null, "mapToData": null, "validation": null, "alias": null, @@ -52376,29 +58895,32 @@ } ], "responses": [ - { "code": 201, "description": "Response for successful upload" }, + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, - "description": "Response if you upload an asset with the same filename as another uploaded asset" + "description": "Validation failed, or the endpoint has been spammed." } ], "renamed": null }, { - "name": "Search code", + "name": "Search repositories", "scope": "search", - "id": "code", + "id": "repos", "method": "GET", - "url": "/search/code", + "url": "/search/repositories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Searches for query terms inside of a file. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for code, you can get text match metadata for the file **content** and file **path** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find the definition of the `addClass` function inside [jQuery](https://github.com/jquery/jquery) repository, your query would look something like this:\n\n`q=addClass+in:file+language:js+repo:jquery/jquery`\n\nThis query searches for the keyword `addClass` within a file's contents. The query limits the search to files where the language is JavaScript in the `jquery/jquery` repository.\n\n#### Considerations for code search\n\nDue to the complexity of searching code, there are a few restrictions on how searches are performed:\n\n* Only the _default branch_ is considered. In most cases, this will be the `master` branch.\n* Only files smaller than 384 KB are searchable.\n* You must always include at least one search term when searching source code. For example, searching for [`language:go`](https://github.com/search?utf8=%E2%9C%93&q=language%3Ago&type=Code) is not valid, while [`amazing\nlanguage:go`](https://github.com/search?utf8=%E2%9C%93&q=amazing+language%3Ago&type=Code) is.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-code", + "description": "Find repositories via various criteria. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for repositories, you can get text match metadata for the **name** and **description** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to search for popular Tetris repositories written in assembly code, your query might look like this:\n\n`q=tetris+language:assembly&sort=stars&order=desc`\n\nThis query searches for repositories with the word `tetris` in the name, the description, or the README. The results are limited to repositories where the primary language is assembly. The results are sorted by stars in descending order, so that the most popular repositories appear first in the search results.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-repositories", "parameters": [ { "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching code](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-code)\" for a detailed list of qualifiers.", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching for repositories](https://docs.github.com/enterprise-cloud@latest//articles/searching-for-repositories/)\" for a detailed list of qualifiers.", "in": "QUERY", "type": "string", "required": true, @@ -52411,11 +58933,11 @@ }, { "name": "sort", - "description": "Sorts the results of your query. Can only be `indexed`, which indicates how recently a file has been indexed by the GitHub Enterprise Cloud search infrastructure. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "description": "Sorts the results of your query by number of `stars`, `forks`, or `help-wanted-issues` or how recently the items were `updated`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", "in": "QUERY", "type": "string", "required": false, - "enum": ["indexed"], + "enum": ["stars", "forks", "help-wanted-issues", "updated"], "allowNull": false, "mapToData": null, "validation": null, @@ -52465,7 +58987,6 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -52475,20 +58996,20 @@ "renamed": null }, { - "name": "Search commits", + "name": "Search topics", "scope": "search", - "id": "commits", + "id": "topics", "method": "GET", - "url": "/search/commits", + "url": "/search/topics", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find commits via various criteria on the default branch (usually `master`). This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for commits, you can get text match metadata for the **message** field when you provide the `text-match` media type. For more details about how to receive highlighted search results, see [Text match\nmetadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find commits related to CSS in the [octocat/Spoon-Knife](https://github.com/octocat/Spoon-Knife) repository. Your query would look something like this:\n\n`q=repo:octocat/Spoon-Knife+css`", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-commits", + "description": "Find topics via various criteria. Results are sorted by best match. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination). See \"[Searching topics](https://docs.github.com/enterprise-cloud@latest//articles/searching-topics/)\" for a detailed list of qualifiers.\n\nWhen searching for topics, you can get text match metadata for the topic's **short\\_description**, **description**, **name**, or **display\\_name** field when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to search for topics related to Ruby that are featured on https://github.com/topics. Your query might look like this:\n\n`q=ruby+is:featured`\n\nThis query searches for topics with the keyword `ruby` and limits the results to find only topics that are featured. The topics that are the best match for the query appear first in the search results.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-topics", "parameters": [ { "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching commits](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-commits)\" for a detailed list of qualifiers.", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query).", "in": "QUERY", "type": "string", "required": true, @@ -52499,32 +59020,6 @@ "alias": null, "deprecated": null }, - { - "name": "sort", - "description": "Sorts the results of your query by `author-date` or `committer-date`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["author-date", "committer-date"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "order", - "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["desc", "asc"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -52559,20 +59054,20 @@ "renamed": null }, { - "name": "Search issues and pull requests", + "name": "Search users", "scope": "search", - "id": "issuesAndPullRequests", + "id": "users", "method": "GET", - "url": "/search/issues", + "url": "/search/users", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find issues by state and keyword. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for issues, you can get text match metadata for the issue **title**, issue **body**, and issue **comment body** fields when you pass the `text-match` media type. For more details about how to receive highlighted\nsearch results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find the oldest unresolved Python bugs on Windows. Your query might look something like this.\n\n`q=windows+label:bug+language:python+state:open&sort=created&order=asc`\n\nThis query searches for the keyword `windows`, within any open issue that is labeled as `bug`. The search runs across repositories whose primary language is Python. The results are sorted by creation date in ascending order, which means the oldest issues appear first in the search results.\n\n**Note:** For [user-to-server](https://docs.github.com/developers/apps/identifying-and-authorizing-users-for-github-apps#user-to-server-requests) GitHub App requests, you can't retrieve a combination of issues and pull requests in a single query. Requests that don't include the `is:issue` or `is:pull-request` qualifier will receive an HTTP `422 Unprocessable Entity` response. To get results for both issues and pull requests, you must send separate queries for issues and pull requests. For more information about the `is` qualifier, see \"[Searching only issues or pull requests](https://docs.github.com/github/searching-for-information-on-github/searching-issues-and-pull-requests#search-only-issues-or-pull-requests).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-issues-and-pull-requests", + "description": "Find users via various criteria. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for users, you can get text match metadata for the issue **login**, public **email**, and **name** fields when you pass the `text-match` media type. For more details about highlighting search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata). For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you're looking for a list of popular users, you might try this query:\n\n`q=tom+repos:%3E42+followers:%3E1000`\n\nThis query searches for users with the name `tom`. The results are restricted to users with more than 42 repositories and over 1,000 followers.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-users", "parameters": [ { "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching issues and pull requests](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-issues-and-pull-requests)\" for a detailed list of qualifiers.", + "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching users](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-users)\" for a detailed list of qualifiers.", "in": "QUERY", "type": "string", "required": true, @@ -52585,23 +59080,11 @@ }, { "name": "sort", - "description": "Sorts the results of your query by the number of `comments`, `reactions`, `reactions-+1`, `reactions--1`, `reactions-smile`, `reactions-thinking_face`, `reactions-heart`, `reactions-tada`, or `interactions`. You can also sort results by how recently the items were `created` or `updated`, Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "description": "Sorts the results of your query by number of `followers` or `repositories`, or when the person `joined` GitHub Enterprise Cloud. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", "in": "QUERY", "type": "string", "required": false, - "enum": [ - "comments", - "reactions", - "reactions-+1", - "reactions--1", - "reactions-smile", - "reactions-thinking_face", - "reactions-heart", - "reactions-tada", - "interactions", - "created", - "updated" - ], + "enum": ["followers", "repositories", "joined"], "allowNull": false, "mapToData": null, "validation": null, @@ -52651,7 +59134,6 @@ "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, { "code": 422, "description": "Validation failed, or the endpoint has been spammed." @@ -52661,21 +59143,47 @@ "renamed": null }, { - "name": "Search labels", - "scope": "search", - "id": "labels", + "name": "Get a secret scanning alert", + "scope": "secretScanning", + "id": "getAlert", "method": "GET", - "url": "/search/labels", + "url": "/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find labels in a repository with names or descriptions that match search keywords. Returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for labels, you can get text match metadata for the label **name** and **description** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to find labels in the `linguist` repository that match `bug`, `defect`, or `enhancement`. Your query might look like this:\n\n`q=bug+defect+enhancement&repository_id=64778136`\n\nThe labels that best match the query appear first in the search results.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-labels", + "description": "Gets a single secret scanning alert detected in an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#get-a-secret-scanning-alert", "parameters": [ { - "name": "repository_id", - "description": "The id of the repository.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "in": "PATH", "type": "integer", "required": true, "enum": null, @@ -52684,13 +59192,76 @@ "validation": null, "alias": null, "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { + "code": 404, + "description": "Repository is public, or secret scanning is disabled for the repository, or the resource is not found" + }, + { "code": 503, "description": "Service unavailable" } + ], + "renamed": null + }, + { + "name": "List secret scanning alerts for an enterprise", + "scope": "secretScanning", + "id": "listAlertsForEnterprise", + "method": "GET", + "url": "/enterprises/{enterprise}/secret-scanning/alerts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists secret scanning alerts for eligible repositories in an enterprise, from newest to oldest.\nTo use this endpoint, you must be a member of the enterprise, and you must use an access token with the `repo` scope or `security_events` scope. Alerts are only returned for organizations in the enterprise for which you are an organization owner or a [security manager](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-an-enterprise", + "parameters": [ + { + "name": "enterprise", + "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null }, { - "name": "q", - "description": "The search keywords. This endpoint does not accept qualifiers in the query. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query).", + "name": "state", + "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", "in": "QUERY", "type": "string", - "required": true, + "required": false, + "enum": ["open", "resolved"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "secret_type", + "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "resolution", + "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", + "in": "QUERY", + "type": "string", + "required": false, "enum": null, "allowNull": false, "mapToData": null, @@ -52700,7 +59271,7 @@ }, { "name": "sort", - "description": "Sorts the results of your query by when the label was `created` or `updated`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", "in": "QUERY", "type": "string", "required": false, @@ -52712,12 +59283,12 @@ "deprecated": null }, { - "name": "order", - "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", + "name": "direction", + "description": "The direction to sort the results by.", "in": "QUERY", "type": "string", "required": false, - "enum": ["desc", "asc"], + "enum": ["asc", "desc"], "allowNull": false, "mapToData": null, "validation": null, @@ -52738,10 +59309,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", "in": "QUERY", - "type": "integer", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -52753,32 +59337,27 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - } + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Search repositories", - "scope": "search", - "id": "repos", + "name": "List secret scanning alerts for an organization", + "scope": "secretScanning", + "id": "listAlertsForOrg", "method": "GET", - "url": "/search/repositories", + "url": "/orgs/{org}/secret-scanning/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find repositories via various criteria. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for repositories, you can get text match metadata for the **name** and **description** fields when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to search for popular Tetris repositories written in assembly code, your query might look like this:\n\n`q=tetris+language:assembly&sort=stars&order=desc`\n\nThis query searches for repositories with the word `tetris` in the name, the description, or the README. The results are limited to repositories where the primary language is assembly. The results are sorted by stars in descending order, so that the most popular repositories appear first in the search results.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-repositories", + "description": "Lists secret scanning alerts for eligible repositories in an organization, from newest to oldest.\nTo use this endpoint, you must be an administrator or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-an-organization", "parameters": [ { - "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching for repositories](https://docs.github.com/articles/searching-for-repositories/)\" for a detailed list of qualifiers.", - "in": "QUERY", + "name": "org", + "description": "The organization name. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -52788,13 +59367,52 @@ "alias": null, "deprecated": null }, + { + "name": "state", + "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["open", "resolved"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "secret_type", + "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "resolution", + "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "sort", - "description": "Sorts the results of your query by number of `stars`, `forks`, or `help-wanted-issues` or how recently the items were `updated`. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", + "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", "in": "QUERY", "type": "string", "required": false, - "enum": ["stars", "forks", "help-wanted-issues", "updated"], + "enum": ["created", "updated"], "allowNull": false, "mapToData": null, "validation": null, @@ -52802,12 +59420,25 @@ "deprecated": null }, { - "name": "order", - "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", + "name": "direction", + "description": "The direction to sort the results by.", "in": "QUERY", "type": "string", "required": false, - "enum": ["desc", "asc"], + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -52828,10 +59459,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for events before this cursor. To receive an initial cursor on your first request, include an empty \"before\" query string.", "in": "QUERY", - "type": "integer", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for events after this cursor. To receive an initial cursor on your first request, include an empty \"after\" query string.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -52843,31 +59487,40 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." - }, + { "code": 404, "description": "Resource not found" }, { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Search topics", - "scope": "search", - "id": "topics", + "name": "List secret scanning alerts for a repository", + "scope": "secretScanning", + "id": "listAlertsForRepo", "method": "GET", - "url": "/search/topics", + "url": "/repos/{owner}/{repo}/secret-scanning/alerts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find topics via various criteria. Results are sorted by best match. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination). See \"[Searching topics](https://docs.github.com/articles/searching-topics/)\" for a detailed list of qualifiers.\n\nWhen searching for topics, you can get text match metadata for the topic's **short\\_description**, **description**, **name**, or **display\\_name** field when you pass the `text-match` media type. For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you want to search for topics related to Ruby that are featured on https://github.com/topics. Your query might look like this:\n\n`q=ruby+is:featured`\n\nThis query searches for topics with the keyword `ruby` and limits the results to find only topics that are featured. The topics that are the best match for the query appear first in the search results.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-topics", + "description": "Lists secret scanning alerts for an eligible repository, from newest to oldest.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-a-repository", "parameters": [ { - "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query).", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -52877,6 +59530,84 @@ "alias": null, "deprecated": null }, + { + "name": "state", + "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["open", "resolved"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "secret_type", + "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "resolution", + "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "sort", + "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["created", "updated"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "direction", + "description": "The direction to sort the results by.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["asc", "desc"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -52891,10 +59622,23 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "before", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for events before this cursor. To receive an initial cursor on your first request, include an empty \"before\" query string.", "in": "QUERY", - "type": "integer", + "type": "string", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "after", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for events after this cursor. To receive an initial cursor on your first request, include an empty \"after\" query string.", + "in": "QUERY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -52906,26 +59650,30 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" } + { + "code": 404, + "description": "Repository is public or secret scanning is disabled for the repository" + }, + { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Search users", - "scope": "search", - "id": "users", + "name": "List locations for a secret scanning alert", + "scope": "secretScanning", + "id": "listLocationsForAlert", "method": "GET", - "url": "/search/users", + "url": "/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Find users via various criteria. This method returns up to 100 results [per page](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#pagination).\n\nWhen searching for users, you can get text match metadata for the issue **login**, public **email**, and **name** fields when you pass the `text-match` media type. For more details about highlighting search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata). For more details about how to receive highlighted search results, see [Text match metadata](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#text-match-metadata).\n\nFor example, if you're looking for a list of popular users, you might try this query:\n\n`q=tom+repos:%3E42+followers:%3E1000`\n\nThis query searches for users with the name `tom`. The results are restricted to users with more than 42 repositories and over 1,000 followers.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/search#search-users", + "description": "Lists all locations for a given secret scanning alert for an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-locations-for-a-secret-scanning-alert", "parameters": [ { - "name": "q", - "description": "The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search to specific areas of GitHub Enterprise Cloud. The REST API supports the same qualifiers as the web interface for GitHub Enterprise Cloud. To learn more about the format of the query, see [Constructing a search query](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#constructing-a-search-query). See \"[Searching users](https://docs.github.com/enterprise-cloud@latest//search-github/searching-on-github/searching-users)\" for a detailed list of qualifiers.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", "required": true, "enum": null, @@ -52936,12 +59684,12 @@ "deprecated": null }, { - "name": "sort", - "description": "Sorts the results of your query by number of `followers` or `repositories`, or when the person `joined` GitHub Enterprise Cloud. Default: [best match](https://docs.github.com/enterprise-cloud@latest//rest/reference/search#ranking-search-results)", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["followers", "repositories", "joined"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -52949,12 +59697,12 @@ "deprecated": null }, { - "name": "order", - "description": "Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["desc", "asc"], + "name": "alert_number", + "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "in": "PATH", + "type": "integer", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -52962,8 +59710,8 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "page", + "description": "Page number of the results to fetch.", "in": "QUERY", "type": "integer", "required": false, @@ -52975,8 +59723,8 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", + "name": "per_page", + "description": "The number of results per page (max 100).", "in": "QUERY", "type": "integer", "required": false, @@ -52990,26 +59738,25 @@ ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, { - "code": 422, - "description": "Validation failed, or the endpoint has been spammed." + "code": 404, + "description": "Repository is public, or secret scanning is disabled for the repository, or the resource is not found" }, { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "Get a secret scanning alert", + "name": "Update a secret scanning alert", "scope": "secretScanning", - "id": "getAlert", - "method": "GET", + "id": "updateAlert", + "method": "PATCH", "url": "/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a single secret scanning alert detected in an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#get-a-secret-scanning-alert", + "description": "Updates the status of a secret scanning alert in an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` write permission to use this endpoint.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#update-a-secret-scanning-alert", "parameters": [ { "name": "owner", @@ -53026,7 +59773,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -53049,34 +59796,80 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "state", + "description": "Sets the state of the secret scanning alert. You must provide `resolution` when you set the state to `resolved`.", + "in": "BODY", + "type": "string", + "required": true, + "enum": ["open", "resolved"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "resolution", + "description": "**Required when the `state` is `resolved`.** The reason for resolving the alert.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["false_positive", "wont_fix", "revoked", "used_in_tests"], + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "resolution_comment", + "description": "An optional comment when closing an alert. Cannot be updated or deleted. Must be `null` when changing `state` to `open`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, + { + "code": 400, + "description": "Bad request, resolution comment is invalid or the resolution was not changed." + }, { "code": 404, "description": "Repository is public, or secret scanning is disabled for the repository, or the resource is not found" }, + { + "code": 422, + "description": "State does not match the resolution or resolution comment" + }, { "code": 503, "description": "Service unavailable" } ], "renamed": null }, { - "name": "List secret scanning alerts for an enterprise", - "scope": "secretScanning", - "id": "listAlertsForEnterprise", - "method": "GET", - "url": "/enterprises/{enterprise}/secret-scanning/alerts", + "name": "Privately report a security vulnerability", + "scope": "securityAdvisories", + "id": "createPrivateVulnerabilityReport", + "method": "POST", + "url": "/repos/{owner}/{repo}/security-advisories/reports", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists secret scanning alerts for eligible repositories in an enterprise, from newest to oldest.\nTo use this endpoint, you must be a member of the enterprise, and you must use an access token with the `repo` scope or `security_events` scope. Alerts are only returned for organizations in the enterprise for which you are an organization owner or a [security manager](https://docs.github.com/enterprise-cloud@latest//organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-an-enterprise", + "description": "Report a security vulnerability to the maintainers of the repository.\nSee \"[Privately reporting a security vulnerability](https://docs.github.com/enterprise-cloud@latest//code-security/security-advisories/guidance-on-reporting-and-writing/privately-reporting-a-security-vulnerability)\" for more information about private vulnerability reporting.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/security-advisories/repository-advisories#privately-report-a-security-vulnerability", "parameters": [ { - "name": "enterprise", - "description": "The slug version of the enterprise name. You can also substitute this value with the enterprise id.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -53088,12 +59881,12 @@ "deprecated": null }, { - "name": "state", - "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "resolved"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53101,11 +59894,11 @@ "deprecated": null }, { - "name": "secret_type", - "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", - "in": "QUERY", + "name": "summary", + "description": "A short summary of the advisory.", + "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -53114,12 +59907,38 @@ "deprecated": null }, { - "name": "resolution", - "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", - "in": "QUERY", + "name": "description", + "description": "A detailed description of what the advisory impacts.", + "in": "BODY", "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities", + "description": "An array of products affected by the vulnerability detailed in a repository security advisory.", + "in": "BODY", + "type": "object[]", "required": false, "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].package", + "description": "The name of the package affected by the vulnerability.", + "in": "BODY", + "type": "object", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53127,12 +59946,25 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", - "in": "QUERY", + "name": "vulnerabilities[].package.ecosystem", + "description": "The package's language or package management ecosystem.", + "in": "BODY", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": [ + "rubygems", + "npm", + "pip", + "maven", + "nuget", + "composer", + "go", + "rust", + "erlang", + "actions", + "pub", + "other" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -53140,52 +59972,91 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", + "name": "vulnerabilities[].package.name", + "description": "The unique package name within its ecosystem.", + "in": "BODY", "type": "string", "required": false, - "enum": ["asc", "desc"], - "allowNull": false, + "enum": null, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "vulnerabilities[].vulnerable_version_range", + "description": "The range of the package versions affected by the vulnerability.", + "in": "BODY", + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "before", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor.", - "in": "QUERY", + "name": "vulnerabilities[].patched_versions", + "description": "The package version(s) that resolve the vulnerability.", + "in": "BODY", "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "after", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor.", - "in": "QUERY", + "name": "vulnerabilities[].vulnerable_functions", + "description": "The functions in the package that are affected.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cwe_ids", + "description": "A list of Common Weakness Enumeration (CWE) IDs.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "severity", + "description": "The severity of the advisory. You must choose between setting this field or `cvss_vector_string`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["critical", "high", "medium", "low"], + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cvss_vector_string", + "description": "The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`.", + "in": "BODY", "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, @@ -53193,27 +60064,31 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List secret scanning alerts for an organization", - "scope": "secretScanning", - "id": "listAlertsForOrg", - "method": "GET", - "url": "/orgs/{org}/secret-scanning/alerts", + "name": "Create a repository security advisory", + "scope": "securityAdvisories", + "id": "createRepositoryAdvisory", + "method": "POST", + "url": "/repos/{owner}/{repo}/security-advisories", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists secret scanning alerts for eligible repositories in an organization, from newest to oldest.\nTo use this endpoint, you must be an administrator or security manager for the organization, and you must use an access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-an-organization", + "description": "Creates a new repository security advisory.\nYou must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint.\n\nIn order to create a draft repository security advisory, you must be a security manager or administrator of that repository.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/security-advisories/repository-advisories#create-a-repository-security-advisory", "parameters": [ { - "name": "org", - "description": "The organization name. The name is not case sensitive.", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -53225,12 +60100,12 @@ "deprecated": null }, { - "name": "state", - "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["open", "resolved"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53238,11 +60113,11 @@ "deprecated": null }, { - "name": "secret_type", - "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", - "in": "QUERY", + "name": "summary", + "description": "A short summary of the advisory.", + "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -53251,11 +60126,11 @@ "deprecated": null }, { - "name": "resolution", - "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", - "in": "QUERY", + "name": "description", + "description": "A detailed description of what the advisory impacts.", + "in": "BODY", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -53264,12 +60139,25 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", - "in": "QUERY", + "name": "cve_id", + "description": "The Common Vulnerabilities and Exposures (CVE) ID.", + "in": "BODY", "type": "string", "required": false, - "enum": ["created", "updated"], + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities", + "description": "A product affected by the vulnerability detailed in a repository security advisory.", + "in": "BODY", + "type": "object[]", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53277,12 +60165,38 @@ "deprecated": null }, { - "name": "direction", - "description": "The direction to sort the results by.", - "in": "QUERY", + "name": "vulnerabilities[].package", + "description": "The name of the package affected by the vulnerability.", + "in": "BODY", + "type": "object", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].package.ecosystem", + "description": "The package's language or package management ecosystem.", + "in": "BODY", "type": "string", - "required": false, - "enum": ["asc", "desc"], + "required": true, + "enum": [ + "rubygems", + "npm", + "pip", + "maven", + "nuget", + "composer", + "go", + "rust", + "erlang", + "actions", + "pub", + "other" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -53290,38 +60204,90 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "vulnerabilities[].package.name", + "description": "The unique package name within its ecosystem.", + "in": "BODY", + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "vulnerabilities[].vulnerable_version_range", + "description": "The range of the package versions affected by the vulnerability.", + "in": "BODY", + "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, "deprecated": null }, { - "name": "before", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor. To receive an initial cursor on your first request, include an empty \"before\" query string.", - "in": "QUERY", + "name": "vulnerabilities[].patched_versions", + "description": "The package version(s) that resolve the vulnerability.", + "in": "BODY", "type": "string", "required": false, "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].vulnerable_functions", + "description": "The functions in the package that are affected.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cwe_ids", + "description": "A list of Common Weakness Enumeration (CWE) IDs.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "credits", + "description": "A list of users receiving credit for their participation in the security advisory.", + "in": "BODY", + "type": "object[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "credits[].login", + "description": "The username of the user credited.", + "in": "BODY", + "type": "string", + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53329,13 +60295,50 @@ "deprecated": null }, { - "name": "after", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor. To receive an initial cursor on your first request, include an empty \"after\" query string.", - "in": "QUERY", + "name": "credits[].type", + "description": "The type of credit the user is receiving.", + "in": "BODY", + "type": "string", + "required": true, + "enum": [ + "analyst", + "finder", + "reporter", + "coordinator", + "remediation_developer", + "remediation_reviewer", + "remediation_verifier", + "tool", + "sponsor", + "other" + ], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "severity", + "description": "The severity of the advisory. You must choose between setting this field or `cvss_vector_string`.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["critical", "high", "medium", "low"], + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cvss_vector_string", + "description": "The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`.", + "in": "BODY", "type": "string", "required": false, "enum": null, - "allowNull": false, + "allowNull": true, "mapToData": null, "validation": null, "alias": null, @@ -53343,23 +60346,27 @@ } ], "responses": [ - { "code": 200, "description": "Response" }, + { "code": 201, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, { "code": 404, "description": "Resource not found" }, - { "code": 503, "description": "Service unavailable" } + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, { - "name": "List secret scanning alerts for a repository", - "scope": "secretScanning", - "id": "listAlertsForRepo", + "name": "Get a repository security advisory", + "scope": "securityAdvisories", + "id": "getRepositoryAdvisory", "method": "GET", - "url": "/repos/{owner}/{repo}/secret-scanning/alerts", + "url": "/repos/{owner}/{repo}/security-advisories/{ghsa_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists secret scanning alerts for an eligible repository, from newest to oldest.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-secret-scanning-alerts-for-a-repository", + "description": "Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier.\nYou can access any published security advisory on a public repository.\nYou must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission\nin order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to.\n\nYou can access an unpublished security advisory from a repository if you are a security manager or administrator of that repository, or if you are a\ncollaborator on the security advisory.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/security-advisories/repository-advisories#get-a-repository-security-advisory", "parameters": [ { "name": "owner", @@ -53376,7 +60383,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -53388,37 +60395,44 @@ "deprecated": null }, { - "name": "state", - "description": "Set to `open` or `resolved` to only list secret scanning alerts in a specific state.", - "in": "QUERY", - "type": "string", - "required": false, - "enum": ["open", "resolved"], - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "secret_type", - "description": "A comma-separated list of secret types to return. By default all secret types are returned.\nSee \"[Secret scanning patterns](https://docs.github.com/enterprise-cloud@latest//code-security/secret-scanning/secret-scanning-patterns#supported-secrets-for-advanced-security)\"\nfor a complete list of secret types.", - "in": "QUERY", + "name": "ghsa_id", + "description": "The GHSA (GitHub Security Advisory) identifier of the advisory.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - }, + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], + "renamed": null + }, + { + "name": "List repository security advisories", + "scope": "securityAdvisories", + "id": "listRepositoryAdvisories", + "method": "GET", + "url": "/repos/{owner}/{repo}/security-advisories", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists security advisories in a repository.\nYou must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission\nin order to get published security advisories in a private repository, or any unpublished security advisories that you have access to.\n\nYou can access unpublished security advisories from a repository if you are a security manager or administrator of that repository, or if you are a collaborator on any security advisory.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/security-advisories/repository-advisories#list-repository-security-advisories", + "parameters": [ { - "name": "resolution", - "description": "A comma-separated list of resolutions. Only secret scanning alerts with one of these resolutions are listed. Valid resolutions are `false_positive`, `wont_fix`, `revoked`, `pattern_edited`, `pattern_deleted` or `used_in_tests`.", - "in": "QUERY", + "name": "owner", + "description": "The account owner of the repository. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, + "required": true, "enum": null, "allowNull": false, "mapToData": null, @@ -53427,12 +60441,12 @@ "deprecated": null }, { - "name": "sort", - "description": "The property to sort the results by. `created` means when the alert was created. `updated` means when the alert was updated or resolved.", - "in": "QUERY", + "name": "repo", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", + "in": "PATH", "type": "string", - "required": false, - "enum": ["created", "updated"], + "required": true, + "enum": null, "allowNull": false, "mapToData": null, "validation": null, @@ -53453,25 +60467,12 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", + "name": "sort", + "description": "The property to sort the results by.", "in": "QUERY", - "type": "integer", + "type": "string", "required": false, - "enum": null, + "enum": ["created", "updated", "published"], "allowNull": false, "mapToData": null, "validation": null, @@ -53480,7 +60481,7 @@ }, { "name": "before", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events before this cursor. To receive an initial cursor on your first request, include an empty \"before\" query string.", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor.", "in": "QUERY", "type": "string", "required": false, @@ -53493,7 +60494,7 @@ }, { "name": "after", - "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header). If specified, the query only searches for events after this cursor. To receive an initial cursor on your first request, include an empty \"after\" query string.", + "description": "A cursor, as given in the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor.", "in": "QUERY", "type": "string", "required": false, @@ -53503,29 +60504,53 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "per_page", + "description": "Number of advisories to return per page.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "state", + "description": "Filter by state of the repository advisories. Only advisories of this state will be returned.", + "in": "QUERY", + "type": "string", + "required": false, + "enum": ["triage", "draft", "published", "closed"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 404, - "description": "Repository is public or secret scanning is disabled for the repository" - }, - { "code": 503, "description": "Service unavailable" } + { "code": 400, "description": "Bad Request" }, + { "code": 400, "description": "Bad Request" }, + { "code": 404, "description": "Resource not found" } ], "renamed": null }, { - "name": "List locations for a secret scanning alert", - "scope": "secretScanning", - "id": "listLocationsForAlert", - "method": "GET", - "url": "/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}/locations", + "name": "Update a repository security advisory", + "scope": "securityAdvisories", + "id": "updateRepositoryAdvisory", + "method": "PATCH", + "url": "/repos/{owner}/{repo}/security-advisories/{ghsa_id}", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all locations for a given secret scanning alert for an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` read permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#list-locations-for-a-secret-scanning-alert", + "description": "Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier.\nYou must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint.\n\nIn order to update any security advisory, you must be a security manager or administrator of that repository,\nor a collaborator on the repository security advisory.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/security-advisories/repository-advisories#update-a-repository-security-advisory", "parameters": [ { "name": "owner", @@ -53542,7 +60567,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -53554,10 +60579,10 @@ "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", + "name": "ghsa_id", + "description": "The GHSA (GitHub Security Advisory) identifier of the advisory.", "in": "PATH", - "type": "integer", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -53567,10 +60592,10 @@ "deprecated": null }, { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", + "name": "summary", + "description": "A short summary of the advisory.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -53580,10 +60605,10 @@ "deprecated": null }, { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", + "name": "description", + "description": "A detailed description of what the advisory impacts.", + "in": "BODY", + "type": "string", "required": false, "enum": null, "allowNull": false, @@ -53591,35 +60616,38 @@ "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { - "code": 404, - "description": "Repository is public, or secret scanning is disabled for the repository, or the resource is not found" }, - { "code": 503, "description": "Service unavailable" } - ], - "renamed": null - }, - { - "name": "Update a secret scanning alert", - "scope": "secretScanning", - "id": "updateAlert", - "method": "PATCH", - "url": "/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Updates the status of a secret scanning alert in an eligible repository.\nTo use this endpoint, you must be an administrator for the repository or for the organization that owns the repository, and you must use a personal access token with the `repo` scope or `security_events` scope.\nFor public repositories, you may instead use the `public_repo` scope.\n\nGitHub Apps must have the `secret_scanning_alerts` write permission to use this endpoint.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/secret-scanning#update-a-secret-scanning-alert", - "parameters": [ { - "name": "owner", - "description": "The account owner of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "cve_id", + "description": "The Common Vulnerabilities and Exposures (CVE) ID.", + "in": "BODY", "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities", + "description": "A product affected by the vulnerability detailed in a repository security advisory.", + "in": "BODY", + "type": "object[]", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].package", + "description": "The name of the package affected by the vulnerability.", + "in": "BODY", + "type": "object", "required": true, "enum": null, "allowNull": false, @@ -53629,12 +60657,25 @@ "deprecated": null }, { - "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", - "in": "PATH", + "name": "vulnerabilities[].package.ecosystem", + "description": "The package's language or package management ecosystem.", + "in": "BODY", "type": "string", "required": true, - "enum": null, + "enum": [ + "rubygems", + "npm", + "pip", + "maven", + "nuget", + "composer", + "go", + "rust", + "erlang", + "actions", + "pub", + "other" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -53642,10 +60683,88 @@ "deprecated": null }, { - "name": "alert_number", - "description": "The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.", - "in": "PATH", - "type": "integer", + "name": "vulnerabilities[].package.name", + "description": "The unique package name within its ecosystem.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].vulnerable_version_range", + "description": "The range of the package versions affected by the vulnerability.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].patched_versions", + "description": "The package version(s) that resolve the vulnerability.", + "in": "BODY", + "type": "string", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "vulnerabilities[].vulnerable_functions", + "description": "The functions in the package that are affected.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "cwe_ids", + "description": "A list of Common Weakness Enumeration (CWE) IDs.", + "in": "BODY", + "type": "string[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "credits", + "description": "A list of users receiving credit for their participation in the security advisory.", + "in": "BODY", + "type": "object[]", + "required": false, + "enum": null, + "allowNull": true, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "credits[].login", + "description": "The username of the user credited.", + "in": "BODY", + "type": "string", "required": true, "enum": null, "allowNull": false, @@ -53655,12 +60774,23 @@ "deprecated": null }, { - "name": "state", - "description": "Sets the state of the secret scanning alert. You must provide `resolution` when you set the state to `resolved`.", + "name": "credits[].type", + "description": "The type of credit the user is receiving.", "in": "BODY", "type": "string", "required": true, - "enum": ["open", "resolved"], + "enum": [ + "analyst", + "finder", + "reporter", + "coordinator", + "remediation_developer", + "remediation_reviewer", + "remediation_verifier", + "tool", + "sponsor", + "other" + ], "allowNull": false, "mapToData": null, "validation": null, @@ -53668,18 +60798,12 @@ "deprecated": null }, { - "name": "resolution", - "description": "**Required when the `state` is `resolved`.** The reason for resolving the alert.", + "name": "severity", + "description": "The severity of the advisory. You must choose between setting this field or `cvss_vector_string`.", "in": "BODY", "type": "string", "required": false, - "enum": [ - null, - "false_positive", - "wont_fix", - "revoked", - "used_in_tests" - ], + "enum": ["critical", "high", "medium", "low"], "allowNull": true, "mapToData": null, "validation": null, @@ -53687,8 +60811,8 @@ "deprecated": null }, { - "name": "resolution_comment", - "description": "Sets an optional comment when closing an alert. Must be null when changing `state` to `open`.", + "name": "cvss_vector_string", + "description": "The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`.", "in": "BODY", "type": "string", "required": false, @@ -53698,23 +60822,29 @@ "validation": null, "alias": null, "deprecated": null + }, + { + "name": "state", + "description": "The state of the advisory.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["published", "closed", "draft"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null } ], "responses": [ { "code": 200, "description": "Response" }, - { - "code": 400, - "description": "Bad request, resolution comment is invalid or the resolution was not changed." - }, - { - "code": 404, - "description": "Repository is public, or secret scanning is disabled for the repository, or the resource is not found" - }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, { "code": 422, - "description": "State does not match the resolution or resolution comment" - }, - { "code": 503, "description": "Service unavailable" } + "description": "Validation failed, or the endpoint has been spammed." + } ], "renamed": null }, @@ -53727,7 +60857,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "The \"Add team member\" endpoint (described below) is deprecated.\n\nWe recommend using the [Add or update team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user) endpoint instead. It allows you to invite new organization members to your teams.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo add someone to a team, the authenticated user must be an organization owner or a team maintainer in the team they're changing. The person being added to the team must be a member of the team's organization.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nNote that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", + "description": "The \"Add team member\" endpoint (described below) is deprecated.\n\nWe recommend using the [Add or update team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user) endpoint instead. It allows you to invite new organization members to your teams.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo add someone to a team, the authenticated user must be an organization owner or a team maintainer in the team they're changing. The person being added to the team must be a member of the team's organization.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nNote that you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-team-member-legacy", "parameters": [ { @@ -53780,7 +60910,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Team synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nAdds an organization member to a team. An authenticated organization owner or team maintainer can add organization members to a team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nAn organization owner can add someone who is not part of the team's organization to a team. When an organization owner adds someone to a team who is not an organization member, this endpoint will send an invitation to the person via email. This newly-created membership will be in the \"pending\" state until the person accepts the invitation, at which point the membership will transition to the \"active\" state and the user will be added as a member of the team.\n\nIf the user is already a member of the team, this endpoint will update the role of the team member's role. To update the membership of a team member, the authenticated user must be an organization owner or a team maintainer.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PUT /organizations/{org_id}/team/{team_id}/memberships/{username}`.", + "description": "Adds an organization member to a team. An authenticated organization owner or team maintainer can add organization members to a team.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nAn organization owner can add someone who is not part of the team's organization to a team. When an organization owner adds someone to a team who is not an organization member, this endpoint will send an invitation to the person via email. This newly-created membership will be in the \"pending\" state until the person accepts the invitation, at which point the membership will transition to the \"active\" state and the user will be added as a member of the team.\n\nIf the user is already a member of the team, this endpoint will update the role of the team member's role. To update the membership of a team member, the authenticated user must be an organization owner or a team maintainer.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PUT /organizations/{org_id}/team/{team_id}/memberships/{username}`.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user", "parameters": [ { @@ -53858,7 +60988,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Add or update team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user) endpoint.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nIf the user is already a member of the team's organization, this endpoint will add the user to the team. To add a membership between an organization member and a team, the authenticated user must be an organization owner or a team maintainer.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nIf the user is unaffiliated with the team's organization, this endpoint will send an invitation to the user via email. This newly-created membership will be in the \"pending\" state until the user accepts the invitation, at which point the membership will transition to the \"active\" state and the user will be added as a member of the team. To add a membership between an unaffiliated user and a team, the authenticated user must be an organization owner.\n\nIf the user is already a member of the team, this endpoint will update the role of the team member's role. To update the membership of a team member, the authenticated user must be an organization owner or a team maintainer.", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Add or update team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user) endpoint.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nIf the user is already a member of the team's organization, this endpoint will add the user to the team. To add a membership between an organization member and a team, the authenticated user must be an organization owner or a team maintainer.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\nIf the user is unaffiliated with the team's organization, this endpoint will send an invitation to the user via email. This newly-created membership will be in the \"pending\" state until the user accepts the invitation, at which point the membership will transition to the \"active\" state and the user will be added as a member of the team. To add a membership between an unaffiliated user and a team, the authenticated user must be an organization owner.\n\nIf the user is already a member of the team, this endpoint will update the role of the team member's role. To update the membership of a team member, the authenticated user must be an organization owner or a team maintainer.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-membership-for-a-user-legacy", "parameters": [ { @@ -54064,7 +61194,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "To add a repository to a team or update the team's permission on a repository, the authenticated user must have admin access to the repository, and must be able to see the team. The repository must be owned by the organization, or a direct fork of a repository owned by the organization. You will get a `422 Unprocessable Entity` status if you attempt to add a repository to a team that is not owned by the organization. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PUT /organizations/{org_id}/team/{team_id}/repos/{owner}/{repo}`.\n\nFor more information about the permission levels, see \"[Repository permission levels for an organization](https://docs.github.com/en/github/setting-up-and-managing-organizations-and-teams/repository-permission-levels-for-an-organization#permission-levels-for-repositories-owned-by-an-organization)\".", + "description": "To add a repository to a team or update the team's permission on a repository, the authenticated user must have admin access to the repository, and must be able to see the team. The repository must be owned by the organization, or a direct fork of a repository owned by the organization. You will get a `422 Unprocessable Entity` status if you attempt to add a repository to a team that is not owned by the organization. Note that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `PUT /organizations/{org_id}/team/{team_id}/repos/{owner}/{repo}`.\n\nFor more information about the permission levels, see \"[Repository permission levels for an organization](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/repository-permission-levels-for-an-organization#permission-levels-for-repositories-owned-by-an-organization)\".", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams/#add-or-update-team-repository-permissions", "parameters": [ { @@ -54108,7 +61238,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -54146,7 +61276,7 @@ "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new \"[Add or update team repository permissions](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-repository-permissions)\" endpoint.\n\nTo add a repository to a team or update the team's permission on a repository, the authenticated user must have admin access to the repository, and must be able to see the team. The repository must be owned by the organization, or a direct fork of a repository owned by the organization. You will get a `422 Unprocessable Entity` status if you attempt to add a repository to a team that is not owned by the organization.\n\nNote that, if you choose not to pass any parameters, you'll need to set `Content-Length` to zero when calling out to this endpoint. For more information, see \"[HTTP verbs](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#http-verbs).\"", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams/#add-or-update-team-repository-permissions-legacy", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#add-or-update-team-repository-permissions-legacy", "parameters": [ { "name": "team_id", @@ -54176,7 +61306,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -54373,7 +61503,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -54441,7 +61571,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -54478,7 +61608,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "To create a team, the authenticated user must be a member or owner of `{org}`. By default, organization members can create teams. Organization owners can limit team creation to organization owners. For more information, see \"[Setting team creation permissions](https://docs.github.com/en/articles/setting-team-creation-permissions-in-your-organization).\"\n\nWhen you create a new team, you automatically become a team maintainer without explicitly adding yourself to the optional array of `maintainers`. For more information, see \"[About teams](https://docs.github.com/en/github/setting-up-and-managing-organizations-and-teams/about-teams)\".", + "description": "To create a team, the authenticated user must be a member or owner of `{org}`. By default, organization members can create teams. Organization owners can limit team creation to organization owners. For more information, see \"[Setting team creation permissions](https://docs.github.com/enterprise-cloud@latest//articles/setting-team-creation-permissions-in-your-organization).\"\n\nWhen you create a new team, you automatically become a team maintainer without explicitly adding yourself to the optional array of `maintainers`. For more information, see \"[About teams](https://docs.github.com/enterprise-cloud@latest//github/setting-up-and-managing-organizations-and-teams/about-teams)\".", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-team", "parameters": [ { @@ -54548,7 +61678,7 @@ }, { "name": "privacy", - "description": "The level of privacy this team should have. The options are: \n**For a non-nested team:** \n\\* `secret` - only visible to organization owners and members of this team. \n\\* `closed` - visible to all members of this organization. \nDefault: `secret` \n**For a parent or child team:** \n\\* `closed` - visible to all members of this organization. \nDefault for child team: `closed`", + "description": "The level of privacy this team should have. The options are: \n**For a non-nested team:** \n * `secret` - only visible to organization owners and members of this team. \n * `closed` - visible to all members of this organization. \nDefault: `secret` \n**For a parent or child team:** \n * `closed` - visible to all members of this organization. \nDefault for child team: `closed`", "in": "BODY", "type": "string", "required": false, @@ -54559,6 +61689,19 @@ "alias": null, "deprecated": null }, + { + "name": "notification_setting", + "description": "The notification setting the team has chosen. The options are: \n * `notifications_enabled` - team members receive notifications when the team is @mentioned. \n * `notifications_disabled` - no one receives notifications. \nDefault: `notifications_enabled`", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["notifications_enabled", "notifications_disabled"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "permission", "description": "**Deprecated**. The permission that new repositories will be added to the team with when none is specified.", @@ -54605,7 +61748,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new comment on a team discussion. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments`.", + "description": "Creates a new comment on a team discussion. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/{org_id}/team/{team_id}/discussions/{discussion_number}/comments`.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion-comment", "parameters": [ { @@ -54673,7 +61816,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Create a discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion-comment) endpoint.\n\nCreates a new comment on a team discussion. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Create a discussion comment](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion-comment) endpoint.\n\nCreates a new comment on a team discussion. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion-comment-legacy", "parameters": [ { @@ -54728,7 +61871,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Creates a new discussion post on a team's page. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/{org_id}/team/{team_id}/discussions`.", + "description": "Creates a new discussion post on a team's page. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `POST /organizations/{org_id}/team/{team_id}/discussions`.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion", "parameters": [ { @@ -54809,7 +61952,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`Create a discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion) endpoint.\n\nCreates a new discussion post on a team's page. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/en/github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [`Create a discussion`](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion) endpoint.\n\nCreates a new discussion post on a team's page. OAuth access tokens require the `write:discussion` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).\n\nThis endpoint triggers [notifications](https://docs.github.com/enterprise-cloud@latest//github/managing-subscriptions-and-notifications-on-github/about-notifications). Creating content too quickly using this endpoint may result in secondary rate limiting. See \"[Secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#secondary-rate-limits)\" and \"[Dealing with secondary rate limits](https://docs.github.com/enterprise-cloud@latest//rest/guides/best-practices-for-integrators#dealing-with-secondary-rate-limits)\" for details.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#create-a-discussion-legacy", "parameters": [ { @@ -55175,7 +62318,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Gets a team using the team's `slug`. GitHub Enterprise Cloud generates the `slug` from the team `name`.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/{org_id}/team/{team_id}`.", + "description": "Gets a team using the team's `slug`. To create the `slug`, GitHub Enterprise Cloud replaces special characters in the `name` string, changes all words to lowercase, and replaces spaces with a `-` separator. For example, `\"My TEam Näme\"` would become `my-team-name`.\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `GET /organizations/{org_id}/team/{team_id}`.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#get-a-team-by-name", "parameters": [ { @@ -56146,7 +63289,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "List all of the teams across all of the organizations to which the authenticated user belongs. This method requires `user`, `repo`, or `read:org` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/) when authenticating via [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/).", + "description": "List all of the teams across all of the organizations to which the authenticated user belongs. This method requires `user`, `repo`, or `read:org` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/) when authenticating via [OAuth](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/). When using a fine-grained personal access token, the resource owner of the token [must be a single organization](https://docs.github.com/enterprise-cloud@latest//authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token#fine-grained-personal-access-tokens), and have at least read-only member organization permissions. The response payload only contains the teams from a single organization when using a fine-grained personal access token.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#list-teams-for-the-authenticated-user", "parameters": [ { @@ -56720,7 +63863,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "The \"Remove team member\" endpoint (described below) is deprecated.\n\nWe recommend using the [Remove team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user) endpoint instead. It allows you to remove both active and pending memberships.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo remove a team member, the authenticated user must have 'admin' permissions to the team or be an owner of the org that the team is associated with. Removing a team member does not delete the user, it just removes them from the team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"", + "description": "The \"Remove team member\" endpoint (described below) is deprecated.\n\nWe recommend using the [Remove team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user) endpoint instead. It allows you to remove both active and pending memberships.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo remove a team member, the authenticated user must have 'admin' permissions to the team or be an owner of the org that the team is associated with. Removing a team member does not delete the user, it just removes them from the team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-member-legacy", "parameters": [ { @@ -56768,7 +63911,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Team synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo remove a membership between a user and a team, the authenticated user must have 'admin' permissions to the team or be an owner of the organization that the team is associated with. Removing team membership does not delete the user, it just removes their membership from the team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `DELETE /organizations/{org_id}/team/{team_id}/memberships/{username}`.", + "description": "To remove a membership between a user and a team, the authenticated user must have 'admin' permissions to the team or be an owner of the organization that the team is associated with. Removing team membership does not delete the user, it just removes their membership from the team.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"\n\n**Note:** You can also specify a team by `org_id` and `team_id` using the route `DELETE /organizations/{org_id}/team/{team_id}/memberships/{username}`.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user", "parameters": [ { @@ -56829,7 +63972,7 @@ "isDeprecated": true, "deprecationDate": "2020-01-21", "removalDate": "2021-02-01", - "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Remove team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user) endpoint.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo remove a membership between a user and a team, the authenticated user must have 'admin' permissions to the team or be an owner of the organization that the team is associated with. Removing team membership does not delete the user, it just removes their membership from the team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/articles/synchronizing-teams-between-your-identity-provider-and-github/).\"", + "description": "**Deprecation Notice:** This endpoint route is deprecated and will be removed from the Teams API. We recommend migrating your existing code to use the new [Remove team membership for a user](https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user) endpoint.\n\nTeam synchronization is available for organizations using GitHub Enterprise Cloud. For more information, see [GitHub's products](https://docs.github.com/enterprise-cloud@latest//github/getting-started-with-github/githubs-products) in the GitHub Help documentation.\n\nTo remove a membership between a user and a team, the authenticated user must have 'admin' permissions to the team or be an owner of the organization that the team is associated with. Removing team membership does not delete the user, it just removes their membership from the team.\n\n**Note:** When you have team synchronization set up for a team with your organization's identity provider (IdP), you will see an error if you attempt to use the API for making changes to the team's membership. If you have access to manage group membership in your IdP, you can manage GitHub Enterprise Cloud team membership through your identity provider, which automatically adds and removes team members in an organization. For more information, see \"[Synchronizing teams between your identity provider and GitHub Enterprise Cloud](https://docs.github.com/enterprise-cloud@latest//articles/synchronizing-teams-between-your-identity-provider-and-github/).\"", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/teams#remove-team-membership-for-a-user-legacy", "parameters": [ { @@ -57022,7 +64165,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -57077,7 +64220,7 @@ }, { "name": "repo", - "description": "The name of the repository. The name is not case sensitive.", + "description": "The name of the repository without the `.git` extension. The name is not case sensitive.", "in": "PATH", "type": "string", "required": true, @@ -57456,7 +64599,7 @@ }, { "name": "privacy", - "description": "The level of privacy this team should have. Editing teams without specifying this parameter leaves `privacy` intact. When a team is nested, the `privacy` for parent teams cannot be `secret`. The options are: \n**For a non-nested team:** \n\\* `secret` - only visible to organization owners and members of this team. \n\\* `closed` - visible to all members of this organization. \n**For a parent or child team:** \n\\* `closed` - visible to all members of this organization.", + "description": "The level of privacy this team should have. Editing teams without specifying this parameter leaves `privacy` intact. When a team is nested, the `privacy` for parent teams cannot be `secret`. The options are: \n**For a non-nested team:** \n * `secret` - only visible to organization owners and members of this team. \n * `closed` - visible to all members of this organization. \n**For a parent or child team:** \n * `closed` - visible to all members of this organization.", "in": "BODY", "type": "string", "required": false, @@ -57467,6 +64610,19 @@ "alias": null, "deprecated": null }, + { + "name": "notification_setting", + "description": "The notification setting the team has chosen. Editing teams without specifying this parameter leaves `notification_setting` intact. The options are: \n * `notifications_enabled` - team members receive notifications when the team is @mentioned. \n * `notifications_disabled` - no one receives notifications.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["notifications_enabled", "notifications_disabled"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "permission", "description": "**Deprecated**. The permission that new repositories will be added to the team with when none is specified.", @@ -57562,7 +64718,7 @@ }, { "name": "privacy", - "description": "The level of privacy this team should have. Editing teams without specifying this parameter leaves `privacy` intact. The options are: \n**For a non-nested team:** \n\\* `secret` - only visible to organization owners and members of this team. \n\\* `closed` - visible to all members of this organization. \n**For a parent or child team:** \n\\* `closed` - visible to all members of this organization.", + "description": "The level of privacy this team should have. Editing teams without specifying this parameter leaves `privacy` intact. The options are: \n**For a non-nested team:** \n * `secret` - only visible to organization owners and members of this team. \n * `closed` - visible to all members of this organization. \n**For a parent or child team:** \n * `closed` - visible to all members of this organization.", "in": "BODY", "type": "string", "required": false, @@ -57573,6 +64729,19 @@ "alias": null, "deprecated": null }, + { + "name": "notification_setting", + "description": "The notification setting the team has chosen. Editing teams without specifying this parameter leaves `notification_setting` intact. The options are: \n * `notifications_enabled` - team members receive notifications when the team is @mentioned. \n * `notifications_disabled` - no one receives notifications.", + "in": "BODY", + "type": "string", + "required": false, + "enum": ["notifications_enabled", "notifications_disabled"], + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, { "name": "permission", "description": "**Deprecated**. The permission that new repositories will be added to the team with when none is specified.", @@ -57698,6 +64867,45 @@ ], "renamed": null }, + { + "name": "Add social accounts for the authenticated user", + "scope": "users", + "id": "addSocialAccountForAuthenticatedUser", + "method": "POST", + "url": "/user/social_accounts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Add one or more social accounts to the authenticated user's profile. This endpoint is accessible with the `user` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/users/social-accounts#add-social-account-for-authenticated-user", + "parameters": [ + { + "name": "account_urls", + "description": "Full URLs for the social media profiles to add.", + "in": "BODY", + "type": "string[]", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 201, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, { "name": "Block a user", "scope": "users", @@ -58384,6 +65592,45 @@ ], "renamed": null }, + { + "name": "Delete social accounts for the authenticated user", + "scope": "users", + "id": "deleteSocialAccountForAuthenticatedUser", + "method": "DELETE", + "url": "/user/social_accounts", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Deletes one or more social accounts from the authenticated user's profile. This endpoint is accessible with the `user` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/users/social-accounts#delete-social-account-for-authenticated-user", + "parameters": [ + { + "name": "account_urls", + "description": "Full URLs for the social media profiles to delete.", + "in": "BODY", + "type": "string[]", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 204, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" }, + { + "code": 422, + "description": "Validation failed, or the endpoint has been spammed." + } + ], + "renamed": null + }, { "name": "Delete an SSH signing key for the authenticated user", "scope": "users", @@ -58463,7 +65710,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "If the authenticated user is authenticated through basic authentication or OAuth with the `user` scope, then the response lists public and private profile information.\n\nIf the authenticated user is authenticated through OAuth without the `user` scope, then the response lists only public profile information.", + "description": "If the authenticated user is authenticated with an OAuth token with the `user` scope, then the response lists public and private profile information.\n\nIf the authenticated user is authenticated through OAuth without the `user` scope, then the response lists only public profile information.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#get-the-authenticated-user", "parameters": [], "responses": [ @@ -58765,7 +66012,7 @@ "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists all users, in the order that they signed up on GitHub Enterprise Cloud. This list includes personal user accounts and organization accounts.\n\nNote: Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/overview/resources-in-the-rest-api#link-header) to get the URL for the next page of users.", + "description": "Lists all users, in the order that they signed up on GitHub Enterprise Cloud. This list includes personal user accounts and organization accounts.\n\nNote: Pagination is powered exclusively by the `since` parameter. Use the [Link header](https://docs.github.com/enterprise-cloud@latest//rest/guides/using-pagination-in-the-rest-api#using-link-headers) to get the URL for the next page of users.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-users", "parameters": [ { @@ -58812,7 +66059,34 @@ "removalDate": null, "description": "List the users you've blocked on your personal account.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-users-blocked-by-the-authenticated-user", - "parameters": [], + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, @@ -58838,7 +66112,34 @@ "removalDate": null, "description": "List the users you've blocked on your personal account.", "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-users-blocked-by-the-authenticated-user", - "parameters": [], + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], "responses": [ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, @@ -58988,30 +66289,234 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": { - "before": { "scope": "users", "id": "listFollowedByAuthenticated" }, - "after": { "scope": "users", "id": "listFollowedByAuthenticatedUser" }, - "date": "2021-10-05", - "note": null - } + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": { + "before": { "scope": "users", "id": "listFollowedByAuthenticated" }, + "after": { "scope": "users", "id": "listFollowedByAuthenticatedUser" }, + "date": "2021-10-05", + "note": null + } + }, + { + "name": "List the people the authenticated user follows", + "scope": "users", + "id": "listFollowedByAuthenticatedUser", + "method": "GET", + "url": "/user/following", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people who the authenticated user follows.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-the-people-the-authenticated-user-follows", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List followers of the authenticated user", + "scope": "users", + "id": "listFollowersForAuthenticatedUser", + "method": "GET", + "url": "/user/followers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people following the authenticated user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-followers-of-the-authenticated-user", + "parameters": [ + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" } + ], + "renamed": null + }, + { + "name": "List followers of a user", + "scope": "users", + "id": "listFollowersForUser", + "method": "GET", + "url": "/users/{username}/followers", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people following the specified user.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-followers-of-a-user", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null + }, + { + "name": "List the people a user follows", + "scope": "users", + "id": "listFollowingForUser", + "method": "GET", + "url": "/users/{username}/following", + "isDeprecated": false, + "deprecationDate": null, + "removalDate": null, + "description": "Lists the people who the specified user follows.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-the-people-a-user-follows", + "parameters": [ + { + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "per_page", + "description": "The number of results per page (max 100).", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + }, + { + "name": "page", + "description": "Page number of the results to fetch.", + "in": "QUERY", + "type": "integer", + "required": false, + "enum": null, + "allowNull": false, + "mapToData": null, + "validation": null, + "alias": null, + "deprecated": null + } + ], + "responses": [{ "code": 200, "description": "Response" }], + "renamed": null }, { - "name": "List the people the authenticated user follows", + "name": "List GPG keys for the authenticated user", "scope": "users", - "id": "listFollowedByAuthenticatedUser", + "id": "listGpgKeysForAuthenticated", "method": "GET", - "url": "/user/following", + "url": "/user/gpg_keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the people who the authenticated user follows.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-the-people-the-authenticated-user-follows", + "description": "Lists the current user's GPG keys. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:gpg_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59044,21 +66549,27 @@ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], - "renamed": null + "renamed": { + "before": { "scope": "users", "id": "listGpgKeysForAuthenticated" }, + "after": { "scope": "users", "id": "listGpgKeysForAuthenticatedUser" }, + "date": "2021-10-05", + "note": null + } }, { - "name": "List followers of the authenticated user", + "name": "List GPG keys for the authenticated user", "scope": "users", - "id": "listFollowersForAuthenticatedUser", + "id": "listGpgKeysForAuthenticatedUser", "method": "GET", - "url": "/user/followers", + "url": "/user/gpg_keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the people following the authenticated user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-followers-of-the-authenticated-user", + "description": "Lists the current user's GPG keys. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:gpg_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59091,76 +66602,22 @@ { "code": 200, "description": "Response" }, { "code": 304, "description": "Not modified" }, { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" } - ], - "renamed": null - }, - { - "name": "List followers of a user", - "scope": "users", - "id": "listFollowersForUser", - "method": "GET", - "url": "/users/{username}/followers", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the people following the specified user.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-followers-of-a-user", - "parameters": [ - { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - } + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } ], - "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { - "name": "List the people a user follows", + "name": "List GPG keys for a user", "scope": "users", - "id": "listFollowingForUser", + "id": "listGpgKeysForUser", "method": "GET", - "url": "/users/{username}/following", + "url": "/users/{username}/gpg_keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the people who the specified user follows.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-the-people-a-user-follows", + "description": "Lists the GPG keys for a user. This information is accessible by anyone.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-a-user", "parameters": [ { "name": "username", @@ -59206,16 +66663,16 @@ "renamed": null }, { - "name": "List GPG keys for the authenticated user", + "name": "List public email addresses for the authenticated user", "scope": "users", - "id": "listGpgKeysForAuthenticated", + "id": "listPublicEmailsForAuthenticated", "method": "GET", - "url": "/user/gpg_keys", + "url": "/user/public_emails", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the current user's GPG keys. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:gpg_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-the-authenticated-user", + "description": "Lists your publicly visible email address, which you can set with the [Set primary email visibility for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/users#set-primary-email-visibility-for-the-authenticated-user) endpoint. This endpoint is accessible with the `user:email` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-email-addresses-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59252,23 +66709,26 @@ { "code": 404, "description": "Resource not found" } ], "renamed": { - "before": { "scope": "users", "id": "listGpgKeysForAuthenticated" }, - "after": { "scope": "users", "id": "listGpgKeysForAuthenticatedUser" }, + "before": { "scope": "users", "id": "listPublicEmailsForAuthenticated" }, + "after": { + "scope": "users", + "id": "listPublicEmailsForAuthenticatedUser" + }, "date": "2021-10-05", "note": null } }, { - "name": "List GPG keys for the authenticated user", + "name": "List public email addresses for the authenticated user", "scope": "users", - "id": "listGpgKeysForAuthenticatedUser", + "id": "listPublicEmailsForAuthenticatedUser", "method": "GET", - "url": "/user/gpg_keys", + "url": "/user/public_emails", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the current user's GPG keys. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:gpg_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-the-authenticated-user", + "description": "Lists your publicly visible email address, which you can set with the [Set primary email visibility for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/users#set-primary-email-visibility-for-the-authenticated-user) endpoint. This endpoint is accessible with the `user:email` scope.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-email-addresses-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59307,16 +66767,16 @@ "renamed": null }, { - "name": "List GPG keys for a user", + "name": "List public keys for a user", "scope": "users", - "id": "listGpgKeysForUser", + "id": "listPublicKeysForUser", "method": "GET", - "url": "/users/{username}/gpg_keys", + "url": "/users/{username}/keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the GPG keys for a user. This information is accessible by anyone.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-gpg-keys-for-a-user", + "description": "Lists the _verified_ public SSH keys for a user. This is accessible by anyone.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-keys-for-a-user", "parameters": [ { "name": "username", @@ -59362,16 +66822,16 @@ "renamed": null }, { - "name": "List public email addresses for the authenticated user", + "name": "List public SSH keys for the authenticated user", "scope": "users", - "id": "listPublicEmailsForAuthenticated", + "id": "listPublicSshKeysForAuthenticated", "method": "GET", - "url": "/user/public_emails", + "url": "/user/keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists your publicly visible email address, which you can set with the [Set primary email visibility for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/users#set-primary-email-visibility-for-the-authenticated-user) endpoint. This endpoint is accessible with the `user:email` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-email-addresses-for-the-authenticated-user", + "description": "Lists the public SSH keys for the authenticated user's GitHub account. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:public_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-ssh-keys-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59408,26 +66868,26 @@ { "code": 404, "description": "Resource not found" } ], "renamed": { - "before": { "scope": "users", "id": "listPublicEmailsForAuthenticated" }, + "before": { "scope": "users", "id": "listPublicSshKeysForAuthenticated" }, "after": { "scope": "users", - "id": "listPublicEmailsForAuthenticatedUser" + "id": "listPublicSshKeysForAuthenticatedUser" }, "date": "2021-10-05", "note": null } }, { - "name": "List public email addresses for the authenticated user", + "name": "List public SSH keys for the authenticated user", "scope": "users", - "id": "listPublicEmailsForAuthenticatedUser", + "id": "listPublicSshKeysForAuthenticatedUser", "method": "GET", - "url": "/user/public_emails", + "url": "/user/keys", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists your publicly visible email address, which you can set with the [Set primary email visibility for the authenticated user](https://docs.github.com/enterprise-cloud@latest//rest/reference/users#set-primary-email-visibility-for-the-authenticated-user) endpoint. This endpoint is accessible with the `user:email` scope.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-email-addresses-for-the-authenticated-user", + "description": "Lists the public SSH keys for the authenticated user's GitHub account. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:public_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-ssh-keys-for-the-authenticated-user", "parameters": [ { "name": "per_page", @@ -59466,30 +66926,17 @@ "renamed": null }, { - "name": "List public keys for a user", + "name": "List social accounts for the authenticated user", "scope": "users", - "id": "listPublicKeysForUser", + "id": "listSocialAccountsForAuthenticatedUser", "method": "GET", - "url": "/users/{username}/keys", + "url": "/user/social_accounts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the _verified_ public SSH keys for a user. This is accessible by anyone.", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-keys-for-a-user", + "description": "Lists all of your social accounts.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/users/social-accounts#list-social-accounts-for-the-authenticated-user", "parameters": [ - { - "name": "username", - "description": "The handle for the GitHub user account.", - "in": "PATH", - "type": "string", - "required": true, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, { "name": "per_page", "description": "The number of results per page (max 100).", @@ -59517,77 +66964,40 @@ "deprecated": null } ], - "responses": [{ "code": 200, "description": "Response" }], + "responses": [ + { "code": 200, "description": "Response" }, + { "code": 304, "description": "Not modified" }, + { "code": 401, "description": "Requires authentication" }, + { "code": 403, "description": "Forbidden" }, + { "code": 404, "description": "Resource not found" } + ], "renamed": null }, { - "name": "List public SSH keys for the authenticated user", + "name": "List social accounts for a user", "scope": "users", - "id": "listPublicSshKeysForAuthenticated", + "id": "listSocialAccountsForUser", "method": "GET", - "url": "/user/keys", + "url": "/users/{username}/social_accounts", "isDeprecated": false, "deprecationDate": null, "removalDate": null, - "description": "Lists the public SSH keys for the authenticated user's GitHub account. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:public_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-ssh-keys-for-the-authenticated-user", + "description": "Lists social media accounts for a user. This endpoint is accessible by anyone.", + "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/users/social-accounts#list-social-accounts-for-a-user", "parameters": [ { - "name": "per_page", - "description": "The number of results per page (max 100).", - "in": "QUERY", - "type": "integer", - "required": false, - "enum": null, - "allowNull": false, - "mapToData": null, - "validation": null, - "alias": null, - "deprecated": null - }, - { - "name": "page", - "description": "Page number of the results to fetch.", - "in": "QUERY", - "type": "integer", - "required": false, + "name": "username", + "description": "The handle for the GitHub user account.", + "in": "PATH", + "type": "string", + "required": true, "enum": null, "allowNull": false, "mapToData": null, "validation": null, "alias": null, "deprecated": null - } - ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], - "renamed": { - "before": { "scope": "users", "id": "listPublicSshKeysForAuthenticated" }, - "after": { - "scope": "users", - "id": "listPublicSshKeysForAuthenticatedUser" }, - "date": "2021-10-05", - "note": null - } - }, - { - "name": "List public SSH keys for the authenticated user", - "scope": "users", - "id": "listPublicSshKeysForAuthenticatedUser", - "method": "GET", - "url": "/user/keys", - "isDeprecated": false, - "deprecationDate": null, - "removalDate": null, - "description": "Lists the public SSH keys for the authenticated user's GitHub account. Requires that you are authenticated via Basic Auth or via OAuth with at least `read:public_key` [scope](https://docs.github.com/enterprise-cloud@latest//apps/building-oauth-apps/understanding-scopes-for-oauth-apps/).", - "documentationUrl": "https://docs.github.com/enterprise-cloud@latest//rest/reference/users#list-public-ssh-keys-for-the-authenticated-user", - "parameters": [ { "name": "per_page", "description": "The number of results per page (max 100).", @@ -59615,13 +67025,7 @@ "deprecated": null } ], - "responses": [ - { "code": 200, "description": "Response" }, - { "code": 304, "description": "Not modified" }, - { "code": 401, "description": "Requires authentication" }, - { "code": 403, "description": "Forbidden" }, - { "code": 404, "description": "Resource not found" } - ], + "responses": [{ "code": 200, "description": "Response" }], "renamed": null }, { diff --git a/src/moctokit/generated/endpoint-details.ts b/src/moctokit/generated/endpoint-details.ts index 2f3fd9e..42bf8fc 100644 --- a/src/moctokit/generated/endpoint-details.ts +++ b/src/moctokit/generated/endpoint-details.ts @@ -24,6 +24,24 @@ const endpoints: Endpoints = { body: [], }, }, + addSelectedRepoToOrgVariable: { + method: "put", + path: "/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", + parameters: { + path: ["org", "name", "repository_id"], + query: [], + body: [], + }, + }, + addSelectedRepoToRequiredWorkflow: { + method: "put", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", + parameters: { + path: ["org", "required_workflow_id", "repository_id"], + query: [], + body: [], + }, + }, approveWorkflowRun: { method: "post", path: "/repos/{owner}/{repo}/actions/runs/{run_id}/approve", @@ -34,6 +52,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/actions/runs/{run_id}/cancel", parameters: { path: ["owner", "repo", "run_id"], query: [], body: [] }, }, + createEnvironmentVariable: { + method: "post", + path: "/repositories/{repository_id}/environments/{environment_name}/variables", + parameters: { + path: ["repository_id", "environment_name"], + query: [], + body: ["name", "value"], + }, + }, createOrUpdateEnvironmentSecret: { method: "put", path: "/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", @@ -66,6 +93,15 @@ const endpoints: Endpoints = { body: ["encrypted_value", "key_id"], }, }, + createOrgVariable: { + method: "post", + path: "/orgs/{org}/actions/variables", + parameters: { + path: ["org"], + query: [], + body: ["name", "value", "visibility", "selected_repository_ids"], + }, + }, createRegistrationTokenForOrg: { method: "post", path: "/orgs/{org}/actions/runners/registration-token", @@ -86,6 +122,29 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/actions/runners/remove-token", parameters: { path: ["owner", "repo"], query: [], body: [] }, }, + createRepoVariable: { + method: "post", + path: "/repos/{owner}/{repo}/actions/variables", + parameters: { + path: ["owner", "repo"], + query: [], + body: ["name", "value"], + }, + }, + createRequiredWorkflow: { + method: "post", + path: "/orgs/{org}/actions/required_workflows", + parameters: { + path: ["org"], + query: [], + body: [ + "workflow_file_path", + "repository_id", + "scope", + "selected_repository_ids", + ], + }, + }, createWorkflowDispatch: { method: "post", path: "/repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches", @@ -123,11 +182,25 @@ const endpoints: Endpoints = { body: [], }, }, + deleteEnvironmentVariable: { + method: "delete", + path: "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + parameters: { + path: ["repository_id", "name", "environment_name"], + query: [], + body: [], + }, + }, deleteOrgSecret: { method: "delete", path: "/orgs/{org}/actions/secrets/{secret_name}", parameters: { path: ["org", "secret_name"], query: [], body: [] }, }, + deleteOrgVariable: { + method: "delete", + path: "/orgs/{org}/actions/variables/{name}", + parameters: { path: ["org", "name"], query: [], body: [] }, + }, deleteRepoSecret: { method: "delete", path: "/repos/{owner}/{repo}/actions/secrets/{secret_name}", @@ -137,6 +210,20 @@ const endpoints: Endpoints = { body: [], }, }, + deleteRepoVariable: { + method: "delete", + path: "/repos/{owner}/{repo}/actions/variables/{name}", + parameters: { path: ["owner", "repo", "name"], query: [], body: [] }, + }, + deleteRequiredWorkflow: { + method: "delete", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}", + parameters: { + path: ["org", "required_workflow_id"], + query: [], + body: [], + }, + }, deleteSelfHostedRunnerFromOrg: { method: "delete", path: "/orgs/{org}/actions/runners/{runner_id}", @@ -213,6 +300,33 @@ const endpoints: Endpoints = { body: [], }, }, + generateRunnerJitconfigForEnterprise: { + method: "post", + path: "/enterprises/{enterprise}/actions/runners/generate-jitconfig", + parameters: { + path: ["enterprise"], + query: [], + body: ["name", "runner_group_id", "labels", "work_folder"], + }, + }, + generateRunnerJitconfigForOrg: { + method: "post", + path: "/orgs/{org}/actions/runners/generate-jitconfig", + parameters: { + path: ["org"], + query: [], + body: ["name", "runner_group_id", "labels", "work_folder"], + }, + }, + generateRunnerJitconfigForRepo: { + method: "post", + path: "/repos/{owner}/{repo}/actions/runners/generate-jitconfig", + parameters: { + path: ["owner", "repo"], + query: [], + body: ["name", "runner_group_id", "labels", "work_folder"], + }, + }, getActionsCacheList: { method: "get", path: "/repos/{owner}/{repo}/actions/caches", @@ -232,11 +346,6 @@ const endpoints: Endpoints = { path: "/orgs/{org}/actions/cache/usage-by-repository", parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, - getActionsCacheUsageForEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/actions/cache/usage", - parameters: { path: ["enterprise"], query: [], body: [] }, - }, getActionsCacheUsageForOrg: { method: "get", path: "/orgs/{org}/actions/cache/usage", @@ -279,10 +388,14 @@ const endpoints: Endpoints = { body: [], }, }, - getGithubActionsDefaultWorkflowPermissionsEnterprise: { + getEnvironmentVariable: { method: "get", - path: "/enterprises/{enterprise}/actions/permissions/workflow", - parameters: { path: ["enterprise"], query: [], body: [] }, + path: "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + parameters: { + path: ["repository_id", "environment_name", "name"], + query: [], + body: [], + }, }, getGithubActionsDefaultWorkflowPermissionsOrganization: { method: "get", @@ -319,6 +432,11 @@ const endpoints: Endpoints = { path: "/orgs/{org}/actions/secrets/{secret_name}", parameters: { path: ["org", "secret_name"], query: [], body: [] }, }, + getOrgVariable: { + method: "get", + path: "/orgs/{org}/actions/variables/{name}", + parameters: { path: ["org", "name"], query: [], body: [] }, + }, getPendingDeploymentsForRun: { method: "get", path: "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", @@ -334,6 +452,24 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/actions/secrets/public-key", parameters: { path: ["owner", "repo"], query: [], body: [] }, }, + getRepoRequiredWorkflow: { + method: "get", + path: "/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}", + parameters: { + path: ["org", "repo", "required_workflow_id_for_repo"], + query: [], + body: [], + }, + }, + getRepoRequiredWorkflowUsage: { + method: "get", + path: "/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/timing", + parameters: { + path: ["org", "repo", "required_workflow_id_for_repo"], + query: [], + body: [], + }, + }, getRepoSecret: { method: "get", path: "/repos/{owner}/{repo}/actions/secrets/{secret_name}", @@ -343,6 +479,20 @@ const endpoints: Endpoints = { body: [], }, }, + getRepoVariable: { + method: "get", + path: "/repos/{owner}/{repo}/actions/variables/{name}", + parameters: { path: ["owner", "repo", "name"], query: [], body: [] }, + }, + getRequiredWorkflow: { + method: "get", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}", + parameters: { + path: ["org", "required_workflow_id"], + query: [], + body: [], + }, + }, getReviewsForRun: { method: "get", path: "/repos/{owner}/{repo}/actions/runs/{run_id}/approvals", @@ -409,7 +559,7 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/actions/artifacts", parameters: { path: ["owner", "repo"], - query: ["per_page", "page"], + query: ["per_page", "page", "name"], body: [], }, }, @@ -422,6 +572,15 @@ const endpoints: Endpoints = { body: [], }, }, + listEnvironmentVariables: { + method: "get", + path: "/repositories/{repository_id}/environments/{environment_name}/variables", + parameters: { + path: ["repository_id", "environment_name"], + query: ["per_page", "page"], + body: [], + }, + }, listJobsForWorkflowRun: { method: "get", path: "/repos/{owner}/{repo}/actions/runs/{run_id}/jobs", @@ -455,6 +614,38 @@ const endpoints: Endpoints = { path: "/orgs/{org}/actions/secrets", parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, + listOrgVariables: { + method: "get", + path: "/orgs/{org}/actions/variables", + parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, + }, + listRepoOrganizationSecrets: { + method: "get", + path: "/repos/{owner}/{repo}/actions/organization-secrets", + parameters: { + path: ["owner", "repo"], + query: ["per_page", "page"], + body: [], + }, + }, + listRepoOrganizationVariables: { + method: "get", + path: "/repos/{owner}/{repo}/actions/organization-variables", + parameters: { + path: ["owner", "repo"], + query: ["per_page", "page"], + body: [], + }, + }, + listRepoRequiredWorkflows: { + method: "get", + path: "/repos/{org}/{repo}/actions/required_workflows", + parameters: { + path: ["org", "repo"], + query: ["per_page", "page"], + body: [], + }, + }, listRepoSecrets: { method: "get", path: "/repos/{owner}/{repo}/actions/secrets", @@ -464,6 +655,15 @@ const endpoints: Endpoints = { body: [], }, }, + listRepoVariables: { + method: "get", + path: "/repos/{owner}/{repo}/actions/variables", + parameters: { + path: ["owner", "repo"], + query: ["per_page", "page"], + body: [], + }, + }, listRepoWorkflows: { method: "get", path: "/repos/{owner}/{repo}/actions/workflows", @@ -473,6 +673,31 @@ const endpoints: Endpoints = { body: [], }, }, + listRequiredWorkflowRuns: { + method: "get", + path: "/repos/{owner}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/runs", + parameters: { + path: ["owner", "repo", "required_workflow_id_for_repo"], + query: [ + "actor", + "branch", + "event", + "status", + "per_page", + "page", + "created", + "exclude_pull_requests", + "check_suite_id", + "head_sha", + ], + body: [], + }, + }, + listRequiredWorkflows: { + method: "get", + path: "/orgs/{org}/actions/required_workflows", + parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, + }, listRunnerApplicationsForOrg: { method: "get", path: "/orgs/{org}/actions/runners/downloads", @@ -492,11 +717,29 @@ const endpoints: Endpoints = { body: [], }, }, + listSelectedReposForOrgVariable: { + method: "get", + path: "/orgs/{org}/actions/variables/{name}/repositories", + parameters: { + path: ["org", "name"], + query: ["page", "per_page"], + body: [], + }, + }, listSelectedRepositoriesEnabledGithubActionsOrganization: { method: "get", path: "/orgs/{org}/actions/permissions/repositories", parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, + listSelectedRepositoriesRequiredWorkflow: { + method: "get", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", + parameters: { + path: ["org", "required_workflow_id"], + query: [], + body: [], + }, + }, listSelfHostedRunnersForOrg: { method: "get", path: "/orgs/{org}/actions/runners", @@ -620,6 +863,29 @@ const endpoints: Endpoints = { body: [], }, }, + removeSelectedRepoFromOrgVariable: { + method: "delete", + path: "/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", + parameters: { + path: ["org", "name", "repository_id"], + query: [], + body: [], + }, + }, + removeSelectedRepoFromRequiredWorkflow: { + method: "delete", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", + parameters: { + path: ["org", "required_workflow_id", "repository_id"], + query: [], + body: [], + }, + }, + reviewCustomGatesForRun: { + method: "post", + path: "/repos/{owner}/{repo}/actions/runs/{run_id}/deployment_protection_rule", + parameters: { path: ["owner", "repo", "run_id"], query: [], body: [] }, + }, reviewPendingDeploymentsForRun: { method: "post", path: "/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", @@ -661,18 +927,6 @@ const endpoints: Endpoints = { body: ["labels"], }, }, - setGithubActionsDefaultWorkflowPermissionsEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/permissions/workflow", - parameters: { - path: ["enterprise"], - query: [], - body: [ - "default_workflow_permissions", - "can_approve_pull_request_reviews", - ], - }, - }, setGithubActionsDefaultWorkflowPermissionsOrganization: { method: "put", path: "/orgs/{org}/actions/permissions/workflow", @@ -724,6 +978,24 @@ const endpoints: Endpoints = { body: ["selected_repository_ids"], }, }, + setSelectedReposForOrgVariable: { + method: "put", + path: "/orgs/{org}/actions/variables/{name}/repositories", + parameters: { + path: ["org", "name"], + query: [], + body: ["selected_repository_ids"], + }, + }, + setSelectedReposToRequiredWorkflow: { + method: "put", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", + parameters: { + path: ["org", "required_workflow_id"], + query: [], + body: ["selected_repository_ids"], + }, + }, setSelectedRepositoriesEnabledGithubActionsOrganization: { method: "put", path: "/orgs/{org}/actions/permissions/repositories", @@ -742,6 +1014,47 @@ const endpoints: Endpoints = { body: ["access_level"], }, }, + updateEnvironmentVariable: { + method: "patch", + path: "/repositories/{repository_id}/environments/{environment_name}/variables/{name}", + parameters: { + path: ["repository_id", "environment_name"], + query: [], + body: ["name", "value"], + }, + }, + updateOrgVariable: { + method: "patch", + path: "/orgs/{org}/actions/variables/{name}", + parameters: { + path: ["org"], + query: [], + body: ["name", "value", "visibility", "selected_repository_ids"], + }, + }, + updateRepoVariable: { + method: "patch", + path: "/repos/{owner}/{repo}/actions/variables/{name}", + parameters: { + path: ["owner", "repo"], + query: [], + body: ["name", "value"], + }, + }, + updateRequiredWorkflow: { + method: "patch", + path: "/orgs/{org}/actions/required_workflows/{required_workflow_id}", + parameters: { + path: ["org", "required_workflow_id"], + query: [], + body: [ + "workflow_file_path", + "repository_id", + "scope", + "selected_repository_ids", + ], + }, + }, }, activity: { checkRepoIsStarredByAuthenticatedUser: { @@ -1006,7 +1319,10 @@ const endpoints: Endpoints = { "permissions.members", "permissions.organization_administration", "permissions.organization_custom_roles", + "permissions.organization_announcement_banners", "permissions.organization_hooks", + "permissions.organization_personal_access_tokens", + "permissions.organization_personal_access_token_requests", "permissions.organization_plan", "permissions.organization_projects", "permissions.organization_packages", @@ -1109,6 +1425,11 @@ const endpoints: Endpoints = { body: [], }, }, + listInstallationRequestsForAuthenticatedApp: { + method: "get", + path: "/app/installation-requests", + parameters: { path: [], query: ["per_page", "page"], body: [] }, + }, listInstallations: { method: "get", path: "/app/installations", @@ -1151,7 +1472,11 @@ const endpoints: Endpoints = { listWebhookDeliveries: { method: "get", path: "/app/hook/deliveries", - parameters: { path: [], query: ["per_page", "cursor"], body: [] }, + parameters: { + path: [], + query: ["per_page", "cursor", "redelivery"], + body: [], + }, }, redeliverWebhookDelivery: { method: "post", @@ -1222,7 +1547,10 @@ const endpoints: Endpoints = { "permissions.members", "permissions.organization_administration", "permissions.organization_custom_roles", + "permissions.organization_announcement_banners", "permissions.organization_hooks", + "permissions.organization_personal_access_tokens", + "permissions.organization_personal_access_token_requests", "permissions.organization_plan", "permissions.organization_projects", "permissions.organization_packages", @@ -1264,20 +1592,6 @@ const endpoints: Endpoints = { path: "/users/{username}/settings/billing/actions", parameters: { path: ["username"], query: [], body: [] }, }, - getGithubAdvancedSecurityBillingGhe: { - method: "get", - path: "/enterprises/{enterprise}/settings/billing/advanced-security", - parameters: { - path: ["enterprise"], - query: ["per_page", "page"], - body: [], - }, - }, - getGithubAdvancedSecurityBillingOrg: { - method: "get", - path: "/orgs/{org}/settings/billing/advanced-security", - parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, - }, getGithubPackagesBillingOrg: { method: "get", path: "/orgs/{org}/settings/billing/packages", @@ -1468,6 +1782,11 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/code-scanning/codeql/databases/{language}", parameters: { path: ["owner", "repo", "language"], query: [], body: [] }, }, + getDefaultSetup: { + method: "get", + path: "/repos/{owner}/{repo}/code-scanning/default-setup", + parameters: { path: ["owner", "repo"], query: [], body: [] }, + }, getSarif: { method: "get", path: "/repos/{owner}/{repo}/code-scanning/sarifs/{sarif_id}", @@ -1482,25 +1801,6 @@ const endpoints: Endpoints = { body: [], }, }, - listAlertsForEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/code-scanning/alerts", - parameters: { - path: ["enterprise"], - query: [ - "tool_name", - "tool_guid", - "before", - "after", - "page", - "per_page", - "direction", - "state", - "sort", - ], - body: [], - }, - }, listAlertsForOrg: { method: "get", path: "/orgs/{org}/code-scanning/alerts", @@ -1516,6 +1816,7 @@ const endpoints: Endpoints = { "direction", "state", "sort", + "severity", ], body: [], }, @@ -1534,6 +1835,7 @@ const endpoints: Endpoints = { "direction", "sort", "state", + "severity", ], body: [], }, @@ -1579,6 +1881,15 @@ const endpoints: Endpoints = { body: ["state", "dismissed_reason", "dismissed_comment"], }, }, + updateDefaultSetup: { + method: "patch", + path: "/repos/{owner}/{repo}/code-scanning/default-setup", + parameters: { + path: ["owner", "repo"], + query: [], + body: ["state", "query_suite"], + }, + }, uploadSarif: { method: "post", path: "/repos/{owner}/{repo}/code-scanning/sarifs", @@ -1592,6 +1903,7 @@ const endpoints: Endpoints = { "checkout_uri", "started_at", "tool_name", + "validate", ], }, }, @@ -1620,7 +1932,7 @@ const endpoints: Endpoints = { }, addSelectedRepoToOrgSecret: { method: "put", - path: "/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", + path: "/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", parameters: { path: ["org", "secret_name", "repository_id"], query: [], @@ -1642,6 +1954,7 @@ const endpoints: Endpoints = { "repository_id", "ref", "location", + "geo", "client_ip", "machine", "devcontainer_path", @@ -1658,7 +1971,7 @@ const endpoints: Endpoints = { }, createOrUpdateOrgSecret: { method: "put", - path: "/organizations/{org}/codespaces/secrets/{secret_name}", + path: "/orgs/{org}/codespaces/secrets/{secret_name}", parameters: { path: ["org", "secret_name"], query: [], @@ -1696,6 +2009,7 @@ const endpoints: Endpoints = { query: [], body: [ "location", + "geo", "client_ip", "machine", "devcontainer_path", @@ -1716,6 +2030,7 @@ const endpoints: Endpoints = { body: [ "ref", "location", + "geo", "client_ip", "machine", "devcontainer_path", @@ -1727,6 +2042,11 @@ const endpoints: Endpoints = { ], }, }, + deleteCodespacesBillingUsers: { + method: "delete", + path: "/orgs/{org}/codespaces/billing/selected_users", + parameters: { path: ["org"], query: [], body: ["selected_usernames"] }, + }, deleteForAuthenticatedUser: { method: "delete", path: "/user/codespaces/{codespace_name}", @@ -1743,7 +2063,7 @@ const endpoints: Endpoints = { }, deleteOrgSecret: { method: "delete", - path: "/organizations/{org}/codespaces/secrets/{secret_name}", + path: "/orgs/{org}/codespaces/secrets/{secret_name}", parameters: { path: ["org", "secret_name"], query: [], body: [] }, }, deleteRepoSecret: { @@ -1765,6 +2085,15 @@ const endpoints: Endpoints = { path: "/user/codespaces/{codespace_name}/exports", parameters: { path: ["codespace_name"], query: [], body: [] }, }, + getCodespacesForUserInOrg: { + method: "get", + path: "/orgs/{org}/members/{username}/codespaces", + parameters: { + path: ["org", "username"], + query: ["per_page", "page"], + body: [], + }, + }, getExportDetailsForAuthenticatedUser: { method: "get", path: "/user/codespaces/{codespace_name}/exports/{export_id}", @@ -1781,12 +2110,12 @@ const endpoints: Endpoints = { }, getOrgPublicKey: { method: "get", - path: "/organizations/{org}/codespaces/secrets/public-key", + path: "/orgs/{org}/codespaces/secrets/public-key", parameters: { path: ["org"], query: [], body: [] }, }, getOrgSecret: { method: "get", - path: "/organizations/{org}/codespaces/secrets/{secret_name}", + path: "/orgs/{org}/codespaces/secrets/{secret_name}", parameters: { path: ["org", "secret_name"], query: [], body: [] }, }, getPublicKeyForAuthenticatedUser: { @@ -1851,7 +2180,7 @@ const endpoints: Endpoints = { }, listOrgSecrets: { method: "get", - path: "/organizations/{org}/codespaces/secrets", + path: "/orgs/{org}/codespaces/secrets", parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, listRepoSecrets: { @@ -1875,7 +2204,7 @@ const endpoints: Endpoints = { }, listSelectedReposForOrgSecret: { method: "get", - path: "/organizations/{org}/codespaces/secrets/{secret_name}/repositories", + path: "/orgs/{org}/codespaces/secrets/{secret_name}/repositories", parameters: { path: ["org", "secret_name"], query: ["page", "per_page"], @@ -1891,6 +2220,15 @@ const endpoints: Endpoints = { body: [], }, }, + publishForAuthenticatedUser: { + method: "post", + path: "/user/codespaces/{codespace_name}/publish", + parameters: { + path: ["codespace_name"], + query: [], + body: ["name", "private"], + }, + }, removeRepositoryForSecretForAuthenticatedUser: { method: "delete", path: "/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", @@ -1902,7 +2240,7 @@ const endpoints: Endpoints = { }, removeSelectedRepoFromOrgSecret: { method: "delete", - path: "/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", + path: "/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", parameters: { path: ["org", "secret_name", "repository_id"], query: [], @@ -1918,6 +2256,20 @@ const endpoints: Endpoints = { body: [], }, }, + setCodespacesBilling: { + method: "put", + path: "/orgs/{org}/codespaces/billing", + parameters: { + path: ["org"], + query: [], + body: ["visibility", "selected_usernames"], + }, + }, + setCodespacesBillingUsers: { + method: "post", + path: "/orgs/{org}/codespaces/billing/selected_users", + parameters: { path: ["org"], query: [], body: ["selected_usernames"] }, + }, setRepositoriesForSecretForAuthenticatedUser: { method: "put", path: "/user/codespaces/secrets/{secret_name}/repositories", @@ -1929,7 +2281,7 @@ const endpoints: Endpoints = { }, setSelectedReposForOrgSecret: { method: "put", - path: "/organizations/{org}/codespaces/secrets/{secret_name}/repositories", + path: "/orgs/{org}/codespaces/secrets/{secret_name}/repositories", parameters: { path: ["org", "secret_name"], query: [], @@ -2045,6 +2397,50 @@ const endpoints: Endpoints = { body: [], }, }, + listAlertsForEnterprise: { + method: "get", + path: "/enterprises/{enterprise}/dependabot/alerts", + parameters: { + path: ["enterprise"], + query: [ + "state", + "severity", + "ecosystem", + "package", + "scope", + "sort", + "direction", + "before", + "after", + "first", + "last", + "per_page", + ], + body: [], + }, + }, + listAlertsForOrg: { + method: "get", + path: "/orgs/{org}/dependabot/alerts", + parameters: { + path: ["org"], + query: [ + "state", + "severity", + "ecosystem", + "package", + "scope", + "sort", + "direction", + "before", + "after", + "first", + "last", + "per_page", + ], + body: [], + }, + }, listAlertsForRepo: { method: "get", path: "/repos/{owner}/{repo}/dependabot/alerts", @@ -2061,6 +2457,10 @@ const endpoints: Endpoints = { "direction", "page", "per_page", + "before", + "after", + "first", + "last", ], body: [], }, @@ -2165,6 +2565,11 @@ const endpoints: Endpoints = { body: [], }, }, + exportSbom: { + method: "get", + path: "/repos/{owner}/{repo}/dependency-graph/sbom", + parameters: { path: ["owner", "repo"], query: [], body: [] }, + }, }, emojis: { get: { @@ -2173,110 +2578,6 @@ const endpoints: Endpoints = { parameters: { path: [], query: [], body: [] }, }, }, - enterpriseAdmin: { - addCustomLabelsToSelfHostedRunnerForEnterprise: { - method: "post", - path: "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - parameters: { - path: ["enterprise", "runner_id"], - query: [], - body: ["labels"], - }, - }, - disableSelectedOrganizationGithubActionsEnterprise: { - method: "delete", - path: "/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", - parameters: { path: ["enterprise", "org_id"], query: [], body: [] }, - }, - enableSelectedOrganizationGithubActionsEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", - parameters: { path: ["enterprise", "org_id"], query: [], body: [] }, - }, - getAllowedActionsEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/actions/permissions/selected-actions", - parameters: { path: ["enterprise"], query: [], body: [] }, - }, - getGithubActionsPermissionsEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/actions/permissions", - parameters: { path: ["enterprise"], query: [], body: [] }, - }, - getServerStatistics: { - method: "get", - path: "/enterprise-installation/{enterprise_or_org}/server-statistics", - parameters: { - path: ["enterprise_or_org"], - query: ["date_start", "date_end"], - body: [], - }, - }, - listLabelsForSelfHostedRunnerForEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - parameters: { path: ["enterprise", "runner_id"], query: [], body: [] }, - }, - listSelectedOrganizationsEnabledGithubActionsEnterprise: { - method: "get", - path: "/enterprises/{enterprise}/actions/permissions/organizations", - parameters: { - path: ["enterprise"], - query: ["per_page", "page"], - body: [], - }, - }, - removeAllCustomLabelsFromSelfHostedRunnerForEnterprise: { - method: "delete", - path: "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - parameters: { path: ["enterprise", "runner_id"], query: [], body: [] }, - }, - removeCustomLabelFromSelfHostedRunnerForEnterprise: { - method: "delete", - path: "/enterprises/{enterprise}/actions/runners/{runner_id}/labels/{name}", - parameters: { - path: ["enterprise", "runner_id", "name"], - query: [], - body: [], - }, - }, - setAllowedActionsEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/permissions/selected-actions", - parameters: { - path: ["enterprise"], - query: [], - body: ["github_owned_allowed", "verified_allowed", "patterns_allowed"], - }, - }, - setCustomLabelsForSelfHostedRunnerForEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/runners/{runner_id}/labels", - parameters: { - path: ["enterprise", "runner_id"], - query: [], - body: ["labels"], - }, - }, - setGithubActionsPermissionsEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/permissions", - parameters: { - path: ["enterprise"], - query: [], - body: ["enabled_organizations", "allowed_actions"], - }, - }, - setSelectedOrganizationsEnabledGithubActionsEnterprise: { - method: "put", - path: "/enterprises/{enterprise}/actions/permissions/organizations", - parameters: { - path: ["enterprise"], - query: [], - body: ["selected_organization_ids"], - }, - }, - }, gists: { checkIsStarred: { method: "get", @@ -2436,11 +2737,7 @@ const endpoints: Endpoints = { createRef: { method: "post", path: "/repos/{owner}/{repo}/git/refs", - parameters: { - path: ["owner", "repo"], - query: [], - body: ["ref", "sha", "key"], - }, + parameters: { path: ["owner", "repo"], query: [], body: ["ref", "sha"] }, }, createTag: { method: "post", @@ -2632,6 +2929,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/assignees/{assignee}", parameters: { path: ["owner", "repo", "assignee"], query: [], body: [] }, }, + checkUserCanBeAssignedToIssue: { + method: "get", + path: "/repos/{owner}/{repo}/issues/{issue_number}/assignees/{assignee}", + parameters: { + path: ["owner", "repo", "issue_number", "assignee"], + query: [], + body: [], + }, + }, create: { method: "post", path: "/repos/{owner}/{repo}/issues", @@ -3033,7 +3339,12 @@ const endpoints: Endpoints = { meta: { get: { method: "get", - path: "/meta", + path: "/meta", + parameters: { path: [], query: [], body: [] }, + }, + getAllVersions: { + method: "get", + path: "/versions", parameters: { path: [], query: [], body: [] }, }, getOctocat: { @@ -3275,15 +3586,6 @@ const endpoints: Endpoints = { path: "/orgs/{org}/outside_collaborators/{username}", parameters: { path: ["org", "username"], query: [], body: ["async"] }, }, - createCustomRole: { - method: "post", - path: "/orgs/{org}/custom_roles", - parameters: { - path: ["org"], - query: [], - body: ["name", "description", "base_role", "permissions"], - }, - }, createInvitation: { method: "post", path: "/orgs/{org}/invitations", @@ -3313,10 +3615,10 @@ const endpoints: Endpoints = { ], }, }, - deleteCustomRole: { + delete: { method: "delete", - path: "/orgs/{org}/custom_roles/{role_id}", - parameters: { path: ["org", "role_id"], query: [], body: [] }, + path: "/orgs/{org}", + parameters: { path: ["org"], query: [], body: [] }, }, deleteWebhook: { method: "delete", @@ -3379,23 +3681,13 @@ const endpoints: Endpoints = { listBlockedUsers: { method: "get", path: "/orgs/{org}/blocks", - parameters: { path: ["org"], query: [], body: [] }, - }, - listCustomRoles: { - method: "get", - path: "/organizations/{organization_id}/custom_roles", - parameters: { path: ["organization_id"], query: [], body: [] }, + parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, listFailedInvitations: { method: "get", path: "/orgs/{org}/failed_invitations", parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, }, - listFineGrainedPermissions: { - method: "get", - path: "/orgs/{org}/fine_grained_permissions", - parameters: { path: ["org"], query: [], body: [] }, - }, listForAuthenticatedUser: { method: "get", path: "/user/orgs", @@ -3438,10 +3730,70 @@ const endpoints: Endpoints = { body: [], }, }, + listPatGrantRepositories: { + method: "get", + path: "/organizations/{org}/personal-access-tokens/{pat_id}/repositories", + parameters: { + path: ["org", "pat_id"], + query: ["per_page", "page"], + body: [], + }, + }, + listPatGrantRequestRepositories: { + method: "get", + path: "/organizations/{org}/personal-access-token-requests/{pat_request_id}/repositories", + parameters: { + path: ["org", "pat_request_id"], + query: ["per_page", "page"], + body: [], + }, + }, + listPatGrantRequests: { + method: "get", + path: "/organizations/{org}/personal-access-token-requests", + parameters: { + path: ["org"], + query: [ + "per_page", + "page", + "sort", + "direction", + "owner", + "repository", + "permission", + "last_used_before", + "last_used_after", + ], + body: [], + }, + }, + listPatGrants: { + method: "get", + path: "/organizations/{org}/personal-access-tokens", + parameters: { + path: ["org"], + query: [ + "per_page", + "page", + "sort", + "direction", + "owner", + "repository", + "permission", + "last_used_before", + "last_used_after", + ], + body: [], + }, + }, listPendingInvitations: { method: "get", path: "/orgs/{org}/invitations", - parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, + parameters: { + path: ["org"], + query: ["per_page", "page", "role", "invitation_source"], + body: [], + }, }, listPublicMembers: { method: "get", @@ -3458,7 +3810,7 @@ const endpoints: Endpoints = { path: "/orgs/{org}/hooks/{hook_id}/deliveries", parameters: { path: ["org", "hook_id"], - query: ["per_page", "cursor"], + query: ["per_page", "cursor", "redelivery"], body: [], }, }, @@ -3506,6 +3858,24 @@ const endpoints: Endpoints = { path: "/orgs/{org}/security-managers/teams/{team_slug}", parameters: { path: ["org", "team_slug"], query: [], body: [] }, }, + reviewPatGrantRequest: { + method: "post", + path: "/organizations/{org}/personal-access-token-requests/{pat_request_id}", + parameters: { + path: ["org", "pat_request_id"], + query: [], + body: ["action", "reason"], + }, + }, + reviewPatGrantRequestsInBulk: { + method: "post", + path: "/organizations/{org}/personal-access-token-requests", + parameters: { + path: ["org"], + query: [], + body: ["pat_request_ids", "action", "reason"], + }, + }, setMembershipForUser: { method: "put", path: "/orgs/{org}/memberships/{username}", @@ -3555,23 +3925,26 @@ const endpoints: Endpoints = { "dependency_graph_enabled_for_new_repositories", "secret_scanning_enabled_for_new_repositories", "secret_scanning_push_protection_enabled_for_new_repositories", + "secret_scanning_push_protection_custom_link_enabled", + "secret_scanning_push_protection_custom_link", ], }, }, - updateCustomRole: { - method: "patch", - path: "/orgs/{org}/custom_roles/{role_id}", - parameters: { - path: ["org", "role_id"], - query: [], - body: ["name", "description", "base_role", "permissions"], - }, - }, updateMembershipForAuthenticatedUser: { method: "patch", path: "/user/memberships/orgs/{org}", parameters: { path: ["org"], query: [], body: ["state"] }, }, + updatePatAccess: { + method: "post", + path: "/organizations/{org}/personal-access-tokens/{pat_id}", + parameters: { path: ["org", "pat_id"], query: [], body: ["action"] }, + }, + updatePatAccesses: { + method: "post", + path: "/organizations/{org}/personal-access-tokens", + parameters: { path: ["org"], query: [], body: ["action", "pat_ids"] }, + }, updateWebhook: { method: "patch", path: "/orgs/{org}/hooks/{hook_id}", @@ -3764,17 +4137,36 @@ const endpoints: Endpoints = { body: [], }, }, + listDockerMigrationConflictingPackagesForAuthenticatedUser: { + method: "get", + path: "/user/docker/conflicts", + parameters: { path: [], query: [], body: [] }, + }, + listDockerMigrationConflictingPackagesForOrganization: { + method: "get", + path: "/orgs/{org}/docker/conflicts", + parameters: { path: ["org"], query: [], body: [] }, + }, + listDockerMigrationConflictingPackagesForUser: { + method: "get", + path: "/users/{username}/docker/conflicts", + parameters: { path: ["username"], query: [], body: [] }, + }, listPackagesForAuthenticatedUser: { method: "get", path: "/user/packages", - parameters: { path: [], query: ["package_type", "visibility"], body: [] }, + parameters: { + path: [], + query: ["package_type", "visibility", "page", "per_page"], + body: [], + }, }, listPackagesForOrganization: { method: "get", path: "/orgs/{org}/packages", parameters: { path: ["org"], - query: ["package_type", "visibility"], + query: ["package_type", "visibility", "page", "per_page"], body: [], }, }, @@ -3783,7 +4175,7 @@ const endpoints: Endpoints = { path: "/users/{username}/packages", parameters: { path: ["username"], - query: ["package_type", "visibility"], + query: ["package_type", "visibility", "page", "per_page"], body: [], }, }, @@ -4037,6 +4429,7 @@ const endpoints: Endpoints = { body: [ "title", "head", + "head_repo", "base", "body", "maintainer_can_modify", @@ -4091,6 +4484,7 @@ const endpoints: Endpoints = { "start_line", "start_side", "in_reply_to", + "subject_type", ], }, }, @@ -4663,6 +5057,15 @@ const endpoints: Endpoints = { body: ["name"], }, }, + createDeploymentProtectionRule: { + method: "post", + path: "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", + parameters: { + path: ["environment_name", "repo", "owner"], + query: [], + body: ["integration_id"], + }, + }, createDeploymentStatus: { method: "post", path: "/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", @@ -4703,6 +5106,7 @@ const endpoints: Endpoints = { "has_issues", "has_projects", "has_wiki", + "has_discussions", "team_id", "auto_init", "gitignore_template", @@ -4745,6 +5149,7 @@ const endpoints: Endpoints = { "has_issues", "has_projects", "has_wiki", + "has_downloads", "is_template", "team_id", "auto_init", @@ -4802,6 +5207,41 @@ const endpoints: Endpoints = { ], }, }, + createOrgRuleset: { + method: "post", + path: "/orgs/{org}/rulesets", + parameters: { + path: ["org"], + query: [], + body: [ + "name", + "target", + "enforcement", + "bypass_actors", + "bypass_actors[].actor_id", + "bypass_actors[].actor_type", + "conditions", + "rules", + "rules[].type", + "rules[].parameters", + "rules[].parameters.update_allows_fetch_and_merge", + "rules[].parameters.required_deployment_environments", + "rules[].parameters.dismiss_stale_reviews_on_push", + "rules[].parameters.require_code_owner_review", + "rules[].parameters.require_last_push_approval", + "rules[].parameters.required_approving_review_count", + "rules[].parameters.required_review_thread_resolution", + "rules[].parameters.required_status_checks", + "rules[].parameters.required_status_checks[].context", + "rules[].parameters.required_status_checks[].integration_id", + "rules[].parameters.strict_required_status_checks_policy", + "rules[].parameters.name", + "rules[].parameters.negate", + "rules[].parameters.operator", + "rules[].parameters.pattern", + ], + }, + }, createPagesDeployment: { method: "post", path: "/repos/{owner}/{repo}/pages/deployment", @@ -4840,6 +5280,46 @@ const endpoints: Endpoints = { "prerelease", "discussion_category_name", "generate_release_notes", + "make_latest", + ], + }, + }, + createRepoRuleset: { + method: "post", + path: "/repos/{owner}/{repo}/rulesets", + parameters: { + path: ["owner", "repo"], + query: [], + body: [ + "name", + "target", + "enforcement", + "bypass_mode", + "bypass_actors", + "bypass_actors[].actor_id", + "bypass_actors[].actor_type", + "conditions", + "conditions.ref_name", + "conditions.ref_name.include", + "conditions.ref_name.exclude", + "rules", + "rules[].type", + "rules[].parameters", + "rules[].parameters.update_allows_fetch_and_merge", + "rules[].parameters.required_deployment_environments", + "rules[].parameters.dismiss_stale_reviews_on_push", + "rules[].parameters.require_code_owner_review", + "rules[].parameters.require_last_push_approval", + "rules[].parameters.required_approving_review_count", + "rules[].parameters.required_review_thread_resolution", + "rules[].parameters.required_status_checks", + "rules[].parameters.required_status_checks[].context", + "rules[].parameters.required_status_checks[].integration_id", + "rules[].parameters.strict_required_status_checks_policy", + "rules[].parameters.name", + "rules[].parameters.negate", + "rules[].parameters.operator", + "rules[].parameters.pattern", ], }, }, @@ -4996,6 +5476,11 @@ const endpoints: Endpoints = { body: [], }, }, + deleteOrgRuleset: { + method: "delete", + path: "/orgs/{org}/rulesets/{ruleset_id}", + parameters: { path: ["org", "ruleset_id"], query: [], body: [] }, + }, deletePagesSite: { method: "delete", path: "/repos/{owner}/{repo}/pages", @@ -5020,6 +5505,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/releases/assets/{asset_id}", parameters: { path: ["owner", "repo", "asset_id"], query: [], body: [] }, }, + deleteRepoRuleset: { + method: "delete", + path: "/repos/{owner}/{repo}/rulesets/{ruleset_id}", + parameters: { + path: ["owner", "repo", "ruleset_id"], + query: [], + body: [], + }, + }, deleteTagProtection: { method: "delete", path: "/repos/{owner}/{repo}/tags/protection/{tag_protection_id}", @@ -5039,6 +5533,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/automated-security-fixes", parameters: { path: ["owner", "repo"], query: [], body: [] }, }, + disableDeploymentProtectionRule: { + method: "delete", + path: "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", + parameters: { + path: ["environment_name", "repo", "owner", "protection_rule_id"], + query: [], + body: [], + }, + }, disableLfsForRepo: { method: "delete", path: "/repos/{owner}/{repo}/lfs", @@ -5108,6 +5611,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", parameters: { path: ["owner", "repo", "branch"], query: [], body: [] }, }, + getAllDeploymentProtectionRules: { + method: "get", + path: "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", + parameters: { + path: ["environment_name", "repo", "owner"], + query: [], + body: [], + }, + }, getAllEnvironments: { method: "get", path: "/repos/{owner}/{repo}/environments", @@ -5155,6 +5667,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/branches/{branch}/protection", parameters: { path: ["owner", "repo", "branch"], query: [], body: [] }, }, + getBranchRules: { + method: "get", + path: "/repos/{owner}/{repo}/rules/branches/{branch}", + parameters: { + path: ["owner", "repo", "branch"], + query: ["per_page", "page"], + body: [], + }, + }, getClones: { method: "get", path: "/repos/{owner}/{repo}/traffic/clones", @@ -5222,6 +5743,15 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/stats/contributors", parameters: { path: ["owner", "repo"], query: [], body: [] }, }, + getCustomDeploymentProtectionRule: { + method: "get", + path: "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", + parameters: { + path: ["owner", "repo", "environment_name", "protection_rule_id"], + query: [], + body: [], + }, + }, getDeployKey: { method: "get", path: "/repos/{owner}/{repo}/keys/{key_id}", @@ -5273,6 +5803,16 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/releases/latest", parameters: { path: ["owner", "repo"], query: [], body: [] }, }, + getOrgRuleset: { + method: "get", + path: "/orgs/{org}/rulesets/{ruleset_id}", + parameters: { path: ["org", "ruleset_id"], query: [], body: [] }, + }, + getOrgRulesets: { + method: "get", + path: "/orgs/{org}/rulesets", + parameters: { path: ["org"], query: ["per_page", "page"], body: [] }, + }, getPages: { method: "get", path: "/repos/{owner}/{repo}/pages", @@ -5332,6 +5872,24 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/releases/tags/{tag}", parameters: { path: ["owner", "repo", "tag"], query: [], body: [] }, }, + getRepoRuleset: { + method: "get", + path: "/repos/{owner}/{repo}/rulesets/{ruleset_id}", + parameters: { + path: ["owner", "repo", "ruleset_id"], + query: ["includes_parents"], + body: [], + }, + }, + getRepoRulesets: { + method: "get", + path: "/repos/{owner}/{repo}/rulesets", + parameters: { + path: ["owner", "repo"], + query: ["per_page", "page", "includes_parents"], + body: [], + }, + }, getStatusChecksProtection: { method: "get", path: "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", @@ -5445,7 +6003,16 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/commits", parameters: { path: ["owner", "repo"], - query: ["sha", "path", "author", "since", "until", "per_page", "page"], + query: [ + "sha", + "path", + "author", + "committer", + "since", + "until", + "per_page", + "page", + ], body: [], }, }, @@ -5458,6 +6025,15 @@ const endpoints: Endpoints = { body: [], }, }, + listCustomDeploymentRuleIntegrations: { + method: "get", + path: "/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/apps", + parameters: { + path: ["environment_name", "repo", "owner"], + query: ["page", "per_page"], + body: [], + }, + }, listDeployKeys: { method: "get", path: "/repos/{owner}/{repo}/keys", @@ -5628,7 +6204,7 @@ const endpoints: Endpoints = { path: "/repos/{owner}/{repo}/hooks/{hook_id}/deliveries", parameters: { path: ["owner", "repo", "hook_id"], - query: ["per_page", "cursor"], + query: ["per_page", "cursor", "redelivery"], body: [], }, }, @@ -5786,7 +6362,7 @@ const endpoints: Endpoints = { parameters: { path: ["owner", "repo"], query: [], - body: ["new_owner", "team_ids"], + body: ["new_owner", "new_name", "team_ids"], }, }, update: { @@ -5852,6 +6428,7 @@ const endpoints: Endpoints = { "required_pull_request_reviews.dismiss_stale_reviews", "required_pull_request_reviews.require_code_owner_reviews", "required_pull_request_reviews.required_approving_review_count", + "required_pull_request_reviews.require_last_push_approval", "required_pull_request_reviews.bypass_pull_request_allowances", "required_pull_request_reviews.bypass_pull_request_allowances.users", "required_pull_request_reviews.bypass_pull_request_allowances.teams", @@ -5865,6 +6442,8 @@ const endpoints: Endpoints = { "allow_deletions", "block_creations", "required_conversation_resolution", + "lock_branch", + "allow_fork_syncing", ], }, }, @@ -5892,7 +6471,7 @@ const endpoints: Endpoints = { parameters: { path: ["owner", "repo"], query: [], - body: ["cname", "https_enforced", "public", "build_type", "source"], + body: ["cname", "https_enforced", "build_type", "source", "public"], }, }, updateInvitation: { @@ -5904,6 +6483,41 @@ const endpoints: Endpoints = { body: ["permissions"], }, }, + updateOrgRuleset: { + method: "put", + path: "/orgs/{org}/rulesets/{ruleset_id}", + parameters: { + path: ["org", "ruleset_id"], + query: [], + body: [ + "name", + "target", + "enforcement", + "bypass_actors", + "bypass_actors[].actor_id", + "bypass_actors[].actor_type", + "conditions", + "rules", + "rules[].type", + "rules[].parameters", + "rules[].parameters.update_allows_fetch_and_merge", + "rules[].parameters.required_deployment_environments", + "rules[].parameters.dismiss_stale_reviews_on_push", + "rules[].parameters.require_code_owner_review", + "rules[].parameters.require_last_push_approval", + "rules[].parameters.required_approving_review_count", + "rules[].parameters.required_review_thread_resolution", + "rules[].parameters.required_status_checks", + "rules[].parameters.required_status_checks[].context", + "rules[].parameters.required_status_checks[].integration_id", + "rules[].parameters.strict_required_status_checks_policy", + "rules[].parameters.name", + "rules[].parameters.negate", + "rules[].parameters.operator", + "rules[].parameters.pattern", + ], + }, + }, updatePullRequestReviewProtection: { method: "patch", path: "/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", @@ -5918,6 +6532,7 @@ const endpoints: Endpoints = { "dismiss_stale_reviews", "require_code_owner_reviews", "required_approving_review_count", + "require_last_push_approval", "bypass_pull_request_allowances", "bypass_pull_request_allowances.users", "bypass_pull_request_allowances.teams", @@ -5938,6 +6553,7 @@ const endpoints: Endpoints = { "body", "draft", "prerelease", + "make_latest", "discussion_category_name", ], }, @@ -5951,6 +6567,45 @@ const endpoints: Endpoints = { body: ["name", "label", "state"], }, }, + updateRepoRuleset: { + method: "put", + path: "/repos/{owner}/{repo}/rulesets/{ruleset_id}", + parameters: { + path: ["owner", "repo", "ruleset_id"], + query: [], + body: [ + "name", + "target", + "enforcement", + "bypass_mode", + "bypass_actors", + "bypass_actors[].actor_id", + "bypass_actors[].actor_type", + "conditions", + "conditions.ref_name", + "conditions.ref_name.include", + "conditions.ref_name.exclude", + "rules", + "rules[].type", + "rules[].parameters", + "rules[].parameters.update_allows_fetch_and_merge", + "rules[].parameters.required_deployment_environments", + "rules[].parameters.dismiss_stale_reviews_on_push", + "rules[].parameters.require_code_owner_review", + "rules[].parameters.require_last_push_approval", + "rules[].parameters.required_approving_review_count", + "rules[].parameters.required_review_thread_resolution", + "rules[].parameters.required_status_checks", + "rules[].parameters.required_status_checks[].context", + "rules[].parameters.required_status_checks[].integration_id", + "rules[].parameters.strict_required_status_checks_policy", + "rules[].parameters.name", + "rules[].parameters.negate", + "rules[].parameters.operator", + "rules[].parameters.pattern", + ], + }, + }, updateStatusCheckPotection: { method: "patch", path: "/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", @@ -6167,6 +6822,97 @@ const endpoints: Endpoints = { }, }, }, + securityAdvisories: { + createPrivateVulnerabilityReport: { + method: "post", + path: "/repos/{owner}/{repo}/security-advisories/reports", + parameters: { + path: ["owner", "repo"], + query: [], + body: [ + "summary", + "description", + "vulnerabilities", + "vulnerabilities[].package", + "vulnerabilities[].package.ecosystem", + "vulnerabilities[].package.name", + "vulnerabilities[].vulnerable_version_range", + "vulnerabilities[].patched_versions", + "vulnerabilities[].vulnerable_functions", + "cwe_ids", + "severity", + "cvss_vector_string", + ], + }, + }, + createRepositoryAdvisory: { + method: "post", + path: "/repos/{owner}/{repo}/security-advisories", + parameters: { + path: ["owner", "repo"], + query: [], + body: [ + "summary", + "description", + "cve_id", + "vulnerabilities", + "vulnerabilities[].package", + "vulnerabilities[].package.ecosystem", + "vulnerabilities[].package.name", + "vulnerabilities[].vulnerable_version_range", + "vulnerabilities[].patched_versions", + "vulnerabilities[].vulnerable_functions", + "cwe_ids", + "credits", + "credits[].login", + "credits[].type", + "severity", + "cvss_vector_string", + ], + }, + }, + getRepositoryAdvisory: { + method: "get", + path: "/repos/{owner}/{repo}/security-advisories/{ghsa_id}", + parameters: { path: ["owner", "repo", "ghsa_id"], query: [], body: [] }, + }, + listRepositoryAdvisories: { + method: "get", + path: "/repos/{owner}/{repo}/security-advisories", + parameters: { + path: ["owner", "repo"], + query: ["direction", "sort", "before", "after", "per_page", "state"], + body: [], + }, + }, + updateRepositoryAdvisory: { + method: "patch", + path: "/repos/{owner}/{repo}/security-advisories/{ghsa_id}", + parameters: { + path: ["owner", "repo", "ghsa_id"], + query: [], + body: [ + "summary", + "description", + "cve_id", + "vulnerabilities", + "vulnerabilities[].package", + "vulnerabilities[].package.ecosystem", + "vulnerabilities[].package.name", + "vulnerabilities[].vulnerable_version_range", + "vulnerabilities[].patched_versions", + "vulnerabilities[].vulnerable_functions", + "cwe_ids", + "credits", + "credits[].login", + "credits[].type", + "severity", + "cvss_vector_string", + "state", + ], + }, + }, + }, teams: { addOrUpdateMembershipForUserInOrg: { method: "put", @@ -6225,6 +6971,7 @@ const endpoints: Endpoints = { "maintainers", "repo_names", "privacy", + "notification_setting", "permission", "parent_team_id", ], @@ -6431,6 +7178,7 @@ const endpoints: Endpoints = { "name", "description", "privacy", + "notification_setting", "permission", "parent_team_id", ], @@ -6448,6 +7196,11 @@ const endpoints: Endpoints = { path: "/user/emails", parameters: { path: [], query: [], body: ["emails"] }, }, + addSocialAccountForAuthenticatedUser: { + method: "post", + path: "/user/social_accounts", + parameters: { path: [], query: [], body: ["account_urls"] }, + }, block: { method: "put", path: "/user/blocks/{username}", @@ -6523,6 +7276,11 @@ const endpoints: Endpoints = { path: "/user/keys/{key_id}", parameters: { path: ["key_id"], query: [], body: [] }, }, + deleteSocialAccountForAuthenticatedUser: { + method: "delete", + path: "/user/social_accounts", + parameters: { path: [], query: [], body: ["account_urls"] }, + }, deleteSshSigningKeyForAuthenticatedUser: { method: "delete", path: "/user/ssh_signing_keys/{ssh_signing_key_id}", @@ -6585,12 +7343,12 @@ const endpoints: Endpoints = { listBlockedByAuthenticated: { method: "get", path: "/user/blocks", - parameters: { path: [], query: [], body: [] }, + parameters: { path: [], query: ["per_page", "page"], body: [] }, }, listBlockedByAuthenticatedUser: { method: "get", path: "/user/blocks", - parameters: { path: [], query: [], body: [] }, + parameters: { path: [], query: ["per_page", "page"], body: [] }, }, listEmailsForAuthenticated: { method: "get", @@ -6667,6 +7425,16 @@ const endpoints: Endpoints = { path: "/user/keys", parameters: { path: [], query: ["per_page", "page"], body: [] }, }, + listSocialAccountsForAuthenticatedUser: { + method: "get", + path: "/user/social_accounts", + parameters: { path: [], query: ["per_page", "page"], body: [] }, + }, + listSocialAccountsForUser: { + method: "get", + path: "/users/{username}/social_accounts", + parameters: { path: ["username"], query: ["per_page", "page"], body: [] }, + }, listSshSigningKeysForAuthenticatedUser: { method: "get", path: "/user/ssh_signing_keys", diff --git a/src/moctokit/generated/endpoint-request.ts b/src/moctokit/generated/endpoint-request.ts index c923486..fcad381 100644 --- a/src/moctokit/generated/endpoint-request.ts +++ b/src/moctokit/generated/endpoint-request.ts @@ -8,16 +8,24 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", "post">(baseUrl, endpoints["actions"]["addCustomLabelsToSelfHostedRunnerForRepo"], allowUnmocked).request, addSelectedRepoToOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}", "put">(baseUrl, endpoints["actions"]["addSelectedRepoToOrgSecret"], allowUnmocked).request, + addSelectedRepoToOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", "put">(baseUrl, endpoints["actions"]["addSelectedRepoToOrgVariable"], allowUnmocked).request, + addSelectedRepoToRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", "put">(baseUrl, endpoints["actions"]["addSelectedRepoToRequiredWorkflow"], allowUnmocked).request, approveWorkflowRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/approve", "post">(baseUrl, endpoints["actions"]["approveWorkflowRun"], allowUnmocked).request, cancelWorkflowRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/cancel", "post">(baseUrl, endpoints["actions"]["cancelWorkflowRun"], allowUnmocked).request, + createEnvironmentVariable: + new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/variables", "post">(baseUrl, endpoints["actions"]["createEnvironmentVariable"], allowUnmocked).request, createOrUpdateEnvironmentSecret: new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", "put">(baseUrl, endpoints["actions"]["createOrUpdateEnvironmentSecret"], allowUnmocked).request, createOrUpdateOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}", "put">(baseUrl, endpoints["actions"]["createOrUpdateOrgSecret"], allowUnmocked).request, createOrUpdateRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/secrets/{secret_name}", "put">(baseUrl, endpoints["actions"]["createOrUpdateRepoSecret"], allowUnmocked).request, + createOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables", "post">(baseUrl, endpoints["actions"]["createOrgVariable"], allowUnmocked).request, createRegistrationTokenForOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/runners/registration-token", "post">(baseUrl, endpoints["actions"]["createRegistrationTokenForOrg"], allowUnmocked).request, createRegistrationTokenForRepo: @@ -26,6 +34,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/actions/runners/remove-token", "post">(baseUrl, endpoints["actions"]["createRemoveTokenForOrg"], allowUnmocked).request, createRemoveTokenForRepo: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/remove-token", "post">(baseUrl, endpoints["actions"]["createRemoveTokenForRepo"], allowUnmocked).request, + createRepoVariable: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/variables", "post">(baseUrl, endpoints["actions"]["createRepoVariable"], allowUnmocked).request, + createRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows", "post">(baseUrl, endpoints["actions"]["createRequiredWorkflow"], allowUnmocked).request, createWorkflowDispatch: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/workflows/{workflow_id}/dispatches", "post">(baseUrl, endpoints["actions"]["createWorkflowDispatch"], allowUnmocked).request, deleteActionsCacheById: @@ -36,10 +48,18 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/artifacts/{artifact_id}", "delete">(baseUrl, endpoints["actions"]["deleteArtifact"], allowUnmocked).request, deleteEnvironmentSecret: new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", "delete">(baseUrl, endpoints["actions"]["deleteEnvironmentSecret"], allowUnmocked).request, + deleteEnvironmentVariable: + new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "delete">(baseUrl, endpoints["actions"]["deleteEnvironmentVariable"], allowUnmocked).request, deleteOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}", "delete">(baseUrl, endpoints["actions"]["deleteOrgSecret"], allowUnmocked).request, + deleteOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}", "delete">(baseUrl, endpoints["actions"]["deleteOrgVariable"], allowUnmocked).request, deleteRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/secrets/{secret_name}", "delete">(baseUrl, endpoints["actions"]["deleteRepoSecret"], allowUnmocked).request, + deleteRepoVariable: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/variables/{name}", "delete">(baseUrl, endpoints["actions"]["deleteRepoVariable"], allowUnmocked).request, + deleteRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}", "delete">(baseUrl, endpoints["actions"]["deleteRequiredWorkflow"], allowUnmocked).request, deleteSelfHostedRunnerFromOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/runners/{runner_id}", "delete">(baseUrl, endpoints["actions"]["deleteSelfHostedRunnerFromOrg"], allowUnmocked).request, deleteSelfHostedRunnerFromRepo: @@ -64,14 +84,18 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/actions/permissions/repositories/{repository_id}", "put">(baseUrl, endpoints["actions"]["enableSelectedRepositoryGithubActionsOrganization"], allowUnmocked).request, enableWorkflow: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/workflows/{workflow_id}/enable", "put">(baseUrl, endpoints["actions"]["enableWorkflow"], allowUnmocked).request, + generateRunnerJitconfigForEnterprise: + new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/generate-jitconfig", "post">(baseUrl, endpoints["actions"]["generateRunnerJitconfigForEnterprise"], allowUnmocked).request, + generateRunnerJitconfigForOrg: + new MoctokitRequestMocker<"/orgs/{org}/actions/runners/generate-jitconfig", "post">(baseUrl, endpoints["actions"]["generateRunnerJitconfigForOrg"], allowUnmocked).request, + generateRunnerJitconfigForRepo: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/generate-jitconfig", "post">(baseUrl, endpoints["actions"]["generateRunnerJitconfigForRepo"], allowUnmocked).request, getActionsCacheList: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/caches", "get">(baseUrl, endpoints["actions"]["getActionsCacheList"], allowUnmocked).request, getActionsCacheUsage: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/cache/usage", "get">(baseUrl, endpoints["actions"]["getActionsCacheUsage"], allowUnmocked).request, getActionsCacheUsageByRepoForOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/cache/usage-by-repository", "get">(baseUrl, endpoints["actions"]["getActionsCacheUsageByRepoForOrg"], allowUnmocked).request, - getActionsCacheUsageForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/cache/usage", "get">(baseUrl, endpoints["actions"]["getActionsCacheUsageForEnterprise"], allowUnmocked).request, getActionsCacheUsageForOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/cache/usage", "get">(baseUrl, endpoints["actions"]["getActionsCacheUsageForOrg"], allowUnmocked).request, getAllowedActionsOrganization: @@ -84,8 +108,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/secrets/public-key", "get">(baseUrl, endpoints["actions"]["getEnvironmentPublicKey"], allowUnmocked).request, getEnvironmentSecret: new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/secrets/{secret_name}", "get">(baseUrl, endpoints["actions"]["getEnvironmentSecret"], allowUnmocked).request, - getGithubActionsDefaultWorkflowPermissionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/workflow", "get">(baseUrl, endpoints["actions"]["getGithubActionsDefaultWorkflowPermissionsEnterprise"], allowUnmocked).request, + getEnvironmentVariable: + new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "get">(baseUrl, endpoints["actions"]["getEnvironmentVariable"], allowUnmocked).request, getGithubActionsDefaultWorkflowPermissionsOrganization: new MoctokitRequestMocker<"/orgs/{org}/actions/permissions/workflow", "get">(baseUrl, endpoints["actions"]["getGithubActionsDefaultWorkflowPermissionsOrganization"], allowUnmocked).request, getGithubActionsDefaultWorkflowPermissionsRepository: @@ -100,14 +124,24 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/public-key", "get">(baseUrl, endpoints["actions"]["getOrgPublicKey"], allowUnmocked).request, getOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}", "get">(baseUrl, endpoints["actions"]["getOrgSecret"], allowUnmocked).request, + getOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}", "get">(baseUrl, endpoints["actions"]["getOrgVariable"], allowUnmocked).request, getPendingDeploymentsForRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", "get">(baseUrl, endpoints["actions"]["getPendingDeploymentsForRun"], allowUnmocked).request, getRepoPermissions: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/permissions", "get">(baseUrl, endpoints["actions"]["getRepoPermissions"], allowUnmocked).request, getRepoPublicKey: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/secrets/public-key", "get">(baseUrl, endpoints["actions"]["getRepoPublicKey"], allowUnmocked).request, + getRepoRequiredWorkflow: + new MoctokitRequestMocker<"/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}", "get">(baseUrl, endpoints["actions"]["getRepoRequiredWorkflow"], allowUnmocked).request, + getRepoRequiredWorkflowUsage: + new MoctokitRequestMocker<"/repos/{org}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/timing", "get">(baseUrl, endpoints["actions"]["getRepoRequiredWorkflowUsage"], allowUnmocked).request, getRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/secrets/{secret_name}", "get">(baseUrl, endpoints["actions"]["getRepoSecret"], allowUnmocked).request, + getRepoVariable: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/variables/{name}", "get">(baseUrl, endpoints["actions"]["getRepoVariable"], allowUnmocked).request, + getRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}", "get">(baseUrl, endpoints["actions"]["getRequiredWorkflow"], allowUnmocked).request, getReviewsForRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/approvals", "get">(baseUrl, endpoints["actions"]["getReviewsForRun"], allowUnmocked).request, getSelfHostedRunnerForOrg: @@ -130,6 +164,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/artifacts", "get">(baseUrl, endpoints["actions"]["listArtifactsForRepo"], allowUnmocked).request, listEnvironmentSecrets: new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/secrets", "get">(baseUrl, endpoints["actions"]["listEnvironmentSecrets"], allowUnmocked).request, + listEnvironmentVariables: + new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/variables", "get">(baseUrl, endpoints["actions"]["listEnvironmentVariables"], allowUnmocked).request, listJobsForWorkflowRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/jobs", "get">(baseUrl, endpoints["actions"]["listJobsForWorkflowRun"], allowUnmocked).request, listJobsForWorkflowRunAttempt: @@ -140,18 +176,36 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", "get">(baseUrl, endpoints["actions"]["listLabelsForSelfHostedRunnerForRepo"], allowUnmocked).request, listOrgSecrets: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets", "get">(baseUrl, endpoints["actions"]["listOrgSecrets"], allowUnmocked).request, + listOrgVariables: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables", "get">(baseUrl, endpoints["actions"]["listOrgVariables"], allowUnmocked).request, + listRepoOrganizationSecrets: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/organization-secrets", "get">(baseUrl, endpoints["actions"]["listRepoOrganizationSecrets"], allowUnmocked).request, + listRepoOrganizationVariables: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/organization-variables", "get">(baseUrl, endpoints["actions"]["listRepoOrganizationVariables"], allowUnmocked).request, + listRepoRequiredWorkflows: + new MoctokitRequestMocker<"/repos/{org}/{repo}/actions/required_workflows", "get">(baseUrl, endpoints["actions"]["listRepoRequiredWorkflows"], allowUnmocked).request, listRepoSecrets: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/secrets", "get">(baseUrl, endpoints["actions"]["listRepoSecrets"], allowUnmocked).request, + listRepoVariables: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/variables", "get">(baseUrl, endpoints["actions"]["listRepoVariables"], allowUnmocked).request, listRepoWorkflows: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/workflows", "get">(baseUrl, endpoints["actions"]["listRepoWorkflows"], allowUnmocked).request, + listRequiredWorkflowRuns: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/required_workflows/{required_workflow_id_for_repo}/runs", "get">(baseUrl, endpoints["actions"]["listRequiredWorkflowRuns"], allowUnmocked).request, + listRequiredWorkflows: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows", "get">(baseUrl, endpoints["actions"]["listRequiredWorkflows"], allowUnmocked).request, listRunnerApplicationsForOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/runners/downloads", "get">(baseUrl, endpoints["actions"]["listRunnerApplicationsForOrg"], allowUnmocked).request, listRunnerApplicationsForRepo: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/downloads", "get">(baseUrl, endpoints["actions"]["listRunnerApplicationsForRepo"], allowUnmocked).request, listSelectedReposForOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}/repositories", "get">(baseUrl, endpoints["actions"]["listSelectedReposForOrgSecret"], allowUnmocked).request, + listSelectedReposForOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}/repositories", "get">(baseUrl, endpoints["actions"]["listSelectedReposForOrgVariable"], allowUnmocked).request, listSelectedRepositoriesEnabledGithubActionsOrganization: new MoctokitRequestMocker<"/orgs/{org}/actions/permissions/repositories", "get">(baseUrl, endpoints["actions"]["listSelectedRepositoriesEnabledGithubActionsOrganization"], allowUnmocked).request, + listSelectedRepositoriesRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", "get">(baseUrl, endpoints["actions"]["listSelectedRepositoriesRequiredWorkflow"], allowUnmocked).request, listSelfHostedRunnersForOrg: new MoctokitRequestMocker<"/orgs/{org}/actions/runners", "get">(baseUrl, endpoints["actions"]["listSelfHostedRunnersForOrg"], allowUnmocked).request, listSelfHostedRunnersForRepo: @@ -178,6 +232,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/{runner_id}/labels/{name}", "delete">(baseUrl, endpoints["actions"]["removeCustomLabelFromSelfHostedRunnerForRepo"], allowUnmocked).request, removeSelectedRepoFromOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}/repositories/{repository_id}", "delete">(baseUrl, endpoints["actions"]["removeSelectedRepoFromOrgSecret"], allowUnmocked).request, + removeSelectedRepoFromOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}/repositories/{repository_id}", "delete">(baseUrl, endpoints["actions"]["removeSelectedRepoFromOrgVariable"], allowUnmocked).request, + removeSelectedRepoFromRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories/{repository_id}", "delete">(baseUrl, endpoints["actions"]["removeSelectedRepoFromRequiredWorkflow"], allowUnmocked).request, + reviewCustomGatesForRun: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/deployment_protection_rule", "post">(baseUrl, endpoints["actions"]["reviewCustomGatesForRun"], allowUnmocked).request, reviewPendingDeploymentsForRun: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runs/{run_id}/pending_deployments", "post">(baseUrl, endpoints["actions"]["reviewPendingDeploymentsForRun"], allowUnmocked).request, setAllowedActionsOrganization: @@ -188,8 +248,6 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/actions/runners/{runner_id}/labels", "put">(baseUrl, endpoints["actions"]["setCustomLabelsForSelfHostedRunnerForOrg"], allowUnmocked).request, setCustomLabelsForSelfHostedRunnerForRepo: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/runners/{runner_id}/labels", "put">(baseUrl, endpoints["actions"]["setCustomLabelsForSelfHostedRunnerForRepo"], allowUnmocked).request, - setGithubActionsDefaultWorkflowPermissionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/workflow", "put">(baseUrl, endpoints["actions"]["setGithubActionsDefaultWorkflowPermissionsEnterprise"], allowUnmocked).request, setGithubActionsDefaultWorkflowPermissionsOrganization: new MoctokitRequestMocker<"/orgs/{org}/actions/permissions/workflow", "put">(baseUrl, endpoints["actions"]["setGithubActionsDefaultWorkflowPermissionsOrganization"], allowUnmocked).request, setGithubActionsDefaultWorkflowPermissionsRepository: @@ -200,10 +258,22 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/permissions", "put">(baseUrl, endpoints["actions"]["setGithubActionsPermissionsRepository"], allowUnmocked).request, setSelectedReposForOrgSecret: new MoctokitRequestMocker<"/orgs/{org}/actions/secrets/{secret_name}/repositories", "put">(baseUrl, endpoints["actions"]["setSelectedReposForOrgSecret"], allowUnmocked).request, + setSelectedReposForOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}/repositories", "put">(baseUrl, endpoints["actions"]["setSelectedReposForOrgVariable"], allowUnmocked).request, + setSelectedReposToRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}/repositories", "put">(baseUrl, endpoints["actions"]["setSelectedReposToRequiredWorkflow"], allowUnmocked).request, setSelectedRepositoriesEnabledGithubActionsOrganization: new MoctokitRequestMocker<"/orgs/{org}/actions/permissions/repositories", "put">(baseUrl, endpoints["actions"]["setSelectedRepositoriesEnabledGithubActionsOrganization"], allowUnmocked).request, setWorkflowAccessToRepository: new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/permissions/access", "put">(baseUrl, endpoints["actions"]["setWorkflowAccessToRepository"], allowUnmocked).request, + updateEnvironmentVariable: + new MoctokitRequestMocker<"/repositories/{repository_id}/environments/{environment_name}/variables/{name}", "patch">(baseUrl, endpoints["actions"]["updateEnvironmentVariable"], allowUnmocked).request, + updateOrgVariable: + new MoctokitRequestMocker<"/orgs/{org}/actions/variables/{name}", "patch">(baseUrl, endpoints["actions"]["updateOrgVariable"], allowUnmocked).request, + updateRepoVariable: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/actions/variables/{name}", "patch">(baseUrl, endpoints["actions"]["updateRepoVariable"], allowUnmocked).request, + updateRequiredWorkflow: + new MoctokitRequestMocker<"/orgs/{org}/actions/required_workflows/{required_workflow_id}", "patch">(baseUrl, endpoints["actions"]["updateRequiredWorkflow"], allowUnmocked).request, }, activity: { checkRepoIsStarredByAuthenticatedUser: @@ -312,6 +382,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/marketplace_listing/stubbed/plans/{plan_id}/accounts", "get">(baseUrl, endpoints["apps"]["listAccountsForPlanStubbed"], allowUnmocked).request, listInstallationReposForAuthenticatedUser: new MoctokitRequestMocker<"/user/installations/{installation_id}/repositories", "get">(baseUrl, endpoints["apps"]["listInstallationReposForAuthenticatedUser"], allowUnmocked).request, + listInstallationRequestsForAuthenticatedApp: + new MoctokitRequestMocker<"/app/installation-requests", "get">(baseUrl, endpoints["apps"]["listInstallationRequestsForAuthenticatedApp"], allowUnmocked).request, listInstallations: new MoctokitRequestMocker<"/app/installations", "get">(baseUrl, endpoints["apps"]["listInstallations"], allowUnmocked).request, listInstallationsForAuthenticatedUser: @@ -352,10 +424,6 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/settings/billing/actions", "get">(baseUrl, endpoints["billing"]["getGithubActionsBillingOrg"], allowUnmocked).request, getGithubActionsBillingUser: new MoctokitRequestMocker<"/users/{username}/settings/billing/actions", "get">(baseUrl, endpoints["billing"]["getGithubActionsBillingUser"], allowUnmocked).request, - getGithubAdvancedSecurityBillingGhe: - new MoctokitRequestMocker<"/enterprises/{enterprise}/settings/billing/advanced-security", "get">(baseUrl, endpoints["billing"]["getGithubAdvancedSecurityBillingGhe"], allowUnmocked).request, - getGithubAdvancedSecurityBillingOrg: - new MoctokitRequestMocker<"/orgs/{org}/settings/billing/advanced-security", "get">(baseUrl, endpoints["billing"]["getGithubAdvancedSecurityBillingOrg"], allowUnmocked).request, getGithubPackagesBillingOrg: new MoctokitRequestMocker<"/orgs/{org}/settings/billing/packages", "get">(baseUrl, endpoints["billing"]["getGithubPackagesBillingOrg"], allowUnmocked).request, getGithubPackagesBillingUser: @@ -399,12 +467,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/analyses/{analysis_id}", "get">(baseUrl, endpoints["codeScanning"]["getAnalysis"], allowUnmocked).request, getCodeqlDatabase: new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/codeql/databases/{language}", "get">(baseUrl, endpoints["codeScanning"]["getCodeqlDatabase"], allowUnmocked).request, + getDefaultSetup: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/default-setup", "get">(baseUrl, endpoints["codeScanning"]["getDefaultSetup"], allowUnmocked).request, getSarif: new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/sarifs/{sarif_id}", "get">(baseUrl, endpoints["codeScanning"]["getSarif"], allowUnmocked).request, listAlertInstances: new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances", "get">(baseUrl, endpoints["codeScanning"]["listAlertInstances"], allowUnmocked).request, - listAlertsForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/code-scanning/alerts", "get">(baseUrl, endpoints["codeScanning"]["listAlertsForEnterprise"], allowUnmocked).request, listAlertsForOrg: new MoctokitRequestMocker<"/orgs/{org}/code-scanning/alerts", "get">(baseUrl, endpoints["codeScanning"]["listAlertsForOrg"], allowUnmocked).request, listAlertsForRepo: @@ -417,6 +485,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/analyses", "get">(baseUrl, endpoints["codeScanning"]["listRecentAnalyses"], allowUnmocked).request, updateAlert: new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}", "patch">(baseUrl, endpoints["codeScanning"]["updateAlert"], allowUnmocked).request, + updateDefaultSetup: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/default-setup", "patch">(baseUrl, endpoints["codeScanning"]["updateDefaultSetup"], allowUnmocked).request, uploadSarif: new MoctokitRequestMocker<"/repos/{owner}/{repo}/code-scanning/sarifs", "post">(baseUrl, endpoints["codeScanning"]["uploadSarif"], allowUnmocked).request, }, @@ -430,13 +500,13 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ addRepositoryForSecretForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", "put">(baseUrl, endpoints["codespaces"]["addRepositoryForSecretForAuthenticatedUser"], allowUnmocked).request, addSelectedRepoToOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", "put">(baseUrl, endpoints["codespaces"]["addSelectedRepoToOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", "put">(baseUrl, endpoints["codespaces"]["addSelectedRepoToOrgSecret"], allowUnmocked).request, codespaceMachinesForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}/machines", "get">(baseUrl, endpoints["codespaces"]["codespaceMachinesForAuthenticatedUser"], allowUnmocked).request, createForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces", "post">(baseUrl, endpoints["codespaces"]["createForAuthenticatedUser"], allowUnmocked).request, createOrUpdateOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}", "put">(baseUrl, endpoints["codespaces"]["createOrUpdateOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}", "put">(baseUrl, endpoints["codespaces"]["createOrUpdateOrgSecret"], allowUnmocked).request, createOrUpdateRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", "put">(baseUrl, endpoints["codespaces"]["createOrUpdateRepoSecret"], allowUnmocked).request, createOrUpdateSecretForAuthenticatedUser: @@ -445,26 +515,30 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/pulls/{pull_number}/codespaces", "post">(baseUrl, endpoints["codespaces"]["createWithPrForAuthenticatedUser"], allowUnmocked).request, createWithRepoForAuthenticatedUser: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces", "post">(baseUrl, endpoints["codespaces"]["createWithRepoForAuthenticatedUser"], allowUnmocked).request, + deleteCodespacesBillingUsers: + new MoctokitRequestMocker<"/orgs/{org}/codespaces/billing/selected_users", "delete">(baseUrl, endpoints["codespaces"]["deleteCodespacesBillingUsers"], allowUnmocked).request, deleteForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteForAuthenticatedUser"], allowUnmocked).request, deleteFromOrganization: new MoctokitRequestMocker<"/orgs/{org}/members/{username}/codespaces/{codespace_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteFromOrganization"], allowUnmocked).request, deleteOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteOrgSecret"], allowUnmocked).request, deleteRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces/secrets/{secret_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteRepoSecret"], allowUnmocked).request, deleteSecretForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets/{secret_name}", "delete">(baseUrl, endpoints["codespaces"]["deleteSecretForAuthenticatedUser"], allowUnmocked).request, exportForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}/exports", "post">(baseUrl, endpoints["codespaces"]["exportForAuthenticatedUser"], allowUnmocked).request, + getCodespacesForUserInOrg: + new MoctokitRequestMocker<"/orgs/{org}/members/{username}/codespaces", "get">(baseUrl, endpoints["codespaces"]["getCodespacesForUserInOrg"], allowUnmocked).request, getExportDetailsForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}/exports/{export_id}", "get">(baseUrl, endpoints["codespaces"]["getExportDetailsForAuthenticatedUser"], allowUnmocked).request, getForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}", "get">(baseUrl, endpoints["codespaces"]["getForAuthenticatedUser"], allowUnmocked).request, getOrgPublicKey: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/public-key", "get">(baseUrl, endpoints["codespaces"]["getOrgPublicKey"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/public-key", "get">(baseUrl, endpoints["codespaces"]["getOrgPublicKey"], allowUnmocked).request, getOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}", "get">(baseUrl, endpoints["codespaces"]["getOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}", "get">(baseUrl, endpoints["codespaces"]["getOrgSecret"], allowUnmocked).request, getPublicKeyForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets/public-key", "get">(baseUrl, endpoints["codespaces"]["getPublicKeyForAuthenticatedUser"], allowUnmocked).request, getRepoPublicKey: @@ -482,7 +556,7 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ listInRepositoryForAuthenticatedUser: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces", "get">(baseUrl, endpoints["codespaces"]["listInRepositoryForAuthenticatedUser"], allowUnmocked).request, listOrgSecrets: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets", "get">(baseUrl, endpoints["codespaces"]["listOrgSecrets"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets", "get">(baseUrl, endpoints["codespaces"]["listOrgSecrets"], allowUnmocked).request, listRepoSecrets: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces/secrets", "get">(baseUrl, endpoints["codespaces"]["listRepoSecrets"], allowUnmocked).request, listRepositoriesForSecretForAuthenticatedUser: @@ -490,19 +564,25 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ listSecretsForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets", "get">(baseUrl, endpoints["codespaces"]["listSecretsForAuthenticatedUser"], allowUnmocked).request, listSelectedReposForOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}/repositories", "get">(baseUrl, endpoints["codespaces"]["listSelectedReposForOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}/repositories", "get">(baseUrl, endpoints["codespaces"]["listSelectedReposForOrgSecret"], allowUnmocked).request, preFlightWithRepoForAuthenticatedUser: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces/new", "get">(baseUrl, endpoints["codespaces"]["preFlightWithRepoForAuthenticatedUser"], allowUnmocked).request, + publishForAuthenticatedUser: + new MoctokitRequestMocker<"/user/codespaces/{codespace_name}/publish", "post">(baseUrl, endpoints["codespaces"]["publishForAuthenticatedUser"], allowUnmocked).request, removeRepositoryForSecretForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets/{secret_name}/repositories/{repository_id}", "delete">(baseUrl, endpoints["codespaces"]["removeRepositoryForSecretForAuthenticatedUser"], allowUnmocked).request, removeSelectedRepoFromOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", "delete">(baseUrl, endpoints["codespaces"]["removeSelectedRepoFromOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}", "delete">(baseUrl, endpoints["codespaces"]["removeSelectedRepoFromOrgSecret"], allowUnmocked).request, repoMachinesForAuthenticatedUser: new MoctokitRequestMocker<"/repos/{owner}/{repo}/codespaces/machines", "get">(baseUrl, endpoints["codespaces"]["repoMachinesForAuthenticatedUser"], allowUnmocked).request, + setCodespacesBilling: + new MoctokitRequestMocker<"/orgs/{org}/codespaces/billing", "put">(baseUrl, endpoints["codespaces"]["setCodespacesBilling"], allowUnmocked).request, + setCodespacesBillingUsers: + new MoctokitRequestMocker<"/orgs/{org}/codespaces/billing/selected_users", "post">(baseUrl, endpoints["codespaces"]["setCodespacesBillingUsers"], allowUnmocked).request, setRepositoriesForSecretForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/secrets/{secret_name}/repositories", "put">(baseUrl, endpoints["codespaces"]["setRepositoriesForSecretForAuthenticatedUser"], allowUnmocked).request, setSelectedReposForOrgSecret: - new MoctokitRequestMocker<"/organizations/{org}/codespaces/secrets/{secret_name}/repositories", "put">(baseUrl, endpoints["codespaces"]["setSelectedReposForOrgSecret"], allowUnmocked).request, + new MoctokitRequestMocker<"/orgs/{org}/codespaces/secrets/{secret_name}/repositories", "put">(baseUrl, endpoints["codespaces"]["setSelectedReposForOrgSecret"], allowUnmocked).request, startForAuthenticatedUser: new MoctokitRequestMocker<"/user/codespaces/{codespace_name}/start", "post">(baseUrl, endpoints["codespaces"]["startForAuthenticatedUser"], allowUnmocked).request, stopForAuthenticatedUser: @@ -533,6 +613,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependabot/secrets/public-key", "get">(baseUrl, endpoints["dependabot"]["getRepoPublicKey"], allowUnmocked).request, getRepoSecret: new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependabot/secrets/{secret_name}", "get">(baseUrl, endpoints["dependabot"]["getRepoSecret"], allowUnmocked).request, + listAlertsForEnterprise: + new MoctokitRequestMocker<"/enterprises/{enterprise}/dependabot/alerts", "get">(baseUrl, endpoints["dependabot"]["listAlertsForEnterprise"], allowUnmocked).request, + listAlertsForOrg: + new MoctokitRequestMocker<"/orgs/{org}/dependabot/alerts", "get">(baseUrl, endpoints["dependabot"]["listAlertsForOrg"], allowUnmocked).request, listAlertsForRepo: new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependabot/alerts", "get">(baseUrl, endpoints["dependabot"]["listAlertsForRepo"], allowUnmocked).request, listOrgSecrets: @@ -553,40 +637,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependency-graph/snapshots", "post">(baseUrl, endpoints["dependencyGraph"]["createRepositorySnapshot"], allowUnmocked).request, diffRange: new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependency-graph/compare/{basehead}", "get">(baseUrl, endpoints["dependencyGraph"]["diffRange"], allowUnmocked).request, + exportSbom: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/dependency-graph/sbom", "get">(baseUrl, endpoints["dependencyGraph"]["exportSbom"], allowUnmocked).request, }, emojis: { get: new MoctokitRequestMocker<"/emojis", "get">(baseUrl, endpoints["emojis"]["get"], allowUnmocked).request, }, - enterpriseAdmin: { - addCustomLabelsToSelfHostedRunnerForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/{runner_id}/labels", "post">(baseUrl, endpoints["enterpriseAdmin"]["addCustomLabelsToSelfHostedRunnerForEnterprise"], allowUnmocked).request, - disableSelectedOrganizationGithubActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", "delete">(baseUrl, endpoints["enterpriseAdmin"]["disableSelectedOrganizationGithubActionsEnterprise"], allowUnmocked).request, - enableSelectedOrganizationGithubActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/organizations/{org_id}", "put">(baseUrl, endpoints["enterpriseAdmin"]["enableSelectedOrganizationGithubActionsEnterprise"], allowUnmocked).request, - getAllowedActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/selected-actions", "get">(baseUrl, endpoints["enterpriseAdmin"]["getAllowedActionsEnterprise"], allowUnmocked).request, - getGithubActionsPermissionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions", "get">(baseUrl, endpoints["enterpriseAdmin"]["getGithubActionsPermissionsEnterprise"], allowUnmocked).request, - getServerStatistics: - new MoctokitRequestMocker<"/enterprise-installation/{enterprise_or_org}/server-statistics", "get">(baseUrl, endpoints["enterpriseAdmin"]["getServerStatistics"], allowUnmocked).request, - listLabelsForSelfHostedRunnerForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/{runner_id}/labels", "get">(baseUrl, endpoints["enterpriseAdmin"]["listLabelsForSelfHostedRunnerForEnterprise"], allowUnmocked).request, - listSelectedOrganizationsEnabledGithubActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/organizations", "get">(baseUrl, endpoints["enterpriseAdmin"]["listSelectedOrganizationsEnabledGithubActionsEnterprise"], allowUnmocked).request, - removeAllCustomLabelsFromSelfHostedRunnerForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/{runner_id}/labels", "delete">(baseUrl, endpoints["enterpriseAdmin"]["removeAllCustomLabelsFromSelfHostedRunnerForEnterprise"], allowUnmocked).request, - removeCustomLabelFromSelfHostedRunnerForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/{runner_id}/labels/{name}", "delete">(baseUrl, endpoints["enterpriseAdmin"]["removeCustomLabelFromSelfHostedRunnerForEnterprise"], allowUnmocked).request, - setAllowedActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/selected-actions", "put">(baseUrl, endpoints["enterpriseAdmin"]["setAllowedActionsEnterprise"], allowUnmocked).request, - setCustomLabelsForSelfHostedRunnerForEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/runners/{runner_id}/labels", "put">(baseUrl, endpoints["enterpriseAdmin"]["setCustomLabelsForSelfHostedRunnerForEnterprise"], allowUnmocked).request, - setGithubActionsPermissionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions", "put">(baseUrl, endpoints["enterpriseAdmin"]["setGithubActionsPermissionsEnterprise"], allowUnmocked).request, - setSelectedOrganizationsEnabledGithubActionsEnterprise: - new MoctokitRequestMocker<"/enterprises/{enterprise}/actions/permissions/organizations", "put">(baseUrl, endpoints["enterpriseAdmin"]["setSelectedOrganizationsEnabledGithubActionsEnterprise"], allowUnmocked).request, - }, gists: { checkIsStarred: new MoctokitRequestMocker<"/gists/{gist_id}/star", "get">(baseUrl, endpoints["gists"]["checkIsStarred"], allowUnmocked).request, @@ -692,6 +748,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/issues/{issue_number}/labels", "post">(baseUrl, endpoints["issues"]["addLabels"], allowUnmocked).request, checkUserCanBeAssigned: new MoctokitRequestMocker<"/repos/{owner}/{repo}/assignees/{assignee}", "get">(baseUrl, endpoints["issues"]["checkUserCanBeAssigned"], allowUnmocked).request, + checkUserCanBeAssignedToIssue: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/issues/{issue_number}/assignees/{assignee}", "get">(baseUrl, endpoints["issues"]["checkUserCanBeAssignedToIssue"], allowUnmocked).request, create: new MoctokitRequestMocker<"/repos/{owner}/{repo}/issues", "post">(baseUrl, endpoints["issues"]["create"], allowUnmocked).request, createComment: @@ -777,6 +835,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ }, meta: { get: new MoctokitRequestMocker<"/meta", "get">(baseUrl, endpoints["meta"]["get"], allowUnmocked).request, + getAllVersions: + new MoctokitRequestMocker<"/versions", "get">(baseUrl, endpoints["meta"]["getAllVersions"], allowUnmocked).request, getOctocat: new MoctokitRequestMocker<"/octocat", "get">(baseUrl, endpoints["meta"]["getOctocat"], allowUnmocked).request, getZen: @@ -846,14 +906,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/public_members/{username}", "get">(baseUrl, endpoints["orgs"]["checkPublicMembershipForUser"], allowUnmocked).request, convertMemberToOutsideCollaborator: new MoctokitRequestMocker<"/orgs/{org}/outside_collaborators/{username}", "put">(baseUrl, endpoints["orgs"]["convertMemberToOutsideCollaborator"], allowUnmocked).request, - createCustomRole: - new MoctokitRequestMocker<"/orgs/{org}/custom_roles", "post">(baseUrl, endpoints["orgs"]["createCustomRole"], allowUnmocked).request, createInvitation: new MoctokitRequestMocker<"/orgs/{org}/invitations", "post">(baseUrl, endpoints["orgs"]["createInvitation"], allowUnmocked).request, createWebhook: new MoctokitRequestMocker<"/orgs/{org}/hooks", "post">(baseUrl, endpoints["orgs"]["createWebhook"], allowUnmocked).request, - deleteCustomRole: - new MoctokitRequestMocker<"/orgs/{org}/custom_roles/{role_id}", "delete">(baseUrl, endpoints["orgs"]["deleteCustomRole"], allowUnmocked).request, + delete: + new MoctokitRequestMocker<"/orgs/{org}", "delete">(baseUrl, endpoints["orgs"]["delete"], allowUnmocked).request, deleteWebhook: new MoctokitRequestMocker<"/orgs/{org}/hooks/{hook_id}", "delete">(baseUrl, endpoints["orgs"]["deleteWebhook"], allowUnmocked).request, enableOrDisableSecurityProductOnAllOrgRepos: @@ -874,12 +932,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/installations", "get">(baseUrl, endpoints["orgs"]["listAppInstallations"], allowUnmocked).request, listBlockedUsers: new MoctokitRequestMocker<"/orgs/{org}/blocks", "get">(baseUrl, endpoints["orgs"]["listBlockedUsers"], allowUnmocked).request, - listCustomRoles: - new MoctokitRequestMocker<"/organizations/{organization_id}/custom_roles", "get">(baseUrl, endpoints["orgs"]["listCustomRoles"], allowUnmocked).request, listFailedInvitations: new MoctokitRequestMocker<"/orgs/{org}/failed_invitations", "get">(baseUrl, endpoints["orgs"]["listFailedInvitations"], allowUnmocked).request, - listFineGrainedPermissions: - new MoctokitRequestMocker<"/orgs/{org}/fine_grained_permissions", "get">(baseUrl, endpoints["orgs"]["listFineGrainedPermissions"], allowUnmocked).request, listForAuthenticatedUser: new MoctokitRequestMocker<"/user/orgs", "get">(baseUrl, endpoints["orgs"]["listForAuthenticatedUser"], allowUnmocked).request, listForUser: @@ -892,6 +946,14 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/user/memberships/orgs", "get">(baseUrl, endpoints["orgs"]["listMembershipsForAuthenticatedUser"], allowUnmocked).request, listOutsideCollaborators: new MoctokitRequestMocker<"/orgs/{org}/outside_collaborators", "get">(baseUrl, endpoints["orgs"]["listOutsideCollaborators"], allowUnmocked).request, + listPatGrantRepositories: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-tokens/{pat_id}/repositories", "get">(baseUrl, endpoints["orgs"]["listPatGrantRepositories"], allowUnmocked).request, + listPatGrantRequestRepositories: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-token-requests/{pat_request_id}/repositories", "get">(baseUrl, endpoints["orgs"]["listPatGrantRequestRepositories"], allowUnmocked).request, + listPatGrantRequests: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-token-requests", "get">(baseUrl, endpoints["orgs"]["listPatGrantRequests"], allowUnmocked).request, + listPatGrants: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-tokens", "get">(baseUrl, endpoints["orgs"]["listPatGrants"], allowUnmocked).request, listPendingInvitations: new MoctokitRequestMocker<"/orgs/{org}/invitations", "get">(baseUrl, endpoints["orgs"]["listPendingInvitations"], allowUnmocked).request, listPublicMembers: @@ -916,6 +978,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/public_members/{username}", "delete">(baseUrl, endpoints["orgs"]["removePublicMembershipForAuthenticatedUser"], allowUnmocked).request, removeSecurityManagerTeam: new MoctokitRequestMocker<"/orgs/{org}/security-managers/teams/{team_slug}", "delete">(baseUrl, endpoints["orgs"]["removeSecurityManagerTeam"], allowUnmocked).request, + reviewPatGrantRequest: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-token-requests/{pat_request_id}", "post">(baseUrl, endpoints["orgs"]["reviewPatGrantRequest"], allowUnmocked).request, + reviewPatGrantRequestsInBulk: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-token-requests", "post">(baseUrl, endpoints["orgs"]["reviewPatGrantRequestsInBulk"], allowUnmocked).request, setMembershipForUser: new MoctokitRequestMocker<"/orgs/{org}/memberships/{username}", "put">(baseUrl, endpoints["orgs"]["setMembershipForUser"], allowUnmocked).request, setPublicMembershipForAuthenticatedUser: @@ -924,10 +990,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/blocks/{username}", "delete">(baseUrl, endpoints["orgs"]["unblockUser"], allowUnmocked).request, update: new MoctokitRequestMocker<"/orgs/{org}", "patch">(baseUrl, endpoints["orgs"]["update"], allowUnmocked).request, - updateCustomRole: - new MoctokitRequestMocker<"/orgs/{org}/custom_roles/{role_id}", "patch">(baseUrl, endpoints["orgs"]["updateCustomRole"], allowUnmocked).request, updateMembershipForAuthenticatedUser: new MoctokitRequestMocker<"/user/memberships/orgs/{org}", "patch">(baseUrl, endpoints["orgs"]["updateMembershipForAuthenticatedUser"], allowUnmocked).request, + updatePatAccess: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-tokens/{pat_id}", "post">(baseUrl, endpoints["orgs"]["updatePatAccess"], allowUnmocked).request, + updatePatAccesses: + new MoctokitRequestMocker<"/organizations/{org}/personal-access-tokens", "post">(baseUrl, endpoints["orgs"]["updatePatAccesses"], allowUnmocked).request, updateWebhook: new MoctokitRequestMocker<"/orgs/{org}/hooks/{hook_id}", "patch">(baseUrl, endpoints["orgs"]["updateWebhook"], allowUnmocked).request, updateWebhookConfigForOrg: @@ -968,6 +1036,12 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/orgs/{org}/packages/{package_type}/{package_name}/versions/{package_version_id}", "get">(baseUrl, endpoints["packages"]["getPackageVersionForOrganization"], allowUnmocked).request, getPackageVersionForUser: new MoctokitRequestMocker<"/users/{username}/packages/{package_type}/{package_name}/versions/{package_version_id}", "get">(baseUrl, endpoints["packages"]["getPackageVersionForUser"], allowUnmocked).request, + listDockerMigrationConflictingPackagesForAuthenticatedUser: + new MoctokitRequestMocker<"/user/docker/conflicts", "get">(baseUrl, endpoints["packages"]["listDockerMigrationConflictingPackagesForAuthenticatedUser"], allowUnmocked).request, + listDockerMigrationConflictingPackagesForOrganization: + new MoctokitRequestMocker<"/orgs/{org}/docker/conflicts", "get">(baseUrl, endpoints["packages"]["listDockerMigrationConflictingPackagesForOrganization"], allowUnmocked).request, + listDockerMigrationConflictingPackagesForUser: + new MoctokitRequestMocker<"/users/{username}/docker/conflicts", "get">(baseUrl, endpoints["packages"]["listDockerMigrationConflictingPackagesForUser"], allowUnmocked).request, listPackagesForAuthenticatedUser: new MoctokitRequestMocker<"/user/packages", "get">(baseUrl, endpoints["packages"]["listPackagesForAuthenticatedUser"], allowUnmocked).request, listPackagesForOrganization: @@ -1178,6 +1252,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/deployments", "post">(baseUrl, endpoints["repos"]["createDeployment"], allowUnmocked).request, createDeploymentBranchPolicy: new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment-branch-policies", "post">(baseUrl, endpoints["repos"]["createDeploymentBranchPolicy"], allowUnmocked).request, + createDeploymentProtectionRule: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", "post">(baseUrl, endpoints["repos"]["createDeploymentProtectionRule"], allowUnmocked).request, createDeploymentStatus: new MoctokitRequestMocker<"/repos/{owner}/{repo}/deployments/{deployment_id}/statuses", "post">(baseUrl, endpoints["repos"]["createDeploymentStatus"], allowUnmocked).request, createDispatchEvent: @@ -1192,12 +1268,16 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}", "put">(baseUrl, endpoints["repos"]["createOrUpdateEnvironment"], allowUnmocked).request, createOrUpdateFileContents: new MoctokitRequestMocker<"/repos/{owner}/{repo}/contents/{path}", "put">(baseUrl, endpoints["repos"]["createOrUpdateFileContents"], allowUnmocked).request, + createOrgRuleset: + new MoctokitRequestMocker<"/orgs/{org}/rulesets", "post">(baseUrl, endpoints["repos"]["createOrgRuleset"], allowUnmocked).request, createPagesDeployment: new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages/deployment", "post">(baseUrl, endpoints["repos"]["createPagesDeployment"], allowUnmocked).request, createPagesSite: new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages", "post">(baseUrl, endpoints["repos"]["createPagesSite"], allowUnmocked).request, createRelease: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases", "post">(baseUrl, endpoints["repos"]["createRelease"], allowUnmocked).request, + createRepoRuleset: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rulesets", "post">(baseUrl, endpoints["repos"]["createRepoRuleset"], allowUnmocked).request, createTagProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/tags/protection", "post">(baseUrl, endpoints["repos"]["createTagProtection"], allowUnmocked).request, createUsingTemplate: @@ -1234,6 +1314,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/contents/{path}", "delete">(baseUrl, endpoints["repos"]["deleteFile"], allowUnmocked).request, deleteInvitation: new MoctokitRequestMocker<"/repos/{owner}/{repo}/invitations/{invitation_id}", "delete">(baseUrl, endpoints["repos"]["deleteInvitation"], allowUnmocked).request, + deleteOrgRuleset: + new MoctokitRequestMocker<"/orgs/{org}/rulesets/{ruleset_id}", "delete">(baseUrl, endpoints["repos"]["deleteOrgRuleset"], allowUnmocked).request, deletePagesSite: new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages", "delete">(baseUrl, endpoints["repos"]["deletePagesSite"], allowUnmocked).request, deletePullRequestReviewProtection: @@ -1242,12 +1324,16 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/{release_id}", "delete">(baseUrl, endpoints["repos"]["deleteRelease"], allowUnmocked).request, deleteReleaseAsset: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/assets/{asset_id}", "delete">(baseUrl, endpoints["repos"]["deleteReleaseAsset"], allowUnmocked).request, + deleteRepoRuleset: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rulesets/{ruleset_id}", "delete">(baseUrl, endpoints["repos"]["deleteRepoRuleset"], allowUnmocked).request, deleteTagProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/tags/protection/{tag_protection_id}", "delete">(baseUrl, endpoints["repos"]["deleteTagProtection"], allowUnmocked).request, deleteWebhook: new MoctokitRequestMocker<"/repos/{owner}/{repo}/hooks/{hook_id}", "delete">(baseUrl, endpoints["repos"]["deleteWebhook"], allowUnmocked).request, disableAutomatedSecurityFixes: new MoctokitRequestMocker<"/repos/{owner}/{repo}/automated-security-fixes", "delete">(baseUrl, endpoints["repos"]["disableAutomatedSecurityFixes"], allowUnmocked).request, + disableDeploymentProtectionRule: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "delete">(baseUrl, endpoints["repos"]["disableDeploymentProtectionRule"], allowUnmocked).request, disableLfsForRepo: new MoctokitRequestMocker<"/repos/{owner}/{repo}/lfs", "delete">(baseUrl, endpoints["repos"]["disableLfsForRepo"], allowUnmocked).request, disableVulnerabilityAlerts: @@ -1271,6 +1357,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection/restrictions", "get">(baseUrl, endpoints["repos"]["getAccessRestrictions"], allowUnmocked).request, getAdminBranchProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection/enforce_admins", "get">(baseUrl, endpoints["repos"]["getAdminBranchProtection"], allowUnmocked).request, + getAllDeploymentProtectionRules: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules", "get">(baseUrl, endpoints["repos"]["getAllDeploymentProtectionRules"], allowUnmocked).request, getAllEnvironments: new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments", "get">(baseUrl, endpoints["repos"]["getAllEnvironments"], allowUnmocked).request, getAllStatusCheckContexts: @@ -1285,6 +1373,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}", "get">(baseUrl, endpoints["repos"]["getBranch"], allowUnmocked).request, getBranchProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection", "get">(baseUrl, endpoints["repos"]["getBranchProtection"], allowUnmocked).request, + getBranchRules: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rules/branches/{branch}", "get">(baseUrl, endpoints["repos"]["getBranchRules"], allowUnmocked).request, getClones: new MoctokitRequestMocker<"/repos/{owner}/{repo}/traffic/clones", "get">(baseUrl, endpoints["repos"]["getClones"], allowUnmocked).request, getCodeFrequencyStats: @@ -1307,6 +1397,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/contents/{path}", "get">(baseUrl, endpoints["repos"]["getContent"], allowUnmocked).request, getContributorsStats: new MoctokitRequestMocker<"/repos/{owner}/{repo}/stats/contributors", "get">(baseUrl, endpoints["repos"]["getContributorsStats"], allowUnmocked).request, + getCustomDeploymentProtectionRule: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/{protection_rule_id}", "get">(baseUrl, endpoints["repos"]["getCustomDeploymentProtectionRule"], allowUnmocked).request, getDeployKey: new MoctokitRequestMocker<"/repos/{owner}/{repo}/keys/{key_id}", "get">(baseUrl, endpoints["repos"]["getDeployKey"], allowUnmocked).request, getDeployment: @@ -1321,6 +1413,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages/builds/latest", "get">(baseUrl, endpoints["repos"]["getLatestPagesBuild"], allowUnmocked).request, getLatestRelease: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/latest", "get">(baseUrl, endpoints["repos"]["getLatestRelease"], allowUnmocked).request, + getOrgRuleset: + new MoctokitRequestMocker<"/orgs/{org}/rulesets/{ruleset_id}", "get">(baseUrl, endpoints["repos"]["getOrgRuleset"], allowUnmocked).request, + getOrgRulesets: + new MoctokitRequestMocker<"/orgs/{org}/rulesets", "get">(baseUrl, endpoints["repos"]["getOrgRulesets"], allowUnmocked).request, getPages: new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages", "get">(baseUrl, endpoints["repos"]["getPages"], allowUnmocked).request, getPagesBuild: @@ -1343,6 +1439,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/assets/{asset_id}", "get">(baseUrl, endpoints["repos"]["getReleaseAsset"], allowUnmocked).request, getReleaseByTag: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/tags/{tag}", "get">(baseUrl, endpoints["repos"]["getReleaseByTag"], allowUnmocked).request, + getRepoRuleset: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rulesets/{ruleset_id}", "get">(baseUrl, endpoints["repos"]["getRepoRuleset"], allowUnmocked).request, + getRepoRulesets: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rulesets", "get">(baseUrl, endpoints["repos"]["getRepoRulesets"], allowUnmocked).request, getStatusChecksProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", "get">(baseUrl, endpoints["repos"]["getStatusChecksProtection"], allowUnmocked).request, getTeamsWithAccessToProtectedBranch: @@ -1379,6 +1479,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/commits", "get">(baseUrl, endpoints["repos"]["listCommits"], allowUnmocked).request, listContributors: new MoctokitRequestMocker<"/repos/{owner}/{repo}/contributors", "get">(baseUrl, endpoints["repos"]["listContributors"], allowUnmocked).request, + listCustomDeploymentRuleIntegrations: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/environments/{environment_name}/deployment_protection_rules/apps", "get">(baseUrl, endpoints["repos"]["listCustomDeploymentRuleIntegrations"], allowUnmocked).request, listDeployKeys: new MoctokitRequestMocker<"/repos/{owner}/{repo}/keys", "get">(baseUrl, endpoints["repos"]["listDeployKeys"], allowUnmocked).request, listDeploymentBranchPolicies: @@ -1473,12 +1575,16 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/repos/{owner}/{repo}/pages", "put">(baseUrl, endpoints["repos"]["updateInformationAboutPagesSite"], allowUnmocked).request, updateInvitation: new MoctokitRequestMocker<"/repos/{owner}/{repo}/invitations/{invitation_id}", "patch">(baseUrl, endpoints["repos"]["updateInvitation"], allowUnmocked).request, + updateOrgRuleset: + new MoctokitRequestMocker<"/orgs/{org}/rulesets/{ruleset_id}", "put">(baseUrl, endpoints["repos"]["updateOrgRuleset"], allowUnmocked).request, updatePullRequestReviewProtection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection/required_pull_request_reviews", "patch">(baseUrl, endpoints["repos"]["updatePullRequestReviewProtection"], allowUnmocked).request, updateRelease: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/{release_id}", "patch">(baseUrl, endpoints["repos"]["updateRelease"], allowUnmocked).request, updateReleaseAsset: new MoctokitRequestMocker<"/repos/{owner}/{repo}/releases/assets/{asset_id}", "patch">(baseUrl, endpoints["repos"]["updateReleaseAsset"], allowUnmocked).request, + updateRepoRuleset: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/rulesets/{ruleset_id}", "put">(baseUrl, endpoints["repos"]["updateRepoRuleset"], allowUnmocked).request, updateStatusCheckPotection: new MoctokitRequestMocker<"/repos/{owner}/{repo}/branches/{branch}/protection/required_status_checks", "patch">(baseUrl, endpoints["repos"]["updateStatusCheckPotection"], allowUnmocked).request, updateStatusCheckProtection: @@ -1519,6 +1625,18 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ updateAlert: new MoctokitRequestMocker<"/repos/{owner}/{repo}/secret-scanning/alerts/{alert_number}", "patch">(baseUrl, endpoints["secretScanning"]["updateAlert"], allowUnmocked).request, }, + securityAdvisories: { + createPrivateVulnerabilityReport: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/security-advisories/reports", "post">(baseUrl, endpoints["securityAdvisories"]["createPrivateVulnerabilityReport"], allowUnmocked).request, + createRepositoryAdvisory: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/security-advisories", "post">(baseUrl, endpoints["securityAdvisories"]["createRepositoryAdvisory"], allowUnmocked).request, + getRepositoryAdvisory: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/security-advisories/{ghsa_id}", "get">(baseUrl, endpoints["securityAdvisories"]["getRepositoryAdvisory"], allowUnmocked).request, + listRepositoryAdvisories: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/security-advisories", "get">(baseUrl, endpoints["securityAdvisories"]["listRepositoryAdvisories"], allowUnmocked).request, + updateRepositoryAdvisory: + new MoctokitRequestMocker<"/repos/{owner}/{repo}/security-advisories/{ghsa_id}", "patch">(baseUrl, endpoints["securityAdvisories"]["updateRepositoryAdvisory"], allowUnmocked).request, + }, teams: { addOrUpdateMembershipForUserInOrg: new MoctokitRequestMocker<"/orgs/{org}/teams/{team_slug}/memberships/{username}", "put">(baseUrl, endpoints["teams"]["addOrUpdateMembershipForUserInOrg"], allowUnmocked).request, @@ -1585,6 +1703,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/user/emails", "post">(baseUrl, endpoints["users"]["addEmailForAuthenticated"], allowUnmocked).request, addEmailForAuthenticatedUser: new MoctokitRequestMocker<"/user/emails", "post">(baseUrl, endpoints["users"]["addEmailForAuthenticatedUser"], allowUnmocked).request, + addSocialAccountForAuthenticatedUser: + new MoctokitRequestMocker<"/user/social_accounts", "post">(baseUrl, endpoints["users"]["addSocialAccountForAuthenticatedUser"], allowUnmocked).request, block: new MoctokitRequestMocker<"/user/blocks/{username}", "put">(baseUrl, endpoints["users"]["block"], allowUnmocked).request, checkBlocked: @@ -1615,6 +1735,8 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/user/keys/{key_id}", "delete">(baseUrl, endpoints["users"]["deletePublicSshKeyForAuthenticated"], allowUnmocked).request, deletePublicSshKeyForAuthenticatedUser: new MoctokitRequestMocker<"/user/keys/{key_id}", "delete">(baseUrl, endpoints["users"]["deletePublicSshKeyForAuthenticatedUser"], allowUnmocked).request, + deleteSocialAccountForAuthenticatedUser: + new MoctokitRequestMocker<"/user/social_accounts", "delete">(baseUrl, endpoints["users"]["deleteSocialAccountForAuthenticatedUser"], allowUnmocked).request, deleteSshSigningKeyForAuthenticatedUser: new MoctokitRequestMocker<"/user/ssh_signing_keys/{ssh_signing_key_id}", "delete">(baseUrl, endpoints["users"]["deleteSshSigningKeyForAuthenticatedUser"], allowUnmocked).request, follow: @@ -1670,6 +1792,10 @@ const endpointToMethod = (baseUrl: string, allowUnmocked = false) => ({ new MoctokitRequestMocker<"/user/keys", "get">(baseUrl, endpoints["users"]["listPublicSshKeysForAuthenticated"], allowUnmocked).request, listPublicSshKeysForAuthenticatedUser: new MoctokitRequestMocker<"/user/keys", "get">(baseUrl, endpoints["users"]["listPublicSshKeysForAuthenticatedUser"], allowUnmocked).request, + listSocialAccountsForAuthenticatedUser: + new MoctokitRequestMocker<"/user/social_accounts", "get">(baseUrl, endpoints["users"]["listSocialAccountsForAuthenticatedUser"], allowUnmocked).request, + listSocialAccountsForUser: + new MoctokitRequestMocker<"/users/{username}/social_accounts", "get">(baseUrl, endpoints["users"]["listSocialAccountsForUser"], allowUnmocked).request, listSshSigningKeysForAuthenticatedUser: new MoctokitRequestMocker<"/user/ssh_signing_keys", "get">(baseUrl, endpoints["users"]["listSshSigningKeysForAuthenticatedUser"], allowUnmocked).request, listSshSigningKeysForUser: