diff --git a/examples/digital-ocean-api.ts b/examples/digital-ocean-api.ts index 0d42603de..026cca814 100644 --- a/examples/digital-ocean-api.ts +++ b/examples/digital-ocean-api.ts @@ -5293,15 +5293,20 @@ export interface external { name: string; /** * @description A slug representing the database engine used for the cluster. The possible values are: "pg" for PostgreSQL, "mysql" for MySQL, "redis" for Redis, and "mongodb" for MongoDB. - * @example pg + * @example mysql * @enum {string} */ engine: "pg" | "mysql" | "redis" | "mongodb"; /** * @description A string representing the version of the database engine in use for the cluster. - * @example 10 + * @example 8 */ version?: string; + /** + * @description A string representing the semantic version of the database engine in use for the cluster. + * @example 8.0.28 + */ + semantic_version?: string; /** * @description The number of nodes in the database cluster. * @example 2 @@ -8062,7 +8067,7 @@ export interface external { * ] * } */ - "application/json": external["resources/firewalls/models/firewall_rule.yml"]["firewall_rules"] & (unknown | unknown); + "application/json": external["resources/firewalls/models/firewall_rule.yml"]["firewall_rules"]; }; }; responses: { @@ -8212,7 +8217,7 @@ export interface external { * ] * } */ - "application/json": external["resources/firewalls/models/firewall.yml"] & (unknown | unknown); + "application/json": external["resources/firewalls/models/firewall.yml"]; }; }; responses: { @@ -8315,7 +8320,7 @@ export interface external { * ] * } */ - "application/json": external["resources/firewalls/models/firewall_rule.yml"]["firewall_rules"] & (unknown | unknown); + "application/json": external["resources/firewalls/models/firewall_rule.yml"]["firewall_rules"]; }; }; responses: { @@ -8490,7 +8495,7 @@ export interface external { * ] * } */ - "application/json": WithRequired; + "application/json": WithRequired; }; }; responses: { diff --git a/examples/digital-ocean-api/resources/databases/models/database_cluster.yml b/examples/digital-ocean-api/resources/databases/models/database_cluster.yml index 0ff17be49..573e055da 100644 --- a/examples/digital-ocean-api/resources/databases/models/database_cluster.yml +++ b/examples/digital-ocean-api/resources/databases/models/database_cluster.yml @@ -13,7 +13,7 @@ properties: description: A unique, human-readable name referring to a database cluster. engine: type: string - example: pg + example: mysql enum: - pg - mysql @@ -24,8 +24,13 @@ properties: are: "pg" for PostgreSQL, "mysql" for MySQL, "redis" for Redis, and "mongodb" for MongoDB. version: type: string - example: '10' + example: '8' description: A string representing the version of the database engine in use for the cluster. + semantic_version: + type: string + example: '8.0.28' + description: A string representing the semantic version of the database engine in use for the cluster. + readOnly: true num_nodes: type: integer example: 2 diff --git a/examples/digital-ocean-api/resources/databases/responses/database_cluster.yml b/examples/digital-ocean-api/resources/databases/responses/database_cluster.yml index 53d286deb..23ca68158 100644 --- a/examples/digital-ocean-api/resources/databases/responses/database_cluster.yml +++ b/examples/digital-ocean-api/resources/databases/responses/database_cluster.yml @@ -23,6 +23,7 @@ content: name: backend engine: pg version: '14' + semantic_version: '14.5' connection: uri: postgres://doadmin:wv78n3zpz42xezdk@backend-do-user-19081923-0.db.ondigitalocean.com:25060/defaultdb?sslmode=require database: '' diff --git a/examples/github-api-next.ts b/examples/github-api-next.ts index 6fbf22616..ccab8e9e6 100644 --- a/examples/github-api-next.ts +++ b/examples/github-api-next.ts @@ -439,9 +439,9 @@ export interface paths { * Get GitHub meta information * @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/)." * - * **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. + * The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. * - * **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. + * **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. */ get: operations["meta/get"]; }; @@ -4464,6 +4464,13 @@ export interface paths { */ get: operations["dependency-graph/diff-range"]; }; + "/repos/{owner}/{repo}/dependency-graph/sbom": { + /** + * Export a software bill of materials (SBOM) for a repository. + * @description Exports the software bill of materials (SBOM) for a repository in SPDX JSON format. + */ + get: operations["dependency-graph/export-sbom"]; + }; "/repos/{owner}/{repo}/dependency-graph/snapshots": { /** * Create a snapshot of dependencies for a repository @@ -4667,6 +4674,8 @@ export interface paths { * @description Create a fork for the authenticated user. * * **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + * + * **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. */ post: operations["repos/create-fork"]; }; @@ -5872,6 +5881,47 @@ export interface paths { */ get: operations["secret-scanning/list-locations-for-alert"]; }; + "/repos/{owner}/{repo}/security-advisories": { + /** + * List repository security advisories + * @description Lists security advisories in a repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + * + * You 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. + */ + get: operations["security-advisories/list-repository-advisories"]; + /** + * Create a repository security advisory + * @description Creates a new repository security advisory. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + */ + post: operations["security-advisories/create-repository-advisory"]; + }; + "/repos/{owner}/{repo}/security-advisories/{ghsa_id}": { + /** + * Get a repository security advisory + * @description Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You can access any published security advisory on a public repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + * + * You 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 + * collaborator on the security advisory. + */ + get: operations["security-advisories/get-repository-advisory"]; + /** + * Update a repository security advisory + * @description Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to update any security advisory, you must be a security manager or administrator of that repository, + * or a collaborator on the repository security advisory. + */ + patch: operations["security-advisories/update-repository-advisory"]; + }; "/repos/{owner}/{repo}/stargazers": { /** * List stargazers @@ -9751,6 +9801,24 @@ export interface webhooks { */ post: operations["release/unpublished"]; }; + "repository-advisory-published": { + /** + * This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + * + * To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + * @description A repository security advisory was published. + */ + post: operations["repository-advisory/published"]; + }; + "repository-advisory-reported": { + /** + * This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + * + * To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + * @description A private vulnerability report was submitted. + */ + post: operations["repository-advisory/reported"]; + }; "repository-archived": { /** * This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. @@ -10502,17 +10570,17 @@ export interface components { request: { /** @description The request headers sent with the webhook delivery. */ headers: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, null]>; /** @description The webhook payload. */ payload: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, null]>; }; response: { /** @description The response headers received when the delivery was made. */ headers: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, null]>; /** @description The response payload received. */ payload: OneOf<[string, null]>; @@ -10625,11 +10693,6 @@ export interface components { * @enum {string} */ pull_requests?: "read" | "write"; - /** - * @description The level of permission to grant the access token to view and manage announcement banners for a repository. - * @enum {string} - */ - repository_announcement_banners?: "read" | "write"; /** * @description The level of permission to grant the access token to manage the post-receive hooks for a repository. * @enum {string} @@ -13265,6 +13328,8 @@ export interface components { permission: string; /** @description The level of privacy this team should have */ privacy?: string; + /** @description The notification setting the team has set */ + notification_setting?: string; /** Format: uri */ html_url: string; /** Format: uri */ @@ -13284,6 +13349,7 @@ export interface components { slug: string; description: OneOf<[string, null]>; privacy?: string; + notification_setting?: string; permission: string; permissions?: { pull: boolean; @@ -13574,6 +13640,11 @@ export interface components { * @enum {string} */ privacy?: "closed" | "secret"; + /** + * @description The notification setting the team has set + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** @description Permission that the team will have for its repositories */ permission: string; members_url: string; @@ -14598,7 +14669,7 @@ export interface components { /** @description Parameter to specify a task to execute */ task: string; payload: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, string]>; original_environment?: string; /** @description Name for the target deployment environment. */ @@ -14788,6 +14859,7 @@ export interface components { slug?: string; description?: OneOf<[string, null]>; privacy?: string; + notification_setting?: string; permission?: string; members_url?: string; repositories_url?: string; @@ -16114,6 +16186,70 @@ export interface components { */ scope: "unknown" | "runtime" | "development"; })[]; + /** + * Dependency Graph SPDX SBOM + * @description A schema for the SPDX JSON format returned by the Dependency Graph. + */ + "dependency-graph-spdx-sbom": { + sbom: { + /** @description The SPDX identifier for the SPDX document. */ + SPDXID: string; + /** @description The version of the SPDX specification that this document conforms to. */ + spdxVersion: string; + creationInfo: { + /** @description The date and time the SPDX document was created. */ + created: string; + /** @description The tools that were used to generate the SPDX document. */ + creators: (string)[]; + }; + /** @description The name of the SPDX document. */ + name: string; + /** @description The license under which the SPDX document is licensed. */ + dataLicense: string; + /** @description The name of the repository that the SPDX document describes. */ + documentDescribes: (string)[]; + /** @description The namespace for the SPDX document. */ + documentNamespace: string; + packages: ({ + /** @description A unique SPDX identifier for the package. */ + SPDXID?: string; + /** @description The name of the package. */ + name?: string; + /** + * @description The version of the package. If the package does not have an exact version specified, + * a version range is given. + */ + versionInfo?: string; + /** + * @description The location where the package can be downloaded, + * or NOASSERTION if this has not been determined. + */ + downloadLocation?: string; + /** + * @description Whether the package's file content has been subjected to + * analysis during the creation of the SPDX document. + */ + filesAnalyzed?: boolean; + /** @description The license of the package as determined while creating the SPDX document. */ + licenseConcluded?: string; + /** + * @description The license of the package as declared by its author, or NOASSERTION if this information + * was not available when the SPDX document was created. + */ + licenseDeclared?: string; + /** @description The distribution source of this package, or NOASSERTION if this was not determined. */ + supplier?: string; + externalRefs?: ({ + /** @description The category of reference to an external resource this reference refers to. */ + referenceCategory: string; + /** @description A locator for the particular external resource this reference refers to. */ + referenceLocator: string; + /** @description The category of reference to an external resource this reference refers to. */ + referenceType: string; + })[]; + })[]; + }; + }; /** * metadata * @description User-defined metadata to store domain-specific information limited to 8 keys with scalar values. @@ -17132,9 +17268,9 @@ export interface components { /** @description The relative path of the file to which the comment applies. */ path: string; /** @description The line index in the diff to which the comment applies. This field is deprecated; use `line` instead. */ - position: number; + position?: number; /** @description The index of the original line in the diff to which the comment applies. This field is deprecated; use `original_line` instead. */ - original_position: number; + original_position?: number; /** @description The SHA of the commit to which the comment applies. */ commit_id: string; /** @description The SHA of the original commit to which the comment applies. */ @@ -18245,6 +18381,213 @@ export interface components { type: "commit" | "issue_title" | "issue_body" | "issue_comment"; details: components["schemas"]["secret-scanning-location-commit"] | components["schemas"]["secret-scanning-location-issue-title"] | components["schemas"]["secret-scanning-location-issue-body"] | components["schemas"]["secret-scanning-location-issue-comment"]; }; + /** + * @description The package's language or package management ecosystem. + * @enum {string} + */ + "repository-advisory-ecosystems": "rubygems" | "npm" | "pip" | "maven" | "nuget" | "composer" | "go" | "rust" | "erlang" | "actions" | "pub" | "other"; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + "repository-advisory-vulnerability": { + /** @description The name of the package affected by the vulnerability. */ + package: OneOf<[{ + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name: OneOf<[string, null]>; + }, null]>; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range: OneOf<[string, null]>; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions: OneOf<[string, null]>; + /** @description The functions in the package that are affected. */ + vulnerable_functions: OneOf<[(string)[], null]>; + }; + /** + * @description The type of credit the user is receiving. + * @enum {string} + */ + "repository-advisory-credit-types": "analyst" | "finder" | "reporter" | "coordinator" | "remediation_developer" | "remediation_reviewer" | "remediation_verifier" | "tool" | "sponsor" | "other"; + /** @description A credit given to a user for a repository security advisory. */ + "repository-advisory-credit": { + user: components["schemas"]["simple-user"]; + type: components["schemas"]["repository-advisory-credit-types"]; + /** + * @description The state of the user's acceptance of the credit. + * @enum {string} + */ + state: "accepted" | "declined" | "pending"; + }; + /** @description A repository security advisory. */ + "repository-advisory": { + /** @description The GitHub Security Advisory ID. */ + ghsa_id: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id: OneOf<[string, null]>; + /** @description The API URL for the advisory. */ + url: string; + /** + * Format: uri + * @description The URL for the advisory. + */ + html_url: string; + /** @description A short summary of the advisory. */ + summary: string; + /** @description A detailed description of what the advisory entails. */ + description: OneOf<[string, null]>; + /** + * @description The severity of the advisory. + * @enum {string|null} + */ + severity: "critical" | "high" | "medium" | "low" | "" | null; + /** @description The author of the advisory. */ + author: null; + /** @description The publisher of the advisory. */ + publisher: null; + identifiers: readonly ({ + /** + * @description The type of identifier. + * @enum {string} + */ + type: "CVE" | "GHSA"; + /** @description The identifier value. */ + value: string; + })[]; + /** + * @description The state of the advisory. + * @enum {string} + */ + state: "published" | "closed" | "withdrawn" | "draft" | "triage"; + /** + * Format: date-time + * @description The date and time of when the advisory was created, in ISO 8601 format. + */ + created_at: OneOf<[string, null]>; + /** + * Format: date-time + * @description The date and time of when the advisory was last updated, in ISO 8601 format. + */ + updated_at: OneOf<[string, null]>; + /** + * Format: date-time + * @description The date and time of when the advisory was published, in ISO 8601 format. + */ + published_at: OneOf<[string, null]>; + /** + * Format: date-time + * @description The date and time of when the advisory was closed, in ISO 8601 format. + */ + closed_at: OneOf<[string, null]>; + /** + * Format: date-time + * @description The date and time of when the advisory was withdrawn, in ISO 8601 format. + */ + withdrawn_at: OneOf<[string, null]>; + submission: OneOf<[{ + /** @description Whether a private vulnerability report was accepted by the repository's administrators. */ + readonly accepted: boolean; + }, null]>; + vulnerabilities: OneOf<[(components["schemas"]["repository-advisory-vulnerability"])[], null]>; + cvss: OneOf<[{ + /** @description The CVSS vector. */ + vector_string: OneOf<[string, null]>; + /** @description The CVSS score. */ + score: OneOf<[number, null]>; + }, null]>; + cwes: OneOf<[readonly ({ + /** @description The Common Weakness Enumeration (CWE) identifier. */ + cwe_id: string; + /** @description The name of the CWE. */ + name: string; + })[], null]>; + /** @description A list of only the CWE IDs. */ + cwe_ids: OneOf<[(string)[], null]>; + credits: OneOf<[({ + /** @description The username of the user credited. */ + login?: string; + type?: components["schemas"]["repository-advisory-credit-types"]; + })[], null]>; + credits_detailed: OneOf<[readonly (components["schemas"]["repository-advisory-credit"])[], null]>; + }; + "repository-advisory-create": { + /** @description A short summary of the advisory. */ + summary: string; + /** @description A detailed description of what the advisory impacts. */ + description: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id?: OneOf<[string, null]>; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + vulnerabilities: ({ + /** @description The name of the package affected by the vulnerability. */ + package: { + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name?: OneOf<[string, null]>; + }; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range?: OneOf<[string, null]>; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions?: OneOf<[string, null]>; + /** @description The functions in the package that are affected. */ + vulnerable_functions?: OneOf<[(string)[], null]>; + })[]; + /** @description A list of Common Weakness Enumeration (CWE) IDs. */ + cwe_ids?: OneOf<[(string)[], null]>; + /** @description A list of users receiving credit for their participation in the security advisory. */ + credits?: OneOf<[({ + /** @description The username of the user credited. */ + login: string; + type: components["schemas"]["repository-advisory-credit-types"]; + })[], null]>; + /** + * @description The severity of the advisory. You must choose between setting this field or `cvss_vector_string`. + * @enum {string|null} + */ + severity?: "critical" | "high" | "medium" | "low" | "" | null; + /** @description The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`. */ + cvss_vector_string?: OneOf<[string, null]>; + }; + "repository-advisory-update": { + /** @description A short summary of the advisory. */ + summary?: string; + /** @description A detailed description of what the advisory impacts. */ + description?: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id?: OneOf<[string, null]>; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + vulnerabilities?: ({ + /** @description The name of the package affected by the vulnerability. */ + package: { + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name?: OneOf<[string, null]>; + }; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range?: OneOf<[string, null]>; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions?: OneOf<[string, null]>; + /** @description The functions in the package that are affected. */ + vulnerable_functions?: OneOf<[(string)[], null]>; + })[]; + /** @description A list of Common Weakness Enumeration (CWE) IDs. */ + cwe_ids?: OneOf<[(string)[], null]>; + /** @description A list of users receiving credit for their participation in the security advisory. */ + credits?: OneOf<[({ + /** @description The username of the user credited. */ + login: string; + type: components["schemas"]["repository-advisory-credit-types"]; + })[], null]>; + /** + * @description The severity of the advisory. You must choose between setting this field or `cvss_vector_string`. + * @enum {string|null} + */ + severity?: "critical" | "high" | "medium" | "low" | "" | null; + /** @description The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`. */ + cvss_vector_string?: OneOf<[string, null]>; + /** + * @description The state of the advisory. + * @enum {string} + */ + state?: "published" | "closed" | "draft"; + }; /** * Stargazer * @description Stargazer @@ -35552,6 +35895,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -35565,6 +35913,8 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** @enum {string} */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -35695,6 +36045,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -35708,6 +36063,8 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** @enum {string} */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -35719,7 +36076,8 @@ export interface components { }; }; "webhook-merge-group-checks-requested": { - action: string; + /** @enum {string} */ + action: "checks_requested"; installation?: components["schemas"]["simple-installation"]; /** MergeGroup */ merge_group: { @@ -36768,7 +37126,7 @@ export interface components { installation_command: string; manifest?: string; metadata: ({ - [key: string]: unknown | undefined; + [key: string]: unknown; })[]; name: string; npm_metadata?: OneOf<[{ @@ -69365,7 +69723,7 @@ export interface components { installation_command: string; manifest?: string; metadata: ({ - [key: string]: unknown | undefined; + [key: string]: unknown; })[]; name: string; npm_metadata?: OneOf<[{ @@ -70832,6 +71190,28 @@ export interface components { repository: components["schemas"]["repository"]; sender?: components["schemas"]["simple-user"]; }; + /** Repository advisory published event */ + "webhook-repository-advisory-published": { + /** @enum {string} */ + action: "published"; + enterprise?: components["schemas"]["enterprise"]; + installation?: components["schemas"]["simple-installation"]; + organization?: components["schemas"]["organization-simple"]; + repository: components["schemas"]["repository"]; + repository_advisory: components["schemas"]["repository-advisory"]; + sender?: components["schemas"]["simple-user"]; + }; + /** Repository advisory reported event */ + "webhook-repository-advisory-reported": { + /** @enum {string} */ + action: "reported"; + enterprise?: components["schemas"]["enterprise"]; + installation?: components["schemas"]["simple-installation"]; + organization?: components["schemas"]["organization-simple"]; + repository: components["schemas"]["repository"]; + repository_advisory: components["schemas"]["repository-advisory"]; + sender?: components["schemas"]["simple-user"]; + }; /** repository archived event */ "webhook-repository-archived": { /** @enum {string} */ @@ -70867,7 +71247,7 @@ export interface components { action: string; branch: string; client_payload: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, null]>; enterprise?: components["schemas"]["enterprise"]; installation: components["schemas"]["simple-installation"]; @@ -72690,6 +73070,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -72703,6 +73088,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -72989,6 +73379,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -73002,6 +73397,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -73288,6 +73688,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -73301,6 +73706,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -73587,6 +73997,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -73600,6 +74015,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -73628,6 +74048,10 @@ export interface components { /** @description The previous version of the team's privacy if the action was `edited`. */ from: string; }; + notification_setting?: { + /** @description The previous version of the team's notification setting if the action was `edited`. */ + from: string; + }; repository?: { permissions: { from: { @@ -73913,6 +74337,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -73926,6 +74355,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -74212,6 +74646,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -74225,6 +74664,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -74249,7 +74693,7 @@ export interface components { "webhook-workflow-dispatch": { enterprise?: components["schemas"]["enterprise"]; inputs: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, null]>; installation?: components["schemas"]["simple-installation"]; organization?: components["schemas"]["organization-simple"]; @@ -76820,6 +77264,8 @@ export interface components { "asset-id": number; /** @description The unique identifier of the release. */ "release-id": number; + /** @description The GHSA (GitHub Security Advisory) identifier of the advisory. */ + ghsa_id: string; /** @description The unique identifier of the tag protection. */ "tag-protection-id": number; /** @description The time frame to display results for. */ @@ -76913,13 +77359,13 @@ export interface operations { /** @description Response */ 201: { content: { - "application/json": components["schemas"]["integration"] & ({ + "application/json": components["schemas"]["integration"] & { client_id: string; client_secret: string; webhook_secret: OneOf<[string, null]>; pem: string; - [key: string]: unknown | undefined; - }); + [key: string]: unknown; + }; }; }; 404: components["responses"]["not_found"]; @@ -77701,7 +78147,7 @@ export interface operations { }; requestBody: { content: { - "application/json": OneOf<[({ + "application/json": OneOf<[{ /** @description The description of the gist. */ description?: string; /** @@ -77711,14 +78157,14 @@ export interface operations { * To delete a file, set the whole file to null. For example: `hello.py : null`. */ files?: { - [key: string]: (OneOf<[{ + [key: string]: OneOf<[{ /** @description The new content of the file. */ content?: string; /** @description The new filename for the file. */ filename?: OneOf<[string, null]>; - } & (unknown | unknown | Record), null]>) | undefined; + }, null]> | undefined; }; - }) & (unknown | unknown), null]>; + }, null]>; }; }; responses: { @@ -78401,9 +78847,9 @@ export interface operations { * Get GitHub meta information * @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/)." * - * **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. + * The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. * - * **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. + * **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. */ "meta/get": { responses: { @@ -83378,6 +83824,14 @@ export interface operations { * @enum {string} */ privacy?: "secret" | "closed"; + /** + * @description The notification setting the team has chosen: + * * `notifications_enabled` - team members receive notifications when the team is @mentioned + * * `notifications_disabled` - no one receives notifications + * Default: `notifications_enabled` + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** * @description **Deprecated**. The permission that new repositories will be added to the team with when none is specified. * @default pull @@ -83473,6 +83927,14 @@ export interface operations { * @enum {string} */ privacy?: "secret" | "closed"; + /** + * @description The notification setting the team has chosen. Editing teams without specifying this parameter leaves `notification_setting` intact. The options are: + * *`notifications_enabled` - team members receive notifications when the team is @mentioned + * * `notifications_disabled` - no one receives notifications + * Default: `notifications_enabled` + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** * @description **Deprecated**. The permission that new repositories will be added to the team with when none is specified. * @default pull @@ -87139,7 +87601,7 @@ export interface operations { ref: string; /** @description Input keys and values configured in the workflow file. The maximum number of properties is 10. Any default properties configured in the workflow file will be used when `inputs` are omitted. */ inputs?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -88548,11 +89010,11 @@ export interface operations { "application/json": OneOf<[{ /** @enum {unknown} */ status: "completed"; - [key: string]: unknown | undefined; + [key: string]: unknown; }, { /** @enum {unknown} */ status?: "queued" | "in_progress"; - [key: string]: unknown | undefined; + [key: string]: unknown; }]>; }; }; @@ -88640,7 +89102,7 @@ export interface operations { summary: string; /** @description Can contain Markdown. */ text?: string; - /** @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/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)". */ + /** @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/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/articles/about-status-checks#checks)". */ annotations?: ({ /** @description The path of the file to add an annotation to. For example, `assets/css/main.css`. */ path: string; @@ -88683,14 +89145,14 @@ export interface operations { /** @description A reference for the action on the integrator's system. The maximum size is 20 characters. */ identifier: string; })[]; - }) & (({ + }) & ({ /** @enum {unknown} */ status?: "completed"; - [key: string]: unknown | undefined; - }) | ({ + [key: string]: unknown; + } | ({ /** @enum {unknown} */ status?: "queued" | "in_progress"; - [key: string]: unknown | undefined; + [key: string]: unknown; })); }; }; @@ -89148,7 +89610,7 @@ export interface operations { content: { "application/json": components["schemas"]["code-scanning-analysis"]; "application/json+sarif": { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -90816,7 +91278,7 @@ export interface operations { "repos/get-content": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -90863,7 +91325,7 @@ export interface operations { content: string; /** @description **Required if you are updating a file**. The blob SHA of the file being replaced. */ sha?: string; - /** @description The branch name. Default: the repository’s default branch (usually `master`) */ + /** @description The branch name. Default: the repository’s default branch. */ branch?: string; /** @description The person that committed the file. Default: the authenticated user. */ committer?: { @@ -90930,7 +91392,7 @@ export interface operations { message: string; /** @description The blob SHA of the file being deleted. */ sha: string; - /** @description The branch name. Default: the repository’s default branch (usually `master`) */ + /** @description The branch name. Default: the repository’s default branch */ branch?: string; /** @description object containing information about the committer. */ committer?: { @@ -91347,6 +91809,31 @@ export interface operations { 404: components["responses"]["not_found"]; }; }; + /** + * Export a software bill of materials (SBOM) for a repository. + * @description Exports the software bill of materials (SBOM) for a repository in SPDX JSON format. + */ + "dependency-graph/export-sbom": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + responses: { + /** @description Response */ + 200: { + headers: { + Link: components["headers"]["link"]; + }; + content: { + "application/json": components["schemas"]["dependency-graph-spdx-sbom"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + }; + }; /** * Create a snapshot of dependencies 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. @@ -91489,7 +91976,7 @@ export interface operations { /** @description The [status](https://docs.github.com/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. */ required_contexts?: (string)[]; payload?: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, string]>; /** * @description Name for the target deployment environment (e.g., `production`, `staging`, `qa`). @@ -91721,7 +92208,7 @@ export interface operations { event_type: string; /** @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. */ client_payload?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -92040,6 +92527,8 @@ export interface operations { * @description Create a fork for the authenticated user. * * **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + * + * **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. */ "repos/create-fork": { parameters: { @@ -95027,7 +95516,7 @@ export interface operations { }; requestBody: { content: { - "application/json": ({ + "application/json": { /** @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/)." */ cname?: OneOf<[string, null]>; /** @description Specify whether HTTPS should be enforced for the repository. */ @@ -95046,7 +95535,7 @@ export interface operations { */ path: "/" | "/docs"; }); - }) & (unknown | unknown | unknown | unknown | unknown); + }; }; }; responses: { @@ -95072,7 +95561,7 @@ export interface operations { }; requestBody: { content: { - "application/json": OneOf<[({ + "application/json": OneOf<[{ /** * @description The process in which the Page will be built. Possible values are `"legacy"` and `"workflow"`. * @enum {string} @@ -95089,7 +95578,7 @@ export interface operations { */ path?: "/" | "/docs"; }; - }) & (unknown | unknown), null]>; + }, null]>; }; }; responses: { @@ -96101,7 +96590,7 @@ export interface operations { reviewers?: (string)[]; /** @description An array of team `slug`s that will be requested. */ team_reviewers?: (string)[]; - } & (unknown | unknown); + }; }; }; responses: { @@ -96447,7 +96936,7 @@ export interface operations { "repos/get-readme": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -96475,7 +96964,7 @@ export interface operations { "repos/get-readme-in-directory": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -96544,7 +97033,7 @@ export interface operations { "application/json": { /** @description The name of the tag. */ tag_name: string; - /** @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`). */ + /** @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. */ target_commitish?: string; /** @description The name of the release. */ name?: string; @@ -96801,7 +97290,7 @@ export interface operations { "application/json": { /** @description The name of the tag. */ tag_name?: string; - /** @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`). */ + /** @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. */ target_commitish?: string; /** @description The name of the release. */ name?: string; @@ -97145,6 +97634,141 @@ export interface operations { 503: components["responses"]["service_unavailable"]; }; }; + /** + * List repository security advisories + * @description Lists security advisories in a repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + * + * You 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. + */ + "security-advisories/list-repository-advisories": { + parameters: { + query: { + direction?: components["parameters"]["direction"]; + /** @description The property to sort the results by. */ + sort?: "created" | "updated" | "published"; + before?: components["parameters"]["pagination-before"]; + after?: components["parameters"]["pagination-after"]; + /** @description Number of advisories to return per page. */ + per_page?: number; + /** @description Filter by state of the repository advisories. Only advisories of this state will be returned. */ + state?: "triage" | "draft" | "published" | "closed"; + }; + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": (components["schemas"]["repository-advisory"])[]; + }; + }; + 400: components["responses"]["bad_request"]; + 404: components["responses"]["not_found"]; + }; + }; + /** + * Create a repository security advisory + * @description Creates a new repository security advisory. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + */ + "security-advisories/create-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["repository-advisory-create"]; + }; + }; + responses: { + /** @description Response */ + 201: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + 422: components["responses"]["validation_failed"]; + }; + }; + /** + * Get a repository security advisory + * @description Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You can access any published security advisory on a public repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + * + * You 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 + * collaborator on the security advisory. + */ + "security-advisories/get-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + ghsa_id: components["parameters"]["ghsa_id"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + }; + }; + /** + * Update a repository security advisory + * @description Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to update any security advisory, you must be a security manager or administrator of that repository, + * or a collaborator on the repository security advisory. + */ + "security-advisories/update-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + ghsa_id: components["parameters"]["ghsa_id"]; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["repository-advisory-update"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + /** @description Validation failed, or the endpoint has been spammed. */ + 422: { + content: { + "application/json": components["schemas"]["validation-error"]; + }; + }; + }; + }; /** * List stargazers * @description Lists the people that have starred the repository. @@ -109663,6 +110287,76 @@ export interface operations { 200: never; }; }; + /** + * This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + * + * To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + * @description A repository security advisory was published. + */ + "repository-advisory/published": { + parameters: { + header: { + /** @example GitHub-Hookshot/123abc */ + "User-Agent"?: string; + /** @example 12312312 */ + "X-Github-Hook-Id"?: string; + /** @example issues */ + "X-Github-Event"?: string; + /** @example 123123 */ + "X-Github-Hook-Installation-Target-Id"?: string; + /** @example repository */ + "X-Github-Hook-Installation-Target-Type"?: string; + /** @example 0b989ba4-242f-11e5-81e1-c7b6966d2516 */ + "X-GitHub-Delivery"?: string; + /** @example sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e */ + "X-Hub-Signature-256"?: string; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["webhook-repository-advisory-published"]; + }; + }; + responses: { + /** @description Return a 200 status to indicate that the data was received successfully */ + 200: never; + }; + }; + /** + * This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + * + * To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + * @description A private vulnerability report was submitted. + */ + "repository-advisory/reported": { + parameters: { + header: { + /** @example GitHub-Hookshot/123abc */ + "User-Agent"?: string; + /** @example 12312312 */ + "X-Github-Hook-Id"?: string; + /** @example issues */ + "X-Github-Event"?: string; + /** @example 123123 */ + "X-Github-Hook-Installation-Target-Id"?: string; + /** @example repository */ + "X-Github-Hook-Installation-Target-Type"?: string; + /** @example 0b989ba4-242f-11e5-81e1-c7b6966d2516 */ + "X-GitHub-Delivery"?: string; + /** @example sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e */ + "X-Hub-Signature-256"?: string; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["webhook-repository-advisory-reported"]; + }; + }; + responses: { + /** @description Return a 200 status to indicate that the data was received successfully */ + 200: never; + }; + }; /** * This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. * diff --git a/examples/github-api-next.yaml b/examples/github-api-next.yaml index 6c0128861..de8e41685 100644 --- a/examples/github-api-next.yaml +++ b/examples/github-api-next.yaml @@ -2761,9 +2761,9 @@ paths: 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/)." - **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. + The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. - **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. + **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. tags: - meta operationId: meta/get @@ -3241,7 +3241,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens post: summary: Review requests to access organization resources with fine-grained personal access tokens @@ -3313,7 +3313,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-token-requests/{pat_request_id}": post: summary: Review a request to access organization resources with a fine-grained @@ -3381,7 +3381,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-token-requests/{pat_request_id}/repositories": get: summary: List repositories requested to be accessed by a fine-grained personal @@ -3433,7 +3433,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens": get: summary: List fine-grained personal access tokens with access to organization @@ -3487,7 +3487,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens post: summary: Update the access to organization resources via fine-grained personal access tokens @@ -3552,7 +3552,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens/{pat_id}": post: summary: Update the access a fine-grained personal access token has to organization @@ -3606,7 +3606,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens/{pat_id}/repositories": get: summary: List repositories a fine-grained personal access token has access to @@ -3656,7 +3656,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/orgs/{org}": get: summary: Get an organization @@ -10442,6 +10442,15 @@ paths: enum: - secret - closed + notification_setting: + type: string + description: "The notification setting the team has chosen: \n * + `notifications_enabled` - team members receive notifications when + the team is @mentioned \n * `notifications_disabled` - no one + receives notifications \nDefault: `notifications_enabled`" + enum: + - notifications_enabled + - notifications_disabled permission: type: string description: "**Deprecated**. The permission that new repositories @@ -10461,6 +10470,7 @@ paths: name: Justice League description: A great team permission: push + notification_setting: notifications_enabled privacy: closed responses: '201': @@ -10555,6 +10565,16 @@ paths: enum: - secret - closed + notification_setting: + type: string + 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 \nDefault: `notifications_enabled`" + enum: + - notifications_enabled + - notifications_disabled permission: type: string description: "**Deprecated**. The permission that new repositories @@ -10575,6 +10595,7 @@ paths: name: new team name description: new team description privacy: closed + notification_setting: notifications_enabled responses: '200': description: Response when the updated information already exists @@ -18609,8 +18630,10 @@ paths: to make multiple requests to the [Update a check run](https://docs.github.com/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 how you can view annotations - on GitHub, see "[About status checks](https://docs.github.com/articles/about-status-checks#checks)". + for the check run. GitHub Actions are limited to 10 warning + annotations and 10 error annotations per step. For details + about how you can view annotations on GitHub, see "[About + status checks](https://docs.github.com/articles/about-status-checks#checks)". maxItems: 50 items: type: object @@ -18931,8 +18954,9 @@ paths: have to make multiple requests to the [Update a check run](https://docs.github.com/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)". + 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/articles/about-status-checks#checks)". maxItems: 50 items: type: object @@ -22228,7 +22252,7 @@ paths: x-multi-segment: true - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -22314,7 +22338,7 @@ paths: branch: type: string description: 'The branch name. Default: the repository’s default - branch (usually `master`)' + branch.' committer: type: object description: 'The person that committed the file. Default: the authenticated @@ -22450,7 +22474,7 @@ paths: branch: type: string description: 'The branch name. Default: the repository’s default - branch (usually `master`)' + branch' committer: type: object description: object containing information about the committer. @@ -23054,6 +23078,41 @@ paths: githubCloudOnly: false category: dependency-graph subcategory: dependency-review + "/repos/{owner}/{repo}/dependency-graph/sbom": + get: + summary: Export a software bill of materials (SBOM) for a repository. + description: Exports the software bill of materials (SBOM) for a repository + in SPDX JSON format. + tags: + - dependency-graph + operationId: dependency-graph/export-sbom + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/dependency-graph/sboms#export-a-software-bill-of-materials-sbom-for-a-repository + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/dependency-graph-spdx-sbom" + examples: + default: + "$ref": "#/components/examples/dependency-graph-export-sbom-response" + headers: + Link: + "$ref": "#/components/headers/link" + '404': + "$ref": "#/components/responses/not_found" + '403': + "$ref": "#/components/responses/forbidden" + x-github: + githubCloudOnly: false + category: dependency-graph + subcategory: sboms "/repos/{owner}/{repo}/dependency-graph/snapshots": post: summary: Create a snapshot of dependencies for a repository @@ -24130,6 +24189,8 @@ paths: Create a fork for the authenticated user. **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + + **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. tags: - repos operationId: repos/create-fork @@ -31405,7 +31466,7 @@ paths: - "$ref": "#/components/parameters/repo" - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -31454,7 +31515,7 @@ paths: x-multi-segment: true - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -31548,7 +31609,7 @@ paths: 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`).' + default branch.' name: type: string description: The name of the release. @@ -31941,7 +32002,7 @@ paths: 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`).' + default branch.' name: type: string description: The name of the release. @@ -32483,6 +32544,313 @@ paths: enabledForGitHubApps: true category: secret-scanning subcategory: + "/repos/{owner}/{repo}/security-advisories": + get: + summary: List repository security advisories + description: |- + Lists security advisories in a repository. + You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + + You 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. + tags: + - security-advisories + operationId: security-advisories/list-repository-advisories + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#list-repository-security-advisories + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/direction" + - name: sort + description: The property to sort the results by. + in: query + required: false + schema: + type: string + enum: + - created + - updated + - published + default: created + - "$ref": "#/components/parameters/pagination-before" + - "$ref": "#/components/parameters/pagination-after" + - name: per_page + description: Number of advisories to return per page. + in: query + required: false + schema: + type: integer + minimum: 1 + maximum: 100 + default: 30 + - name: state + description: Filter by state of the repository advisories. Only advisories + of this state will be returned. + in: query + required: false + schema: + type: string + enum: + - triage + - draft + - published + - closed + responses: + '200': + description: Response + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/list-repository-advisories" + '400': + "$ref": "#/components/responses/bad_request" + '404': + "$ref": "#/components/responses/not_found" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + post: + summary: Create a repository security advisory + description: |- + Creates a new repository security advisory. + You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + + In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + tags: + - security-advisories + operationId: security-advisories/create-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#create-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory-create" + examples: + default: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + severity: high + cve_id: + vulnerabilities: + - package: + name: a-package + ecosystem: npm + vulnerable_version_range: "< 1.0.0" + patched_versions: 1.0.0 + vulnerable_functions: + - important_function + cwe_ids: + - CWE-1101 + - CWE-20 + credits: + - login: monalisa + type: reporter + - login: octocat + type: analyst + withVectorString: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + cvss_vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L + cve_id: + vulnerabilities: + - package: + name: a-package + ecosystem: npm + vulnerable_version_range: "< 1.0.0" + patched_versions: 1.0.0 + vulnerable_functions: + - important_function + cwe_ids: + - CWE-1101 + - CWE-20 + credits: + - login: monalisa + type: reporter + - login: octocat + type: analyst + minimal: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + vulnerabilities: + - package: + ecosystem: npm + responses: + '201': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + '422': + "$ref": "#/components/responses/validation_failed" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + "/repos/{owner}/{repo}/security-advisories/{ghsa_id}": + get: + summary: Get a repository security advisory + description: |- + Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + You can access any published security advisory on a public repository. + You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + + You 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 + collaborator on the security advisory. + tags: + - security-advisories + operationId: security-advisories/get-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#get-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/ghsa_id" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + patch: + summary: Update a repository security advisory + description: |- + Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + + In order to update any security advisory, you must be a security manager or administrator of that repository, + or a collaborator on the repository security advisory. + tags: + - security-advisories + operationId: security-advisories/update-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#update-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/ghsa_id" + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory-update" + examples: + default: + summary: Updating the severity and state. + value: + severity: critical + state: published + add_credit: + summary: When adding a credit to an advisory, you must send the whole + array of values. + value: + credits: + - login: monauser + type: remediation_developer + update_vvrs: + summary: When adding vulnerable versions, you must include existing + vulnerable versions in the array. + value: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + invalid_state_transition: + summary: Some state transitions are invalid, such as changing the + state from `published` to `draft` + value: + state: draft + update_severity_with_cvss_set: + summary: Severity cannot be updated when the CVSS is already set. + value: + severity: low + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + add_credit: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + '422': + description: Validation failed, or the endpoint has been spammed. + content: + application/json: + schema: + "$ref": "#/components/schemas/validation-error" + examples: + invalid_state_transition: + value: + message: Invalid state transition from `published` to `draft`. + update_severity_with_cvss_set: + value: + message: Cannot update severity value when CVSS is set. + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories "/repos/{owner}/{repo}/stargazers": get: summary: List stargazers @@ -53837,16 +54205,16 @@ webhooks: - repository - organization - app - repository-archived: + repository-advisory-published: post: summary: |- - This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. + This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." - To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. - description: A repository was archived. - operationId: repository/archived + To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + description: A repository security advisory was published. + operationId: repository-advisory/published externalDocs: - url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository + url: https://docs.github.com/webhooks-and-events/webhooks/webhook-events-and-payloads#repository-advisory parameters: - name: User-Agent in: header @@ -53888,7 +54256,7 @@ webhooks: content: application/json: schema: - "$ref": "#/components/schemas/webhook-repository-archived" + "$ref": "#/components/schemas/webhook-repository-advisory-published" responses: '200': description: Return a 200 status to indicate that the data was received @@ -53896,20 +54264,148 @@ webhooks: x-github: githubCloudOnly: false category: webhooks - subcategory: repository + subcategory: repository-advisory supported-webhook-types: - - business - repository - organization - app - repository-created: + repository-advisory-reported: + post: + summary: |- + This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + + To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + description: A private vulnerability report was submitted. + operationId: repository-advisory/reported + externalDocs: + url: https://docs.github.com/webhooks-and-events/webhooks/webhook-events-and-payloads#repository-advisory + parameters: + - name: User-Agent + in: header + example: GitHub-Hookshot/123abc + schema: + type: string + - name: X-Github-Hook-Id + in: header + example: 12312312 + schema: + type: string + - name: X-Github-Event + in: header + example: issues + schema: + type: string + - name: X-Github-Hook-Installation-Target-Id + in: header + example: 123123 + schema: + type: string + - name: X-Github-Hook-Installation-Target-Type + in: header + example: repository + schema: + type: string + - name: X-GitHub-Delivery + in: header + example: 0b989ba4-242f-11e5-81e1-c7b6966d2516 + schema: + type: string + - name: X-Hub-Signature-256 + in: header + example: sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/webhook-repository-advisory-reported" + responses: + '200': + description: Return a 200 status to indicate that the data was received + successfully + x-github: + githubCloudOnly: false + category: webhooks + subcategory: repository-advisory + supported-webhook-types: + - repository + - organization + - app + repository-archived: post: summary: |- This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. - description: A repository was created. - operationId: repository/created + description: A repository was archived. + operationId: repository/archived + externalDocs: + url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository + parameters: + - name: User-Agent + in: header + example: GitHub-Hookshot/123abc + schema: + type: string + - name: X-Github-Hook-Id + in: header + example: 12312312 + schema: + type: string + - name: X-Github-Event + in: header + example: issues + schema: + type: string + - name: X-Github-Hook-Installation-Target-Id + in: header + example: 123123 + schema: + type: string + - name: X-Github-Hook-Installation-Target-Type + in: header + example: repository + schema: + type: string + - name: X-GitHub-Delivery + in: header + example: 0b989ba4-242f-11e5-81e1-c7b6966d2516 + schema: + type: string + - name: X-Hub-Signature-256 + in: header + example: sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/webhook-repository-archived" + responses: + '200': + description: Return a 200 status to indicate that the data was received + successfully + x-github: + githubCloudOnly: false + category: webhooks + subcategory: repository + supported-webhook-types: + - business + - repository + - organization + - app + repository-created: + post: + summary: |- + This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. + + To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. + description: A repository was created. + operationId: repository/created externalDocs: url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository parameters: @@ -57862,13 +58358,6 @@ components: enum: - read - write - repository_announcement_banners: - type: string - description: The level of permission to grant the access token to view and - manage announcement banners for a repository. - enum: - - read - - write repository_hooks: type: string description: The level of permission to grant the access token to manage @@ -61527,67 +62016,61 @@ components: items: type: string examples: - - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl + - ssh-ed25519 ABCDEFGHIJKLMNOPQRSTUVWXYZ hooks: type: array items: type: string examples: - - 127.0.0.1/32 + - 192.0.2.1 web: type: array items: type: string examples: - - 127.0.0.1/32 + - 192.0.2.1 api: type: array items: type: string examples: - - 127.0.0.1/32 + - 192.0.2.1 git: type: array items: type: string examples: - - 127.0.0.1/32 + - 192.0.2.1 packages: type: array items: type: string examples: - - 13.65.0.0/16 - - 157.55.204.33/32 - - 2a01:111:f403:f90c::/62 + - 192.0.2.1 pages: type: array items: type: string examples: - - 192.30.252.153/32 - - 192.30.252.154/32 + - 192.0.2.1 importer: type: array items: type: string examples: - - 54.158.161.132 - - 54.226.70.38 + - 192.0.2.1 actions: type: array items: type: string examples: - - 13.64.0.0/16 - - 13.65.0.0/16 + - 192.0.2.1 dependabot: type: array items: type: string examples: - - 192.168.7.15/32 - - 192.168.7.16/32 + - 192.0.2.1 required: - verifiable_password_authentication security-and-analysis: @@ -64061,6 +64544,11 @@ components: type: string examples: - closed + notification_setting: + description: The notification setting the team has set + type: string + examples: + - notifications_enabled html_url: type: string format: uri @@ -64111,6 +64599,8 @@ components: - 'null' privacy: type: string + notification_setting: + type: string permission: type: string permissions: @@ -64895,6 +65385,14 @@ components: - secret examples: - closed + notification_setting: + description: The notification setting the team has set + type: string + enum: + - notifications_enabled + - notifications_disabled + examples: + - notifications_enabled permission: description: Permission that the team will have for its repositories type: string @@ -68071,6 +68569,8 @@ components: - 'null' privacy: type: string + notification_setting: + type: string permission: type: string members_url: @@ -71426,6 +71926,167 @@ components: - source_repository_url - vulnerabilities - scope + dependency-graph-spdx-sbom: + title: Dependency Graph SPDX SBOM + description: A schema for the SPDX JSON format returned by the Dependency Graph. + type: object + properties: + sbom: + type: object + properties: + SPDXID: + type: string + description: The SPDX identifier for the SPDX document. + examples: + - SPDXRef-DOCUMENT + spdxVersion: + type: string + description: The version of the SPDX specification that this document + conforms to. + examples: + - SPDX-2.3 + creationInfo: + type: object + properties: + created: + type: string + description: The date and time the SPDX document was created. + examples: + - '2021-11-03T00:00:00Z' + creators: + type: array + items: + type: string + examples: + - GitHub + description: The tools that were used to generate the SPDX document. + required: + - created + - creators + name: + type: string + description: The name of the SPDX document. + examples: + - github/github + dataLicense: + type: string + description: The license under which the SPDX document is licensed. + examples: + - CC0-1.0 + documentDescribes: + type: array + items: + type: string + examples: + - github/github + description: The name of the repository that the SPDX document describes. + documentNamespace: + type: string + description: The namespace for the SPDX document. + examples: + - https://github.com/example/dependency_graph/sbom-123 + packages: + type: array + items: + type: object + properties: + SPDXID: + type: string + description: A unique SPDX identifier for the package. + examples: + - SPDXRef-Package + name: + type: string + description: The name of the package. + examples: + - rubygems:github/github + versionInfo: + type: string + description: |- + The version of the package. If the package does not have an exact version specified, + a version range is given. + examples: + - 1.0.0 + downloadLocation: + type: string + description: |- + The location where the package can be downloaded, + or NOASSERTION if this has not been determined. + examples: + - NOASSERTION + filesAnalyzed: + type: boolean + description: |- + Whether the package's file content has been subjected to + analysis during the creation of the SPDX document. + examples: + - false + licenseConcluded: + type: string + description: The license of the package as determined while creating + the SPDX document. + examples: + - MIT + licenseDeclared: + type: string + description: |- + The license of the package as declared by its author, or NOASSERTION if this information + was not available when the SPDX document was created. + examples: + - NOASSERTION + supplier: + type: string + description: The distribution source of this package, or NOASSERTION + if this was not determined. + examples: + - NOASSERTION + externalRefs: + type: array + items: + type: object + properties: + referenceCategory: + type: string + description: The category of reference to an external resource + this reference refers to. + examples: + - PACKAGE-MANAGER + referenceLocator: + type: string + description: A locator for the particular external resource + this reference refers to. + examples: + - pkg:gem/rails@6.0.1 + referenceType: + type: string + description: The category of reference to an external resource + this reference refers to. + examples: + - purl + required: + - referenceCategory + - referenceLocator + - referenceType + required: + - SPDXID + - name + - versionInfo + - downloadLocation + - filesAnalyzed + - licenseConcluded + - licenseDeclared + - supplier + required: + - SPDXID + - spdxVersion + - creationInfo + - name + - dataLicense + - documentDescribes + - documentNamespace + - packages + required: + - sbom metadata: title: metadata description: User-defined metadata to store domain-specific information limited @@ -74080,8 +74741,6 @@ components: - pull_request_review_id - diff_hunk - path - - position - - original_position - commit_id - original_commit_id - user @@ -76715,6 +77374,543 @@ components: required: - type - details + repository-advisory-ecosystems: + type: string + description: The package's language or package management ecosystem. + enum: + - rubygems + - npm + - pip + - maven + - nuget + - composer + - go + - rust + - erlang + - actions + - pub + - other + repository-advisory-vulnerability: + description: A product affected by the vulnerability detailed in a repository + security advisory. + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: + - object + - 'null' + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: + - string + - 'null' + description: The unique package name within its ecosystem. + required: + - ecosystem + - name + vulnerable_version_range: + type: + - string + - 'null' + description: The range of the package versions affected by the vulnerability. + patched_versions: + type: + - string + - 'null' + description: The package version(s) that resolve the vulnerability. + vulnerable_functions: + type: + - array + - 'null' + description: The functions in the package that are affected. + items: + type: string + required: + - package + - vulnerable_version_range + - patched_versions + - vulnerable_functions + additionalProperties: false + repository-advisory-credit-types: + type: string + description: The type of credit the user is receiving. + enum: + - analyst + - finder + - reporter + - coordinator + - remediation_developer + - remediation_reviewer + - remediation_verifier + - tool + - sponsor + - other + repository-advisory-credit: + description: A credit given to a user for a repository security advisory. + type: object + properties: + user: + "$ref": "#/components/schemas/simple-user" + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + state: + type: string + description: The state of the user's acceptance of the credit. + enum: + - accepted + - declined + - pending + required: + - user + - type + - state + additionalProperties: false + repository-advisory: + description: A repository security advisory. + type: object + properties: + ghsa_id: + type: string + description: The GitHub Security Advisory ID. + readOnly: true + cve_id: + type: + - string + - 'null' + description: The Common Vulnerabilities and Exposures (CVE) ID. + url: + type: string + description: The API URL for the advisory. + html_url: + type: string + format: uri + description: The URL for the advisory. + readOnly: true + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: + - string + - 'null' + description: A detailed description of what the advisory entails. + maxLength: 65535 + severity: + type: + - string + - 'null' + description: The severity of the advisory. + enum: + - critical + - high + - medium + - low + - + author: + readOnly: true + description: The author of the advisory. + allOf: + - "$ref": "#/components/schemas/simple-user" + type: + - 'null' + publisher: + readOnly: true + description: The publisher of the advisory. + allOf: + - "$ref": "#/components/schemas/simple-user" + type: + - 'null' + identifiers: + type: array + items: + type: object + properties: + type: + type: string + description: The type of identifier. + enum: + - CVE + - GHSA + value: + type: string + description: The identifier value. + required: + - type + - value + readOnly: true + state: + type: string + description: The state of the advisory. + enum: + - published + - closed + - withdrawn + - draft + - triage + created_at: + type: + - string + - 'null' + format: date-time + description: The date and time of when the advisory was created, in ISO + 8601 format. + readOnly: true + updated_at: + type: + - string + - 'null' + format: date-time + description: The date and time of when the advisory was last updated, in + ISO 8601 format. + readOnly: true + published_at: + type: + - string + - 'null' + format: date-time + description: The date and time of when the advisory was published, in ISO + 8601 format. + readOnly: true + closed_at: + type: + - string + - 'null' + format: date-time + description: The date and time of when the advisory was closed, in ISO 8601 + format. + readOnly: true + withdrawn_at: + type: + - string + - 'null' + format: date-time + description: The date and time of when the advisory was withdrawn, in ISO + 8601 format. + readOnly: true + submission: + type: + - object + - 'null' + readOnly: true + properties: + accepted: + type: boolean + description: Whether a private vulnerability report was accepted by + the repository's administrators. + readOnly: true + required: + - accepted + vulnerabilities: + type: + - array + - 'null' + items: + "$ref": "#/components/schemas/repository-advisory-vulnerability" + cvss: + type: + - object + - 'null' + properties: + vector_string: + type: + - string + - 'null' + description: The CVSS vector. + score: + type: + - number + - 'null' + description: The CVSS score. + minimum: 0 + maximum: 10 + readOnly: true + required: + - vector_string + - score + cwes: + type: + - array + - 'null' + items: + type: object + properties: + cwe_id: + type: string + description: The Common Weakness Enumeration (CWE) identifier. + name: + type: string + description: The name of the CWE. + readOnly: true + required: + - cwe_id + - name + readOnly: true + cwe_ids: + type: + - array + - 'null' + description: A list of only the CWE IDs. + items: + type: string + credits: + type: + - array + - 'null' + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + credits_detailed: + type: + - array + - 'null' + items: + "$ref": "#/components/schemas/repository-advisory-credit" + readOnly: true + required: + - ghsa_id + - cve_id + - url + - html_url + - summary + - description + - severity + - author + - publisher + - identifiers + - state + - created_at + - updated_at + - published_at + - closed_at + - withdrawn_at + - submission + - vulnerabilities + - cvss + - cwes + - cwe_ids + - credits + - credits_detailed + additionalProperties: false + repository-advisory-create: + type: object + properties: + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: string + description: A detailed description of what the advisory impacts. + maxLength: 65535 + cve_id: + type: + - string + - 'null' + description: The Common Vulnerabilities and Exposures (CVE) ID. + vulnerabilities: + type: array + description: A product affected by the vulnerability detailed in a repository + security advisory. + items: + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: object + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: + - string + - 'null' + description: The unique package name within its ecosystem. + required: + - ecosystem + vulnerable_version_range: + type: + - string + - 'null' + description: The range of the package versions affected by the vulnerability. + patched_versions: + type: + - string + - 'null' + description: The package version(s) that resolve the vulnerability. + vulnerable_functions: + type: + - array + - 'null' + description: The functions in the package that are affected. + items: + type: string + required: + - package + additionalProperties: false + cwe_ids: + type: + - array + - 'null' + description: A list of Common Weakness Enumeration (CWE) IDs. + items: + type: string + credits: + type: + - array + - 'null' + description: A list of users receiving credit for their participation in + the security advisory. + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + required: + - login + - type + additionalProperties: false + severity: + type: + - string + - 'null' + description: The severity of the advisory. You must choose between setting + this field or `cvss_vector_string`. + enum: + - critical + - high + - medium + - low + - + cvss_vector_string: + type: + - string + - 'null' + description: The CVSS vector that calculates the severity of the advisory. + You must choose between setting this field or `severity`. + required: + - summary + - description + - vulnerabilities + additionalProperties: false + repository-advisory-update: + type: object + properties: + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: string + description: A detailed description of what the advisory impacts. + maxLength: 65535 + cve_id: + type: + - string + - 'null' + description: The Common Vulnerabilities and Exposures (CVE) ID. + vulnerabilities: + type: array + description: A product affected by the vulnerability detailed in a repository + security advisory. + items: + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: object + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: + - string + - 'null' + description: The unique package name within its ecosystem. + required: + - ecosystem + vulnerable_version_range: + type: + - string + - 'null' + description: The range of the package versions affected by the vulnerability. + patched_versions: + type: + - string + - 'null' + description: The package version(s) that resolve the vulnerability. + vulnerable_functions: + type: + - array + - 'null' + description: The functions in the package that are affected. + items: + type: string + required: + - package + additionalProperties: false + cwe_ids: + type: + - array + - 'null' + description: A list of Common Weakness Enumeration (CWE) IDs. + items: + type: string + credits: + type: + - array + - 'null' + description: A list of users receiving credit for their participation in + the security advisory. + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + required: + - login + - type + additionalProperties: false + severity: + type: + - string + - 'null' + description: The severity of the advisory. You must choose between setting + this field or `cvss_vector_string`. + enum: + - critical + - high + - medium + - low + - + cvss_vector_string: + type: + - string + - 'null' + description: The CVSS vector that calculates the severity of the advisory. + You must choose between setting this field or `severity`. + state: + type: string + description: The state of the advisory. + enum: + - published + - closed + - draft + additionalProperties: false stargazer: title: Stargazer description: Stargazer @@ -115883,6 +117079,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -115899,6 +117102,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -115913,6 +117117,11 @@ components: - open - closed - secret + notification_setting: + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -116152,6 +117361,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -116168,6 +117384,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -116182,6 +117399,11 @@ components: - open - closed - secret + notification_setting: + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -116206,6 +117428,8 @@ components: properties: action: type: string + enum: + - checks_requested installation: "$ref": "#/components/schemas/simple-installation" merge_group: @@ -186034,6 +187258,54 @@ components: - action - release - repository + webhook-repository-advisory-published: + title: Repository advisory published event + type: object + properties: + action: + type: string + enum: + - published + enterprise: + "$ref": "#/components/schemas/enterprise" + installation: + "$ref": "#/components/schemas/simple-installation" + organization: + "$ref": "#/components/schemas/organization-simple" + repository: + "$ref": "#/components/schemas/repository" + repository_advisory: + "$ref": "#/components/schemas/repository-advisory" + sender: + "$ref": "#/components/schemas/simple-user" + required: + - action + - repository + - repository_advisory + webhook-repository-advisory-reported: + title: Repository advisory reported event + type: object + properties: + action: + type: string + enum: + - reported + enterprise: + "$ref": "#/components/schemas/enterprise" + installation: + "$ref": "#/components/schemas/simple-installation" + organization: + "$ref": "#/components/schemas/organization-simple" + repository: + "$ref": "#/components/schemas/repository" + repository_advisory: + "$ref": "#/components/schemas/repository-advisory" + sender: + "$ref": "#/components/schemas/simple-user" + required: + - action + - repository + - repository_advisory webhook-repository-archived: title: repository archived event type: object @@ -190059,6 +191331,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -190075,6 +191354,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -190089,6 +191369,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -190640,6 +191927,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -190656,6 +191950,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -190670,6 +191965,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -191221,6 +192523,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -191237,6 +192546,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -191251,6 +192561,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -191803,6 +193120,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -191819,6 +193143,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -191833,6 +193158,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -191888,6 +193220,15 @@ components: type: string required: - from + notification_setting: + type: object + properties: + from: + description: The previous version of the team's notification setting + if the action was `edited`. + type: string + required: + - from repository: type: object properties: @@ -192440,6 +193781,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -192456,6 +193804,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -192470,6 +193819,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -193023,6 +194379,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -193039,6 +194402,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -193053,6 +194417,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -202058,75 +203429,32 @@ components: value: verifiable_password_authentication: true ssh_key_fingerprints: - SHA256_RSA: uNiVztksCsDhcc0u9e8BujQXVUpKZIDTMczCvj3tD2s - SHA256_DSA: br9IjFspm1vxR3iA35FWE+4VTyz1hYVLIE2t1/CeyWQ - SHA256_ECDSA: p2QAMXNIC1TJYWeIOttrVc98/R1BUFWu3/LiyKgUfQM - SHA256_ED25519: "+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU" + SHA256_RSA: 1234567890 + SHA256_DSA: 1234567890 + SHA256_ECDSA: 1234567890 + SHA256_ED25519: 1234567890 ssh_keys: - - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl - - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBEmKSENjQEezOmxkZMy7opKgwFB9nkt5YRrYMjNuG5N87uRgg6CLrbo5wAdT/y6v0mKV0U2w0WZ2YB/++Tpockg= - - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCj7ndNxQowgcQnjshcLrqPEiiphnt+VTTvDP6mHBL9j1aNUkY4Ue1gvwnGLVlOhGeYrnZaMgRK6+PKCUXaDbC7qtbW8gIkhL7aGCsOr/C56SJMy/BCZfxd1nWzAOxSDPgVsmerOBYfNqltV9/hWCqBywINIR+5dIg6JTJ72pcEpEjcYgXkE2YEFXV1JHnsKgbLWNlhScqb2UmyRkQyytRLtL+38TGxkxCflmO+5Z8CSSNY7GidjMIZ7Q4zMjA2n1nGrlTDkzwDCsw+wqFPGQA179cnfGWOWRVruj16z6XyvxvjJwbz0wQZ75XK5tKSb7FNyeIEs4TT4jk+S4dhPeAUC5y+bDYirYgM4GC7uEnztnZyaVWQ7B381AK4Qdrwt51ZqExKbQpTUNn+EjqoTwvqNj4kqx5QUCI0ThS/YkOxJCXmPUWZbhjpCg56i+2aB6CmK2JGhn57K5mj0MNdBXA4/WnwH6XoPWJzK5Nyu2zB3nAZp+S5hpQs+p1vN1/wsjk= + - ssh-ed25519 ABCDEFGHIJKLMNOPQRSTUVWXYZ + - ecdsa-sha2-nistp256 ABCDEFGHIJKLMNOPQRSTUVWXYZ + - ssh-rsa ABCDEFGHIJKLMNOPQRSTUVWXYZ hooks: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 + - 192.0.2.1 web: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 - - 20.201.28.151/32 - - 20.205.243.166/32 - - 102.133.202.242/32 + - 192.0.2.1 api: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 - - 20.201.28.148/32 + - 192.0.2.1 git: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 + - 192.0.2.1 packages: - - 140.82.121.33/32 - - 192.30.255.164/31 - - 20.200.245.241/32 - - 20.233.54.55/32 + - 192.0.2.1 pages: - - 192.30.252.153/32 - - 192.30.252.154/32 - - 185.199.108.153/32 - - 185.199.109.153/32 - - 185.199.110.153/32 - - 185.199.111.153/32 - - 2606:50c0:8000::153/128 - - 2606:50c0:8001::153/128 - - 2606:50c0:8002::153/128 - - 2606:50c0:8003::153/128 + - 192.0.2.1 importer: - - 52.23.85.212/32 - - 52.0.228.224/32 - - 52.22.155.48/32 + - 192.0.2.1 actions: - - 4.148.0.0/16 - - 13.67.153.64/26 - - 2603:1030:804:220::/61 - - 2603:1036:2500:10::/64 + - 192.0.2.1 dependabot: - - 18.213.123.130/32 - - 3.217.79.163/32 - - 3.217.93.44/32 + - 192.0.2.1 public-repo-events-items: value: - id: '22249084964' @@ -204293,6 +205621,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -205208,6 +206537,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -205919,6 +207249,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208033,6 +209364,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208311,6 +209643,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208383,6 +209716,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208522,6 +209856,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208606,6 +209941,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -210918,6 +212254,7 @@ components: description: A great team. privacy: closed permission: admin + notification_setting: notifications_enabled members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos parent: @@ -212508,6 +213845,28 @@ components: advisory_ghsa_id: GHSA-fqfj-cmh6-hj49 advisory_summary: Ruby OpenID advisory_url: https://github.com/advisories/GHSA-fqfj-cmh6-hj49 + dependency-graph-export-sbom-response: + value: + sbom: + SPDXID: SPDXRef-DOCUMENT + spdxVersion: SPDX-2.3 + creationInfo: + created: '2021-09-01T00:00:00Z' + creators: + - 'Tool: GitHub.com-Dependency-Graph' + name: github/example + dataLicense: CC0-1.0 + documentDescribes: + - github/example + documentNamespace: https://github.com/github/example/dependency_graph/sbom-abcdef123456 + packages: + - SPDXID: SPDXRef-Package + name: rubygems:rails + versionInfo: 1.0.0 + downloadLocation: NOASSERTION + filesAnalyzed: false + licenseConcluded: NOASSERTION + licenseDeclared: NOASSERTION dependency-graph-create-snapshot-request: value: version: 0 @@ -212736,6 +214095,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -212794,6 +214154,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -214963,6 +216324,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -215536,6 +216898,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -215747,6 +217110,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -216224,6 +217588,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -217156,6 +218521,326 @@ components: - type: issue_comment details: issue_comment_url: https://api.github.com/repos/octocat/Hello-World/issues/comments/1081119451 + list-repository-advisories: + value: + - ghsa_id: GHSA-abcd-1234-efgh + cve_id: CVE-2050-00000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-abcd-1234-efgh + html_url: https://github.com/repo/a-package/security/advisories/GHSA-abcd-1234-efgh + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: critical + author: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + publisher: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-abcd-1234-efgh + - type: CVE + value: CVE-2050-00000 + state: published + created_at: '2020-01-01T00:00:00Z' + updated_at: '2020-01-02T00:00:00Z' + published_at: '2020-01-03T00:00:00Z' + closed_at: + withdrawn_at: + submission: + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H + score: 9.8 + cwes: + - cwe_id: CWE-123 + name: A CWE + cwe_ids: + - CWE-123 + credits: + - login: octocat + type: analyst + credits_detailed: + - user: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + type: analyst + state: accepted + - ghsa_id: GHSA-1234-5678-9012 + cve_id: CVE-2051-0000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-1234-5678-9012 + html_url: https://github.com/repo/a-package/security/advisories/GHSA-1234-5678-9012 + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: low + author: + login: monauser + id: 2 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monauser + html_url: https://github.com/monauser + followers_url: https://api.github.com/users/monauser/followers + following_url: https://api.github.com/users/monauser/following{/other_user} + gists_url: https://api.github.com/users/monauser/gists{/gist_id} + starred_url: https://api.github.com/users/monauser/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monauser/subscriptions + organizations_url: https://api.github.com/users/monauser/orgs + repos_url: https://api.github.com/users/monauser/repos + events_url: https://api.github.com/users/monauser/events{/privacy} + received_events_url: https://api.github.com/users/monauser/received_events + type: User + site_admin: false + publisher: + login: monalisa + id: 3 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monalisa + html_url: https://github.com/monalisa + followers_url: https://api.github.com/users/monalisa/followers + following_url: https://api.github.com/users/monalisa/following{/other_user} + gists_url: https://api.github.com/users/monalisa/gists{/gist_id} + starred_url: https://api.github.com/users/monalisa/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monalisa/subscriptions + organizations_url: https://api.github.com/users/monalisa/orgs + repos_url: https://api.github.com/users/monalisa/repos + events_url: https://api.github.com/users/monalisa/events{/privacy} + received_events_url: https://api.github.com/users/monalisa/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-1234-5678-9012 + - type: CVE + value: CVE-2051-00000 + state: published + created_at: '2020-01-03T00:00:00Z' + updated_at: '2020-01-04T00:00:00Z' + published_at: '2020-01-04T00:00:00Z' + closed_at: + withdrawn_at: + submission: + - accepted: true + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: AV:P/AC:H/PR:H/UI:R/S:U/C:N/I:L/A:N + score: 1.6 + cwes: + - cwe_id: CWE-456 + name: A CWE 2.0 + cwe_ids: + - CWE-456 + credits: + - login: monauser + type: reporter + credits_detailed: + - user: + login: monauser + id: 2 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monauser + html_url: https://github.com/monauser + followers_url: https://api.github.com/users/monauser/followers + following_url: https://api.github.com/users/monauser/following{/other_user} + gists_url: https://api.github.com/users/monauser/gists{/gist_id} + starred_url: https://api.github.com/users/monauser/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monauser/subscriptions + organizations_url: https://api.github.com/users/monauser/orgs + repos_url: https://api.github.com/users/monauser/repos + events_url: https://api.github.com/users/monauser/events{/privacy} + received_events_url: https://api.github.com/users/monauser/received_events + type: User + site_admin: false + type: reporter + state: accepted + repository-advisory: + value: + ghsa_id: GHSA-abcd-1234-efgh + cve_id: CVE-2050-00000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-abcd-1234-efgh + html_url: https://github.com/repo/a-package/security/advisories/GHSA-abcd-1234-efgh + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: critical + author: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + publisher: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-abcd-1234-efgh + - type: CVE + value: CVE-2050-00000 + state: published + created_at: '2020-01-01T00:00:00Z' + updated_at: '2020-01-02T00:00:00Z' + published_at: '2020-01-03T00:00:00Z' + closed_at: + withdrawn_at: + submission: + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H + score: 9.8 + cwes: + - cwe_id: CWE-123 + name: A CWE + cwe_ids: + - CWE-123 + credits: + - login: octocat + type: analyst + credits_detailed: + - user: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + type: analyst + state: accepted simple-user-items-default-response: summary: Default response value: @@ -221035,6 +222720,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -224164,6 +225850,13 @@ components: required: true schema: type: integer + ghsa_id: + name: ghsa_id + description: The GHSA (GitHub Security Advisory) identifier of the advisory. + in: path + required: true + schema: + type: string tag-protection-id: name: tag_protection_id description: The unique identifier of the tag protection. diff --git a/examples/github-api.ts b/examples/github-api.ts index dfbf713d4..2b9fbb314 100644 --- a/examples/github-api.ts +++ b/examples/github-api.ts @@ -439,9 +439,9 @@ export interface paths { * Get GitHub meta information * @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/)." * - * **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. + * The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. * - * **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. + * **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. */ get: operations["meta/get"]; }; @@ -4464,6 +4464,13 @@ export interface paths { */ get: operations["dependency-graph/diff-range"]; }; + "/repos/{owner}/{repo}/dependency-graph/sbom": { + /** + * Export a software bill of materials (SBOM) for a repository. + * @description Exports the software bill of materials (SBOM) for a repository in SPDX JSON format. + */ + get: operations["dependency-graph/export-sbom"]; + }; "/repos/{owner}/{repo}/dependency-graph/snapshots": { /** * Create a snapshot of dependencies for a repository @@ -4667,6 +4674,8 @@ export interface paths { * @description Create a fork for the authenticated user. * * **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + * + * **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. */ post: operations["repos/create-fork"]; }; @@ -5872,6 +5881,47 @@ export interface paths { */ get: operations["secret-scanning/list-locations-for-alert"]; }; + "/repos/{owner}/{repo}/security-advisories": { + /** + * List repository security advisories + * @description Lists security advisories in a repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + * + * You 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. + */ + get: operations["security-advisories/list-repository-advisories"]; + /** + * Create a repository security advisory + * @description Creates a new repository security advisory. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + */ + post: operations["security-advisories/create-repository-advisory"]; + }; + "/repos/{owner}/{repo}/security-advisories/{ghsa_id}": { + /** + * Get a repository security advisory + * @description Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You can access any published security advisory on a public repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + * + * You 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 + * collaborator on the security advisory. + */ + get: operations["security-advisories/get-repository-advisory"]; + /** + * Update a repository security advisory + * @description Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to update any security advisory, you must be a security manager or administrator of that repository, + * or a collaborator on the repository security advisory. + */ + patch: operations["security-advisories/update-repository-advisory"]; + }; "/repos/{owner}/{repo}/stargazers": { /** * List stargazers @@ -8238,19 +8288,19 @@ export interface components { url?: string; request: { /** @description The request headers sent with the webhook delivery. */ - headers: ({ - [key: string]: unknown | undefined; - }) | null; + headers: { + [key: string]: unknown; + } | null; /** @description The webhook payload. */ - payload: ({ - [key: string]: unknown | undefined; - }) | null; + payload: { + [key: string]: unknown; + } | null; }; response: { /** @description The response headers received when the delivery was made. */ - headers: ({ - [key: string]: unknown | undefined; - }) | null; + headers: { + [key: string]: unknown; + } | null; /** @description The response payload received. */ payload: string | null; }; @@ -8457,11 +8507,6 @@ export interface components { * @enum {string} */ pull_requests?: "read" | "write"; - /** - * @description The level of permission to grant the access token to view and manage announcement banners for a repository. - * @enum {string} - */ - repository_announcement_banners?: "read" | "write"; /** * @description The level of permission to grant the access token to manage the post-receive hooks for a repository. * @enum {string} @@ -10675,67 +10720,61 @@ export interface components { }; /** * @example [ - * "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl" + * "ssh-ed25519 ABCDEFGHIJKLMNOPQRSTUVWXYZ" * ] */ ssh_keys?: (string)[]; /** * @example [ - * "127.0.0.1/32" + * "192.0.2.1" * ] */ hooks?: (string)[]; /** * @example [ - * "127.0.0.1/32" + * "192.0.2.1" * ] */ web?: (string)[]; /** * @example [ - * "127.0.0.1/32" + * "192.0.2.1" * ] */ api?: (string)[]; /** * @example [ - * "127.0.0.1/32" + * "192.0.2.1" * ] */ git?: (string)[]; /** * @example [ - * "13.65.0.0/16", - * "157.55.204.33/32", - * "2a01:111:f403:f90c::/62" + * "192.0.2.1" * ] */ packages?: (string)[]; /** * @example [ - * "192.30.252.153/32", - * "192.30.252.154/32" + * "192.0.2.1" * ] */ pages?: (string)[]; /** * @example [ - * "54.158.161.132", - * "54.226.70.38" + * "192.0.2.1" * ] */ importer?: (string)[]; /** * @example [ - * "13.64.0.0/16", - * "13.65.0.0/16" + * "192.0.2.1" * ] */ actions?: (string)[]; /** * @example [ - * "192.168.7.15/32", - * "192.168.7.16/32" + * "192.0.2.1" * ] */ dependabot?: (string)[]; @@ -12422,6 +12461,11 @@ export interface components { * @example closed */ privacy?: string; + /** + * @description The notification setting the team has set + * @example notifications_enabled + */ + notification_setting?: string; /** * Format: uri * @example https://github.com/orgs/rails/teams/core @@ -12451,6 +12495,7 @@ export interface components { slug: string; description: string | null; privacy?: string; + notification_setting?: string; permission: string; permissions?: { pull: boolean; @@ -12708,6 +12753,11 @@ export interface components { * @example closed */ privacy?: string; + /** + * @description The notification setting the team has set + * @example notifications_enabled + */ + notification_setting?: string; /** * Format: uri * @example https://github.com/orgs/rails/teams/core @@ -12950,6 +13000,12 @@ export interface components { * @enum {string} */ privacy?: "closed" | "secret"; + /** + * @description The notification setting the team has set + * @example notifications_enabled + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** * @description Permission that the team will have for its repositories * @example push @@ -15101,7 +15157,7 @@ export interface components { */ task: string; payload: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, string]>; /** @example staging */ original_environment?: string; @@ -15357,6 +15413,7 @@ export interface components { slug?: string; description?: string | null; privacy?: string; + notification_setting?: string; permission?: string; members_url?: string; repositories_url?: string; @@ -17183,6 +17240,113 @@ export interface components { */ scope: "unknown" | "runtime" | "development"; })[]; + /** + * Dependency Graph SPDX SBOM + * @description A schema for the SPDX JSON format returned by the Dependency Graph. + */ + "dependency-graph-spdx-sbom": { + sbom: { + /** + * @description The SPDX identifier for the SPDX document. + * @example SPDXRef-DOCUMENT + */ + SPDXID: string; + /** + * @description The version of the SPDX specification that this document conforms to. + * @example SPDX-2.3 + */ + spdxVersion: string; + creationInfo: { + /** + * @description The date and time the SPDX document was created. + * @example 2021-11-03T00:00:00Z + */ + created: string; + /** @description The tools that were used to generate the SPDX document. */ + creators: (string)[]; + }; + /** + * @description The name of the SPDX document. + * @example github/github + */ + name: string; + /** + * @description The license under which the SPDX document is licensed. + * @example CC0-1.0 + */ + dataLicense: string; + /** @description The name of the repository that the SPDX document describes. */ + documentDescribes: (string)[]; + /** + * @description The namespace for the SPDX document. + * @example https://github.com/example/dependency_graph/sbom-123 + */ + documentNamespace: string; + packages: ({ + /** + * @description A unique SPDX identifier for the package. + * @example SPDXRef-Package + */ + SPDXID?: string; + /** + * @description The name of the package. + * @example rubygems:github/github + */ + name?: string; + /** + * @description The version of the package. If the package does not have an exact version specified, + * a version range is given. + * @example 1.0.0 + */ + versionInfo?: string; + /** + * @description The location where the package can be downloaded, + * or NOASSERTION if this has not been determined. + * @example NOASSERTION + */ + downloadLocation?: string; + /** + * @description Whether the package's file content has been subjected to + * analysis during the creation of the SPDX document. + * @example false + */ + filesAnalyzed?: boolean; + /** + * @description The license of the package as determined while creating the SPDX document. + * @example MIT + */ + licenseConcluded?: string; + /** + * @description The license of the package as declared by its author, or NOASSERTION if this information + * was not available when the SPDX document was created. + * @example NOASSERTION + */ + licenseDeclared?: string; + /** + * @description The distribution source of this package, or NOASSERTION if this was not determined. + * @example NOASSERTION + */ + supplier?: string; + externalRefs?: ({ + /** + * @description The category of reference to an external resource this reference refers to. + * @example PACKAGE-MANAGER + */ + referenceCategory: string; + /** + * @description A locator for the particular external resource this reference refers to. + * @example pkg:gem/rails@6.0.1 + */ + referenceLocator: string; + /** + * @description The category of reference to an external resource this reference refers to. + * @example purl + */ + referenceType: string; + })[]; + })[]; + }; + }; /** * metadata * @description User-defined metadata to store domain-specific information limited to 8 keys with scalar values. @@ -18624,12 +18788,12 @@ export interface components { * @description The line index in the diff to which the comment applies. This field is deprecated; use `line` instead. * @example 1 */ - position: number; + position?: number; /** * @description The index of the original line in the diff to which the comment applies. This field is deprecated; use `original_line` instead. * @example 4 */ - original_position: number; + original_position?: number; /** * @description The SHA of the commit to which the comment applies. * @example 6dcb09b5b57875f334f61aebed695e2e4193db5e @@ -20038,6 +20202,213 @@ export interface components { type: "commit" | "issue_title" | "issue_body" | "issue_comment"; details: components["schemas"]["secret-scanning-location-commit"] | components["schemas"]["secret-scanning-location-issue-title"] | components["schemas"]["secret-scanning-location-issue-body"] | components["schemas"]["secret-scanning-location-issue-comment"]; }; + /** + * @description The package's language or package management ecosystem. + * @enum {string} + */ + "repository-advisory-ecosystems": "rubygems" | "npm" | "pip" | "maven" | "nuget" | "composer" | "go" | "rust" | "erlang" | "actions" | "pub" | "other"; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + "repository-advisory-vulnerability": { + /** @description The name of the package affected by the vulnerability. */ + package: ({ + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name: string | null; + }) | null; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range: string | null; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions: string | null; + /** @description The functions in the package that are affected. */ + vulnerable_functions: (string)[] | null; + }; + /** + * @description The type of credit the user is receiving. + * @enum {string} + */ + "repository-advisory-credit-types": "analyst" | "finder" | "reporter" | "coordinator" | "remediation_developer" | "remediation_reviewer" | "remediation_verifier" | "tool" | "sponsor" | "other"; + /** @description A credit given to a user for a repository security advisory. */ + "repository-advisory-credit": { + user: components["schemas"]["simple-user"]; + type: components["schemas"]["repository-advisory-credit-types"]; + /** + * @description The state of the user's acceptance of the credit. + * @enum {string} + */ + state: "accepted" | "declined" | "pending"; + }; + /** @description A repository security advisory. */ + "repository-advisory": { + /** @description The GitHub Security Advisory ID. */ + ghsa_id: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id: string | null; + /** @description The API URL for the advisory. */ + url: string; + /** + * Format: uri + * @description The URL for the advisory. + */ + html_url: string; + /** @description A short summary of the advisory. */ + summary: string; + /** @description A detailed description of what the advisory entails. */ + description: string | null; + /** + * @description The severity of the advisory. + * @enum {string|null} + */ + severity: "critical" | "high" | "medium" | "low" | null; + /** @description The author of the advisory. */ + author: components["schemas"]["simple-user"] | null; + /** @description The publisher of the advisory. */ + publisher: components["schemas"]["simple-user"] | null; + identifiers: readonly ({ + /** + * @description The type of identifier. + * @enum {string} + */ + type: "CVE" | "GHSA"; + /** @description The identifier value. */ + value: string; + })[]; + /** + * @description The state of the advisory. + * @enum {string} + */ + state: "published" | "closed" | "withdrawn" | "draft" | "triage"; + /** + * Format: date-time + * @description The date and time of when the advisory was created, in ISO 8601 format. + */ + created_at: string | null; + /** + * Format: date-time + * @description The date and time of when the advisory was last updated, in ISO 8601 format. + */ + updated_at: string | null; + /** + * Format: date-time + * @description The date and time of when the advisory was published, in ISO 8601 format. + */ + published_at: string | null; + /** + * Format: date-time + * @description The date and time of when the advisory was closed, in ISO 8601 format. + */ + closed_at: string | null; + /** + * Format: date-time + * @description The date and time of when the advisory was withdrawn, in ISO 8601 format. + */ + withdrawn_at: string | null; + submission: { + /** @description Whether a private vulnerability report was accepted by the repository's administrators. */ + readonly accepted: boolean; + } | null; + vulnerabilities: (components["schemas"]["repository-advisory-vulnerability"])[] | null; + cvss: ({ + /** @description The CVSS vector. */ + vector_string: string | null; + /** @description The CVSS score. */ + score: number | null; + }) | null; + cwes: readonly ({ + /** @description The Common Weakness Enumeration (CWE) identifier. */ + cwe_id: string; + /** @description The name of the CWE. */ + name: string; + })[] | null; + /** @description A list of only the CWE IDs. */ + cwe_ids: (string)[] | null; + credits: ({ + /** @description The username of the user credited. */ + login?: string; + type?: components["schemas"]["repository-advisory-credit-types"]; + })[] | null; + credits_detailed: readonly (components["schemas"]["repository-advisory-credit"])[] | null; + }; + "repository-advisory-create": { + /** @description A short summary of the advisory. */ + summary: string; + /** @description A detailed description of what the advisory impacts. */ + description: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id?: string | null; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + vulnerabilities: ({ + /** @description The name of the package affected by the vulnerability. */ + package: { + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name?: string | null; + }; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range?: string | null; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions?: string | null; + /** @description The functions in the package that are affected. */ + vulnerable_functions?: (string)[] | null; + })[]; + /** @description A list of Common Weakness Enumeration (CWE) IDs. */ + cwe_ids?: (string)[] | null; + /** @description A list of users receiving credit for their participation in the security advisory. */ + credits?: ({ + /** @description The username of the user credited. */ + login: string; + type: components["schemas"]["repository-advisory-credit-types"]; + })[] | null; + /** + * @description The severity of the advisory. You must choose between setting this field or `cvss_vector_string`. + * @enum {string|null} + */ + severity?: "critical" | "high" | "medium" | "low" | null; + /** @description The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`. */ + cvss_vector_string?: string | null; + }; + "repository-advisory-update": { + /** @description A short summary of the advisory. */ + summary?: string; + /** @description A detailed description of what the advisory impacts. */ + description?: string; + /** @description The Common Vulnerabilities and Exposures (CVE) ID. */ + cve_id?: string | null; + /** @description A product affected by the vulnerability detailed in a repository security advisory. */ + vulnerabilities?: ({ + /** @description The name of the package affected by the vulnerability. */ + package: { + ecosystem: components["schemas"]["repository-advisory-ecosystems"]; + /** @description The unique package name within its ecosystem. */ + name?: string | null; + }; + /** @description The range of the package versions affected by the vulnerability. */ + vulnerable_version_range?: string | null; + /** @description The package version(s) that resolve the vulnerability. */ + patched_versions?: string | null; + /** @description The functions in the package that are affected. */ + vulnerable_functions?: (string)[] | null; + })[]; + /** @description A list of Common Weakness Enumeration (CWE) IDs. */ + cwe_ids?: (string)[] | null; + /** @description A list of users receiving credit for their participation in the security advisory. */ + credits?: ({ + /** @description The username of the user credited. */ + login: string; + type: components["schemas"]["repository-advisory-credit-types"]; + })[] | null; + /** + * @description The severity of the advisory. You must choose between setting this field or `cvss_vector_string`. + * @enum {string|null} + */ + severity?: "critical" | "high" | "medium" | "low" | null; + /** @description The CVSS vector that calculates the severity of the advisory. You must choose between setting this field or `severity`. */ + cvss_vector_string?: string | null; + /** + * @description The state of the advisory. + * @enum {string} + */ + state?: "published" | "closed" | "draft"; + }; /** * Stargazer * @description Stargazer @@ -37662,6 +38033,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -37675,6 +38051,8 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** @enum {string} */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -37805,6 +38183,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -37818,6 +38201,8 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** @enum {string} */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -37829,7 +38214,8 @@ export interface components { }; }; "webhook-merge-group-checks-requested": { - action: string; + /** @enum {string} */ + action: "checks_requested"; installation?: components["schemas"]["simple-installation"]; /** MergeGroup */ merge_group: { @@ -38878,7 +39264,7 @@ export interface components { installation_command: string; manifest?: string; metadata: ({ - [key: string]: unknown | undefined; + [key: string]: unknown; })[]; name: string; npm_metadata?: ({ @@ -71475,7 +71861,7 @@ export interface components { installation_command: string; manifest?: string; metadata: ({ - [key: string]: unknown | undefined; + [key: string]: unknown; })[]; name: string; npm_metadata?: ({ @@ -72942,6 +73328,28 @@ export interface components { repository: components["schemas"]["repository"]; sender?: components["schemas"]["simple-user"]; }; + /** Repository advisory published event */ + "webhook-repository-advisory-published": { + /** @enum {string} */ + action: "published"; + enterprise?: components["schemas"]["enterprise"]; + installation?: components["schemas"]["simple-installation"]; + organization?: components["schemas"]["organization-simple"]; + repository: components["schemas"]["repository"]; + repository_advisory: components["schemas"]["repository-advisory"]; + sender?: components["schemas"]["simple-user"]; + }; + /** Repository advisory reported event */ + "webhook-repository-advisory-reported": { + /** @enum {string} */ + action: "reported"; + enterprise?: components["schemas"]["enterprise"]; + installation?: components["schemas"]["simple-installation"]; + organization?: components["schemas"]["organization-simple"]; + repository: components["schemas"]["repository"]; + repository_advisory: components["schemas"]["repository-advisory"]; + sender?: components["schemas"]["simple-user"]; + }; /** repository archived event */ "webhook-repository-archived": { /** @enum {string} */ @@ -72976,9 +73384,9 @@ export interface components { "webhook-repository-dispatch-sample": { action: string; branch: string; - client_payload: ({ - [key: string]: unknown | undefined; - }) | null; + client_payload: { + [key: string]: unknown; + } | null; enterprise?: components["schemas"]["enterprise"]; installation: components["schemas"]["simple-installation"]; organization?: components["schemas"]["organization-simple"]; @@ -74800,6 +75208,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -74813,6 +75226,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -75099,6 +75517,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -75112,6 +75535,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -75398,6 +75826,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -75411,6 +75844,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -75697,6 +76135,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -75710,6 +76153,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -75738,6 +76186,10 @@ export interface components { /** @description The previous version of the team's privacy if the action was `edited`. */ from: string; }; + notification_setting?: { + /** @description The previous version of the team's notification setting if the action was `edited`. */ + from: string; + }; repository?: { permissions: { from: { @@ -76023,6 +76475,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -76036,6 +76493,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -76322,6 +76784,11 @@ export interface components { permission: string; /** @enum {string} */ privacy: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url: string; slug: string; @@ -76335,6 +76802,11 @@ export interface components { permission?: string; /** @enum {string} */ privacy?: "open" | "closed" | "secret"; + /** + * @description Whether team members will receive notifications when their team is @mentioned + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** Format: uri */ repositories_url?: string; slug?: string; @@ -76358,9 +76830,9 @@ export interface components { /** workflow_dispatch event */ "webhook-workflow-dispatch": { enterprise?: components["schemas"]["enterprise"]; - inputs: ({ - [key: string]: unknown | undefined; - }) | null; + inputs: { + [key: string]: unknown; + } | null; installation?: components["schemas"]["simple-installation"]; organization?: components["schemas"]["organization-simple"]; ref: string; @@ -78930,6 +79402,8 @@ export interface components { "asset-id": number; /** @description The unique identifier of the release. */ "release-id": number; + /** @description The GHSA (GitHub Security Advisory) identifier of the advisory. */ + ghsa_id: string; /** @description The unique identifier of the tag protection. */ "tag-protection-id": number; /** @description The time frame to display results for. */ @@ -79028,7 +79502,7 @@ export interface operations { client_secret: string; webhook_secret: string | null; pem: string; - [key: string]: unknown | undefined; + [key: string]: unknown; }); }; }; @@ -79840,7 +80314,7 @@ export interface operations { }; requestBody: { content: { - "application/json": (({ + "application/json": ({ /** * @description The description of the gist. * @example Example Ruby script @@ -79859,14 +80333,14 @@ export interface operations { * } */ files?: { - [key: string]: ((({ + [key: string]: (({ /** @description The new content of the file. */ content?: string; /** @description The new filename for the file. */ filename?: string | null; - }) & (unknown | unknown | Record)) | null) | undefined; + }) | null) | undefined; }; - }) & (unknown | unknown)) | null; + }) | null; }; }; responses: { @@ -80557,9 +81031,9 @@ export interface operations { * Get GitHub meta information * @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/)." * - * **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. + * The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. * - * **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. + * **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. */ "meta/get": { responses: { @@ -85544,6 +86018,14 @@ export interface operations { * @enum {string} */ privacy?: "secret" | "closed"; + /** + * @description The notification setting the team has chosen: + * * `notifications_enabled` - team members receive notifications when the team is @mentioned + * * `notifications_disabled` - no one receives notifications + * Default: `notifications_enabled` + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** * @description **Deprecated**. The permission that new repositories will be added to the team with when none is specified. * @default pull @@ -85639,6 +86121,14 @@ export interface operations { * @enum {string} */ privacy?: "secret" | "closed"; + /** + * @description The notification setting the team has chosen. Editing teams without specifying this parameter leaves `notification_setting` intact. The options are: + * *`notifications_enabled` - team members receive notifications when the team is @mentioned + * * `notifications_disabled` - no one receives notifications + * Default: `notifications_enabled` + * @enum {string} + */ + notification_setting?: "notifications_enabled" | "notifications_disabled"; /** * @description **Deprecated**. The permission that new repositories will be added to the team with when none is specified. * @default pull @@ -89355,7 +89845,7 @@ export interface operations { ref: string; /** @description Input keys and values configured in the workflow file. The maximum number of properties is 10. Any default properties configured in the workflow file will be used when `inputs` are omitted. */ inputs?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -90764,11 +91254,11 @@ export interface operations { "application/json": OneOf<[{ /** @enum {unknown} */ status: "completed"; - [key: string]: unknown | undefined; + [key: string]: unknown; }, { /** @enum {unknown} */ status?: "queued" | "in_progress"; - [key: string]: unknown | undefined; + [key: string]: unknown; }]>; }; }; @@ -90856,7 +91346,7 @@ export interface operations { summary: string; /** @description Can contain Markdown. */ text?: string; - /** @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/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)". */ + /** @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/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/articles/about-status-checks#checks)". */ annotations?: ({ /** @description The path of the file to add an annotation to. For example, `assets/css/main.css`. */ path: string; @@ -90899,14 +91389,14 @@ export interface operations { /** @description A reference for the action on the integrator's system. The maximum size is 20 characters. */ identifier: string; })[]; - }) & (({ + }) & ({ /** @enum {unknown} */ status?: "completed"; - [key: string]: unknown | undefined; - }) | ({ + [key: string]: unknown; + } | ({ /** @enum {unknown} */ status?: "queued" | "in_progress"; - [key: string]: unknown | undefined; + [key: string]: unknown; })); }; }; @@ -91364,7 +91854,7 @@ export interface operations { content: { "application/json": components["schemas"]["code-scanning-analysis"]; "application/json+sarif": { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -93033,7 +93523,7 @@ export interface operations { "repos/get-content": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -93080,7 +93570,7 @@ export interface operations { content: string; /** @description **Required if you are updating a file**. The blob SHA of the file being replaced. */ sha?: string; - /** @description The branch name. Default: the repository’s default branch (usually `master`) */ + /** @description The branch name. Default: the repository’s default branch. */ branch?: string; /** @description The person that committed the file. Default: the authenticated user. */ committer?: { @@ -93149,7 +93639,7 @@ export interface operations { message: string; /** @description The blob SHA of the file being deleted. */ sha: string; - /** @description The branch name. Default: the repository’s default branch (usually `master`) */ + /** @description The branch name. Default: the repository’s default branch */ branch?: string; /** @description object containing information about the committer. */ committer?: { @@ -93566,6 +94056,31 @@ export interface operations { 404: components["responses"]["not_found"]; }; }; + /** + * Export a software bill of materials (SBOM) for a repository. + * @description Exports the software bill of materials (SBOM) for a repository in SPDX JSON format. + */ + "dependency-graph/export-sbom": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + responses: { + /** @description Response */ + 200: { + headers: { + Link: components["headers"]["link"]; + }; + content: { + "application/json": components["schemas"]["dependency-graph-spdx-sbom"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + }; + }; /** * Create a snapshot of dependencies 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. @@ -93708,7 +94223,7 @@ export interface operations { /** @description The [status](https://docs.github.com/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. */ required_contexts?: (string)[]; payload?: OneOf<[{ - [key: string]: unknown | undefined; + [key: string]: unknown; }, string]>; /** * @description Name for the target deployment environment (e.g., `production`, `staging`, `qa`). @@ -93940,7 +94455,7 @@ export interface operations { event_type: string; /** @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. */ client_payload?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; }; }; @@ -94268,6 +94783,8 @@ export interface operations { * @description Create a fork for the authenticated user. * * **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + * + * **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. */ "repos/create-fork": { parameters: { @@ -97265,7 +97782,7 @@ export interface operations { }; requestBody: { content: { - "application/json": ({ + "application/json": { /** @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/)." */ cname?: string | null; /** @description Specify whether HTTPS should be enforced for the repository. */ @@ -97284,7 +97801,7 @@ export interface operations { */ path: "/" | "/docs"; }); - }) & (unknown | unknown | unknown | unknown | unknown); + }; }; }; responses: { @@ -97310,7 +97827,7 @@ export interface operations { }; requestBody: { content: { - "application/json": (({ + "application/json": ({ /** * @description The process in which the Page will be built. Possible values are `"legacy"` and `"workflow"`. * @enum {string} @@ -97327,7 +97844,7 @@ export interface operations { */ path?: "/" | "/docs"; }; - }) & (unknown | unknown)) | null; + }) | null; }; }; responses: { @@ -98344,7 +98861,7 @@ export interface operations { reviewers?: (string)[]; /** @description An array of team `slug`s that will be requested. */ team_reviewers?: (string)[]; - } & (unknown | unknown); + }; }; }; responses: { @@ -98697,7 +99214,7 @@ export interface operations { "repos/get-readme": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -98725,7 +99242,7 @@ export interface operations { "repos/get-readme-in-directory": { parameters: { query: { - /** @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. */ ref?: string; }; path: { @@ -98794,7 +99311,7 @@ export interface operations { "application/json": { /** @description The name of the tag. */ tag_name: string; - /** @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`). */ + /** @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. */ target_commitish?: string; /** @description The name of the release. */ name?: string; @@ -99052,7 +99569,7 @@ export interface operations { "application/json": { /** @description The name of the tag. */ tag_name?: string; - /** @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`). */ + /** @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. */ target_commitish?: string; /** @description The name of the release. */ name?: string; @@ -99396,6 +99913,141 @@ export interface operations { 503: components["responses"]["service_unavailable"]; }; }; + /** + * List repository security advisories + * @description Lists security advisories in a repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + * + * You 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. + */ + "security-advisories/list-repository-advisories": { + parameters: { + query: { + direction?: components["parameters"]["direction"]; + /** @description The property to sort the results by. */ + sort?: "created" | "updated" | "published"; + before?: components["parameters"]["pagination-before"]; + after?: components["parameters"]["pagination-after"]; + /** @description Number of advisories to return per page. */ + per_page?: number; + /** @description Filter by state of the repository advisories. Only advisories of this state will be returned. */ + state?: "triage" | "draft" | "published" | "closed"; + }; + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": (components["schemas"]["repository-advisory"])[]; + }; + }; + 400: components["responses"]["bad_request"]; + 404: components["responses"]["not_found"]; + }; + }; + /** + * Create a repository security advisory + * @description Creates a new repository security advisory. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + */ + "security-advisories/create-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["repository-advisory-create"]; + }; + }; + responses: { + /** @description Response */ + 201: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + 422: components["responses"]["validation_failed"]; + }; + }; + /** + * Get a repository security advisory + * @description Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You can access any published security advisory on a public repository. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + * in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + * + * You 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 + * collaborator on the security advisory. + */ + "security-advisories/get-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + ghsa_id: components["parameters"]["ghsa_id"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + }; + }; + /** + * Update a repository security advisory + * @description Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + * You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + * + * In order to update any security advisory, you must be a security manager or administrator of that repository, + * or a collaborator on the repository security advisory. + */ + "security-advisories/update-repository-advisory": { + parameters: { + path: { + owner: components["parameters"]["owner"]; + repo: components["parameters"]["repo"]; + ghsa_id: components["parameters"]["ghsa_id"]; + }; + }; + requestBody: { + content: { + "application/json": components["schemas"]["repository-advisory-update"]; + }; + }; + responses: { + /** @description Response */ + 200: { + content: { + "application/json": components["schemas"]["repository-advisory"]; + }; + }; + 403: components["responses"]["forbidden"]; + 404: components["responses"]["not_found"]; + /** @description Validation failed, or the endpoint has been spammed. */ + 422: { + content: { + "application/json": components["schemas"]["validation-error"]; + }; + }; + }; + }; /** * List stargazers * @description Lists the people that have starred the repository. diff --git a/examples/github-api.yaml b/examples/github-api.yaml index 96ceb2291..2735d6516 100644 --- a/examples/github-api.yaml +++ b/examples/github-api.yaml @@ -2744,9 +2744,9 @@ paths: 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/)." - **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. + The values shown in the documentation's response are example values. You must always query the API directly to get the latest values. - **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. + **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. tags: - meta operationId: meta/get @@ -3224,7 +3224,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens post: summary: Review requests to access organization resources with fine-grained personal access tokens @@ -3295,7 +3295,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-token-requests/{pat_request_id}": post: summary: Review a request to access organization resources with a fine-grained @@ -3362,7 +3362,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-token-requests/{pat_request_id}/repositories": get: summary: List repositories requested to be accessed by a fine-grained personal @@ -3414,7 +3414,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens": get: summary: List fine-grained personal access tokens with access to organization @@ -3468,7 +3468,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens post: summary: Update the access to organization resources via fine-grained personal access tokens @@ -3533,7 +3533,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens/{pat_id}": post: summary: Update the access a fine-grained personal access token has to organization @@ -3587,7 +3587,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/organizations/{org}/personal-access-tokens/{pat_id}/repositories": get: summary: List repositories a fine-grained personal access token has access to @@ -3637,7 +3637,7 @@ paths: githubCloudOnly: false enabledForGitHubApps: true category: orgs - subcategory: orgs + subcategory: personal-access-tokens "/orgs/{org}": get: summary: Get an organization @@ -10411,6 +10411,15 @@ paths: enum: - secret - closed + notification_setting: + type: string + description: "The notification setting the team has chosen: \n * + `notifications_enabled` - team members receive notifications when + the team is @mentioned \n * `notifications_disabled` - no one + receives notifications \nDefault: `notifications_enabled`" + enum: + - notifications_enabled + - notifications_disabled permission: type: string description: "**Deprecated**. The permission that new repositories @@ -10430,6 +10439,7 @@ paths: name: Justice League description: A great team permission: push + notification_setting: notifications_enabled privacy: closed responses: '201': @@ -10524,6 +10534,16 @@ paths: enum: - secret - closed + notification_setting: + type: string + 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 \nDefault: `notifications_enabled`" + enum: + - notifications_enabled + - notifications_disabled permission: type: string description: "**Deprecated**. The permission that new repositories @@ -10543,6 +10563,7 @@ paths: name: new team name description: new team description privacy: closed + notification_setting: notifications_enabled responses: '200': description: Response when the updated information already exists @@ -18547,8 +18568,10 @@ paths: to make multiple requests to the [Update a check run](https://docs.github.com/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 how you can view annotations - on GitHub, see "[About status checks](https://docs.github.com/articles/about-status-checks#checks)". + for the check run. GitHub Actions are limited to 10 warning + annotations and 10 error annotations per step. For details + about how you can view annotations on GitHub, see "[About + status checks](https://docs.github.com/articles/about-status-checks#checks)". maxItems: 50 items: type: object @@ -18869,8 +18892,9 @@ paths: have to make multiple requests to the [Update a check run](https://docs.github.com/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)". + 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/articles/about-status-checks#checks)". maxItems: 50 items: type: object @@ -22159,7 +22183,7 @@ paths: x-multi-segment: true - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -22245,7 +22269,7 @@ paths: branch: type: string description: 'The branch name. Default: the repository’s default - branch (usually `master`)' + branch.' committer: type: object description: 'The person that committed the file. Default: the authenticated @@ -22379,7 +22403,7 @@ paths: branch: type: string description: 'The branch name. Default: the repository’s default - branch (usually `master`)' + branch' committer: type: object description: object containing information about the committer. @@ -22983,6 +23007,41 @@ paths: githubCloudOnly: false category: dependency-graph subcategory: dependency-review + "/repos/{owner}/{repo}/dependency-graph/sbom": + get: + summary: Export a software bill of materials (SBOM) for a repository. + description: Exports the software bill of materials (SBOM) for a repository + in SPDX JSON format. + tags: + - dependency-graph + operationId: dependency-graph/export-sbom + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/dependency-graph/sboms#export-a-software-bill-of-materials-sbom-for-a-repository + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/dependency-graph-spdx-sbom" + examples: + default: + "$ref": "#/components/examples/dependency-graph-export-sbom-response" + headers: + Link: + "$ref": "#/components/headers/link" + '404': + "$ref": "#/components/responses/not_found" + '403': + "$ref": "#/components/responses/forbidden" + x-github: + githubCloudOnly: false + category: dependency-graph + subcategory: sboms "/repos/{owner}/{repo}/dependency-graph/snapshots": post: summary: Create a snapshot of dependencies for a repository @@ -24052,6 +24111,8 @@ paths: Create a fork for the authenticated user. **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 Support](https://support.github.com/contact?tags=dotcom-rest-api). + + **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. tags: - repos operationId: repos/create-fork @@ -31283,7 +31344,7 @@ paths: - "$ref": "#/components/parameters/repo" - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -31332,7 +31393,7 @@ paths: x-multi-segment: true - name: ref description: 'The name of the commit/branch/tag. Default: the repository’s - default branch (usually `master`)' + default branch.' in: query required: false schema: @@ -31426,7 +31487,7 @@ paths: 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`).' + default branch.' name: type: string description: The name of the release. @@ -31818,7 +31879,7 @@ paths: 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`).' + default branch.' name: type: string description: The name of the release. @@ -32360,6 +32421,313 @@ paths: enabledForGitHubApps: true category: secret-scanning subcategory: + "/repos/{owner}/{repo}/security-advisories": + get: + summary: List repository security advisories + description: |- + Lists security advisories in a repository. + You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + in order to get published security advisories in a private repository, or any unpublished security advisories that you have access to. + + You 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. + tags: + - security-advisories + operationId: security-advisories/list-repository-advisories + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#list-repository-security-advisories + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/direction" + - name: sort + description: The property to sort the results by. + in: query + required: false + schema: + type: string + enum: + - created + - updated + - published + default: created + - "$ref": "#/components/parameters/pagination-before" + - "$ref": "#/components/parameters/pagination-after" + - name: per_page + description: Number of advisories to return per page. + in: query + required: false + schema: + type: integer + minimum: 1 + maximum: 100 + default: 30 + - name: state + description: Filter by state of the repository advisories. Only advisories + of this state will be returned. + in: query + required: false + schema: + type: string + enum: + - triage + - draft + - published + - closed + responses: + '200': + description: Response + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/list-repository-advisories" + '400': + "$ref": "#/components/responses/bad_request" + '404': + "$ref": "#/components/responses/not_found" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + post: + summary: Create a repository security advisory + description: |- + Creates a new repository security advisory. + You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + + In order to create a draft repository security advisory, you must be a security manager or administrator of that repository. + tags: + - security-advisories + operationId: security-advisories/create-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#create-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory-create" + examples: + default: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + severity: high + cve_id: + vulnerabilities: + - package: + name: a-package + ecosystem: npm + vulnerable_version_range: "< 1.0.0" + patched_versions: 1.0.0 + vulnerable_functions: + - important_function + cwe_ids: + - CWE-1101 + - CWE-20 + credits: + - login: monalisa + type: reporter + - login: octocat + type: analyst + withVectorString: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + cvss_vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L + cve_id: + vulnerabilities: + - package: + name: a-package + ecosystem: npm + vulnerable_version_range: "< 1.0.0" + patched_versions: 1.0.0 + vulnerable_functions: + - important_function + cwe_ids: + - CWE-1101 + - CWE-20 + credits: + - login: monalisa + type: reporter + - login: octocat + type: analyst + minimal: + value: + summary: A new important advisory + description: A more in-depth description of what the problem is. + vulnerabilities: + - package: + ecosystem: npm + responses: + '201': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + '422': + "$ref": "#/components/responses/validation_failed" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + "/repos/{owner}/{repo}/security-advisories/{ghsa_id}": + get: + summary: Get a repository security advisory + description: |- + Get a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + You can access any published security advisory on a public repository. + You must authenticate using an access token with the `repo` scope or `repository_advisories:read` permission + in order to get a published security advisory in a private repository, or any unpublished security advisory that you have access to. + + You 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 + collaborator on the security advisory. + tags: + - security-advisories + operationId: security-advisories/get-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#get-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/ghsa_id" + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories + patch: + summary: Update a repository security advisory + description: |- + Update a repository security advisory using its GitHub Security Advisory (GHSA) identifier. + You must authenticate using an access token with the `repo` scope or `repository_advisories:write` permission to use this endpoint. + + In order to update any security advisory, you must be a security manager or administrator of that repository, + or a collaborator on the repository security advisory. + tags: + - security-advisories + operationId: security-advisories/update-repository-advisory + externalDocs: + description: API method documentation + url: https://docs.github.com/rest/security-advisories/repository-advisories#update-a-repository-security-advisory + parameters: + - "$ref": "#/components/parameters/owner" + - "$ref": "#/components/parameters/repo" + - "$ref": "#/components/parameters/ghsa_id" + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory-update" + examples: + default: + summary: Updating the severity and state. + value: + severity: critical + state: published + add_credit: + summary: When adding a credit to an advisory, you must send the whole + array of values. + value: + credits: + - login: monauser + type: remediation_developer + update_vvrs: + summary: When adding vulnerable versions, you must include existing + vulnerable versions in the array. + value: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + invalid_state_transition: + summary: Some state transitions are invalid, such as changing the + state from `published` to `draft` + value: + state: draft + update_severity_with_cvss_set: + summary: Severity cannot be updated when the CVSS is already set. + value: + severity: low + responses: + '200': + description: Response + content: + application/json: + schema: + "$ref": "#/components/schemas/repository-advisory" + examples: + default: + "$ref": "#/components/examples/repository-advisory" + add_credit: + "$ref": "#/components/examples/repository-advisory" + '403': + "$ref": "#/components/responses/forbidden" + '404': + "$ref": "#/components/responses/not_found" + '422': + description: Validation failed, or the endpoint has been spammed. + content: + application/json: + schema: + "$ref": "#/components/schemas/validation-error" + examples: + invalid_state_transition: + value: + message: Invalid state transition from `published` to `draft`. + update_severity_with_cvss_set: + value: + message: Cannot update severity value when CVSS is set. + x-github: + githubCloudOnly: false + enabledForGitHubApps: true + category: security-advisories + subcategory: repository-advisories "/repos/{owner}/{repo}/stargazers": get: summary: List stargazers @@ -53670,16 +54038,16 @@ x-webhooks: - repository - organization - app - repository-archived: + repository-advisory-published: post: summary: |- - This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. + This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." - To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. - description: A repository was archived. - operationId: repository/archived + To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + description: A repository security advisory was published. + operationId: repository-advisory/published externalDocs: - url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository + url: https://docs.github.com/webhooks-and-events/webhooks/webhook-events-and-payloads#repository-advisory parameters: - name: User-Agent in: header @@ -53721,7 +54089,7 @@ x-webhooks: content: application/json: schema: - "$ref": "#/components/schemas/webhook-repository-archived" + "$ref": "#/components/schemas/webhook-repository-advisory-published" responses: '200': description: Return a 200 status to indicate that the data was received @@ -53729,20 +54097,148 @@ x-webhooks: x-github: githubCloudOnly: false category: webhooks - subcategory: repository + subcategory: repository-advisory supported-webhook-types: - - business - repository - organization - app - repository-created: + repository-advisory-reported: + post: + summary: |- + This event occurs when there is activity relating to a repository security advisory. For more information about repository security advisories, see "[About GitHub Security Advisories for repositories](https://docs.github.com/code-security/repository-security-advisories/about-github-security-advisories-for-repositories)." + + To subscribe to this event, a GitHub App must have at least read-level access for the "Repository security advisories" permission. + description: A private vulnerability report was submitted. + operationId: repository-advisory/reported + externalDocs: + url: https://docs.github.com/webhooks-and-events/webhooks/webhook-events-and-payloads#repository-advisory + parameters: + - name: User-Agent + in: header + example: GitHub-Hookshot/123abc + schema: + type: string + - name: X-Github-Hook-Id + in: header + example: 12312312 + schema: + type: string + - name: X-Github-Event + in: header + example: issues + schema: + type: string + - name: X-Github-Hook-Installation-Target-Id + in: header + example: 123123 + schema: + type: string + - name: X-Github-Hook-Installation-Target-Type + in: header + example: repository + schema: + type: string + - name: X-GitHub-Delivery + in: header + example: 0b989ba4-242f-11e5-81e1-c7b6966d2516 + schema: + type: string + - name: X-Hub-Signature-256 + in: header + example: sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/webhook-repository-advisory-reported" + responses: + '200': + description: Return a 200 status to indicate that the data was received + successfully + x-github: + githubCloudOnly: false + category: webhooks + subcategory: repository-advisory + supported-webhook-types: + - repository + - organization + - app + repository-archived: post: summary: |- This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. - description: A repository was created. - operationId: repository/created + description: A repository was archived. + operationId: repository/archived + externalDocs: + url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository + parameters: + - name: User-Agent + in: header + example: GitHub-Hookshot/123abc + schema: + type: string + - name: X-Github-Hook-Id + in: header + example: 12312312 + schema: + type: string + - name: X-Github-Event + in: header + example: issues + schema: + type: string + - name: X-Github-Hook-Installation-Target-Id + in: header + example: 123123 + schema: + type: string + - name: X-Github-Hook-Installation-Target-Type + in: header + example: repository + schema: + type: string + - name: X-GitHub-Delivery + in: header + example: 0b989ba4-242f-11e5-81e1-c7b6966d2516 + schema: + type: string + - name: X-Hub-Signature-256 + in: header + example: sha256=6dcb09b5b57875f334f61aebed695e2e4193db5e + schema: + type: string + requestBody: + required: true + content: + application/json: + schema: + "$ref": "#/components/schemas/webhook-repository-archived" + responses: + '200': + description: Return a 200 status to indicate that the data was received + successfully + x-github: + githubCloudOnly: false + category: webhooks + subcategory: repository + supported-webhook-types: + - business + - repository + - organization + - app + repository-created: + post: + summary: |- + This event occurs when there is activity relating to repositories. For more information, see "[About repositories](https://docs.github.com/repositories/creating-and-managing-repositories/about-repositories)." For information about the APIs to manage repositories, see [the GraphQL documentation](https://docs.github.com/graphql/reference/objects#repository) or "[Repositories](https://docs.github.com/rest/repos)" in the REST API documentation. + + To subscribe to this event, a GitHub App must have at least read-level access for the "Metadata" repository permission. + description: A repository was created. + operationId: repository/created externalDocs: url: https://docs.github.com/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#repository parameters: @@ -57694,13 +58190,6 @@ components: enum: - read - write - repository_announcement_banners: - type: string - description: The level of permission to grant the access token to view and - manage announcement banners for a repository. - enum: - - read - - write repository_hooks: type: string description: The level of permission to grant the access token to manage @@ -61156,67 +61645,61 @@ components: items: type: string example: - - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl + - ssh-ed25519 ABCDEFGHIJKLMNOPQRSTUVWXYZ hooks: type: array items: type: string example: - - 127.0.0.1/32 + - 192.0.2.1 web: type: array items: type: string example: - - 127.0.0.1/32 + - 192.0.2.1 api: type: array items: type: string example: - - 127.0.0.1/32 + - 192.0.2.1 git: type: array items: type: string example: - - 127.0.0.1/32 + - 192.0.2.1 packages: type: array items: type: string example: - - 13.65.0.0/16 - - 157.55.204.33/32 - - 2a01:111:f403:f90c::/62 + - 192.0.2.1 pages: type: array items: type: string example: - - 192.30.252.153/32 - - 192.30.252.154/32 + - 192.0.2.1 importer: type: array items: type: string example: - - 54.158.161.132 - - 54.226.70.38 + - 192.0.2.1 actions: type: array items: type: string example: - - 13.64.0.0/16 - - 13.65.0.0/16 + - 192.0.2.1 dependabot: type: array items: type: string example: - - 192.168.7.15/32 - - 192.168.7.16/32 + - 192.0.2.1 required: - verifiable_password_authentication security-and-analysis: @@ -63731,6 +64214,10 @@ components: description: The level of privacy this team should have type: string example: closed + notification_setting: + description: The notification setting the team has set + type: string + example: notifications_enabled html_url: type: string format: uri @@ -63777,6 +64264,8 @@ components: nullable: true privacy: type: string + notification_setting: + type: string permission: type: string permissions: @@ -64151,6 +64640,10 @@ components: description: The level of privacy this team should have type: string example: closed + notification_setting: + description: The notification setting the team has set + type: string + example: notifications_enabled html_url: type: string format: uri @@ -64518,6 +65011,13 @@ components: - closed - secret example: closed + notification_setting: + description: The notification setting the team has set + type: string + enum: + - notifications_enabled + - notifications_disabled + example: notifications_enabled permission: description: Permission that the team will have for its repositories example: push @@ -68002,6 +68502,8 @@ components: nullable: true privacy: type: string + notification_setting: + type: string permission: type: string members_url: @@ -71251,6 +71753,148 @@ components: - source_repository_url - vulnerabilities - scope + dependency-graph-spdx-sbom: + title: Dependency Graph SPDX SBOM + description: A schema for the SPDX JSON format returned by the Dependency Graph. + type: object + properties: + sbom: + type: object + properties: + SPDXID: + type: string + example: SPDXRef-DOCUMENT + description: The SPDX identifier for the SPDX document. + spdxVersion: + type: string + example: SPDX-2.3 + description: The version of the SPDX specification that this document + conforms to. + creationInfo: + type: object + properties: + created: + type: string + example: '2021-11-03T00:00:00Z' + description: The date and time the SPDX document was created. + creators: + type: array + items: + type: string + example: GitHub + description: The tools that were used to generate the SPDX document. + required: + - created + - creators + name: + type: string + example: github/github + description: The name of the SPDX document. + dataLicense: + type: string + example: CC0-1.0 + description: The license under which the SPDX document is licensed. + documentDescribes: + type: array + items: + type: string + example: github/github + description: The name of the repository that the SPDX document describes. + documentNamespace: + type: string + example: https://github.com/example/dependency_graph/sbom-123 + description: The namespace for the SPDX document. + packages: + type: array + items: + type: object + properties: + SPDXID: + type: string + example: SPDXRef-Package + description: A unique SPDX identifier for the package. + name: + type: string + example: rubygems:github/github + description: The name of the package. + versionInfo: + type: string + example: 1.0.0 + description: |- + The version of the package. If the package does not have an exact version specified, + a version range is given. + downloadLocation: + type: string + example: NOASSERTION + description: |- + The location where the package can be downloaded, + or NOASSERTION if this has not been determined. + filesAnalyzed: + type: boolean + example: false + description: |- + Whether the package's file content has been subjected to + analysis during the creation of the SPDX document. + licenseConcluded: + type: string + example: MIT + description: The license of the package as determined while creating + the SPDX document. + licenseDeclared: + type: string + example: NOASSERTION + description: |- + The license of the package as declared by its author, or NOASSERTION if this information + was not available when the SPDX document was created. + supplier: + type: string + example: NOASSERTION + description: The distribution source of this package, or NOASSERTION + if this was not determined. + externalRefs: + type: array + items: + type: object + properties: + referenceCategory: + type: string + example: PACKAGE-MANAGER + description: The category of reference to an external resource + this reference refers to. + referenceLocator: + type: string + example: pkg:gem/rails@6.0.1 + description: A locator for the particular external resource + this reference refers to. + referenceType: + type: string + example: purl + description: The category of reference to an external resource + this reference refers to. + required: + - referenceCategory + - referenceLocator + - referenceType + required: + - SPDXID + - name + - versionInfo + - downloadLocation + - filesAnalyzed + - licenseConcluded + - licenseDeclared + - supplier + required: + - SPDXID + - spdxVersion + - creationInfo + - name + - dataLicense + - documentDescribes + - documentNamespace + - packages + required: + - sbom metadata: title: metadata description: User-defined metadata to store domain-specific information limited @@ -73832,8 +74476,6 @@ components: - pull_request_review_id - diff_hunk - path - - position - - original_position - commit_id - original_commit_id - user @@ -76326,6 +76968,498 @@ components: required: - type - details + repository-advisory-ecosystems: + type: string + description: The package's language or package management ecosystem. + enum: + - rubygems + - npm + - pip + - maven + - nuget + - composer + - go + - rust + - erlang + - actions + - pub + - other + repository-advisory-vulnerability: + description: A product affected by the vulnerability detailed in a repository + security advisory. + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: object + nullable: true + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: string + description: The unique package name within its ecosystem. + nullable: true + required: + - ecosystem + - name + vulnerable_version_range: + type: string + description: The range of the package versions affected by the vulnerability. + nullable: true + patched_versions: + type: string + description: The package version(s) that resolve the vulnerability. + nullable: true + vulnerable_functions: + type: array + description: The functions in the package that are affected. + nullable: true + items: + type: string + required: + - package + - vulnerable_version_range + - patched_versions + - vulnerable_functions + additionalProperties: false + repository-advisory-credit-types: + type: string + description: The type of credit the user is receiving. + enum: + - analyst + - finder + - reporter + - coordinator + - remediation_developer + - remediation_reviewer + - remediation_verifier + - tool + - sponsor + - other + repository-advisory-credit: + description: A credit given to a user for a repository security advisory. + type: object + properties: + user: + "$ref": "#/components/schemas/simple-user" + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + state: + type: string + description: The state of the user's acceptance of the credit. + enum: + - accepted + - declined + - pending + required: + - user + - type + - state + additionalProperties: false + repository-advisory: + description: A repository security advisory. + type: object + properties: + ghsa_id: + type: string + description: The GitHub Security Advisory ID. + readOnly: true + cve_id: + type: string + description: The Common Vulnerabilities and Exposures (CVE) ID. + nullable: true + url: + type: string + description: The API URL for the advisory. + html_url: + type: string + format: uri + description: The URL for the advisory. + readOnly: true + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: string + description: A detailed description of what the advisory entails. + maxLength: 65535 + nullable: true + severity: + type: string + description: The severity of the advisory. + nullable: true + enum: + - critical + - high + - medium + - low + author: + readOnly: true + nullable: true + description: The author of the advisory. + allOf: + - "$ref": "#/components/schemas/simple-user" + publisher: + readOnly: true + nullable: true + description: The publisher of the advisory. + allOf: + - "$ref": "#/components/schemas/simple-user" + identifiers: + type: array + items: + type: object + properties: + type: + type: string + description: The type of identifier. + enum: + - CVE + - GHSA + value: + type: string + description: The identifier value. + required: + - type + - value + readOnly: true + state: + type: string + description: The state of the advisory. + enum: + - published + - closed + - withdrawn + - draft + - triage + created_at: + type: string + format: date-time + description: The date and time of when the advisory was created, in ISO + 8601 format. + readOnly: true + nullable: true + updated_at: + type: string + format: date-time + description: The date and time of when the advisory was last updated, in + ISO 8601 format. + readOnly: true + nullable: true + published_at: + type: string + format: date-time + description: The date and time of when the advisory was published, in ISO + 8601 format. + readOnly: true + nullable: true + closed_at: + type: string + format: date-time + description: The date and time of when the advisory was closed, in ISO 8601 + format. + readOnly: true + nullable: true + withdrawn_at: + type: string + format: date-time + description: The date and time of when the advisory was withdrawn, in ISO + 8601 format. + readOnly: true + nullable: true + submission: + type: object + nullable: true + readOnly: true + properties: + accepted: + type: boolean + description: Whether a private vulnerability report was accepted by + the repository's administrators. + readOnly: true + required: + - accepted + vulnerabilities: + type: array + nullable: true + items: + "$ref": "#/components/schemas/repository-advisory-vulnerability" + cvss: + type: object + nullable: true + properties: + vector_string: + type: string + description: The CVSS vector. + nullable: true + score: + type: number + description: The CVSS score. + minimum: 0 + maximum: 10 + nullable: true + readOnly: true + required: + - vector_string + - score + cwes: + type: array + nullable: true + items: + type: object + properties: + cwe_id: + type: string + description: The Common Weakness Enumeration (CWE) identifier. + name: + type: string + description: The name of the CWE. + readOnly: true + required: + - cwe_id + - name + readOnly: true + cwe_ids: + type: array + description: A list of only the CWE IDs. + nullable: true + items: + type: string + credits: + type: array + nullable: true + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + credits_detailed: + type: array + nullable: true + items: + "$ref": "#/components/schemas/repository-advisory-credit" + readOnly: true + required: + - ghsa_id + - cve_id + - url + - html_url + - summary + - description + - severity + - author + - publisher + - identifiers + - state + - created_at + - updated_at + - published_at + - closed_at + - withdrawn_at + - submission + - vulnerabilities + - cvss + - cwes + - cwe_ids + - credits + - credits_detailed + additionalProperties: false + repository-advisory-create: + type: object + properties: + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: string + description: A detailed description of what the advisory impacts. + maxLength: 65535 + cve_id: + type: string + description: The Common Vulnerabilities and Exposures (CVE) ID. + nullable: true + vulnerabilities: + type: array + description: A product affected by the vulnerability detailed in a repository + security advisory. + items: + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: object + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: string + description: The unique package name within its ecosystem. + nullable: true + required: + - ecosystem + vulnerable_version_range: + type: string + description: The range of the package versions affected by the vulnerability. + nullable: true + patched_versions: + type: string + description: The package version(s) that resolve the vulnerability. + nullable: true + vulnerable_functions: + type: array + description: The functions in the package that are affected. + nullable: true + items: + type: string + required: + - package + additionalProperties: false + cwe_ids: + type: array + description: A list of Common Weakness Enumeration (CWE) IDs. + nullable: true + items: + type: string + credits: + type: array + description: A list of users receiving credit for their participation in + the security advisory. + nullable: true + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + required: + - login + - type + additionalProperties: false + severity: + type: string + description: The severity of the advisory. You must choose between setting + this field or `cvss_vector_string`. + nullable: true + enum: + - critical + - high + - medium + - low + cvss_vector_string: + type: string + description: The CVSS vector that calculates the severity of the advisory. + You must choose between setting this field or `severity`. + nullable: true + required: + - summary + - description + - vulnerabilities + additionalProperties: false + repository-advisory-update: + type: object + properties: + summary: + type: string + description: A short summary of the advisory. + maxLength: 1024 + description: + type: string + description: A detailed description of what the advisory impacts. + maxLength: 65535 + cve_id: + type: string + description: The Common Vulnerabilities and Exposures (CVE) ID. + nullable: true + vulnerabilities: + type: array + description: A product affected by the vulnerability detailed in a repository + security advisory. + items: + type: object + properties: + package: + description: The name of the package affected by the vulnerability. + type: object + properties: + ecosystem: + "$ref": "#/components/schemas/repository-advisory-ecosystems" + name: + type: string + description: The unique package name within its ecosystem. + nullable: true + required: + - ecosystem + vulnerable_version_range: + type: string + description: The range of the package versions affected by the vulnerability. + nullable: true + patched_versions: + type: string + description: The package version(s) that resolve the vulnerability. + nullable: true + vulnerable_functions: + type: array + description: The functions in the package that are affected. + nullable: true + items: + type: string + required: + - package + additionalProperties: false + cwe_ids: + type: array + description: A list of Common Weakness Enumeration (CWE) IDs. + nullable: true + items: + type: string + credits: + type: array + description: A list of users receiving credit for their participation in + the security advisory. + nullable: true + items: + type: object + properties: + login: + type: string + description: The username of the user credited. + type: + "$ref": "#/components/schemas/repository-advisory-credit-types" + required: + - login + - type + additionalProperties: false + severity: + type: string + description: The severity of the advisory. You must choose between setting + this field or `cvss_vector_string`. + nullable: true + enum: + - critical + - high + - medium + - low + cvss_vector_string: + type: string + description: The CVSS vector that calculates the severity of the advisory. + You must choose between setting this field or `severity`. + nullable: true + state: + type: string + description: The state of the advisory. + enum: + - published + - closed + - draft + additionalProperties: false stargazer: title: Stargazer description: Stargazer @@ -114214,6 +115348,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -114230,6 +115371,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -114244,6 +115386,11 @@ components: - open - closed - secret + notification_setting: + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -114476,6 +115623,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -114492,6 +115646,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -114506,6 +115661,11 @@ components: - open - closed - secret + notification_setting: + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -114530,6 +115690,8 @@ components: properties: action: type: string + enum: + - checks_requested installation: "$ref": "#/components/schemas/simple-installation" merge_group: @@ -182406,6 +183568,54 @@ components: - action - release - repository + webhook-repository-advisory-published: + title: Repository advisory published event + type: object + properties: + action: + type: string + enum: + - published + enterprise: + "$ref": "#/components/schemas/enterprise" + installation: + "$ref": "#/components/schemas/simple-installation" + organization: + "$ref": "#/components/schemas/organization-simple" + repository: + "$ref": "#/components/schemas/repository" + repository_advisory: + "$ref": "#/components/schemas/repository-advisory" + sender: + "$ref": "#/components/schemas/simple-user" + required: + - action + - repository + - repository_advisory + webhook-repository-advisory-reported: + title: Repository advisory reported event + type: object + properties: + action: + type: string + enum: + - reported + enterprise: + "$ref": "#/components/schemas/enterprise" + installation: + "$ref": "#/components/schemas/simple-installation" + organization: + "$ref": "#/components/schemas/organization-simple" + repository: + "$ref": "#/components/schemas/repository" + repository_advisory: + "$ref": "#/components/schemas/repository-advisory" + sender: + "$ref": "#/components/schemas/simple-user" + required: + - action + - repository + - repository_advisory webhook-repository-archived: title: repository archived event type: object @@ -186345,6 +187555,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -186361,6 +187578,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -186375,6 +187593,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -186911,6 +188136,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -186927,6 +188159,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -186941,6 +188174,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -187477,6 +188717,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -187493,6 +188740,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -187507,6 +188755,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -188044,6 +189299,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -188060,6 +189322,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -188074,6 +189337,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -188129,6 +189399,15 @@ components: type: string required: - from + notification_setting: + type: object + properties: + from: + description: The previous version of the team's notification setting + if the action was `edited`. + type: string + required: + - from repository: type: object properties: @@ -188666,6 +189945,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -188682,6 +189968,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -188696,6 +189983,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -189234,6 +190528,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when + their team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -189250,6 +190551,7 @@ components: - slug - description - privacy + - notification_setting - url - html_url - members_url @@ -189264,6 +190566,13 @@ components: - open - closed - secret + notification_setting: + description: Whether team members will receive notifications when their + team is @mentioned + type: string + enum: + - notifications_enabled + - notifications_disabled repositories_url: type: string format: uri @@ -198133,75 +199442,32 @@ components: value: verifiable_password_authentication: true ssh_key_fingerprints: - SHA256_RSA: uNiVztksCsDhcc0u9e8BujQXVUpKZIDTMczCvj3tD2s - SHA256_DSA: br9IjFspm1vxR3iA35FWE+4VTyz1hYVLIE2t1/CeyWQ - SHA256_ECDSA: p2QAMXNIC1TJYWeIOttrVc98/R1BUFWu3/LiyKgUfQM - SHA256_ED25519: "+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU" + SHA256_RSA: 1234567890 + SHA256_DSA: 1234567890 + SHA256_ECDSA: 1234567890 + SHA256_ED25519: 1234567890 ssh_keys: - - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl - - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBEmKSENjQEezOmxkZMy7opKgwFB9nkt5YRrYMjNuG5N87uRgg6CLrbo5wAdT/y6v0mKV0U2w0WZ2YB/++Tpockg= - - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCj7ndNxQowgcQnjshcLrqPEiiphnt+VTTvDP6mHBL9j1aNUkY4Ue1gvwnGLVlOhGeYrnZaMgRK6+PKCUXaDbC7qtbW8gIkhL7aGCsOr/C56SJMy/BCZfxd1nWzAOxSDPgVsmerOBYfNqltV9/hWCqBywINIR+5dIg6JTJ72pcEpEjcYgXkE2YEFXV1JHnsKgbLWNlhScqb2UmyRkQyytRLtL+38TGxkxCflmO+5Z8CSSNY7GidjMIZ7Q4zMjA2n1nGrlTDkzwDCsw+wqFPGQA179cnfGWOWRVruj16z6XyvxvjJwbz0wQZ75XK5tKSb7FNyeIEs4TT4jk+S4dhPeAUC5y+bDYirYgM4GC7uEnztnZyaVWQ7B381AK4Qdrwt51ZqExKbQpTUNn+EjqoTwvqNj4kqx5QUCI0ThS/YkOxJCXmPUWZbhjpCg56i+2aB6CmK2JGhn57K5mj0MNdBXA4/WnwH6XoPWJzK5Nyu2zB3nAZp+S5hpQs+p1vN1/wsjk= + - ssh-ed25519 ABCDEFGHIJKLMNOPQRSTUVWXYZ + - ecdsa-sha2-nistp256 ABCDEFGHIJKLMNOPQRSTUVWXYZ + - ssh-rsa ABCDEFGHIJKLMNOPQRSTUVWXYZ hooks: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 + - 192.0.2.1 web: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 - - 20.201.28.151/32 - - 20.205.243.166/32 - - 102.133.202.242/32 + - 192.0.2.1 api: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 - - 20.201.28.148/32 + - 192.0.2.1 git: - - 192.30.252.0/22 - - 185.199.108.0/22 - - 140.82.112.0/20 - - 143.55.64.0/20 - - 2a0a:a440::/29 - - 2606:50c0::/32 + - 192.0.2.1 packages: - - 140.82.121.33/32 - - 192.30.255.164/31 - - 20.200.245.241/32 - - 20.233.54.55/32 + - 192.0.2.1 pages: - - 192.30.252.153/32 - - 192.30.252.154/32 - - 185.199.108.153/32 - - 185.199.109.153/32 - - 185.199.110.153/32 - - 185.199.111.153/32 - - 2606:50c0:8000::153/128 - - 2606:50c0:8001::153/128 - - 2606:50c0:8002::153/128 - - 2606:50c0:8003::153/128 + - 192.0.2.1 importer: - - 52.23.85.212/32 - - 52.0.228.224/32 - - 52.22.155.48/32 + - 192.0.2.1 actions: - - 4.148.0.0/16 - - 13.67.153.64/26 - - 2603:1030:804:220::/61 - - 2603:1036:2500:10::/64 + - 192.0.2.1 dependabot: - - 18.213.123.130/32 - - 3.217.79.163/32 - - 3.217.93.44/32 + - 192.0.2.1 public-repo-events-items: value: - id: '22249084964' @@ -200368,6 +201634,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -201283,6 +202550,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -201994,6 +203262,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -204108,6 +205377,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -204386,6 +205656,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -204458,6 +205729,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -204597,6 +205869,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -204681,6 +205954,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -206993,6 +208267,7 @@ components: description: A great team. privacy: closed permission: admin + notification_setting: notifications_enabled members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos parent: @@ -208583,6 +209858,28 @@ components: advisory_ghsa_id: GHSA-fqfj-cmh6-hj49 advisory_summary: Ruby OpenID advisory_url: https://github.com/advisories/GHSA-fqfj-cmh6-hj49 + dependency-graph-export-sbom-response: + value: + sbom: + SPDXID: SPDXRef-DOCUMENT + spdxVersion: SPDX-2.3 + creationInfo: + created: '2021-09-01T00:00:00Z' + creators: + - 'Tool: GitHub.com-Dependency-Graph' + name: github/example + dataLicense: CC0-1.0 + documentDescribes: + - github/example + documentNamespace: https://github.com/github/example/dependency_graph/sbom-abcdef123456 + packages: + - SPDXID: SPDXRef-Package + name: rubygems:rails + versionInfo: 1.0.0 + downloadLocation: NOASSERTION + filesAnalyzed: false + licenseConcluded: NOASSERTION + licenseDeclared: NOASSERTION dependency-graph-create-snapshot-request: value: version: 0 @@ -208811,6 +210108,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -208869,6 +210167,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -211038,6 +212337,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -211611,6 +212911,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -211822,6 +213123,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -212299,6 +213601,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -213231,6 +214534,326 @@ components: - type: issue_comment details: issue_comment_url: https://api.github.com/repos/octocat/Hello-World/issues/comments/1081119451 + list-repository-advisories: + value: + - ghsa_id: GHSA-abcd-1234-efgh + cve_id: CVE-2050-00000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-abcd-1234-efgh + html_url: https://github.com/repo/a-package/security/advisories/GHSA-abcd-1234-efgh + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: critical + author: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + publisher: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-abcd-1234-efgh + - type: CVE + value: CVE-2050-00000 + state: published + created_at: '2020-01-01T00:00:00Z' + updated_at: '2020-01-02T00:00:00Z' + published_at: '2020-01-03T00:00:00Z' + closed_at: + withdrawn_at: + submission: + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H + score: 9.8 + cwes: + - cwe_id: CWE-123 + name: A CWE + cwe_ids: + - CWE-123 + credits: + - login: octocat + type: analyst + credits_detailed: + - user: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + type: analyst + state: accepted + - ghsa_id: GHSA-1234-5678-9012 + cve_id: CVE-2051-0000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-1234-5678-9012 + html_url: https://github.com/repo/a-package/security/advisories/GHSA-1234-5678-9012 + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: low + author: + login: monauser + id: 2 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monauser + html_url: https://github.com/monauser + followers_url: https://api.github.com/users/monauser/followers + following_url: https://api.github.com/users/monauser/following{/other_user} + gists_url: https://api.github.com/users/monauser/gists{/gist_id} + starred_url: https://api.github.com/users/monauser/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monauser/subscriptions + organizations_url: https://api.github.com/users/monauser/orgs + repos_url: https://api.github.com/users/monauser/repos + events_url: https://api.github.com/users/monauser/events{/privacy} + received_events_url: https://api.github.com/users/monauser/received_events + type: User + site_admin: false + publisher: + login: monalisa + id: 3 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monalisa + html_url: https://github.com/monalisa + followers_url: https://api.github.com/users/monalisa/followers + following_url: https://api.github.com/users/monalisa/following{/other_user} + gists_url: https://api.github.com/users/monalisa/gists{/gist_id} + starred_url: https://api.github.com/users/monalisa/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monalisa/subscriptions + organizations_url: https://api.github.com/users/monalisa/orgs + repos_url: https://api.github.com/users/monalisa/repos + events_url: https://api.github.com/users/monalisa/events{/privacy} + received_events_url: https://api.github.com/users/monalisa/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-1234-5678-9012 + - type: CVE + value: CVE-2051-00000 + state: published + created_at: '2020-01-03T00:00:00Z' + updated_at: '2020-01-04T00:00:00Z' + published_at: '2020-01-04T00:00:00Z' + closed_at: + withdrawn_at: + submission: + - accepted: true + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: AV:P/AC:H/PR:H/UI:R/S:U/C:N/I:L/A:N + score: 1.6 + cwes: + - cwe_id: CWE-456 + name: A CWE 2.0 + cwe_ids: + - CWE-456 + credits: + - login: monauser + type: reporter + credits_detailed: + - user: + login: monauser + id: 2 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/monauser + html_url: https://github.com/monauser + followers_url: https://api.github.com/users/monauser/followers + following_url: https://api.github.com/users/monauser/following{/other_user} + gists_url: https://api.github.com/users/monauser/gists{/gist_id} + starred_url: https://api.github.com/users/monauser/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/monauser/subscriptions + organizations_url: https://api.github.com/users/monauser/orgs + repos_url: https://api.github.com/users/monauser/repos + events_url: https://api.github.com/users/monauser/events{/privacy} + received_events_url: https://api.github.com/users/monauser/received_events + type: User + site_admin: false + type: reporter + state: accepted + repository-advisory: + value: + ghsa_id: GHSA-abcd-1234-efgh + cve_id: CVE-2050-00000 + url: https://api.github.com/repos/repo/a-package/security-advisories/GHSA-abcd-1234-efgh + html_url: https://github.com/repo/a-package/security/advisories/GHSA-abcd-1234-efgh + summary: A short summary of the advisory. + description: A detailed description of what the advisory entails. + severity: critical + author: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + publisher: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + identifiers: + - type: GHSA + value: GHSA-abcd-1234-efgh + - type: CVE + value: CVE-2050-00000 + state: published + created_at: '2020-01-01T00:00:00Z' + updated_at: '2020-01-02T00:00:00Z' + published_at: '2020-01-03T00:00:00Z' + closed_at: + withdrawn_at: + submission: + vulnerabilities: + - package: + ecosystem: pip + name: a-package + vulnerable_version_range: ">= 1.0.0, < 1.0.1" + patched_versions: 1.0.1 + vulnerable_functions: + - function1 + - package: + ecosystem: pip + name: another-package + vulnerable_version_range: ">= 1.0.0, < 1.0.2" + patched_versions: 1.0.2 + vulnerable_functions: + - function2 + cvss: + vector_string: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H + score: 9.8 + cwes: + - cwe_id: CWE-123 + name: A CWE + cwe_ids: + - CWE-123 + credits: + - login: octocat + type: analyst + credits_detailed: + - user: + login: octocat + id: 1 + node_id: MDQ6VXNlcjE= + avatar_url: https://github.com/images/error/octocat_happy.gif + gravatar_id: '' + url: https://api.github.com/users/octocat + html_url: https://github.com/octocat + followers_url: https://api.github.com/users/octocat/followers + following_url: https://api.github.com/users/octocat/following{/other_user} + gists_url: https://api.github.com/users/octocat/gists{/gist_id} + starred_url: https://api.github.com/users/octocat/starred{/owner}{/repo} + subscriptions_url: https://api.github.com/users/octocat/subscriptions + organizations_url: https://api.github.com/users/octocat/orgs + repos_url: https://api.github.com/users/octocat/repos + events_url: https://api.github.com/users/octocat/events{/privacy} + received_events_url: https://api.github.com/users/octocat/received_events + type: User + site_admin: false + type: analyst + state: accepted simple-user-items-default-response: summary: Default response value: @@ -217110,6 +218733,7 @@ components: slug: justice-league description: A great team. privacy: closed + notification_setting: notifications_enabled permission: admin members_url: https://api.github.com/teams/1/members{/member} repositories_url: https://api.github.com/teams/1/repos @@ -220235,6 +221859,13 @@ components: required: true schema: type: integer + ghsa_id: + name: ghsa_id + description: The GHSA (GitHub Security Advisory) identifier of the advisory. + in: path + required: true + schema: + type: string tag-protection-id: name: tag_protection_id description: The unique identifier of the tag protection. diff --git a/examples/octokit-ghes-3.6-diff-to-api.ts b/examples/octokit-ghes-3.6-diff-to-api.ts index 637ea8803..14b548793 100644 --- a/examples/octokit-ghes-3.6-diff-to-api.ts +++ b/examples/octokit-ghes-3.6-diff-to-api.ts @@ -1955,7 +1955,7 @@ export interface components { country_name?: string; }; data?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; org_id?: number; /** @description The username of the account being blocked. */ @@ -6352,11 +6352,11 @@ export interface operations { script: string; /** @description The GitHub repository where the script is kept. */ script_repository: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; /** @description The pre-receive environment where the script is executed. */ environment: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; /** @description The state of enforcement for this hook. default: `disabled` */ enforcement?: string; @@ -6418,11 +6418,11 @@ export interface operations { script?: string; /** @description The GitHub repository where the script is kept. */ script_repository?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; /** @description The pre-receive environment where the script is executed. */ environment?: { - [key: string]: unknown | undefined; + [key: string]: unknown; }; /** @description The state of enforcement for this hook. */ enforcement?: string; diff --git a/examples/stripe-api.ts b/examples/stripe-api.ts index 49d9846cc..e42f1c2fc 100644 --- a/examples/stripe-api.ts +++ b/examples/stripe-api.ts @@ -3140,7 +3140,7 @@ export interface components { address_zip_check?: string | null; /** @description A set of available payout methods for this card. Only values from this set should be passed as the `method` when creating a payout. */ available_payout_methods?: (("instant" | "standard")[]) | null; - /** @description Card brand. Can be `American Express`, `Diners Club`, `Discover`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`. */ + /** @description Card brand. Can be `American Express`, `Diners Club`, `Discover`, `Eftpos Australia`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`. */ brand: string; /** @description Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected. */ country?: string | null; @@ -4254,7 +4254,7 @@ export interface components { /** @description When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links. */ custom_unit_amount?: components["schemas"]["custom_unit_amount"] | null; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string|null} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified" | null; @@ -6835,7 +6835,7 @@ export interface components { */ status: "active" | "blocked" | "inactive"; /** - * @description One of `individual` or `company`. + * @description One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details. * @enum {string} */ type: "company" | "individual"; @@ -9054,7 +9054,7 @@ export interface components { }; /** payment_method_card */ payment_method_card: { - /** @description Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ brand: string; /** @description Checks on Card address and CVC if provided. */ checks?: components["schemas"]["payment_method_card_checks"] | null; @@ -9113,10 +9113,10 @@ export interface components { masterpass?: components["schemas"]["payment_method_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_card_wallet_samsung_pay"]; /** - * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. * @enum {string} */ - type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; + type: "amex_express_checkout" | "apple_pay" | "google_pay" | "link" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_card_wallet_visa_checkout"]; }; /** payment_method_card_wallet_amex_express_checkout */ @@ -9306,7 +9306,7 @@ export interface components { }; /** payment_method_details_card */ payment_method_details_card: { - /** @description Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ brand?: string | null; /** @description Check results by Card networks on Card address and CVC at time of payment. */ checks?: components["schemas"]["payment_method_details_card_checks"] | null; @@ -9334,7 +9334,7 @@ export interface components { last4?: string | null; /** @description ID of the mandate used to make this payment or created by it. */ mandate?: string | null; - /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ network?: string | null; /** @description Populated if this transaction used 3D Secure authentication. */ three_d_secure?: components["schemas"]["three_d_secure_details"] | null; @@ -9375,7 +9375,7 @@ export interface components { payment_method_details_card_present: { /** @description The authorized amount */ amount_authorized?: number | null; - /** @description Card brand. Can be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ brand?: string | null; /** * Format: unix-time @@ -9406,7 +9406,7 @@ export interface components { incremental_authorization_supported: boolean; /** @description The last four digits of the card. */ last4?: string | null; - /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ network?: string | null; /** @description Defines whether the authorized amount can be over-captured or not */ overcapture_supported: boolean; @@ -9452,10 +9452,10 @@ export interface components { masterpass?: components["schemas"]["payment_method_details_card_wallet_masterpass"]; samsung_pay?: components["schemas"]["payment_method_details_card_wallet_samsung_pay"]; /** - * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or `visa_checkout`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. + * @description The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type. * @enum {string} */ - type: "amex_express_checkout" | "apple_pay" | "google_pay" | "masterpass" | "samsung_pay" | "visa_checkout"; + type: "amex_express_checkout" | "apple_pay" | "google_pay" | "link" | "masterpass" | "samsung_pay" | "visa_checkout"; visa_checkout?: components["schemas"]["payment_method_details_card_wallet_visa_checkout"]; }; /** payment_method_details_card_wallet_amex_express_checkout */ @@ -9586,7 +9586,7 @@ export interface components { generated_card?: string | null; /** @description The last four digits of the card. */ last4?: string | null; - /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ + /** @description Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. */ network?: string | null; /** @description EMV tag 5F2D. Preferred languages specified by the integrated circuit chip. */ preferred_locales?: (string)[] | null; @@ -9818,6 +9818,11 @@ export interface components { payment_method_konbini: Record; /** payment_method_link */ payment_method_link: { + /** + * @description Two-letter ISO code representing the funding source (i.e. card, bank) country beneath the Link payment method. + * You could use this attribute to get a sense of the international breakdown of funding sources you've collected. + */ + country?: string; /** @description Account owner's email address. */ email?: string | null; /** @description Token used for persistent Link logins. */ @@ -10280,6 +10285,25 @@ export interface components { networks?: components["schemas"]["us_bank_account_networks"] | null; /** @description Routing number of the bank account. */ routing_number?: string | null; + /** @description Contains information about the future reusability of this PaymentMethod. */ + status_details?: components["schemas"]["payment_method_us_bank_account_status_details"] | null; + }; + /** payment_method_us_bank_account_blocked */ + payment_method_us_bank_account_blocked: { + /** + * @description The ACH network code that resulted in this block. + * @enum {string|null} + */ + network_code?: "R02" | "R03" | "R04" | "R05" | "R07" | "R08" | "R10" | "R11" | "R16" | "R20" | "R29" | "R31" | null; + /** + * @description The reason why this PaymentMethod's fingerprint has been blocked + * @enum {string|null} + */ + reason?: "bank_account_closed" | "bank_account_frozen" | "bank_account_invalid_details" | "bank_account_restricted" | "bank_account_unusable" | "debit_not_authorized" | null; + }; + /** payment_method_us_bank_account_status_details */ + payment_method_us_bank_account_status_details: { + blocked?: components["schemas"]["payment_method_us_bank_account_blocked"]; }; /** payment_method_wechat_pay */ payment_method_wechat_pay: Record; @@ -11041,7 +11065,7 @@ export interface components { /** @description The recurring components of a price such as `interval` and `usage_type`. */ recurring?: components["schemas"]["recurring"] | null; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string|null} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified" | null; @@ -11632,7 +11656,7 @@ export interface components { failure_reason?: string; /** @description Unique identifier for the object. */ id: string; - /** @description Email to which refund instructions, if required, are sent to. */ + /** @description For payment methods without native refund support (e.g., Konbini, PromptPay), email for the customer to receive refund instructions. */ instructions_email?: string; /** @description Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. */ metadata?: ({ @@ -13497,7 +13521,9 @@ export interface components { }; /** * TaxProductResourceTaxCalculation - * @description A Tax `Calculation` allows you to calculate the tax to collect from your customer. + * @description A Tax Calculation allows you to calculate the tax to collect from your customer. + * + * Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom). */ "tax.calculation": { /** @description Total after taxes. */ @@ -13585,7 +13611,9 @@ export interface components { }; /** * TaxProductResourceTaxTransaction - * @description A Tax transaction records the tax collected from or refunded to your customer. + * @description A Tax Transaction records the tax collected from or refunded to your customer. + * + * Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom#tax-transaction). */ "tax.transaction": { /** @@ -20003,6 +20031,7 @@ export interface operations { amount?: number; /** @description Specifies which fields in the response should be expanded. */ expand?: (string)[]; + /** @description For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions. */ instructions_email?: string; /** @description Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: ({ @@ -20098,7 +20127,7 @@ export interface operations { customer?: string; /** @description Specifies which fields in the response should be expanded. */ expand?: (string)[]; - /** @description Address to send refund email, use customer email if not specified */ + /** @description For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions. */ instructions_email?: string; /** @description Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: ({ @@ -25803,7 +25832,7 @@ export interface operations { /** @description The ID of a subscription to add this invoice item to. When left blank, the invoice item will be be added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription. */ subscription?: string; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified"; @@ -25922,7 +25951,7 @@ export interface operations { /** @description Non-negative integer. The quantity of units for the invoice item. */ quantity?: number; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified"; @@ -27556,7 +27585,7 @@ export interface operations { * @description One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details. * @enum {string} */ - type: "company" | "individual"; + type?: "company" | "individual"; }; }; }; @@ -32399,7 +32428,7 @@ export interface operations { usage_type?: "licensed" | "metered"; }; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified"; @@ -32585,7 +32614,7 @@ export interface operations { /** @description A brief description of the price, hidden from customers. */ nickname?: string; /** - * @description Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. + * @description Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. * @enum {string} */ tax_behavior?: "exclusive" | "inclusive" | "unspecified"; @@ -34176,7 +34205,7 @@ export interface operations { customer?: string; /** @description Specifies which fields in the response should be expanded. */ expand?: (string)[]; - /** @description Address to send refund email, use customer email if not specified */ + /** @description For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions. */ instructions_email?: string; /** @description Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. */ metadata?: ({ @@ -38149,7 +38178,7 @@ export interface operations { })[]; /** * shipping_cost - * @description Shipping cost details to be used for the calculation + * @description Shipping cost details to be used for the calculation. */ shipping_cost?: { amount?: number; diff --git a/examples/stripe-api.yaml b/examples/stripe-api.yaml index 467e1b6a8..792823532 100644 --- a/examples/stripe-api.yaml +++ b/examples/stripe-api.yaml @@ -155,7 +155,7 @@ components: tos_acceptance: $ref: '#/components/schemas/account_tos_acceptance' type: - description: The Stripe account type. Can be `standard`, `express`, or `custom`. + description: 'The Stripe account type. Can be `standard`, `express`, or `custom`.' enum: - custom - express @@ -1425,7 +1425,7 @@ components: description: '' properties: city: - description: City, district, suburb, town, or village. + description: 'City, district, suburb, town, or village.' maxLength: 5000 nullable: true type: string @@ -1437,12 +1437,12 @@ components: nullable: true type: string line1: - description: Address line 1 (e.g., street, PO Box, or company name). + description: 'Address line 1 (e.g., street, PO Box, or company name).' maxLength: 5000 nullable: true type: string line2: - description: Address line 2 (e.g., apartment, suite, unit, or building). + description: 'Address line 2 (e.g., apartment, suite, unit, or building).' maxLength: 5000 nullable: true type: string @@ -1452,7 +1452,7 @@ components: nullable: true type: string state: - description: State, county, province, or region. + description: 'State, county, province, or region.' maxLength: 5000 nullable: true type: string @@ -1463,7 +1463,7 @@ components: description: '' properties: charge: - description: For card errors, the ID of the failed charge. + description: 'For card errors, the ID of the failed charge.' maxLength: 5000 type: string code: @@ -1620,7 +1620,7 @@ components: oneOf: - $ref: '#/components/schemas/account' amount: - description: Amount earned, in %s. + description: 'Amount earned, in %s.' type: integer amount_refunded: description: >- @@ -1790,7 +1790,7 @@ components: format: unix-time type: integer deleted: - description: If true, indicates that this secret has been deleted + description: 'If true, indicates that this secret has been deleted' type: boolean expires_at: description: >- @@ -2012,7 +2012,7 @@ components: Types](https://stripe.com/docs/reports/balance-transaction-types). properties: amount: - description: Gross amount of the transaction, in %s. + description: 'Gross amount of the transaction, in %s.' type: integer available_on: description: >- @@ -2066,7 +2066,7 @@ components: maxLength: 5000 type: string net: - description: Net amount of the transaction, in %s. + description: 'Net amount of the transaction, in %s.' type: integer object: description: >- @@ -3011,7 +3011,7 @@ components: nullable: true type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 nullable: true type: string @@ -3063,7 +3063,8 @@ components: brand: description: >- Card brand. Can be `American Express`, `Diners Club`, `Discover`, - `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`. + `Eftpos Australia`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or + `Unknown`. maxLength: 5000 type: string country: @@ -3529,7 +3530,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/payment_intent' - description: ID of the PaymentIntent associated with this charge, if one exists. + description: 'ID of the PaymentIntent associated with this charge, if one exists.' nullable: true x-expansionResources: oneOf: @@ -3738,7 +3739,7 @@ components: description: '' properties: stripe_report: - description: Assessments from Stripe. If set, the value is `fraudulent`. + description: 'Assessments from Stripe. If set, the value is `fraudulent`.' maxLength: 5000 type: string user_report: @@ -3801,7 +3802,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/rule' - description: The ID of the Radar rule that matched the payment, if applicable. + description: 'The ID of the Radar rule that matched the payment, if applicable.' x-expansionResources: oneOf: - $ref: '#/components/schemas/rule' @@ -4048,7 +4049,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/invoice' - description: ID of the invoice created by the Checkout Session, if it exists. + description: 'ID of the invoice created by the Checkout Session, if it exists.' nullable: true x-expansionResources: oneOf: @@ -5349,7 +5350,7 @@ components: description: '' properties: amount: - description: Amount transferred, in %s. + description: 'Amount transferred, in %s.' type: integer currency: description: >- @@ -6048,7 +6049,7 @@ components: description: '' properties: amount: - description: The amount, in %s, of the tax. + description: 'The amount, in %s, of the tax.' type: integer inclusive: description: Whether this tax amount is inclusive or exclusive. @@ -6082,10 +6083,12 @@ components: nullable: true tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes or - exclusive of taxes. One of `inclusive`, `exclusive`, or - `unspecified`. Once specified as either `inclusive` or `exclusive`, - it cannot be changed. + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies whether the + price is considered inclusive of taxes or exclusive of taxes. One of + `inclusive`, `exclusive`, or `unspecified`. Once specified as either + `inclusive` or `exclusive`, it cannot be changed. enum: - exclusive - inclusive @@ -6287,7 +6290,7 @@ components: nullable: true type: string next_invoice_sequence: - description: The suffix of the customer's next invoice number, e.g., 0001. + description: 'The suffix of the customer''s next invoice number, e.g., 0001.' type: integer object: description: >- @@ -6302,7 +6305,7 @@ components: nullable: true type: string preferred_locales: - description: The customer's preferred locales (languages), ordered by preference. + description: 'The customer''s preferred locales (languages), ordered by preference.' items: maxLength: 5000 type: string @@ -6316,7 +6319,7 @@ components: emailed to this customer. nullable: true sources: - description: The customer's payment sources, if any. + description: 'The customer''s payment sources, if any.' properties: data: description: Details about each object. @@ -6354,7 +6357,7 @@ components: x-expandableFields: - data subscriptions: - description: The customer's current subscriptions, if any. + description: 'The customer''s current subscriptions, if any.' properties: data: description: Details about each object. @@ -6589,7 +6592,7 @@ components: nullable: true type: string sender_name: - description: The full name of the sender, as supplied by the sending bank. + description: 'The full name of the sender, as supplied by the sending bank.' maxLength: 5000 nullable: true type: string @@ -7789,7 +7792,7 @@ components: description: '' properties: amount: - description: The amount, in %s, of the discount. + description: 'The amount, in %s, of the discount.' type: integer discount: anyOf: @@ -8565,7 +8568,7 @@ components: description: '' properties: amount: - description: Amount of the fee, in cents. + description: 'Amount of the fee, in cents.' type: integer application: description: ID of the Connect application that earned the fee. @@ -8612,7 +8615,7 @@ components: Fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee). properties: amount: - description: Amount, in %s. + description: 'Amount, in %s.' type: integer balance_transaction: anyOf: @@ -8712,7 +8715,7 @@ components: nullable: true type: integer filename: - description: A filename for the file, suitable for saving to a filesystem. + description: 'A filename for the file, suitable for saving to a filesystem.' maxLength: 5000 nullable: true type: string @@ -8795,7 +8798,7 @@ components: nullable: true type: string type: - description: The type of the file returned (e.g., `csv`, `pdf`, `jpg`, or `png`). + description: 'The type of the file returned (e.g., `csv`, `pdf`, `jpg`, or `png`).' maxLength: 5000 nullable: true type: string @@ -9534,7 +9537,7 @@ components: nullable: true type: string account_type: - description: The bank account type. In Japan, this can only be `futsu` or `toza`. + description: 'The bank account type. In Japan, this can only be `futsu` or `toza`.' maxLength: 5000 nullable: true type: string @@ -10502,10 +10505,10 @@ components: invoice will be for the amount specified in `amount_due`. type: integer amount_paid: - description: The amount, in %s, that was paid. + description: 'The amount, in %s, that was paid.' type: integer amount_remaining: - description: The difference between amount_due and amount_paid, in %s. + description: 'The difference between amount_due and amount_paid, in %s.' type: integer amount_shipping: description: This is the sum of all the shipping amounts. @@ -10583,7 +10586,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/charge' - description: ID of the latest charge generated for this invoice, if any. + description: 'ID of the latest charge generated for this invoice, if any.' nullable: true x-expansionResources: oneOf: @@ -10724,7 +10727,7 @@ components: - $ref: '#/components/schemas/source' x-stripeBypassValidation: true default_tax_rates: - description: The tax rates applied to this invoice, if any. + description: 'The tax rates applied to this invoice, if any.' items: $ref: '#/components/schemas/tax_rate' type: array @@ -11040,7 +11043,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/subscription' - description: The subscription that this invoice was prepared for, if any. + description: 'The subscription that this invoice was prepared for, if any.' nullable: true x-expansionResources: oneOf: @@ -11542,7 +11545,7 @@ components: description: '' properties: amount: - description: The amount, in %s, of the tax. + description: 'The amount, in %s, of the tax.' type: integer inclusive: description: Whether this tax amount is inclusive or exclusive. @@ -12451,7 +12454,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/issuing.card' - description: The latest card that replaces this card, if any. + description: 'The latest card that replaces this card, if any.' nullable: true x-expansionResources: oneOf: @@ -12461,7 +12464,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/issuing.card' - description: The card this card replaces, if any. + description: 'The card this card replaces, if any.' nullable: true x-expansionResources: oneOf: @@ -12623,7 +12626,10 @@ components: - inactive type: string type: - description: One of `individual` or `company`. + description: >- + One of `individual` or `company`. See [Choose a cardholder + type](https://stripe.com/docs/issuing/other/choose-cardholder) for + more details. enum: - company - individual @@ -12809,7 +12815,7 @@ components: description: The total net amount required to settle with the network. type: integer network: - description: The card network for this settlement report. One of ["visa"] + description: 'The card network for this settlement report. One of ["visa"]' enum: - visa type: string @@ -12946,7 +12952,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/issuing.dispute' - description: If you've disputed the transaction, the ID of the dispute. + description: 'If you''ve disputed the transaction, the ID of the dispute.' nullable: true x-expansionResources: oneOf: @@ -14074,7 +14080,7 @@ components: nullable: true type: boolean service: - description: Shipment service, such as `standard` or `express`. + description: 'Shipment service, such as `standard` or `express`.' enum: - express - priority @@ -15238,11 +15244,11 @@ components: description: '' properties: day: - description: The day of birth, between 1 and 31. + description: 'The day of birth, between 1 and 31.' nullable: true type: integer month: - description: The month of birth, between 1 and 12. + description: 'The month of birth, between 1 and 12.' nullable: true type: integer year: @@ -15654,7 +15660,7 @@ components: document: anyOf: - $ref: '#/components/schemas/issuing_cardholder_id_document' - description: An identifying document, either a passport or local ID card. + description: 'An identifying document, either a passport or local ID card.' nullable: true title: IssuingCardholderVerification type: object @@ -16275,7 +16281,7 @@ components: description: Total before any discounts or taxes are applied. type: integer amount_tax: - description: Total tax amount applied. If no tax was applied, defaults to 0. + description: 'Total tax amount applied. If no tax was applied, defaults to 0.' type: integer amount_total: description: Total after discounts and taxes. @@ -16540,11 +16546,11 @@ components: description: '' properties: day: - description: The day of birth, between 1 and 31. + description: 'The day of birth, between 1 and 31.' nullable: true type: integer month: - description: The month of birth, between 1 and 12. + description: 'The month of birth, between 1 and 12.' nullable: true type: integer year: @@ -16726,7 +16732,7 @@ components: description: '' properties: amount: - description: The amount, in %s. + description: 'The amount, in %s.' type: integer amount_excluding_tax: description: >- @@ -16831,7 +16837,7 @@ components: nullable: true type: integer subscription: - description: The subscription that the invoice item pertains to, if any. + description: 'The subscription that the invoice item pertains to, if any.' maxLength: 5000 nullable: true type: string @@ -17258,10 +17264,10 @@ components: description: '' properties: amount: - description: On a single use mandate, the amount of the payment. + description: 'On a single use mandate, the amount of the payment.' type: integer currency: - description: On a single use mandate, the currency of the payment. + description: 'On a single use mandate, the currency of the payment.' type: string required: - amount @@ -17532,16 +17538,16 @@ components: description: '' properties: height: - description: Height, in inches. + description: 'Height, in inches.' type: number length: - description: Length, in inches. + description: 'Length, in inches.' type: number weight: - description: Weight, in ounces. + description: 'Weight, in ounces.' type: number width: - description: Width, in inches. + description: 'Width, in inches.' type: number required: - height @@ -17637,11 +17643,11 @@ components: description: '' properties: day: - description: The day of birth, between 1 and 31. + description: 'The day of birth, between 1 and 31.' nullable: true type: integer month: - description: The month of birth, between 1 and 12. + description: 'The month of birth, between 1 and 12.' nullable: true type: integer year: @@ -17834,7 +17840,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/invoice' - description: ID of the invoice that created this PaymentIntent, if it exists. + description: 'ID of the invoice that created this PaymentIntent, if it exists.' nullable: true x-expansionResources: oneOf: @@ -17946,7 +17952,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/review' - description: ID of the review associated with this PaymentIntent, if any. + description: 'ID of the review associated with this PaymentIntent, if any.' nullable: true x-expansionResources: oneOf: @@ -19974,7 +19980,7 @@ components: description: '' properties: enabled: - description: If `true`, a phone number will be collected during checkout. + description: 'If `true`, a phone number will be collected during checkout.' type: boolean required: - enabled @@ -20611,7 +20617,7 @@ components: nullable: true type: string sort_code: - description: Sort code of the bank account. (e.g., `10-20-30`) + description: 'Sort code of the bank account. (e.g., `10-20-30`)' maxLength: 5000 nullable: true type: string @@ -20647,7 +20653,7 @@ components: properties: brand: description: >- - Card brand. Can be `amex`, `diners`, `discover`, `jcb`, + Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 type: string @@ -20825,14 +20831,15 @@ components: type: description: >- The type of the card wallet, one of `amex_express_checkout`, - `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or - `visa_checkout`. An additional hash is included on the Wallet - subhash with a name matching this value. It contains additional - information specific to the card wallet type. + `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, + `visa_checkout`, or `link`. An additional hash is included on the + Wallet subhash with a name matching this value. It contains + additional information specific to the card wallet type. enum: - amex_express_checkout - apple_pay - google_pay + - link - masterpass - samsung_pay - visa_checkout @@ -21269,7 +21276,7 @@ components: nullable: true type: string sort_code: - description: Sort code of the bank account. (e.g., `10-20-30`) + description: 'Sort code of the bank account. (e.g., `10-20-30`)' maxLength: 5000 nullable: true type: string @@ -21376,7 +21383,7 @@ components: properties: brand: description: >- - Card brand. Can be `amex`, `diners`, `discover`, `jcb`, + Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 nullable: true @@ -21448,8 +21455,8 @@ components: network: description: >- Identifies which network this charge was processed on. Can be - `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, - `mastercard`, `unionpay`, `visa`, or `unknown`. + `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, + `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 nullable: true type: string @@ -21535,7 +21542,7 @@ components: nullable: true type: string type: - description: Type of installment plan, one of `fixed_count`. + description: 'Type of installment plan, one of `fixed_count`.' enum: - fixed_count type: string @@ -21553,7 +21560,7 @@ components: type: integer brand: description: >- - Card brand. Can be `amex`, `diners`, `discover`, `jcb`, + Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 nullable: true @@ -21642,8 +21649,8 @@ components: network: description: >- Identifies which network this charge was processed on. Can be - `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, - `mastercard`, `unionpay`, `visa`, or `unknown`. + `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, + `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 nullable: true type: string @@ -21689,7 +21696,7 @@ components: type: string x-stripeBypassValidation: true application_cryptogram: - description: EMV tag 9F26, cryptogram generated by the integrated circuit chip. + description: 'EMV tag 9F26, cryptogram generated by the integrated circuit chip.' maxLength: 5000 nullable: true type: string @@ -21761,14 +21768,15 @@ components: type: description: >- The type of the card wallet, one of `amex_express_checkout`, - `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, or - `visa_checkout`. An additional hash is included on the Wallet - subhash with a name matching this value. It contains additional - information specific to the card wallet type. + `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, + `visa_checkout`, or `link`. An additional hash is included on the + Wallet subhash with a name matching this value. It contains + additional information specific to the card wallet type. enum: - amex_express_checkout - apple_pay - google_pay + - link - masterpass - samsung_pay - visa_checkout @@ -22154,7 +22162,7 @@ components: description: '' properties: brand: - description: Card brand. Can be `interac`, `mastercard` or `visa`. + description: 'Card brand. Can be `interac`, `mastercard` or `visa`.' maxLength: 5000 nullable: true type: string @@ -22229,8 +22237,8 @@ components: network: description: >- Identifies which network this charge was processed on. Can be - `amex`, `cartes_bancaires`, `diners`, `discover`, `interac`, `jcb`, - `mastercard`, `unionpay`, `visa`, or `unknown`. + `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, + `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`. maxLength: 5000 nullable: true type: string @@ -22280,7 +22288,7 @@ components: type: string x-stripeBypassValidation: true application_cryptogram: - description: EMV tag 9F26, cryptogram generated by the integrated circuit chip. + description: 'EMV tag 9F26, cryptogram generated by the integrated circuit chip.' maxLength: 5000 nullable: true type: string @@ -22890,7 +22898,7 @@ components: anyOf: - $ref: >- #/components/schemas/payment_flows_private_payment_methods_klarna_dob - description: The customer's date of birth, if provided. + description: 'The customer''s date of birth, if provided.' nullable: true title: payment_method_klarna type: object @@ -22905,6 +22913,15 @@ components: payment_method_link: description: '' properties: + country: + description: >- + Two-letter ISO code representing the funding source (i.e. card, + bank) country beneath the Link payment method. + + You could use this attribute to get a sense of the international + breakdown of funding sources you've collected. + maxLength: 5000 + type: string email: description: Account owner's email address. maxLength: 5000 @@ -23886,7 +23903,7 @@ components: description: '' properties: bank: - description: The customer's bank, if provided. + description: 'The customer''s bank, if provided.' enum: - alior_bank - bank_millennium @@ -24044,10 +24061,62 @@ components: maxLength: 5000 nullable: true type: string + status_details: + anyOf: + - $ref: >- + #/components/schemas/payment_method_us_bank_account_status_details + description: >- + Contains information about the future reusability of this + PaymentMethod. + nullable: true title: payment_method_us_bank_account type: object x-expandableFields: - networks + - status_details + payment_method_us_bank_account_blocked: + description: '' + properties: + network_code: + description: The ACH network code that resulted in this block. + enum: + - R02 + - R03 + - R04 + - R05 + - R07 + - R08 + - R10 + - R11 + - R16 + - R20 + - R29 + - R31 + nullable: true + type: string + reason: + description: The reason why this PaymentMethod's fingerprint has been blocked + enum: + - bank_account_closed + - bank_account_frozen + - bank_account_invalid_details + - bank_account_restricted + - bank_account_unusable + - debit_not_authorized + nullable: true + type: string + title: payment_method_us_bank_account_blocked + type: object + x-expandableFields: [] + payment_method_us_bank_account_status_details: + description: '' + properties: + blocked: + $ref: '#/components/schemas/payment_method_us_bank_account_blocked' + title: payment_method_us_bank_account_status_details + type: object + x-expandableFields: + - blocked payment_method_wechat_pay: description: '' properties: {} @@ -24316,7 +24385,7 @@ components: description: '' properties: value: - description: The value entered by the customer, containing only digits. + description: 'The value entered by the customer, containing only digits.' maxLength: 5000 nullable: true type: string @@ -25531,7 +25600,7 @@ components: nullable: true type: boolean title: - description: The person's title (e.g., CEO, Support Engineer). + description: 'The person''s title (e.g., CEO, Support Engineer).' maxLength: 5000 nullable: true type: string @@ -25724,7 +25793,7 @@ components: nullable: true type: object nickname: - description: A brief description of the plan, hidden from customers. + description: 'A brief description of the plan, hidden from customers.' maxLength: 5000 nullable: true type: string @@ -26322,7 +26391,7 @@ components: additional information about the object in a structured format. type: object nickname: - description: A brief description of the price, hidden from customers. + description: 'A brief description of the price, hidden from customers.' maxLength: 5000 nullable: true type: string @@ -26353,10 +26422,12 @@ components: nullable: true tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes or - exclusive of taxes. One of `inclusive`, `exclusive`, or - `unspecified`. Once specified as either `inclusive` or `exclusive`, - it cannot be changed. + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies whether the + price is considered inclusive of taxes or exclusive of taxes. One of + `inclusive`, `exclusive`, or `unspecified`. Once specified as either + `inclusive` or `exclusive`, it cannot be changed. enum: - exclusive - inclusive @@ -26544,7 +26615,7 @@ components: additional information about the object in a structured format. type: object name: - description: The product's name, meant to be displayable to the customer. + description: 'The product''s name, meant to be displayable to the customer.' maxLength: 5000 type: string object: @@ -26560,7 +26631,7 @@ components: description: The dimensions of this product for shipping purposes. nullable: true shippable: - description: Whether this product is shipped (i.e., physical goods). + description: 'Whether this product is shipped (i.e., physical goods).' nullable: true type: boolean statement_descriptor: @@ -26576,7 +26647,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/tax_code' - description: A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + description: 'A [tax code](https://stripe.com/docs/tax/tax-categories) ID.' nullable: true x-expansionResources: oneOf: @@ -27691,7 +27762,7 @@ components: description: '' properties: browser: - description: The browser used in this browser session (e.g., `Chrome`). + description: 'The browser used in this browser session (e.g., `Chrome`).' maxLength: 5000 nullable: true type: string @@ -27703,12 +27774,12 @@ components: nullable: true type: string platform: - description: The platform for the browser session (e.g., `Macintosh`). + description: 'The platform for the browser session (e.g., `Macintosh`).' maxLength: 5000 nullable: true type: string version: - description: The version for the browser session (e.g., `61.0.3163.100`). + description: 'The version for the browser session (e.g., `61.0.3163.100`).' maxLength: 5000 nullable: true type: string @@ -27802,7 +27873,7 @@ components: Related guide: [Refunds](https://stripe.com/docs/refunds). properties: amount: - description: Amount, in %s. + description: 'Amount, in %s.' type: integer balance_transaction: anyOf: @@ -27870,7 +27941,9 @@ components: maxLength: 5000 type: string instructions_email: - description: Email to which refund instructions, if required, are sent to. + description: >- + For payment methods without native refund support (e.g., Konbini, + PromptPay), email for the customer to receive refund instructions. maxLength: 5000 type: string metadata: @@ -28250,7 +28323,7 @@ components: [here](https://stripe.com/docs/radar/reviews). properties: billing_zip: - description: The ZIP or postal code of the card used, if applicable. + description: 'The ZIP or postal code of the card used, if applicable.' maxLength: 5000 nullable: true type: string @@ -28314,7 +28387,7 @@ components: - review type: string open: - description: If `true`, the review needs action. + description: 'If `true`, the review needs action.' type: boolean opened_reason: description: The reason the review was opened. One of `rule` or `manual`. @@ -28327,7 +28400,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/payment_intent' - description: The PaymentIntent ID associated with this review, if one exists. + description: 'The PaymentIntent ID associated with this review, if one exists.' x-expansionResources: oneOf: - $ref: '#/components/schemas/payment_intent' @@ -28490,7 +28563,7 @@ components: - user type: string user: - description: The user ID, if type is set to "user" + description: 'The user ID, if type is set to "user"' maxLength: 5000 type: string required: @@ -28506,7 +28579,7 @@ components: - maxLength: 5000 type: string - $ref: '#/components/schemas/charge' - description: The ID of the Charge that generated this PaymentMethod, if any. + description: 'The ID of the Charge that generated this PaymentMethod, if any.' nullable: true x-expansionResources: oneOf: @@ -30490,7 +30563,7 @@ components: number of instances of the SKU to be ordered. type: integer type: - description: The type of this order item. Must be `sku`, `tax`, or `shipping`. + description: 'The type of this order item. Must be `sku`, `tax`, or `shipping`.' maxLength: 5000 nullable: true type: string @@ -31541,7 +31614,7 @@ components: overrides a discount applied on a customer-wide basis. nullable: true ended_at: - description: If the subscription has ended, the date the subscription ended. + description: 'If the subscription has ended, the date the subscription ended.' format: unix-time nullable: true type: integer @@ -31550,7 +31623,7 @@ components: maxLength: 5000 type: string items: - description: List of subscription items, each with an attached price. + description: 'List of subscription items, each with an attached price.' properties: data: description: Details about each object. @@ -31759,7 +31832,7 @@ components: transferred to for each of the subscription's invoices. nullable: true trial_end: - description: If the subscription has a trial, the end of that trial. + description: 'If the subscription has a trial, the end of that trial.' format: unix-time nullable: true type: integer @@ -31770,7 +31843,7 @@ components: description: Settings related to subscription trials. nullable: true trial_start: - description: If the subscription has a trial, the beginning of that trial. + description: 'If the subscription has a trial, the beginning of that trial.' format: unix-time nullable: true type: integer @@ -32847,8 +32920,12 @@ components: - end_behavior tax.calculation: description: >- - A Tax `Calculation` allows you to calculate the tax to collect from your + A Tax Calculation allows you to calculate the tax to collect from your customer. + + + Related guide: [Calculate tax in your custom payment + flow](https://stripe.com/docs/tax/custom). properties: amount_total: description: Total after taxes. @@ -32905,7 +32982,7 @@ components: url: description: The URL where this list can be accessed. maxLength: 5000 - pattern: ^/v1/tax/calculations/:id/line_items + pattern: '^/v1/tax/calculations/:id/line_items' type: string required: - data @@ -32978,7 +33055,7 @@ components: top of this amount. type: integer amount_tax: - description: The amount of tax calculated for this line item, in integer cents. + description: 'The amount of tax calculated for this line item, in integer cents.' type: integer id: description: Unique identifier for the object. @@ -33047,8 +33124,12 @@ components: x-resourceId: tax.calculation_line_item tax.transaction: description: >- - A Tax transaction records the tax collected from or refunded to your + A Tax Transaction records the tax collected from or refunded to your customer. + + + Related guide: [Calculate tax in your custom payment + flow](https://stripe.com/docs/tax/custom#tax-transaction). properties: created: description: >- @@ -33079,7 +33160,7 @@ components: maxLength: 5000 type: string line_items: - description: The tax collected or refunded, by line item. + description: 'The tax collected or refunded, by line item.' nullable: true properties: data: @@ -33102,7 +33183,7 @@ components: url: description: The URL where this list can be accessed. maxLength: 5000 - pattern: ^/v1/tax/transactions/:id/line_items + pattern: '^/v1/tax/transactions/:id/line_items' type: string required: - data @@ -33136,14 +33217,14 @@ components: - tax.transaction type: string reference: - description: A custom unique identifier, such as 'myOrder_123'. + description: 'A custom unique identifier, such as ''myOrder_123''.' maxLength: 5000 type: string reversal: anyOf: - $ref: >- #/components/schemas/tax_product_resource_tax_transaction_resource_reversal - description: If `type=reversal`, contains information about what was reversed. + description: 'If `type=reversal`, contains information about what was reversed.' nullable: true shipping_cost: anyOf: @@ -33157,7 +33238,7 @@ components: format: unix-time type: integer type: - description: If `reversal`, this transaction reverses an earlier transaction. + description: 'If `reversal`, this transaction reverses an earlier transaction.' enum: - reversal - transaction @@ -33190,7 +33271,7 @@ components: top of this amount. type: integer amount_tax: - description: The amount of tax calculated for this line item, in integer cents. + description: 'The amount of tax calculated for this line item, in integer cents.' type: integer id: description: Unique identifier for the object. @@ -33231,7 +33312,7 @@ components: anyOf: - $ref: >- #/components/schemas/tax_product_resource_tax_transaction_line_item_resource_reversal - description: If `type=reversal`, contains information about what was reversed. + description: 'If `type=reversal`, contains information about what was reversed.' nullable: true tax_behavior: description: >- @@ -33248,7 +33329,7 @@ components: maxLength: 5000 type: string type: - description: If `reversal`, this line item reverses an earlier transaction. + description: 'If `reversal`, this line item reverses an earlier transaction.' enum: - reversal - transaction @@ -33531,7 +33612,7 @@ components: nullable: true type: string tax_ids: - description: The customer's tax IDs (for example, EU VAT numbers). + description: 'The customer''s tax IDs (for example, EU VAT numbers).' items: $ref: >- #/components/schemas/tax_product_resource_customer_details_resource_tax_id @@ -33670,7 +33751,7 @@ components: description: '' properties: amount: - description: The amount of tax, in integer cents. + description: 'The amount of tax, in integer cents.' type: integer jurisdiction: $ref: '#/components/schemas/tax_product_resource_jurisdiction' @@ -33714,7 +33795,7 @@ components: - zero_rated type: string taxable_amount: - description: The amount on which tax is calculated, in integer cents. + description: 'The amount on which tax is calculated, in integer cents.' type: integer required: - amount @@ -33744,7 +33825,7 @@ components: maxLength: 5000 type: string tax_type: - description: The tax type, such as `vat` or `sales_tax`. + description: 'The tax type, such as `vat` or `sales_tax`.' enum: - gst - hst @@ -33768,7 +33849,7 @@ components: description: '' properties: city: - description: City, district, suburb, town, or village. + description: 'City, district, suburb, town, or village.' maxLength: 5000 nullable: true type: string @@ -33779,12 +33860,12 @@ components: maxLength: 5000 type: string line1: - description: Address line 1 (e.g., street, PO Box, or company name). + description: 'Address line 1 (e.g., street, PO Box, or company name).' maxLength: 5000 nullable: true type: string line2: - description: Address line 2 (e.g., apartment, suite, unit, or building). + description: 'Address line 2 (e.g., apartment, suite, unit, or building).' maxLength: 5000 nullable: true type: string @@ -33816,7 +33897,7 @@ components: top of this amount. type: integer amount_tax: - description: The amount of tax calculated for shipping, in integer cents. + description: 'The amount of tax calculated for shipping, in integer cents.' type: integer shipping_rate: description: >- @@ -33850,7 +33931,7 @@ components: description: '' properties: amount: - description: The amount of tax, in integer cents. + description: 'The amount of tax, in integer cents.' type: integer inclusive: description: >- @@ -33860,7 +33941,7 @@ components: tax_rate_details: $ref: '#/components/schemas/tax_product_resource_tax_rate_details' taxable_amount: - description: The amount on which tax is calculated, in integer cents. + description: 'The amount on which tax is calculated, in integer cents.' type: integer required: - amount @@ -33888,12 +33969,12 @@ components: maxLength: 5000 type: string state: - description: State, county, province, or region. + description: 'State, county, province, or region.' maxLength: 5000 nullable: true type: string tax_type: - description: The tax type, such as `vat` or `sales_tax`. + description: 'The tax type, such as `vat` or `sales_tax`.' enum: - gst - hst @@ -34028,7 +34109,7 @@ components: nullable: true type: string tax_type: - description: The high-level tax type, such as `vat` or `sales_tax`. + description: 'The high-level tax type, such as `vat` or `sales_tax`.' enum: - gst - hst @@ -34514,12 +34595,12 @@ components: description: Represents an action performed by the reader properties: failure_code: - description: Failure code, only set if status is `failed`. + description: 'Failure code, only set if status is `failed`.' maxLength: 5000 nullable: true type: string failure_message: - description: Detailed failure message, only set if status is `failed`. + description: 'Detailed failure message, only set if status is `failed`.' maxLength: 5000 nullable: true type: string @@ -35310,7 +35391,7 @@ components: Transfers](https://stripe.com/docs/connect/charges-transfers#reversing-transfers). properties: amount: - description: Amount, in %s. + description: 'Amount, in %s.' type: integer balance_transaction: anyOf: @@ -35441,7 +35522,7 @@ components: description: Divide usage by this number. type: integer round: - description: After division, either round the result `up` or `down`. + description: 'After division, either round the result `up` or `down`.' enum: - down - up @@ -35459,7 +35540,7 @@ components: description: Divide usage by this number. type: integer round: - description: After division, either round the result `up` or `down`. + description: 'After division, either round the result `up` or `down`.' enum: - down - up @@ -36071,7 +36152,7 @@ components: description: Amount (in cents) transferred. type: integer cancelable: - description: Returns `true` if the object can be canceled, and `false` otherwise. + description: 'Returns `true` if the object can be canceled, and `false` otherwise.' type: boolean created: description: >- @@ -36249,7 +36330,7 @@ components: description: Amount (in cents) transferred. type: integer cancelable: - description: Returns `true` if the object can be canceled, and `false` otherwise. + description: 'Returns `true` if the object can be canceled, and `false` otherwise.' type: boolean created: description: >- @@ -36983,7 +37064,7 @@ components: inbound_pending: additionalProperties: type: integer - description: Funds not spendable yet, but will become available at a later time. + description: 'Funds not spendable yet, but will become available at a later time.' type: object outbound_pending: additionalProperties: @@ -38039,11 +38120,11 @@ info: contact: email: dev-platform@stripe.com name: Stripe Dev Platform Team - url: https://stripe.com + url: 'https://stripe.com' description: >- The Stripe REST API. Please see https://stripe.com/docs/api for more details. - termsOfService: https://stripe.com/us/terms/ + termsOfService: 'https://stripe.com/us/terms/' title: Stripe API version: '2022-11-15' x-stripeSpecFilename: spec3 @@ -39385,7 +39466,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}: + '/v1/accounts/{account}': delete: description: >-

With Connect, you can delete accounts you @@ -40500,7 +40581,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/bank_accounts: + '/v1/accounts/{account}/bank_accounts': post: description:

Create an external account for a given account.

operationId: PostAccountsAccountBankAccounts @@ -40634,7 +40715,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/bank_accounts/{id}: + '/v1/accounts/{account}/bank_accounts/{id}': delete: description:

Delete a specified external account for a given account.

operationId: DeleteAccountsAccountBankAccountsId @@ -40799,7 +40880,7 @@ paths: maxLength: 5000 type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 type: string address_line1: @@ -40888,7 +40969,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/capabilities: + '/v1/accounts/{account}/capabilities': get: description: >-

Returns a list of capabilities associated with the account. The @@ -40966,7 +41047,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/capabilities/{capability}: + '/v1/accounts/{account}/capabilities/{capability}': get: description:

Retrieves information about the specified Account Capability.

operationId: GetAccountsAccountCapabilitiesCapability @@ -41072,7 +41153,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/external_accounts: + '/v1/accounts/{account}/external_accounts': get: description:

List external accounts for an account.

operationId: GetAccountsAccountExternalAccounts @@ -41321,7 +41402,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/external_accounts/{id}: + '/v1/accounts/{account}/external_accounts/{id}': delete: description:

Delete a specified external account for a given account.

operationId: DeleteAccountsAccountExternalAccountsId @@ -41486,7 +41567,7 @@ paths: maxLength: 5000 type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 type: string address_line1: @@ -41575,7 +41656,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/login_links: + '/v1/accounts/{account}/login_links': post: description: >-

Creates a single-use login link for an Express account to access @@ -41625,7 +41706,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/people: + '/v1/accounts/{account}/people': get: description: >-

Returns a list of people associated with the account’s legal entity. @@ -42144,7 +42225,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/people/{person}: + '/v1/accounts/{account}/people/{person}': delete: description: >-

Deletes an existing person’s relationship to the account’s legal @@ -42635,7 +42716,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/persons: + '/v1/accounts/{account}/persons': get: description: >-

Returns a list of people associated with the account’s legal entity. @@ -43154,7 +43235,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/persons/{person}: + '/v1/accounts/{account}/persons/{person}': delete: description: >-

Deletes an existing person’s relationship to the account’s legal @@ -43645,7 +43726,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/accounts/{account}/reject: + '/v1/accounts/{account}/reject': post: description: >-

With Connect, you may flag accounts as @@ -43852,7 +43933,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/apple_pay/domains/{domain}: + '/v1/apple_pay/domains/{domain}': delete: description:

Delete an apple pay domain.

operationId: DeleteApplePayDomainsDomain @@ -44066,7 +44147,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/application_fees/{fee}/refunds/{id}: + '/v1/application_fees/{fee}/refunds/{id}': get: description: >-

By default, you can see the 10 most recent refunds stored directly on @@ -44195,7 +44276,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/application_fees/{id}: + '/v1/application_fees/{id}': get: description: >-

Retrieves the details of an application fee that your account has @@ -44243,7 +44324,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/application_fees/{id}/refund: + '/v1/application_fees/{id}/refund': post: description: '' operationId: PostApplicationFeesIdRefund @@ -44291,7 +44372,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/application_fees/{id}/refunds: + '/v1/application_fees/{id}/refunds': get: description: >-

You can see a list of the refunds belonging to a specific application @@ -45043,7 +45124,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/balance/history/{id}: + '/v1/balance/history/{id}': get: description: >-

Retrieves the balance transaction with the given ID.

@@ -45272,7 +45353,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/balance_transactions/{id}: + '/v1/balance_transactions/{id}': get: description: >-

Retrieves the balance transaction with the given ID.

@@ -45691,7 +45772,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/billing_portal/configurations/{configuration}: + '/v1/billing_portal/configurations/{configuration}': get: description: >-

Retrieves a configuration that describes the functionality of the @@ -46775,7 +46856,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}: + '/v1/charges/{charge}': get: description: >-

Retrieves the details of a charge that has previously been created. @@ -46990,7 +47071,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/capture: + '/v1/charges/{charge}/capture': post: description: >-

Capture the payment of an existing, uncaptured, charge. This is the @@ -47104,7 +47185,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/dispute: + '/v1/charges/{charge}/dispute': get: description:

Retrieve a dispute for a specified charge.

operationId: GetChargesChargeDispute @@ -47302,7 +47383,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/dispute/close: + '/v1/charges/{charge}/dispute/close': post: description: '' operationId: PostChargesChargeDisputeClose @@ -47345,7 +47426,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/refund: + '/v1/charges/{charge}/refund': post: description: >-

When you create a new refund, you must specify a Charge or a @@ -47402,6 +47483,10 @@ paths: type: string type: array instructions_email: + description: >- + For payment methods without native refund support (e.g., + Konbini, PromptPay), use this email from the customer to + receive refund instructions. type: string metadata: anyOf: @@ -47448,7 +47533,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/refunds: + '/v1/charges/{charge}/refunds': get: description: >-

You can see a list of the refunds belonging to a specific charge. @@ -47607,8 +47692,9 @@ paths: type: array instructions_email: description: >- - Address to send refund email, use customer email if not - specified + For payment methods without native refund support (e.g., + Konbini, PromptPay), use this email from the customer to + receive refund instructions. type: string metadata: anyOf: @@ -47660,7 +47746,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/charges/{charge}/refunds/{refund}: + '/v1/charges/{charge}/refunds/{refund}': get: description:

Retrieves the details of an existing refund.

operationId: GetChargesChargeRefundsRefund @@ -49570,7 +49656,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/checkout/sessions/{session}: + '/v1/checkout/sessions/{session}': get: description:

Retrieves a Session object.

operationId: GetCheckoutSessionsSession @@ -49615,7 +49701,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/checkout/sessions/{session}/expire: + '/v1/checkout/sessions/{session}/expire': post: description: >-

A Session can be expired when it is in one of these statuses: @@ -49664,7 +49750,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/checkout/sessions/{session}/line_items: + '/v1/checkout/sessions/{session}/line_items': get: description: >-

When retrieving a Checkout Session, there is an includable @@ -49883,7 +49969,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/country_specs/{country}: + '/v1/country_specs/{country}': get: description:

Returns a Country Spec for a given Country code.

operationId: GetCountrySpecsCountry @@ -50220,7 +50306,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/coupons/{coupon}: + '/v1/coupons/{coupon}': delete: description: >-

You can delete coupons via the -

When retrieving a credit note, you’ll get a lines @@ -51256,7 +51342,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/credit_notes/{id}: + '/v1/credit_notes/{id}': get: description:

Retrieves the credit note object with the given identifier.

operationId: GetCreditNotesId @@ -51362,7 +51448,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/credit_notes/{id}/void: + '/v1/credit_notes/{id}/void': post: description: >-

Marks a credit note as void. Learn more about -

Permanently deletes a customer. It cannot be undone. Also immediately @@ -52464,7 +52550,7 @@ paths: maxLength: 20 type: string preferred_locales: - description: Customer's preferred languages, ordered by preference. + description: 'Customer''s preferred languages, ordered by preference.' items: maxLength: 5000 type: string @@ -52559,7 +52645,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/balance_transactions: + '/v1/customers/{customer}/balance_transactions': get: description: >-

Returns a list of transactions that updated the customer’s -

Retrieves a specific customer balance transaction that updated the @@ -52888,7 +52974,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/bank_accounts: + '/v1/customers/{customer}/bank_accounts': get: deprecated: true description: >- @@ -53185,7 +53271,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/bank_accounts/{id}: + '/v1/customers/{customer}/bank_accounts/{id}': delete: description:

Delete a specified source for a given customer.

operationId: DeleteCustomersCustomerBankAccountsId @@ -53345,7 +53431,7 @@ paths: maxLength: 5000 type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 type: string address_line1: @@ -53450,7 +53536,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/bank_accounts/{id}/verify: + '/v1/customers/{customer}/bank_accounts/{id}/verify': post: description:

Verify a specified bank account for a given customer.

operationId: PostCustomersCustomerBankAccountsIdVerify @@ -53510,7 +53596,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/cards: + '/v1/customers/{customer}/cards': get: deprecated: true description: >- @@ -53809,7 +53895,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/cards/{id}: + '/v1/customers/{customer}/cards/{id}': delete: description:

Delete a specified source for a given customer.

operationId: DeleteCustomersCustomerCardsId @@ -53969,7 +54055,7 @@ paths: maxLength: 5000 type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 type: string address_line1: @@ -54074,7 +54160,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/cash_balance: + '/v1/customers/{customer}/cash_balance': get: description:

Retrieves a customer’s cash balance.

operationId: GetCustomersCustomerCashBalance @@ -54175,7 +54261,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/cash_balance_transactions: + '/v1/customers/{customer}/cash_balance_transactions': get: description: >-

Returns a list of transactions that modified the customer’s -

Retrieves a specific cash balance transaction, which updated the @@ -54352,7 +54438,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/discount: + '/v1/customers/{customer}/discount': delete: description:

Removes the currently applied discount on a customer.

operationId: DeleteCustomersCustomerDiscount @@ -54430,7 +54516,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/funding_instructions: + '/v1/customers/{customer}/funding_instructions': post: description: >-

Retrieve funding instructions for a customer cash balance. If funding @@ -54534,7 +54620,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/payment_methods: + '/v1/customers/{customer}/payment_methods': get: description:

Returns a list of PaymentMethods for a given Customer

operationId: GetCustomersCustomerPaymentMethods @@ -54685,7 +54771,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/payment_methods/{payment_method}: + '/v1/customers/{customer}/payment_methods/{payment_method}': get: description:

Retrieves a PaymentMethod object for a given Customer.

operationId: GetCustomersCustomerPaymentMethodsPaymentMethod @@ -54737,7 +54823,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/sources: + '/v1/customers/{customer}/sources': get: description:

List sources for a specified customer.

operationId: GetCustomersCustomerSources @@ -55041,7 +55127,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/sources/{id}: + '/v1/customers/{customer}/sources/{id}': delete: description:

Delete a specified source for a given customer.

operationId: DeleteCustomersCustomerSourcesId @@ -55197,7 +55283,7 @@ paths: maxLength: 5000 type: string address_country: - description: Billing address country, if provided when creating card. + description: 'Billing address country, if provided when creating card.' maxLength: 5000 type: string address_line1: @@ -55302,7 +55388,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/sources/{id}/verify: + '/v1/customers/{customer}/sources/{id}/verify': post: description:

Verify a specified bank account for a given customer.

operationId: PostCustomersCustomerSourcesIdVerify @@ -55362,7 +55448,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/subscriptions: + '/v1/customers/{customer}/subscriptions': get: description: >-

You can see a list of the customer’s active subscriptions. Note that @@ -56201,7 +56287,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/subscriptions/{subscription_exposed_id}: + '/v1/customers/{customer}/subscriptions/{subscription_exposed_id}': delete: description: >-

Cancels a customer’s subscription. If you set the @@ -57126,7 +57212,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/subscriptions/{subscription_exposed_id}/discount: + '/v1/customers/{customer}/subscriptions/{subscription_exposed_id}/discount': delete: description:

Removes the currently applied discount on a customer.

operationId: DeleteCustomersCustomerSubscriptionsSubscriptionExposedIdDiscount @@ -57218,7 +57304,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/tax_ids: + '/v1/customers/{customer}/tax_ids': get: description:

Returns a list of tax IDs for a customer.

operationId: GetCustomersCustomerTaxIds @@ -57444,7 +57530,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/customers/{customer}/tax_ids/{id}: + '/v1/customers/{customer}/tax_ids/{id}': delete: description:

Deletes an existing TaxID object.

operationId: DeleteCustomersCustomerTaxIdsId @@ -57679,7 +57765,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/disputes/{dispute}: + '/v1/disputes/{dispute}': get: description:

Retrieves the dispute with the given ID.

operationId: GetDisputesDispute @@ -57888,7 +57974,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/disputes/{dispute}/close: + '/v1/disputes/{dispute}/close': post: description: >-

Closing the dispute for a charge indicates that you do not have any @@ -57992,7 +58078,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/ephemeral_keys/{key}: + '/v1/ephemeral_keys/{key}': delete: description:

Invalidates a short-lived API key for a given resource.

operationId: DeleteEphemeralKeysKey @@ -58198,7 +58284,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/events/{id}: + '/v1/events/{id}': get: description: >-

Retrieves the details of an event. Supply the unique identifier of @@ -58353,7 +58439,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/exchange_rates/{rate_id}: + '/v1/exchange_rates/{rate_id}': get: description: >-

Retrieves the exchange rates from the given currency to every @@ -58611,7 +58697,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/file_links/{link}: + '/v1/file_links/{link}': get: description:

Retrieves the file link with the given ID.

operationId: GetFileLinksLink @@ -58983,8 +59069,8 @@ paths: $ref: '#/components/schemas/error' description: Error response. servers: - - url: https://files.stripe.com/ - /v1/files/{file}: + - url: 'https://files.stripe.com/' + '/v1/files/{file}': get: description: >-

Retrieves the details of an existing file object. Supply the unique @@ -59170,7 +59256,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/financial_connections/accounts/{account}: + '/v1/financial_connections/accounts/{account}': get: description: >-

Retrieves the details of an Financial Connections @@ -59217,7 +59303,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/financial_connections/accounts/{account}/disconnect: + '/v1/financial_connections/accounts/{account}/disconnect': post: description: >-

Disables your access to a Financial Connections Account. @@ -59263,7 +59349,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/financial_connections/accounts/{account}/owners: + '/v1/financial_connections/accounts/{account}/owners': get: description:

Lists all owners for a given Account

operationId: GetFinancialConnectionsAccountsAccountOwners @@ -59382,7 +59468,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/financial_connections/accounts/{account}/refresh: + '/v1/financial_connections/accounts/{account}/refresh': post: description: >-

Refreshes the data associated with a Financial Connections @@ -59546,7 +59632,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/financial_connections/sessions/{session}: + '/v1/financial_connections/sessions/{session}': get: description: >-

Retrieves the details of a Financial Connections @@ -59737,7 +59823,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/identity/verification_reports/{report}: + '/v1/identity/verification_reports/{report}': get: description:

Retrieves an existing VerificationReport

operationId: GetIdentityVerificationReportsReport @@ -60031,7 +60117,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/identity/verification_sessions/{session}: + '/v1/identity/verification_sessions/{session}': get: description: >-

Retrieves the details of a VerificationSession that was previously @@ -60189,7 +60275,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/identity/verification_sessions/{session}/cancel: + '/v1/identity/verification_sessions/{session}/cancel': post: description: >-

A VerificationSession object can be canceled when it is in @@ -60240,7 +60326,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/identity/verification_sessions/{session}/redact: + '/v1/identity/verification_sessions/{session}/redact': post: description: >-

Redact a VerificationSession to remove all collected information from @@ -60672,8 +60758,11 @@ paths: type: string tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes - or exclusive of taxes. One of `inclusive`, `exclusive`, or + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies + whether the price is considered inclusive of taxes or + exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. enum: @@ -60687,7 +60776,7 @@ paths: - enum: - '' type: string - description: A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + description: 'A [tax code](https://stripe.com/docs/tax/tax-categories) ID.' tax_rates: description: >- The tax rates which apply to the invoice item. When set, the @@ -60729,7 +60818,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoiceitems/{invoiceitem}: + '/v1/invoiceitems/{invoiceitem}': delete: description: >-

Deletes an invoice item, removing it from an invoice. Deleting @@ -60975,8 +61064,11 @@ paths: type: integer tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes - or exclusive of taxes. One of `inclusive`, `exclusive`, or + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies + whether the price is considered inclusive of taxes or + exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. enum: @@ -60990,7 +61082,7 @@ paths: - enum: - '' type: string - description: A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + description: 'A [tax code](https://stripe.com/docs/tax/tax-categories) ID.' tax_rates: anyOf: - items: @@ -62493,7 +62585,7 @@ paths: - '' type: string style: deepObject - - description: A list of up to 20 subscription items, each with an attached price. + - description: 'A list of up to 20 subscription items, each with an attached price.' explode: true in: query name: subscription_items @@ -63200,7 +63292,7 @@ paths: - '' type: string style: deepObject - - description: A list of up to 20 subscription items, each with an attached price. + - description: 'A list of up to 20 subscription items, each with an attached price.' explode: true in: query name: subscription_items @@ -63429,7 +63521,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}: + '/v1/invoices/{invoice}': delete: description: >-

Permanently deletes a one-off invoice draft. This cannot be undone. @@ -64153,7 +64245,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/finalize: + '/v1/invoices/{invoice}/finalize': post: description: >-

Stripe automatically finalizes drafts before sending and attempting @@ -64206,7 +64298,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/lines: + '/v1/invoices/{invoice}/lines': get: description: >-

When retrieving an invoice, you’ll get a lines @@ -64321,7 +64413,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/mark_uncollectible: + '/v1/invoices/{invoice}/mark_uncollectible': post: description: >-

Marking an invoice as uncollectible is useful for keeping track of @@ -64366,7 +64458,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/pay: + '/v1/invoices/{invoice}/pay': post: description: >-

Stripe automatically creates and then attempts to collect payment on @@ -64466,7 +64558,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/send: + '/v1/invoices/{invoice}/send': post: description: >-

Stripe will automatically send invoices to customers according to @@ -64520,7 +64612,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/invoices/{invoice}/void: + '/v1/invoices/{invoice}/void': post: description: >-

Mark a finalized invoice as void. This cannot be undone. Voiding an @@ -64725,7 +64817,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/authorizations/{authorization}: + '/v1/issuing/authorizations/{authorization}': get: description:

Retrieves an Issuing Authorization object.

operationId: GetIssuingAuthorizationsAuthorization @@ -64834,7 +64926,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/authorizations/{authorization}/approve: + '/v1/issuing/authorizations/{authorization}/approve': post: description: >-

Approves a pending Issuing Authorization object. This @@ -64913,7 +65005,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/authorizations/{authorization}/decline: + '/v1/issuing/authorizations/{authorization}/decline': post: description: >-

Declines a pending Issuing Authorization object. This @@ -66300,7 +66392,6 @@ paths: required: - billing - name - - type type: object required: true responses: @@ -66316,7 +66407,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/cardholders/{cardholder}: + '/v1/issuing/cardholders/{cardholder}': get: description:

Retrieves an Issuing Cardholder object.

operationId: GetIssuingCardholdersCardholder @@ -68820,7 +68911,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/cards/{card}: + '/v1/issuing/cards/{card}': get: description:

Retrieves an Issuing Card object.

operationId: GetIssuingCardsCard @@ -70428,7 +70519,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/disputes/{dispute}: + '/v1/issuing/disputes/{dispute}': get: description:

Retrieves an Issuing Dispute object.

operationId: GetIssuingDisputesDispute @@ -70813,7 +70904,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/disputes/{dispute}/submit: + '/v1/issuing/disputes/{dispute}/submit': post: description: >-

Submits an Issuing Dispute to the card network. Stripe @@ -71009,7 +71100,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/settlements/{settlement}: + '/v1/issuing/settlements/{settlement}': get: description:

Retrieves an Issuing Settlement object.

operationId: GetIssuingSettlementsSettlement @@ -71271,7 +71362,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/issuing/transactions/{transaction}: + '/v1/issuing/transactions/{transaction}': get: description:

Retrieves an Issuing Transaction object.

operationId: GetIssuingTransactionsTransaction @@ -71485,7 +71576,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/link_account_sessions/{session}: + '/v1/link_account_sessions/{session}': get: description: >-

Retrieves the details of a Financial Connections @@ -71668,7 +71759,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/linked_accounts/{account}: + '/v1/linked_accounts/{account}': get: description: >-

Retrieves the details of an Financial Connections @@ -71715,7 +71806,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/linked_accounts/{account}/disconnect: + '/v1/linked_accounts/{account}/disconnect': post: description: >-

Disables your access to a Financial Connections Account. @@ -71761,7 +71852,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/linked_accounts/{account}/owners: + '/v1/linked_accounts/{account}/owners': get: description:

Lists all owners for a given Account

operationId: GetLinkedAccountsAccountOwners @@ -71880,7 +71971,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/linked_accounts/{account}/refresh: + '/v1/linked_accounts/{account}/refresh': post: description: >-

Refreshes the data associated with a Financial Connections @@ -71939,7 +72030,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/mandates/{mandate}: + '/v1/mandates/{mandate}': get: description:

Retrieves a Mandate object.

operationId: GetMandatesMandate @@ -73857,7 +73948,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}: + '/v1/payment_intents/{intent}': get: description: >-

Retrieves the details of a PaymentIntent that has previously been @@ -75413,7 +75504,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/apply_customer_balance: + '/v1/payment_intents/{intent}/apply_customer_balance': post: description: >-

Manually reconcile the remaining amount for a customer_balance @@ -75484,7 +75575,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/cancel: + '/v1/payment_intents/{intent}/cancel': post: description: >-

A PaymentIntent object can be canceled when it is in one of these @@ -75557,7 +75648,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/capture: + '/v1/payment_intents/{intent}/capture': post: description: >-

Capture the funds of an existing uncaptured PaymentIntent when its @@ -75659,7 +75750,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/confirm: + '/v1/payment_intents/{intent}/confirm': post: description: >-

Confirm that your customer intends to pay with current or provided @@ -77207,7 +77298,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/increment_authorization: + '/v1/payment_intents/{intent}/increment_authorization': post: description: >-

Perform an incremental authorization on an eligible @@ -77365,7 +77456,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_intents/{intent}/verify_microdeposits: + '/v1/payment_intents/{intent}/verify_microdeposits': post: description:

Verifies microdeposits on a PaymentIntent object.

operationId: PostPaymentIntentsIntentVerifyMicrodeposits @@ -78334,7 +78425,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_links/{payment_link}: + '/v1/payment_links/{payment_link}': get: description:

Retrieve a payment link.

operationId: GetPaymentLinksPaymentLink @@ -79036,7 +79127,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_links/{payment_link}/line_items: + '/v1/payment_links/{payment_link}/line_items': get: description: >-

When retrieving a payment link, there is an includable @@ -79999,7 +80090,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_methods/{payment_method}: + '/v1/payment_methods/{payment_method}': get: description: >-

Retrieves a PaymentMethod object attached to the StripeAccount. To @@ -80199,7 +80290,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_methods/{payment_method}/attach: + '/v1/payment_methods/{payment_method}/attach': post: description: >-

Attaches a PaymentMethod object to a Customer.

@@ -80279,7 +80370,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payment_methods/{payment_method}/detach: + '/v1/payment_methods/{payment_method}/detach': post: description: >-

Detaches a PaymentMethod object from a Customer. After a @@ -80613,7 +80704,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payouts/{payout}: + '/v1/payouts/{payout}': get: description: >-

Retrieves the details of an existing payout. Supply the unique payout @@ -80725,7 +80816,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payouts/{payout}/cancel: + '/v1/payouts/{payout}/cancel': post: description: >-

A previously created payout can be canceled if it has not yet been @@ -80771,7 +80862,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/payouts/{payout}/reverse: + '/v1/payouts/{payout}/reverse': post: description: >-

Reverses a payout by debiting the destination bank account. Only @@ -81115,7 +81206,7 @@ paths: value to them. All keys can be unset by posting an empty value to `metadata`. nickname: - description: A brief description of the plan, hidden from customers. + description: 'A brief description of the plan, hidden from customers.' maxLength: 5000 type: string product: @@ -81250,7 +81341,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/plans/{plan}: + '/v1/plans/{plan}': delete: description: >-

Deleting plans means new subscribers can’t be added. Existing @@ -81385,7 +81476,7 @@ paths: value to them. All keys can be unset by posting an empty value to `metadata`. nickname: - description: A brief description of the plan, hidden from customers. + description: 'A brief description of the plan, hidden from customers.' maxLength: 5000 type: string product: @@ -81492,7 +81583,7 @@ paths: schema: type: integer style: form - - description: Only return the price with these lookup_keys, if any exist. + - description: 'Only return the price with these lookup_keys, if any exist.' explode: true in: query name: lookup_keys @@ -81776,7 +81867,7 @@ paths: value to `metadata`. type: object nickname: - description: A brief description of the price, hidden from customers. + description: 'A brief description of the price, hidden from customers.' maxLength: 5000 type: string product: @@ -81845,8 +81936,11 @@ paths: type: object tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes - or exclusive of taxes. One of `inclusive`, `exclusive`, or + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies + whether the price is considered inclusive of taxes or + exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. enum: @@ -82064,7 +82158,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/prices/{price}: + '/v1/prices/{price}': get: description:

Retrieves the price with the given ID.

operationId: GetPricesPrice @@ -82237,13 +82331,16 @@ paths: value to them. All keys can be unset by posting an empty value to `metadata`. nickname: - description: A brief description of the price, hidden from customers. + description: 'A brief description of the price, hidden from customers.' maxLength: 5000 type: string tax_behavior: description: >- - Specifies whether the price is considered inclusive of taxes - or exclusive of taxes. One of `inclusive`, `exclusive`, or + Only required if a [default tax + behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) + was not provided in the Stripe Tax settings. Specifies + whether the price is considered inclusive of taxes or + exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed. enum: @@ -82607,7 +82704,7 @@ paths: value to `metadata`. type: object name: - description: The product's name, meant to be displayable to the customer. + description: 'The product''s name, meant to be displayable to the customer.' maxLength: 5000 type: string package_dimensions: @@ -82629,7 +82726,7 @@ paths: title: package_dimensions_specs type: object shippable: - description: Whether this product is shipped (i.e., physical goods). + description: 'Whether this product is shipped (i.e., physical goods).' type: boolean statement_descriptor: description: >- @@ -82647,7 +82744,7 @@ paths: maxLength: 22 type: string tax_code: - description: A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + description: 'A [tax code](https://stripe.com/docs/tax/tax-categories) ID.' type: string unit_label: description: >- @@ -82793,7 +82890,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/products/{id}: + '/v1/products/{id}': delete: description: >-

Delete a product. Deleting a product is only possible if it has no @@ -82967,7 +83064,7 @@ paths: value to them. All keys can be unset by posting an empty value to `metadata`. name: - description: The product's name, meant to be displayable to the customer. + description: 'The product''s name, meant to be displayable to the customer.' maxLength: 5000 type: string package_dimensions: @@ -82993,7 +83090,7 @@ paths: type: string description: The dimensions of this product for shipping purposes. shippable: - description: Whether this product is shipped (i.e., physical goods). + description: 'Whether this product is shipped (i.e., physical goods).' type: boolean statement_descriptor: description: >- @@ -83016,7 +83113,7 @@ paths: - enum: - '' type: string - description: A [tax code](https://stripe.com/docs/tax/tax-categories) ID. + description: 'A [tax code](https://stripe.com/docs/tax/tax-categories) ID.' unit_label: description: >- A label that represents units of this product. When set, @@ -83314,7 +83411,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/promotion_codes/{promotion_code}: + '/v1/promotion_codes/{promotion_code}': get: description: >-

Retrieves the promotion code with the given ID. In order to retrieve @@ -83940,7 +84037,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}: + '/v1/quotes/{quote}': get: description:

Retrieves the quote with the given ID.

operationId: GetQuotesQuote @@ -84307,7 +84404,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}/accept: + '/v1/quotes/{quote}/accept': post: description:

Accepts the specified quote.

operationId: PostQuotesQuoteAccept @@ -84350,7 +84447,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}/cancel: + '/v1/quotes/{quote}/cancel': post: description:

Cancels the quote.

operationId: PostQuotesQuoteCancel @@ -84393,7 +84490,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}/computed_upfront_line_items: + '/v1/quotes/{quote}/computed_upfront_line_items': get: description: >-

When retrieving a quote, there is an includable Finalizes the quote.

operationId: PostQuotesQuoteFinalize @@ -84559,7 +84656,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}/line_items: + '/v1/quotes/{quote}/line_items': get: description: >-

When retrieving a quote, there is an includable @@ -84674,7 +84771,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/quotes/{quote}/pdf: + '/v1/quotes/{quote}/pdf': get: description:

Download the PDF for a finalized quote

operationId: GetQuotesQuotePdf @@ -84843,7 +84940,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/radar/early_fraud_warnings/{early_fraud_warning}: + '/v1/radar/early_fraud_warnings/{early_fraud_warning}': get: description: >-

Retrieves the details of an early fraud warning that has previously @@ -85089,7 +85186,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/radar/value_list_items/{item}: + '/v1/radar/value_list_items/{item}': delete: description: >-

Deletes a ValueListItem object, removing it from its @@ -85393,7 +85490,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/radar/value_lists/{value_list}: + '/v1/radar/value_lists/{value_list}': delete: description: >-

Deletes a ValueList object, also deleting any items @@ -85723,8 +85820,9 @@ paths: type: array instructions_email: description: >- - Address to send refund email, use customer email if not - specified + For payment methods without native refund support (e.g., + Konbini, PromptPay), use this email from the customer to + receive refund instructions. type: string metadata: anyOf: @@ -85776,7 +85874,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/refunds/{refund}: + '/v1/refunds/{refund}': get: description:

Retrieves the details of an existing refund.

operationId: GetRefundsRefund @@ -85885,7 +85983,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/refunds/{refund}/cancel: + '/v1/refunds/{refund}/cancel': post: description: >-

Cancels a refund with a status of requires_action.

@@ -86775,7 +86873,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/reporting/report_runs/{report_run}: + '/v1/reporting/report_runs/{report_run}': get: description:

Retrieves the details of an existing Report Run.

operationId: GetReportingReportRunsReportRun @@ -86888,7 +86986,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/reporting/report_types/{report_type}: + '/v1/reporting/report_types/{report_type}': get: description: >-

Retrieves the details of a Report Type. (Certain report types require @@ -87061,7 +87159,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/reviews/{review}: + '/v1/reviews/{review}': get: description:

Retrieves a Review object.

operationId: GetReviewsReview @@ -87106,7 +87204,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/reviews/{review}/approve: + '/v1/reviews/{review}/approve': post: description: >-

Approves a Review object, closing it and removing it @@ -88279,7 +88377,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/setup_intents/{intent}: + '/v1/setup_intents/{intent}': get: description: >-

Retrieves the details of a SetupIntent that has previously been @@ -89073,7 +89171,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/setup_intents/{intent}/cancel: + '/v1/setup_intents/{intent}/cancel': post: description: >-

A SetupIntent object can be canceled when it is in one of these @@ -89134,7 +89232,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/setup_intents/{intent}/confirm: + '/v1/setup_intents/{intent}/confirm': post: description: >-

Confirm that your customer intends to set up the current or @@ -89888,7 +89986,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/setup_intents/{intent}/verify_microdeposits: + '/v1/setup_intents/{intent}/verify_microdeposits': post: description:

Verifies microdeposits on a SetupIntent object.

operationId: PostSetupIntentsIntentVerifyMicrodeposits @@ -90249,7 +90347,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/shipping_rates/{shipping_rate_token}: + '/v1/shipping_rates/{shipping_rate_token}': get: description:

Returns the shipping rate object with the given ID.

operationId: GetShippingRatesShippingRateToken @@ -90498,7 +90596,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sigma/scheduled_query_runs/{scheduled_query_run}: + '/v1/sigma/scheduled_query_runs/{scheduled_query_run}': get: description:

Retrieves the details of an scheduled query run.

operationId: GetSigmaScheduledQueryRunsScheduledQueryRun @@ -90889,7 +90987,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sources/{source}: + '/v1/sources/{source}': get: description: >-

Retrieves an existing source object. Supply the unique source ID from @@ -91221,7 +91319,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sources/{source}/mandate_notifications/{mandate_notification}: + '/v1/sources/{source}/mandate_notifications/{mandate_notification}': get: description:

Retrieves a new Source MandateNotification.

operationId: GetSourcesSourceMandateNotificationsMandateNotification @@ -91273,7 +91371,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sources/{source}/source_transactions: + '/v1/sources/{source}/source_transactions': get: description:

List source transactions for a given source.

operationId: GetSourcesSourceSourceTransactions @@ -91383,7 +91481,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sources/{source}/source_transactions/{source_transaction}: + '/v1/sources/{source}/source_transactions/{source_transaction}': get: description: >-

Retrieve an existing source transaction object. Supply the unique @@ -91439,7 +91537,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/sources/{source}/verify: + '/v1/sources/{source}/verify': post: description:

Verify a given source.

operationId: PostSourcesSourceVerify @@ -91822,7 +91920,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_items/{item}: + '/v1/subscription_items/{item}': delete: description: >-

Deletes an item from the subscription. Removing a subscription item @@ -92161,7 +92259,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_items/{subscription_item}/usage_record_summaries: + '/v1/subscription_items/{subscription_item}/usage_record_summaries': get: description: >-

For the specified subscription item, returns a list of summary @@ -92281,7 +92379,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_items/{subscription_item}/usage_records: + '/v1/subscription_items/{subscription_item}/usage_records': post: description: >-

Creates a usage record for a specified subscription item and date, @@ -92995,7 +93093,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_schedules/{schedule}: + '/v1/subscription_schedules/{schedule}': get: description: >-

Retrieves the details of an existing subscription schedule. You only @@ -93440,7 +93538,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_schedules/{schedule}/cancel: + '/v1/subscription_schedules/{schedule}/cancel': post: description: >-

Cancels a subscription schedule and its associated subscription @@ -93499,7 +93597,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscription_schedules/{schedule}/release: + '/v1/subscription_schedules/{schedule}/release': post: description: >-

Releases the subscription schedule immediately, which will stop @@ -94660,7 +94758,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscriptions/{subscription_exposed_id}: + '/v1/subscriptions/{subscription_exposed_id}': delete: description: >-

Cancels a customer’s subscription immediately. The customer will not @@ -95601,7 +95699,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscriptions/{subscription_exposed_id}/discount: + '/v1/subscriptions/{subscription_exposed_id}/discount': delete: description:

Removes the currently applied discount on a subscription.

operationId: DeleteSubscriptionsSubscriptionExposedIdDiscount @@ -95635,7 +95733,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/subscriptions/{subscription}/resume: + '/v1/subscriptions/{subscription}/resume': post: description: >-

Initiates resumption of a paused subscription, optionally resetting @@ -95762,7 +95860,7 @@ paths: maxLength: 5000 type: string customer_details: - description: Details about the customer, including address and tax IDs. + description: 'Details about the customer, including address and tax IDs.' properties: address: properties: @@ -95903,7 +96001,7 @@ paths: type: object type: array shipping_cost: - description: Shipping cost details to be used for the calculation + description: Shipping cost details to be used for the calculation. properties: amount: type: integer @@ -95944,7 +96042,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tax/calculations/{calculation}/line_items: + '/v1/tax/calculations/{calculation}/line_items': get: description: >-

Retrieves the line items of a persisted tax calculation as a @@ -96040,7 +96138,7 @@ paths: url: description: The URL where this list can be accessed. maxLength: 5000 - pattern: ^/v1/tax/calculations/:id/line_items + pattern: '^/v1/tax/calculations/:id/line_items' type: string required: - data @@ -96247,7 +96345,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tax/transactions/{transaction}: + '/v1/tax/transactions/{transaction}': get: description:

Retrieves a Tax Transaction object.

operationId: GetTaxTransactionsTransaction @@ -96292,7 +96390,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tax/transactions/{transaction}/line_items: + '/v1/tax/transactions/{transaction}/line_items': get: description: >-

Retrieves the line items of a committed standalone transaction as a @@ -96388,7 +96486,7 @@ paths: url: description: The URL where this list can be accessed. maxLength: 5000 - pattern: ^/v1/tax/transactions/:id/line_items + pattern: '^/v1/tax/transactions/:id/line_items' type: string required: - data @@ -96510,7 +96608,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tax_codes/{id}: + '/v1/tax_codes/{id}': get: description: >-

Retrieves the details of an existing tax code. Supply the unique tax @@ -96784,7 +96882,7 @@ paths: maxLength: 2 type: string tax_type: - description: The high-level tax type, such as `vat` or `sales_tax`. + description: 'The high-level tax type, such as `vat` or `sales_tax`.' enum: - gst - hst @@ -96816,7 +96914,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tax_rates/{tax_rate}: + '/v1/tax_rates/{tax_rate}': get: description:

Retrieves a tax rate with the given ID

operationId: GetTaxRatesTaxRate @@ -96948,7 +97046,7 @@ paths: maxLength: 2 type: string tax_type: - description: The high-level tax type, such as `vat` or `sales_tax`. + description: 'The high-level tax type, such as `vat` or `sales_tax`.' enum: - gst - hst @@ -97363,7 +97461,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/configurations/{configuration}: + '/v1/terminal/configurations/{configuration}': delete: description:

Deletes a Configuration object.

operationId: DeleteTerminalConfigurationsConfiguration @@ -97988,7 +98086,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/locations/{location}: + '/v1/terminal/locations/{location}': delete: description:

Deletes a Location object.

operationId: DeleteTerminalLocationsLocation @@ -98381,7 +98479,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}: + '/v1/terminal/readers/{reader}': delete: description:

Deletes a Reader object.

operationId: DeleteTerminalReadersReader @@ -98531,7 +98629,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}/cancel_action: + '/v1/terminal/readers/{reader}/cancel_action': post: description:

Cancels the current reader action.

operationId: PostTerminalReadersReaderCancelAction @@ -98574,7 +98672,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}/process_payment_intent: + '/v1/terminal/readers/{reader}/process_payment_intent': post: description:

Initiates a payment flow on a Reader.

operationId: PostTerminalReadersReaderProcessPaymentIntent @@ -98639,7 +98737,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}/process_setup_intent: + '/v1/terminal/readers/{reader}/process_setup_intent': post: description:

Initiates a setup intent flow on a Reader.

operationId: PostTerminalReadersReaderProcessSetupIntent @@ -98692,7 +98790,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}/refund_payment: + '/v1/terminal/readers/{reader}/refund_payment': post: description:

Initiates a refund on a Reader

operationId: PostTerminalReadersReaderRefundPayment @@ -98781,7 +98879,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/terminal/readers/{reader}/set_reader_display: + '/v1/terminal/readers/{reader}/set_reader_display': post: description:

Sets reader display to show cart details.

operationId: PostTerminalReadersReaderSetReaderDisplay @@ -98866,7 +98964,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/customers/{customer}/fund_cash_balance: + '/v1/test_helpers/customers/{customer}/fund_cash_balance': post: description:

Create an incoming testmode bank transfer

operationId: PostTestHelpersCustomersCustomerFundCashBalance @@ -98938,7 +99036,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/issuing/cards/{card}/shipping/deliver: + '/v1/test_helpers/issuing/cards/{card}/shipping/deliver': post: description: >-

Updates the shipping status of the specified Issuing @@ -98983,7 +99081,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/issuing/cards/{card}/shipping/fail: + '/v1/test_helpers/issuing/cards/{card}/shipping/fail': post: description: >-

Updates the shipping status of the specified Issuing @@ -99028,7 +99126,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/issuing/cards/{card}/shipping/return: + '/v1/test_helpers/issuing/cards/{card}/shipping/return': post: description: >-

Updates the shipping status of the specified Issuing @@ -99073,7 +99171,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/issuing/cards/{card}/shipping/ship: + '/v1/test_helpers/issuing/cards/{card}/shipping/ship': post: description: >-

Updates the shipping status of the specified Issuing @@ -99118,7 +99216,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/refunds/{refund}/expire: + '/v1/test_helpers/refunds/{refund}/expire': post: description:

Expire a refund with a status of requires_action.

operationId: PostTestHelpersRefundsRefundExpire @@ -99160,7 +99258,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/terminal/readers/{reader}/present_payment_method: + '/v1/test_helpers/terminal/readers/{reader}/present_payment_method': post: description: >-

Presents a payment method on a simulated reader. Can be used to @@ -99388,7 +99486,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/test_clocks/{test_clock}: + '/v1/test_helpers/test_clocks/{test_clock}': delete: description:

Deletes a test clock.

operationId: DeleteTestHelpersTestClocksTestClock @@ -99466,7 +99564,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/test_clocks/{test_clock}/advance: + '/v1/test_helpers/test_clocks/{test_clock}/advance': post: description: >-

Starts advancing a test clock to a specified time in the future. @@ -99522,7 +99620,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/inbound_transfers/{id}/fail: + '/v1/test_helpers/treasury/inbound_transfers/{id}/fail': post: description: >-

Transitions a test mode created InboundTransfer to the @@ -99592,7 +99690,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/inbound_transfers/{id}/return: + '/v1/test_helpers/treasury/inbound_transfers/{id}/return': post: description: >-

Marks the test mode InboundTransfer object as returned and links the @@ -99638,7 +99736,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/inbound_transfers/{id}/succeed: + '/v1/test_helpers/treasury/inbound_transfers/{id}/succeed': post: description: >-

Transitions a test mode created InboundTransfer to the @@ -99684,7 +99782,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_payments/{id}/fail: + '/v1/test_helpers/treasury/outbound_payments/{id}/fail': post: description: >-

Transitions a test mode created OutboundPayment to the @@ -99730,7 +99828,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_payments/{id}/post: + '/v1/test_helpers/treasury/outbound_payments/{id}/post': post: description: >-

Transitions a test mode created OutboundPayment to the @@ -99776,7 +99874,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_payments/{id}/return: + '/v1/test_helpers/treasury/outbound_payments/{id}/return': post: description: >-

Transitions a test mode created OutboundPayment to the @@ -99843,7 +99941,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail: + '/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail': post: description: >-

Transitions a test mode created OutboundTransfer to the @@ -99889,7 +99987,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post: + '/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post': post: description: >-

Transitions a test mode created OutboundTransfer to the @@ -99935,7 +100033,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return: + '/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return': post: description: >-

Transitions a test mode created OutboundTransfer to the @@ -100993,7 +101091,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/tokens/{token}: + '/v1/tokens/{token}': get: description:

Retrieves the token with the given ID.

operationId: GetTokensToken @@ -101291,7 +101389,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/topups/{topup}: + '/v1/topups/{topup}': get: description: >-

Retrieves the details of a top-up that has previously been created. @@ -101409,7 +101507,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/topups/{topup}/cancel: + '/v1/topups/{topup}/cancel': post: description:

Cancels a top-up. Only pending top-ups can be canceled.

operationId: PostTopupsTopupCancel @@ -101704,7 +101802,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/transfers/{id}/reversals: + '/v1/transfers/{id}/reversals': get: description: >-

You can see a list of the reversals belonging to a specific transfer. @@ -101918,7 +102016,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/transfers/{transfer}: + '/v1/transfers/{transfer}': get: description: >-

Retrieves the details of an existing transfer. Supply the unique @@ -102039,7 +102137,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/transfers/{transfer}/reversals/{id}: + '/v1/transfers/{transfer}/reversals/{id}': get: description: >-

By default, you can see the 10 most recent reversals stored directly @@ -102353,7 +102451,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/credit_reversals/{credit_reversal}: + '/v1/treasury/credit_reversals/{credit_reversal}': get: description: >-

Retrieves the details of an existing CreditReversal by passing the @@ -102596,7 +102694,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/debit_reversals/{debit_reversal}: + '/v1/treasury/debit_reversals/{debit_reversal}': get: description:

Retrieves a DebitReversal object.

operationId: GetTreasuryDebitReversalsDebitReversal @@ -102933,7 +103031,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/financial_accounts/{financial_account}: + '/v1/treasury/financial_accounts/{financial_account}': get: description:

Retrieves the details of a FinancialAccount.

operationId: GetTreasuryFinancialAccountsFinancialAccount @@ -103155,7 +103253,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/financial_accounts/{financial_account}/features: + '/v1/treasury/financial_accounts/{financial_account}/features': get: description: >-

Retrieves Features information associated with the @@ -103590,7 +103688,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/inbound_transfers/{id}: + '/v1/treasury/inbound_transfers/{id}': get: description:

Retrieves the details of an existing InboundTransfer.

operationId: GetTreasuryInboundTransfersId @@ -103635,7 +103733,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/inbound_transfers/{inbound_transfer}/cancel: + '/v1/treasury/inbound_transfers/{inbound_transfer}/cancel': post: description:

Cancels an InboundTransfer.

operationId: PostTreasuryInboundTransfersInboundTransferCancel @@ -104036,7 +104134,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/outbound_payments/{id}: + '/v1/treasury/outbound_payments/{id}': get: description: >-

Retrieves the details of an existing OutboundPayment by passing the @@ -104084,7 +104182,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/outbound_payments/{id}/cancel: + '/v1/treasury/outbound_payments/{id}/cancel': post: description:

Cancel an OutboundPayment.

operationId: PostTreasuryOutboundPaymentsIdCancel @@ -104362,7 +104460,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/outbound_transfers/{outbound_transfer}: + '/v1/treasury/outbound_transfers/{outbound_transfer}': get: description: >-

Retrieves the details of an existing OutboundTransfer by passing the @@ -104410,7 +104508,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/outbound_transfers/{outbound_transfer}/cancel: + '/v1/treasury/outbound_transfers/{outbound_transfer}/cancel': post: description: >-

An OutboundTransfer can be canceled if the funds have not yet been @@ -104599,7 +104697,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/received_credits/{id}: + '/v1/treasury/received_credits/{id}': get: description: >-

Retrieves the details of an existing ReceivedCredit by passing the @@ -104770,7 +104868,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/received_debits/{id}: + '/v1/treasury/received_debits/{id}': get: description: >-

Retrieves the details of an existing ReceivedDebit by passing the @@ -104987,7 +105085,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/transaction_entries/{id}: + '/v1/treasury/transaction_entries/{id}': get: description:

Retrieves a TransactionEntry object.

operationId: GetTreasuryTransactionEntriesId @@ -105215,7 +105313,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/treasury/transactions/{id}: + '/v1/treasury/transactions/{id}': get: description:

Retrieves the details of an existing Transaction.

operationId: GetTreasuryTransactionsId @@ -105785,7 +105883,7 @@ paths: schema: $ref: '#/components/schemas/error' description: Error response. - /v1/webhook_endpoints/{webhook_endpoint}: + '/v1/webhook_endpoints/{webhook_endpoint}': delete: description: >-

You can also delete webhook endpoints via the (TS_UNION_INTERSECTION_RE.test(String(t)) ? `(${t})` : t)).join(" | "); + if (types.length === 0) return "never"; + + // de-duplicate the union + const members = new Set(); + for (const t of types) { + // unknown swallows everything else in the union + if (t === "unknown") return "unknown"; + + members.add(String(t)); + } + + // never gets swallowed by anything else, so only return never + // if it is the only member + if (members.has("never") && members.size === 1) return "never"; + + // (otherwise remove it) + members.delete("never"); + + // return the only member without parentheses + const memberArr = Array.from(members); + if (members.size === 1) return memberArr[0]; + + // build the union string + let out = ""; + for (let i = 0; i < memberArr.length; i++) { + const t = memberArr[i]; + + // if the type has & or | we should parenthesise it for safety + const escaped = TS_UNION_INTERSECTION_RE.test(t) ? `(${t})` : t; + + out += escaped; + if (i !== memberArr.length - 1) out += " | "; + } + + return out; } /** escape string value */ diff --git a/test/schema-object.test.ts b/test/schema-object.test.ts index 55237c5df..3b84e3c9b 100644 --- a/test/schema-object.test.ts +++ b/test/schema-object.test.ts @@ -211,7 +211,7 @@ describe("Schema Object", () => { const schema: SchemaObject = { type: "object", additionalProperties: true }; const generated = transformSchemaObject(schema, options); expect(generated).toBe(`{ - [key: string]: unknown | undefined; + [key: string]: unknown; }`); }); @@ -230,7 +230,7 @@ describe("Schema Object", () => { const schema: SchemaObject = { type: "object", additionalProperties: {} }; const generated = transformSchemaObject(schema, options); expect(generated).toBe(`{ - [key: string]: unknown | undefined; + [key: string]: unknown; }`); }); @@ -425,7 +425,7 @@ describe("Schema Object", () => { }); expect(generated).toBe(`{ fixed: boolean; - [key: string]: unknown | undefined; + [key: string]: unknown; }`); }); }); @@ -517,9 +517,9 @@ describe("Schema Object", () => { ctx: { ...options.ctx, immutableTypes: true }, }); expect(generated).toBe(`{ - readonly array?: (readonly ({ - [key: string]: unknown | undefined; - })[]) | null; + readonly array?: readonly ({ + [key: string]: unknown; + })[] | null; }`); }); }); diff --git a/test/utils.test.ts b/test/utils.test.ts index 5d7c71ece..cff61722a 100644 --- a/test/utils.test.ts +++ b/test/utils.test.ts @@ -2,20 +2,41 @@ import { tsIntersectionOf, tsUnionOf } from "../src/utils.js"; describe("utils", () => { describe("tsUnionOf", () => { + test("never for no elements", () => { + expect(tsUnionOf()).toBe("never"); + }); + test("identity for single element", () => { + expect(tsUnionOf("boolean")).toBe("boolean"); + }); test("primitive", () => { - return expect(tsUnionOf(...["string", "number", "boolean"])).toBe("string | number | boolean"); + expect(tsUnionOf("string", "number", "boolean")).toBe("string | number | boolean"); }); test("constant booleans", () => { - return expect(tsUnionOf(...[true, false])).toBe("true | false"); + expect(tsUnionOf(true, false)).toBe("true | false"); }); test("constant strings", () => { - return expect(tsUnionOf(...['"hello"', '"world"'])).toBe('"hello" | "world"'); + expect(tsUnionOf('"hello"', '"world"')).toBe('"hello" | "world"'); }); test("constant numbers", () => { - return expect(tsUnionOf(...[0, 1, 2, 3])).toBe("0 | 1 | 2 | 3"); + expect(tsUnionOf(0, 1, 2, 3)).toBe("0 | 1 | 2 | 3"); }); test("mixed", () => { - return expect(tsUnionOf(...[0, true, "string", '"hello"'])).toBe('0 | true | string | "hello"'); + expect(tsUnionOf(0, true, "string", '"hello"')).toBe('0 | true | string | "hello"'); + }); + test("de-duplicate", () => { + expect(tsUnionOf("string", "string", "number")).toBe("string | number"); + }); + test("remove all but unknown", () => { + expect(tsUnionOf("string", "unknown")).toBe("unknown"); + }); + test("remove never", () => { + expect(tsUnionOf("string", "never")).toBe("string"); + }); + test("never if no other members of union", () => { + expect(tsUnionOf("never", "never")).toBe("never"); + }); + test("don't add parenthesis around a single element from a de-duped union", () => { + expect(tsUnionOf("number & number", "number & number")).toBe("number & number"); }); });