Skip to content

Commit 99ac21b

Browse files
authored
fix: Generate CloudQuery Go API Client from spec.json (#178)
This PR was created by a scheduled workflow to generate the CloudQuery Go API Client from `spec.json`
1 parent fd9a4ef commit 99ac21b

File tree

3 files changed

+186
-5
lines changed

3 files changed

+186
-5
lines changed

client.gen.go

Lines changed: 34 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

models.gen.go

Lines changed: 53 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spec.json

Lines changed: 99 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5080,7 +5080,18 @@
50805080
"description" : "Filter connectors by a given type.",
50815081
"explode" : true,
50825082
"in" : "query",
5083-
"name" : "type",
5083+
"name" : "filter_type",
5084+
"required" : false,
5085+
"schema" : {
5086+
"type" : "string"
5087+
},
5088+
"style" : "form"
5089+
}, {
5090+
"description" : "Filter connectors by a given plugin reference. Mutually exclusive with `type`.",
5091+
"example" : "cloudquery/source/googleanalytics",
5092+
"explode" : true,
5093+
"in" : "query",
5094+
"name" : "filter_plugin",
50845095
"required" : false,
50855096
"schema" : {
50865097
"type" : "string"
@@ -5098,6 +5109,9 @@
50985109
},
50995110
"description" : "Response"
51005111
},
5112+
"400" : {
5113+
"$ref" : "#/components/responses/BadRequest"
5114+
},
51015115
"401" : {
51025116
"$ref" : "#/components/responses/RequiresAuthentication"
51035117
},
@@ -5290,6 +5304,9 @@
52905304
"401" : {
52915305
"$ref" : "#/components/responses/RequiresAuthentication"
52925306
},
5307+
"403" : {
5308+
"$ref" : "#/components/responses/Forbidden"
5309+
},
52935310
"404" : {
52945311
"$ref" : "#/components/responses/NotFound"
52955312
},
@@ -8388,6 +8405,20 @@
83888405
},
83898406
"required" : [ "access_key_id", "can_expire", "expires", "secret_access_key", "session_token", "source" ]
83908407
},
8408+
"ConnectorCredentialsResponseOAuth" : {
8409+
"additionalProperties" : false,
8410+
"description" : "OAuth connector credentials response",
8411+
"properties" : {
8412+
"access_token" : {
8413+
"type" : "string"
8414+
},
8415+
"expires" : {
8416+
"format" : "date-time",
8417+
"type" : "string"
8418+
}
8419+
},
8420+
"required" : [ "access_token" ]
8421+
},
83918422
"ManagedDatabaseID" : {
83928423
"description" : "The identifier for the managed database",
83938424
"example" : "12345678-1234-1234-1234-1234567890ab",
@@ -8521,6 +8552,34 @@
85218552
},
85228553
"required" : [ "plugin_kind", "plugin_name", "plugin_team" ]
85238554
},
8555+
"ConnectorAuthRequestOAuth" : {
8556+
"additionalProperties" : false,
8557+
"description" : "OAuth connector authentication request to start the authentication process",
8558+
"properties" : {
8559+
"plugin_team" : {
8560+
"description" : "Team that owns the plugin we are authenticating the connector for",
8561+
"example" : "cloudquery",
8562+
"type" : "string"
8563+
},
8564+
"plugin_kind" : {
8565+
"description" : "Kind of the plugin",
8566+
"example" : "source",
8567+
"type" : "string"
8568+
},
8569+
"plugin_name" : {
8570+
"description" : "Name of the plugin",
8571+
"example" : "googleanalytics",
8572+
"type" : "string"
8573+
},
8574+
"base_url" : {
8575+
"description" : "Base of the URL the callback url will be constructed from",
8576+
"example" : "https://cloud.cloudquery.io/oauth",
8577+
"type" : "string",
8578+
"x-go-name" : "BaseURL"
8579+
}
8580+
},
8581+
"required" : [ "base_url", "plugin_kind", "plugin_name", "plugin_team" ]
8582+
},
85248583
"ConnectorAuthResponseAWS" : {
85258584
"additionalProperties" : false,
85268585
"description" : "AWS connector authentication response to start the authentication process",
@@ -8551,6 +8610,18 @@
85518610
},
85528611
"required" : [ "redirect_url", "role_template_url", "suggested_external_id", "suggested_policy_arns" ]
85538612
},
8613+
"ConnectorAuthResponseOAuth" : {
8614+
"additionalProperties" : false,
8615+
"description" : "OAuth connector authentication response to start the authentication process",
8616+
"properties" : {
8617+
"redirect_url" : {
8618+
"description" : "URL to redirect the user to, to authenticate",
8619+
"type" : "string",
8620+
"x-go-name" : "RedirectURL"
8621+
}
8622+
},
8623+
"required" : [ "redirect_url" ]
8624+
},
85548625
"ConnectorAuthFinishRequestAWS" : {
85558626
"additionalProperties" : false,
85568627
"description" : "AWS connector authentication request, filled in after the user has authenticated through AWS",
@@ -8568,6 +8639,21 @@
85688639
},
85698640
"required" : [ "role_arn" ]
85708641
},
8642+
"ConnectorAuthFinishRequestOAuth" : {
8643+
"additionalProperties" : false,
8644+
"description" : "OAuth connector authentication request, filled in after the user has authenticated through OAuth",
8645+
"properties" : {
8646+
"auth_code" : {
8647+
"description" : "Auth code received from the OAuth provider",
8648+
"type" : "string"
8649+
},
8650+
"state" : {
8651+
"description" : "State value received from the OAuth provider",
8652+
"type" : "string"
8653+
}
8654+
},
8655+
"required" : [ "auth_code" ]
8656+
},
85718657
"ListPluginNotificationRequests_200_response" : {
85728658
"properties" : {
85738659
"items" : {
@@ -9304,6 +9390,9 @@
93049390
"properties" : {
93059391
"aws" : {
93069392
"$ref" : "#/components/schemas/ConnectorCredentialsResponseAWS"
9393+
},
9394+
"oauth" : {
9395+
"$ref" : "#/components/schemas/ConnectorCredentialsResponseOAuth"
93079396
}
93089397
}
93099398
},
@@ -9357,20 +9446,29 @@
93579446
"properties" : {
93589447
"aws" : {
93599448
"$ref" : "#/components/schemas/ConnectorAuthRequestAWS"
9449+
},
9450+
"oauth" : {
9451+
"$ref" : "#/components/schemas/ConnectorAuthRequestOAuth"
93609452
}
93619453
}
93629454
},
93639455
"AuthenticateConnector_200_response" : {
93649456
"properties" : {
93659457
"aws" : {
93669458
"$ref" : "#/components/schemas/ConnectorAuthResponseAWS"
9459+
},
9460+
"oauth" : {
9461+
"$ref" : "#/components/schemas/ConnectorAuthResponseOAuth"
93679462
}
93689463
}
93699464
},
93709465
"AuthenticateConnectorFinish_request" : {
93719466
"properties" : {
93729467
"aws" : {
93739468
"$ref" : "#/components/schemas/ConnectorAuthFinishRequestAWS"
9469+
},
9470+
"oauth" : {
9471+
"$ref" : "#/components/schemas/ConnectorAuthFinishRequestOAuth"
93749472
}
93759473
}
93769474
},

0 commit comments

Comments
 (0)