Take a look at using the Order plugin's Embed Code field to add HTML to the footer. You can specify your JS there (i.e. Packages > Order Forms > Settings tab) and add a conditional to display content only when on the checkout/complete page. There are fields for order number and total price that you can use too, but there is no coupon code field. You could try to parse the coupon code field from the {{invoice.line_items}} if you really needed it, via other custom JS.
e.g.
{% if order_page == 'checkout/complete' %}
<p>Total: {{order.total}}</p>
<p>Order #: {{order.order_number}}</p>
<p>Currency: {{order.currency}}</p>
{% endif %}