COMMUNITY
|
Code files |
1blankspace.util.site.collect-1.0.0.js 1blankspace.util.site.collect-1.0.0.css 1blankspace.util.site.collect-1.0.0.html (Example /Paynow page) |
Setup public & private keys | Use SETUP_FINANCIAL_FUNDS_TRANSFER_ACCOUNT_MANAGE to store your Stripe the public key (APIKey) and private key (APIPassword). |
App | Create a /paynow (or whatever you want to call it) page which includes reference to the code files (above). If you use the example HTML in Code Files section the Stripe Elements object will be used to create the credit card collection HTML. Else you can use .render() method in the 1blankspace namespace to create the standard credit card form. You need to set the siteAccount variable on the page to the payment account set up on mydigitalstructure. |
Notes | If not set in the stripePublicKey variable on the page, the .init() method uses SITE_FUNDS_TRANSFER_ACCOUNT_SEARCH to get the Stripe public key that is used to tokenize the user's payment. |
The .getToken() method then uses SITE_COLLECT_PAYMENT_STRIPE {data: token=[stripe returned token]} to confirm the payment under your account using the Stripe private key. | |
If the invoiceGUID is present then you can call SITE_AUTO_RECEIPT to create a receipt against the invoice. Receipts will be allocated to the bank account with "Default for receipting" set to "Yes". | |
Example URL | /paynow/#invoiceGUID=b23ab284-d4bd-4eb5-aa40-2d1a49a5e8d7|amount=132.50|description=INV0012345 |
Invoice Template | Use app.1blankspace.com to insert the [[Pay Now]] or [[Unique ID]] tag for the invoice GUID. |
See also:
stripe.com |
docs |
API |
Example node code |
Tutorial |
Countries |
Currency codes |
Elements UI (recommended) |
Example credit card payment HTML |
CardJS |
card.js (looks like credit card) |
Example Elements Code |