Get custom form fields through API


(Dodini Behavioral Health, Pllc) #1

I have a custom field on my form that doesn’t come through in the API request for Transactions. How can I get this information?


(Jared Dellitt) #2

Hey @Dodini_Behavioral_He, could you be more specific? Are you referring to the metadata field when initiating a transfer?


(Dodini Behavioral Health, Pllc) #3

I am not sure if it is called metadata but that is likely what it is. My business partner added a dropdown custom field to my form to indicate WHO at our clinic was was being paid but that name/email address from the dropdown doesn’t come thru in the json response from the api. Do I need to make another request to get the “metadata”?


(Spencer Hunter) #4

@Dodini_Behavioral_He, Can you provide additional details about your application as well as which API version you are using (v1 vs. v2)? If metadata was attached to a transfer request then your application can fetch this metadata after the resource was created.


(Dodini Behavioral Health, Pllc) #5

using v1. (Is the v2 available without going whitelabel?)
I am not sure what else to tell you about the application.
The form has a dropdown field that contains a name and email address.
I am pulling the Transactions and getting only the “standard” properties. I SEE a metadata tag but have alway seen it as null. Do I need to do something to connect up the dropdown from the form to the metadata that gets pulled with the transaction call?


(Spencer Hunter) #6

@Dodini_Behavioral_He, You’ll want to pass the values selected and submitted in the form to your server which will call our API to initiate the transaction. These fields will need to be passed in as metadata in the Send money request or else metadata will return as null when fetching the transaction because nothing was supplied. Metadata is only visible to an application via the API. Example of Send Money with metadata:

POST https://https://uat.dwolla.com/oauth/rest/transactions/send
Content-Type: application/json
Authorization: Bearer {account access token}

{
  "amount": 50,
  "destinationId": "812-114-7461",
  "destinationType": "Dwolla",
  "fundsSource": "balance",
  "notes": "This is a note",
  "pin": 1234,
  "metadata": {
      "email": "emailvalue",
      "name": "namevalue"
  }
}

v2 is available without using white label functionality. I’d recommend checking out the docs here and reach out if you have any questions. You’ll want to disregard the “Customers” section as it relates to white label Customers.