Commit 55dd075
committed
fix: make grant_types optional in OpenIdConnectApplicationSettingsClient
Rebased onto master after v6.1.0 openapi spec regeneration.
The Okta API does not require grant_types when creating an OIDC
application client — it defaults to [authorization_code]. The
generated Go SDK incorrectly marks grant_types as a required property,
which forces callers to supply an empty array just to satisfy the
constructor signature and triggers a JSON unmarshal error on responses
where grant_types isn't present.
This change:
- Removes the required: [grant_types] entry from the two source
OpenAPI spec files (.generator/*.yaml and okta/api/openapi.yaml)
- Regenerates the affected Go model:
- GrantTypes json tag gains omitempty
- NewOpenIdConnectApplicationSettingsClient no longer takes a
grantTypes parameter
- GetGrantTypes/GetGrantTypesOk handle nil GrantTypes
- UnmarshalJSON drops the requiredProperties check for grant_types
- ToMap skips grant_types when nil1 parent 59e763d commit 55dd075
File tree
5 files changed
+12
-38
lines changed- .generator
- okta
- api
- docs
5 files changed
+12
-38
lines changedLines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44553 | 44553 | | |
44554 | 44554 | | |
44555 | 44555 | | |
44556 | | - | |
44557 | | - | |
44558 | 44556 | | |
44559 | 44557 | | |
44560 | 44558 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
549 | 549 | | |
550 | 550 | | |
551 | 551 | | |
552 | | - | |
| 552 | + | |
553 | 553 | | |
554 | 554 | | |
555 | 555 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70077 | 70077 | | |
70078 | 70078 | | |
70079 | 70079 | | |
70080 | | - | |
70081 | | - | |
70082 | 70080 | | |
70083 | 70081 | | |
70084 | 70082 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
41 | | - | |
| 41 | + | |
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| |||
Lines changed: 9 additions & 31 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
29 | 28 | | |
30 | 29 | | |
31 | 30 | | |
| |||
51 | 50 | | |
52 | 51 | | |
53 | 52 | | |
54 | | - | |
| 53 | + | |
55 | 54 | | |
56 | 55 | | |
57 | 56 | | |
| |||
95 | 94 | | |
96 | 95 | | |
97 | 96 | | |
98 | | - | |
| 97 | + | |
99 | 98 | | |
100 | 99 | | |
101 | 100 | | |
102 | 101 | | |
103 | 102 | | |
104 | | - | |
105 | 103 | | |
106 | 104 | | |
107 | 105 | | |
| |||
405 | 403 | | |
406 | 404 | | |
407 | 405 | | |
408 | | - | |
| 406 | + | |
409 | 407 | | |
410 | | - | |
| 408 | + | |
411 | 409 | | |
412 | 410 | | |
413 | 411 | | |
414 | | - | |
415 | 412 | | |
416 | 413 | | |
417 | 414 | | |
418 | | - | |
| 415 | + | |
419 | 416 | | |
420 | 417 | | |
421 | | - | |
| 418 | + | |
422 | 419 | | |
423 | 420 | | |
424 | 421 | | |
| |||
1074 | 1071 | | |
1075 | 1072 | | |
1076 | 1073 | | |
1077 | | - | |
| 1074 | + | |
| 1075 | + | |
| 1076 | + | |
1078 | 1077 | | |
1079 | 1078 | | |
1080 | 1079 | | |
| |||
1141 | 1140 | | |
1142 | 1141 | | |
1143 | 1142 | | |
1144 | | - | |
1145 | | - | |
1146 | | - | |
1147 | | - | |
1148 | | - | |
1149 | | - | |
1150 | | - | |
1151 | | - | |
1152 | | - | |
1153 | | - | |
1154 | | - | |
1155 | | - | |
1156 | | - | |
1157 | | - | |
1158 | | - | |
1159 | | - | |
1160 | | - | |
1161 | | - | |
1162 | | - | |
1163 | | - | |
1164 | | - | |
1165 | 1143 | | |
1166 | 1144 | | |
1167 | 1145 | | |
| |||
0 commit comments