n8n/packages/nodes-base/nodes/Stripe
Iván Ovejero b4f4ecc77e
Add Stripe regular node (#1470)
* 🎉 Register node

* 🎨 Add SVG icon

*  Add preliminary node stub

*  Add resource description stubs

* 🎨 Fix SVG size and position

*  Implement charge operations

*  Implement customer operations

* 🎨 Apply cosmetic changes

*  Fix customer address fields

*  Add stub and fields for invoice

*  Add invoice item stubs

*  Implement source operations

*  Reduce scope per feedback

*  Add continueOnFail functionality

* 🎨 Prettify error thrown

* 🔥 Remove unused resource

*  Replace source in card with token

* 🔨 Remove logging

* 🔧 Fix shipping address in charge:create

* 🔧 Load update fields for charge:update

*  Implement token:create to ease testing

*  Simplify card token fields

*  Update description parameters

* 🔧 Fix field adjusters

*  Remove unused source options

* 🔧 Fix shipping fields adjuster

* 🔥 Remove PNG icon

* 🔥 Remove logging

* 🔨 Reorder address fields

* 🐛 Fix shipping field in charge:update

* 💄 Apply cosmetic change

*  Small improvements

*  Fix lintings in main file

*  Lint all descriptions

*  Add target="_blank" attribute

*  Fix various lintings for charge

*  Fix lintings for coupon

*  Fix lintings for customer

*  Fix lintings for source

*  Fix lintings for token

*  Reorder address fields

*  Fix casing in credentials

* 🔨 Place recipient name above address in shipping

*  Remove references to string in descriptions

*  Apply minor renamings

* 🔥 Remove logging

* 🔨 Simplify error handling

*  Fix indentation

*  Move cardFields to root level for Token creation

Co-authored-by: ricardo <ricardoespinoza105@gmail.com>
Co-authored-by: Jan Oberhauser <jan.oberhauser@gmail.com>
2021-07-10 13:15:14 +02:00
..
descriptions Add Stripe regular node (#1470) 2021-07-10 13:15:14 +02:00
helpers.ts Add Stripe regular node (#1470) 2021-07-10 13:15:14 +02:00
README.md Fix indentation on Stripe-Trigger Node 2020-05-12 00:06:51 +02:00
Stripe.node.ts Add Stripe regular node (#1470) 2021-07-10 13:15:14 +02:00
stripe.svg Add Stripe regular node (#1470) 2021-07-10 13:15:14 +02:00
StripeTrigger.node.json Add new codex files and fix previous files (#1608) 2021-04-10 10:18:10 +02:00
StripeTrigger.node.ts Replace PNG icons with SVG and optimize (#1890) 2021-06-12 21:00:37 +02:00

All Stripe webhook events are taken from docs: https://stripe.com/docs/api/events/types#event_types

To get the entire list of events as a JS array, scrape the website:

  1. manually add the id #event-types to <ul> that contains all event types
  2. copy-paste the function in the JS console
  3. the result is copied into in the clipboard
  4. paste the prepared array in StripeTrigger.node.ts
types = []
$$('ul#event-types li').forEach(el => {
	const value = el.querySelector('.method-list-item-label-name').innerText

	types.push({
		name: value
			.replace(/(\.|_)/, ' ')
			.split(' ')
			.map((s) => s.charAt(0).toUpperCase() + s.substring(1))
			.join(' '),
		value,
		description: el.querySelector('.method-list-item-description').innerText
	})
})
copy(types)