{"_id":"vendure-plugin-stripe-subscription","_rev":"57-ccceaa96bbfca7653e57adec5c1d370b","name":"vendure-plugin-stripe-subscription","dist-tags":{"beta1":"4.3.0","latest":"7.0.4","beta":"5.0.3-beta.1","v6":"6.0.1","v2":"7.0.0-beta.v2.7"},"versions":{"4.3.0":{"name":"vendure-plugin-stripe-subscription","version":"4.3.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/indexjs","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"_id":"vendure-plugin-stripe-subscription@4.3.0","dist":{"shasum":"86c4bd842b92e213bcdd84d70412fe40c2a2c155","integrity":"sha512-qtoAI7qcg54oZDzMEHGTPkXhu+SVktESJnV8BcoFcRRyzNAGgoR+5VFPs/byht57VukuyHtL1V3/CwJziyww+w==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.3.0.tgz","fileCount":27,"unpackedSize":47721,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCfZzGlR+geiPOX6zeUHQkDUeU3E2io/v9G0trgHnFLEAIhAMhvEW0ALTla2GRhDz46bwGbZgvEOEpOBrnr3AUc4ZGy"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjoclPACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpQuQ/+NV2LNnGABkn9lSle+m3gbPkn5QMiiasNog6fXYQ/a+3qv/5j\r\nzmsi1a+lGmc7EcLTRpOr32H/daTOXcHCsspuLBon1w9IJQ+Y8HSA0qJGYVNl\r\np95npWvPVR5fOiF+IrMV0Ti0qy7kN/XUe+H6Ksc6m9t6E2sv8ZpYsNzCMTZ/\r\nBdVVLeXD9z+e+acoNMpN9x0n8Hx8aWJESWnSPJ7x3432vM/MBByv6QFYo+Kr\r\n2YJ2ksZ4FNvLSk+yivaOV0AZNEXnVzc0yVBzN29OKAPktce/SKxCdvbeZ/sf\r\nD/3kQlMw/prVr6DHmGKd3uVnDtWDUSQJSseyyvBYqFGFplPOs/fd2s//GvPQ\r\nrnBT4ffse3s8EQ6PxO4IXZs778W9ofdUQvXDU1LDF3B0XTEp6lrlHuX6Vjuj\r\n+NFXx7U3Jq3uZRV+yeXeZ9Rnf7rQV7n3BJzQUoozedKqerV1/tj69FJJKDos\r\nHdbnm8FrH5uRwrhnDx6ce17+8xofxo5vGEVEj9ejCCMypBc8rlIbZeyabMpe\r\nxDa2sDc+dL4tOWyg1mDKLW8hK03YvhR0Wx/onEVB3y8qkFIxWTPNZs7GBt/9\r\nLTxChzNhNfqNuCNvFTO+gqyAddyDTMLbrLMeUcsyq+6jKmQnzApwxZCWJFoW\r\nLa1qIho/ZgSHzUSilCIsWuctlidgpQigTSc=\r\n=zTQU\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.3.0_1671547215129_0.6214930619559644"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/indexjs","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant with the following custom fields:\n\n```js\n  subscriptionDownpayment: 0, // or empty\n  durationInterval: 'month',\n  durationCount: 6,\n  startDate: 'Start of the billing interval',\n  billingInterval: 'month',\n  billingType: 'Paid in full'\n```\n\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n9. From your storefront, add the created variant to your order\n10. Add a shippingaddress and a shippingmethod to the order\n11. Call the mutation `createStripeSubscriptionCheckout('stripe-subscription-payment')` to receive an url to the hosted Stripe checkout page.\n12. Redirect your customer to the url.\n13. The order will be settled when a customer completes the checkout.\n","_id":"vendure-plugin-stripe-subscription@4.4.0","dist":{"shasum":"ad9b968c7f31c698f5cdc62e539029037dba4fb6","integrity":"sha512-LS1i+931vF1YpqZvmNpZbb9cm+2u7vPpQgqZv56NsYDLpQcsgfWEmRbT9kXIvDwdpdCDovstXo3kHXOLUwP4OQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0.tgz","fileCount":27,"unpackedSize":47721,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCgWDIRxNBq2OQ6vjpEj3/fkcijnq6PovGXydHldNlJhQIgOW7RWO87zVpabpklnNH76IUxNRuqoyZkERGz61OzRlI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjocmgACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpVfQ/+M/WXo6ZLyoc4wckV8ObTFO+lG/zFPSJIO67KrbJkHRtQJ8Pd\r\nebQMAoBbfaatuUqUDnHp5HOPOCG8rXXum2LwrIsujF/Rk93tUOKfmm1sDAV/\r\nkY4mDlfa3q6z04xmchtDq+Dg/lapecJz6IkW1Xzu0Yj67uBfIHxF5OgeZOJD\r\nZyQgSJYRnpMbrMsXJwLa/OZQfrBr23les+NKQAMO0hDWjt98ueQGcD+zjDqG\r\nfxMEVrcaqx5/ZCzY7+F6D5Nt23jlvW7m59A263weLbByj9mMY/YfRvVlJH3I\r\nFWbtKiXmBy045zt3M4PFiIv2mCgWhE5y5l+OWQWEpy7LRVKaFcdytOlXZLmg\r\ndFpkQfJyI83UHw/ZUhiD6F6/BAfjIGw7gqfh8hvZhirUslwhu5kZ8xVc5ZnC\r\nKWMwMizgoCMcUkL4ud1PvM1n8An7BwTYGbIR5vBf4/+m1XtKaAK5+uFqoZxN\r\nRxbYT2tP4wKDpxDMnBW2gx+g+ad/BrUxhOpKa4MVVnKQk9cUl+a3065LBvRS\r\n4swewjGXHTmmz2ZUq67c/3MmRWGNxhJV7JOSrbWkqE+CpDPflpXDa+sbttFL\r\nivWtZhZIDpx6o1mdNoIsZQ1tajw7RAK+ohJix6ARForkDKFlAC9Ja0Be562/\r\n3sHB6wjRI7zsGvdDCvV46Xt2DXVRC26j6Fk=\r\n=rIwR\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0_1671547295752_0.6396704036146721"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.1":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.1","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/indexjs","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant with the following custom fields:\n\n```js\n  subscriptionDownpayment: 0, // or empty\n  durationInterval: 'month',\n  durationCount: 6,\n  startDate: 'Start of the billing interval',\n  billingInterval: 'month',\n  billingType: 'Paid in full'\n```\n\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n9. From your storefront, add the created variant to your order\n10. Add a shippingaddress and a shippingmethod to the order\n11. Call the mutation `createStripeSubscriptionCheckout('stripe-subscription-payment')` to receive an url to the hosted Stripe checkout page.\n12. Redirect your customer to the url.\n13. The order will be settled when a customer completes the checkout.\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.1","dist":{"shasum":"8571e25d16ff5808f217dfe3f318efec9f181338","integrity":"sha512-YGQzZxzY+a3iyct3uT9bWup4oEriOa8pdeUbL/oJwDw7LHAb9USq5I/KN7D7QhgtfgPZumPfQr7e9L381EbwiQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.1.tgz","fileCount":27,"unpackedSize":47728,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDhStJrUKvWhKkzy8v7W1C/HSgLjm91RMMnzImT+wMy4AiAowVJkpBu39sHYT3qjS011u0/YtaCRZVxH12j9XDCcNw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjocnSACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq9sRAAjeRzN0RQhU7YL4jkZFji8hcGQ5CYSQ9u3IpzFdpWHKP51FEA\r\n4xW5XxVW1HzDRcRdybyJiNj3ssam/LX2PBeWZ6lv35mWg2afj28145rSkvH/\r\npw+nZsBl/rkmzYYv+YfYX8nuLCSx8NA3BunV+an25xtYas8iWB7UF7UXhJQ5\r\nG7ExdhqcjXonUnigJ3AUD6PoXNjIrAHHRkEPtsRUdD+m9WT6adzzHHxaDlOP\r\nZHvE1VoAH1wrPwlEnj9D3guFMU2o6wCcOVbJAZ1S62Qmgc8mX1J9wVHnvAEI\r\n7ANrAdGG+yJ74nmDztZUEYP48ItsRX8riZjUrVhf7HLWOyzCECvp88Tm2vIc\r\nxyLVkTzMTG60R3QyioJ/7CaBCjoIoL5uaxMa8UgahX3o6yy3/woj4FNY3hSy\r\nDe6PCrVYGONly1joFYrnma8fq/d0NpKxlBqTGLUgpNZ0BjZlrnE3F2po9VDk\r\nFzCKqFwaJX0O2MYdDHjAicbVpFwJG8bRaq5DKa/kG+QItWCUKn2RoFsxDZZL\r\nVhY2eQ+JyfgWqGvppHHKj3qJ62bJxD+Vdv/kGgh2g+M3xrMsfSe/ySUD6v3N\r\n6HDjh3NvkFkbJ+9JVfz1fRyYm7/S6+wwOlzCMqsjM9kj6k9eCBEhCRfqhK3q\r\nFpmWS9xrjaspapq4kQsfW25MXXUa7HUmIw0=\r\n=88tA\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.1_1671547346213_0.4315513141358007"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.2":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.2","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant with the following custom fields:\n\n```js\n  subscriptionDownpayment: 0, // or empty\n  durationInterval: 'month',\n  durationCount: 6,\n  startDate: 'Start of the billing interval',\n  billingInterval: 'month',\n  billingType: 'Paid in full'\n```\n\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order\n3. Call the mutation `createStripeSubscriptionCheckout('stripe-subscription-payment')` to receive an url to the hosted Stripe checkout page.\n4. Redirect your customer to the url.\n5. The order will be settled when a customer completes the checkout.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.2","dist":{"shasum":"095f9ffc8e814575bacb1055e26bf5981794c39c","integrity":"sha512-0LMILDYON/vIgzNlbXlfnO8ZvmwC7kxq0eNTx5VtAz4ephp6A2tHyfpM6whDSNbzmYNaFH+YdH7O54ka0cpUWw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.2.tgz","fileCount":27,"unpackedSize":52059,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC61UeBn48cVLLDpukkhCFU23LyEMYnbcaONpFfxZfdMgIgDX3+R9z4SBhuF+PJ2aTfrxI8T/JOvvpuaYHvjgJJ2QM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjovgAACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoU5A//fio2crYMYec/Z9ucPa2XFBeztktny95wY5BdkQTthLydrv9M\r\n6YYuquq4pPt18Sdwcx+NaNvl8dmjZC1fnTT+Qihs+gCCJW23SmGw9BmDhnjr\r\nwrF3UtWWIH9IX69acdZHo9gZ2Y003FRCNYLirYoTCK+bPu1MWGJ0kdgQPbs6\r\nfuZ3jNdxaGIjN9tV4wEpTFgsJlIlC6QB58RrkUinNyoh4elXQVwR4eAc9VDE\r\ntoRG+fboro9T1DUssfhBBOY9xxmiJnNWTmezaiaJM8bAjS82L3sMre6BgKfz\r\nhQLwzrp+WTqlOJYa5XfkOErKtBcvCRI93blrJE0hxp6/3MyP49w0UxTdhDud\r\ntWGVIjns8wV2gg/zs3Ja5km+upK4pDxDC6qmLkTOJU9axmLuOGzPvwVuRkN9\r\nVgMJ+TnxAdt7euKE4SS8MbPjsqmu4CFRLLR+bW2EfsPv9sed+TffGaSUkciZ\r\nett/AyAoodjKs6KVr1la4/vITX826IEiDqMEc617rC/9H3+iPKKCDmrsHOSF\r\nOmcrho/FC5GpOAP/dE2fR9c7z5WT3BNddBzUEmzLTf1Ek8I0S9G3YwyK8wsi\r\ne1J0H6DWksYc9XEhgkMfZsYrjoOEwmzOSIXhHhRy6u3GpsyaPgwFZPqa1M0+\r\nZocWDLHsTHjSf8iooAeHIpIteuYOP/bD2IE=\r\n=lyEf\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.2_1671624704677_0.3631327692734796"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.3":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.3","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.2"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant with the following custom fields:\n\n```js\n  subscriptionDownpayment: 0, // or empty\n  durationInterval: 'month',\n  durationCount: 6,\n  startDate: 'Start of the billing interval',\n  billingInterval: 'month',\n  billingType: 'Paid in full'\n```\n\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order\n3. Call the mutation `createStripeSubscriptionCheckout('stripe-subscription-payment')` to receive an url to the hosted Stripe checkout page.\n4. Redirect your customer to the url.\n5. The order will be settled when a customer completes the checkout.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.3","dist":{"shasum":"7972148cad05275bd4dc573a0717cd70357485bf","integrity":"sha512-sbedqkvEIvJialHF4t1XdesAhJHKlYBOsvnhe+8G9dBd+XJkzy57IY3yW+YFapaNEOs+9RNtyuaG5MbUMLKRTQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.3.tgz","fileCount":27,"unpackedSize":52080,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICvojQTjqyBciWoVFSjahk5uDkKSKKc1XU5x9taK5gQBAiEAomNLzjc9smuW7lJCuQzqaBr1rono4epQzQSQhFef7JQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjov00ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpWoA//a+E+t+q4bNHfsVM0WD1JZlqw1YmdrwTQemcvEYYA5vk5npNS\r\nBpp0IDg9psbEIRInpjLU5F6si2O0f3OBSKg4yjICfYMkBZ9vitpMDVdLoZQy\r\ny8hr5+SwQXOgvoJO5GNKNBbi8pYdxglV1h0rOESAmB23FhFGCIEWoswbOMbZ\r\noRerAXHbjR92JISeN+0fmCSc/8CjSoNgZef+gDBkpOMEO8qOi9xsrLnbul+f\r\nQf/N03WhS4ry7upi2fDyXt3RjM8SGFvQsFwyTcmvR+QLL7B/oMitCJDSppoW\r\nbbxGC+D0f9K688MQIg7Uy5cBjQDYIOeUbsQHp9V7WglTEezDooLcxsaZu4bm\r\nQwnl38Ghz6USslbFtwgJI16Lxdy8hkpoQ40Ts29jJBJZ+Gw+wQXSSGKdaQgc\r\n57tsWmJk+M02veG+l7xg2Bc26pp4Fb4w9L13AG3lBwbEn0QGWJhfhHfIbL1f\r\nAy0uYQrNDcaLIHe41zNJsZbAJ6HAJnXXD5HU/RT9mfG9rAYVbSjhr3ndz/nd\r\npbakQXvQuEwucmN2sTdNO8eQ3lk8BKLXPqc6qY6u6HgoLUTU1ywmpLlZIJTj\r\nzzQx3YBcQgFqYdzRejT0g4HfUwqC84h1ZZRQT87BZA7l5W3GRhDdMMGWkyzi\r\nDWYGjQYaRKPt7aJ3MuEOE8zICkTvGJGb/y0=\r\n=dBYh\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.3_1671626036019_0.4655871702115082"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.4":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.4","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.3"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant with the following custom fields:\n\n```js\n  subscriptionDownpayment: 0, // or empty\n  durationInterval: 'month',\n  durationCount: 6,\n  startDate: 'Start of the billing interval',\n  billingInterval: 'month',\n  billingCount: 6,\n```\n\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent('stripe-subscription-payment')` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.4","dist":{"shasum":"479e59979bfcc245ebc22eb718d2cebf93b68b29","integrity":"sha512-TDPx046aeCGD3D3aC6fqxgpDfuiHoTpN3xJ24cCWzOnuCdE4uqlHKXVmGPnpmwdgcSDAt8XKM6St1SQ+catVDg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.4.tgz","fileCount":27,"unpackedSize":52843,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGKe6zsopVt5+ppSw9YJFAEIuuaTtJhyYdxl7ZoHil1dAiEAyHMN4JC/zavWnAt9I1tVO+9XQFoI1AHfgSm0+mjofd0="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjoyjEACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmplrg/+MWOTrW7M46XOLA+4BCL0oeCifMES9fFJhq5+iY055YCpYAYk\r\nTamoFJQWjEO+IQe7eKqp453JlIWlQHXgUyV73LXM/7FmayqL1VsDAd0At5BP\r\n/PH2kEvI0mxkJ9BO1NqsgxOYseKusDsxnoEjL3ZNjvfTrjVssgtqMKmtUOLB\r\n5NL1gKxyE4WoFRdSUYVPiGxNemN0k2GXxxfRNa7bRQFUP0ANxORikoSkbDTM\r\ncFxzs/ovHaFLDA+Eae5bWzJ+O5CyBWXRFDpOJt232vCS6Wp5+Cd1+gd27g6C\r\nB9VbPPJrfgVU/aULrRWBpeUsCtu9HXyjHv/y9sEI/v+Lvfg3IL+XQSH+ulGk\r\nQRpAkSQM/SVPHyxnRYiW2AxquADNmaGD3gApdru79s9A8RQmUpFKNBEC470c\r\ni+AVxrgjLAdJha5ymL1KypDDAcoCNZA8Y4SNhMtDUhhhjYHaCQSjHpJtOd2j\r\nNaUgE7Rj6zjaVnQImBd1rYu7FBv/O4HYPHgoAKmb3KKWateoTGi75QYeItT3\r\nJuG/ehFN2KQ56XZd6mBiQUAIjezifeh6VgfsJbzlDN8Xy5YC1jgyHZIx1ICl\r\nhmqxRm2gEDsop8WVl4EaXZAn6ooEvLPji/oVoBiliuHR0FlKB7Iz/YYlF5A8\r\naJrw0xVbZOGrEwSkGcO4uwl7mG7Yrolu2NY=\r\n=zTzd\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.4_1671637188696_0.5659515435347098"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.5":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.5","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.4"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Set a redirect url. This is used to redirect your customer back to your storefront from the Stripe platform.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the future: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.5","dist":{"shasum":"c2850e485d8846e611195350b94ab8eb26995861","integrity":"sha512-9CVq6ZKct+p68DCYl3YILENZf/l9toroOaDF0QKUyhIE9/9E6qY0OuOPjydgM6SKNJtDdv4g1lN9aB152SQzrw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.5.tgz","fileCount":29,"unpackedSize":50802,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBSxPPTOnVw/CRmCXU3r8SfIS+gswMTPfTXCAgbUnmAnAiAdgJcw20Xno9P2DUBtKxg77BckYOkUkpSB9uZrJQoAwA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjpbujACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmoo5w/+PoJIT4IbZBcI92zhWBD1OXmE6zTqFKdQGB34J1k2KsXic92b\r\nyXWhz1HTSiTGulwGPEZdMv1R6ci+vO7KA0165diSCSdQfpWfv3Cww9pNHI66\r\nJgD/+5zrGaXZWilTCMSHK+G4mDdjAG6uaAryI2Ts0yJGB755ogWM8Ovy6h7i\r\nD2MZWcRsGhMRs5qQgIFUNQ2tkZh/JU3u64gh/3eVP+fLaMqfOus5cyBV3xjb\r\n/1t7RJFQQjUAfqZsTMcOfIVEqfVOXK6tWOTlxR74F3E2gcPQ9GqPauzFnGWK\r\niVVaa0rt/sz1PinEKRAKL/SM0G91keiKomtAUnTp0UEKpDpm4xYrZzkww2yX\r\nsQkINmpmTarxmuIlSluxddazarbQPf8YD1guT3QLoPMiVoInycxmItcwiOpx\r\nMrOlE+Qg5847w4pgtJFe37T7DHpHiF+s2Hj68Tw9TNbhL7wi6ZcX2qpw8UPr\r\n+9ANhbbEGr29NVVH8wojEB7qjHpE5MI9BVRLmKPybPnKzPw1Q0LkzZaviNMf\r\n/jfJ+t7xXMAO89UJ0u0/uuvi1EHIEKkWuDj5UpcjP80wbI2op1tgLV2SLsOu\r\n7wZwaqjgGwAh3k2iJq0mOZ8wYRH+72dAHOTlluEcIEZpwMQ8Hh+wX3cFtnkB\r\nH8Nu542PPxfwD613FbqHULFHde896v/jdms=\r\n=eUSo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.5_1671805859110_0.32984546864636344"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.6":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.6","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.4"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Get the webhook secret from you Stripe dashboard and save it here.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the future: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.6","dist":{"shasum":"91956a40c387d140cf7e98b95d36e016f0631806","integrity":"sha512-CRJR3L3GB4VmgDh6NuapBM8RsHqE4o+G8UMdAQYtZJ8AHgDwirmsVgXwP+cZy518gilExulNE5HQNUsUZBxtrg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.6.tgz","fileCount":29,"unpackedSize":51275,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCvM9rFRliXMGw5I3nFx54XKZ2ZfJXENsvyESprwgyKagIhAI17PFfkM2i3EctpbuFm9sc/WUvYRDnSc02IipljgLVk"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjpbxFACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoG9g/9Em5DnqztJdihdklLg56d5LYMNfNKaRvr9+NqZ4F/oLsvsU6c\r\nwHf7QYTITjAq2KsryjNzNuQnY261ckblO5W9hqBRvT5bZOw7oI3paENzAeyA\r\nfhP0mIAbRMgSQjmqctm5mkdFj0p4qfu8Ag3sm7q4mC91b/sdV4HbeN3xe24e\r\nQD2FBBwRjELXnQeE68dW3BZz5cW1GEXSLQhSy4YDWYPNV3o/BH0lfwup31ZQ\r\nBKFR0M4Eax22GSqULxzGn09NqAkjcnXE/+xQ1FvjWTzuHTggxhTIaluDtHEX\r\nVgToQxpewJPSA0A7cgSQKl7FaqN6PxxmP1NuFCIxVWUWsGORMkUNVtmNSE+I\r\nEeJkEHPSB2Mx+wbCcoFyPpWJRe7H3E9DZ7lsYZnxXSYm/ieVsEXgEZt8jm16\r\nor13XcSlmzFxfjVO7ZA6X1uKlrhhO0TfLB9Y66pHSr5gxlUEUd7AWn8o0Frv\r\nUGM71GaNQizPehlRIAjcyiwTUSichLQe4T5WA7L2wzrFiuncJzP5Fx1sf7bv\r\nPUelU+mvpfjOLuQ4d0FapR8wiQRTdnX+OlwzX81xzmSPpeH+0Oc2IPAYWll4\r\nqAYEJxUyBrZGKBWr+nefkmwuYtagKWpRwtd/auAjnRjOrXQ9ewoF1UTPorsz\r\n3X++tylME/41JDPNYS2kw3qqHym7XTvV03s=\r\n=Fxkx\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.6_1671806021591_0.15544356983805985"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.7":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.7","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `Checkout` and `PaymentIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Get the webhook secret from you Stripe dashboard and save it here.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the future: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.7","dist":{"shasum":"c91bab7c63e4f87e425ae0fc829ee73a39cd1980","integrity":"sha512-+Qzs2NqIpH2vz6qG0bu5j9zwPomQGlV8TN1rjMLQlS+wKjOEX9IRjDk5KZRwaiSWAlg2Qclz3ovKpPJ86B/3og==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.7.tgz","fileCount":29,"unpackedSize":51272,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDHgcGBrzKb16Q9D7B+7VEDkJjyxq7Ww2Zn1bqDCcuvDQIgPH6J1UpHjr2Cd/gv0UvuxcsfgSNiqZOGmVLlTDX3c7Q="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjpb2fACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqTsg//Z5439uy3zrfmBioOkpK8T7vOnOt25LlSxYkmEYXtY5NF9lV7\r\nWEn7aCoKmKTNVWqbjx2I3N/ReaHrFDfzO1tAywX22EoANR83jVZaZN1/eJ2S\r\nWDUOHle2J5c11TQygKz4djhbpriMC3Ki9JuQHfXG4seXDAYk7lRWBBD/8teT\r\nDWAaWBnu4cJc59P/9iezwnimv/CvNqKuX+oXxg/1dNVDk4aK4uxVUcB7K/gU\r\n3/EFbRa5r1nIiXnFY2A9rD2fT6dXbvaNb8Q3ij0SC9HsOtPt7NT8p1rC3/U+\r\n3n9EkxuKK1R0mmCQyp/C6V0UVIWgNp8rkRxt37uZ9OsnpHPQ+2Bu/pXtreNx\r\nnomk35AG0Aq5MgUB/6UphHOFQXLdUbXvN6mfED2GisZmWd5KF2umgDHhQrE0\r\nZXCsIRk3LwS8pyLj0l4c5z06Ouz63sqN76gYjBO9hmEe1oEdiAsY08Upuqnk\r\nLA/gcxe4ovbTYrGh8ekS04tYpshSFBXMYcmREkqsCG2HrPDqF8dA6RXpckA2\r\nw9kVkKwWD7CQbnUoXo12ZB2cm/iYA4itAnXw3XAWxh3n9RbP6OdyBNOL6ADv\r\n2G8NAD2tSX1xvQfCsLMOUOnnHGMBNADZD9fmAnJX6PLgXDoG4llJqqozttfd\r\nGXYT05Ha1W7KFSNTTrQXOTkoGfaWzOgwH0E=\r\n=VXRl\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.7_1671806367114_0.7703918611774587"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.8":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.8","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (Use something liek localtunnel or ngrok for local development)\n2. Select all `SetupIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n5. Set your API key\n6. Get the webhook secret from you Stripe dashboard and save it here.\n7. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n8. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the future: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.8","dist":{"shasum":"bd14c05b2ae77222b49408713ccac9c4478b28c5","integrity":"sha512-/3Ctg6t7p7Z8Lu7uP+mNVyVpCpwZhkey8UX9EJUiOzk/PZc8rAPNivwr0qcBWDF+nCYDbxwbjZk0Ia1E0xAFFQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.8.tgz","fileCount":29,"unpackedSize":51505,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGpfN2VzHG278NJufzjljJ6xkWFODJz0H+Sihz/pBPXXAiEAofnOBUhzN5hMnDhol0CfaOV1n+tVOY9XWuFPbHWAFlQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjpcYnACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoG5A/+N05cMMdqi8+6NEqKzx7Zo3IubkQl4OzD5vqM1eDuztIuRqOK\r\ne1S4LRuxF0IICsAqg2e8cimkajub+qftGmMO7AY6Hg2Ze8hxw2gUFZTCpaYS\r\nFrBkHnl8G7twcgViziDFcLBPIqYwSnijnVSQm9sOOeTzxH5e/wujlBsgkAhF\r\neJgw8I/5v676zHMJxFk4TKXJ9mc/hN9q6Qqj1w2Oi6Yh0ozgqycnGbEQEc0O\r\n7TZD6LRwUygLrAeCIET4F6BdLdmYgpMlmpFy1sq8eOj22fVHmxfHJKG39mdI\r\nXUilih+G7h94H1g1iBk1W76veRUzqdGPHzmlt52alSe+F+tIQK1i5NzCPsLg\r\nJwCfEPFtPkhalKRtmT5916ML+7Hju3t9rTMYyLhyvn4HVvcmgGKLWbFNKxpa\r\nC0DmfCJ/bT6njTiTacHodIi/IV/HZQsatISjQ8UEtiIAkTOVUEpyelk3Fgc7\r\n9zI8Foon/rKBkS62Q+xnOdrvHTrydPQXQoZk1nD6vn6XHKUBydoYloMIK3qs\r\nTaXSePkOy4R4+J1W9cSz3Yt+z7mC5RiuZRB0bq1qhPdL5jKR7L/V2oxh0xAL\r\nCVK2nhxV4nNNP2Mc3Ls2IQurMDv5oVKz+Jk2ycho3hVahDjVsSbCUmVBt6zK\r\n6mptilwjuTJAfaZkjwtOUGZTcYUNzbTud08=\r\n=1/vy\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.8_1671808551723_0.6246953955224823"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.9":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.9","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select all `SetupIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n    getStripeSubscriptionPricing(\n        input: {\n            productVariantId: 1\n            startDate: \"2022-12-25T00:00:00.000Z\"\n            downpayment: 1200\n        }\n    ) {\n        downpayment\n        totalProratedAmount\n        proratedDays\n        recurringPrice\n        interval\n        intervalCount\n        amountDueNow\n    }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.9","dist":{"shasum":"53d01a6fcfb036fc97cb04e1fea20f3124a606da","integrity":"sha512-uzOIaokIqXO0/EC07+/Rds+iGnYznvsEEqZRFv2MwcofAHnZxOYBhgc7Z48wD6g33CnrSpqswnuqR648HaiMiw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.9.tgz","fileCount":29,"unpackedSize":51890,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICgbKxRPYjeV2nMe1/PzrFMsfg4SvWd7qkLEan7cXz68AiBZPL03sOI9QTC8TNR7Cf1nsJLH1JKEsZEp+DpXqD+1wA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjpcm0ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo1+BAAiiqHFG58ZOEDbVQxpbTfRL7YLLuMmTI8e0mHWRkSVvYUqg7l\r\nQBIMkesGgCCEQXf/awl6XwWmF56QdnEWB0BZg22zPE+RlbdhVjX7cN1AsTui\r\nvQ7csb2E2a8Wf9aSo03I+1Qy/pc7YY23e8bDNdFZAPcmRl29+3KQj2I7pyaA\r\nO198PuYBnUgCs0NpWtdYE7t+Eukx812geLGQwOn0Uof172ueu4j5Yxwzlymk\r\nt6QoeYl0oZ5I418zD2kUCre4y7VpWyg/7fKVuPYzvY8p7ECuxJcvxYnokJ1m\r\nbkiYM/pC5mR2Dzgypy23O2ZxiGNtY2/r4LqY+/740+m4wrquc1WbylHLOZ9s\r\nnm1H0c3OLBrkPs2GUqJZR4u/4JoDiJ6LHQ4sySrjOhEcDipLdPt8D0EGZ04Q\r\nD/dX5HexV3QPk2stluyHG2NcAeo8PSIlZ0NeUdeG6sz5p8zfwCBBn5+Hfbo/\r\nFhI7tCSdDqDIXGO0htD46Q0SlLzLStlICUNFDM+GNBeDfvpGV18l6YavrWEA\r\nxfrb/nlfbMnx7yUEcTH9Igv9E9yGc9SXBxYLwppoqnMQW1pW8K0rLcarY3xm\r\ntkpTMwc835/YUVLZu02F1IXGkKUNs358f+xBffYpSUQr7YzO/wpXoErmaR98\r\nu0Dg0Jww3MtrzZ540JpcTBlczJra/rwrEPU=\r\n=M5ak\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.9_1671809459913_0.6709142865114044"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.10":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.10","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select all `SetupIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler.\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.10","dist":{"shasum":"92c4fecd77c28f11cfb0a9e0d50248215bb59d25","integrity":"sha512-KcKD+WTlvkdCZ3KtFX/rcHkx/2tXHvoWGHo6QA57m5KXgMug1Y3ht0Hob4SHscj0hpkmewiOaRBUXhEq7JwdOQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.10.tgz","fileCount":29,"unpackedSize":52448,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGJcCtdxOaEiI8HalRgU0yj1MX+27FEOCfHYlz/mbOnwAiEAijPAcNSo8tAsemrkQk0XUFqKkI3M732ibjlGfeiC3yE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjq+4RACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrDQBAAjXGsk19EzcjkXcxXiFvBhNMd0gBu8Jg8IfHXOV6zo0nk/h6Z\r\nXKcxp7Y20rKaz09fkFEPz4DKbP0Cc2e8hz0Wk+74G1lGgc1SeLxDkBuHbKk+\r\nIi9xhnffzw6tmiEfo7tFQo9M4ARoBW/KPedThmcHw1iO4dHnaOLl3khturCK\r\nbN4L4C20uGimGjKBvIuDJ919kPhbsgzrvq8yPd4t4wuGRxiW42h6XLC0vI8+\r\nh14H4KZzLZU+yiZce3Mg7kRDwemFWq4HgRzdV8KKRQrm3joPuyonXiC45F4w\r\n0jJbGmvFsBnGaTQKFl+eYT08VjDmC0huFhNZStVP4jlfb/hIZ77HGDdohrd8\r\n2tk/EKZlLcm1KbbgF5sNTE72gDfriHerHDRUnzDY7QeBJAKfu5POT+qrxVNX\r\nLbpUUCB2pc4sIUNZweP0NkPKRHTHbNchTYM37il0ehHIsauwIWPf38x9v3V6\r\nBshrAravOU3EApeZsnKrQlRSTQ9f7ZrKh5gp5TI9tejQmVZv9GxM8vLBG136\r\ny3s+atMJFLKrO+2Hk+J9pQUZSbEcpdqIjTtu0w0Nbpf/M5V6DGBUBPQ2mIhb\r\nSQMHB+D/ajfck0it2W8LAr5c1S21GuCgOFNawZO0dXvjAOfEjRLibyQKSSZT\r\ng0ynf1+J1cViWaa5rxVUiWGETxueY7ar5zk=\r\n=So3Z\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.10_1672211985323_0.6250953409189828"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.11":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.11","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/index.js","types":"dist/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure.\n\n!! This plugin currently only supports checkout of 1 single \"Paid-in-full\" subscription per order.\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select all `SetupIntent` events for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **Your payment method MUST have 'stripe-subscription' in the code**\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.11","dist":{"shasum":"b7b9711c87c62408683cffa0c8cf0eb0eb9bce66","integrity":"sha512-Zz8HcFPwSBZ/3hxMsPxGs1ct+IsCsnCoFKsNvdpKxJrye4KAtARQ7Foo2W38G4qbv9LQk9jGH/9TXOsNp0wxsg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.11.tgz","fileCount":29,"unpackedSize":52872,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGCO9+G8IyepPYzKdkvVTtJpxMIQ0xSW1+cABrVdGW1ZAiAaOvaBLeX+IF4oTSdELqSJ4RjG0GXCFf1I5leOnAwsrg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjq/dqACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmruXw/6Ar3W1P71ZAbsBKX6ikW0dafJR+LRTqFB29X0sP2G2IG/+OyW\r\n1VAoQu8+g9LT85nFxke3ZXUv+nG83D35N040016Qv7OM+0zENCf3I82mryMK\r\nTsgqmliCa6jehLz7yYdIYu1J0bQQ/6umcNot5x5q6qrcps6SP87OMVTmtafA\r\n73V6Kpxeik/xrSVEbS+gPXwOYsRRhc4Q4w4vV4c+uf74DPwwHpNtvbTjc55n\r\n1D4xR6XWb8NDDdF7hQoDUbiLaJOmN7FrAyQE4H7x2FgaIysW+YVsB70p1Nb4\r\nrNt/hDB6HNoE9yE9dXhizWGsC4BSsQLEUXpm+VnhhIe+WbPfoXbBXtmMmQm6\r\nRFpVqOEpDkYSSCTZ6XFsw8wnXs0y2nWqHvIBpb+KRF0GrBKQqjRLcAaWbJP1\r\nxZebrG6VqyHpBYfKC23GPfSkpIEeintBPIH5vU9co8ByCPzy08jmC9pMiGM6\r\n2LlTDuS6lJRJEFsl608Kn9TyKUYyGplmQvEHeg8VGCHnlc7LuUdWpnlYRwfh\r\nelLC8ZngTAndjEnS6dKP3P0cPO8gAayxOCAldcTxhONsqdtk/hsrrr/ZLD2h\r\n6PeWvoXAn/aA9HwEIxaUVaxX8XHX+fJMwoux6XdLuBBYDrxfTe2rbC4hwwde\r\nAXyPbfFGVEm5TSwPoJuR+WA4KAYwMQEN4jI=\r\n=WbDp\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.11_1672214378054_0.17709676585871836"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.12":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.12","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.6"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### OrderItemCalculationStrategy\n\nThis plugin sets `SubscriptionOrderItemCalculation` as `OrderItemCalculationStrategy`, which calculates the amount due\nfor a subscription, if the variant is a subscription. For non-subscription variants, the normal default orderline\ncalculation is used.\n\n**Only 1 strategy can be used per Vendure instance, so any other OrderItemCalculationStrategies are overwritten by this\nplugin.**\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.12","dist":{"shasum":"d524b306e2ebac216c3dbc7fc6ed676568fa1937","integrity":"sha512-PKt+fwrcMc7rI03fxlfNZNnx0MqzxtAGFa8QrMBAAn/FijNQOMEsAkuyKtnCVaGXKgPY0/4pWxyiHv8ETKknrQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.12.tgz","fileCount":37,"unpackedSize":60675,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICdDMNphKaCDMqkbloGBfKKIZKWgg6zAfOpdvPX+xABaAiA6o4ezIKw8dJp3+lv86e3kzFHZd3zDAREe/I3rSIjuAA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjrFdMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmph4w/+JsbinQy6tmJsQbFmwLF5sosFz8nbrU2OnC1w15TgQZ38ScAy\r\nDrIz60DxE2oNQ1TychV0IL87ZTWOE3q4X6awvhkfhJkx3HcsewD+u29WSe6A\r\nbAQYF3fbNCqqv3jPvqP5RROqLGcpEoNAvHlGkroWcyudjBU5QXd2AUziQlfN\r\ndeU/0bwrFtYych9Kz7t6UuVF69kA5h353MS0IcU0j3muTQ8I1zlMx5HyecLY\r\nQMHMFY0i36k2o9re6anDNXBzfnGuKdeuUKcIKK6yl/3l21DIArafuilscKyx\r\nGx2s4FTyFb/gLuMiztm+46aHu/fp1P/wkpeB2clZEngVNCINCVKRIceX0zu4\r\n6doWVLho56Ctr0GaEB/WX6foY0cSE2RMzJjEqaaoJbH+BvdIZsPDnG0NtzoB\r\nJwVxMgsB6u3whEi2OL+Z6obUBy+SXJ2YWUybtkf8Wy+Zn9F9Cd98nwphSnU+\r\ntNgyu6f9OivuVP5JOy/39LBg3NTD7C6zrY08sCoo34eLoepUJH/HZ9rQnrBM\r\npw093EG7sivwUBOA56i5MuTs5kUJ9ffW6VsO94Dqo1zYiRvczvTiNuzFvQi7\r\n3qcBB/8tsOgGq0INmDpovdMcAZ2uDPsHLlRHtM/9mzmlx8WEuudtWq0tSy7X\r\nMRNdg18BTPRpdR9/93+h0cm41Mk9yTCGV6g=\r\n=lZY7\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.12_1672238924116_0.5920598954209195"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.13":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.13","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.12"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### OrderItemCalculationStrategy\n\nThis plugin sets `SubscriptionOrderItemCalculation` as `OrderItemCalculationStrategy`, which calculates the amount due\nfor a subscription, if the variant is a subscription. For non-subscription variants, the normal default orderline\ncalculation is used.\n\n**Only 1 strategy can be used per Vendure instance, so any other OrderItemCalculationStrategies are overwritten by this\nplugin.**\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.13","dist":{"shasum":"6b1f29ca2cd427077e8f97dbc58507a5de57e4e0","integrity":"sha512-Q+JsfPQ0HaaJNWm9D5Kewv0YQk79xRuqo3lmDN6/V57ztB3IwkVVbO1F16GgIhyxKEcnKbtIupIBidvtzLuEDw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.13.tgz","fileCount":37,"unpackedSize":60861,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCGr3tnZJLIBURpyFKvuW4upWFIVIEnLRuusSeJfduxugIhAJR7QQCkH6CNr0pVTB62ef2kamMNNmEIf6MNmWKlgbzN"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjrFfKACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqEPxAAoxVwGEqSvC9/8i+Ow330FTOK2DggB56LqAuoFtKbr5jtkEhi\r\n8QKeRYIB3/i7AyaKzg1FHw1an0LK5+obr5UqCDO6CsOKCmje5oBsz6SYnQm6\r\nXT3zxhSLy8w5EkEoC7dvJjCQA8w6GL8i2uha/UcZ2gVv6m1DOoVXBeadYVtT\r\n5t4AItk1S5gDUE6P9zmxcDXAjSTeyV2ZzdEZ+JzSGU9txlPyBBO5blKqNKrs\r\nDgvW8pHhwWWGQ66JWn4dBnPtEwaqzIuFTIMQEmt6S+O/Jfhs+FuZa1/bMQu3\r\neK0Gg0qjSPCT5dXkhIWklFczMZnJ3bjI++k8wrXXenLNr4GPhQo1ibmNiqR9\r\n833IbTftgzu7KxLRs911HSzt3za7cYdkqpvhCu3TzNStUXv8FGumb0vMoiQh\r\njL/IK24pDdGsA/JLSNEz5SnrnTulZEMibG5v7ojMLE+Zso0CVTED1viLKHvV\r\nQKCXoc6I2J3+VB6g2pEm175SSx5Yuno9HsFayfl9D4WXQgBRBSvZlu1fvPbV\r\nU3+devE9RAjZvQFiWcbCzXPhEw25FMI0+s7FFqTALHyPP28babMXlkYnzuTy\r\nW3Q+ZQYvZ7phM3NnPd9G/UdKN17hsXUFKTiY+01sGMfbx7AtpEXfP2TmoUgn\r\n+/fHPGitmPa5JBo+N5jgtIlNUlZtFsSdKIw=\r\n=1vnm\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.13_1672239050342_0.5591689749572339"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.14":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.14","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.13"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins:\n\n```ts\nplugins: [StripeSubscriptionPlugin];\n```\n\n2. Start the Vendure server and login to the admin UI\n3. Create a variant and select a `Subscription schedule` via the admin UI\n4. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n5. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n6. Set your API key\n7. Get the webhook secret from you Stripe dashboard and save it here.\n8. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n9. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.14","dist":{"shasum":"2a84fe739b0011bdc3566902eeeffccdb36da6b8","integrity":"sha512-dqAd994I9INhBfnDG3Beg3uoGEsMZPRweHQ+FOMAbsnTGIj+AVBjSPl72jAl1/uZXa/sXRQhVtourSKBdT5C0g==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.14.tgz","fileCount":39,"unpackedSize":67040,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCH1Uj5zE3vv+fvTkPXAte4HFEgd6wSPB0P2bC4m5HaogCIQCPBywhI+gElbZpsnMJibzz5KQtl0ZfE1Q5qvEXcDU82w=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjrt6+ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrDUxAAlTeatbzClcgVzZEUMu00tYMziSFLI0cUPK0JL1x9y4+nyeBY\r\n58bcQWUMrGvGvCZ7Cp+JY8UotSRUQEJEhzS4mYnAzSSUwKybI2liQ8FOaepg\r\nhQEmSvtEOfjCCjeQGrEUepGh7PJsQSrjxyenVtJ5PxIhwtD2TMKQnQkz8n21\r\nAy/KdyWAMJ3DJT2tMkJwz+zmzVghClN7RkCt0XyOJeZCeOlgG5u5gdGCNEB3\r\n3aQwP7p6GkoroVsm8KjvT2HYiU9luuS+1azxbUpoHS8LvX6+rfxi91LRv3QH\r\naXt1tdOKybL+yisB28mYr/s4i6Q2d9U1v55/sZrqLPzuP9VgxQPVSgz8JX/L\r\nMH5AT4OSki1CVjqcPYfn2juHLCuwjj1VRDnDMC7v2rV91FxJS1qfB3jY/Oju\r\nb1Mc0nvapiQJns7AI9kimwX7zi2BjYrhyBYnS5qnewJmowyCycjfVt1VPxEH\r\nXuoPd2eNTZydSsGaOeIWD0QW2h1Nu9couympcvUy3Ieh4dgbKOzty2MwuLHA\r\nKzX/wuBz4wFN36ENTltBm+EBpIM2TtQ7xL3MlC5mia/2t8eS4xSaFUpXcbfa\r\n+NjG5zaXUxIkNhfIJtDUgW/Mqy6qgAc2E0w1dF++GcZ5dwHYy8WqU0t1mLd0\r\nAxYjZvJ62u5owUTzJfTl6nkeuiw2Kp/RFyo=\r\n=7Qdu\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.14_1672404670438_0.4340418394738428"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.15":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.15","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","vendure-plugin-stripe-subscription":"4.4.0-beta.13","typescript":"4.5.X"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.15","dist":{"shasum":"931496cf180c55501d442e6bb9edf7b02750b3fa","integrity":"sha512-/MhfISg2CJN4Psh2EtPA1Y56tp0dU6YpI9Qjl+ljzIYfJm0URtY8xNZuR0nrBeVwoDW5+Q50GUaz9/urFr3gGQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.15.tgz","fileCount":46,"unpackedSize":77371,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIELZaRHnJr9Mvj/mJ1seLg7zQNNcEV5f92pHX2036ltIAiB68O+lGdgcjlvSiUFhHRKHq1j5q5VXxqj9Jia0fNrkFQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjrwBlACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo3Aw//d4hjvn8WjRf9sQUEnDAxo3O7TYzdF4R49m0FrueCkOyH1SNu\r\nJCOK4HDPyeao5ruEj5q4GGQ4HVJeXL3NKnGsDnul/WDhX0Wxdk38YfeQnrbF\r\na+76vcNA0kLo5IeMsNng64Tx738S3Vb5VcJWoSXAlxvn63fxZ8zc36FiqRF2\r\n/IuGt70CPBLqlLOeBXVVB/gfNj9ID/04CXF7gTW9CV6a/woypSco8DFZfidT\r\ncC8JvoD2EdYPfSh50S5EnNmieWZZMXY1oYBAPomvNOeukwrIgTTUAEC8aaql\r\nEbMh6Rewx/aaBMu9m8jkrt0hZdot9umtlJn/ZGGcVB/MFVxWJCXvJujqXoZZ\r\ntQ5CdlKLKoLdBnA5Q0HrddFo+mYTTTQkQv9F3w7IC0gdHGkLqC23tlyIgDk8\r\nFPfLgsX2MAsd5ftRc0U7w1+rpSn8gqKU1HFWW7/3IcArC+Kh/ORpc/Kna7IG\r\nOKOkbUh6wf9j/xE+2xiTW06MaggyycYZbRGCXqRJxuHMd6E0lAg6pMepAi+V\r\nAu1RcqfPPXWT+gvDQ3wKIr+JNkic7BXu/1a9SLTD7awWgc/D79SHC5TSE3Ij\r\nPyFtaG/2ZxOej6Cp4BIfVvn4R4HDiA71CzHbN63FN/ratRGgwbLF+YlhD+qo\r\nnWv6znX6JRt02XmPk9klXcTwVNoDTUZbgZM=\r\n=gT1E\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.15_1672413285412_0.6221427727846127"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.16":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.16","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.X","vendure-plugin-stripe-subscription":"4.4.0-beta.15"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.16","dist":{"shasum":"6951fa872f0c7d771294f855eac861983977b416","integrity":"sha512-mijmXkk6TsOC+llA/xOFWl3GIns2HDUEYRHN+DnQUN7H2xdBXPiwa38nuyVY0fUYhb0fVmqBDoIg+70LhwaZRg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.16.tgz","fileCount":46,"unpackedSize":77997,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDhRnjTjhRjzvw78lmzDvjKojpPuZlHjK/deJK/PG2N4gIgQkEAu6dvKCoTIldNeHEG9U3MwlpaBYxBbRqgsvbyC30="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjsrFFACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo3Qg/+Kgi/102M6c3eTR9MoYdiBZMLl0H+5y6E7ztDMhtWmyMDo34M\r\na0mZx68N2NQYmM24J0lqQihnHEVZo1a7pvvkxhZ62sxSrgh2JVFg/+Zk2/29\r\nP91SIKP4I6kZ1n5MFzxwY4igBJWMccs9Sht1TunmBVu3ps5oXMRSJnoquUgX\r\nUX0Bh1BW+dBcnLAVYOTz1kvq/A8bN3lxlhs+EHRljyTIFm9DT8U8krZnDv3e\r\nChNcF/bGPkNRJSMoOznXqMVlKNNIoOhm/HfzJTbAiBp9zLOF9BWg/2fSXhLo\r\nrP43Mc1pkf8+asKo/5/av3HDEekPUi9I5PyMkQL+LW23FMatoiEBoZO9NTIZ\r\n/RunrinPEgbSBxWhFI9M/lP/Npx27zB6UhGXbKkq1rfjWBnJCZE9ZKeK1fZ7\r\nB7+hAMiXEgLH8rzvv/cKmGJsM7UID8EoPtjz8+kb3YPlVpfSpmq9DizSX36O\r\nvFDj4Rvw2sNkibPVEo9liPRlwH378O+UyfMfNKWoCNYAzn/NMybX4GAmi/UB\r\nJ3EhP30HkuPkeIHZJXtlkQJYTfLXbAs5CGms/iWwV+r+mDV6ZGvGZEsllJ2K\r\n+XYqMWzJDksUkw+ujcWRKBKpOVr1dM6FCzaLRPS4dBPiYyVeV/2lvD1G1dUM\r\ndRl0GTS9scXO+VvWRL2vQSBxd/8ZISgwkjs=\r\n=x3rD\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.16_1672655173246_0.14180782053463425"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.17":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.17","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.25","@vendure/core":"2.0.0-next.25","@vendure/testing":"2.0.0-next.25","@vendure/ui-devkit":"2.0.0-next.25","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.X","vendure-plugin-stripe-subscription":"4.4.0-beta.16"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.17","dist":{"shasum":"fff3f660a4763c13e8f83329db0e91eb2aa2e8d1","integrity":"sha512-5kj2V9fhsjavG7SvyTd20XJ6LJJYWNUGU63ziTfbT4Bc84ao8DJ21bXXkG0vOhmfYUe2zEtMkwLKZS4a7aKMjA==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.17.tgz","fileCount":46,"unpackedSize":78083,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC1QzitSfETCtxpAqWSxIdmX0hkwEHFCeWxOaOe45w1FAIhAN9kIF5UQ8K5SbvqIiFBSCC+4g/YJ7WHtEOCv133h9RP"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjsseWACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoZMA//XXTSqz9SGjpVL1y2jfkBLkDeda/cnB+rz3MTqJJ2dSS9X/SM\r\n737716fCEpplQsneEpqzi3fQepLfswkTEV8AFLpdbpYg5pVE7HqNqiTnL4PA\r\nuK6NWoxaoeZF5WeB1wWL7baT7frx3jxDcz6XtBnRJLffub/iKHFRWz8z9ywZ\r\ntSni/5MGJdiw45mbyak46SzrLcT0QpxuwzlYvV6vL+Ru6ULvZ/edeYgI6LMt\r\nglHixaRDD1YAUr/Rm2y+7hE2wWnwmgRohfNZ7yANpRG+mYHXAqmX1BCB/wIR\r\n2N+Eb0ys236+SStsY67+4IWjQaboE1w86QH/J8OtDg5ny5QxK6ojCDFFA9Oz\r\nNYllkd2X2C/0c80tM+5dNEOLxIa1e7JxCgo7s/SKAJmhvvPMAyQPWi90xtbM\r\nrEy76Ivt1wP+hr1NIScHariIt3sV2gKAZPsOPrUbtc1IQC0VaccGqKCntoPm\r\nrK1BzJOe1CtBgBBvQxwXS0D4ydgOjzCqKlcgsZJTJHWhkLQ3hHLXhyW2r3KA\r\nlP7az8KY/pgv4ZgX/vBVR/xvbyyJ1zl1At54JcsiFoXznyBIUcKRggvrQFZJ\r\ndJtO4fic+dukD1TN0vbi4gsWY7YSgzBknGtuACeZkbNxmko5jOGLJxQ0cNms\r\n5jSmz/vCxWCtyVKCkcxIuPc8ai6Uc3hH2n4=\r\n=DrkW\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.17_1672660885822_0.20411045029297958"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.18":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.18","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"resolutions":{"@angular-devkit/build-angular":"13.2.4"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.27","@vendure/core":"2.0.0-next.27","@vendure/testing":"2.0.0-next.27","@vendure/ui-devkit":"2.0.0-next.27","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.18","dist":{"shasum":"7dc2f480b0f9381d032b7f554ee5a2bb38e04ad8","integrity":"sha512-DafEq0xML6N6VfefiMWCzgXYMNBouKK648QzkUtQZTOg4+w3pXrMBpZsaXzKFltgWUnC/9VKsXGvhpg7aJ51Gg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.18.tgz","fileCount":46,"unpackedSize":78206,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDS86UdHxvmkMBcvU4Bo8N7JiwsO3SbiCRDWfZg/cMRewIhALFeT0k8T3CJooD+RuaP6vB4eiNFZevyLFxKQ5cNMMJD"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjsu4CACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmojdBAAm9dJHjM/nu1sQh5u+WP/LPA4aBDHSbiF5k93AtDnoVx6VXjq\r\natU6vGjdQTmVnbdQKmzBmQtL3+0MIsdU6KaBA2DN5IgTPPaBxUErNUUtzu+C\r\nMGarNBONFme1vIs3TmLz6jnjEBuuu8IchNrdbSDX7+DMsrThGEPhGoES3hgD\r\nHuC1iNYiuelWZuMv05Vf7sVyiBFVRgO3ZuGrUtwnXNb+RFUWP7IAZ/ZvIYXF\r\n1H4EwoSUChnZ/DqKhqf0UHKBsaiNCSb8VkaSrIVL0gnWkZ1/OgKapMJEuNuJ\r\nfO2IMylEgOfuep9ogrXj9O5RKioUdnNX4PuEiPBNV6mflKldlOYeQWVa4ab1\r\nIIsV4ErJh2zTwEPQip/ryZjrTbHT5XKZO8y7FauqfWiro5GMC7FSC06lXlGd\r\nex4OxzgUaKpRBYjlXmx8kO8G62vL98kYbREFicFIiVoi1PB5ssfJMhNevu0W\r\na0CUXFMJDH52xs0TLrf4ROJbKmVa7lPcox3Wb+YVvgu4qrxzX+kC39sbrwI3\r\n5YdhvvmKDcR4Mxfu4qCpO9LGbtKZShkGRjJilIwVfGZ3utIm6CDBvKMvtN4c\r\nSZ2EmeJPGCyFt7J6wWGkxbuT8ZB2mzvuOIuK0SCHOBgUDl172P9K5POBPmBC\r\n+BiMC7pEGsQFebTvcpuhIUyyBBJgvfqoEck=\r\n=MQMu\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.18_1672670722665_0.02957997087315878"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.19":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.19","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"resolutions":{"@angular-devkit/build-angular":"13.2.4"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.27","@vendure/core":"2.0.0-next.27","@vendure/testing":"2.0.0-next.27","@vendure/ui-devkit":"2.0.0-next.27","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations in the\n   EU area. This is due to the fact that prorations are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.19","dist":{"shasum":"ad8a33fd60d25cad2a1b7e2c990add406d3a2752","integrity":"sha512-HHGvp3+Ky/6XSfsK6cMNTsUxEYhERYOsUM80toic/PFyYTXdTuW2eWwivKiWti/eoS9ajhu8gzruDaKL5tY4Xg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.19.tgz","fileCount":46,"unpackedSize":78291,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC5wvw0LOJcsE6HmzwHQ8ow0O1QK7u7EQy+x//b5vzRiwIgJl30DwQFCLuzZHrChj8AvrgLrUKJWBWiDX5cC5vf1j8="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjsu7sACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr1FhAAlJhtyYl6iu204PhiaOJSMdosdpVeR4K51m5ONQDFKwoXF4pF\r\nxHZHjqRsJOBuVPi4rZxLFCneveqnDqPjrcCZ861q4vv0Hb4ATe4J1Q4ScSNc\r\ngGizCcGzjhWQJ99v78OJ+OrH4cFNGzbvtJNjRgl+wLdqoeSoBo3Lv2ubuoXu\r\nJB7lHpBYyv40vEpzmiRB+6UE+veM+q1wSWs2xe6xg5mG2lV+99WWLOF3YWlJ\r\nLJCzZz1dVBmNuvEs+9LxeOdKYQIFAgerkr3+B+9HQAzVkGXT0qFywk7OYYWd\r\nyJlb+XLo/T19OeDGACuWQbjQhu8Xqf+8aiVpCkH/xrFwtS9YSTD0dTsm7rhY\r\nAhH4PQzpa81HofcnoGhQ3J99YuYqawS6MF2ULR6xeq4GEtWCcebxOafjmet1\r\ndl9LG9+L30lwk9ZVjXxH3V8pL7tLgnxWkT52RmHcEkmz2i/ios5/N2a5bQS+\r\nGhnmhm6ZXk45E5IwmKUpYwDw9fwXRQ7OplwyeGm0brnBVRndmmWYykGpzkX9\r\n+D7xWs/+X7ilHH994Eou3pSPaNSnCWej5Fsh5pJmoGjY0mnu3IXyP+zKTEJH\r\nnWxLObKBgC7304R830I6ZAgxM6vVyd6G3YxKr+5Eieaql+E/R1NarvVXZu0D\r\nwHZ4dbaOazst6mO6Cl4BMuHbRjMP6B38gdg=\r\n=qwj3\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.19_1672670956382_0.4760505943328248"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.20":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.20","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-next.27","@vendure/core":"2.0.0-next.27","@vendure/testing":"2.0.0-next.27","@vendure/ui-devkit":"2.0.0-next.27","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations or paid-up-front subscriptions in the\n   EU area. This is due to the fact that prorations and paid-up-front are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.20","dist":{"shasum":"bf3d75c198b44cd775e2747a836c312ba9802a62","integrity":"sha512-5dyUC/l+SuEnlRITi/cDYf/iUZ46hI6jY8oU8bYp1oiSY3eXm1MDO+OvPpl/aLDfY08EfDV3bJyRUHwizFEztQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.20.tgz","fileCount":46,"unpackedSize":79284,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDJJKlJokduPO7H3+PKRkoUl63X+FfwYH3ChuaD7OBIPAIgL+JcmJ4C1HtrjbapxyZYwKe2Ke6+cDCAm6ypW7rjIHE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtZB8ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrURw//fG+ycY9rc46PkvaOHaxmQ/7GhoeubJJfQQgaalhuSwzTPB82\r\nMv03Gz5Xr90TH52p3UMdLpaIj6fBmej2ooigAS/OiLvxDH0mKRCOnnZPZ94c\r\njLkGGsgXzDLTY1sgjSzcGP2xRB1+/qVVCTiNuZfvpW7wfm5PHIDp8i0YFmgN\r\ny7zS+JYk9xVZ7VLHMFplXJ9IiIproPb8W1wU2upzXNwDkFJqftXmnKNuh2HK\r\nCLN1WniMFHXowrXyTEMxo1M2IusuWGuSbMzbEIH8q3RxehETJ1m2fsKunG5D\r\n9yT1gq2TN+aSpn8Nx0Dd7Ylr+gCCjBh00obfQBUnVuliY3KQOrLBS9jty4fH\r\nfB/XhcUdy1IP5DqwKFfVM1z4XYFRGr0lC6cdZ2OXPv2xrLUrKJzl302IY+1K\r\nfYw9c8cRPPSoyq1t7ATSOlo+3/WlfUwMvGv/miGbgcMfFXsHMb4rpUrZYEoz\r\ntcw+TFF9CNUmnoB8fyMBhTNhXHLEz6GSnZAm8Ksp5lFam9jNr6tcj4V0uqMo\r\nGX9b7zFO687aaSKzOX/5j+5Ytb72I3TOZSF6qCjm8hkxO2MhUhP7ml2nDJe9\r\n8E77BfuErKvEeq4QGy9jW9q2xEY6hNnf8V9CIhq731GrJgT8zKj7OGBfnvZl\r\n1TAXHZOksYsipCP1P3Eq7pJMNvxrnxPIfCg=\r\n=2+tB\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.20_1672843387821_0.14547735854234256"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.21":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.21","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n## Caveats\n\n1. This plugin creates subscriptions off-session (in the background). Because of this, you can not use prorations or paid-up-front subscriptions in the\n   EU area. This is due to the fact that prorations and paid-up-front are one-time payments, and one time payment require additional SCA\n   confirmation.\n\n2. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n## Advanced features\n\n// TODO prorations, downpayment, startdates, enddates\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.21","dist":{"shasum":"bf535156816982549d8ce7d1f13d75a8877e6023","integrity":"sha512-Oeoj6sdWhpnDoO/GPanzCVQMTTiaFD0YryXOxo4ZKcVwdiD/Rv0Lilpc/1bUseBIzg7/F1cUVeva3ioZ9KwUYg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.21.tgz","fileCount":46,"unpackedSize":79256,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGr3SCRRYXAcIJrILHCdQudtVdWCmOqMfNgq27e82R6YAiEAovbAUrxrXwRZr58IizzZ/sHn6BY6B5/IVIgJ6lbDbTk="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtZMrACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoMMQ//djktPoDhvBIhEMF2KhC9koJWq5okHfRMMnQgCEuO65+iIYcs\r\nwzoW5hPfwrzhy+0cYTok9HTO0xEo+HLBf3HDGrrfVCyI+Jh40D+GB55uJ0B9\r\nyFx1VcK8MK/Ad5+01RmxlwVqPlRScslLY11v4SgN6dJsEK88b81i8nCgUM67\r\nnoKP7odVvKYt/wEgMTWaMT1/u6BewwhhrQl0uPDiyYAmyu0yBepyLTJTf5yn\r\nVipxNWMkAZjdC1izhhbV+IZbSZvqae0lGYVUhjinJLrZbCS8mdG0wOWOtmQ/\r\nAb+Or4JQFf/44JWZRuRYxd+6yS9MNEIgpCYjf3pSaHrAKrgYfaXNznOL86en\r\nxmGM2tj2ZHCqv2NdoMx1Qd5S/XewXWQjgUoCJzWWkBhzO5DZ6jWLJdFup6Hc\r\nmdyoezTzUBnioe2G0rpNKffPXBIrvtguKodcqWfcpLl4pjE3C5GtE6NwG8t8\r\nglRZLP6ITZU/xU8JRx6bdpZyHO6cMKv1PrqxyqPkL0q2KWBTytnuhYtbnB42\r\nbtzhniEdGABIi2cKlBImWmAcE76gMrxP5qaRlyy84WFXql/fNe7WHg/iAPiY\r\nA0JftlctPuF/A+rcNwy5jYY0aL5xe1ldnfY0XV1n6TYsUOhnsXbjWexjFs12\r\nvlhogKCpNcOOTkj4e3Ba8RMvhBPeQHTJ0d8=\r\n=Z6Em\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.21_1672844075179_0.8796544895455141"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.22":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.22","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.5.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Concepts and advanced features\n\nThere are 2 types of subscriptions, paid-up-front and normal recurring subscriptions.\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n## Normal recurring subscriptions\n\n// TODO example\n\n## Paid up front\n\n// TODO. No downpayments! example\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.22","dist":{"shasum":"53dafc7d468cb4ca551b7189e60712409987d5ea","integrity":"sha512-jnAgJgB5yQkUR198Yhr3TeKHHgE0QprcNsMSic0Em2IB2dHVl4FA283XhE/fx2Bebwiq1HAdBdPl1zYI/N/mRQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.22.tgz","fileCount":46,"unpackedSize":81687,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDNBp50pOH7PfufhMWcw2zovS4mZzOEEyJ0O82GxH9DZgIhAIX73yOJL/7OPXUTw3tlkxsYO+UbA2NMKmRRWT9vGPzc"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjuDg0ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq/hA//QQ4Jvm/agIJXrnJ+dgdXSInRJ9soxFMw1xia0PkvECcqGEDD\r\nyGXIgsBK483tJvrDmJgxDHTsRAn5jlgr43ixh0WmlKgInTycPa6Zmh8EfOmp\r\nv8BsPHVoRdqBcZETxHlRcNFBylO7vVwnAubh63IRn5WvY5nljls7bIVjybut\r\np0T4oTaSzCWmuOZYwqIn8u0u1Te5ewARSJJirICGE7PjGfxwrdDz1JON+58N\r\nxZFXAhIsloD3stvbd2ukCa+mIHMz7zTMZ/Zh0mg9ldzEizPTOl3vaR7KUTqv\r\n2kXH6iyFvp95rreHWOdcTfqLezVRrOhWIIHUEudlO0ntJiQo+YY4HZDU1xe8\r\nwE3XtzdK0WoR79Cf3ifZL5YnU43ohvKEHNpq6Uv+L9ZBcyo74FrHWcR7FSyZ\r\ngLq4eDv0JxPKsBpHHh9ik+JVxrGb7pQFgw+ho9pvxu1r7caEOHnILxqln/BX\r\nQqEuw7PjoPsOSh+3vO/8Cb7cRF57cb0k7NITFns2Y3i4AJ2dKVq88NmrB2+X\r\nuywoLuqHGhgXQeza8VvrOxbMrpE0gMJ8WFnZvUUt6NKc96+QD3pBHqh7fCom\r\notOvz+57xUpHHOkqeuNzRcr/UM1BxBjHG0qepijSPr7Rm6XYHUCFhgOE7nGX\r\na8nRa8w+mR+FGJw5waAJO9ngyrcJn3oE5oo=\r\n=ZHn2\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.22_1673017395910_0.616243637958596"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.23":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.23","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Concepts and advanced features\n\nThere are 2 types of subscriptions, paid-up-front and normal recurring subscriptions.\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n## Normal recurring subscriptions\n\n// TODO example\n\n## Paid up front\n\n// TODO. No downpayments! example\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.23","dist":{"shasum":"ece0213eaebd167af2f5cbcc96403fd50fb41ce0","integrity":"sha512-TmB1ontK092605qfCACoX4ZDPyQJTnOUYbynoxM60NEmZcOgI2b5OOxs1NRSosbArRWF2yANMvtK+NEKfdSheA==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.23.tgz","fileCount":49,"unpackedSize":104009,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIC2Mnd9miUZrN3H+E48RTDCz8FCcn2WYbCcHT12q1UDQAiEAkDtsU76ExRBvDJ/JQrW9cga3NH+h7gJbA6CNKA1gxOI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjvBrzACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrUbw/9FMmpcsNYM1Z7coQQGkUMEE7XmTtrx0BJyXUDhAAztGipAgFC\r\nbDO8ek5ziZ9js40PLADHq+7yJHq07TGLNlQ8C5VnKZG+cG4OzBVKzu/wg6Y9\r\nJVQ4rxHLYZmjwoeyomCyNeprxU6Ppd3TkFLxnbF4avgTL2coShjtePLxiXhl\r\n7gHrY7N4Zvzs+isLLUW4LqxCJSwVy0OZ0SU7KB2kQksW/rHTM+TWG9EdcTla\r\n8sR4UQhzzquJktS4w+X9meQp7ld+FBLrLzra0qFYrbHwkHgncO/kEWuPoPio\r\nMquuExqAUNlSSPOAzFzyHdND8BpXP72adRFBftFhF3Kj+l5AG9DM/3rHv+En\r\nyts+6Y7txCqXT+xzQVCqhSYZWO/71bVxhVlmi0ixuapHYJTi5z9XbjhTpglm\r\nfV0LNHbFq9OSao2p6iac3jprs2MY+44CVS+fd0k5TZXh4S4guO3uVVRHm6V5\r\ngr9AtjXg5dtqryu1AFXqnWTbSBInZcaEkDjPOJQT3JyL4iOMBvnmK+utJeWX\r\nmVIOg5XjCjZNNB6PU/umrlWquaspw/+VDbBrjKM2oClF2eAg4Dzn6/TKOlZ/\r\n23RfPI+Df/bE/kQV4e2yU0YyJoF48pdHRoTuCV2/CIx/W9HQ24UvNj60KP0Z\r\nR0guqESDKCXXmq5gXHuNNWpPs2oqrPJ2Xto=\r\n=U3rO\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.23_1673272050936_0.7090559736660864"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.24":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.24","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Concepts and advanced features\n\nThere are 2 types of subscriptions, paid-up-front and normal recurring subscriptions.\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n## Normal recurring subscriptions\n\n// TODO example\n\n## Paid up front\n\n// TODO. No downpayments! example\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.24","dist":{"shasum":"7f985a73c144839b7a2d639f7aa0379b86c09509","integrity":"sha512-28tBrBRvyQW9+69dKExLDQ11cd5TQJAFwcLiZVDxtLTF4v1tA1gMvRE/zEIPfbW4KOvb5vqAVx61Mi2K86grDQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.24.tgz","fileCount":49,"unpackedSize":103445,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAx8fXb/wroJL526enmzSxkwGH+e8WIySLPJOMVZvnWCAiBUcCTt17j3WWqxq49CXpDd8WacunyJM5OfyimgMsQxZg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjvCrcACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq9tRAAmlRSSHpAlAHMRbQFnEyykPSacS4FLMKyuWkoAsiDYrcmaP93\r\ncr/pWQpD1QRFTEzyaFy2w8ILNewG0BRykSkTguGaMwuUqeB8f76ARCGzS0IN\r\n5V9Lw5RMt82VcVyWLRBl/t0rsSN7YTCy/iP7yhTGIEBMU+Tg2Ytz9i2RYBVC\r\nTG5XonpWx0d++6GCVJMP31PL+snX4HC0ruSJO54vQhCe5QQbcSDfU248gu0u\r\nWQGlSJZg1+JNDCGny1JbmqhZLNtwdojRjuY17gbwDsD0UCft7C8VBLi94x+a\r\n2F00pwIcR1ATfgyh9NhqH97Wi5N09k33wma2b0kAdFcB395AymIrWbyJgV0i\r\nN2xVPUJkYbFZA53eQU8EFlc0MhhRwSztVkQOFTLKF+x/r0Eauw9EBUBdKFNJ\r\ntEhhWNAFqhVbJXZpNeF+dWiDD+Zr5M9bePLLYBwEYM0PJ3PjGpHWajXyBfoS\r\nuRGppPH3iaLtKwyCTZvwLJaz6qHwgI+ZZAeAAHWKnOCO97nZ0/JGghe8IU5B\r\nAZn7T5iqist2U66lwoT3yGl3uAhb5E80/r9X1uv7Gyd/S7l4KziulDjFlwLm\r\nFNrxLZaC0FXSjq+ZnQc+vS4Y6xApPPOlmCD99jVNGmTgjcMYHnol/5Nd3THy\r\nOMw6XRrXHNaD+FO15jqaKwF506oAbuphitQ=\r\n=c9VP\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.24_1673276124626_0.4834078740925696"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.25":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.25","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something liek localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Create a variant and select a `Subscription schedule` via the admin UI\n7. The price of the variant should be the **price per billing interval**. I.E. for a subscription of $50 per 1 month,\n   the variant price should be $50. For a subscription of $300 per 6 months, the variant price should be set to $300.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code**\n9. Set your API key\n10. Get the webhook secret from you Stripe dashboard and save it here.\n11. The `label` fields are optional, used for displaying on the hosted Stripe checkout.\n12. Save the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Setup intent.\n4. Have the customer fill out his payment details.\n5. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n6. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Concepts and advanced features\n\nThere are 2 types of subscriptions, paid-up-front and normal recurring subscriptions.\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n## Normal recurring subscriptions\n\n// TODO example\n\n## Paid up front\n\n// TODO. No downpayments! example\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.25","dist":{"shasum":"0611f6b521a147df057ecb6c94e5d325b6f6cb75","integrity":"sha512-oiCmWfKELC6MWLPjIYQ04sC/Gp+/U07DojEmxu1mM7CfoDIMCHBSW7+tt4fje9nw0twLflDCWAslnk4KROqnnw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.25.tgz","fileCount":49,"unpackedSize":112361,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBGp3ESSYvZeH/4g5blJSAmUQr0CuxOsrks+Ul0bXLD3AiEAiSvZQCPoPSJsxrtDIOewazTm+0do/Z7hzA2t/7iJ/wc="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjvWAbACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqRbxAAigehbTKYWU9orBOihsvew0O7GoefN2RkZkm/5IbslX6+USHZ\r\nZG9jsF4JFHIlV7R8gO1f8csUXBHMrtYqcLQWtOKuCKUOR7suAFCA44BrxnlJ\r\nKIABKs3wNA9DQe/8JmfyystG4dOLyVOYAsP1uvWzhjIC5r7UqRmHKTMvSbmb\r\nGAXRriNzuFomk1Dvk+uCBbV2Zm8WETIjttb+iQsgeG9oxGzSZ46mzZyea/Gj\r\n15dEo0rao+2im2OM3IQQF3kIVwNloG8a3quo9tXv3hx7yL4450M8cr9J1W4R\r\n3gm33xbN8Wy14BvMZPwTCtfVfSx3jd0by9U+m4Z2pp062jBrFDcOwcdmHopH\r\npA/LD6QFk5KuV+TnNJfxWXjhbmV3n26YsEtgdIT0KQjePrL3Na1oXw3ohbr3\r\n890TKWCCCaEIzPHhi55g8XD1mKyWoVtb5ANnCLE0YS6dAX44xABNI3thLfM7\r\n9F5UVPLUnwISB16Ljyq7mi1jHCBoKcEJg8uytIE2aAB+CmQmcQ9Uu3JPj1Xn\r\n9jRNm1zYjj8Do3naEnrBhZdfcFq4ZSk8RT9wSdEO0b7hwzmKx6Zbkt4YuuyO\r\nHu4qm5FyQnPOiMu4eJRrFqg2R4FaUkb/XFMshhy5q6jC6yzE5RsWNijeReF0\r\nxPE8dd+hFYLvHSux/sdvON2OCnBiHcULOVs=\r\n=lXFU\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.25_1673355291073_0.5150568167249672"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.26":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.26","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.26","dist":{"shasum":"ff3a4524f2410050cf340b680413205ec2c22d63","integrity":"sha512-UDeTrkCgs0UoLg4UD+H7iboXu8jbpBrfehD5/Actp9BQMwLNa2284b4AsKKajJrSZQLh+1nuimWHpmzvsfimog==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.26.tgz","fileCount":49,"unpackedSize":107600,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCqKKx7LiKsfnVIAXtBUU6cx56SwRUcUFqTyRM/G4CiUwIhAIUDDuUwhL/iM9AeFPgGUDXVGlPfK26YCwBNqzlq/dE8"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjwVpPACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqihg//YFgypyi98YxNxMMlzu3jm0qVD1IUoZxHzu+6yHTEmd1zXsiE\r\nun/AivcQ7gWVFlTbVmPmrgG6PgOzZJV/6DFC+xgcS0/eDy0VBoKy/JLACzsX\r\nqbHHC9cgHRS7wV5DEcllncOXE0Qt168d/3lZnK/pB1WD08Zo+a09G19yXCPX\r\n+sS50+6URGIGWs8omchIvcAxTYxdg2VOCCRC7s0QCLpUyYbYhRS0JYaA/hZK\r\nzRi9DWq5Y/UOpUSk3JoaN+4sUjN7sVk+uL5bZuUY1OjFZUCd81JyEloF8PDy\r\nXGkddClBj0NbunioyelKWaaXPFBluzm5Tk3FVRNrT49GOTnqvLTBqa/y1Vqm\r\nakSTu16MYu+sjysiXa1682oyOyOQBfQ4tJaGNKgysLhLLNpkK+qkAMJkfn2f\r\nit6QB2X9Ek/wAf5UlifXefuqgXhW4KOcOuYmg2ED038u1Og8maa6YQ6g55qY\r\nljhsEVDVXuRbJy9gtn4T65CqAUZ8Y5ZhIxjnCB4DbRnGd0Po3DU5gl3fLwvT\r\nXpwfgxS6KmDrdMfcwlPMbIJivQpzJkF6Njo1TynAmkqjXz7gbtikMdHoTWx4\r\n6j9xTKklWtgjU8XjmHsNo0O8a9IAxovoGxqjvk/8/Qp4a639hZ4SgwsmbGWg\r\nJh080T6M26ED4tHmaKy0CayVbF6GHrx4E9Y=\r\n=+dY/\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.26_1673615950962_0.2084980563601888"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.27":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.27","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.27","dist":{"shasum":"06a27e8e39f3007e6f7f9606356bab2313c0fbc7","integrity":"sha512-wJgRA5f5RcpLXaHJvhlTZdxV40zsiz/WA7GPdwCu/L0EIyVpKssfI9FQ6ufYD0EmrV5N0P//vSUbDsr0Rqaxgg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.27.tgz","fileCount":49,"unpackedSize":108290,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHIOPSB2h5Q2v/u8/7kffWPc/J1D6Ij2Ov3iQOy7dt7FAiAisDd9+5tUhesqCkAL3Cc9n8AhGVYjOZlzUSHIEGcs/Q=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjxW+2ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpKSw//VE4/7MuUuDnPu92DEg9hmH741eXwnRGuj7E0kA2vuQXlyelH\r\nXOdzD6JxOyU39QvqG2bK+5wz0tkwi8yWduBef+X2sel5rQ+60sr94SGfZVdx\r\nMvqOtVmEZzQvvPH2Pw+3JPNwxDY4tDKWTQzAx4D8U1G6W0zbFo8Z28f80zBO\r\nsHcsIBGTHKs977dBmRslTALwkCcouSweHenFvGTkWEK0nJHoP9XTClNpzDr3\r\nOneUtRyp7z+v9/ImxLnRL2LTPKkoY0OmTCWe7W7bjtsLHiOxHeLBcLfLyHEM\r\nFgKYYLtwh68vSPni6Uzvt0yCvcXOYUv0KQUdBUCvL1mDs7ibC9ktxtkP1RXU\r\nnF4ESTxDUEMksW1A48BUQ6WHykKLE8177yKCpYjB/UUjlhfRe2skqHad+w5h\r\nilnkCOD7c3/h+RpBjN65HZNnD0ZFjZ2csn4vi/rQ8HF0ilS+Ur7xIXvNhCWK\r\nbV0skYpgpGp/qKpesX486OidkoZWZIT3Sp5O0ndyG8J2SVrONIY5qVJUEb2q\r\nWEwTDGdUnrlH4QVdp9q3Bw7URzulY0O4Mj+Euvh7KTOqx9+B+92QY4K+mL2t\r\nWFdViXlRf//e4SRdX3XT9fV0iU3V30Ptef+MFa1ncGbc9p1ZvHBTKC+qsfju\r\nCkZ6y2z3/ACceYrAOQY7Nb0y83SossABkL0=\r\n=FW7Z\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.27_1673883574666_0.140474860565327"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.28":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.28","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.27"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.28","dist":{"shasum":"6113ac7c96e27980d77e160e545f0909c6428439","integrity":"sha512-MPcqaS99uAOmwUEhosBmXVHvLqz0TFjcC+Z4I88K5+PBBwyedy38OTovIq9Oo5EDDa50cs4gHBRn/AuzLsUH6A==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.28.tgz","fileCount":49,"unpackedSize":109554,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCDs4R10JPN5bdY/NbG3Ar6phpZadDR4KaRVKbqvHm16QIhAPEoslDHIE4meU6C5Ailm9BtpSI/dZoclIbYx0DEPLTE"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjx+HZACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrDvg//RW3FWMufr/rzaFHU3B3HBIHYJtwGIGsZVk+EtqclqsPI10zx\r\ndPWPAYgm2xOjR9IIliXeBJLeEKBV0/kE841QoSASK3Z74Tk8TTN5CYtrxl39\r\nomIlGktQV9BLdzxuDG8Apic+YmfPMlqipJnU0iz0rwUruhRfJakgks7cYIZL\r\nJFLMebXk2d3lx1jVCor/yLMpki7THfq5KXFE7uVOK9qVp3vqCsry0hydVnff\r\nQ6kLb4RWZOivCQ3b0ThbNJ8dmcObyRZqPOtqBGOqVCTm3+e1NVEAeTh7a1MS\r\nOSs+wutu7LJAzm3iVhQuwGs2NfN+1k3OyCThD68nUoHgTR1YkwvWbI2F/fGl\r\nfipkZdjylG4DUmTng5mOeGUl+4B3+a1IGgVvLr5KgYB2bPDgBpWtMB2s8KI4\r\nFsDeEaZz6CaeRH9gWy+sOjhj/im+h9e7n1Ajr1r94dXK8pnRfFYK+OmUAEF+\r\nyEeaLG1+EPOqhXo8Q3qmQm0gz9adr5viL5R/rdSyl4Bk8Urj2ZNuR/s1B+7S\r\nUdo1fXr1JeMvcdBuO1Zsu1x4VY3k3Ku5Jb0als5THy8cUTXIHnk4VC/2AjNp\r\nQOH6NzwLqT7/498KiboOB16xfeEIpqM0o0XeZ7QOkEpi+37astiMo9oFqFI6\r\n2DjWC2QDcRDaRL1Fu9uzvlxQRLLdmttgTNs=\r\n=+SC5\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.28_1674043865708_0.930826132619107"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.29":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.29","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.27"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.29","dist":{"shasum":"2b5db548e5a3f0d183221c3dc8c5fa6287d3dac1","integrity":"sha512-j7WQ+gRR7QtRiEw0s0B2fagM8ix/x28TGFZfGw6ym7bEnl8JikzwBtKNSGYIFIDMun00mfqHOUYLwyllsQtGFw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.29.tgz","fileCount":49,"unpackedSize":110940,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCCK5HU9zfC5ED/TuBal2l7wGZFXYUxzFRPod6amxHBZAIhAJfWDhxw+Xq3HVbh3SPEjb+arrUXZ2/u9Cb2SZQMaD2e"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjz/cBACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoLtA/9EPjdOyjQOabl1rJMYpTL3vNKjX+7Rz039xBOpvWcHy8+/myS\r\nCviK6lKXJzPAZOnC2TOTGCEVz0IGQXWgjHMglQe5PaBXEH8YFgihzcM1KWNE\r\nf2BedEyXjcC9JACrtBpZEQdNVS+Q7ZXsqfNVwbR0U6KFlBe2j1QzjbEUhuW7\r\nikX//X7E6MAsYI/TfcNQ9/R7CVtf5ex9HjKSvp9o2rZHTxflBRnYjR1bFT8L\r\nVC1/KNJ/Yg5DNVeGSxlb8UjNLJhecnQCDu9rmnSuxCO9i401kmtBjicG5YBu\r\njf7SbC+iqOgmGAvgNIcJHxZBKRJKJDTqnREHsBnqt3sHXcTjas2Dg+DF2HE/\r\nrJl1WJIfn3nnpQwWTK7ErvaOtJEWi2o77cPdSWgjMUUurHzte14yrhI7d7mp\r\nsBZPJdiuDMCLFaCo0ie1+45wkha+c/ZzOskIEVkfylMqzVwPkpM/0zcmLuYk\r\nID5s2tEt7xTNO/7rBvtiwo40/NRUhlwfMDX863u5YyXfDjxW7te++YxbG6Gi\r\nN5NLhTSdh8Dr2rMsmww7NPt8wmcFP7h/Mx5YjoHQm1XQqJfrtCjkWZBhYxcb\r\nwX1RyqeOoEPuhEGwgzDF0OTcdXJFUCcIGy4fG5G42H4uAiuqHBrcy9f/Bv1H\r\nAqayQsO4FJnGvHOMomt7gDLkv3FY4Y31PS4=\r\n=vaFq\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.29_1674573569011_0.29598849229360735"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.30":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.30","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.1","@vendure/core":"1.9.1","@vendure/testing":"1.9.1","@vendure/ui-devkit":"1.9.1","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.27"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.30","dist":{"shasum":"d8a13366e4e65b936b46c14989094e9159c733eb","integrity":"sha512-iq11k97QsZUJowNmupdAupSYJVvwxp2n8kIc0Zvhx8qHuGw268LUAXN8Sa91HkMq4WUbU85TlAuh5R/aweOxLw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.30.tgz","fileCount":49,"unpackedSize":110749,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCxmwkY8lrTSzw6dvg3Iy5juFjrUkwDdgweHO3k1eASYwIgKwb8OjPsqLS7rkNY+4xqqUY/93Q66I2tmX7AhirFNik="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj09+ZACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq5cA//Wb8nX3iBeWQZSmuyGrYuckTZ1gIkBhI9Unee0dtQREIp5+l+\r\nJ89farzFF3jhdHJ4vKM43Dib64np1otlIVnV34T5xQC5qO5SrPBnljI18+ZL\r\nfdsH2MS7LAw2KRSkAXwdjkXFcsnhFpqm4pKuqWt9BOZdf+TLF0rDp8/PM9iH\r\neKA03M65BWuT+lP+4Ns7fsYLcM1ziVxLb4S7hbm/vaHTsA/Id6VmCKk9hZeU\r\nEXBNlQjyvSbEpOf7tE7/+4zJ5FE3H/C0RNdr6UXPGc9lvDOrf/6F4xkV8QtY\r\nx+wpJLjjz5gwJv1zAzElM+idxUGjTAIBVw2//UpVc9mqIiS2yuCMK2WC8H08\r\nv6cYh0r5kj6/3v0z8q5U0G3NEwXmWZhAhQKM/wSwyidXp19xeAAwmKrnHJ6+\r\nWlTA9CLgZvb53SHILbWor8NXBeY69lvOMbHXwbhmbLPP6qWRdRJy4i1D8hAw\r\n2JhHnsTR35utzVR/F0BUPY5/MKkT9bXThU7ET8cCUz+ksT+Pcu/narOqHDl5\r\n4rbds/xGv/i13n9r1gAUd4UtvAk1r+hEI0ud5LS/a9rX3PG62+VEmaWF9gKZ\r\nKDDrq8dBtx+Aa3mAttQB0NQHcuuyG/BPE9/L/m+0dQpGngFAthhjtzY+HZ4H\r\ndlESX4Eo4iIWFWDzljjz+FNZ5xwOJtkXSpk=\r\n=ZHNg\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.30_1674829721496_0.17530328644115323"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.4.0-beta.31":{"name":"vendure-plugin-stripe-subscription","version":"4.4.0-beta.31","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && tsc && yarn generate && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5","vendure-plugin-stripe-subscription":"4.4.0-beta.27"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\n### [Official documentation here](https://pinelab-plugins.com/plugin/vendure-plugin-stripe-subscription)\n\nThis plugin allows you to sell subscription based services or memberships through Vendure. This plugin was made in\ncollaboration with the great people at [isoutfitters.com](https://isoutfitters.com/)\n\n## Getting started\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. They can be configured to auto-renew after that duration.\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n### Examples\n\nA variant with price $30,- and schedule `Duration of 6 months, billed montly` is a subscription where the customer is\nbilled $30,- per month for 6 months. After which is auto-renews.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months. After which is auto-renews.\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook` (\n   Use something like localtunnel or ngrok for local development)\n2. Select `setup_intent.succeeded` as event for the webhook.\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Start the Vendure server and login to the admin UI\n6. Go to `Settings > Subscriptions` and create a Schedule.\n7. Create a variant and select a schedule in the variant detail screen in the admin UI.\n8. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n9. Set your API key from Stripe.\n10. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the created variant to your order\n2. Add a shippingaddress and a shippingmethod to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule.\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n# Advanced features\n\n## Paid in full\n\n// TODO. No downpayments! examples\n\n## Prorations\n\nAll subscriptions have a fixed start moment, for example \"Every first of the month\". This is also when billing will\noccur. If a customer orders a subscription now, but the subscription starts in 5 days, a prorated amount for the\nremaining 5 days will be billed to the customer.\n\n### Customer chosen start dates\n\n// TODO\n\n### Customer chosen downpayments\n\n// TODO\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the subscriptions default will be used.\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@4.4.0-beta.31","dist":{"shasum":"ec9b4ac46c9ebd96190141cf6baa64070add7a8f","integrity":"sha512-rf4dvNpKa8dSPwi6nQvs4UU1rXRZhxqJ/NqmVGc3+uMACGkokHL15Hq0pWnFtEF8qEFuIFexEmQPzghGh32urw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.4.0-beta.31.tgz","fileCount":49,"unpackedSize":111655,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDqZ/OXgxRV5oOJaDyWheW68FY33+3I2BQafNKnC9pAZgIgNxBnqdF2neCNiBDTraMqADYuso1704zpCfEAalxbmb4="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj1+PrACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmraeRAAnkTin5wMfVHryNBgXbtSYpjK7HAFqabzHK30C4vF4dFS742W\r\nkUfsjVbuuxipA2b021DOGgb6ml+rc6LzfCP2n14hUjwPfcjNbGwW1FBpz5N4\r\nvfzMqEIW8AeF+GjNJNwmlqOwvqzYvJg27zWUPMWSPvpibbLtjYkQezTTKxCp\r\n6+u5EnCqk/RFxfCn+HDCVdthlvFLVoM1Ca09IPmHrumjrEvtbFiDmKPjSF4S\r\n46cL82TXvRapcV7/t5sD8Wiaw/9vGFNa2k1swxqzn1TKZpxnAVjyLV6toLuJ\r\nowez7juWsfA/a4fSLZFoLSHiUVRGs1MbiZPxdtbulvp49kPPQ+X2pWiJ27HQ\r\n4wpJ+kfDdSMavh84LwuEdJDa4lLmFouTlJcPL0gNo51U7HnNJ4QfWdHttCsC\r\nCaKwE2zd0/WYOPEuJD2/JGLoaAunrl4Vopn5lKGrZNPh6eKhY69wgUo4HVQz\r\n5clGRM6aDXMGl6HTv64PFrPdworQav9kkGVeVydqwjXF/gUbYIxdNxkzdAed\r\nbY9bUnNQXB2fzsHRdYeEeY0R/afwMpeB4M8zrMaEFeV6WCoP1hevvr9eo5g3\r\nd5jRduv0mEIwJOXqvTsyvmmBL0WWYnnja7nrJerbs7SqAKi2RG1X9Dkoxocm\r\nMMB3yQ2eXfwvFrt+K3jQT4iW5UJQQGH+5QY=\r\n=Y9Xv\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.4.0-beta.31_1675092971562_0.589872230599116"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"4.11.0":{"name":"vendure-plugin-stripe-subscription","version":"4.11.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"e2862f35c3197ea8e62a6d0920bb897a774c2581","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@4.11.0","_nodeVersion":"16.13.0","_npmVersion":"lerna/6.0.3/node@v16.13.0+x64 (linux)","dist":{"integrity":"sha512-cWoiOc9s1UbuYbN/RYsrBiN4tBaj2evU7sFvtbWNMGN+5p5U5GtgRfrlLC1Kwxp6ISbVquAhnNxn+/kE/2dW/w==","shasum":"9a5e05cf452ea5e385402bd795b144351f9cf30c","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-4.11.0.tgz","fileCount":41,"unpackedSize":113233,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD1XnETtn28M70eZiu0+3hcegIky+JSSTv+7mWMgXgP6wIgYWEzRWg6eoJhni8dj/rtXFvccmXLD7YUU1b6lfFLWMo="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj4Ov4ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqkSw//XkDourz1MH1UPC93IoNWwH8Y6a0gwh4882cfNTyPakPIsnr/\r\nykYDrtoe7iGG8Mjf6+ci33Gu6a0WLyTZxR2CmH8GJZ8KNwWjnRfY24i4oKiw\r\nagcm5w04PSWQD8dYHqlbw/fIcZ+0MNwAxCBvYr7NCSEWrmT5NJQwqAoRVcsZ\r\nFs+9WK1s2tt1LmR+kmEWnaZNV6Asxf/b9KaEXrlyN4z9VH21YHuNM/fquLiY\r\ndrG26yMK3fpfLMnq7h9XEO+g5B/jsprMm9AsdIKM0BHrDHyCE1nkVNOaK3BL\r\nU87bfBG8cQZMZjFbVqqkl2B9+g3yIFh6XIjOCxDhlinjoOlQsrC3SmXUC4vL\r\nBAwaoSYU0rUoXesYtZ4f2cz0OSOqhFOm8U42QGxDMKdG9TIgOBqo4KPPjKnB\r\nuZs+bua/WySoOFQDtAl0oNJZEVJ01B3WJlYzbsqZOW/kegcCI6KIrRu6PksD\r\n1ycDzDgsYTE14VfrlZqTN6nJMeym9HDYIU7GvC73vxDsdS9KCWohUHV11DfZ\r\nzpfFsBHS3pl1NK2jMTD8Yn+JKhe4dN7fRkNvPxJYPaQsauR71EbKay5klh92\r\n0Bo4dJxID3sSezBNFVggGRl00cq7/aN8rtAnc4Ul2NFJm6RbgG6Y8fsr1ENv\r\nM7niXtymMQVLSwSCSWFY5/5yq9kxjEg95Lw=\r\n=Tyo9\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_4.11.0_1675684856219_0.3029831950268056"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.0.1":{"name":"vendure-plugin-stripe-subscription","version":"5.0.1","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"a1694598cbe35d360a00208db01a6e7064401f0e","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.0.1","_nodeVersion":"16.13.0","_npmVersion":"lerna/6.0.3/node@v16.13.0+x64 (linux)","dist":{"integrity":"sha512-TgXQVUzHhbscLXsCaDy3RSGuEQ1jo1TsljLc47pvuAWyS222gLeT9LCbzLXKLt1+eqjcWRb/9Rb6Ycj6kLrgRA==","shasum":"333a6a97d4c469db4e9d8909560d34b80536da6f","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.0.1.tgz","fileCount":42,"unpackedSize":123789,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAN2H/KpfxKpvWkg36msR6+dIYLGD0Xlm/o47U5x3p+YAiEAlK/GtS1oMyeohREe3u0asITTuRcUxnEikKWJaZciam4="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj47cPACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrDYw/+LT+7GaYai5j9xACzIDlMnxeRhIKtQqNY6//70ilVqR92tU1V\r\ncYxMzvGpR6lK71b79Ij3yPSydHFVRJE2Zpg0S0zflleocZ8pfACQ8bP1UMBd\r\nSqN501Ctvn6Y8XiB8TFcIvoGDST+YErM0dLQ0d3a3kP40nWuMRfQHJDn8Mqb\r\nLsEyRsTNweMwce/kH6E/bL0EEe4N0LBoC641Su7ehS332WkXwr6F1VjfRh0Y\r\n6KBctHuAtOjaT0xI4WAQtixvtGWzQfWaQtXtXM9ZXbgP4e501zSz8UDPS89T\r\npZhr7cpCYpOfH1q5PsVy5LfFE8mhAQyJt3AWQeSZhQqcmAyF+By0XSzG12sz\r\n5T/q3GWMjffVTWlmwOrf7mrJkvHev8KMQxzo6hnVAT36tPSBZG7Bbel5MiBB\r\n7k6mLqq/xx7OPiPBzKWmSa1/sVnU4OhajPQN54aboDpalJe2WrY+It+tpxyJ\r\nt4/JkzBI6wIZEoXBd7GC3RTaleLHF4gv+zlYdi0tBOpOe0iDjGNLDp8ZD+rM\r\nIMPZGII39DNVSoxwE5PAiR5gmYmVV79i70tYMZ2cXlq3ZLUykBDuAcAyoNre\r\nOKQmG/++WgEeY5CcZ45M/52omgOQA2z6ciiHxoWk7ksImbq5WSM+Nm/WbPq5\r\ny8Wl41naeFIF8pyDks5Ngr9LYB758qDQNoM=\r\n=fkau\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.0.1_1675867918953_0.026766164398833503"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.0.2":{"name":"vendure-plugin-stripe-subscription","version":"5.0.2","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"fdb9366049c4199bbebf2e966d5167178745e519","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.0.2","_nodeVersion":"16.13.0","_npmVersion":"lerna/6.0.3/node@v16.13.0+x64 (linux)","dist":{"integrity":"sha512-IWdEuap1Lx+LqPCmbV+l3g2dBPUxrvSBOwGEsV3NuxVFHbepN0/VlHWG3zzWKofqTH+wxPVB09E+bzzs6OIq3A==","shasum":"5c932d7c2082a9046b24f3d1d538fc72a4e3ea6a","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.0.2.tgz","fileCount":42,"unpackedSize":127806,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDS42H6T7rNMp5eMK6LpnO1yPqah972aJW6OEq8ElgfOQIgfU2KaIz202ET/E2poAZU4kTIcVVVD3VGGEpopyE+Fs0="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj5lJ/ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo7NQ/6AnzgyBRvm66UOBh2oNASZXmXgCr1pbxKTEXGcYZIBzIzhzYd\r\nnIw5JQdWt4nmoejdWdz07D6Ev6zAQ6UH54cvEBUeIp/4Vk35Qh7UplrHPtCI\r\nKrRW58ypAICvPYaLQUEZ7fI2Uxbr/xitwsVMtUG3GbqpJfwHgMqgF3Iqbm0h\r\nn5aEljjrfSyjxW18LwBqk7EjDgJfQprJpL5Nm5C7ki9KzmU02w2Z7YDt5Foj\r\n5tvDF8lSteN4MFCagsRxlI8xPQQ4A9z1zZtgJjB0oz4h9jSUTUuElmCB+z7K\r\nSgX+Vhl9SjThIvuP9KtLuQ+ZB/WyBKC3wdsvnpOQxFjAWCW8RvhXPz++1j4j\r\nftlZsUtyPxi9pID1JeXyy3wC9xhLSjw4kgr40h49f5TelSY0HsNAtpdxi1XX\r\nxYfT73tvsyIhPiZB/shpFOl423aY53mMBAn5Jb/idHTodqdPeLmrWOY9pH4q\r\nZXMtaK1TiepZ2iBIh9jXSbHVfJtogitsz/LBCIjh0SjTo6uHzjgPj0ogM+GP\r\nUkA/3AmiiR1XMa4gqARPF1ZFjhqnC9EuVXRa+rUObpmPMS8gYvaISUmCi8KL\r\njJe5RxD1TzR5UWog1RLWeeScuNLOuBW7qQ3lFURQTMtscK8/jxvezlJfgQDA\r\nJ9TVNldcQrTZYA5tmBwdgFnbROT/zcSRY8o=\r\n=Us8q\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.0.2_1676038783736_0.5957553649203482"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.0.3-beta.1":{"name":"vendure-plugin-stripe-subscription","version":"5.0.3-beta.1","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and downpayment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential downpayment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have downpayments, because it's already one big\ndownpayment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined downpayments\n\nA customer can also choose to pay a higher downpayment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na downpayment of $270,- during checkout to lower to monthly price. The $270 downpayment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the downpayment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDownpayments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { downpayment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDownpayments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic downpayment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpaymentWithTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpaymentWithTax\n                totalProratedAmountWithTax\n                proratedDays\n                dayRateWithTax\n                recurringPriceWithTax\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpaymentWithTax\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@5.0.3-beta.1","dist":{"shasum":"217403307b541f214d5dee1ea773627d4665f5a2","integrity":"sha512-4G0QwU+qK+eQUF/4nHPUSWeYIVcHaIdbe42uc71OfZ4jrwMOQVwK5fWdAoun9ewL5+evCnGMbWZlxTTqlDIONg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.0.3-beta.1.tgz","fileCount":50,"unpackedSize":131550,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFy4Swm9/zvNUE9HskHMsRgXbKSKmJEAseJElhS5L8BLAiEAloL8ZqwP4gWeP1bmMLBMV3zlLHsgx94iOBXDjbqadEE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj67IuACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqEPg/+LVvjzokxxeBdQVW6ylYmv1HrpIVPDDzBvCXFQ8CeuJs/scsr\r\ndu14tgFM7DouXMEQXsdZoyugtl1OmiVhcogg+n4L3npG52P//XW3c0769o5z\r\nWIJs3kRinct+bvgmzVjYPZa1KJguT8SLAoRXhkJfS35eZ/pUshUUTHqwtBsW\r\n5BWytkN7ySSvMuFn6Rd3y4O1U0UBXVNRpvUJPTGlR+tdKU0yrIP2hPMBid4a\r\nJULc+lW5iHh1/w6HQ3c9Y2VgzvdpiemD/gXVIZ9G/GrGfbxvPQvlngg0z1VL\r\nv+3z3sBAv02AdImyn3SfyL+opB1VDOwDLPZm4a05pMn3UtCEJnuj3dHYqI3B\r\nLeguNABgga6WySahEMxtxhmfQx2EHer/uqQWBuauhwt7+m4SfVivigyWfDpx\r\nkpvnymNqgYvbxghvi7bJcYXZ9X8yDhbGMl6179OaeM2ynuoMiQIIccCB2CRN\r\naopv2aP6JIJXAITfsDODRwi649esL80GLC6LfrP9Z5ZLFmSlF2HAxlVktvQj\r\nZXKOcdyGJ3dDZmRy4f3yDWLBEjgBhPAP/nCKzGSMozWZ+2YwMVHd3AHGRO8S\r\ntVvH+fIEZkeoN8oilQ2x08MD0cJrthoI6jkLGjAP2GhmaPE02bCPCmS/f1qr\r\n4UWRz6+eTVXcus6zc2kTxy/tJFilfGNa5f4=\r\n=h2GY\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.0.3-beta.1_1676390957849_0.5796756569062227"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.2.0":{"name":"vendure-plugin-stripe-subscription","version":"5.2.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"84603bb05256a47f10022a8d7c318ae9c0cc29c6","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.2.0","_nodeVersion":"16.13.0","_npmVersion":"lerna/6.0.3/node@v16.13.0+x64 (linux)","dist":{"integrity":"sha512-hsaVDnun8nNRLBOOClgvJROhLnPSvOdp4E+cciOt8d3rl0vmO+nBXVpYoiWMfzKjOOn9WnATDiZK+ktvjkqyow==","shasum":"3418d387d1177b7e5f85e60547da55037dadd6c7","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.2.0.tgz","fileCount":42,"unpackedSize":135965,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQChJmluf/tK27TaFpJLWqrt221ak4lou4rMJbWOjyTZRgIhAPUXnhCUprbp2nzPVLCX8RoJQDAopJKpPxf6eoDQgpNQ"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj80zmACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqwxhAAgqaKkCieztElhi1mdP6EvBs9SZCr2wjtvK2TsnheNmE9kZ4N\r\nbcfGguQjPW7trX5S4z8OlesPgTMTqvA8Kg5DQGlnio/vQ/v0AEVZM7gYZEJX\r\nd5XXApC235UhG5gGZYbqiHfJUYRHlXTchhPs+VfiPt7JtWl6t8W8/fxTwdUm\r\n9D/bmgpX+gJfm2Qslb1iZ6BIDFgCAkLXN9ZJI0mst8l9hZGQ9tDogJ4V/ns2\r\nF9nsCH0wnag8X8gNLa3wERk1zBOw8Ydh4dyBdMlHScI8/s/dGNN4kVta3fja\r\nP2xYAp1d5L67EKqezLFi7g3gATtIgeRGfRhyFGy/Y1j6rzvy95D6BoCj8W3c\r\ntmYdvZi0o939ltrqkBFEO8mQRvKPhpkik7Y3sq4w1ySILDPTImaUhW0n03/x\r\nvpnEfTlxYhOUN/AStOn2vVPWmGSXMqJIEHr3hTVYjGZDMmtPap0iZqwhOVjb\r\noqv54yK8qhjNF/lq2aB5gBrtKoSPhBT3LztptlL7UlbYHSIeez7/tR0i8+bQ\r\n4z6yYKKth1eYsvssaFgtPgYWtHJlf/Evs7C3v/cicJaD8TfHuAcx3I9VTcyX\r\niGkryWC2ErzAn3xILn5nBsOZ9g3inxt7aHmMvJl2EA9vV/vD5VcsEvRJrCMh\r\n6PS1LtBOYoxWjUKSLgtFzulc3+O2oFVPteU=\r\n=z/S0\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.2.0_1676889318387_0.03252753161046873"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.2.3":{"name":"vendure-plugin-stripe-subscription","version":"5.2.3","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"f45644e3f39bd7eef948e930b91dde5f823b703a","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.2.3","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.0.3/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-D5mkbqrYD6+EPss6lDwaStg1wyCNlpSHvCQB6SBZNjSB/Y5+aNFNYg88zTpfafoJsxN+tPapmYfD6rBPXEUkiQ==","shasum":"b898b7547f45b1df415a267fd64d55054570a780","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.2.3.tgz","fileCount":42,"unpackedSize":136139,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHaC3rbklCfz6mnMYFI4wfu7hOSvUzZZP0wjV7P9BOg2AiEA6lAVWVB02UzJUF25oEl7Tt6Hag0T8vWZApV21eExxDQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkEJkBACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqAxBAAkcX+NqDLc//f/+tK2SUFZZe3RQ60mn0DfDTyjcczP746faz9\r\nM4uaih+67jH3m8gG+sipjRmUvR/SKhGoyam20W+K8jTcHGQSfFGXxfWwzKFQ\r\ngsOYNTw8w7DkZGynndF4/Y7Hx6JHEZpDT/b4XsFqDNV0jbDuZNPYRb2tLj5I\r\nXK9RwiJFGOYv7eH3UjDgrJQ4vwCiBPUr4ImjaH0EAp5iUngPb3L1tV7HXtOt\r\nGR7bV9+qY3qPo6XNlws4/Lhm6U1O/JYg1nkOzI5Yn0BbyOvtu4TyXb2nobdb\r\nJf2wVKtB+k0HXYdKiP+tKStuvhbFI/f9tdmpSE6D8UMt36n0KcNPnWd6pDDR\r\nrMuJmsxJy4Uuo+ftIKUE8fz6RTquXHM9h2pnnmJOeRcF/zVWpu2hosB0MgQC\r\nt0K3Rab3eVv7S+EDfAVybGbG5axzxnP+qLZBs0waIozzBUWBn25kKvOVd0Hb\r\nhlVGKSbGNyp6PggdVZC/LbEn8v5WvgXbDy2i1RKloNok+9yqX9qimJyDq+Ku\r\nYbvTxMZIxK583OSCND4czvq/236nM+QRyExUWv3lDHtSf5TxTp5wyn5+TDZ1\r\nI2nEVXAVhjBgd5dIHQ5P4x/bQXPzhh2w8z4xM5AucRkQtCaUByEmRvtDGnNX\r\nJ5eMDZMrG1DeQIQi/JzDoSBozi3XroAbh6I=\r\n=E4vM\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.2.3_1678809344888_0.1995949086368396"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.3.0":{"name":"vendure-plugin-stripe-subscription","version":"5.3.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.2","@vendure/core":"1.9.2","@vendure/testing":"1.9.2","@vendure/ui-devkit":"1.9.2","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"8422a8b3b9a3d41347c43b34ceb908f8c9d91355","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.3.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.0.3/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-nCkHEaDZt2MWAYEhtTb4mh3YBdXv2CmzmwgcUrnBXEtMSxB7y6WD1XEYSta9LJPZ82ZgWzc3oK+xaaJ9bJQlEA==","shasum":"67e19986e6043837775ae612559f4c0ec31f7a28","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.3.0.tgz","fileCount":44,"unpackedSize":139415,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIE5LMQ+JXiQRxSc45Lau952uh4LwpRL95oK9+CUkEujLAiEAz02HyMTiq0lClc+QnhIqfhNzjf0/82Gj8V8cu0DxJEI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkHY+JACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrWNhAApPUJAZlsRqDcLJywGfTEdgdVbJMpbk06vyGb2/0vGwIhdk4o\r\n9c1HEA59I7XQtKS5o6mjhNmamx1HJQbyGqzHrj7heS6w4/WXNH9s9ZA2lH6v\r\nRsAHS4jxF2VgEscS4CD0ZJeKYnyQm34x/+r70JN+OC2sCEJkE1+uUZ/UF3JZ\r\nD2eODlPgV0eaFEGcDw8MzmpaesRLmxzd7U0IlrTbZ6V8gm0pqDzR++Ea/KyK\r\nG8U4VWUKQO9bcCVbj4YPy2SvfAYW3nFV7RrR0G7Dwc2ZwiT/pTv5IMSEaA5X\r\ncdtqA26KnY+OQnJomU38OTPR+gt0gUCHLlN9YpvEKmItJo2DW1OZETqNN+Jp\r\nHTSl35qNhz79ngkz1ehMa+yd9ERrDGDu3shj3YuhJzssOirJe60ySsVS9YKE\r\nfGpFLrtNRFhofEOpEvhM/OY6dJzAh79tMQ6J88Uru8V6oPgoeGN7wbgcij0D\r\nyoZXfjGwRMXzKZ1Qq1MuJlag0xeo4Pghdz80cdG8NRxZLn//cq7xu8bw/kLO\r\n7qXy9bXpL4cy2Epqck4gh3YDOQqyqfE7fc5WOKDKSzcbkdGsVb6Ig1DxPR5i\r\nu07jtqosh6SZ+bzrNaoMrKIwKaEF2h0NVoNGslDBFMWlObATG5CiD7gHoIpP\r\ngCWoQIIfc7ragcovRPN53Jvv8BxoVPn5p48=\r\n=dNCr\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.3.0_1679658889249_0.47530670045743584"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.4.0":{"name":"vendure-plugin-stripe-subscription","version":"5.4.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"d6b68bca6c39d81ddee78efc9e5523060ba12e0e","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.4.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.0.3/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-iJ5FPdE7Y0Hr94DlIhGROvqeze484ekzAoekkU/hOlox2FwnYGZvntOky6Eddy0h6TPF5+/64hQ+53ZXFnRuLg==","shasum":"4f48c9cf46a349f487dfe9e3af98f717e28e00db","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.4.0.tgz","fileCount":44,"unpackedSize":139415,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDUIEo1gcBEsnzRqdxfF3XbTSQ5iU0dp2jQkmLRAYRrOwIhANGtia7M0SzF5ShdtyiCAiWMi6FgtSxNDnLL9LBlCuiv"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkHb7IACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpPkw/9H6NklFSYhyLwWS5unHsXytOH11bMMLEUeyW9t7IfHwuxZWur\r\nAXFWCF3Oo4JRB3RcJqVIsDqJyCWYKzLWmTx4nfuo1Q1nvacDVWB4ED1wZYtC\r\nRmn+XwQ5sT4FMu+/KAg53pBdkBYSWc3VKpIvJwInWAfgeuxwJmKd0fn167gs\r\nAHRmVV/e/4kMxb64Yw2C5sglNBLXRsdVssJaiOs/tSgelcuulxYykP6T8a++\r\n8ubYQ7sThhUcAkwRknjzT4qEbzAgh2af/4buquS753X0k76E+4HSOm3Qex+c\r\nAVh0DwA4iOSRZ9yAO8igxDX0pzU5QGWTaDzM04TIB70d1zIXCITuH1UWnTbr\r\nItEOimhYwPoswDmJjiif+Z+7TppjEaqNcIIoslZRddLO1vN+XuAV6aqydr31\r\nxjPhqDx/X8ovoGGGmtXEHq+evG6Ep2ngKwGlIdpJhGBx3SaUc1wePdsKoYb5\r\nkb1XZ8gf2qFdYg0GohyR6laRiKLf3GljJo8sRoY6tUkHYihBv0xFWcma4IlQ\r\nTCdbJmektjkvUomsvwQHFG7w35iiJGiIt5prf3vXURS9xuCwn3FdPSDLHm0g\r\nWzUAht7OSJgzZATGE3mOCwLSg2nGAEWWzqDgxTs6hUyZuru0E2LjnY80BWVK\r\n1WrxrLzTei79pMm3w2HJOdbwIPAR6acCWgs=\r\n=1rBn\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.4.0_1679670984624_0.8048003031861772"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.5.0":{"name":"vendure-plugin-stripe-subscription","version":"5.5.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"0b07216a3b6b0601b7dfb2c8e19a845686ae3ed5","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.5.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-b8HRHwKKqbb7QJbEqFz27Eer12h2vibZz9vZ9/5SIBwiX8aSz4mVKVi8Vqb3gSAzX9yxRLKuhEdpFOOzkoPTyA==","shasum":"a4bc558c9eb435775ca2ec4aa3afc73b91e1cde9","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.5.0.tgz","fileCount":44,"unpackedSize":139415,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCq9ZUir8/9vcDvZFcfS6hiWWr+VO1AdFH7JDUqqNEfTgIhANbIFH+oc6kIFSExEPVrcAFYEPV/W4Loqed/6LHFCw/6"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkJvEWACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoZSg/6ApJCT7FCxwHLqd5f+rJS9rWHaHtNOP+2LpmViQhFL4E8MPAe\r\n3YSicuNcHShs21GLqE40RRz7fBA3VhmpoI3FH0f+6iAU7zITpB+eJg+9YVx1\r\nUgxowMu4sOK0RQSNsbnWzJkou3yrZPtc4gnmZ+l0Fi9hyrhFiY51SCf9X685\r\n7c/krXOvVys+0hTfBwgatY8nmiZFW+yLPO9lJn1Vr+zMXffPUFeVj5iPql3Z\r\nV8PVTTuYMLJ9Zxch3oGE1kU54nTb+umRphQ2gBLjQfEB4Chqmjs0OJ3jtnDn\r\n6afzmmKul9DzsRLhXFRqNcZZSNfTmDItTP3ZYhjT0V/90stgF93iXP2xKdfs\r\njZ2fI+tThl5usRiaHAAw5Vftyt1ViB2RQKZWlHXV2X+3ZGB9CbL6ew9des4Y\r\n+AIMye1lcZX4/qGlAsVJjzQLYo8zKjcYEy+D1TZV+dIGUSw+cIHIP57O5h4J\r\nEN333c8K9btBaK9QRpY5oxRgYXL4ISNVsYbCYRJq8/8x7cuGyPEtlQmiraV3\r\nFOsfDwa5BhVyVBsdb7b8iza8rmkOjre+NLrIIoDVmDUVUUQR/lz+uBmizJBO\r\ntoWgW3vrmLlKD0lHkcWn0OEBH52Tw8vpANZsfCWKr5uRPKdcK2y6sFK+FanJ\r\nx7x7lfuRoV4gDSzbexZ1/BhugIw3kNylEXA=\r\n=NiTG\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.5.0_1680273686534_0.8594640937201592"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.5.2":{"name":"vendure-plugin-stripe-subscription","version":"5.5.2","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"cbbb6af052567e0057a3bb63dafca372ca9d5c6a","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.5.2","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-hVDrLUBgATg9LT5D5a4TFbDggYMik/bPpjc3GaHgdLADXJBs0UFgLx9WH9KE54pUsv183VtTwTkJILjaavRfnA==","shasum":"347ef7ba5a76179e160db2db8d9c8e79d5e2fe67","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.5.2.tgz","fileCount":44,"unpackedSize":139427,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEIHpuVhCbShkabRQGeINKdQJUaxLlHwN0L/OiQWY7NRAiBjP910lVmy4Q3eMJ2tmty/kKdZp+gAemHnNXbfGn6Mzw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkK9mhACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoEqRAAjEfm5a2kfZ5/2JGf6NMHINrWHaUC9V4SZAKTod9ljeetweDU\r\nYDL/ajZFtvBbgCqcsLFK53REEvO0bjBJWJ2VMSoddqfBCr9ON2Ygk/01OYR6\r\n0KXEZwRAzJx9f+vygRsqBetnYAxXNFJ5iNfPiHzqbsZewHv6dyK+p2sLtAA/\r\nt++b9jTTGuKt6ddoLlsXMWT5yjvjmeLVOmSoQwpYMZPzTaOBJMD7AwNDfNNa\r\n+VxiXlWFWFHVytq1tgfI5PbH+caBzqO5TX0FJjYIoUOT4cTGXuFprb30RfZY\r\nFafgldmMqgZf75/YUaAwOlOpYWh3kNjFfbndnks/jQK5gn3rt4BPDKpluJY4\r\nLU2wpeD16fA/0x8Y1Cg4Nx+jrpeeNkNzbs4fi72OgU8kzWUND4bkya9tcTB0\r\nD4NbIo3MWF2xYjhiI85VU5Yw68ecunvCUVYCl8Gy/ln0sQBvje+5yM1fUa1S\r\n0q6dE+r4niLJIoUsUbEfJ293I0PS4qdSPOv9Cr7pkvIanE5PVVUTNqE0j4kX\r\nn7I/aDI7CU4zG3vmdKFgjYRSI+ZUzyQIFZorLic8kP+VfAZTA1fwVvaqWgbX\r\nwwFd0n6LnYmnrd5xGaIr3DxL4on7uGmfACWsB/WG7oGP6mC7hg0p1FrYRihN\r\ntoHy9qezenEvkc+e08a0VW+t1bLEU7kDEwk=\r\n=oCZ7\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.5.2_1680595361214_0.9407721145794972"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.6.7":{"name":"vendure-plugin-stripe-subscription","version":"5.6.7","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"16fe83d655038683b2df6e11e9b7162535c4098f","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.6.7","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-gQTm6nPlng4Ayo3RP4en7ps4ySoO7S+W1yZR9rMXa0odsC9zTp8nWbkzXKjbyoRWZlB2ImhrxYq2HFK7R+0D3A==","shasum":"c363b220c743be4c0a415fa8b56a527a1e2ddc37","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.6.7.tgz","fileCount":44,"unpackedSize":139427,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDIJWvGsIuCIIIt+FOlpE4BYFo3RKTc2b+mboqymkMcOwIgSyZDXAnWLCvqbVYoUwX2C0G0ebCRyI2+zPmnzkeAisg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkOSQMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrQTQ/+Og7pTNz2wv8nMSnUTHTtdiajqK/ski7eiZjW/mG+dFiYzIQj\r\nJQpl0ynNZvwjqa0RKAjDEJCeM4BGgCsWtQEGwz72pzWaLiztyZ4zR1YssLVO\r\ne31AfNTxeKUq9cG8/hw1htWCU5uKmXosFasRQlFa5bEiaTpFLrAmCxrti2E7\r\nHHwn03GiokHidj0PqtFhBTK88pQ6/PqkcIHW7kLhNBGKx6jXmGEZkbpFxEA1\r\nGK2PB/a60dolgGt3zCgBtlBcDfyeOK5v6+VCvwM42LSPLSJpRRdCE37Y7Sv5\r\nEffhE8U98TxdnNLMnvAfzRkchoj6dSoP5F+iw0v/PZ1GoZY6lZnbmYupxa8j\r\nFgd1AUqcAiTqacw6Ycqpa8wvjAhRJ0t34VPb6+tx00vfChRae8h1m0B0OHXn\r\nMb3Xf2iAaXITHVfkt8sdUEdcb9kwQ+46priqHSNChFMVYEpmlJW0y4V4m0qQ\r\njOd9hGB2Lu7/b5I9W24rMIEzIYex458CRpa4ZoFQCX1UoqyAAheYyV7DVWWS\r\nfse8blMA6XLoHzSy+defrqm6zr+ZUMMnKn4dXXzPQsMVvKnacT1fU9FpJQcP\r\ntXcUrHRI4GcFZhFP8Q0CH2fbRcirAQyfBZD6sr+vAXL6SgAr2KN5DkSlH1bK\r\n9SYd+qZkj0uhzJt9W4ypnlWy5TushrKYrzo=\r\n=YkI3\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.6.7_1681466380329_0.13842000125549947"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.10.0":{"name":"vendure-plugin-stripe-subscription","version":"5.10.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"4d8ecfcd7dd48a91635d3b8b284ba48c1738a2a1","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.10.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-3CszDx8s5tYU3QM2UUUmVmVC6vWIM809uZDbplCGB7kFt9DfJwh5nMrNj25yjSDSVrnydB5f9Uj6+2OF4OryRQ==","shasum":"07db7c22ebb9bed9651cb76d805377ad01b1f679","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.10.0.tgz","fileCount":46,"unpackedSize":148993,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBPyZWK7qZKdGlCfK2izNyF3P0+KXqHJ4xawnHgCdHvBAiEAqGnOtnByeaSATjFfXddn23pX05mcqFa3azbUsH7CWD8="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkT3iKACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmriMQ/+LrP5TogT7Un9bH7YR1VQzSj4NqaxHFxumeP2aoSD9Z+Lxyof\r\nlam+xVusWjP/+KM4qJ8VfT/YaTOzp4Dauac3rVxHIGRAY18rShm/nKd3UfmX\r\nfFdyItTmwgiHm61045dkJta6UB80EaoUyuU8FG5Y6I5OgChp6jNBZPx/zwBn\r\nXv8r1h5NkQOUaqCAlCn22ZiZgrRyoJ156BCtQLUNELY5vK0j7ep4rZGeV2N9\r\ncDP1COHPGS7FrAFeCTAtfWYOsfKmHSt53QIdRTodSGgy78yQGztYd5/Pm/YT\r\nxJR6uVQ+gDWY3x5LmA1IGuadcEaR2zwrU6Lvp87ivP+rxriOVqJgzstDi4Tq\r\nO8rL5vxVhiKUkUctc4C5U3cpPpQwacrXpxTGx5Y0JvrOODOsfF+QbKJgnvEI\r\nZJ1iRHnKCmzqbx1drxa7myvY529PIe7BvebHZxA9itHsLmz3cqK29L/+g71H\r\nqicDpRHJCd21CCtTSa953pm3VloyagRYIseQrXhjHyVYzGBS+ieV0olQjNlW\r\nNPEE4jcJWGTCINkpnGmFVLVsTz3M/153qIrxEoXBn9ctCwahHZm/Hbrtjw+6\r\nZDAl4RVl+g6n4M+TVj3bujIR7bBfGQIpCvDU8BOjgwcMZWyd6BqCl5NeEXO0\r\na27gshLr4VnDr8O+mCQRocRDpj27p1kq3po=\r\n=upuV\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.10.0_1682929802002_0.2661607463775091"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.10.2-beta":{"name":"vendure-plugin-stripe-subscription","version":"5.10.2-beta","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","_id":"vendure-plugin-stripe-subscription@5.10.2-beta","dist":{"shasum":"558c4b37b0dc5c3e57e8cd5b88334e45c1776637","integrity":"sha512-wng0S7L3XyuYXIUgPEamynkjMThe5jkHKj9s1RW5aPyGK8+uBovNc0lY4RNnxNerS8NlHTMDZyyQyjC+OvDzmg==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.10.2-beta.tgz","fileCount":55,"unpackedSize":151916,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD/ctDqNTvDexaCwMbSGsGooxqoWd12kDbC4uxH9m/CoAIhAM5Vqh8GnK+htE+gZgq5yRY/7i3/EamzpSPsyFWbxkoF"}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.10.2-beta_1683041004783_0.43097407024055445"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"5.10.2":{"name":"vendure-plugin-stripe-subscription","version":"5.10.2","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"6523a3b56d932cbaff057200efaa5df30c99681a","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@5.10.2","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-Iehv3pNilLUiaihx2MeuONhku2cdm6TE1l/OX5KmBZ731P9jYGK86vs8x7OOadH4DfX6iXhdlAbvebN0T3FiAw==","shasum":"e5faaeed23bf4a49714bf332a64ddf70d6fc4d62","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-5.10.2.tgz","fileCount":46,"unpackedSize":158260,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCMmlBQBFpq3NeI18WeQL/0hatsqL5//BgBaklhWzU3bwIhANSDoPLeLpGnhXW2hSxGxb0LiuCJ8bNmWpgxF4y9pITh"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkUnvRACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp/ag//Xy/HTDP2apBIrJwsu4fcuKdoACutEUkzFZTbPWQaE4GlaNVE\r\nlV3SMwePsnV6BgxK3lQCD8YzWEuaWu9LbnBVb1uBS7w+LETVdvTewRj3+6WM\r\nbE38kHtQHPgTxdSizrtOrY3DiaILUSA1ge4dhaa9pJirhm1mK+JYHbwEKkiB\r\ntIGxQ9EfUuncmQkirDr4nXNBRTkCk+AtCWMuBbwzZdUPMx3p0v/LKP34Si+W\r\ncNla1Vyqer35+uGGGESdaYSfWOvS17LWzkhQBXZcB4Z0Aaw29Y5yZ2XeCTHm\r\n1OAnH0MVEPqha8GHw8MxPyLRiGEUeANzyhNvtRHpRCBZ64wyZtATnIB8D75P\r\nmjbzgqL15pKJq4jCILIzBQXOT1K/sQUTvHKLiYmJ6DDV0n/WGIvOXU4jKYBA\r\nbQUGaOl3ZJKcfjw+WarYhCG1nhr/U5h1DhxFbujRcU/VlRwCax6OWtuqN4uQ\r\nLBUiLl754bRMPHganYUX4PRKRUQp7hSyf9QkL9o5sHpiffOH3aMpfn6mdbTu\r\nDU0A4dLHYKcE8Uq6iAy6L2BJpSwxJ+GkJzVKRioCIcnwEX+LIPaWZFRd/+8D\r\nrQG9QOGNCy17dpHSSKMvChQyuUYNh3wCBnXNcHS8+Wqn6wWErJJKCxztaipG\r\ntUUPtyy54uDqVzhgwv23D1JEnhoGonkEYlQ=\r\n=9jWw\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_5.10.2_1683127249001_0.8508589953113834"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"6.0.0":{"name":"vendure-plugin-stripe-subscription","version":"6.0.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"d10f9b0c064eafbe37c53be12acbbc68b438e4af","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@6.0.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-D8jPYtL/oeIjMdDH/kFvVjeJEcYsMXXCwp575NoueefPMe8YOhqr30e2GyQadwrdb4vWjlg5i1G0Dt0PoziZqQ==","shasum":"3a73c3db016300f913020c870649ee4d0ebeaca1","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-6.0.0.tgz","fileCount":46,"unpackedSize":158259,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHxJRLPyLCHng+Wbyhf6eOfYMu4PJrven/eGIpw+Syn0AiBldPpZurHhA0J94Mh9ZgdaDLhP8ZIVLQhEvtVAsF2idQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkVLr+ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo52xAAitXJCNiSGS2qZTCJ24jkl5pummYwVJ1ltD0QzV1M8xfSFeZM\r\n5old8/aAzUEzBPw1U6N2qAFpsaKnYiou0i55Ds2nby9oTipr2stmx64BGg4D\r\nmjZvraBnABRbh/rNl4dPIvw00w5uSD1/H6raNUVrmVCWYMdrYHCEfsdezL5H\r\nPaJNczqypWMadwav5wEO39T7+LYZhE4cnFoRIhW8JRlL2dR7ymWFUgbc8UP2\r\n9m494ciSZVwh2tXUtvTHb65IB83rwTTArf0+zrY/8bVbLej6XPmTs+CweOqd\r\ns2xK4ogWWnlptfhpMd6NKyV46Zo3JStJCorU2QNfEloMSVwpm2jBFKPvgbPB\r\nnIFST6OIK5iARwqm74fRG8yaYRtTO4R2ZqWlyfJGUPtAEmG9cySRACl06MUI\r\nKNveYXvvdeFkDgY/ytpulZ6dCZk2bk+1rxYAo7SeAMWUD5P+5MhhX+wdeS/8\r\nZro9aMPL4aZ05QwK9dInIOU2NAe141HgPzSAQotUxzxGpYpBS6HvQYaPEWPd\r\naSN+UXBjwR5FDaB+FCAJl3ZbAKwnIMnZevU5SfvuCkWyHZgsiLYkm8leKZnB\r\nU39bTyWGDhYFMBFwELDr5hu3VeGxQZTxB+N0JNp6B/VrzRWUe9iDrWiB2PFJ\r\nxuoDalHH1vzSVwpZgubD49EW3cTdPgL7i2o=\r\n=u7UX\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_6.0.0_1683274493883_0.8225291758917281"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.0":{"name":"vendure-plugin-stripe-subscription","version":"7.0.0","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"1c4e56271c3ae2a5da5d85f74c66a587b45f8b23","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@7.0.0","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-CMLPZs4LoVwphfc9bfqP2TYhZTZTyN1QcV2+4BWmVjmP0R3ykSh0KoYhbAEX7WUlpHk51uJSVL4wePEC5tTxqA==","shasum":"f9d0029b1389a4cbcf142bffd830cd1426e24196","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.0.tgz","fileCount":46,"unpackedSize":159388,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA0csIGCG/F6BlZqiFCbLnXaYce5JBiQcHRt8KHTzYtiAiEAgOPQTgjZpxxyvbJ3fvakZ9U1TtuFuD5E0HUnZY06F04="}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.0_1683644034130_0.7859129024780804"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.1":{"name":"vendure-plugin-stripe-subscription","version":"7.0.1","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"42ad9288a1afe37540e229445839460845d2ae44","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@7.0.1","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-aEX7GvlBwSDjMHFIpWJxAUiY6wJh9DR+3VKTxSenhYOmeQjIG4C62y/GTNhjZQWoiUkVC4wV9AMEl0TSobWp8w==","shasum":"14a71ad0908b40bdd7b1bd72c79c27723fb142e6","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.1.tgz","fileCount":46,"unpackedSize":159390,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIACXfs9QwdyES0eaf314lLReYmoR80VFbCeIpe8tMOANAiAODV4ACamdosLkkYpUYhPHql81+Wfpasp4BxlGV6ZEaQ=="}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.1_1683700860812_0.6611182264118505"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"6.0.1":{"name":"vendure-plugin-stripe-subscription","version":"6.0.1","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and down payment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential down payment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n## Order with a total of €0\n\nWith subscriptions, it can be that your order totals to €0, because, for example, you start charging your customer starting next month.\nIn case of an order being €0, a verification fee of €1 is added, because payment_intents with €0 are not allowed by Stripe.\n\n## Canceling subscriptions\n\nYou can cancel a subscription by canceling the corresponding order line of an order. The subscription will be canceled before the next billing cycle using Stripe's `cancel_at_period_end` parameter.\n\n## Refunding subscriptions\n\nOnly initial payments of subscriptions can be refunded. Any future payments should be refunded via the Stripe dashboard.\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Payment eligibility checker\n\nYou can use the payment eligibility checker `has-stripe-subscription-products-checker` if you want customers that don't have subscription products in their order to use a different payment method. The `has-stripe-subscription-products-checker` makes your payment method not eligible if it does not contain any subscription products.\n\nThe checker is added automatically, you can just select it via the Admin UI when creating or updating a payment method.\n\n## Down payments\n\nYou can define down payments to a schedule, to have a customer pay a certain amount up front. The paid amount is then deducted from the recurring charges.\n\nExample:\nWe have a schedule + variant where the customer normally pays $90 a month for 6 months. We set a down payment of $180, so the customer pays $180 during checkout.\nThe customer will now be billed $60 a month, because he already paid $180 up front: $180 / 6 months = $30, so we deduct the $30 from every month.\n\nA down payment is created as separate subscription in Stripe. In the example above, a subscription will be created that charges the customer $180 every 6 months,\nbecause the down payment needs to be paid again after renewal\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have down payments, because it's already one big\ndown payment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined down payments\n\nA customer can also choose to pay a higher down payment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na down payment of $270,- during checkout to lower to monthly price. The $270 down payment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the down payment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDown payments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { down payment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDown payments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic down payment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    totalProratedAmount\n    proratedDays\n    recurringPriceWithTax\n    originalRecurringPriceWithTax\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpaymentWithTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpaymentWithTax\n                totalProratedAmountWithTax\n                proratedDays\n                dayRateWithTax\n                recurringPriceWithTax\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpaymentWithTax\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n### Discount subscription payments\n\nExample of a discount on subscription payments:\n\n- We have a subscription that will cost $30 a month, but has the promotion `Discount future subscription payments by 10%` applied\n- The actual monthly price of the subscription will be $27, forever.\n\nThere are some built in discounts that work on future payments of a subscription. You can select the under Promotion Actions in the Admin UI.\n\n`StripeSubscriptionPricing.originalRecurringPriceWithTax` will have the non-discounted subscription price, while `StripeSubscriptionPricing.recurringPriceWithTax` will have the final discounted price.\n\n### Custom future payments promotions\n\nYou can implement your own custom discounts that will apply to future payments. These promotions **do not** affect the actual order price, only future payments (the actual subscription price)!\n\nThe `SubscriptionPromotionAction` will discount all subscriptions in an order.\n\n```ts\n// Example fixed discount promotion\nimport { SubscriptionPromotionAction } from 'vendure-plugin-stripe-subscription';\n\n/**\n * Discount all subscription payments by a percentage.\n */\nexport const discountAllSubscriptionsByPercentage =\n  new SubscriptionPromotionAction({\n    code: 'discount_all_subscription_payments_example',\n    description: [\n      {\n        languageCode: LanguageCode.en,\n        value: 'Discount future subscription payments by { discount } %',\n      },\n    ],\n    args: {\n      discount: {\n        type: 'int',\n        ui: {\n          component: 'number-form-input',\n          suffix: '%',\n        },\n      },\n    },\n    async executeOnSubscription(\n      ctx,\n      currentSubscriptionPrice,\n      orderLine,\n      args\n    ) {\n      const discount = currentSubscriptionPrice * (args.discount / 100);\n      return discount;\n    },\n  });\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@6.0.1","dist":{"shasum":"72350eaa373dcc40e99a9b96ebbcfc246374a75b","integrity":"sha512-Er9mmpeZc5Qi/S8hWWQlYLooOUFRx/te0LYdnZHDlnVN90tsRfdCNSRwTyhWLFXfoISXB/L5l7xv41FtQr4Cyw==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-6.0.1.tgz","fileCount":55,"unpackedSize":159416,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCv3+k+HiWtFmxedCDu27wj1T9oVrPSTdF01MXqcCpf9gIhAI4sghhvSswBEPk0VeL0YNug1T3zAH+/0sFzUZ9tZHlK"}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_6.0.1_1683873283140_0.774374363543548"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.2":{"name":"vendure-plugin-stripe-subscription","version":"7.0.2","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"aef19513f6ac64c7981c1d39da6159613756e31d","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@7.0.2","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-l/yQFH9KpuYzlmJeTXtjXEG5iT613KqiuZwNbL71UQBc/QgVb+Lz4NW7fbXSh1uGbeKQ9ulCc7c15/iCcgKtKw==","shasum":"87bbef0b5ed0262a296e9db91ddb434e80da0a52","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.2.tgz","fileCount":46,"unpackedSize":159478,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBmor5ZSW9woF2QustjJwSn4+lalLtYXvk/6vERwmeKrAiEA584033lJIG/WuT27FaRLVfQrhoHW4bKak0+8iIvQAwk="}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.2_1683873532021_0.9663697006489491"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.3":{"name":"vendure-plugin-stripe-subscription","version":"7.0.3","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio","repository":{"type":"git","url":"git+https://github.com/Pinelab-studio/pinelab-vendure-plugins.git"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"jest --preset=\"ts-jest\" --forceExit","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@types/jest":"^27.4.1","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"1.9.5","@vendure/core":"1.9.5","@vendure/testing":"1.9.5","@vendure/ui-devkit":"1.9.5","copyfiles":"^2.4.1","jest":"^27.5.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-jest":"^27.1.3","ts-node":"^10.7.0","typescript":"4.3.5"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"e983914a9010dae65355ef93f6911c4049f27ade","bugs":{"url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins/issues"},"_id":"vendure-plugin-stripe-subscription@7.0.3","_nodeVersion":"16.19.1","_npmVersion":"lerna/6.5.1/node@v16.19.1+x64 (linux)","dist":{"integrity":"sha512-M7CUHI0l//wmzWNQS8qkIp8RWHuIHLk7VeYJmFI0FjKhY+6aBYr/Y9AR4OG/aaV6E9ohfUFJikdZL4DirPJATg==","shasum":"8c8fd68c2f9f8bece4ad39efcb1227a2b3292706","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.3.tgz","fileCount":46,"unpackedSize":159490,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDrFBYmjXyckNW1WDY/Yc2aC88vqeqGnUdR+nW1YgxTKwIhANDREWTgPjXOTn8UWj/vEMBbE+VVNARAaAWQyoOqPt0A"}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.3_1684159331238_0.05721010693936268"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.0-v2.5":{"name":"vendure-plugin-stripe-subscription","version":"7.0.0-v2.5","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"vitest run","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@swc/core":"^1.3.59","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-beta.2","@vendure/core":"2.0.0-beta.2","@vendure/testing":"2.0.0-beta.2","@vendure/ui-devkit":"2.0.0-beta.2","copyfiles":"^2.4.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-node":"^10.9.1","typescript":"4.9.5","unplugin-swc":"^1.3.2","vitest":"^0.30.1"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and down payment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential down payment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n## Order with a total of €0\n\nWith subscriptions, it can be that your order totals to €0, because, for example, you start charging your customer starting next month.\nIn case of an order being €0, a verification fee of €1 is added, because payment_intents with €0 are not allowed by Stripe.\n\n## Canceling subscriptions\n\nYou can cancel a subscription by canceling the corresponding order line of an order. The subscription will be canceled before the next billing cycle using Stripe's `cancel_at_period_end` parameter.\n\n## Refunding subscriptions\n\nOnly initial payments of subscriptions can be refunded. Any future payments should be refunded via the Stripe dashboard.\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Payment eligibility checker\n\nYou can use the payment eligibility checker `has-stripe-subscription-products-checker` if you want customers that don't have subscription products in their order to use a different payment method. The `has-stripe-subscription-products-checker` makes your payment method not eligible if it does not contain any subscription products.\n\nThe checker is added automatically, you can just select it via the Admin UI when creating or updating a payment method.\n\n## Down payments\n\nYou can define down payments to a schedule, to have a customer pay a certain amount up front. The paid amount is then deducted from the recurring charges.\n\nExample:\nWe have a schedule + variant where the customer normally pays $90 a month for 6 months. We set a down payment of $180, so the customer pays $180 during checkout.\nThe customer will now be billed $60 a month, because he already paid $180 up front: $180 / 6 months = $30, so we deduct the $30 from every month.\n\nA down payment is created as separate subscription in Stripe. In the example above, a subscription will be created that charges the customer $180 every 6 months,\nbecause the down payment needs to be paid again after renewal\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have down payments, because it's already one big\ndown payment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined down payments\n\nA customer can also choose to pay a higher down payment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na down payment of $270,- during checkout to lower to monthly price. The $270 down payment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the down payment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDown payments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { down payment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDown payments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic down payment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    pricesIncludeTax\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    originalRecurringPrice\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpayment\n      pricesIncludeTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpayment\n                totalProratedAmount\n                proratedDays\n                dayRate\n                recurringPrice\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpayment\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n### Discount subscription payments\n\nExample of a discount on subscription payments:\n\n- We have a subscription that will cost $30 a month, but has the promotion `Discount future subscription payments by 10%` applied\n- The actual monthly price of the subscription will be $27, forever.\n\nThere are some built in discounts that work on future payments of a subscription. You can select the under Promotion Actions in the Admin UI.\n\n`StripeSubscriptionPricing.originalrecurringPrice` will have the non-discounted subscription price, while `StripeSubscriptionPricing.recurringPrice` will have the final discounted price.\n\n### Custom future payments promotions\n\nYou can implement your own custom discounts that will apply to future payments. These promotions **do not** affect the actual order price, only future payments (the actual subscription price)!\n\nThe `SubscriptionPromotionAction` will discount all subscriptions in an order.\n\n```ts\n// Example fixed discount promotion\nimport { SubscriptionPromotionAction } from 'vendure-plugin-stripe-subscription';\n\n/**\n * Discount all subscription payments by a percentage.\n */\nexport const discountAllSubscriptionsByPercentage =\n  new SubscriptionPromotionAction({\n    code: 'discount_all_subscription_payments_example',\n    description: [\n      {\n        languageCode: LanguageCode.en,\n        value: 'Discount future subscription payments by { discount } %',\n      },\n    ],\n    args: {\n      discount: {\n        type: 'int',\n        ui: {\n          component: 'number-form-input',\n          suffix: '%',\n        },\n      },\n    },\n    async executeOnSubscription(\n      ctx,\n      currentSubscriptionPrice,\n      orderLine,\n      args\n    ) {\n      const discount = currentSubscriptionPrice * (args.discount / 100);\n      return discount;\n    },\n  });\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@7.0.0-v2.5","dist":{"shasum":"981521ff493f83d9c18092db08039bada7074dab","integrity":"sha512-9qegjUfLiNjwh8QS8Iwg25GgHaSMo3m48CzPRjtVwoV3yKdtNu8TirIgqSOjIleSpbwsab3ZZ6FU6YduVHdq8w==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.0-v2.5.tgz","fileCount":55,"unpackedSize":159500,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCIH2j0xSnQ6aGlBHaSelZaskQGjWs0dqIJHPFzf4ZnFQIhALHC3sxh0lXJf38lB3gf0eFlQ2PxvFXQSsBWlhK7nOlc"}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.0-v2.5_1686318817223_0.7194877553632484"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.0-beta.v2.6":{"name":"vendure-plugin-stripe-subscription","version":"7.0.0-beta.v2.6","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"vitest run","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@swc/core":"^1.3.59","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0-beta.2","@vendure/core":"2.0.0-beta.2","@vendure/testing":"2.0.0-beta.2","@vendure/ui-devkit":"2.0.0-beta.2","copyfiles":"^2.4.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-node":"^10.9.1","typescript":"4.9.5","unplugin-swc":"^1.3.2","vitest":"^0.30.1"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and down payment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential down payment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n## Order with a total of €0\n\nWith subscriptions, it can be that your order totals to €0, because, for example, you start charging your customer starting next month.\nIn case of an order being €0, a verification fee of €1 is added, because payment_intents with €0 are not allowed by Stripe.\n\n## Canceling subscriptions\n\nYou can cancel a subscription by canceling the corresponding order line of an order. The subscription will be canceled before the next billing cycle using Stripe's `cancel_at_period_end` parameter.\n\n## Refunding subscriptions\n\nOnly initial payments of subscriptions can be refunded. Any future payments should be refunded via the Stripe dashboard.\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Payment eligibility checker\n\nYou can use the payment eligibility checker `has-stripe-subscription-products-checker` if you want customers that don't have subscription products in their order to use a different payment method. The `has-stripe-subscription-products-checker` makes your payment method not eligible if it does not contain any subscription products.\n\nThe checker is added automatically, you can just select it via the Admin UI when creating or updating a payment method.\n\n## Down payments\n\nYou can define down payments to a schedule, to have a customer pay a certain amount up front. The paid amount is then deducted from the recurring charges.\n\nExample:\nWe have a schedule + variant where the customer normally pays $90 a month for 6 months. We set a down payment of $180, so the customer pays $180 during checkout.\nThe customer will now be billed $60 a month, because he already paid $180 up front: $180 / 6 months = $30, so we deduct the $30 from every month.\n\nA down payment is created as separate subscription in Stripe. In the example above, a subscription will be created that charges the customer $180 every 6 months,\nbecause the down payment needs to be paid again after renewal\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have down payments, because it's already one big\ndown payment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined down payments\n\nA customer can also choose to pay a higher down payment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na down payment of $270,- during checkout to lower to monthly price. The $270 down payment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the down payment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDown payments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { down payment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDown payments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic down payment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    pricesIncludeTax\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    originalRecurringPrice\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpayment\n      pricesIncludeTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpayment\n                totalProratedAmount\n                proratedDays\n                dayRate\n                recurringPrice\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpayment\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n### Discount subscription payments\n\nExample of a discount on subscription payments:\n\n- We have a subscription that will cost $30 a month, but has the promotion `Discount future subscription payments by 10%` applied\n- The actual monthly price of the subscription will be $27, forever.\n\nThere are some built in discounts that work on future payments of a subscription. You can select the under Promotion Actions in the Admin UI.\n\n`StripeSubscriptionPricing.originalrecurringPrice` will have the non-discounted subscription price, while `StripeSubscriptionPricing.recurringPrice` will have the final discounted price.\n\n### Custom future payments promotions\n\nYou can implement your own custom discounts that will apply to future payments. These promotions **do not** affect the actual order price, only future payments (the actual subscription price)!\n\nThe `SubscriptionPromotionAction` will discount all subscriptions in an order.\n\n```ts\n// Example fixed discount promotion\nimport { SubscriptionPromotionAction } from 'vendure-plugin-stripe-subscription';\n\n/**\n * Discount all subscription payments by a percentage.\n */\nexport const discountAllSubscriptionsByPercentage =\n  new SubscriptionPromotionAction({\n    code: 'discount_all_subscription_payments_example',\n    description: [\n      {\n        languageCode: LanguageCode.en,\n        value: 'Discount future subscription payments by { discount } %',\n      },\n    ],\n    args: {\n      discount: {\n        type: 'int',\n        ui: {\n          component: 'number-form-input',\n          suffix: '%',\n        },\n      },\n    },\n    async executeOnSubscription(\n      ctx,\n      currentSubscriptionPrice,\n      orderLine,\n      args\n    ) {\n      const discount = currentSubscriptionPrice * (args.discount / 100);\n      return discount;\n    },\n  });\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@7.0.0-beta.v2.6","dist":{"shasum":"a0d42e8950559097d56324ae63666d363d99ff7c","integrity":"sha512-7SxbEaYhkOUxbjeHOE3My4XXYzD77rrLJ186pQgtBbybq3XVRcoV6axHH5kddoiYNjOjpoY2CZMusTLglCrR5Q==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.0-beta.v2.6.tgz","fileCount":55,"unpackedSize":158373,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCskmvAu4jJ852i0OUFsy3gFZJ1NZRyLx40wPoWk6cTKQIhAPgbUdG0Oa3MtEMAAfajDzmb5qKDsJUCbuzD5Y7Mxady"}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.0-beta.v2.6_1686319022038_0.4270122689049016"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.0-beta.v2.7":{"name":"vendure-plugin-stripe-subscription","version":"7.0.0-beta.v2.7","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"vitest run","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@swc/core":"^1.3.59","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0","@vendure/core":"2.0.0","@vendure/testing":"2.0.0","@vendure/ui-devkit":"2.0.0","copyfiles":"^2.4.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-node":"^10.9.1","typescript":"4.9.5","unplugin-swc":"^1.3.2","vitest":"^0.30.1"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","readmeFilename":"README.md","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and down payment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential down payment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n## Order with a total of €0\n\nWith subscriptions, it can be that your order totals to €0, because, for example, you start charging your customer starting next month.\nIn case of an order being €0, a verification fee of €1 is added, because payment_intents with €0 are not allowed by Stripe.\n\n## Canceling subscriptions\n\nYou can cancel a subscription by canceling the corresponding order line of an order. The subscription will be canceled before the next billing cycle using Stripe's `cancel_at_period_end` parameter.\n\n## Refunding subscriptions\n\nOnly initial payments of subscriptions can be refunded. Any future payments should be refunded via the Stripe dashboard.\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Payment eligibility checker\n\nYou can use the payment eligibility checker `has-stripe-subscription-products-checker` if you want customers that don't have subscription products in their order to use a different payment method. The `has-stripe-subscription-products-checker` makes your payment method not eligible if it does not contain any subscription products.\n\nThe checker is added automatically, you can just select it via the Admin UI when creating or updating a payment method.\n\n## Down payments\n\nYou can define down payments to a schedule, to have a customer pay a certain amount up front. The paid amount is then deducted from the recurring charges.\n\nExample:\nWe have a schedule + variant where the customer normally pays $90 a month for 6 months. We set a down payment of $180, so the customer pays $180 during checkout.\nThe customer will now be billed $60 a month, because he already paid $180 up front: $180 / 6 months = $30, so we deduct the $30 from every month.\n\nA down payment is created as separate subscription in Stripe. In the example above, a subscription will be created that charges the customer $180 every 6 months,\nbecause the down payment needs to be paid again after renewal\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have down payments, because it's already one big\ndown payment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined down payments\n\nA customer can also choose to pay a higher down payment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na down payment of $270,- during checkout to lower to monthly price. The $270 down payment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the down payment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDown payments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { down payment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDown payments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic down payment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    pricesIncludeTax\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    originalRecurringPrice\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpayment\n      pricesIncludeTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpayment\n                totalProratedAmount\n                proratedDays\n                dayRate\n                recurringPrice\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpayment\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n### Discount subscription payments\n\nExample of a discount on subscription payments:\n\n- We have a subscription that will cost $30 a month, but has the promotion `Discount future subscription payments by 10%` applied\n- The actual monthly price of the subscription will be $27, forever.\n\nThere are some built in discounts that work on future payments of a subscription. You can select the under Promotion Actions in the Admin UI.\n\n`StripeSubscriptionPricing.originalrecurringPrice` will have the non-discounted subscription price, while `StripeSubscriptionPricing.recurringPrice` will have the final discounted price.\n\n### Custom future payments promotions\n\nYou can implement your own custom discounts that will apply to future payments. These promotions **do not** affect the actual order price, only future payments (the actual subscription price)!\n\nThe `SubscriptionPromotionAction` will discount all subscriptions in an order.\n\n```ts\n// Example fixed discount promotion\nimport { SubscriptionPromotionAction } from 'vendure-plugin-stripe-subscription';\n\n/**\n * Discount all subscription payments by a percentage.\n */\nexport const discountAllSubscriptionsByPercentage =\n  new SubscriptionPromotionAction({\n    code: 'discount_all_subscription_payments_example',\n    description: [\n      {\n        languageCode: LanguageCode.en,\n        value: 'Discount future subscription payments by { discount } %',\n      },\n    ],\n    args: {\n      discount: {\n        type: 'int',\n        ui: {\n          component: 'number-form-input',\n          suffix: '%',\n        },\n      },\n    },\n    async executeOnSubscription(\n      ctx,\n      currentSubscriptionPrice,\n      orderLine,\n      args\n    ) {\n      const discount = currentSubscriptionPrice * (args.discount / 100);\n      return discount;\n    },\n  });\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","_id":"vendure-plugin-stripe-subscription@7.0.0-beta.v2.7","dist":{"shasum":"73ec3053386ed6ff2fff7f1a56327053bde899e5","integrity":"sha512-Y70eT3vhEkyEBouXF94pelOL8EzJ3UmK5Be0+oGRlT6ChM9MHQ9hE4HjkVJQx4Fy+do49eXxltQ+cSCUa/G1mQ==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.0-beta.v2.7.tgz","fileCount":3,"unpackedSize":15238,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEZlflSEqe7YiCXb0kx5JObBFLnEzcxJRhef676qdEyNAiEA/C67l51v+6ZXqRwE4G4OGLb2HTm5G+FNXKC7EP/4xbk="}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.0-beta.v2.7_1686560071525_0.25075585802887734"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"},"7.0.4":{"name":"vendure-plugin-stripe-subscription","version":"7.0.4","description":"Vendure plugin for selling subscriptions via Stripe","author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"license":"MIT","private":false,"main":"dist/vendure-plugin-stripe-subscription/src/index.js","types":"dist/vendure-plugin-stripe-subscription/src/index.d.ts","scripts":{"build":"rimraf dist && yarn generate && tsc && copyfiles -u 1 'src/ui/**/*' dist/vendure-plugin-stripe-subscription/src/","test":"vitest run","start":"COMPILE_ADMIN=true yarn ts-node test/dev-server.ts","start:no-admin":"yarn ts-node test/dev-server.ts","generate":"graphql-codegen"},"devDependencies":{"@graphql-codegen/cli":"^2.4.0","@graphql-codegen/typescript":"^2.4.8","@graphql-codegen/typescript-operations":"^2.3.5","@swc/core":"^1.3.59","@types/localtunnel":"^2.0.1","@types/nock":"^11.1.0","@vendure/admin-ui-plugin":"2.0.0","@vendure/core":"2.0.0","@vendure/testing":"2.0.0","@vendure/ui-devkit":"2.0.0","copyfiles":"^2.4.1","nock":"^13.2.9","node-fetch":"^2.0.0","ts-node":"^10.9.1","typescript":"4.9.5","unplugin-swc":"^1.3.2","vitest":"^0.30.1"},"dependencies":{"date-fns":"^2.29.3","stripe":"^11.1.0"},"gitHead":"89507cfaa85a9fe1fb204f382f6ba730138fcc27","_id":"vendure-plugin-stripe-subscription@7.0.4","dist":{"shasum":"83676fe0573fdcc10ac36ec6632fb23d72ae7055","integrity":"sha512-j5ZiTEDW54mFv5lJhLuXAR0IFSmDdHp0gwsQOm7PZBPuQxbyURuWgnYSbQOyNHS+frB74i7Kg+9nGLakY/K29Q==","tarball":"https://registry.npmjs.org/vendure-plugin-stripe-subscription/-/vendure-plugin-stripe-subscription-7.0.4.tgz","fileCount":55,"unpackedSize":158444,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC4Uuvhg4gq1hKTkICwZz+5eSGsdRVP+fUptZ9KIpEAPgIgR/MWhKGM+lN5fB9ndhWzMu4G6lLk5PCdsLFqPKlAIqU="}]},"_npmUser":{"name":"mbrug","email":"martijn.brug@gmail.com"},"directories":{},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vendure-plugin-stripe-subscription_7.0.4_1687242179352_0.8928769749330647"},"_hasShrinkwrap":false,"deprecated":"Moved to @pinelab/vendure-plugin-stripe-subscription"}},"time":{"created":"2022-12-20T14:40:15.129Z","4.3.0":"2022-12-20T14:40:15.350Z","modified":"2023-08-02T09:28:34.236Z","4.4.0":"2022-12-20T14:41:35.969Z","4.4.0-beta.1":"2022-12-20T14:42:26.437Z","4.4.0-beta.2":"2022-12-21T12:11:44.829Z","4.4.0-beta.3":"2022-12-21T12:33:56.244Z","4.4.0-beta.4":"2022-12-21T15:39:48.869Z","4.4.0-beta.5":"2022-12-23T14:30:59.355Z","4.4.0-beta.6":"2022-12-23T14:33:41.740Z","4.4.0-beta.7":"2022-12-23T14:39:27.253Z","4.4.0-beta.8":"2022-12-23T15:15:51.882Z","4.4.0-beta.9":"2022-12-23T15:31:00.073Z","4.4.0-beta.10":"2022-12-28T07:19:45.488Z","4.4.0-beta.11":"2022-12-28T07:59:38.250Z","4.4.0-beta.12":"2022-12-28T14:48:44.338Z","4.4.0-beta.13":"2022-12-28T14:50:50.504Z","4.4.0-beta.14":"2022-12-30T12:51:10.591Z","4.4.0-beta.15":"2022-12-30T15:14:45.556Z","4.4.0-beta.16":"2023-01-02T10:26:13.422Z","4.4.0-beta.17":"2023-01-02T12:01:26.015Z","4.4.0-beta.18":"2023-01-02T14:45:22.861Z","4.4.0-beta.19":"2023-01-02T14:49:16.546Z","4.4.0-beta.20":"2023-01-04T14:43:08.034Z","4.4.0-beta.21":"2023-01-04T14:54:35.378Z","4.4.0-beta.22":"2023-01-06T15:03:16.078Z","4.4.0-beta.23":"2023-01-09T13:47:31.153Z","4.4.0-beta.24":"2023-01-09T14:55:24.820Z","4.4.0-beta.25":"2023-01-10T12:54:51.233Z","4.4.0-beta.26":"2023-01-13T13:19:11.126Z","4.4.0-beta.27":"2023-01-16T15:39:34.827Z","4.4.0-beta.28":"2023-01-18T12:11:05.860Z","4.4.0-beta.29":"2023-01-24T15:19:29.191Z","4.4.0-beta.30":"2023-01-27T14:28:41.665Z","4.4.0-beta.31":"2023-01-30T15:36:11.725Z","4.11.0":"2023-02-06T12:00:56.371Z","5.0.1":"2023-02-08T14:51:59.055Z","5.0.2":"2023-02-10T14:19:43.884Z","5.0.3-beta.1":"2023-02-14T16:09:18.143Z","5.2.0":"2023-02-20T10:35:18.546Z","5.2.3":"2023-03-14T15:55:45.073Z","5.3.0":"2023-03-24T11:54:49.380Z","5.4.0":"2023-03-24T15:16:24.835Z","5.5.0":"2023-03-31T14:41:26.731Z","5.5.2":"2023-04-04T08:02:41.421Z","5.6.7":"2023-04-14T09:59:40.534Z","5.10.0":"2023-05-01T08:30:02.183Z","5.10.2-beta":"2023-05-02T15:23:24.996Z","5.10.2":"2023-05-03T15:20:49.241Z","6.0.0":"2023-05-05T08:14:54.023Z","7.0.0":"2023-05-09T14:53:54.351Z","7.0.1":"2023-05-10T06:41:01.013Z","6.0.1":"2023-05-12T06:34:43.364Z","7.0.2":"2023-05-12T06:38:52.280Z","7.0.3":"2023-05-15T14:02:11.383Z","7.0.0-v2.5":"2023-06-09T13:53:37.485Z","7.0.0-beta.v2.6":"2023-06-09T13:57:02.238Z","7.0.0-beta.v2.7":"2023-06-12T08:54:31.671Z","7.0.4":"2023-06-20T06:22:59.515Z"},"maintainers":[{"name":"mbrug","email":"martijn.brug@gmail.com"}],"description":"Vendure plugin for selling subscriptions via Stripe","homepage":"https://pinelab.studio/","repository":{"type":"git","url":"https://github.com/Pinelab-studio/pinelab-vendure-plugins"},"author":{"name":"Martijn van de Brug","email":"martijn@pinelab.studio"},"license":"MIT","readme":"# Vendure Stripe Subscription plugin\n\n![Vendure version](https://img.shields.io/npm/dependency-version/vendure-plugin-stripe-subscription/dev/@vendure/core)\n\nA channel aware plugin that allows you to sell subscription based services or memberships through Vendure. Also support\nnon-subscription payments. This plugin was made in collaboration with the great people\nat [isoutfitters.com](https://isoutfitters.com/).\n\n## How it works\n\nA few things you should know before getting started:\n\n- Subscriptions are defined by `Schedules`. A schedule is a blueprint for a subscription and can be reused on multiple\n  subscriptions. An example of a schedule is\n  `Billed every first of the month, for 6 months`.\n- Schedules have a fixed duration. Currently, they do autorenew after this duration. The duration is used to calculate\n  prorations and down payment deductions. Read more on this under [Advanced features](#advanced-features)\n- By connecting a `Schedule` to a ProductVariant, you turn the variant into a subscription. The price of the variant is\n  the price a customer pays **per interval**.\n\n![](docs/schedule-weekly.png)  \n_Managing schedules in the Admin UI_\n\n![](docs/sub-product.png)  \n_Connecting a schedule to a product variant_\n\n### Examples of schedules\n\nA variant with price $30,- and schedule `Duration of 6 months, billed monthly` is a subscription where the customer is\nbilled $30,- per month for 6 months.\n\nA variant with price $300 and a schedule of `Duration of 12 months, billed every 2 months` is a subscription where the\ncustomer is billed $300 every 2 months, for a duration of 12 months.\n\nCurrently, subscriptions auto-renew after their duration: After 12 months, the customer is again billed $300 per 2\nmomnths for 12 months.\n\n## Getting started\n\n### Setup Stripe webhook\n\n1. Go to Stripe > developers > webhooks and create a webhook to `https://your-vendure.io/stripe-subscriptions/webhook`\n2. Select the following events for the webhook: `payment_intent.succeeded`, `invoice.payment_succeeded` and `invoice.payment_failed`\n\n## Vendure setup\n\n3. Add the plugin to your `vendure-config.ts` plugins and admin UI compilation:\n\n```ts\nimport { StripeSubscriptionPlugin } from 'vendure-plugin-stripe-subscription';\n\nplugins: [\n  StripeSubscriptionPlugin,\n  AdminUiPlugin.init({\n    port: 3002,\n    route: 'admin',\n    app: compileUiExtensions({\n      outputPath: path.join(__dirname, '__admin-ui'),\n      extensions: [StripeSubscriptionPlugin.ui],\n    }),\n  }),\n];\n```\n\n5. Run a migration to add the `Schedule` entity and custom fields to the database.\n6. Start the Vendure server and login to the admin UI\n7. Go to `Settings > Subscriptions` and create a Schedule.\n8. Create a variant and select a schedule in the variant detail screen in the admin UI.\n9. Create a payment method with the code `stripe-subscription-payment` and select `stripe-subscription` as handler. **\n   Your payment method MUST have 'stripe-subscription' in the code field**\n10. Set your API key from Stripe in the apiKey field.\n11. Get the webhook secret from you Stripe dashboard and save it on the payment method.\n\n## Storefront usage\n\n1. From your storefront, add the subscription variant to your order\n2. Add a shipping address and a shipping method to the order (mandatory for all orders).\n3. Call the graphql mutation `createStripeSubscriptionIntent` to receive the Payment intent token.\n4. Use this token to display the Stripe form on your storefront. See\n   the [Stripe docs](https://stripe.com/docs/payments/accept-a-payment?platform=web&ui=elements#set-up-stripe.js) on how\n   to accomplish that.\n5. During the checkout the user is only charged any potential down payment or proration (\n   see [Advanced features](#advanced-features)). The recurring charges will occur on the start of the schedule. For\n   paid-up-front schedules the customer pays the full amount during checkout\n6. Have the customer fill out his payment details.\n7. Vendure will create the subscriptions after the intent has successfully been completed by the customer.\n8. The order will be settled by Vendure when the subscriptions are created.\n\nIt's important to inform your customers what you will be billing them in the\nfuture: https://stripe.com/docs/payments/setup-intents#mandates\n\n![](docs/subscription-events.png)  \n_After order settlement you can view the subscription details on the order history_\n\n![](docs/sequence.png)  \n_Subscriptions are created in the background, after a customer has finished the checkout_\n\n## Order with a total of €0\n\nWith subscriptions, it can be that your order totals to €0, because, for example, you start charging your customer starting next month.\nIn case of an order being €0, a verification fee of €1 is added, because payment_intents with €0 are not allowed by Stripe.\n\n## Canceling subscriptions\n\nYou can cancel a subscription by canceling the corresponding order line of an order. The subscription will be canceled before the next billing cycle using Stripe's `cancel_at_period_end` parameter.\n\n## Refunding subscriptions\n\nOnly initial payments of subscriptions can be refunded. Any future payments should be refunded via the Stripe dashboard.\n\n# Advanced features\n\nFeatures you can use, but don't have to!\n\n## Payment eligibility checker\n\nYou can use the payment eligibility checker `has-stripe-subscription-products-checker` if you want customers that don't have subscription products in their order to use a different payment method. The `has-stripe-subscription-products-checker` makes your payment method not eligible if it does not contain any subscription products.\n\nThe checker is added automatically, you can just select it via the Admin UI when creating or updating a payment method.\n\n## Down payments\n\nYou can define down payments to a schedule, to have a customer pay a certain amount up front. The paid amount is then deducted from the recurring charges.\n\nExample:\nWe have a schedule + variant where the customer normally pays $90 a month for 6 months. We set a down payment of $180, so the customer pays $180 during checkout.\nThe customer will now be billed $60 a month, because he already paid $180 up front: $180 / 6 months = $30, so we deduct the $30 from every month.\n\nA down payment is created as separate subscription in Stripe. In the example above, a subscription will be created that charges the customer $180 every 6 months,\nbecause the down payment needs to be paid again after renewal\n\n## Paid up front\n\nSchedules can be defined as 'Paid up front'. This means the customer will have to pay the total value of the\nsubscription during the checkout. Paid-up-front subscriptions can not have down payments, because it's already one big\ndown payment.\n\nExample:\n![](docs/schedule-paid-up-front.png)\nWhen we connect the schedule above to a variant with price $540,-, the user will be prompted to pay $540,- during\ncheckout. The schedules start date is **first of the month**, so a subscription is created to renew the $540,- in 6\nmonths from the first of the month. E.g. the customer buys this subscription on January 15 and pays $540,- during\ncheckout. The subscription's start date is February 1, because that's the first of the next month.\n\nThe customer will be billed $540 again automatically on July 1, because that's 6 months (the duration) from the start\ndate of the subscription.\n\n## Prorations\n\nIn the example above, the customer will also be billed for the remaining 15 days from January 15 to February 1, this is\ncalled proration.\n\nProration can be configured on a schedule. With `useProration=false` a customer isn't charged for the remaining days during checkout.\n\nProration is calculated on a yearly basis. E.g, in the example above: $540 is for a duration of 6 months, that means\n$1080 for the full year. The day rate of that subscription will then be 1080 / 365 = $2,96 a day. When the customer buys\nthe subscription on January 15, he will be billed $44,40 proration for the remaining 15 days.\n\n## Storefront defined start dates\n\nA customer can decide to start the subscription on January 17, to pay less proration, because there are now only 13 days\nleft until the first of February. This can be done in the storefront with the following query:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { startDate: \"2023-01-31T09:18:28.533Z\" }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\n## Storefront defined down payments\n\nA customer can also choose to pay a higher down payment, to lower the recurring costs of a subscription.\n\nExample:\nA customer buys a subscription that has a duration of 6 months, and costs $90 per month. The customer can choose to pay\na down payment of $270,- during checkout to lower to monthly price. The $270 down payment will be deducted from the\nmonthly price: 270 / 6 months = $45. With the down payment of $270, customer will now be billed 90 - 45 = $45,- per month\nfor the next 6 months.\n\nDown payments can be added via a custom field on the order line:\n\n```graphql\nmutation {\n  addItemToOrder(\n    productVariantId: 1\n    quantity: 1\n    customFields: { down payment: 27000 }\n  ) {\n    ... on Order {\n      id\n    }\n  }\n}\n```\n\nDown payments can never be lower that the amount set in the schedule, and never higher than the total value of a\nsubscription.\n\n### Preview pricing calculations\n\nYou can preview the pricing model of a subscription without adding it to cart with the following query on the shop-api:\n\n```graphql\n{\n  getStripeSubscriptionPricing(\n    input: {\n      productVariantId: 1\n      # Optional dynamic start date\n      startDate: \"2022-12-25T00:00:00.000Z\"\n      # Optional dynamic down payment\n      downpayment: 1200\n    }\n  ) {\n    downpayment\n    pricesIncludeTax\n    totalProratedAmount\n    proratedDays\n    recurringPrice\n    originalRecurringPrice\n    interval\n    intervalCount\n    amountDueNow\n    subscriptionStartDate\n    schedule {\n      id\n      name\n      downpayment\n      pricesIncludeTax\n      durationInterval\n      durationCount\n      startMoment\n      paidUpFront\n      billingCount\n      billingInterval\n    }\n  }\n}\n```\n\n`Downpayment` and `startDate` are optional parameters. Without them, the defaults defined by the schedule will be used.\n\n### Get subscription pricing details per order line\n\nYou can also get the subscription and Schedule pricing details per order line with the following query:\n\n```graphql\n{\n    activeOrder {\n        id\n        code\n        lines {\n            subscriptionPricing {\n                downpayment\n                totalProratedAmount\n                proratedDays\n                dayRate\n                recurringPrice\n                interval\n                intervalCount\n                amountDueNow\n                subscriptionStartDate\n                schedule {\n                    id\n                    name\n                    downpayment\n                    durationInterval\n                    durationCount\n                    startMoment\n                    paidUpFront\n                    billingCount\n                    billingInterval\n                }\n            }\n        }\n```\n\n### Discount subscription payments\n\nExample of a discount on subscription payments:\n\n- We have a subscription that will cost $30 a month, but has the promotion `Discount future subscription payments by 10%` applied\n- The actual monthly price of the subscription will be $27, forever.\n\nThere are some built in discounts that work on future payments of a subscription. You can select the under Promotion Actions in the Admin UI.\n\n`StripeSubscriptionPricing.originalrecurringPrice` will have the non-discounted subscription price, while `StripeSubscriptionPricing.recurringPrice` will have the final discounted price.\n\n### Custom future payments promotions\n\nYou can implement your own custom discounts that will apply to future payments. These promotions **do not** affect the actual order price, only future payments (the actual subscription price)!\n\nThe `SubscriptionPromotionAction` will discount all subscriptions in an order.\n\n```ts\n// Example fixed discount promotion\nimport { SubscriptionPromotionAction } from 'vendure-plugin-stripe-subscription';\n\n/**\n * Discount all subscription payments by a percentage.\n */\nexport const discountAllSubscriptionsByPercentage =\n  new SubscriptionPromotionAction({\n    code: 'discount_all_subscription_payments_example',\n    description: [\n      {\n        languageCode: LanguageCode.en,\n        value: 'Discount future subscription payments by { discount } %',\n      },\n    ],\n    args: {\n      discount: {\n        type: 'int',\n        ui: {\n          component: 'number-form-input',\n          suffix: '%',\n        },\n      },\n    },\n    async executeOnSubscription(\n      ctx,\n      currentSubscriptionPrice,\n      orderLine,\n      args\n    ) {\n      const discount = currentSubscriptionPrice * (args.discount / 100);\n      return discount;\n    },\n  });\n```\n\n## Caveats\n\n1. This plugin overrides any set OrderItemCalculationStrategies. The strategy in this plugin is used for calculating the\n   amount due for a subscription, if the variant is a subscription. For non-subscription variants, the normal default\n   orderline calculation is used. Only 1 strategy can be used per Vendure instance, so any other\n   OrderItemCalculationStrategies are overwritten by this plugin.\n\n### Contributing and dev server\n\nYou can locally test this plugin by checking out the source.\n\n1. Create a .env file with the following contents:\n\n```\nSTRIPE_APIKEY=sk_test_\nSTRIPE_PUBLISHABLE_KEY=pk_test_\n```\n\n2. Run `yarn start`\n3. Go to `http://localhost:3050/checkout` to view the Stripe checkout\n","readmeFilename":"README.md"}