From 380d8607c08ca9bfe60b959cfb00566ed702995a Mon Sep 17 00:00:00 2001 From: mjspi Date: Wed, 1 May 2024 10:00:25 -0500 Subject: [PATCH] Added support for new credential type properties. Minor defect fix. --- credentials/.openapi-generator/FILES | 4 + credentials/.version | 2 +- credentials/README.md | 4 +- credentials/api/openapi.yaml | 34 +++- credentials/configuration.go | 2 +- credentials/docs/CredentialType.md | 36 +++- credentials/docs/CredentialTypeManagement.md | 56 ++++++ .../docs/CredentialTypeMetaDataFieldsInner.md | 26 +++ .../docs/EntityArrayEmbeddedItemsInner.md | 36 +++- .../docs/EnumCredentialTypeManagementMode.md | 13 ++ credentials/generate/pingone-credentials.yml | 16 +- credentials/go.mod | 8 - credentials/go.sum | 10 -- credentials/model_credential_type.go | 50 +++++- .../model_credential_type_management.go | 126 +++++++++++++ ..._credential_type_meta_data_fields_inner.go | 37 ++++ ...el_enum_credential_type_management_mode.go | 112 ++++++++++++ .../api_credential_issuance_rules_test.go | 166 ------------------ .../test/api_credential_issuers_test.go | 67 ------- credentials/test/api_credential_types_test.go | 98 ----------- .../test/api_digital_wallet_apps_test.go | 97 ---------- credentials/test/api_digital_wallets_test.go | 118 ------------- credentials/test/api_user_credentials_test.go | 104 ----------- 23 files changed, 531 insertions(+), 691 deletions(-) create mode 100644 credentials/docs/CredentialTypeManagement.md create mode 100644 credentials/docs/EnumCredentialTypeManagementMode.md create mode 100644 credentials/model_credential_type_management.go create mode 100644 credentials/model_enum_credential_type_management_mode.go delete mode 100644 credentials/test/api_credential_issuance_rules_test.go delete mode 100644 credentials/test/api_credential_issuers_test.go delete mode 100644 credentials/test/api_credential_types_test.go delete mode 100644 credentials/test/api_digital_wallet_apps_test.go delete mode 100644 credentials/test/api_digital_wallets_test.go delete mode 100644 credentials/test/api_user_credentials_test.go diff --git a/credentials/.openapi-generator/FILES b/credentials/.openapi-generator/FILES index a7a9d56a..d6154bf9 100644 --- a/credentials/.openapi-generator/FILES +++ b/credentials/.openapi-generator/FILES @@ -40,6 +40,7 @@ docs/CredentialIssuerProfile.md docs/CredentialIssuerProfileApplicationInstance.md docs/CredentialIssuersApi.md docs/CredentialType.md +docs/CredentialTypeManagement.md docs/CredentialTypeMetaData.md docs/CredentialTypeMetaDataFieldsInner.md docs/CredentialTypeMultiple.md @@ -56,6 +57,7 @@ docs/EnumCredentialIssuanceRuleAutomationMethod.md docs/EnumCredentialIssuanceRuleNotificationMethod.md docs/EnumCredentialIssuanceRuleStagedChangeAction.md docs/EnumCredentialIssuanceRuleStatus.md +docs/EnumCredentialTypeManagementMode.md docs/EnumCredentialTypeMetaDataFieldsFileSupport.md docs/EnumCredentialTypeMetaDataFieldsType.md docs/LinksHATEOAS.md @@ -110,6 +112,7 @@ model_credential_issuance_rule_usage_inner_user.go model_credential_issuer_profile.go model_credential_issuer_profile_application_instance.go model_credential_type.go +model_credential_type_management.go model_credential_type_meta_data.go model_credential_type_meta_data_fields_inner.go model_credential_type_multiple.go @@ -123,6 +126,7 @@ model_enum_credential_issuance_rule_automation_method.go model_enum_credential_issuance_rule_notification_method.go model_enum_credential_issuance_rule_staged_change_action.go model_enum_credential_issuance_rule_status.go +model_enum_credential_type_management_mode.go model_enum_credential_type_meta_data_fields_file_support.go model_enum_credential_type_meta_data_fields_type.go model_links_hateoas.go diff --git a/credentials/.version b/credentials/.version index b1d7abc0..a0a15177 100644 --- a/credentials/.version +++ b/credentials/.version @@ -1 +1 @@ -0.6.2 \ No newline at end of file +0.6.3 \ No newline at end of file diff --git a/credentials/README.md b/credentials/README.md index 90d69401..1908bc43 100644 --- a/credentials/README.md +++ b/credentials/README.md @@ -6,7 +6,7 @@ The PingOne Platform API covering the PingOne Credentials 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-06-29 -- Package version: 0.6.2 +- Package version: 0.6.3 - Build package: org.openapitools.codegen.languages.GoClientCodegen ## Installation @@ -145,6 +145,7 @@ Class | Method | HTTP request | Description - [CredentialIssuerProfile](docs/CredentialIssuerProfile.md) - [CredentialIssuerProfileApplicationInstance](docs/CredentialIssuerProfileApplicationInstance.md) - [CredentialType](docs/CredentialType.md) + - [CredentialTypeManagement](docs/CredentialTypeManagement.md) - [CredentialTypeMetaData](docs/CredentialTypeMetaData.md) - [CredentialTypeMetaDataFieldsInner](docs/CredentialTypeMetaDataFieldsInner.md) - [CredentialTypeMultiple](docs/CredentialTypeMultiple.md) @@ -158,6 +159,7 @@ Class | Method | HTTP request | Description - [EnumCredentialIssuanceRuleNotificationMethod](docs/EnumCredentialIssuanceRuleNotificationMethod.md) - [EnumCredentialIssuanceRuleStagedChangeAction](docs/EnumCredentialIssuanceRuleStagedChangeAction.md) - [EnumCredentialIssuanceRuleStatus](docs/EnumCredentialIssuanceRuleStatus.md) + - [EnumCredentialTypeManagementMode](docs/EnumCredentialTypeManagementMode.md) - [EnumCredentialTypeMetaDataFieldsFileSupport](docs/EnumCredentialTypeMetaDataFieldsFileSupport.md) - [EnumCredentialTypeMetaDataFieldsType](docs/EnumCredentialTypeMetaDataFieldsType.md) - [LinksHATEOAS](docs/LinksHATEOAS.md) diff --git a/credentials/api/openapi.yaml b/credentials/api/openapi.yaml index 989670da..3e8e3080 100644 --- a/credentials/api/openapi.yaml +++ b/credentials/api/openapi.yaml @@ -2539,6 +2539,13 @@ components: description: The URI of the resource. format: uri type: string + EnumCredentialTypeManagementMode: + description: Specifies the mechanism used to manage the lifecycle of the credential + type. + enum: + - AUTOMATED + - MANAGED + type: string EnumCredentialTypeMetaDataFieldsFileSupport: description: | Specifies the type of data in the defined field within a credential type: @@ -2675,6 +2682,7 @@ components: title: title type: null value: value + required: true - default: default attribute: attribute id: id @@ -2683,6 +2691,7 @@ components: title: title type: null value: value + required: true textColor: textColor version: 1 properties: @@ -2745,6 +2754,7 @@ components: title: title type: null value: value + required: true - default: default attribute: attribute id: id @@ -2753,6 +2763,7 @@ components: title: title type: null value: value + required: true textColor: textColor version: 1 _links: @@ -2771,9 +2782,11 @@ components: createdAt: 2000-01-23T04:56:07.000+00:00 onDelete: revokeIssuedCredentials: true - deletedAt: deletedAt + deletedAt: 2000-01-23T04:56:07.000+00:00 environment: id: id + management: + mode: null cardDesignTemplate: cardDesignTemplate id: id updatedAt: 2000-01-23T04:56:07.000+00:00 @@ -2800,6 +2813,8 @@ components: deletedAt: description: A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a "soft delete". + format: date-time + readOnly: true type: string environment: $ref: '#/components/schemas/ObjectEnvironment' @@ -2811,8 +2826,11 @@ components: issuer: $ref: '#/components/schemas/ObjectIssuer' issuerName: - description: "v issuer name associated with the card, can differ from title." + description: "A string that specifies the issuer name associated with the\ + \ card, can differ from title." type: string + management: + $ref: '#/components/schemas/CredentialType_management' metadata: $ref: '#/components/schemas/CredentialTypeMetaData' multiple: @@ -3817,6 +3835,7 @@ components: title: title type: null value: value + required: true properties: attribute: description: A string that specifies the name of the PingOne Directory attribute @@ -3835,6 +3854,10 @@ components: description: A boolean value that specifies whether the field should be visible to viewers of the credential. type: boolean + required: + description: A boolean value that specifies whether the field is required + for the credential. + type: boolean title: description: A string that specifies the descriptive text when showing the field. @@ -3851,6 +3874,13 @@ components: - title - type type: object + CredentialType_management: + example: + mode: null + properties: + mode: + $ref: '#/components/schemas/EnumCredentialTypeManagementMode' + type: object CredentialType_multiple: description: An object containing directives that enable the issuance of multiple credentials to a user based on a directory attribute. diff --git a/credentials/configuration.go b/credentials/configuration.go index 7d54ed7d..0659c814 100644 --- a/credentials/configuration.go +++ b/credentials/configuration.go @@ -91,7 +91,7 @@ type Configuration struct { func NewConfiguration() *Configuration { cfg := &Configuration{ DefaultHeader: make(map[string]string), - UserAgent: "pingtools PingOne-GOLANG-SDK-credentials/0.6.2", + UserAgent: "pingtools PingOne-GOLANG-SDK-credentials/0.6.3", Debug: false, DefaultServerIndex: 0, Servers: ServerConfigurations{ diff --git a/credentials/docs/CredentialType.md b/credentials/docs/CredentialType.md index ce0c5459..e0f41303 100644 --- a/credentials/docs/CredentialType.md +++ b/credentials/docs/CredentialType.md @@ -9,11 +9,12 @@ Name | Type | Description | Notes **CardType** | Pointer to **string** | A string that specifies the descriptor of the credential type. Can be non-identity types such as proof of employment or proof of insurance. | [optional] **CreatedAt** | Pointer to **time.Time** | A string that specifies the date and time the credential type was created. | [optional] [readonly] **Description** | Pointer to **string** | A string that specifies the description of the credential type. | [optional] -**DeletedAt** | Pointer to **string** | A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a \"soft delete\". | [optional] +**DeletedAt** | Pointer to **time.Time** | A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a \"soft delete\". | [optional] [readonly] **Environment** | Pointer to [**ObjectEnvironment**](ObjectEnvironment.md) | | [optional] **Id** | Pointer to **string** | A string that specifies the identifier (UUID) associated with the credential type. | [optional] [readonly] **Issuer** | Pointer to [**ObjectIssuer**](ObjectIssuer.md) | | [optional] -**IssuerName** | Pointer to **string** | v issuer name associated with the card, can differ from title. | [optional] +**IssuerName** | Pointer to **string** | A string that specifies the issuer name associated with the card, can differ from title. | [optional] +**Management** | Pointer to [**CredentialTypeManagement**](CredentialTypeManagement.md) | | [optional] **Metadata** | [**CredentialTypeMetaData**](CredentialTypeMetaData.md) | | **Multiple** | Pointer to [**CredentialTypeMultiple**](CredentialTypeMultiple.md) | | [optional] **OnDelete** | Pointer to [**CredentialTypeOnDelete**](CredentialTypeOnDelete.md) | | [optional] @@ -161,20 +162,20 @@ HasDescription returns a boolean if a field has been set. ### GetDeletedAt -`func (o *CredentialType) GetDeletedAt() string` +`func (o *CredentialType) GetDeletedAt() time.Time` GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. ### GetDeletedAtOk -`func (o *CredentialType) GetDeletedAtOk() (*string, bool)` +`func (o *CredentialType) GetDeletedAtOk() (*time.Time, bool)` GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise and a boolean to check if the value has been set. ### SetDeletedAt -`func (o *CredentialType) SetDeletedAt(v string)` +`func (o *CredentialType) SetDeletedAt(v time.Time)` SetDeletedAt sets DeletedAt field to given value. @@ -284,6 +285,31 @@ SetIssuerName sets IssuerName field to given value. HasIssuerName returns a boolean if a field has been set. +### GetManagement + +`func (o *CredentialType) GetManagement() CredentialTypeManagement` + +GetManagement returns the Management field if non-nil, zero value otherwise. + +### GetManagementOk + +`func (o *CredentialType) GetManagementOk() (*CredentialTypeManagement, bool)` + +GetManagementOk returns a tuple with the Management field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetManagement + +`func (o *CredentialType) SetManagement(v CredentialTypeManagement)` + +SetManagement sets Management field to given value. + +### HasManagement + +`func (o *CredentialType) HasManagement() bool` + +HasManagement returns a boolean if a field has been set. + ### GetMetadata `func (o *CredentialType) GetMetadata() CredentialTypeMetaData` diff --git a/credentials/docs/CredentialTypeManagement.md b/credentials/docs/CredentialTypeManagement.md new file mode 100644 index 00000000..ae80e4ba --- /dev/null +++ b/credentials/docs/CredentialTypeManagement.md @@ -0,0 +1,56 @@ +# CredentialTypeManagement + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Mode** | Pointer to [**EnumCredentialTypeManagementMode**](EnumCredentialTypeManagementMode.md) | | [optional] + +## Methods + +### NewCredentialTypeManagement + +`func NewCredentialTypeManagement() *CredentialTypeManagement` + +NewCredentialTypeManagement instantiates a new CredentialTypeManagement object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewCredentialTypeManagementWithDefaults + +`func NewCredentialTypeManagementWithDefaults() *CredentialTypeManagement` + +NewCredentialTypeManagementWithDefaults instantiates a new CredentialTypeManagement object +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 + +### GetMode + +`func (o *CredentialTypeManagement) GetMode() EnumCredentialTypeManagementMode` + +GetMode returns the Mode field if non-nil, zero value otherwise. + +### GetModeOk + +`func (o *CredentialTypeManagement) GetModeOk() (*EnumCredentialTypeManagementMode, bool)` + +GetModeOk returns a tuple with the Mode field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMode + +`func (o *CredentialTypeManagement) SetMode(v EnumCredentialTypeManagementMode)` + +SetMode sets Mode field to given value. + +### HasMode + +`func (o *CredentialTypeManagement) HasMode() bool` + +HasMode returns a boolean if a field has been set. + + +[[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/credentials/docs/CredentialTypeMetaDataFieldsInner.md b/credentials/docs/CredentialTypeMetaDataFieldsInner.md index 0c5ede3b..ce7aee2b 100644 --- a/credentials/docs/CredentialTypeMetaDataFieldsInner.md +++ b/credentials/docs/CredentialTypeMetaDataFieldsInner.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **Id** | **string** | A string that specifies the identifier of the field. | **FileSupport** | Pointer to [**EnumCredentialTypeMetaDataFieldsFileSupport**](EnumCredentialTypeMetaDataFieldsFileSupport.md) | | [optional] **IsVisible** | **bool** | A boolean value that specifies whether the field should be visible to viewers of the credential. | +**Required** | Pointer to **bool** | A boolean value that specifies whether the field is required for the credential. | [optional] **Title** | **string** | A string that specifies the descriptive text when showing the field. | **Type** | [**EnumCredentialTypeMetaDataFieldsType**](EnumCredentialTypeMetaDataFieldsType.md) | | **Value** | Pointer to **string** | A string that specifies the text to appear on the credential for a type of Alphanumeric Text. | [optional] @@ -147,6 +148,31 @@ and a boolean to check if the value has been set. SetIsVisible sets IsVisible field to given value. +### GetRequired + +`func (o *CredentialTypeMetaDataFieldsInner) GetRequired() bool` + +GetRequired returns the Required field if non-nil, zero value otherwise. + +### GetRequiredOk + +`func (o *CredentialTypeMetaDataFieldsInner) GetRequiredOk() (*bool, bool)` + +GetRequiredOk returns a tuple with the Required field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetRequired + +`func (o *CredentialTypeMetaDataFieldsInner) SetRequired(v bool)` + +SetRequired sets Required field to given value. + +### HasRequired + +`func (o *CredentialTypeMetaDataFieldsInner) HasRequired() bool` + +HasRequired returns a boolean if a field has been set. + ### GetTitle `func (o *CredentialTypeMetaDataFieldsInner) GetTitle() string` diff --git a/credentials/docs/EntityArrayEmbeddedItemsInner.md b/credentials/docs/EntityArrayEmbeddedItemsInner.md index 1351d6d4..6a0c6816 100644 --- a/credentials/docs/EntityArrayEmbeddedItemsInner.md +++ b/credentials/docs/EntityArrayEmbeddedItemsInner.md @@ -9,11 +9,12 @@ Name | Type | Description | Notes **CardType** | Pointer to **string** | A string that specifies the descriptor of the credential type. Can be non-identity types such as proof of employment or proof of insurance. | [optional] **CreatedAt** | Pointer to **time.Time** | | [optional] [readonly] **Description** | Pointer to **string** | A string that specifies the description of the credential type. | [optional] -**DeletedAt** | Pointer to **string** | A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a \"soft delete\". | [optional] +**DeletedAt** | Pointer to **time.Time** | A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a \"soft delete\". | [optional] [readonly] **Environment** | Pointer to [**ObjectEnvironment**](ObjectEnvironment.md) | | [optional] **Id** | Pointer to **string** | | [optional] **Issuer** | Pointer to [**ObjectIssuer**](ObjectIssuer.md) | | [optional] -**IssuerName** | Pointer to **string** | v issuer name associated with the card, can differ from title. | [optional] +**IssuerName** | Pointer to **string** | A string that specifies the issuer name associated with the card, can differ from title. | [optional] +**Management** | Pointer to [**CredentialTypeManagement**](CredentialTypeManagement.md) | | [optional] **Metadata** | [**CredentialTypeMetaData**](CredentialTypeMetaData.md) | | **Multiple** | Pointer to [**CredentialTypeMultiple**](CredentialTypeMultiple.md) | | [optional] **OnDelete** | Pointer to [**CredentialTypeOnDelete**](CredentialTypeOnDelete.md) | | [optional] @@ -167,20 +168,20 @@ HasDescription returns a boolean if a field has been set. ### GetDeletedAt -`func (o *EntityArrayEmbeddedItemsInner) GetDeletedAt() string` +`func (o *EntityArrayEmbeddedItemsInner) GetDeletedAt() time.Time` GetDeletedAt returns the DeletedAt field if non-nil, zero value otherwise. ### GetDeletedAtOk -`func (o *EntityArrayEmbeddedItemsInner) GetDeletedAtOk() (*string, bool)` +`func (o *EntityArrayEmbeddedItemsInner) GetDeletedAtOk() (*time.Time, bool)` GetDeletedAtOk returns a tuple with the DeletedAt field if it's non-nil, zero value otherwise and a boolean to check if the value has been set. ### SetDeletedAt -`func (o *EntityArrayEmbeddedItemsInner) SetDeletedAt(v string)` +`func (o *EntityArrayEmbeddedItemsInner) SetDeletedAt(v time.Time)` SetDeletedAt sets DeletedAt field to given value. @@ -290,6 +291,31 @@ SetIssuerName sets IssuerName field to given value. HasIssuerName returns a boolean if a field has been set. +### GetManagement + +`func (o *EntityArrayEmbeddedItemsInner) GetManagement() CredentialTypeManagement` + +GetManagement returns the Management field if non-nil, zero value otherwise. + +### GetManagementOk + +`func (o *EntityArrayEmbeddedItemsInner) GetManagementOk() (*CredentialTypeManagement, bool)` + +GetManagementOk returns a tuple with the Management field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetManagement + +`func (o *EntityArrayEmbeddedItemsInner) SetManagement(v CredentialTypeManagement)` + +SetManagement sets Management field to given value. + +### HasManagement + +`func (o *EntityArrayEmbeddedItemsInner) HasManagement() bool` + +HasManagement returns a boolean if a field has been set. + ### GetMetadata `func (o *EntityArrayEmbeddedItemsInner) GetMetadata() CredentialTypeMetaData` diff --git a/credentials/docs/EnumCredentialTypeManagementMode.md b/credentials/docs/EnumCredentialTypeManagementMode.md new file mode 100644 index 00000000..05507592 --- /dev/null +++ b/credentials/docs/EnumCredentialTypeManagementMode.md @@ -0,0 +1,13 @@ +# EnumCredentialTypeManagementMode + +## Enum + + +* `AUTOMATED` (value: `"AUTOMATED"`) + +* `MANAGED` (value: `"MANAGED"`) + + +[[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/credentials/generate/pingone-credentials.yml b/credentials/generate/pingone-credentials.yml index 43f9e8dd..b9745479 100644 --- a/credentials/generate/pingone-credentials.yml +++ b/credentials/generate/pingone-credentials.yml @@ -57,6 +57,10 @@ components: type: string format: uri description: The URI of the resource. + EnumCredentialTypeManagementMode: + type: string + enum: [AUTOMATED, MANAGED] + description: Specifies the mechanism used to manage the lifecycle of the credential type. EnumCredentialTypeMetaDataFieldsFileSupport: type: string enum: [BASE64_STRING, INCLUDE_FILE, REFERENCE_FILE] @@ -173,6 +177,9 @@ components: isVisible: type: boolean description: A boolean value that specifies whether the field should be visible to viewers of the credential. + required: + type: boolean + description: A boolean value that specifies whether the field is required for the credential. title: type: string description: A string that specifies the descriptive text when showing the field. @@ -219,6 +226,8 @@ components: description: A string that specifies the description of the credential type. deletedAt: type: string + format: date-time + readOnly: true description: A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a "soft delete". environment: $ref: '#/components/schemas/ObjectEnvironment' @@ -230,7 +239,12 @@ components: $ref: '#/components/schemas/ObjectIssuer' issuerName: type: string - description: v issuer name associated with the card, can differ from title. + description: A string that specifies the issuer name associated with the card, can differ from title. + management: + type: object + properties: + mode: + $ref: '#/components/schemas/EnumCredentialTypeManagementMode' metadata: $ref: '#/components/schemas/CredentialTypeMetaData' multiple: diff --git a/credentials/go.mod b/credentials/go.mod index b6fcf5f8..1a24c9fb 100644 --- a/credentials/go.mod +++ b/credentials/go.mod @@ -1,11 +1,3 @@ module github.com/patrickcping/pingone-go-sdk-v2/credentials go 1.21 - -require github.com/stretchr/testify v1.8.4 - -require ( - github.com/davecgh/go-spew v1.1.1 // indirect - github.com/pmezard/go-difflib v1.0.0 // indirect - gopkg.in/yaml.v3 v3.0.1 // indirect -) diff --git a/credentials/go.sum b/credentials/go.sum index fa4b6e68..e69de29b 100644 --- a/credentials/go.sum +++ b/credentials/go.sum @@ -1,10 +0,0 @@ -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= -gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/credentials/model_credential_type.go b/credentials/model_credential_type.go index 673ccfd3..6da62efe 100644 --- a/credentials/model_credential_type.go +++ b/credentials/model_credential_type.go @@ -30,13 +30,14 @@ type CredentialType struct { // A string that specifies the description of the credential type. Description *string `json:"description,omitempty"` // A string that specifies the date and time the credential type was deleted. Note - a deletion of a credential type is a \"soft delete\". - DeletedAt *string `json:"deletedAt,omitempty"` + DeletedAt *time.Time `json:"deletedAt,omitempty"` Environment *ObjectEnvironment `json:"environment,omitempty"` // A string that specifies the identifier (UUID) associated with the credential type. Id *string `json:"id,omitempty"` Issuer *ObjectIssuer `json:"issuer,omitempty"` - // v issuer name associated with the card, can differ from title. + // A string that specifies the issuer name associated with the card, can differ from title. IssuerName *string `json:"issuerName,omitempty"` + Management *CredentialTypeManagement `json:"management,omitempty"` Metadata CredentialTypeMetaData `json:"metadata"` Multiple *CredentialTypeMultiple `json:"multiple,omitempty"` OnDelete *CredentialTypeOnDelete `json:"onDelete,omitempty"` @@ -219,9 +220,9 @@ func (o *CredentialType) SetDescription(v string) { } // GetDeletedAt returns the DeletedAt field value if set, zero value otherwise. -func (o *CredentialType) GetDeletedAt() string { +func (o *CredentialType) GetDeletedAt() time.Time { if o == nil || IsNil(o.DeletedAt) { - var ret string + var ret time.Time return ret } return *o.DeletedAt @@ -229,7 +230,7 @@ func (o *CredentialType) GetDeletedAt() string { // GetDeletedAtOk returns a tuple with the DeletedAt field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CredentialType) GetDeletedAtOk() (*string, bool) { +func (o *CredentialType) GetDeletedAtOk() (*time.Time, bool) { if o == nil || IsNil(o.DeletedAt) { return nil, false } @@ -245,8 +246,8 @@ func (o *CredentialType) HasDeletedAt() bool { return false } -// SetDeletedAt gets a reference to the given string and assigns it to the DeletedAt field. -func (o *CredentialType) SetDeletedAt(v string) { +// SetDeletedAt gets a reference to the given time.Time and assigns it to the DeletedAt field. +func (o *CredentialType) SetDeletedAt(v time.Time) { o.DeletedAt = &v } @@ -378,6 +379,38 @@ func (o *CredentialType) SetIssuerName(v string) { o.IssuerName = &v } +// GetManagement returns the Management field value if set, zero value otherwise. +func (o *CredentialType) GetManagement() CredentialTypeManagement { + if o == nil || IsNil(o.Management) { + var ret CredentialTypeManagement + return ret + } + return *o.Management +} + +// GetManagementOk returns a tuple with the Management field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialType) GetManagementOk() (*CredentialTypeManagement, bool) { + if o == nil || IsNil(o.Management) { + return nil, false + } + return o.Management, true +} + +// HasManagement returns a boolean if a field has been set. +func (o *CredentialType) HasManagement() bool { + if o != nil && !IsNil(o.Management) { + return true + } + + return false +} + +// SetManagement gets a reference to the given CredentialTypeManagement and assigns it to the Management field. +func (o *CredentialType) SetManagement(v CredentialTypeManagement) { + o.Management = &v +} + // GetMetadata returns the Metadata field value func (o *CredentialType) GetMetadata() CredentialTypeMetaData { if o == nil { @@ -560,6 +593,9 @@ func (o CredentialType) ToMap() (map[string]interface{}, error) { if !IsNil(o.IssuerName) { toSerialize["issuerName"] = o.IssuerName } + if !IsNil(o.Management) { + toSerialize["management"] = o.Management + } toSerialize["metadata"] = o.Metadata if !IsNil(o.Multiple) { toSerialize["multiple"] = o.Multiple diff --git a/credentials/model_credential_type_management.go b/credentials/model_credential_type_management.go new file mode 100644 index 00000000..fc9dd061 --- /dev/null +++ b/credentials/model_credential_type_management.go @@ -0,0 +1,126 @@ +/* +PingOne Platform API - Credentials + +The PingOne Platform API covering the PingOne Credentials service + +API version: 2023-06-29 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package credentials + +import ( + "encoding/json" +) + +// checks if the CredentialTypeManagement type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CredentialTypeManagement{} + +// CredentialTypeManagement struct for CredentialTypeManagement +type CredentialTypeManagement struct { + Mode *EnumCredentialTypeManagementMode `json:"mode,omitempty"` +} + +// NewCredentialTypeManagement instantiates a new CredentialTypeManagement object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCredentialTypeManagement() *CredentialTypeManagement { + this := CredentialTypeManagement{} + return &this +} + +// NewCredentialTypeManagementWithDefaults instantiates a new CredentialTypeManagement object +// 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 +func NewCredentialTypeManagementWithDefaults() *CredentialTypeManagement { + this := CredentialTypeManagement{} + return &this +} + +// GetMode returns the Mode field value if set, zero value otherwise. +func (o *CredentialTypeManagement) GetMode() EnumCredentialTypeManagementMode { + if o == nil || IsNil(o.Mode) { + var ret EnumCredentialTypeManagementMode + return ret + } + return *o.Mode +} + +// GetModeOk returns a tuple with the Mode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialTypeManagement) GetModeOk() (*EnumCredentialTypeManagementMode, bool) { + if o == nil || IsNil(o.Mode) { + return nil, false + } + return o.Mode, true +} + +// HasMode returns a boolean if a field has been set. +func (o *CredentialTypeManagement) HasMode() bool { + if o != nil && !IsNil(o.Mode) { + return true + } + + return false +} + +// SetMode gets a reference to the given EnumCredentialTypeManagementMode and assigns it to the Mode field. +func (o *CredentialTypeManagement) SetMode(v EnumCredentialTypeManagementMode) { + o.Mode = &v +} + +func (o CredentialTypeManagement) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CredentialTypeManagement) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Mode) { + toSerialize["mode"] = o.Mode + } + return toSerialize, nil +} + +type NullableCredentialTypeManagement struct { + value *CredentialTypeManagement + isSet bool +} + +func (v NullableCredentialTypeManagement) Get() *CredentialTypeManagement { + return v.value +} + +func (v *NullableCredentialTypeManagement) Set(val *CredentialTypeManagement) { + v.value = val + v.isSet = true +} + +func (v NullableCredentialTypeManagement) IsSet() bool { + return v.isSet +} + +func (v *NullableCredentialTypeManagement) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCredentialTypeManagement(val *CredentialTypeManagement) *NullableCredentialTypeManagement { + return &NullableCredentialTypeManagement{value: val, isSet: true} +} + +func (v NullableCredentialTypeManagement) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCredentialTypeManagement) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/credentials/model_credential_type_meta_data_fields_inner.go b/credentials/model_credential_type_meta_data_fields_inner.go index 11abb47d..6cf16eda 100644 --- a/credentials/model_credential_type_meta_data_fields_inner.go +++ b/credentials/model_credential_type_meta_data_fields_inner.go @@ -28,6 +28,8 @@ type CredentialTypeMetaDataFieldsInner struct { FileSupport *EnumCredentialTypeMetaDataFieldsFileSupport `json:"fileSupport,omitempty"` // A boolean value that specifies whether the field should be visible to viewers of the credential. IsVisible bool `json:"isVisible"` + // A boolean value that specifies whether the field is required for the credential. + Required *bool `json:"required,omitempty"` // A string that specifies the descriptive text when showing the field. Title string `json:"title"` Type EnumCredentialTypeMetaDataFieldsType `json:"type"` @@ -200,6 +202,38 @@ func (o *CredentialTypeMetaDataFieldsInner) SetIsVisible(v bool) { o.IsVisible = v } +// GetRequired returns the Required field value if set, zero value otherwise. +func (o *CredentialTypeMetaDataFieldsInner) GetRequired() bool { + if o == nil || IsNil(o.Required) { + var ret bool + return ret + } + return *o.Required +} + +// GetRequiredOk returns a tuple with the Required field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CredentialTypeMetaDataFieldsInner) GetRequiredOk() (*bool, bool) { + if o == nil || IsNil(o.Required) { + return nil, false + } + return o.Required, true +} + +// HasRequired returns a boolean if a field has been set. +func (o *CredentialTypeMetaDataFieldsInner) HasRequired() bool { + if o != nil && !IsNil(o.Required) { + return true + } + + return false +} + +// SetRequired gets a reference to the given bool and assigns it to the Required field. +func (o *CredentialTypeMetaDataFieldsInner) SetRequired(v bool) { + o.Required = &v +} + // GetTitle returns the Title field value func (o *CredentialTypeMetaDataFieldsInner) GetTitle() string { if o == nil { @@ -301,6 +335,9 @@ func (o CredentialTypeMetaDataFieldsInner) ToMap() (map[string]interface{}, erro toSerialize["fileSupport"] = o.FileSupport } toSerialize["isVisible"] = o.IsVisible + if !IsNil(o.Required) { + toSerialize["required"] = o.Required + } toSerialize["title"] = o.Title toSerialize["type"] = o.Type if !IsNil(o.Value) { diff --git a/credentials/model_enum_credential_type_management_mode.go b/credentials/model_enum_credential_type_management_mode.go new file mode 100644 index 00000000..19357555 --- /dev/null +++ b/credentials/model_enum_credential_type_management_mode.go @@ -0,0 +1,112 @@ +/* +PingOne Platform API - Credentials + +The PingOne Platform API covering the PingOne Credentials service + +API version: 2023-06-29 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package credentials + +import ( + "encoding/json" + "fmt" +) + +// EnumCredentialTypeManagementMode Specifies the mechanism used to manage the lifecycle of the credential type. +type EnumCredentialTypeManagementMode string + +// List of EnumCredentialTypeManagementMode +const ( + ENUMCREDENTIALTYPEMANAGEMENTMODE_AUTOMATED EnumCredentialTypeManagementMode = "AUTOMATED" + ENUMCREDENTIALTYPEMANAGEMENTMODE_MANAGED EnumCredentialTypeManagementMode = "MANAGED" +) + +// All allowed values of EnumCredentialTypeManagementMode enum +var AllowedEnumCredentialTypeManagementModeEnumValues = []EnumCredentialTypeManagementMode{ + "AUTOMATED", + "MANAGED", +} + +func (v *EnumCredentialTypeManagementMode) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := EnumCredentialTypeManagementMode(value) + for _, existing := range AllowedEnumCredentialTypeManagementModeEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + *v = EnumCredentialTypeManagementMode(fmt.Sprintf("%s", "UNKNOWN")) + return nil +} + +// NewEnumCredentialTypeManagementModeFromValue returns a pointer to a valid EnumCredentialTypeManagementMode +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewEnumCredentialTypeManagementModeFromValue(v string) (*EnumCredentialTypeManagementMode, error) { + ev := EnumCredentialTypeManagementMode(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for EnumCredentialTypeManagementMode: valid values are %v", v, AllowedEnumCredentialTypeManagementModeEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v EnumCredentialTypeManagementMode) IsValid() bool { + for _, existing := range AllowedEnumCredentialTypeManagementModeEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to EnumCredentialTypeManagementMode value +func (v EnumCredentialTypeManagementMode) Ptr() *EnumCredentialTypeManagementMode { + return &v +} + +type NullableEnumCredentialTypeManagementMode struct { + value *EnumCredentialTypeManagementMode + isSet bool +} + +func (v NullableEnumCredentialTypeManagementMode) Get() *EnumCredentialTypeManagementMode { + return v.value +} + +func (v *NullableEnumCredentialTypeManagementMode) Set(val *EnumCredentialTypeManagementMode) { + v.value = val + v.isSet = true +} + +func (v NullableEnumCredentialTypeManagementMode) IsSet() bool { + return v.isSet +} + +func (v *NullableEnumCredentialTypeManagementMode) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableEnumCredentialTypeManagementMode(val *EnumCredentialTypeManagementMode) *NullableEnumCredentialTypeManagementMode { + return &NullableEnumCredentialTypeManagementMode{value: val, isSet: true} +} + +func (v NullableEnumCredentialTypeManagementMode) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableEnumCredentialTypeManagementMode) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + diff --git a/credentials/test/api_credential_issuance_rules_test.go b/credentials/test/api_credential_issuance_rules_test.go deleted file mode 100644 index 67530f25..00000000 --- a/credentials/test/api_credential_issuance_rules_test.go +++ /dev/null @@ -1,166 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing CredentialIssuanceRulesApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "testing" -) - -func Test_credentials_CredentialIssuanceRulesApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test CredentialIssuanceRulesApiService ApplyCredentialIssuanceRuleStagedChanges", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ApplyCredentialIssuanceRuleStagedChanges(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService CreateCredentialIssuanceRule", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.CreateCredentialIssuanceRule(context.Background(), environmentID, credentialTypeID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService DeleteCredentialIssuanceRule", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - httpRes, err := apiClient.CredentialIssuanceRulesApi.DeleteCredentialIssuanceRule(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService ReadAllCredentialIssuanceRules", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ReadAllCredentialIssuanceRules(context.Background(), environmentID, credentialTypeID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService ReadCredentialIssuanceRuleStagedChanges", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ReadCredentialIssuanceRuleStagedChanges(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService ReadCredentialIssuanceRuleUsageCounts", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ReadCredentialIssuanceRuleUsageCounts(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService ReadCredentialIssuanceRuleUsageDetails", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ReadCredentialIssuanceRuleUsageDetails(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService ReadOneCredentialIssuanceRule", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.ReadOneCredentialIssuanceRule(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuanceRulesApiService UpdateCredentialIssuanceRule", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - var credentialIssuanceRuleID string - - resp, httpRes, err := apiClient.CredentialIssuanceRulesApi.UpdateCredentialIssuanceRule(context.Background(), environmentID, credentialTypeID, credentialIssuanceRuleID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -} diff --git a/credentials/test/api_credential_issuers_test.go b/credentials/test/api_credential_issuers_test.go deleted file mode 100644 index a775e79c..00000000 --- a/credentials/test/api_credential_issuers_test.go +++ /dev/null @@ -1,67 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing CredentialIssuersApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "testing" -) - -func Test_credentials_CredentialIssuersApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test CredentialIssuersApiService CreateCredentialIssuerProfile", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.CredentialIssuersApi.CreateCredentialIssuerProfile(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuersApiService ReadCredentialIssuerProfile", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.CredentialIssuersApi.ReadCredentialIssuerProfile(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialIssuersApiService UpdateCredentialIssuerProfile", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.CredentialIssuersApi.UpdateCredentialIssuerProfile(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -} diff --git a/credentials/test/api_credential_types_test.go b/credentials/test/api_credential_types_test.go deleted file mode 100644 index 385a471d..00000000 --- a/credentials/test/api_credential_types_test.go +++ /dev/null @@ -1,98 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing CredentialTypesApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - "testing" - - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func Test_credentials_CredentialTypesApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test CredentialTypesApiService CreateCredentialType", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.CredentialTypesApi.CreateCredentialType(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialTypesApiService DeleteACredentialType", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - - httpRes, err := apiClient.CredentialTypesApi.DeleteCredentialType(context.Background(), environmentID, credentialTypeID).Execute() - - require.Nil(t, err) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialTypesApiService ReadAllCredentialTypes", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.CredentialTypesApi.ReadAllCredentialTypes(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialTypesApiService ReadOneCredentialType", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - - resp, httpRes, err := apiClient.CredentialTypesApi.ReadOneCredentialType(context.Background(), environmentID, credentialTypeID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test CredentialTypesApiService UpdateACredentialType", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var credentialTypeID string - - resp, httpRes, err := apiClient.CredentialTypesApi.UpdateCredentialType(context.Background(), environmentID, credentialTypeID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -} diff --git a/credentials/test/api_digital_wallet_apps_test.go b/credentials/test/api_digital_wallet_apps_test.go deleted file mode 100644 index 0eaed88b..00000000 --- a/credentials/test/api_digital_wallet_apps_test.go +++ /dev/null @@ -1,97 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing DigitalWalletAppsApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "testing" -) - -func Test_credentials_DigitalWalletAppsApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test DigitalWalletAppsApiService CreateDigitalWalletApp", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.DigitalWalletAppsApi.CreateDigitalWalletApp(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletAppsApiService DeleteDigitalWalletApp", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var digitalWalletApplicationID string - - httpRes, err := apiClient.DigitalWalletAppsApi.DeleteDigitalWalletApp(context.Background(), environmentID, digitalWalletApplicationID).Execute() - - require.Nil(t, err) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletAppsApiService ReadAllDigitalWalletApps", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - - resp, httpRes, err := apiClient.DigitalWalletAppsApi.ReadAllDigitalWalletApps(context.Background(), environmentID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletAppsApiService ReadOneDigitalWalletApp", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var digitalWalletApplicationID string - - resp, httpRes, err := apiClient.DigitalWalletAppsApi.ReadOneDigitalWalletApp(context.Background(), environmentID, digitalWalletApplicationID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletAppsApiService UpdateDigitalWalletApp", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var digitalWalletApplicationID string - - resp, httpRes, err := apiClient.DigitalWalletAppsApi.UpdateDigitalWalletApp(context.Background(), environmentID, digitalWalletApplicationID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -} diff --git a/credentials/test/api_digital_wallets_test.go b/credentials/test/api_digital_wallets_test.go deleted file mode 100644 index d63a547a..00000000 --- a/credentials/test/api_digital_wallets_test.go +++ /dev/null @@ -1,118 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing DigitalWalletsApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - "testing" -) - -func Test_credentials_DigitalWalletsApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test DigitalWalletsApiService CreateDigitalWallet", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - - resp, httpRes, err := apiClient.DigitalWalletsApi.CreateDigitalWallet(context.Background(), environmentID, userID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletsApiService DeleteDigitalWallet", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var digitalWalletID string - - httpRes, err := apiClient.DigitalWalletsApi.DeleteDigitalWallet(context.Background(), environmentID, userID, digitalWalletID).Execute() - - require.Nil(t, err) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletsApiService ReadAllDigitalWallets", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - - resp, httpRes, err := apiClient.DigitalWalletsApi.ReadAllDigitalWallets(context.Background(), environmentID, userID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletsApiService ReadOneDigitalWallet", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var digitalWalletID string - - resp, httpRes, err := apiClient.DigitalWalletsApi.ReadOneDigitalWallet(context.Background(), environmentID, userID, digitalWalletID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletsApiService ReadOneDigitalWalletCredential", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var digitalWalletID string - - resp, httpRes, err := apiClient.DigitalWalletsApi.ReadOneDigitalWalletCredential(context.Background(), environmentID, userID, digitalWalletID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test DigitalWalletsApiService UpdateDigitalWallet", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var digitalWalletID string - - resp, httpRes, err := apiClient.DigitalWalletsApi.UpdateDigitalWallet(context.Background(), environmentID, userID, digitalWalletID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -} diff --git a/credentials/test/api_user_credentials_test.go b/credentials/test/api_user_credentials_test.go deleted file mode 100644 index f6038556..00000000 --- a/credentials/test/api_user_credentials_test.go +++ /dev/null @@ -1,104 +0,0 @@ -/* -PingOne Platform API - Credentials - -Testing UserCredentialsApiService - -*/ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); - -package credentials - -import ( - "context" - "testing" - - openapiclient "github.com/patrickcping/pingone-go-sdk-v2/credentials" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" -) - -func Test_credentials_UserCredentialsApiService(t *testing.T) { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - - t.Run("Test UserCredentialsApiService CreateAUserCredential", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - - resp, httpRes, err := apiClient.UserCredentialsApi.CreateAUserCredential(context.Background(), environmentID, userID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test UserCredentialsApiService ReadAllUserCredentials", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - - resp, httpRes, err := apiClient.UserCredentialsApi.ReadAllUserCredentials(context.Background(), environmentID, userID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test UserCredentialsApiService ReadOneUserCredential", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var credentialID string - - resp, httpRes, err := apiClient.UserCredentialsApi.ReadOneUserCredential(context.Background(), environmentID, userID, credentialID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test UserCredentialsApiService ReadOneUserCredentialWallet", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var credentialID string - - resp, httpRes, err := apiClient.UserCredentialsApi.ReadOneUserCredentialWallet(context.Background(), environmentID, userID, credentialID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - - t.Run("Test UserCredentialsApiService UpdateAUserCredential", func(t *testing.T) { - - t.Skip("skip test") // remove to run test - - var environmentID string - var userID string - var credentialID string - - resp, httpRes, err := apiClient.UserCredentialsApi.UpdateUserCredential(context.Background(), environmentID, userID, credentialID).Execute() - - require.Nil(t, err) - require.NotNil(t, resp) - assert.Equal(t, 200, httpRes.StatusCode) - - }) - -}