Rate this page:

TwiML™ Voice: <Parameter>

The TwiML <Pay> verb's <Parameter> noun allows you to:

  • send custom parameters to your payment processor when using a Generic Pay Connector
  • send ACH information not included as part of the <Pay> verb

<Parameter> attributes

The <Parameter> noun takes two attributes, name (for the name of the parameter) and value (for the value of the parameter). Both attribute values must be strings.

Send custom parameters using a Generic Pay Connector

If you are using a Generic Pay Connector, you can send custom parameters to your payment processor using the <Parameter> noun. This functionality could be used to send additional contextual information about the transaction. For example, you could inform the payment processor to waive fees, charge fees, process a refund, etc.

The <Parameter> noun is nested within the <Pay> verb's open and closing tags, and takes name and value attributes for the name and value of your custom parameter.

The example below shows a charge transaction using the <Parameter> noun to pass custom parameters to the payment processor.

You can also pass custom parameters for tokenize transactions in the same manner.

There is no limit to the number of custom parameters you can nest within a <Pay> verb.

Loading Code Sample...

        Send custom parameters with <Parameter>

        Send ACH information when accepting ACH payments

        The <Parameter> noun is a subelement within the <Pay> verb. This noun, <Parameter>, is required when accepting ACH payments in order to capture certain ACH information not included as part of the <Pay> verb to send to the payment provider. The value(s) that have to be captured by <Parameter> depend on the payment provider.

        <Pay chargeAmount="10.0" description="pizza" paymentMethod="ach-debit" paymentConnector="myConnector" action="myactionurl">
          <Parameter name="AVSName" value="CallerABC"/>
        Rate this page:

        Need some help?

        We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd by visiting Twilio's Stack Overflow Collective or browsing the Twilio tag on Stack Overflow.

        Loading Code Sample...

              Thank you for your feedback!

              Please select the reason(s) for your feedback. The additional information you provide helps us improve our documentation:

              Sending your feedback...
              🎉 Thank you for your feedback!
              Something went wrong. Please try again.

              Thanks for your feedback!