Skip to content

Commit

Permalink
Merge pull request #35398 from github/repo-sync
Browse files Browse the repository at this point in the history
Repo sync
  • Loading branch information
docs-bot authored Nov 23, 2024
2 parents a886624 + 7ab9c95 commit f0d52e0
Show file tree
Hide file tree
Showing 21 changed files with 514 additions and 34 deletions.
13 changes: 13 additions & 0 deletions content/rest/billing/enhanced-billing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
title: Enhanced billing platform
intro: Use the REST API to get billing usage information from the enhanced billing platform.
versions: # DO NOT MANUALLY EDIT. CHANGES WILL BE OVERWRITTEN BY A 🤖
fpt: '*'
ghec: '*'
topics:
- API
autogenerated: rest
allowTitleToDifferFromFilename: true
---

<!-- Content after this section is automatically generated -->
1 change: 1 addition & 0 deletions content/rest/billing/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ versions:
ghes: '*'
children:
- /billing
- /enhanced-billing
autogenerated: rest
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,15 @@
"title": "Administration",
"displayTitle": "Organization permissions for \"Administration\"",
"permissions": [
{
"category": "billing",
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage",
"additional-permissions": false,
"access": "read"
},
{
"category": "orgs",
"slug": "update-an-organization",
Expand Down
6 changes: 6 additions & 0 deletions src/github-apps/data/fpt-2022-11-28/fine-grained-pat.json
Original file line number Diff line number Diff line change
Expand Up @@ -984,6 +984,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,17 @@
"title": "Administration",
"displayTitle": "Organization permissions for \"Administration\"",
"permissions": [
{
"category": "billing",
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage",
"access": "read",
"user-to-server": true,
"server-to-server": true,
"additional-permissions": false
},
{
"category": "orgs",
"slug": "update-an-organization",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -936,6 +936,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
6 changes: 6 additions & 0 deletions src/github-apps/data/fpt-2022-11-28/user-to-server-rest.json
Original file line number Diff line number Diff line change
Expand Up @@ -984,6 +984,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,15 @@
"additional-permissions": true,
"access": "read"
},
{
"category": "billing",
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage",
"additional-permissions": false,
"access": "read"
},
{
"category": "orgs",
"slug": "update-an-organization",
Expand Down
6 changes: 6 additions & 0 deletions src/github-apps/data/ghec-2022-11-28/fine-grained-pat.json
Original file line number Diff line number Diff line change
Expand Up @@ -1016,6 +1016,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,17 @@
"server-to-server": true,
"additional-permissions": true
},
{
"category": "billing",
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage",
"access": "read",
"user-to-server": true,
"server-to-server": true,
"additional-permissions": false
},
{
"category": "orgs",
"slug": "update-an-organization",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -968,6 +968,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
6 changes: 6 additions & 0 deletions src/github-apps/data/ghec-2022-11-28/user-to-server-rest.json
Original file line number Diff line number Diff line change
Expand Up @@ -1016,6 +1016,12 @@
}
],
"billing": [
{
"slug": "get-billing-usage-report-for-an-organization",
"subcategory": "enhanced-billing",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage"
},
{
"slug": "get-github-actions-billing-for-an-organization",
"subcategory": "billing",
Expand Down
2 changes: 1 addition & 1 deletion src/github-apps/lib/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,5 @@
"2022-11-28"
]
},
"sha": "d97436bb3672e8d985262803de6ab7cafe1c7ff3"
"sha": "b2ff88e4eaa64e465b9b210369bfd701e48edd9a"
}
195 changes: 195 additions & 0 deletions src/rest/data/fpt-2022-11-28/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -103833,6 +103833,201 @@
}
]
}
],
"enhanced-billing": [
{
"serverUrl": "https://api.github.com",
"verb": "get",
"requestPath": "/organizations/{org}/settings/billing/usage",
"title": "Get billing usage report for an organization",
"category": "billing",
"subcategory": "enhanced-billing",
"parameters": [
{
"name": "org",
"description": "<p>The organization name. The name is not case sensitive.</p>",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "year",
"description": "<p>If specified, only return results for a single year. The value of <code>year</code> is an integer with four digits representing a year. For example, <code>2024</code>. Default value is the current year.</p>",
"in": "query",
"required": false,
"schema": {
"type": "integer"
}
},
{
"name": "month",
"description": "<p>If specified, only return results for a single month. The value of <code>month</code> is an integer between <code>1</code> and <code>12</code>.</p>",
"in": "query",
"required": false,
"schema": {
"type": "integer"
}
},
{
"name": "day",
"description": "<p>If specified, only return results for a single day. The value of <code>day</code> is an integer between <code>1</code> and <code>31</code>.</p>",
"in": "query",
"required": false,
"schema": {
"type": "integer"
}
},
{
"name": "hour",
"description": "<p>If specified, only return results for a single hour. The value of <code>hour</code> is an integer between <code>0</code> and <code>23</code>.</p>",
"in": "query",
"required": false,
"schema": {
"type": "integer"
}
}
],
"bodyParameters": [],
"progAccess": {
"userToServerRest": true,
"serverToServer": true,
"fineGrainedPat": true,
"permissions": [
{
"\"Administration\" organization permissions": "read"
}
]
},
"codeExamples": [
{
"key": "default",
"request": {
"description": "Example",
"acceptHeader": "application/vnd.github.v3+json",
"parameters": {
"org": "ORG"
}
},
"response": {
"statusCode": "200",
"contentType": "application/json",
"description": "<p>Billing usage report response for an organization</p>",
"example": {
"usageItems": [
{
"date": "2023-08-01",
"product": "Actions",
"sku": "Actions Linux",
"quantity": 100,
"unitType": "minutes",
"pricePerUnit": 0.008,
"grossAmount": 0.8,
"discountAmount": 0,
"netAmount": 0.8,
"organizationName": "GitHub",
"repositoryName": "github/example"
}
]
},
"schema": {
"type": "object",
"properties": {
"usageItems": {
"type": "array",
"items": {
"type": "object",
"properties": {
"date": {
"type": "string",
"description": "Date of the usage line item."
},
"product": {
"type": "string",
"description": "Product name."
},
"sku": {
"type": "string",
"description": "SKU name."
},
"quantity": {
"type": "integer",
"description": "Quantity of the usage line item."
},
"unitType": {
"type": "string",
"description": "Unit type of the usage line item."
},
"pricePerUnit": {
"type": "number",
"description": "Price per unit of the usage line item."
},
"grossAmount": {
"type": "number",
"description": "Gross amount of the usage line item."
},
"discountAmount": {
"type": "number",
"description": "Discount amount of the usage line item."
},
"netAmount": {
"type": "number",
"description": "Net amount of the usage line item."
},
"organizationName": {
"type": "string",
"description": "Name of the organization."
},
"repositoryName": {
"type": "string",
"description": "Name of the repository."
}
},
"required": [
"date",
"product",
"sku",
"quantity",
"unitType",
"pricePerUnit",
"grossAmount",
"discountAmount",
"netAmount",
"organizationName"
]
}
}
}
}
}
}
],
"previews": [],
"descriptionHTML": "<p>Gets a report of the total usage for an organization. To use this endpoint, you must be an administrator of an organization within an enterprise or an organization account.</p>\n<p><strong>Note:</strong> This endpoint is only available to organizations with access to the enhanced billing platform. For more information, see \"<a href=\"https://docs.github.com/billing/using-the-new-billing-platform\">About the enhanced billing platform</a>.\"</p>",
"statusCodes": [
{
"httpStatusCode": "200",
"description": "<p>Billing usage report response for an organization</p>"
},
{
"httpStatusCode": "400",
"description": "<p>Bad Request</p>"
},
{
"httpStatusCode": "403",
"description": "<p>Forbidden</p>"
},
{
"httpStatusCode": "500",
"description": "<p>Internal Error</p>"
},
{
"httpStatusCode": "503",
"description": "<p>Service unavailable</p>"
}
]
}
]
},
"branches": {
Expand Down
Loading

0 comments on commit f0d52e0

Please sign in to comment.