diff --git a/src/adyen/api.go b/src/adyen/api.go index 36483e301..461122d58 100644 --- a/src/adyen/api.go +++ b/src/adyen/api.go @@ -80,21 +80,21 @@ const ( type APIClient struct { client *common.Client // API Services - checkout *checkout.APIClient - payments *payments.APIClient - paymentsApp *paymentsapp.PaymentsAppApi - payout *payout.APIClient - recurring *recurring.GeneralApi - binLookup *binlookup.GeneralApi - balancecontrol *balancecontrol.GeneralApi - posTerminalManagement *posterminalmanagement.GeneralApi - disputes *disputes.GeneralApi - storedValue *storedvalue.GeneralApi - balancePlatform *balanceplatform.APIClient - transfers *transfers.APIClient - management *management.APIClient - legalEntity *legalentity.APIClient - dataProtection *dataprotection.GeneralApi + checkout *checkout.APIClient + payments *payments.APIClient + paymentsApp *paymentsapp.PaymentsAppApi + payout *payout.APIClient + recurring *recurring.GeneralApi + binLookup *binlookup.GeneralApi + balancecontrol *balancecontrol.GeneralApi + posTerminalManagement *posterminalmanagement.GeneralApi + disputes *disputes.GeneralApi + storedValue *storedvalue.GeneralApi + balancePlatform *balanceplatform.APIClient + transfers *transfers.APIClient + management *management.APIClient + legalEntity *legalentity.APIClient + dataProtection *dataprotection.GeneralApi } // NewClient optionally a custom http.Client can be passed via the Config allow for advanced features such as caching. diff --git a/src/management/api_payment_methods_merchant_level.go b/src/management/api_payment_methods_merchant_level.go index c3f99583c..53d76a2af 100644 --- a/src/management/api_payment_methods_merchant_level.go +++ b/src/management/api_payment_methods_merchant_level.go @@ -49,7 +49,7 @@ func (a *PaymentMethodsMerchantLevelApi) AddApplePayDomainInput(merchantId strin /* AddApplePayDomain Add an Apple Pay domain -Adds the new domain to the list of Apple Pay domains that are registered with the merchant account and the payment method identified in the path. For more information, see [Apple Pay documentation](https://docs.adyen.com/payment-methods/apple-pay/enable-apple-pay#register-merchant-domain). +Adds the new domain to the list of Apple Pay domains that are registered with the merchant account and the payment method identified in the path. For more information, see [Apple Pay documentation](https://docs.adyen.com/payment-methods/apple-pay/web-drop-in/?tab=adyen-certificate-live_1#going-live). To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API—Payment methods read and write diff --git a/src/management/api_split_configuration_merchant_level.go b/src/management/api_split_configuration_merchant_level.go index 8c397e2d5..73b60036f 100644 --- a/src/management/api_split_configuration_merchant_level.go +++ b/src/management/api_split_configuration_merchant_level.go @@ -49,7 +49,7 @@ func (a *SplitConfigurationMerchantLevelApi) CreateRuleInput(merchantId string, /* CreateRule Create a rule -Creates a rule in the split configuration specified in the path. +[Creates a rule](https://docs.adyen.com/platforms/automatic-split-configuration/manage-split-configurations/api/#create-rule) in the split configuration profile specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -148,9 +148,9 @@ func (a *SplitConfigurationMerchantLevelApi) CreateSplitConfigurationInput(merch } /* -CreateSplitConfiguration Create a split configuration +CreateSplitConfiguration Create a split configuration profile -Creates a split configuration for the merchant account specified in the path. +Creates a split configuration profile to [split payments automatically](https://docs.adyen.com/platforms/automatic-split-configuration/). After you [associate it with a store](https://docs.adyen.com/api-explorer/Management/latest/patch/merchants/(merchantId)/stores/(storeId)#request-splitConfiguration) in your merchant account, it splits the funds of all transactions processed through that store between your liable balance account and [your user's balance account](https://docs.adyen.com/api-explorer/Management/latest/patch/merchants/(merchantId)/stores/(storeId)#request-splitConfiguration-balanceAccountId). To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -244,9 +244,9 @@ func (a *SplitConfigurationMerchantLevelApi) DeleteSplitConfigurationInput(merch } /* -DeleteSplitConfiguration Delete a split configuration +DeleteSplitConfiguration Delete a split configuration profile -Deletes the split configuration specified in the path. +Deletes the split configuration profile specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -343,9 +343,9 @@ func (a *SplitConfigurationMerchantLevelApi) DeleteSplitConfigurationRuleInput(m } /* -DeleteSplitConfigurationRule Delete a split configuration rule +DeleteSplitConfigurationRule Delete a rule -Deletes the split configuration rule specified in the path. +Deletes the rule specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -441,9 +441,9 @@ func (a *SplitConfigurationMerchantLevelApi) GetSplitConfigurationInput(merchant } /* -GetSplitConfiguration Get a split configuration +GetSplitConfiguration Get a split configuration profile -Returns the split configuration specified in the path. +Returns the details of the split configuration profile specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -536,9 +536,9 @@ func (a *SplitConfigurationMerchantLevelApi) ListSplitConfigurationsInput(mercha } /* -ListSplitConfigurations Get a list of split configurations +ListSplitConfigurations Get a list of split configuration profiles -Returns the list of split configurations for the merchant account. +Returns the list of split configuration profiles for the merchant account. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -640,9 +640,9 @@ func (a *SplitConfigurationMerchantLevelApi) UpdateSplitConditionsInput(merchant } /* -UpdateSplitConditions Update split conditions +UpdateSplitConditions Update the split conditions -Changes the conditions of the split configuration rule specified in the path. +Changes the [split conditions of the rule](https://docs.adyen.com/platforms/automatic-split-configuration/manage-split-configurations/api/#update-condition) specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -744,9 +744,9 @@ func (a *SplitConfigurationMerchantLevelApi) UpdateSplitConfigurationDescription } /* -UpdateSplitConfigurationDescription Update split configuration description +UpdateSplitConfigurationDescription Update the description of the split configuration profile -Changes the description of the split configuration specified in the path. +Changes the description of the split configuration profile specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write @@ -853,7 +853,7 @@ func (a *SplitConfigurationMerchantLevelApi) UpdateSplitLogicInput(merchantId st /* UpdateSplitLogic Update the split logic -Changes the split logic specified in the path. +Changes the [split logic](https://docs.adyen.com/platforms/automatic-split-configuration/manage-split-configurations/api/#update-split-logic) specified in the path. To make this request, your API credential must have the following [role](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API - SplitConfiguration read and write diff --git a/src/management/api_terminal_orders_merchant_level.go b/src/management/api_terminal_orders_merchant_level.go index 71eb33d46..40029de7f 100644 --- a/src/management/api_terminal_orders_merchant_level.go +++ b/src/management/api_terminal_orders_merchant_level.go @@ -820,7 +820,7 @@ func (a *TerminalOrdersMerchantLevelApi) ListTerminalModelsInput(merchantId stri /* ListTerminalModels Get a list of terminal models -Returns the payment terminal models that merchant account identified in the path has access to. The response includes the terminal model ID, which can be used as a query parameter when getting a list of terminals or a list of products for ordering. +Returns the payment terminal models that the merchant account identified in the path has access to. The response includes the terminal model ID, which can be used as a query parameter when getting a list of terminals or a list of products for ordering. To make this request, your API credential must have one of the following [roles](https://docs.adyen.com/development-resources/api-credentials#api-permissions): * Management API—Terminal ordering read diff --git a/src/management/model_additional_settings.go b/src/management/model_additional_settings.go index 1fdfbe7c3..8806f91df 100644 --- a/src/management/model_additional_settings.go +++ b/src/management/model_additional_settings.go @@ -21,7 +21,7 @@ var _ common.MappedNullable = &AdditionalSettings{} type AdditionalSettings struct { // Object containing list of event codes for which the notification will be sent. IncludeEventCodes []string `json:"includeEventCodes,omitempty"` - // Object containing boolean key-value pairs. The key can be any [standard webhook additional setting](https://docs.adyen.com/development-resources/webhooks/additional-settings), and the value indicates if the setting is enabled. For example, `captureDelayHours`: **true** means the standard notifications you get will contain the number of hours remaining until the payment will be captured. + // Object containing boolean key-value pairs. The key can be any [standard webhook additional setting](https://docs.adyen.com/development-resources/webhooks/additional-settings), and the value indicates if the setting is enabled. For example, `includeCaptureDelayHours`: **true** means the standard notifications you get will contain the number of hours remaining until the payment will be captured. Properties *map[string]bool `json:"properties,omitempty"` } diff --git a/src/management/model_additional_settings_response.go b/src/management/model_additional_settings_response.go index bd3ce2cc5..8d8abee2c 100644 --- a/src/management/model_additional_settings_response.go +++ b/src/management/model_additional_settings_response.go @@ -23,7 +23,7 @@ type AdditionalSettingsResponse struct { ExcludeEventCodes []string `json:"excludeEventCodes,omitempty"` // Object containing list of event codes for which the notification will be sent. IncludeEventCodes []string `json:"includeEventCodes,omitempty"` - // Object containing boolean key-value pairs. The key can be any [standard webhook additional setting](https://docs.adyen.com/development-resources/webhooks/additional-settings), and the value indicates if the setting is enabled. For example, `captureDelayHours`: **true** means the standard notifications you get will contain the number of hours remaining until the payment will be captured. + // Object containing boolean key-value pairs. The key can be any [standard webhook additional setting](https://docs.adyen.com/development-resources/webhooks/additional-settings), and the value indicates if the setting is enabled. For example, `includeCaptureDelayHours`: **true** means the standard notifications you get will contain the number of hours remaining until the payment will be captured. Properties *map[string]bool `json:"properties,omitempty"` } diff --git a/src/management/model_alipay_plus_info.go b/src/management/model_alipay_plus_info.go new file mode 100644 index 000000000..6d35cdead --- /dev/null +++ b/src/management/model_alipay_plus_info.go @@ -0,0 +1,125 @@ +/* +Management API + +API version: 3 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package management + +import ( + "encoding/json" + + "github.com/adyen/adyen-go-api-library/v21/src/common" +) + +// checks if the AlipayPlusInfo type satisfies the MappedNullable interface at compile time +var _ common.MappedNullable = &AlipayPlusInfo{} + +// AlipayPlusInfo struct for AlipayPlusInfo +type AlipayPlusInfo struct { + // The currency used for settlement. Defaults to USD. + SettlementCurrencyCode *string `json:"settlementCurrencyCode,omitempty"` +} + +// NewAlipayPlusInfo instantiates a new AlipayPlusInfo 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 NewAlipayPlusInfo() *AlipayPlusInfo { + this := AlipayPlusInfo{} + return &this +} + +// NewAlipayPlusInfoWithDefaults instantiates a new AlipayPlusInfo 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 NewAlipayPlusInfoWithDefaults() *AlipayPlusInfo { + this := AlipayPlusInfo{} + return &this +} + +// GetSettlementCurrencyCode returns the SettlementCurrencyCode field value if set, zero value otherwise. +func (o *AlipayPlusInfo) GetSettlementCurrencyCode() string { + if o == nil || common.IsNil(o.SettlementCurrencyCode) { + var ret string + return ret + } + return *o.SettlementCurrencyCode +} + +// GetSettlementCurrencyCodeOk returns a tuple with the SettlementCurrencyCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AlipayPlusInfo) GetSettlementCurrencyCodeOk() (*string, bool) { + if o == nil || common.IsNil(o.SettlementCurrencyCode) { + return nil, false + } + return o.SettlementCurrencyCode, true +} + +// HasSettlementCurrencyCode returns a boolean if a field has been set. +func (o *AlipayPlusInfo) HasSettlementCurrencyCode() bool { + if o != nil && !common.IsNil(o.SettlementCurrencyCode) { + return true + } + + return false +} + +// SetSettlementCurrencyCode gets a reference to the given string and assigns it to the SettlementCurrencyCode field. +func (o *AlipayPlusInfo) SetSettlementCurrencyCode(v string) { + o.SettlementCurrencyCode = &v +} + +func (o AlipayPlusInfo) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o AlipayPlusInfo) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !common.IsNil(o.SettlementCurrencyCode) { + toSerialize["settlementCurrencyCode"] = o.SettlementCurrencyCode + } + return toSerialize, nil +} + +type NullableAlipayPlusInfo struct { + value *AlipayPlusInfo + isSet bool +} + +func (v NullableAlipayPlusInfo) Get() *AlipayPlusInfo { + return v.value +} + +func (v *NullableAlipayPlusInfo) Set(val *AlipayPlusInfo) { + v.value = val + v.isSet = true +} + +func (v NullableAlipayPlusInfo) IsSet() bool { + return v.isSet +} + +func (v *NullableAlipayPlusInfo) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAlipayPlusInfo(val *AlipayPlusInfo) *NullableAlipayPlusInfo { + return &NullableAlipayPlusInfo{value: val, isSet: true} +} + +func (v NullableAlipayPlusInfo) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAlipayPlusInfo) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/src/management/model_create_company_webhook_request.go b/src/management/model_create_company_webhook_request.go index 875ea0044..0f9b84280 100644 --- a/src/management/model_create_company_webhook_request.go +++ b/src/management/model_create_company_webhook_request.go @@ -44,7 +44,7 @@ type CreateCompanyWebhookRequest struct { Password *string `json:"password,omitempty"` // Indicates if the SOAP action header needs to be populated. Default value: **false**. Only applies if `communicationFormat`: **soap**. PopulateSoapActionHeader *bool `json:"populateSoapActionHeader,omitempty"` - // The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). + // The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#event-codes) and [other types of webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#other-webhooks). Type string `json:"type"` // Public URL where webhooks will be sent, for example **https://www.domain.com/webhook-endpoint**. Url string `json:"url"` diff --git a/src/management/model_create_merchant_webhook_request.go b/src/management/model_create_merchant_webhook_request.go index 5fa8959aa..0521d0ba5 100644 --- a/src/management/model_create_merchant_webhook_request.go +++ b/src/management/model_create_merchant_webhook_request.go @@ -40,7 +40,7 @@ type CreateMerchantWebhookRequest struct { Password *string `json:"password,omitempty"` // Indicates if the SOAP action header needs to be populated. Default value: **false**. Only applies if `communicationFormat`: **soap**. PopulateSoapActionHeader *bool `json:"populateSoapActionHeader,omitempty"` - // The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). + // The type of webhook that is being created. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **rreq-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#event-codes) and [other types of webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#other-webhooks). Type string `json:"type"` // Public URL where webhooks will be sent, for example **https://www.domain.com/webhook-endpoint**. Url string `json:"url"` diff --git a/src/management/model_key.go b/src/management/model_key.go index afc65d1f5..c365dc59e 100644 --- a/src/management/model_key.go +++ b/src/management/model_key.go @@ -21,7 +21,7 @@ var _ common.MappedNullable = &Key{} type Key struct { // The unique identifier of the shared key. Identifier *string `json:"identifier,omitempty"` - // The secure passphrase to protect the shared key. + // The secure passphrase to protect the shared key. Must consist of: * At least 12 characters. * At least 1 uppercase letter: `[A-Z]`. * At least 1 lowercase letter: `[a-z]`. * At least 1 digit: `[0-9]`. * At least 1 special character. Limited to the following: `~`, `@`, `$`, `%`, `^`, `&`, `*`, `(`, `)`, `_`, `+`, `=`, `}`, `{`, `]`, `[`, `;`, `:`, `?`, `.`, `,`, `>`, `<`. Passphrase *string `json:"passphrase,omitempty"` // The version number of the shared key. Version *int32 `json:"version,omitempty"` diff --git a/src/management/model_pay_by_bank_plaid_info.go b/src/management/model_pay_by_bank_plaid_info.go index 28adad413..824741782 100644 --- a/src/management/model_pay_by_bank_plaid_info.go +++ b/src/management/model_pay_by_bank_plaid_info.go @@ -19,23 +19,9 @@ var _ common.MappedNullable = &PayByBankPlaidInfo{} // PayByBankPlaidInfo struct for PayByBankPlaidInfo type PayByBankPlaidInfo struct { - // Country Code. - CountryCode *string `json:"countryCode,omitempty"` // Merchant logo (max. size 150kB). Format: Base64-encoded string. - Logo *string `json:"logo,omitempty"` - // The city the merchant is doing business in. - MerchantCity *string `json:"merchantCity,omitempty"` - // Legal Business Name of the Merchant. - MerchantLegalName *string `json:"merchantLegalName,omitempty"` - // Merchant shop url. - MerchantShopUrl *string `json:"merchantShopUrl,omitempty"` - // The state/province of the merchant. - MerchantStateProvince *string `json:"merchantStateProvince,omitempty"` - // The street address of the merchant. - MerchantStreetAddress *string `json:"merchantStreetAddress,omitempty"` + Logo *string `json:"logo,omitempty"` TransactionDescription *TransactionDescriptionInfo `json:"transactionDescription,omitempty"` - // The zip code of the account. - ZipCode *string `json:"zipCode,omitempty"` } // NewPayByBankPlaidInfo instantiates a new PayByBankPlaidInfo object @@ -55,38 +41,6 @@ func NewPayByBankPlaidInfoWithDefaults() *PayByBankPlaidInfo { return &this } -// GetCountryCode returns the CountryCode field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetCountryCode() string { - if o == nil || common.IsNil(o.CountryCode) { - var ret string - return ret - } - return *o.CountryCode -} - -// GetCountryCodeOk returns a tuple with the CountryCode field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetCountryCodeOk() (*string, bool) { - if o == nil || common.IsNil(o.CountryCode) { - return nil, false - } - return o.CountryCode, true -} - -// HasCountryCode returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasCountryCode() bool { - if o != nil && !common.IsNil(o.CountryCode) { - return true - } - - return false -} - -// SetCountryCode gets a reference to the given string and assigns it to the CountryCode field. -func (o *PayByBankPlaidInfo) SetCountryCode(v string) { - o.CountryCode = &v -} - // GetLogo returns the Logo field value if set, zero value otherwise. func (o *PayByBankPlaidInfo) GetLogo() string { if o == nil || common.IsNil(o.Logo) { @@ -119,166 +73,6 @@ func (o *PayByBankPlaidInfo) SetLogo(v string) { o.Logo = &v } -// GetMerchantCity returns the MerchantCity field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetMerchantCity() string { - if o == nil || common.IsNil(o.MerchantCity) { - var ret string - return ret - } - return *o.MerchantCity -} - -// GetMerchantCityOk returns a tuple with the MerchantCity field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetMerchantCityOk() (*string, bool) { - if o == nil || common.IsNil(o.MerchantCity) { - return nil, false - } - return o.MerchantCity, true -} - -// HasMerchantCity returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasMerchantCity() bool { - if o != nil && !common.IsNil(o.MerchantCity) { - return true - } - - return false -} - -// SetMerchantCity gets a reference to the given string and assigns it to the MerchantCity field. -func (o *PayByBankPlaidInfo) SetMerchantCity(v string) { - o.MerchantCity = &v -} - -// GetMerchantLegalName returns the MerchantLegalName field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetMerchantLegalName() string { - if o == nil || common.IsNil(o.MerchantLegalName) { - var ret string - return ret - } - return *o.MerchantLegalName -} - -// GetMerchantLegalNameOk returns a tuple with the MerchantLegalName field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetMerchantLegalNameOk() (*string, bool) { - if o == nil || common.IsNil(o.MerchantLegalName) { - return nil, false - } - return o.MerchantLegalName, true -} - -// HasMerchantLegalName returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasMerchantLegalName() bool { - if o != nil && !common.IsNil(o.MerchantLegalName) { - return true - } - - return false -} - -// SetMerchantLegalName gets a reference to the given string and assigns it to the MerchantLegalName field. -func (o *PayByBankPlaidInfo) SetMerchantLegalName(v string) { - o.MerchantLegalName = &v -} - -// GetMerchantShopUrl returns the MerchantShopUrl field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetMerchantShopUrl() string { - if o == nil || common.IsNil(o.MerchantShopUrl) { - var ret string - return ret - } - return *o.MerchantShopUrl -} - -// GetMerchantShopUrlOk returns a tuple with the MerchantShopUrl field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetMerchantShopUrlOk() (*string, bool) { - if o == nil || common.IsNil(o.MerchantShopUrl) { - return nil, false - } - return o.MerchantShopUrl, true -} - -// HasMerchantShopUrl returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasMerchantShopUrl() bool { - if o != nil && !common.IsNil(o.MerchantShopUrl) { - return true - } - - return false -} - -// SetMerchantShopUrl gets a reference to the given string and assigns it to the MerchantShopUrl field. -func (o *PayByBankPlaidInfo) SetMerchantShopUrl(v string) { - o.MerchantShopUrl = &v -} - -// GetMerchantStateProvince returns the MerchantStateProvince field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetMerchantStateProvince() string { - if o == nil || common.IsNil(o.MerchantStateProvince) { - var ret string - return ret - } - return *o.MerchantStateProvince -} - -// GetMerchantStateProvinceOk returns a tuple with the MerchantStateProvince field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetMerchantStateProvinceOk() (*string, bool) { - if o == nil || common.IsNil(o.MerchantStateProvince) { - return nil, false - } - return o.MerchantStateProvince, true -} - -// HasMerchantStateProvince returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasMerchantStateProvince() bool { - if o != nil && !common.IsNil(o.MerchantStateProvince) { - return true - } - - return false -} - -// SetMerchantStateProvince gets a reference to the given string and assigns it to the MerchantStateProvince field. -func (o *PayByBankPlaidInfo) SetMerchantStateProvince(v string) { - o.MerchantStateProvince = &v -} - -// GetMerchantStreetAddress returns the MerchantStreetAddress field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetMerchantStreetAddress() string { - if o == nil || common.IsNil(o.MerchantStreetAddress) { - var ret string - return ret - } - return *o.MerchantStreetAddress -} - -// GetMerchantStreetAddressOk returns a tuple with the MerchantStreetAddress field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetMerchantStreetAddressOk() (*string, bool) { - if o == nil || common.IsNil(o.MerchantStreetAddress) { - return nil, false - } - return o.MerchantStreetAddress, true -} - -// HasMerchantStreetAddress returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasMerchantStreetAddress() bool { - if o != nil && !common.IsNil(o.MerchantStreetAddress) { - return true - } - - return false -} - -// SetMerchantStreetAddress gets a reference to the given string and assigns it to the MerchantStreetAddress field. -func (o *PayByBankPlaidInfo) SetMerchantStreetAddress(v string) { - o.MerchantStreetAddress = &v -} - // GetTransactionDescription returns the TransactionDescription field value if set, zero value otherwise. func (o *PayByBankPlaidInfo) GetTransactionDescription() TransactionDescriptionInfo { if o == nil || common.IsNil(o.TransactionDescription) { @@ -311,38 +105,6 @@ func (o *PayByBankPlaidInfo) SetTransactionDescription(v TransactionDescriptionI o.TransactionDescription = &v } -// GetZipCode returns the ZipCode field value if set, zero value otherwise. -func (o *PayByBankPlaidInfo) GetZipCode() string { - if o == nil || common.IsNil(o.ZipCode) { - var ret string - return ret - } - return *o.ZipCode -} - -// GetZipCodeOk returns a tuple with the ZipCode field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PayByBankPlaidInfo) GetZipCodeOk() (*string, bool) { - if o == nil || common.IsNil(o.ZipCode) { - return nil, false - } - return o.ZipCode, true -} - -// HasZipCode returns a boolean if a field has been set. -func (o *PayByBankPlaidInfo) HasZipCode() bool { - if o != nil && !common.IsNil(o.ZipCode) { - return true - } - - return false -} - -// SetZipCode gets a reference to the given string and assigns it to the ZipCode field. -func (o *PayByBankPlaidInfo) SetZipCode(v string) { - o.ZipCode = &v -} - func (o PayByBankPlaidInfo) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -353,33 +115,12 @@ func (o PayByBankPlaidInfo) MarshalJSON() ([]byte, error) { func (o PayByBankPlaidInfo) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - if !common.IsNil(o.CountryCode) { - toSerialize["countryCode"] = o.CountryCode - } if !common.IsNil(o.Logo) { toSerialize["logo"] = o.Logo } - if !common.IsNil(o.MerchantCity) { - toSerialize["merchantCity"] = o.MerchantCity - } - if !common.IsNil(o.MerchantLegalName) { - toSerialize["merchantLegalName"] = o.MerchantLegalName - } - if !common.IsNil(o.MerchantShopUrl) { - toSerialize["merchantShopUrl"] = o.MerchantShopUrl - } - if !common.IsNil(o.MerchantStateProvince) { - toSerialize["merchantStateProvince"] = o.MerchantStateProvince - } - if !common.IsNil(o.MerchantStreetAddress) { - toSerialize["merchantStreetAddress"] = o.MerchantStreetAddress - } if !common.IsNil(o.TransactionDescription) { toSerialize["transactionDescription"] = o.TransactionDescription } - if !common.IsNil(o.ZipCode) { - toSerialize["zipCode"] = o.ZipCode - } return toSerialize, nil } diff --git a/src/management/model_payment_method.go b/src/management/model_payment_method.go index af34136aa..bbc94de47 100644 --- a/src/management/model_payment_method.go +++ b/src/management/model_payment_method.go @@ -22,6 +22,7 @@ type PaymentMethod struct { Accel *AccelInfo `json:"accel,omitempty"` Affirm *AffirmInfo `json:"affirm,omitempty"` AfterpayTouch *AfterpayTouchInfo `json:"afterpayTouch,omitempty"` + AlipayPlus *AlipayPlusInfo `json:"alipayPlus,omitempty"` // Indicates whether receiving payments is allowed. This value is set to **true** by Adyen after screening your merchant account. Allowed *bool `json:"allowed,omitempty"` Amex *AmexInfo `json:"amex,omitempty"` @@ -53,6 +54,7 @@ type PaymentMethod struct { Jcb *JCBInfo `json:"jcb,omitempty"` Klarna *KlarnaInfo `json:"klarna,omitempty"` Maestro *GenericPmWithTdiInfo `json:"maestro,omitempty"` + MaestroUsa *GenericPmWithTdiInfo `json:"maestro_usa,omitempty"` Mc *GenericPmWithTdiInfo `json:"mc,omitempty"` MealVoucherFR *MealVoucherFRInfo `json:"mealVoucher_FR,omitempty"` Nyce *NyceInfo `json:"nyce,omitempty"` @@ -62,7 +64,8 @@ type PaymentMethod struct { Payto *PayToInfo `json:"payto,omitempty"` Pulse *PulseInfo `json:"pulse,omitempty"` // Your reference for the payment method. Supported characters a-z, A-Z, 0-9. - Reference *string `json:"reference,omitempty"` + Reference *string `json:"reference,omitempty"` + Sepadirectdebit *SepaDirectDebitInfo `json:"sepadirectdebit,omitempty"` // The sales channel. ShopperInteraction *string `json:"shopperInteraction,omitempty"` Sodexo *SodexoInfo `json:"sodexo,omitempty"` @@ -197,6 +200,38 @@ func (o *PaymentMethod) SetAfterpayTouch(v AfterpayTouchInfo) { o.AfterpayTouch = &v } +// GetAlipayPlus returns the AlipayPlus field value if set, zero value otherwise. +func (o *PaymentMethod) GetAlipayPlus() AlipayPlusInfo { + if o == nil || common.IsNil(o.AlipayPlus) { + var ret AlipayPlusInfo + return ret + } + return *o.AlipayPlus +} + +// GetAlipayPlusOk returns a tuple with the AlipayPlus field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethod) GetAlipayPlusOk() (*AlipayPlusInfo, bool) { + if o == nil || common.IsNil(o.AlipayPlus) { + return nil, false + } + return o.AlipayPlus, true +} + +// HasAlipayPlus returns a boolean if a field has been set. +func (o *PaymentMethod) HasAlipayPlus() bool { + if o != nil && !common.IsNil(o.AlipayPlus) { + return true + } + + return false +} + +// SetAlipayPlus gets a reference to the given AlipayPlusInfo and assigns it to the AlipayPlus field. +func (o *PaymentMethod) SetAlipayPlus(v AlipayPlusInfo) { + o.AlipayPlus = &v +} + // GetAllowed returns the Allowed field value if set, zero value otherwise. func (o *PaymentMethod) GetAllowed() bool { if o == nil || common.IsNil(o.Allowed) { @@ -957,6 +992,38 @@ func (o *PaymentMethod) SetMaestro(v GenericPmWithTdiInfo) { o.Maestro = &v } +// GetMaestroUsa returns the MaestroUsa field value if set, zero value otherwise. +func (o *PaymentMethod) GetMaestroUsa() GenericPmWithTdiInfo { + if o == nil || common.IsNil(o.MaestroUsa) { + var ret GenericPmWithTdiInfo + return ret + } + return *o.MaestroUsa +} + +// GetMaestroUsaOk returns a tuple with the MaestroUsa field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethod) GetMaestroUsaOk() (*GenericPmWithTdiInfo, bool) { + if o == nil || common.IsNil(o.MaestroUsa) { + return nil, false + } + return o.MaestroUsa, true +} + +// HasMaestroUsa returns a boolean if a field has been set. +func (o *PaymentMethod) HasMaestroUsa() bool { + if o != nil && !common.IsNil(o.MaestroUsa) { + return true + } + + return false +} + +// SetMaestroUsa gets a reference to the given GenericPmWithTdiInfo and assigns it to the MaestroUsa field. +func (o *PaymentMethod) SetMaestroUsa(v GenericPmWithTdiInfo) { + o.MaestroUsa = &v +} + // GetMc returns the Mc field value if set, zero value otherwise. func (o *PaymentMethod) GetMc() GenericPmWithTdiInfo { if o == nil || common.IsNil(o.Mc) { @@ -1245,6 +1312,38 @@ func (o *PaymentMethod) SetReference(v string) { o.Reference = &v } +// GetSepadirectdebit returns the Sepadirectdebit field value if set, zero value otherwise. +func (o *PaymentMethod) GetSepadirectdebit() SepaDirectDebitInfo { + if o == nil || common.IsNil(o.Sepadirectdebit) { + var ret SepaDirectDebitInfo + return ret + } + return *o.Sepadirectdebit +} + +// GetSepadirectdebitOk returns a tuple with the Sepadirectdebit field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethod) GetSepadirectdebitOk() (*SepaDirectDebitInfo, bool) { + if o == nil || common.IsNil(o.Sepadirectdebit) { + return nil, false + } + return o.Sepadirectdebit, true +} + +// HasSepadirectdebit returns a boolean if a field has been set. +func (o *PaymentMethod) HasSepadirectdebit() bool { + if o != nil && !common.IsNil(o.Sepadirectdebit) { + return true + } + + return false +} + +// SetSepadirectdebit gets a reference to the given SepaDirectDebitInfo and assigns it to the Sepadirectdebit field. +func (o *PaymentMethod) SetSepadirectdebit(v SepaDirectDebitInfo) { + o.Sepadirectdebit = &v +} + // GetShopperInteraction returns the ShopperInteraction field value if set, zero value otherwise. func (o *PaymentMethod) GetShopperInteraction() string { if o == nil || common.IsNil(o.ShopperInteraction) { @@ -1712,6 +1811,9 @@ func (o PaymentMethod) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.AfterpayTouch) { toSerialize["afterpayTouch"] = o.AfterpayTouch } + if !common.IsNil(o.AlipayPlus) { + toSerialize["alipayPlus"] = o.AlipayPlus + } if !common.IsNil(o.Allowed) { toSerialize["allowed"] = o.Allowed } @@ -1782,6 +1884,9 @@ func (o PaymentMethod) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Maestro) { toSerialize["maestro"] = o.Maestro } + if !common.IsNil(o.MaestroUsa) { + toSerialize["maestro_usa"] = o.MaestroUsa + } if !common.IsNil(o.Mc) { toSerialize["mc"] = o.Mc } @@ -1809,6 +1914,9 @@ func (o PaymentMethod) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Reference) { toSerialize["reference"] = o.Reference } + if !common.IsNil(o.Sepadirectdebit) { + toSerialize["sepadirectdebit"] = o.Sepadirectdebit + } if !common.IsNil(o.ShopperInteraction) { toSerialize["shopperInteraction"] = o.ShopperInteraction } diff --git a/src/management/model_payment_method_response.go b/src/management/model_payment_method_response.go index d874039fc..7ade4e724 100644 --- a/src/management/model_payment_method_response.go +++ b/src/management/model_payment_method_response.go @@ -26,7 +26,7 @@ type PaymentMethodResponse struct { ItemsTotal int32 `json:"itemsTotal"` // Total number of pages. PagesTotal int32 `json:"pagesTotal"` - // Payment method types with errors. + // The payment method types that were not successfully requested and their corresponding errors. TypesWithErrors []string `json:"typesWithErrors,omitempty"` } diff --git a/src/management/model_payment_method_setup_info.go b/src/management/model_payment_method_setup_info.go index e64394cd7..39c5db56d 100644 --- a/src/management/model_payment_method_setup_info.go +++ b/src/management/model_payment_method_setup_info.go @@ -22,6 +22,7 @@ type PaymentMethodSetupInfo struct { Accel *AccelInfo `json:"accel,omitempty"` Affirm *AffirmInfo `json:"affirm,omitempty"` AfterpayTouch *AfterpayTouchInfo `json:"afterpayTouch,omitempty"` + AlipayPlus *AlipayPlusInfo `json:"alipayPlus,omitempty"` Amex *AmexInfo `json:"amex,omitempty"` ApplePay *ApplePayInfo `json:"applePay,omitempty"` Bcmc *BcmcInfo `json:"bcmc,omitempty"` @@ -47,6 +48,7 @@ type PaymentMethodSetupInfo struct { Jcb *JCBInfo `json:"jcb,omitempty"` Klarna *KlarnaInfo `json:"klarna,omitempty"` Maestro *GenericPmWithTdiInfo `json:"maestro,omitempty"` + MaestroUsa *GenericPmWithTdiInfo `json:"maestro_usa,omitempty"` Mc *GenericPmWithTdiInfo `json:"mc,omitempty"` MealVoucherFR *MealVoucherFRInfo `json:"mealVoucher_FR,omitempty"` Nyce *NyceInfo `json:"nyce,omitempty"` @@ -56,7 +58,8 @@ type PaymentMethodSetupInfo struct { Payto *PayToInfo `json:"payto,omitempty"` Pulse *PulseInfo `json:"pulse,omitempty"` // Your reference for the payment method. Supported characters a-z, A-Z, 0-9. - Reference *string `json:"reference,omitempty"` + Reference *string `json:"reference,omitempty"` + Sepadirectdebit *SepaDirectDebitInfo `json:"sepadirectdebit,omitempty"` // The sales channel. Required if the merchant account does not have a sales channel. When you provide this field, it overrides the default sales channel set on the merchant account. Possible values: **eCommerce**, **pos**, **contAuth**, and **moto**. ShopperInteraction *string `json:"shopperInteraction,omitempty"` Sodexo *SodexoInfo `json:"sodexo,omitempty"` @@ -189,6 +192,38 @@ func (o *PaymentMethodSetupInfo) SetAfterpayTouch(v AfterpayTouchInfo) { o.AfterpayTouch = &v } +// GetAlipayPlus returns the AlipayPlus field value if set, zero value otherwise. +func (o *PaymentMethodSetupInfo) GetAlipayPlus() AlipayPlusInfo { + if o == nil || common.IsNil(o.AlipayPlus) { + var ret AlipayPlusInfo + return ret + } + return *o.AlipayPlus +} + +// GetAlipayPlusOk returns a tuple with the AlipayPlus field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethodSetupInfo) GetAlipayPlusOk() (*AlipayPlusInfo, bool) { + if o == nil || common.IsNil(o.AlipayPlus) { + return nil, false + } + return o.AlipayPlus, true +} + +// HasAlipayPlus returns a boolean if a field has been set. +func (o *PaymentMethodSetupInfo) HasAlipayPlus() bool { + if o != nil && !common.IsNil(o.AlipayPlus) { + return true + } + + return false +} + +// SetAlipayPlus gets a reference to the given AlipayPlusInfo and assigns it to the AlipayPlus field. +func (o *PaymentMethodSetupInfo) SetAlipayPlus(v AlipayPlusInfo) { + o.AlipayPlus = &v +} + // GetAmex returns the Amex field value if set, zero value otherwise. func (o *PaymentMethodSetupInfo) GetAmex() AmexInfo { if o == nil || common.IsNil(o.Amex) { @@ -861,6 +896,38 @@ func (o *PaymentMethodSetupInfo) SetMaestro(v GenericPmWithTdiInfo) { o.Maestro = &v } +// GetMaestroUsa returns the MaestroUsa field value if set, zero value otherwise. +func (o *PaymentMethodSetupInfo) GetMaestroUsa() GenericPmWithTdiInfo { + if o == nil || common.IsNil(o.MaestroUsa) { + var ret GenericPmWithTdiInfo + return ret + } + return *o.MaestroUsa +} + +// GetMaestroUsaOk returns a tuple with the MaestroUsa field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethodSetupInfo) GetMaestroUsaOk() (*GenericPmWithTdiInfo, bool) { + if o == nil || common.IsNil(o.MaestroUsa) { + return nil, false + } + return o.MaestroUsa, true +} + +// HasMaestroUsa returns a boolean if a field has been set. +func (o *PaymentMethodSetupInfo) HasMaestroUsa() bool { + if o != nil && !common.IsNil(o.MaestroUsa) { + return true + } + + return false +} + +// SetMaestroUsa gets a reference to the given GenericPmWithTdiInfo and assigns it to the MaestroUsa field. +func (o *PaymentMethodSetupInfo) SetMaestroUsa(v GenericPmWithTdiInfo) { + o.MaestroUsa = &v +} + // GetMc returns the Mc field value if set, zero value otherwise. func (o *PaymentMethodSetupInfo) GetMc() GenericPmWithTdiInfo { if o == nil || common.IsNil(o.Mc) { @@ -1149,6 +1216,38 @@ func (o *PaymentMethodSetupInfo) SetReference(v string) { o.Reference = &v } +// GetSepadirectdebit returns the Sepadirectdebit field value if set, zero value otherwise. +func (o *PaymentMethodSetupInfo) GetSepadirectdebit() SepaDirectDebitInfo { + if o == nil || common.IsNil(o.Sepadirectdebit) { + var ret SepaDirectDebitInfo + return ret + } + return *o.Sepadirectdebit +} + +// GetSepadirectdebitOk returns a tuple with the Sepadirectdebit field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PaymentMethodSetupInfo) GetSepadirectdebitOk() (*SepaDirectDebitInfo, bool) { + if o == nil || common.IsNil(o.Sepadirectdebit) { + return nil, false + } + return o.Sepadirectdebit, true +} + +// HasSepadirectdebit returns a boolean if a field has been set. +func (o *PaymentMethodSetupInfo) HasSepadirectdebit() bool { + if o != nil && !common.IsNil(o.Sepadirectdebit) { + return true + } + + return false +} + +// SetSepadirectdebit gets a reference to the given SepaDirectDebitInfo and assigns it to the Sepadirectdebit field. +func (o *PaymentMethodSetupInfo) SetSepadirectdebit(v SepaDirectDebitInfo) { + o.Sepadirectdebit = &v +} + // GetShopperInteraction returns the ShopperInteraction field value if set, zero value otherwise. func (o *PaymentMethodSetupInfo) GetShopperInteraction() string { if o == nil || common.IsNil(o.ShopperInteraction) { @@ -1576,6 +1675,9 @@ func (o PaymentMethodSetupInfo) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.AfterpayTouch) { toSerialize["afterpayTouch"] = o.AfterpayTouch } + if !common.IsNil(o.AlipayPlus) { + toSerialize["alipayPlus"] = o.AlipayPlus + } if !common.IsNil(o.Amex) { toSerialize["amex"] = o.Amex } @@ -1639,6 +1741,9 @@ func (o PaymentMethodSetupInfo) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Maestro) { toSerialize["maestro"] = o.Maestro } + if !common.IsNil(o.MaestroUsa) { + toSerialize["maestro_usa"] = o.MaestroUsa + } if !common.IsNil(o.Mc) { toSerialize["mc"] = o.Mc } @@ -1666,6 +1771,9 @@ func (o PaymentMethodSetupInfo) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Reference) { toSerialize["reference"] = o.Reference } + if !common.IsNil(o.Sepadirectdebit) { + toSerialize["sepadirectdebit"] = o.Sepadirectdebit + } if !common.IsNil(o.ShopperInteraction) { toSerialize["shopperInteraction"] = o.ShopperInteraction } @@ -1752,7 +1860,7 @@ func (o *PaymentMethodSetupInfo) isValidShopperInteraction() bool { return false } func (o *PaymentMethodSetupInfo) isValidType() bool { - var allowedEnumValues = []string{"accel", "ach", "affirm", "afterpaytouch", "alelo", "alipay", "alipay_hk", "alipay_wap", "amex", "applepay", "banese_card", "banese_card_credit", "banese_card_debit", "banese_card_prepaid", "bcmc", "blik", "cartebancaire", "clearpay", "clicktopay", "credtodos", "credtodos_private_credit", "credtodos_private_debit", "cup", "diners", "directdebit_GB", "discover", "ebanking_FI", "eft_directdebit_CA", "eftpos_australia", "elo", "elocredit", "elodebit", "girocard", "googlepay", "hiper", "hipercard", "ideal", "interac_card", "jcb", "klarna", "klarna_account", "klarna_paynow", "maestro", "mbway", "mc", "mcdebit", "mealVoucher_FR", "mobilepay", "multibanco", "nyce", "onlineBanking_PL", "paybybank", "paybybank_plaid", "payme", "payme_pos", "paynow", "paynow_pos", "paypal", "payto", "pulse", "sodexo", "star", "swish", "ticket", "todo_giftcard", "trustly", "twint", "twint_pos", "up_brazil_credit", "vale_refeicao", "vale_refeicao_prepaid", "vipps", "visa", "visadebit", "vpay", "wechatpay", "wechatpay_pos"} + var allowedEnumValues = []string{"abrapetite", "abrapetite_credit", "abrapetite_debit", "abrapetite_prepaid", "accel", "ach", "affirm", "afterpaytouch", "alelo", "alipay", "alipay_hk", "alipay_plus", "alipay_wap", "amex", "applepay", "avancard", "avancard_credit", "avancard_debit", "banese_card", "banese_card_credit", "banese_card_debit", "banese_card_prepaid", "bcmc", "blik", "br_schemes", "cartebancaire", "clearpay", "clicktopay", "cooper", "cooper_credit", "cooper_debit", "cooper_food_debit", "cooper_meal_debit", "cooper_prepaid", "cooper_private_credit", "cooper_retail_credit", "credtodos", "credtodos_private_credit", "credtodos_private_debit", "cup", "diners", "directdebit_GB", "discover", "ebanking_FI", "eft_directdebit_CA", "eftpos_australia", "elo", "elocredit", "elodebit", "girocard", "googlepay", "green_card", "green_card_credit", "green_card_debit", "green_card_food_prepaid", "green_card_meal_prepaid", "green_card_prepaid", "hiper", "hipercard", "ideal", "interac_card", "jcb", "klarna", "klarna_account", "klarna_paynow", "le_card", "le_card_credit", "le_card_debit", "maestro", "maestro_usa", "maxifrota", "maxifrota_prepaid", "mbway", "mc", "mcdebit", "mealVoucher_FR", "megaleve", "megaleve_credit", "megaleve_debit", "mobilepay", "multibanco", "nutricash", "nutricash_prepaid", "nyce", "onlineBanking_PL", "paybybank", "paybybank_plaid", "payme", "payme_pos", "paynow", "paynow_pos", "paypal", "payto", "personal_card", "personal_card_credit", "personal_card_debit", "pulse", "romcard", "romcard_credit", "romcard_debit", "senff", "senff_credit", "sepadirectdebit", "sodexo", "star", "swish", "ticket", "todo_giftcard", "trustly", "twint", "twint_pos", "up_brazil", "up_brazil_credit", "up_brazil_debit", "up_brazil_prepaid", "vale_refeicao", "vale_refeicao_prepaid", "vegas_card", "vegas_card_credit", "vegas_card_debit", "vero_card", "vero_card_credit", "vero_card_debit", "vero_card_prepaid", "vipps", "visa", "visadebit", "vpay", "wechatpay", "wechatpay_pos"} for _, allowed := range allowedEnumValues { if o.GetType() == allowed { return true diff --git a/src/management/model_refunds.go b/src/management/model_refunds.go index 09837dc1c..be590ebcd 100644 --- a/src/management/model_refunds.go +++ b/src/management/model_refunds.go @@ -19,7 +19,8 @@ var _ common.MappedNullable = &Refunds{} // Refunds struct for Refunds type Refunds struct { - Referenced *Referenced `json:"referenced,omitempty"` + Referenced *Referenced `json:"referenced,omitempty"` + Unreferenced *Unreferenced `json:"unreferenced,omitempty"` } // NewRefunds instantiates a new Refunds object @@ -71,6 +72,38 @@ func (o *Refunds) SetReferenced(v Referenced) { o.Referenced = &v } +// GetUnreferenced returns the Unreferenced field value if set, zero value otherwise. +func (o *Refunds) GetUnreferenced() Unreferenced { + if o == nil || common.IsNil(o.Unreferenced) { + var ret Unreferenced + return ret + } + return *o.Unreferenced +} + +// GetUnreferencedOk returns a tuple with the Unreferenced field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Refunds) GetUnreferencedOk() (*Unreferenced, bool) { + if o == nil || common.IsNil(o.Unreferenced) { + return nil, false + } + return o.Unreferenced, true +} + +// HasUnreferenced returns a boolean if a field has been set. +func (o *Refunds) HasUnreferenced() bool { + if o != nil && !common.IsNil(o.Unreferenced) { + return true + } + + return false +} + +// SetUnreferenced gets a reference to the given Unreferenced and assigns it to the Unreferenced field. +func (o *Refunds) SetUnreferenced(v Unreferenced) { + o.Unreferenced = &v +} + func (o Refunds) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -84,6 +117,9 @@ func (o Refunds) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Referenced) { toSerialize["referenced"] = o.Referenced } + if !common.IsNil(o.Unreferenced) { + toSerialize["unreferenced"] = o.Unreferenced + } return toSerialize, nil } diff --git a/src/management/model_sepa_direct_debit_info.go b/src/management/model_sepa_direct_debit_info.go new file mode 100644 index 000000000..ec814fc40 --- /dev/null +++ b/src/management/model_sepa_direct_debit_info.go @@ -0,0 +1,161 @@ +/* +Management API + +API version: 3 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package management + +import ( + "encoding/json" + + "github.com/adyen/adyen-go-api-library/v21/src/common" +) + +// checks if the SepaDirectDebitInfo type satisfies the MappedNullable interface at compile time +var _ common.MappedNullable = &SepaDirectDebitInfo{} + +// SepaDirectDebitInfo struct for SepaDirectDebitInfo +type SepaDirectDebitInfo struct { + // Creditor id + CreditorId *string `json:"creditorId,omitempty"` + TransactionDescription *TransactionDescriptionInfo `json:"transactionDescription,omitempty"` +} + +// NewSepaDirectDebitInfo instantiates a new SepaDirectDebitInfo 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 NewSepaDirectDebitInfo() *SepaDirectDebitInfo { + this := SepaDirectDebitInfo{} + return &this +} + +// NewSepaDirectDebitInfoWithDefaults instantiates a new SepaDirectDebitInfo 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 NewSepaDirectDebitInfoWithDefaults() *SepaDirectDebitInfo { + this := SepaDirectDebitInfo{} + return &this +} + +// GetCreditorId returns the CreditorId field value if set, zero value otherwise. +func (o *SepaDirectDebitInfo) GetCreditorId() string { + if o == nil || common.IsNil(o.CreditorId) { + var ret string + return ret + } + return *o.CreditorId +} + +// GetCreditorIdOk returns a tuple with the CreditorId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SepaDirectDebitInfo) GetCreditorIdOk() (*string, bool) { + if o == nil || common.IsNil(o.CreditorId) { + return nil, false + } + return o.CreditorId, true +} + +// HasCreditorId returns a boolean if a field has been set. +func (o *SepaDirectDebitInfo) HasCreditorId() bool { + if o != nil && !common.IsNil(o.CreditorId) { + return true + } + + return false +} + +// SetCreditorId gets a reference to the given string and assigns it to the CreditorId field. +func (o *SepaDirectDebitInfo) SetCreditorId(v string) { + o.CreditorId = &v +} + +// GetTransactionDescription returns the TransactionDescription field value if set, zero value otherwise. +func (o *SepaDirectDebitInfo) GetTransactionDescription() TransactionDescriptionInfo { + if o == nil || common.IsNil(o.TransactionDescription) { + var ret TransactionDescriptionInfo + return ret + } + return *o.TransactionDescription +} + +// GetTransactionDescriptionOk returns a tuple with the TransactionDescription field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SepaDirectDebitInfo) GetTransactionDescriptionOk() (*TransactionDescriptionInfo, bool) { + if o == nil || common.IsNil(o.TransactionDescription) { + return nil, false + } + return o.TransactionDescription, true +} + +// HasTransactionDescription returns a boolean if a field has been set. +func (o *SepaDirectDebitInfo) HasTransactionDescription() bool { + if o != nil && !common.IsNil(o.TransactionDescription) { + return true + } + + return false +} + +// SetTransactionDescription gets a reference to the given TransactionDescriptionInfo and assigns it to the TransactionDescription field. +func (o *SepaDirectDebitInfo) SetTransactionDescription(v TransactionDescriptionInfo) { + o.TransactionDescription = &v +} + +func (o SepaDirectDebitInfo) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SepaDirectDebitInfo) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !common.IsNil(o.CreditorId) { + toSerialize["creditorId"] = o.CreditorId + } + if !common.IsNil(o.TransactionDescription) { + toSerialize["transactionDescription"] = o.TransactionDescription + } + return toSerialize, nil +} + +type NullableSepaDirectDebitInfo struct { + value *SepaDirectDebitInfo + isSet bool +} + +func (v NullableSepaDirectDebitInfo) Get() *SepaDirectDebitInfo { + return v.value +} + +func (v *NullableSepaDirectDebitInfo) Set(val *SepaDirectDebitInfo) { + v.value = val + v.isSet = true +} + +func (v NullableSepaDirectDebitInfo) IsSet() bool { + return v.isSet +} + +func (v *NullableSepaDirectDebitInfo) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSepaDirectDebitInfo(val *SepaDirectDebitInfo) *NullableSepaDirectDebitInfo { + return &NullableSepaDirectDebitInfo{value: val, isSet: true} +} + +func (v NullableSepaDirectDebitInfo) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSepaDirectDebitInfo) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/src/management/model_split_configuration_rule.go b/src/management/model_split_configuration_rule.go index 6ff18dafe..71e316f17 100644 --- a/src/management/model_split_configuration_rule.go +++ b/src/management/model_split_configuration_rule.go @@ -19,15 +19,17 @@ var _ common.MappedNullable = &SplitConfigurationRule{} // SplitConfigurationRule struct for SplitConfigurationRule type SplitConfigurationRule struct { + // The card region condition that determines whether the [split logic](https://docs.adyen.com/api-explorer/Management/latest/post/merchants/(merchantId)/splitConfigurations#request-rules-splitLogic) applies to the transaction. > This condition is in pilot phase, and not yet available for all platforms. Possible values: * **domestic**: The card issuer and the store where the transaction is processed are registered in the same country. * **international**: The card issuer and the store where the transaction is processed are registered in different countries or regions. Includes all **interRegional** and **intraRegional** transactions. * **interRegional**: The card issuer and the store where the transaction is processed are registered in different regions. * **intraRegional**: The card issuer and the store where the transaction is processed are registered in different countries, but in the same region. * **ANY**: Applies to all transactions, regardless of the processing and issuing country/region. + CardRegion *string `json:"cardRegion,omitempty"` // The currency condition that defines whether the split logic applies. Its value must be a three-character [ISO currency code](https://en.wikipedia.org/wiki/ISO_4217). Currency string `json:"currency"` - // The funding source of the payment method. This only applies to card transactions. Possible values: * **credit** * **debit** * **prepaid** * **deferred_debit** * **charged** * **ANY** - FundingSource *string `json:"fundingSource,omitempty"` + // The funding source of the payment method. Possible values: * **credit** * **debit** * **prepaid** * **deferred_debit** * **charged** * **ANY** + FundingSource string `json:"fundingSource"` // The payment method condition that defines whether the split logic applies. Possible values: * [Payment method variant](https://docs.adyen.com/development-resources/paymentmethodvariant): Apply the split logic for a specific payment method. * **ANY**: Apply the split logic for all available payment methods. PaymentMethod string `json:"paymentMethod"` // The unique identifier of the split configuration rule. RuleId *string `json:"ruleId,omitempty"` - // The sales channel condition that defines whether the split logic applies. Possible values: * **Ecommerce**: Online transactions where the cardholder is present. * **ContAuth**: Card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). * **Moto**: Mail-order and telephone-order transactions where the customer is in contact with the merchant via email or telephone. * **POS**: Point-of-sale transactions where the customer is physically present to make a payment using a secure payment terminal. * **ANY**: All sales channels. + // The sales channel condition that defines whether the split logic applies. Possible values: * **Ecommerce**: online transactions where the cardholder is present. * **ContAuth**: card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). * **Moto**: mail-order and telephone-order transactions where the customer is in contact with the merchant via email or telephone. * **POS**: point-of-sale transactions where the customer is physically present to make a payment using a secure payment terminal. * **ANY**: all sales channels. ShopperInteraction string `json:"shopperInteraction"` SplitLogic SplitConfigurationLogic `json:"splitLogic"` } @@ -36,9 +38,10 @@ type SplitConfigurationRule struct { // 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 NewSplitConfigurationRule(currency string, paymentMethod string, shopperInteraction string, splitLogic SplitConfigurationLogic) *SplitConfigurationRule { +func NewSplitConfigurationRule(currency string, fundingSource string, paymentMethod string, shopperInteraction string, splitLogic SplitConfigurationLogic) *SplitConfigurationRule { this := SplitConfigurationRule{} this.Currency = currency + this.FundingSource = fundingSource this.PaymentMethod = paymentMethod this.ShopperInteraction = shopperInteraction this.SplitLogic = splitLogic @@ -53,6 +56,38 @@ func NewSplitConfigurationRuleWithDefaults() *SplitConfigurationRule { return &this } +// GetCardRegion returns the CardRegion field value if set, zero value otherwise. +func (o *SplitConfigurationRule) GetCardRegion() string { + if o == nil || common.IsNil(o.CardRegion) { + var ret string + return ret + } + return *o.CardRegion +} + +// GetCardRegionOk returns a tuple with the CardRegion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SplitConfigurationRule) GetCardRegionOk() (*string, bool) { + if o == nil || common.IsNil(o.CardRegion) { + return nil, false + } + return o.CardRegion, true +} + +// HasCardRegion returns a boolean if a field has been set. +func (o *SplitConfigurationRule) HasCardRegion() bool { + if o != nil && !common.IsNil(o.CardRegion) { + return true + } + + return false +} + +// SetCardRegion gets a reference to the given string and assigns it to the CardRegion field. +func (o *SplitConfigurationRule) SetCardRegion(v string) { + o.CardRegion = &v +} + // GetCurrency returns the Currency field value func (o *SplitConfigurationRule) GetCurrency() string { if o == nil { @@ -77,36 +112,28 @@ func (o *SplitConfigurationRule) SetCurrency(v string) { o.Currency = v } -// GetFundingSource returns the FundingSource field value if set, zero value otherwise. +// GetFundingSource returns the FundingSource field value func (o *SplitConfigurationRule) GetFundingSource() string { - if o == nil || common.IsNil(o.FundingSource) { + if o == nil { var ret string return ret } - return *o.FundingSource + + return o.FundingSource } -// GetFundingSourceOk returns a tuple with the FundingSource field value if set, nil otherwise +// GetFundingSourceOk returns a tuple with the FundingSource field value // and a boolean to check if the value has been set. func (o *SplitConfigurationRule) GetFundingSourceOk() (*string, bool) { - if o == nil || common.IsNil(o.FundingSource) { + if o == nil { return nil, false } - return o.FundingSource, true -} - -// HasFundingSource returns a boolean if a field has been set. -func (o *SplitConfigurationRule) HasFundingSource() bool { - if o != nil && !common.IsNil(o.FundingSource) { - return true - } - - return false + return &o.FundingSource, true } -// SetFundingSource gets a reference to the given string and assigns it to the FundingSource field. +// SetFundingSource sets field value func (o *SplitConfigurationRule) SetFundingSource(v string) { - o.FundingSource = &v + o.FundingSource = v } // GetPaymentMethod returns the PaymentMethod field value @@ -223,10 +250,11 @@ func (o SplitConfigurationRule) MarshalJSON() ([]byte, error) { func (o SplitConfigurationRule) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - toSerialize["currency"] = o.Currency - if !common.IsNil(o.FundingSource) { - toSerialize["fundingSource"] = o.FundingSource + if !common.IsNil(o.CardRegion) { + toSerialize["cardRegion"] = o.CardRegion } + toSerialize["currency"] = o.Currency + toSerialize["fundingSource"] = o.FundingSource toSerialize["paymentMethod"] = o.PaymentMethod if !common.IsNil(o.RuleId) { toSerialize["ruleId"] = o.RuleId @@ -272,6 +300,15 @@ func (v *NullableSplitConfigurationRule) UnmarshalJSON(src []byte) error { return json.Unmarshal(src, &v.value) } +func (o *SplitConfigurationRule) isValidCardRegion() bool { + var allowedEnumValues = []string{"international", "intraRegional", "interRegional", "domestic", "ANY"} + for _, allowed := range allowedEnumValues { + if o.GetCardRegion() == allowed { + return true + } + } + return false +} func (o *SplitConfigurationRule) isValidFundingSource() bool { var allowedEnumValues = []string{"charged", "credit", "debit", "deferred_debit", "prepaid", "ANY"} for _, allowed := range allowedEnumValues { diff --git a/src/management/model_store.go b/src/management/model_store.go index 6ad404de1..81912ddc8 100644 --- a/src/management/model_store.go +++ b/src/management/model_store.go @@ -39,7 +39,8 @@ type Store struct { ShopperStatement *string `json:"shopperStatement,omitempty"` SplitConfiguration *StoreSplitConfiguration `json:"splitConfiguration,omitempty"` // The status of the store. Possible values are: - **active**. This value is assigned automatically when a store is created. - **inactive**. The terminals under the store are blocked from accepting new transactions, but capturing outstanding transactions is still possible. - **closed**. This status is irreversible. The terminals under the store are reassigned to the merchant inventory. - Status *string `json:"status,omitempty"` + Status *string `json:"status,omitempty"` + SubMerchantData *SubMerchantData `json:"subMerchantData,omitempty"` } // NewStore instantiates a new Store object @@ -443,6 +444,38 @@ func (o *Store) SetStatus(v string) { o.Status = &v } +// GetSubMerchantData returns the SubMerchantData field value if set, zero value otherwise. +func (o *Store) GetSubMerchantData() SubMerchantData { + if o == nil || common.IsNil(o.SubMerchantData) { + var ret SubMerchantData + return ret + } + return *o.SubMerchantData +} + +// GetSubMerchantDataOk returns a tuple with the SubMerchantData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Store) GetSubMerchantDataOk() (*SubMerchantData, bool) { + if o == nil || common.IsNil(o.SubMerchantData) { + return nil, false + } + return o.SubMerchantData, true +} + +// HasSubMerchantData returns a boolean if a field has been set. +func (o *Store) HasSubMerchantData() bool { + if o != nil && !common.IsNil(o.SubMerchantData) { + return true + } + + return false +} + +// SetSubMerchantData gets a reference to the given SubMerchantData and assigns it to the SubMerchantData field. +func (o *Store) SetSubMerchantData(v SubMerchantData) { + o.SubMerchantData = &v +} + func (o Store) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -489,6 +522,9 @@ func (o Store) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Status) { toSerialize["status"] = o.Status } + if !common.IsNil(o.SubMerchantData) { + toSerialize["subMerchantData"] = o.SubMerchantData + } return toSerialize, nil } diff --git a/src/management/model_store_creation_request.go b/src/management/model_store_creation_request.go index 5b22a96a5..cc64b2cf1 100644 --- a/src/management/model_store_creation_request.go +++ b/src/management/model_store_creation_request.go @@ -33,6 +33,7 @@ type StoreCreationRequest struct { // The store name to be shown on the shopper's bank or credit card statement and on the shopper receipt. Maximum length: 22 characters; can't be all numbers. ShopperStatement string `json:"shopperStatement"` SplitConfiguration *StoreSplitConfiguration `json:"splitConfiguration,omitempty"` + SubMerchantData *SubMerchantData `json:"subMerchantData,omitempty"` } // NewStoreCreationRequest instantiates a new StoreCreationRequest object @@ -280,6 +281,38 @@ func (o *StoreCreationRequest) SetSplitConfiguration(v StoreSplitConfiguration) o.SplitConfiguration = &v } +// GetSubMerchantData returns the SubMerchantData field value if set, zero value otherwise. +func (o *StoreCreationRequest) GetSubMerchantData() SubMerchantData { + if o == nil || common.IsNil(o.SubMerchantData) { + var ret SubMerchantData + return ret + } + return *o.SubMerchantData +} + +// GetSubMerchantDataOk returns a tuple with the SubMerchantData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StoreCreationRequest) GetSubMerchantDataOk() (*SubMerchantData, bool) { + if o == nil || common.IsNil(o.SubMerchantData) { + return nil, false + } + return o.SubMerchantData, true +} + +// HasSubMerchantData returns a boolean if a field has been set. +func (o *StoreCreationRequest) HasSubMerchantData() bool { + if o != nil && !common.IsNil(o.SubMerchantData) { + return true + } + + return false +} + +// SetSubMerchantData gets a reference to the given SubMerchantData and assigns it to the SubMerchantData field. +func (o *StoreCreationRequest) SetSubMerchantData(v SubMerchantData) { + o.SubMerchantData = &v +} + func (o StoreCreationRequest) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -306,6 +339,9 @@ func (o StoreCreationRequest) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.SplitConfiguration) { toSerialize["splitConfiguration"] = o.SplitConfiguration } + if !common.IsNil(o.SubMerchantData) { + toSerialize["subMerchantData"] = o.SubMerchantData + } return toSerialize, nil } diff --git a/src/management/model_store_creation_with_merchant_code_request.go b/src/management/model_store_creation_with_merchant_code_request.go index fc6bf6d5d..bdaf914f6 100644 --- a/src/management/model_store_creation_with_merchant_code_request.go +++ b/src/management/model_store_creation_with_merchant_code_request.go @@ -35,6 +35,7 @@ type StoreCreationWithMerchantCodeRequest struct { // The store name to be shown on the shopper's bank or credit card statement and on the shopper receipt. Maximum length: 22 characters; can't be all numbers. ShopperStatement string `json:"shopperStatement"` SplitConfiguration *StoreSplitConfiguration `json:"splitConfiguration,omitempty"` + SubMerchantData *SubMerchantData `json:"subMerchantData,omitempty"` } // NewStoreCreationWithMerchantCodeRequest instantiates a new StoreCreationWithMerchantCodeRequest object @@ -307,6 +308,38 @@ func (o *StoreCreationWithMerchantCodeRequest) SetSplitConfiguration(v StoreSpli o.SplitConfiguration = &v } +// GetSubMerchantData returns the SubMerchantData field value if set, zero value otherwise. +func (o *StoreCreationWithMerchantCodeRequest) GetSubMerchantData() SubMerchantData { + if o == nil || common.IsNil(o.SubMerchantData) { + var ret SubMerchantData + return ret + } + return *o.SubMerchantData +} + +// GetSubMerchantDataOk returns a tuple with the SubMerchantData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StoreCreationWithMerchantCodeRequest) GetSubMerchantDataOk() (*SubMerchantData, bool) { + if o == nil || common.IsNil(o.SubMerchantData) { + return nil, false + } + return o.SubMerchantData, true +} + +// HasSubMerchantData returns a boolean if a field has been set. +func (o *StoreCreationWithMerchantCodeRequest) HasSubMerchantData() bool { + if o != nil && !common.IsNil(o.SubMerchantData) { + return true + } + + return false +} + +// SetSubMerchantData gets a reference to the given SubMerchantData and assigns it to the SubMerchantData field. +func (o *StoreCreationWithMerchantCodeRequest) SetSubMerchantData(v SubMerchantData) { + o.SubMerchantData = &v +} + func (o StoreCreationWithMerchantCodeRequest) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -334,6 +367,9 @@ func (o StoreCreationWithMerchantCodeRequest) ToMap() (map[string]interface{}, e if !common.IsNil(o.SplitConfiguration) { toSerialize["splitConfiguration"] = o.SplitConfiguration } + if !common.IsNil(o.SubMerchantData) { + toSerialize["subMerchantData"] = o.SubMerchantData + } return toSerialize, nil } diff --git a/src/management/model_sub_merchant_data.go b/src/management/model_sub_merchant_data.go new file mode 100644 index 000000000..08d3aeaaa --- /dev/null +++ b/src/management/model_sub_merchant_data.go @@ -0,0 +1,200 @@ +/* +Management API + +API version: 3 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package management + +import ( + "encoding/json" + + "github.com/adyen/adyen-go-api-library/v21/src/common" +) + +// checks if the SubMerchantData type satisfies the MappedNullable interface at compile time +var _ common.MappedNullable = &SubMerchantData{} + +// SubMerchantData struct for SubMerchantData +type SubMerchantData struct { + // The email associated with the sub-merchant's account. + Email string `json:"email"` + // A unique identifier that you create for the sub-merchant, used by schemes to identify the sub-merchant. * Format: Alphanumeric * Maximum length: 15 characters + Id string `json:"id"` + // The sub-merchant's 4-digit Merchant Category Code (MCC). * Format: Numeric * Fixed length: 4 digits + Mcc string `json:"mcc"` + // The name of the sub-merchant. Based on scheme specifications, this value will overwrite the shopper statement that will appear in the card statement. * Format: Alphanumeric * Maximum length: 22 characters + Name string `json:"name"` +} + +// NewSubMerchantData instantiates a new SubMerchantData 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 NewSubMerchantData(email string, id string, mcc string, name string) *SubMerchantData { + this := SubMerchantData{} + this.Email = email + this.Id = id + this.Mcc = mcc + this.Name = name + return &this +} + +// NewSubMerchantDataWithDefaults instantiates a new SubMerchantData 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 NewSubMerchantDataWithDefaults() *SubMerchantData { + this := SubMerchantData{} + return &this +} + +// GetEmail returns the Email field value +func (o *SubMerchantData) GetEmail() string { + if o == nil { + var ret string + return ret + } + + return o.Email +} + +// GetEmailOk returns a tuple with the Email field value +// and a boolean to check if the value has been set. +func (o *SubMerchantData) GetEmailOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Email, true +} + +// SetEmail sets field value +func (o *SubMerchantData) SetEmail(v string) { + o.Email = v +} + +// GetId returns the Id field value +func (o *SubMerchantData) GetId() string { + if o == nil { + var ret string + return ret + } + + return o.Id +} + +// GetIdOk returns a tuple with the Id field value +// and a boolean to check if the value has been set. +func (o *SubMerchantData) GetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Id, true +} + +// SetId sets field value +func (o *SubMerchantData) SetId(v string) { + o.Id = v +} + +// GetMcc returns the Mcc field value +func (o *SubMerchantData) GetMcc() string { + if o == nil { + var ret string + return ret + } + + return o.Mcc +} + +// GetMccOk returns a tuple with the Mcc field value +// and a boolean to check if the value has been set. +func (o *SubMerchantData) GetMccOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Mcc, true +} + +// SetMcc sets field value +func (o *SubMerchantData) SetMcc(v string) { + o.Mcc = v +} + +// GetName returns the Name field value +func (o *SubMerchantData) GetName() string { + if o == nil { + var ret string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *SubMerchantData) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Name, true +} + +// SetName sets field value +func (o *SubMerchantData) SetName(v string) { + o.Name = v +} + +func (o SubMerchantData) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SubMerchantData) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["email"] = o.Email + toSerialize["id"] = o.Id + toSerialize["mcc"] = o.Mcc + toSerialize["name"] = o.Name + return toSerialize, nil +} + +type NullableSubMerchantData struct { + value *SubMerchantData + isSet bool +} + +func (v NullableSubMerchantData) Get() *SubMerchantData { + return v.value +} + +func (v *NullableSubMerchantData) Set(val *SubMerchantData) { + v.value = val + v.isSet = true +} + +func (v NullableSubMerchantData) IsSet() bool { + return v.isSet +} + +func (v *NullableSubMerchantData) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubMerchantData(val *SubMerchantData) *NullableSubMerchantData { + return &NullableSubMerchantData{value: val, isSet: true} +} + +func (v NullableSubMerchantData) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubMerchantData) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/src/management/model_test_output.go b/src/management/model_test_output.go index 05c382c9f..902291580 100644 --- a/src/management/model_test_output.go +++ b/src/management/model_test_output.go @@ -21,7 +21,7 @@ var _ common.MappedNullable = &TestOutput{} type TestOutput struct { // Unique identifier of the merchant account that the notification is about. MerchantId *string `json:"merchantId,omitempty"` - // A short, human-readable explanation of the test result. Your server must respond with **HTTP 2xx* for the test webhook to be successful (`data.status`: **success**). Find out more about [accepting notifications](https://docs.adyen.com/development-resources/webhooks#accept-notifications) You can use the value of this field together with the [`responseCode`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-responseCode) value to troubleshoot unsuccessful test webhooks. + // A short, human-readable explanation of the test result. Your server must respond with **HTTP 2xx* for the test webhook to be successful (`data.status`: **success**). Find out more about [accepting notifications](https://docs.adyen.com/development-resources/webhooks/#accept-webhooks) You can use the value of this field together with the [`responseCode`](https://docs.adyen.com/api-explorer/#/ManagementService/v1/post/merchants/{merchantId}/webhooks/{id}/test__resParam_data-responseCode) value to troubleshoot unsuccessful test webhooks. Output *string `json:"output,omitempty"` // The [body of the notification webhook](https://docs.adyen.com/development-resources/webhooks/understand-notifications#notification-structure) that was sent to your server. RequestSent *string `json:"requestSent,omitempty"` diff --git a/src/management/model_unreferenced.go b/src/management/model_unreferenced.go new file mode 100644 index 000000000..232dd3136 --- /dev/null +++ b/src/management/model_unreferenced.go @@ -0,0 +1,125 @@ +/* +Management API + +API version: 3 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package management + +import ( + "encoding/json" + + "github.com/adyen/adyen-go-api-library/v21/src/common" +) + +// checks if the Unreferenced type satisfies the MappedNullable interface at compile time +var _ common.MappedNullable = &Unreferenced{} + +// Unreferenced struct for Unreferenced +type Unreferenced struct { + // Indicates whether unreferenced refunds are enabled on the terminal. + EnableUnreferencedRefunds *bool `json:"enableUnreferencedRefunds,omitempty"` +} + +// NewUnreferenced instantiates a new Unreferenced 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 NewUnreferenced() *Unreferenced { + this := Unreferenced{} + return &this +} + +// NewUnreferencedWithDefaults instantiates a new Unreferenced 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 NewUnreferencedWithDefaults() *Unreferenced { + this := Unreferenced{} + return &this +} + +// GetEnableUnreferencedRefunds returns the EnableUnreferencedRefunds field value if set, zero value otherwise. +func (o *Unreferenced) GetEnableUnreferencedRefunds() bool { + if o == nil || common.IsNil(o.EnableUnreferencedRefunds) { + var ret bool + return ret + } + return *o.EnableUnreferencedRefunds +} + +// GetEnableUnreferencedRefundsOk returns a tuple with the EnableUnreferencedRefunds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Unreferenced) GetEnableUnreferencedRefundsOk() (*bool, bool) { + if o == nil || common.IsNil(o.EnableUnreferencedRefunds) { + return nil, false + } + return o.EnableUnreferencedRefunds, true +} + +// HasEnableUnreferencedRefunds returns a boolean if a field has been set. +func (o *Unreferenced) HasEnableUnreferencedRefunds() bool { + if o != nil && !common.IsNil(o.EnableUnreferencedRefunds) { + return true + } + + return false +} + +// SetEnableUnreferencedRefunds gets a reference to the given bool and assigns it to the EnableUnreferencedRefunds field. +func (o *Unreferenced) SetEnableUnreferencedRefunds(v bool) { + o.EnableUnreferencedRefunds = &v +} + +func (o Unreferenced) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Unreferenced) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !common.IsNil(o.EnableUnreferencedRefunds) { + toSerialize["enableUnreferencedRefunds"] = o.EnableUnreferencedRefunds + } + return toSerialize, nil +} + +type NullableUnreferenced struct { + value *Unreferenced + isSet bool +} + +func (v NullableUnreferenced) Get() *Unreferenced { + return v.value +} + +func (v *NullableUnreferenced) Set(val *Unreferenced) { + v.value = val + v.isSet = true +} + +func (v NullableUnreferenced) IsSet() bool { + return v.isSet +} + +func (v *NullableUnreferenced) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnreferenced(val *Unreferenced) *NullableUnreferenced { + return &NullableUnreferenced{value: val, isSet: true} +} + +func (v NullableUnreferenced) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnreferenced) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/src/management/model_update_payment_method_info.go b/src/management/model_update_payment_method_info.go index ca5a010ad..ac98dadcf 100644 --- a/src/management/model_update_payment_method_info.go +++ b/src/management/model_update_payment_method_info.go @@ -34,17 +34,19 @@ type UpdatePaymentMethodInfo struct { EftDirectdebitCA *GenericPmWithTdiInfo `json:"eft_directdebit_CA,omitempty"` EftposAustralia *GenericPmWithTdiInfo `json:"eftpos_australia,omitempty"` // Indicates whether the payment method is enabled (**true**) or disabled (**false**). - Enabled *bool `json:"enabled,omitempty"` - Girocard *GenericPmWithTdiInfo `json:"girocard,omitempty"` - Ideal *GenericPmWithTdiInfo `json:"ideal,omitempty"` - InteracCard *GenericPmWithTdiInfo `json:"interac_card,omitempty"` - Jcb *GenericPmWithTdiInfo `json:"jcb,omitempty"` - Maestro *GenericPmWithTdiInfo `json:"maestro,omitempty"` - Mc *GenericPmWithTdiInfo `json:"mc,omitempty"` - Nyce *NyceInfo `json:"nyce,omitempty"` - PaybybankPlaid *PayByBankPlaidInfo `json:"paybybank_plaid,omitempty"` - Pulse *PulseInfo `json:"pulse,omitempty"` - Star *StarInfo `json:"star,omitempty"` + Enabled *bool `json:"enabled,omitempty"` + Girocard *GenericPmWithTdiInfo `json:"girocard,omitempty"` + Ideal *GenericPmWithTdiInfo `json:"ideal,omitempty"` + InteracCard *GenericPmWithTdiInfo `json:"interac_card,omitempty"` + Jcb *GenericPmWithTdiInfo `json:"jcb,omitempty"` + Maestro *GenericPmWithTdiInfo `json:"maestro,omitempty"` + MaestroUsa *GenericPmWithTdiInfo `json:"maestro_usa,omitempty"` + Mc *GenericPmWithTdiInfo `json:"mc,omitempty"` + Nyce *NyceInfo `json:"nyce,omitempty"` + PaybybankPlaid *PayByBankPlaidInfo `json:"paybybank_plaid,omitempty"` + Pulse *PulseInfo `json:"pulse,omitempty"` + Sepadirectdebit *SepaDirectDebitInfo `json:"sepadirectdebit,omitempty"` + Star *StarInfo `json:"star,omitempty"` // The store for this payment method StoreId *string `json:"storeId,omitempty"` // The list of stores for this payment method @@ -615,6 +617,38 @@ func (o *UpdatePaymentMethodInfo) SetMaestro(v GenericPmWithTdiInfo) { o.Maestro = &v } +// GetMaestroUsa returns the MaestroUsa field value if set, zero value otherwise. +func (o *UpdatePaymentMethodInfo) GetMaestroUsa() GenericPmWithTdiInfo { + if o == nil || common.IsNil(o.MaestroUsa) { + var ret GenericPmWithTdiInfo + return ret + } + return *o.MaestroUsa +} + +// GetMaestroUsaOk returns a tuple with the MaestroUsa field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdatePaymentMethodInfo) GetMaestroUsaOk() (*GenericPmWithTdiInfo, bool) { + if o == nil || common.IsNil(o.MaestroUsa) { + return nil, false + } + return o.MaestroUsa, true +} + +// HasMaestroUsa returns a boolean if a field has been set. +func (o *UpdatePaymentMethodInfo) HasMaestroUsa() bool { + if o != nil && !common.IsNil(o.MaestroUsa) { + return true + } + + return false +} + +// SetMaestroUsa gets a reference to the given GenericPmWithTdiInfo and assigns it to the MaestroUsa field. +func (o *UpdatePaymentMethodInfo) SetMaestroUsa(v GenericPmWithTdiInfo) { + o.MaestroUsa = &v +} + // GetMc returns the Mc field value if set, zero value otherwise. func (o *UpdatePaymentMethodInfo) GetMc() GenericPmWithTdiInfo { if o == nil || common.IsNil(o.Mc) { @@ -743,6 +777,38 @@ func (o *UpdatePaymentMethodInfo) SetPulse(v PulseInfo) { o.Pulse = &v } +// GetSepadirectdebit returns the Sepadirectdebit field value if set, zero value otherwise. +func (o *UpdatePaymentMethodInfo) GetSepadirectdebit() SepaDirectDebitInfo { + if o == nil || common.IsNil(o.Sepadirectdebit) { + var ret SepaDirectDebitInfo + return ret + } + return *o.Sepadirectdebit +} + +// GetSepadirectdebitOk returns a tuple with the Sepadirectdebit field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdatePaymentMethodInfo) GetSepadirectdebitOk() (*SepaDirectDebitInfo, bool) { + if o == nil || common.IsNil(o.Sepadirectdebit) { + return nil, false + } + return o.Sepadirectdebit, true +} + +// HasSepadirectdebit returns a boolean if a field has been set. +func (o *UpdatePaymentMethodInfo) HasSepadirectdebit() bool { + if o != nil && !common.IsNil(o.Sepadirectdebit) { + return true + } + + return false +} + +// SetSepadirectdebit gets a reference to the given SepaDirectDebitInfo and assigns it to the Sepadirectdebit field. +func (o *UpdatePaymentMethodInfo) SetSepadirectdebit(v SepaDirectDebitInfo) { + o.Sepadirectdebit = &v +} + // GetStar returns the Star field value if set, zero value otherwise. func (o *UpdatePaymentMethodInfo) GetStar() StarInfo { if o == nil || common.IsNil(o.Star) { @@ -938,6 +1004,9 @@ func (o UpdatePaymentMethodInfo) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Maestro) { toSerialize["maestro"] = o.Maestro } + if !common.IsNil(o.MaestroUsa) { + toSerialize["maestro_usa"] = o.MaestroUsa + } if !common.IsNil(o.Mc) { toSerialize["mc"] = o.Mc } @@ -950,6 +1019,9 @@ func (o UpdatePaymentMethodInfo) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Pulse) { toSerialize["pulse"] = o.Pulse } + if !common.IsNil(o.Sepadirectdebit) { + toSerialize["sepadirectdebit"] = o.Sepadirectdebit + } if !common.IsNil(o.Star) { toSerialize["star"] = o.Star } diff --git a/src/management/model_update_split_configuration_rule_request.go b/src/management/model_update_split_configuration_rule_request.go index 69137015f..f3ad3b998 100644 --- a/src/management/model_update_split_configuration_rule_request.go +++ b/src/management/model_update_split_configuration_rule_request.go @@ -21,11 +21,11 @@ var _ common.MappedNullable = &UpdateSplitConfigurationRuleRequest{} type UpdateSplitConfigurationRuleRequest struct { // The currency condition that defines whether the split logic applies. Its value must be a three-character [ISO currency code](https://en.wikipedia.org/wiki/ISO_4217). Currency string `json:"currency"` - // The funding source of the payment method. This only applies to card transactions. Possible values: * **credit** * **debit** * **prepaid** * **deferred_debit** * **charged** * **ANY** - FundingSource *string `json:"fundingSource,omitempty"` + // The funding source of the payment method. Possible values: * **credit** * **debit** * **prepaid** * **deferred_debit** * **charged** * **ANY** + FundingSource string `json:"fundingSource"` // The payment method condition that defines whether the split logic applies. Possible values: * [Payment method variant](https://docs.adyen.com/development-resources/paymentmethodvariant): Apply the split logic for a specific payment method. * **ANY**: Apply the split logic for all available payment methods. PaymentMethod string `json:"paymentMethod"` - // The sales channel condition that defines whether the split logic applies. Possible values: * **Ecommerce**: Online transactions where the cardholder is present. * **ContAuth**: Card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). * **Moto**: Mail-order and telephone-order transactions where the customer is in contact with the merchant via email or telephone. * **POS**: Point-of-sale transactions where the customer is physically present to make a payment using a secure payment terminal. * **ANY**: All sales channels. + // The sales channel condition that defines whether the split logic applies. Possible values: * **Ecommerce**: online transactions where the cardholder is present. * **ContAuth**: card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). * **Moto**: mail-order and telephone-order transactions where the customer is in contact with the merchant via email or telephone. * **POS**: point-of-sale transactions where the customer is physically present to make a payment using a secure payment terminal. * **ANY**: all sales channels. ShopperInteraction string `json:"shopperInteraction"` } @@ -33,9 +33,10 @@ type UpdateSplitConfigurationRuleRequest struct { // 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 NewUpdateSplitConfigurationRuleRequest(currency string, paymentMethod string, shopperInteraction string) *UpdateSplitConfigurationRuleRequest { +func NewUpdateSplitConfigurationRuleRequest(currency string, fundingSource string, paymentMethod string, shopperInteraction string) *UpdateSplitConfigurationRuleRequest { this := UpdateSplitConfigurationRuleRequest{} this.Currency = currency + this.FundingSource = fundingSource this.PaymentMethod = paymentMethod this.ShopperInteraction = shopperInteraction return &this @@ -73,36 +74,28 @@ func (o *UpdateSplitConfigurationRuleRequest) SetCurrency(v string) { o.Currency = v } -// GetFundingSource returns the FundingSource field value if set, zero value otherwise. +// GetFundingSource returns the FundingSource field value func (o *UpdateSplitConfigurationRuleRequest) GetFundingSource() string { - if o == nil || common.IsNil(o.FundingSource) { + if o == nil { var ret string return ret } - return *o.FundingSource + + return o.FundingSource } -// GetFundingSourceOk returns a tuple with the FundingSource field value if set, nil otherwise +// GetFundingSourceOk returns a tuple with the FundingSource field value // and a boolean to check if the value has been set. func (o *UpdateSplitConfigurationRuleRequest) GetFundingSourceOk() (*string, bool) { - if o == nil || common.IsNil(o.FundingSource) { + if o == nil { return nil, false } - return o.FundingSource, true -} - -// HasFundingSource returns a boolean if a field has been set. -func (o *UpdateSplitConfigurationRuleRequest) HasFundingSource() bool { - if o != nil && !common.IsNil(o.FundingSource) { - return true - } - - return false + return &o.FundingSource, true } -// SetFundingSource gets a reference to the given string and assigns it to the FundingSource field. +// SetFundingSource sets field value func (o *UpdateSplitConfigurationRuleRequest) SetFundingSource(v string) { - o.FundingSource = &v + o.FundingSource = v } // GetPaymentMethod returns the PaymentMethod field value @@ -164,9 +157,7 @@ func (o UpdateSplitConfigurationRuleRequest) MarshalJSON() ([]byte, error) { func (o UpdateSplitConfigurationRuleRequest) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} toSerialize["currency"] = o.Currency - if !common.IsNil(o.FundingSource) { - toSerialize["fundingSource"] = o.FundingSource - } + toSerialize["fundingSource"] = o.FundingSource toSerialize["paymentMethod"] = o.PaymentMethod toSerialize["shopperInteraction"] = o.ShopperInteraction return toSerialize, nil diff --git a/src/management/model_update_store_request.go b/src/management/model_update_store_request.go index 1b8ebf622..95c452507 100644 --- a/src/management/model_update_store_request.go +++ b/src/management/model_update_store_request.go @@ -30,7 +30,8 @@ type UpdateStoreRequest struct { PhoneNumber *string `json:"phoneNumber,omitempty"` SplitConfiguration *StoreSplitConfiguration `json:"splitConfiguration,omitempty"` // The status of the store. Possible values are: - **active**: This value is assigned automatically when a store is created. - **inactive**: The maximum [transaction limits and number of Store-and-Forward transactions](https://docs.adyen.com/point-of-sale/determine-account-structure/configure-features#payment-features) for the store are set to 0. This blocks new transactions, but captures are still possible. - **closed**: The terminals of the store are reassigned to the merchant inventory, so they can't process payments. You can change the status from **active** to **inactive**, and from **inactive** to **active** or **closed**. Once **closed**, a store can't be reopened. - Status *string `json:"status,omitempty"` + Status *string `json:"status,omitempty"` + SubMerchantData *SubMerchantData `json:"subMerchantData,omitempty"` } // NewUpdateStoreRequest instantiates a new UpdateStoreRequest object @@ -274,6 +275,38 @@ func (o *UpdateStoreRequest) SetStatus(v string) { o.Status = &v } +// GetSubMerchantData returns the SubMerchantData field value if set, zero value otherwise. +func (o *UpdateStoreRequest) GetSubMerchantData() SubMerchantData { + if o == nil || common.IsNil(o.SubMerchantData) { + var ret SubMerchantData + return ret + } + return *o.SubMerchantData +} + +// GetSubMerchantDataOk returns a tuple with the SubMerchantData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateStoreRequest) GetSubMerchantDataOk() (*SubMerchantData, bool) { + if o == nil || common.IsNil(o.SubMerchantData) { + return nil, false + } + return o.SubMerchantData, true +} + +// HasSubMerchantData returns a boolean if a field has been set. +func (o *UpdateStoreRequest) HasSubMerchantData() bool { + if o != nil && !common.IsNil(o.SubMerchantData) { + return true + } + + return false +} + +// SetSubMerchantData gets a reference to the given SubMerchantData and assigns it to the SubMerchantData field. +func (o *UpdateStoreRequest) SetSubMerchantData(v SubMerchantData) { + o.SubMerchantData = &v +} + func (o UpdateStoreRequest) MarshalJSON() ([]byte, error) { toSerialize, err := o.ToMap() if err != nil { @@ -305,6 +338,9 @@ func (o UpdateStoreRequest) ToMap() (map[string]interface{}, error) { if !common.IsNil(o.Status) { toSerialize["status"] = o.Status } + if !common.IsNil(o.SubMerchantData) { + toSerialize["subMerchantData"] = o.SubMerchantData + } return toSerialize, nil } diff --git a/src/management/model_webhook.go b/src/management/model_webhook.go index 637ed3b6c..2104de3db 100644 --- a/src/management/model_webhook.go +++ b/src/management/model_webhook.go @@ -55,7 +55,7 @@ type Webhook struct { NetworkType *string `json:"networkType,omitempty"` // Indicates if the SOAP action header needs to be populated. Default value: **false**. Only applies if `communicationFormat`: **soap**. PopulateSoapActionHeader *bool `json:"populateSoapActionHeader,omitempty"` - // The type of webhook. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **terminal-api-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard notification webhooks](https://docs.adyen.com/development-resources/webhooks/understand-notifications#event-codes) and [other types of notifications](https://docs.adyen.com/development-resources/webhooks/understand-notifications#other-notifications). + // The type of webhook. Possible values are: - **standard** - **account-settings-notification** - **banktransfer-notification** - **boletobancario-notification** - **directdebit-notification** - **ach-notification-of-change-notification** - **direct-debit-notice-of-change-notification** - **pending-notification** - **ideal-notification** - **ideal-pending-notification** - **report-notification** - **terminal-api-notification** - **terminal-settings** - **terminal-boarding** Find out more about [standard webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#event-codes) and [other types of webhooks](https://docs.adyen.com/development-resources/webhooks/webhook-types/#other-webhooks). Type string `json:"type"` // Public URL where webhooks will be sent, for example **https://www.domain.com/webhook-endpoint**. Url string `json:"url"`