From f631a850e6100b499fbadbb5663277f5e8de1c3e Mon Sep 17 00:00:00 2001 From: mjspi Date: Mon, 6 Nov 2023 13:25:23 -0600 Subject: [PATCH 1/4] Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. --- verify/.openapi-generator/FILES | 2 + verify/CHANGELOG.md | 4 + verify/README.md | 1 + verify/api/openapi.yaml | 16 +++ verify/docs/EnumInspectionType.md | 15 +++ verify/docs/GovernmentIdConfiguration.md | 26 +++++ verify/generate/pingone-verify.yml | 7 ++ verify/model_enum_inspection_type.go | 114 ++++++++++++++++++++ verify/model_government_id_configuration.go | 36 +++++++ 9 files changed, 221 insertions(+) create mode 100644 verify/docs/EnumInspectionType.md create mode 100644 verify/model_enum_inspection_type.go diff --git a/verify/.openapi-generator/FILES b/verify/.openapi-generator/FILES index 3ba442ce..c5225a96 100644 --- a/verify/.openapi-generator/FILES +++ b/verify/.openapi-generator/FILES @@ -6,6 +6,7 @@ api_voice_phrases.go configuration.go docs/EntityArray.md docs/EntityArrayEmbedded.md +docs/EnumInspectionType.md docs/EnumThreshold.md docs/EnumTimeUnit.md docs/EnumVerify.md @@ -46,6 +47,7 @@ go.mod go.sum model_entity_array.go model_entity_array__embedded.go +model_enum_inspection_type.go model_enum_threshold.go model_enum_time_unit.go model_enum_verify.go diff --git a/verify/CHANGELOG.md b/verify/CHANGELOG.md index 5d5e97b0..f861df5a 100644 --- a/verify/CHANGELOG.md +++ b/verify/CHANGELOG.md @@ -1,3 +1,7 @@ +# v0.4.0 (2023-11-06) + +* **Enhancement** Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. [#275](https://github.com/patrickcping/pingone-go-sdk-v2/pull/275) + # v0.3.1 (2023-10-16) * **Note** Unskip read only attributes when converting API models to maps. [#255](https://github.com/patrickcping/pingone-go-sdk-v2/pull/255) diff --git a/verify/README.md b/verify/README.md index b98a517a..a51cc880 100644 --- a/verify/README.md +++ b/verify/README.md @@ -98,6 +98,7 @@ Class | Method | HTTP request | Description - [EntityArray](docs/EntityArray.md) - [EntityArrayEmbedded](docs/EntityArrayEmbedded.md) + - [EnumInspectionType](docs/EnumInspectionType.md) - [EnumThreshold](docs/EnumThreshold.md) - [EnumTimeUnit](docs/EnumTimeUnit.md) - [EnumVerify](docs/EnumVerify.md) diff --git a/verify/api/openapi.yaml b/verify/api/openapi.yaml index f2a4f6da..95945ca3 100644 --- a/verify/api/openapi.yaml +++ b/verify/api/openapi.yaml @@ -1275,6 +1275,7 @@ components: duration: 2 timeUnit: null governmentId: + inspectionType: null verify: null updatedAt: 2000-01-23T04:56:07.000+00:00 - voice: @@ -1354,6 +1355,7 @@ components: duration: 2 timeUnit: null governmentId: + inspectionType: null verify: null updatedAt: 2000-01-23T04:56:07.000+00:00 voicePhrases: @@ -1377,6 +1379,14 @@ components: size: type: number type: object + EnumInspectionType: + description: "A string that defines the mechanism used to authenticate a `governmentId`\ + \ document. Options are `AUTOMATIC`, `MANUAL`, or `STEP_UP`." + enum: + - AUTOMATIC + - MANUAL + - STEP_UP + type: string EnumTimeUnit: description: A string that defines the time unit of a specified duration in `SECONDS` or `MINUTES`. @@ -1415,8 +1425,11 @@ components: type: object GovernmentIdConfiguration: example: + inspectionType: null verify: null properties: + inspectionType: + $ref: '#/components/schemas/EnumInspectionType' verify: $ref: '#/components/schemas/EnumVerify' required: @@ -1741,6 +1754,7 @@ components: duration: 2 timeUnit: null governmentId: + inspectionType: null verify: null updatedAt: 2000-01-23T04:56:07.000+00:00 properties: @@ -1907,6 +1921,7 @@ components: duration: 2 timeUnit: null governmentId: + inspectionType: null verify: null updatedAt: 2000-01-23T04:56:07.000+00:00 - voice: @@ -1986,6 +2001,7 @@ components: duration: 2 timeUnit: null governmentId: + inspectionType: null verify: null updatedAt: 2000-01-23T04:56:07.000+00:00 voicePhrases: diff --git a/verify/docs/EnumInspectionType.md b/verify/docs/EnumInspectionType.md new file mode 100644 index 00000000..9b9e9de1 --- /dev/null +++ b/verify/docs/EnumInspectionType.md @@ -0,0 +1,15 @@ +# EnumInspectionType + +## Enum + + +* `AUTOMATIC` (value: `"AUTOMATIC"`) + +* `MANUAL` (value: `"MANUAL"`) + +* `STEP_UP` (value: `"STEP_UP"`) + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/verify/docs/GovernmentIdConfiguration.md b/verify/docs/GovernmentIdConfiguration.md index c4e09d75..13d6f1f3 100644 --- a/verify/docs/GovernmentIdConfiguration.md +++ b/verify/docs/GovernmentIdConfiguration.md @@ -4,6 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**InspectionType** | Pointer to [**EnumInspectionType**](EnumInspectionType.md) | | [optional] **Verify** | [**EnumVerify**](EnumVerify.md) | | ## Methods @@ -25,6 +26,31 @@ NewGovernmentIdConfigurationWithDefaults instantiates a new GovernmentIdConfigur This constructor will only assign default values to properties that have it defined, but it doesn't guarantee that properties required by API are set +### GetInspectionType + +`func (o *GovernmentIdConfiguration) GetInspectionType() EnumInspectionType` + +GetInspectionType returns the InspectionType field if non-nil, zero value otherwise. + +### GetInspectionTypeOk + +`func (o *GovernmentIdConfiguration) GetInspectionTypeOk() (*EnumInspectionType, bool)` + +GetInspectionTypeOk returns a tuple with the InspectionType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetInspectionType + +`func (o *GovernmentIdConfiguration) SetInspectionType(v EnumInspectionType)` + +SetInspectionType sets InspectionType field to given value. + +### HasInspectionType + +`func (o *GovernmentIdConfiguration) HasInspectionType() bool` + +HasInspectionType returns a boolean if a field has been set. + ### GetVerify `func (o *GovernmentIdConfiguration) GetVerify() EnumVerify` diff --git a/verify/generate/pingone-verify.yml b/verify/generate/pingone-verify.yml index 29b2bdb9..643e58c2 100644 --- a/verify/generate/pingone-verify.yml +++ b/verify/generate/pingone-verify.yml @@ -79,6 +79,10 @@ components: $ref: '#/components/schemas/VoicePhraseContents' size: type: number + EnumInspectionType: + type: string + enum: [AUTOMATIC, MANUAL, STEP_UP] + description: A string that defines the mechanism used to authenticate a `governmentId` document. Options are `AUTOMATIC`, `MANUAL`, or `STEP_UP`. EnumTimeUnit: type: string enum: [SECONDS, MINUTES] @@ -106,6 +110,9 @@ components: GovernmentIdConfiguration: type: object properties: + inspectionType: + $ref: '#/components/schemas/EnumInspectionType' + description: Determines whether document authentication is automated, manual, or a combination of both where manual authentication is performed if automated inspection fails. Can be AUTOMATIC, MANUAL, or STEP_UP. verify: $ref: '#/components/schemas/EnumVerify' description: Controls if Government ID verification is REQUIRED, OPTIONAL, or DISABLED. diff --git a/verify/model_enum_inspection_type.go b/verify/model_enum_inspection_type.go new file mode 100644 index 00000000..4061f3e6 --- /dev/null +++ b/verify/model_enum_inspection_type.go @@ -0,0 +1,114 @@ +/* +PingOne Platform API - PingOne Verify + +The PingOne Platform API covering the PingOne Verify service + +API version: 2023-07-20 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package verify + +import ( + "encoding/json" + "fmt" +) + +// EnumInspectionType A string that defines the mechanism used to authenticate a `governmentId` document. Options are `AUTOMATIC`, `MANUAL`, or `STEP_UP`. +type EnumInspectionType string + +// List of EnumInspectionType +const ( + ENUMINSPECTIONTYPE_AUTOMATIC EnumInspectionType = "AUTOMATIC" + ENUMINSPECTIONTYPE_MANUAL EnumInspectionType = "MANUAL" + ENUMINSPECTIONTYPE_STEP_UP EnumInspectionType = "STEP_UP" +) + +// All allowed values of EnumInspectionType enum +var AllowedEnumInspectionTypeEnumValues = []EnumInspectionType{ + "AUTOMATIC", + "MANUAL", + "STEP_UP", +} + +func (v *EnumInspectionType) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := EnumInspectionType(value) + for _, existing := range AllowedEnumInspectionTypeEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + *v = EnumInspectionType(fmt.Sprintf("%s", "UNKNOWN")) + return nil +} + +// NewEnumInspectionTypeFromValue returns a pointer to a valid EnumInspectionType +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewEnumInspectionTypeFromValue(v string) (*EnumInspectionType, error) { + ev := EnumInspectionType(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for EnumInspectionType: valid values are %v", v, AllowedEnumInspectionTypeEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v EnumInspectionType) IsValid() bool { + for _, existing := range AllowedEnumInspectionTypeEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to EnumInspectionType value +func (v EnumInspectionType) Ptr() *EnumInspectionType { + return &v +} + +type NullableEnumInspectionType struct { + value *EnumInspectionType + isSet bool +} + +func (v NullableEnumInspectionType) Get() *EnumInspectionType { + return v.value +} + +func (v *NullableEnumInspectionType) Set(val *EnumInspectionType) { + v.value = val + v.isSet = true +} + +func (v NullableEnumInspectionType) IsSet() bool { + return v.isSet +} + +func (v *NullableEnumInspectionType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableEnumInspectionType(val *EnumInspectionType) *NullableEnumInspectionType { + return &NullableEnumInspectionType{value: val, isSet: true} +} + +func (v NullableEnumInspectionType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableEnumInspectionType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + diff --git a/verify/model_government_id_configuration.go b/verify/model_government_id_configuration.go index f0928b47..aa1f749e 100644 --- a/verify/model_government_id_configuration.go +++ b/verify/model_government_id_configuration.go @@ -19,6 +19,7 @@ var _ MappedNullable = &GovernmentIdConfiguration{} // GovernmentIdConfiguration struct for GovernmentIdConfiguration type GovernmentIdConfiguration struct { + InspectionType *EnumInspectionType `json:"inspectionType,omitempty"` Verify EnumVerify `json:"verify"` } @@ -40,6 +41,38 @@ func NewGovernmentIdConfigurationWithDefaults() *GovernmentIdConfiguration { return &this } +// GetInspectionType returns the InspectionType field value if set, zero value otherwise. +func (o *GovernmentIdConfiguration) GetInspectionType() EnumInspectionType { + if o == nil || IsNil(o.InspectionType) { + var ret EnumInspectionType + return ret + } + return *o.InspectionType +} + +// GetInspectionTypeOk returns a tuple with the InspectionType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GovernmentIdConfiguration) GetInspectionTypeOk() (*EnumInspectionType, bool) { + if o == nil || IsNil(o.InspectionType) { + return nil, false + } + return o.InspectionType, true +} + +// HasInspectionType returns a boolean if a field has been set. +func (o *GovernmentIdConfiguration) HasInspectionType() bool { + if o != nil && !IsNil(o.InspectionType) { + return true + } + + return false +} + +// SetInspectionType gets a reference to the given EnumInspectionType and assigns it to the InspectionType field. +func (o *GovernmentIdConfiguration) SetInspectionType(v EnumInspectionType) { + o.InspectionType = &v +} + // GetVerify returns the Verify field value func (o *GovernmentIdConfiguration) GetVerify() EnumVerify { if o == nil { @@ -74,6 +107,9 @@ func (o GovernmentIdConfiguration) MarshalJSON() ([]byte, error) { func (o GovernmentIdConfiguration) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} + if !IsNil(o.InspectionType) { + toSerialize["inspectionType"] = o.InspectionType + } toSerialize["verify"] = o.Verify return toSerialize, nil } From cf7c15adfdafb83507b6fcdb223650108c21506d Mon Sep 17 00:00:00 2001 From: mjspi Date: Mon, 6 Nov 2023 13:27:05 -0600 Subject: [PATCH 2/4] Updated changelog. --- verify/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/verify/CHANGELOG.md b/verify/CHANGELOG.md index f861df5a..603a9fb3 100644 --- a/verify/CHANGELOG.md +++ b/verify/CHANGELOG.md @@ -1,6 +1,6 @@ # v0.4.0 (2023-11-06) -* **Enhancement** Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. [#275](https://github.com/patrickcping/pingone-go-sdk-v2/pull/275) +* **Enhancement** Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. [#278](https://github.com/patrickcping/pingone-go-sdk-v2/pull/278) # v0.3.1 (2023-10-16) From f669065053bde72797a92ef412f564c530eb5408 Mon Sep 17 00:00:00 2001 From: Patrick Cowland Date: Tue, 7 Nov 2023 09:46:21 +0000 Subject: [PATCH 3/4] changelogs --- CHANGELOG.md | 5 +++++ verify/CHANGELOG.md | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 25b63695..60104f42 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +# Release (Unreleased) + +* `github.com/patrickcping/pingone-go-sdk-v2/verify` : [v0.4.0](./verify/CHANGELOG.md) + * **Enhancement** Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. [#278](https://github.com/patrickcping/pingone-go-sdk-v2/pull/278) + # Release (2023-11-01) * `github.com/patrickcping/pingone-go-sdk-v2` : v0.10.9 diff --git a/verify/CHANGELOG.md b/verify/CHANGELOG.md index 603a9fb3..2e6e8210 100644 --- a/verify/CHANGELOG.md +++ b/verify/CHANGELOG.md @@ -1,4 +1,4 @@ -# v0.4.0 (2023-11-06) +# v0.4.0 (Unreleased) * **Enhancement** Added the `InspectionType` property to the `GovernmentIdConfiguration` object model. [#278](https://github.com/patrickcping/pingone-go-sdk-v2/pull/278) From f09d1bad3f038802c191cef355f21c706bb7485a Mon Sep 17 00:00:00 2001 From: Patrick Cowland Date: Tue, 7 Nov 2023 09:46:38 +0000 Subject: [PATCH 4/4] bump `verify` module version --- verify/.version | 2 +- verify/README.md | 2 +- verify/configuration.go | 2 +- verify/go.mod | 2 +- verify/go.sum | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/verify/.version b/verify/.version index a2268e2d..60a2d3e9 100644 --- a/verify/.version +++ b/verify/.version @@ -1 +1 @@ -0.3.1 \ No newline at end of file +0.4.0 \ No newline at end of file diff --git a/verify/README.md b/verify/README.md index a51cc880..65311cd7 100644 --- a/verify/README.md +++ b/verify/README.md @@ -6,7 +6,7 @@ The PingOne Platform API covering the PingOne Verify service This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. - API version: 2023-07-20 -- Package version: 0.3.1 +- Package version: 0.4.0 - Build package: org.openapitools.codegen.languages.GoClientCodegen ## Installation diff --git a/verify/configuration.go b/verify/configuration.go index 4ffb5419..70edd155 100644 --- a/verify/configuration.go +++ b/verify/configuration.go @@ -91,7 +91,7 @@ type Configuration struct { func NewConfiguration() *Configuration { cfg := &Configuration{ DefaultHeader: make(map[string]string), - UserAgent: "pingtools PingOne-GOLANG-SDK (verify)/0.3.1 go", + UserAgent: "pingtools PingOne-GOLANG-SDK (verify)/0.4.0 go", Debug: false, DefaultServerIndex: 0, Servers: ServerConfigurations{ diff --git a/verify/go.mod b/verify/go.mod index 2eb0e0a4..b34ac2bf 100644 --- a/verify/go.mod +++ b/verify/go.mod @@ -2,4 +2,4 @@ module github.com/patrickcping/pingone-go-sdk-v2/verify go 1.18 -require golang.org/x/exp v0.0.0-20230905200255-921286631fa9 +require golang.org/x/exp v0.0.0-20231006140011-7918f672742d diff --git a/verify/go.sum b/verify/go.sum index fa6da3f7..9a43984a 100644 --- a/verify/go.sum +++ b/verify/go.sum @@ -1,2 +1,2 @@ -golang.org/x/exp v0.0.0-20230905200255-921286631fa9 h1:GoHiUyI/Tp2nVkLI2mCxVkOjsbSXD66ic0XW0js0R9g= -golang.org/x/exp v0.0.0-20230905200255-921286631fa9/go.mod h1:S2oDrQGGwySpoQPVqRShND87VCbxmc6bL1Yd2oYrm6k= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d h1:jtJma62tbqLibJ5sFQz8bKtEM8rJBtfilJ2qTU199MI= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d/go.mod h1:ldy0pHrwJyGW56pPQzzkH36rKxoZW1tw7ZJpeKx+hdo=