func (c *ApiService) CreatePayments(CallSid string, params *CreatePaymentsParams) (*ApiV2010Payments, error) {
	path := "/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}/Payments.json"
	if params != nil && params.PathAccountSid != nil {
		path = strings.Replace(path, "{"+"AccountSid"+"}", *params.PathAccountSid, -1)
	} else {
		path = strings.Replace(path, "{"+"AccountSid"+"}", c.requestHandler.Client.AccountSid(), -1)
	}
	path = strings.Replace(path, "{"+"CallSid"+"}", CallSid, -1)
	data := url.Values{}
	headers := make(map[string]interface{})
	if params != nil && params.BankAccountType != nil {
		data.Set("BankAccountType", *params.BankAccountType)
	}
	if params != nil && params.ChargeAmount != nil {
		data.Set("ChargeAmount", fmt.Sprint(*params.ChargeAmount))
	}
	if params != nil && params.Currency != nil {
		data.Set("Currency", *params.Currency)
	}
	if params != nil && params.Description != nil {
		data.Set("Description", *params.Description)
	}
	if params != nil && params.IdempotencyKey != nil {
		data.Set("IdempotencyKey", *params.IdempotencyKey)
	}
	if params != nil && params.Input != nil {
		data.Set("Input", *params.Input)
	}
	if params != nil && params.MinPostalCodeLength != nil {
		data.Set("MinPostalCodeLength", fmt.Sprint(*params.MinPostalCodeLength))
	}
	if params != nil && params.Parameter != nil {
		v, err := json.Marshal(params.Parameter)
		if err != nil {
			return nil, err
		}
		data.Set("Parameter", string(v))
	}
	if params != nil && params.PaymentConnector != nil {
		data.Set("PaymentConnector", *params.PaymentConnector)
	}
	if params != nil && params.PaymentMethod != nil {
		data.Set("PaymentMethod", *params.PaymentMethod)
	}
	if params != nil && params.PostalCode != nil {
		data.Set("PostalCode", fmt.Sprint(*params.PostalCode))
	}
	if params != nil && params.SecurityCode != nil {
		data.Set("SecurityCode", fmt.Sprint(*params.SecurityCode))
	}
	if params != nil && params.StatusCallback != nil {
		data.Set("StatusCallback", *params.StatusCallback)
	}
	if params != nil && params.Timeout != nil {
		data.Set("Timeout", fmt.Sprint(*params.Timeout))
	}
	if params != nil && params.TokenType != nil {
		data.Set("TokenType", *params.TokenType)
	}
	if params != nil && params.ValidCardTypes != nil {
		data.Set("ValidCardTypes", *params.ValidCardTypes)
	}
	resp, err := c.requestHandler.Post(c.baseURL+path, data, headers)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	ps := &ApiV2010Payments{}
	if err := json.NewDecoder(resp.Body).Decode(ps); err != nil {
		return nil, err
	}
	return ps, err
}
create an instance of payments. This will start a new payments session
package openapi
import (
	"encoding/json"
	"fmt"
	"net/url"
	"strings"
)
type CreatePaymentsParams struct {
	PathAccountSid *string `json:"PathAccountSid,omitempty"`
	BankAccountType *string `json:"BankAccountType,omitempty"`
	ChargeAmount *float32 `json:"ChargeAmount,omitempty"`
	Currency *string `json:"Currency,omitempty"`
	Description *string `json:"Description,omitempty"`
	IdempotencyKey *string `json:"IdempotencyKey,omitempty"`
	Input *string `json:"Input,omitempty"`
	MinPostalCodeLength *int `json:"MinPostalCodeLength,omitempty"`
	Parameter *map[string]interface{} `json:"Parameter,omitempty"`
	PaymentConnector *string `json:"PaymentConnector,omitempty"`
	PaymentMethod *string `json:"PaymentMethod,omitempty"`
	PostalCode *bool `json:"PostalCode,omitempty"`
	SecurityCode *bool `json:"SecurityCode,omitempty"`
	StatusCallback *string `json:"StatusCallback,omitempty"`
	Timeout *int `json:"Timeout,omitempty"`
	TokenType *string `json:"TokenType,omitempty"`
	ValidCardTypes *string `json:"ValidCardTypes,omitempty"`
}
func (params *CreatePaymentsParams) SetPathAccountSid(PathAccountSid string) *CreatePaymentsParams {
	params.PathAccountSid = &PathAccountSid
	return params
}
func (params *CreatePaymentsParams) SetBankAccountType(BankAccountType string) *CreatePaymentsParams {
	params.BankAccountType = &BankAccountType
	return params
}
func (params *CreatePaymentsParams) SetChargeAmount(ChargeAmount float32) *CreatePaymentsParams {
	params.ChargeAmount = &ChargeAmount
	return params
}
func (params *CreatePaymentsParams) SetCurrency(Currency string) *CreatePaymentsParams {
	params.Currency = &Currency
	return params
}
func (params *CreatePaymentsParams) SetDescription(Description string) *CreatePaymentsParams {
	params.Description = &Description
	return params
}
func (params *CreatePaymentsParams) SetIdempotencyKey(IdempotencyKey string) *CreatePaymentsParams {
	params.IdempotencyKey = &IdempotencyKey
	return params
}
func (params *CreatePaymentsParams) SetInput(Input string) *CreatePaymentsParams {
	params.Input = &Input
	return params
}
func (params *CreatePaymentsParams) SetMinPostalCodeLength(MinPostalCodeLength int) *CreatePaymentsParams {
	params.MinPostalCodeLength = &MinPostalCodeLength
	return params
}
func (params *CreatePaymentsParams) SetParameter(Parameter map[string]interface{}) *CreatePaymentsParams {
	params.Parameter = &Parameter
	return params
}
func (params *CreatePaymentsParams) SetPaymentConnector(PaymentConnector string) *CreatePaymentsParams {
	params.PaymentConnector = &PaymentConnector
	return params
}
func (params *CreatePaymentsParams) SetPaymentMethod(PaymentMethod string) *CreatePaymentsParams {
	params.PaymentMethod = &PaymentMethod
	return params
}
func (params *CreatePaymentsParams) SetPostalCode(PostalCode bool) *CreatePaymentsParams {
	params.PostalCode = &PostalCode
	return params
}
func (params *CreatePaymentsParams) SetSecurityCode(SecurityCode bool) *CreatePaymentsParams {
	params.SecurityCode = &SecurityCode
	return params
}
func (params *CreatePaymentsParams) SetStatusCallback(StatusCallback string) *CreatePaymentsParams {
	params.StatusCallback = &StatusCallback
	return params
}
func (params *CreatePaymentsParams) SetTimeout(Timeout int) *CreatePaymentsParams {
	params.Timeout = &Timeout
	return params
}
func (params *CreatePaymentsParams) SetTokenType(TokenType string) *CreatePaymentsParams {
	params.TokenType = &TokenType
	return params
}
func (params *CreatePaymentsParams) SetValidCardTypes(ValidCardTypes string) *CreatePaymentsParams {
	params.ValidCardTypes = &ValidCardTypes
	return params
}