While I am trying to same card details as the card previously added for a user. API does not throw any error for duplication. It lets me add same card twice with different funding source id in dwolla.
Also I am trying to get hold of form which is displayed on screen to insert the card details, is there any way I can get access to that form?
use case for this is that when we click on link card/submit button in dwolla-card.js form it is not disabling while the APIs are being called of dwolla and therefore user can click on link card change the information in the form and then click on link card again. Then both cards are added for user which should not happen.
As for preventing users from double-submitting, you can access the form by using the "form-wrapper" ID. You could then use an event handler for the submit event to try to catch a click or keypress event:
Upon submission of the form, you could then hide the"submit-form-button" element.