+3
-0
@@ -0,1 +1,4 @@ | ||
| 2.3.3 Jan 10th 2013 | ||
| - Document cancelSubscription method params and add specs for `at_period_end` | ||
| 2.3.2 Dec 2nd, 2013 | ||
@@ -2,0 +5,0 @@ - Add application fees API |
+1
-1
| { | ||
| "name": "stripe", | ||
| "version": "2.3.2", | ||
| "version": "2.3.3", | ||
| "description": "Stripe API wrapper", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/stripe/stripe-node", |
+1
-1
@@ -92,3 +92,3 @@ # Stripe node.js bindings [](https://travis-ci.org/stripe/stripe-node) | ||
| * [`updateSubscription(customerId[, params])`](https://stripe.com/docs/api/node#update_subscription) | ||
| * [`cancelSubscription(customerId)`](https://stripe.com/docs/api/node#cancel_subscription) | ||
| * [`cancelSubscription(customerId[, params])`](https://stripe.com/docs/api/node#cancel_subscription) | ||
| * [`createCard(customerId[, params])`](https://stripe.com/docs/api/node#create_card) | ||
@@ -95,0 +95,0 @@ * [`listCards(customerId)`](https://stripe.com/docs/api/node#list_cards) |
+33
-0
@@ -95,2 +95,35 @@ 'use strict'; | ||
| it('Allows me to: subscribe then cancel with `at_period_end` defined', function() { | ||
| return expect( | ||
| when.join( | ||
| stripe.plans.create({ | ||
| id: 'plan' + +new Date, | ||
| amount: 1700, | ||
| currency: CURRENCY, | ||
| interval: 'month', | ||
| name: 'Silver Super Amazing Tier' | ||
| }), | ||
| stripe.customers.create(CUSTOMER_DETAILS) | ||
| ).then(function(j) { | ||
| var plan = j[0]; | ||
| var customer = j[1]; | ||
| cleanup.deleteCustomer(customer.id); | ||
| cleanup.deletePlan(plan.id); | ||
| return stripe.customers.updateSubscription(customer.id, { | ||
| plan: plan.id | ||
| }); | ||
| }).then(function(subscription) { | ||
| return stripe.customers.cancelSubscription(subscription.customer, { | ||
| at_period_end: true | ||
| }); | ||
| }) | ||
| ).to.eventually.have.property('cancel_at_period_end', true); | ||
| }); | ||
| }); | ||
@@ -97,0 +130,0 @@ |
@@ -168,2 +168,15 @@ 'use strict'; | ||
| describe('With at_period_end defined', function() { | ||
| it('Sends the correct request', function() { | ||
| stripe.customers.cancelSubscription('customerIdFoo321', {at_period_end: true}); | ||
| expect(stripe.LAST_REQUEST).to.deep.equal({ | ||
| method: 'DELETE', | ||
| url: '/v1/customers/customerIdFoo321/subscription', | ||
| data: { at_period_end: true } | ||
| }); | ||
| }); | ||
| }); | ||
| }); | ||
@@ -170,0 +183,0 @@ |
+1
-1
@@ -1,1 +0,1 @@ | ||
| 2.3.2 | ||
| 2.3.3 |
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
88351
1.7%2354
1.55%7
-12.5%