New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

stripe

Package Overview
Dependencies
Maintainers
4
Versions
671
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stripe - npm Package Compare versions

Comparing version 2.3.2 to 2.3.3

2

package.json
{
"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",

@@ -92,3 +92,3 @@ # Stripe node.js bindings [![Build Status](https://travis-ci.org/stripe/stripe-node.png?branch=master)](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)

@@ -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 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc