Skip to content

Commit 59835d2

Browse files
Commit via running ake Sources/code-scanning
1 parent 661f545 commit 59835d2

File tree

2 files changed

+47
-1
lines changed

2 files changed

+47
-1
lines changed

Sources/code-scanning/Client.swift

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,13 @@ public struct Client: APIProtocol {
292292
name: "ref",
293293
value: input.query.ref
294294
)
295+
try converter.setQueryItemAsURI(
296+
in: &request,
297+
style: .form,
298+
explode: true,
299+
name: "pr",
300+
value: input.query.pr
301+
)
295302
try converter.setQueryItemAsURI(
296303
in: &request,
297304
style: .form,
@@ -755,6 +762,13 @@ public struct Client: APIProtocol {
755762
name: "ref",
756763
value: input.query.ref
757764
)
765+
try converter.setQueryItemAsURI(
766+
in: &request,
767+
style: .form,
768+
explode: true,
769+
name: "pr",
770+
value: input.query.pr
771+
)
758772
converter.setAcceptHeader(
759773
in: &request.headerFields,
760774
contentTypes: input.headers.accept
@@ -928,6 +942,13 @@ public struct Client: APIProtocol {
928942
name: "per_page",
929943
value: input.query.per_page
930944
)
945+
try converter.setQueryItemAsURI(
946+
in: &request,
947+
style: .form,
948+
explode: true,
949+
name: "pr",
950+
value: input.query.pr
951+
)
931952
try converter.setQueryItemAsURI(
932953
in: &request,
933954
style: .form,

Sources/code-scanning/Types.swift

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3296,6 +3296,10 @@ public enum Components {
32963296
///
32973297
/// - Remark: Generated from `#/components/parameters/git-ref`.
32983298
public typealias git_hyphen_ref = Components.Schemas.code_hyphen_scanning_hyphen_ref
3299+
/// The number of the pull request for the results you want to list.
3300+
///
3301+
/// - Remark: Generated from `#/components/parameters/pr-alias`.
3302+
public typealias pr_hyphen_alias = Swift.Int
32993303
/// The number that identifies an alert. You can find this at the end of the URL for a code scanning alert within GitHub, and in the `number` field in the response from the `GET /repos/{owner}/{repo}/code-scanning/alerts` operation.
33003304
///
33013305
/// - Remark: Generated from `#/components/parameters/alert-number`.
@@ -3899,6 +3903,10 @@ public enum Operations {
38993903
///
39003904
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/alerts/GET/query/ref`.
39013905
public var ref: Components.Parameters.git_hyphen_ref?
3906+
/// The number of the pull request for the results you want to list.
3907+
///
3908+
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/alerts/GET/query/pr`.
3909+
public var pr: Components.Parameters.pr_hyphen_alias?
39023910
/// - Remark: Generated from `#/components/parameters/direction`.
39033911
@frozen public enum direction: String, Codable, Hashable, Sendable {
39043912
case asc = "asc"
@@ -3933,6 +3941,7 @@ public enum Operations {
39333941
/// - page: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
39343942
/// - per_page: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
39353943
/// - ref: The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/<branch name>` or simply `<branch name>`. To reference a pull request use `refs/pull/<number>/merge`.
3944+
/// - pr: The number of the pull request for the results you want to list.
39363945
/// - direction: The direction to sort the results by.
39373946
/// - sort: The property by which to sort the results.
39383947
/// - state: If specified, only code scanning alerts with this state will be returned.
@@ -3943,6 +3952,7 @@ public enum Operations {
39433952
page: Components.Parameters.page? = nil,
39443953
per_page: Components.Parameters.per_hyphen_page? = nil,
39453954
ref: Components.Parameters.git_hyphen_ref? = nil,
3955+
pr: Components.Parameters.pr_hyphen_alias? = nil,
39463956
direction: Components.Parameters.direction? = nil,
39473957
sort: Operations.code_hyphen_scanning_sol_list_hyphen_alerts_hyphen_for_hyphen_repo.Input.Query.sortPayload? = nil,
39483958
state: Components.Schemas.code_hyphen_scanning_hyphen_alert_hyphen_state_hyphen_query? = nil,
@@ -3953,6 +3963,7 @@ public enum Operations {
39533963
self.page = page
39543964
self.per_page = per_page
39553965
self.ref = ref
3966+
self.pr = pr
39563967
self.direction = direction
39573968
self.sort = sort
39583969
self.state = state
@@ -4717,20 +4728,27 @@ public enum Operations {
47174728
///
47184729
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances/GET/query/ref`.
47194730
public var ref: Components.Parameters.git_hyphen_ref?
4731+
/// The number of the pull request for the results you want to list.
4732+
///
4733+
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/alerts/{alert_number}/instances/GET/query/pr`.
4734+
public var pr: Components.Parameters.pr_hyphen_alias?
47204735
/// Creates a new `Query`.
47214736
///
47224737
/// - Parameters:
47234738
/// - page: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
47244739
/// - per_page: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
47254740
/// - ref: The Git reference for the results you want to list. The `ref` for a branch can be formatted either as `refs/heads/<branch name>` or simply `<branch name>`. To reference a pull request use `refs/pull/<number>/merge`.
4741+
/// - pr: The number of the pull request for the results you want to list.
47264742
public init(
47274743
page: Components.Parameters.page? = nil,
47284744
per_page: Components.Parameters.per_hyphen_page? = nil,
4729-
ref: Components.Parameters.git_hyphen_ref? = nil
4745+
ref: Components.Parameters.git_hyphen_ref? = nil,
4746+
pr: Components.Parameters.pr_hyphen_alias? = nil
47304747
) {
47314748
self.page = page
47324749
self.per_page = per_page
47334750
self.ref = ref
4751+
self.pr = pr
47344752
}
47354753
}
47364754
public var query: Operations.code_hyphen_scanning_sol_list_hyphen_alert_hyphen_instances.Input.Query
@@ -4979,6 +4997,10 @@ public enum Operations {
49794997
///
49804998
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/analyses/GET/query/per_page`.
49814999
public var per_page: Components.Parameters.per_hyphen_page?
5000+
/// The number of the pull request for the results you want to list.
5001+
///
5002+
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/analyses/GET/query/pr`.
5003+
public var pr: Components.Parameters.pr_hyphen_alias?
49825004
/// The Git reference for the analyses you want to list. The `ref` for a branch can be formatted either as `refs/heads/<branch name>` or simply `<branch name>`. To reference a pull request use `refs/pull/<number>/merge`.
49835005
///
49845006
/// - Remark: Generated from `#/paths/repos/{owner}/{repo}/code-scanning/analyses/GET/query/ref`.
@@ -5011,6 +5033,7 @@ public enum Operations {
50115033
/// - tool_guid: The GUID of a code scanning tool. Only results by this tool will be listed. Note that some code scanning tools may not include a GUID in their analysis data. You can specify the tool by using either `tool_guid` or `tool_name`, but not both.
50125034
/// - page: The page number of the results to fetch. For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
50135035
/// - per_page: The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/rest/using-the-rest-api/using-pagination-in-the-rest-api)."
5036+
/// - pr: The number of the pull request for the results you want to list.
50145037
/// - ref: The Git reference for the analyses you want to list. The `ref` for a branch can be formatted either as `refs/heads/<branch name>` or simply `<branch name>`. To reference a pull request use `refs/pull/<number>/merge`.
50155038
/// - sarif_id: Filter analyses belonging to the same SARIF upload.
50165039
/// - direction: The direction to sort the results by.
@@ -5020,6 +5043,7 @@ public enum Operations {
50205043
tool_guid: Components.Parameters.tool_hyphen_guid? = nil,
50215044
page: Components.Parameters.page? = nil,
50225045
per_page: Components.Parameters.per_hyphen_page? = nil,
5046+
pr: Components.Parameters.pr_hyphen_alias? = nil,
50235047
ref: Components.Schemas.code_hyphen_scanning_hyphen_ref? = nil,
50245048
sarif_id: Components.Schemas.code_hyphen_scanning_hyphen_analysis_hyphen_sarif_hyphen_id? = nil,
50255049
direction: Components.Parameters.direction? = nil,
@@ -5029,6 +5053,7 @@ public enum Operations {
50295053
self.tool_guid = tool_guid
50305054
self.page = page
50315055
self.per_page = per_page
5056+
self.pr = pr
50325057
self.ref = ref
50335058
self.sarif_id = sarif_id
50345059
self.direction = direction

0 commit comments

Comments
 (0)