// Code generated by applyconfiguration-gen. DO NOT EDIT.

package v1alpha1

// OAuth2EndpointParamApplyConfiguration represents a declarative configuration of the OAuth2EndpointParam type for use
// with apply.
//
// OAuth2EndpointParam defines a name/value parameter for the OAuth2 token URL.
type OAuth2EndpointParamApplyConfiguration struct {
	// name is the parameter name. Must be between 1 and 256 characters.
	Name *string `json:"name,omitempty"`
	// value is the optional parameter value. When omitted, the query parameter is applied as ?name (no value).
	// When set (including to the empty string), it is applied as ?name=value. Empty string may be used when the
	// external system expects a parameter with an empty value (e.g. ?parameter="").
	// Must be between 0 and 2048 characters when present (aligned with common URL length recommendations).
	Value *string `json:"value,omitempty"`
}

// OAuth2EndpointParamApplyConfiguration constructs a declarative configuration of the OAuth2EndpointParam type for use with
// apply.
func OAuth2EndpointParam() *OAuth2EndpointParamApplyConfiguration {
	return &OAuth2EndpointParamApplyConfiguration{}
}

// WithName sets the Name field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Name field is set to the value of the last call.
func (b *OAuth2EndpointParamApplyConfiguration) WithName(value string) *OAuth2EndpointParamApplyConfiguration {
	b.Name = &value
	return b
}

// WithValue sets the Value field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Value field is set to the value of the last call.
func (b *OAuth2EndpointParamApplyConfiguration) WithValue(value string) *OAuth2EndpointParamApplyConfiguration {
	b.Value = &value
	return b
}
