Skip to content

A simple wrapper around Chargify's API that returns promises.

Notifications You must be signed in to change notification settings

bgwaltney/chargify-promise

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chargify API Node.js (unofficial module)

Installation:

$ npm install --save chargify-promise
const chargify = new Chargify(config.subdomain, config.apiKey);

Create a new customer in Chargify:

chargify.customer.create({
customer:{
  first_name: "Joe",
  last_name: "Blow",
  email: "[email protected]"
}
}).then((customer)=>{
  console.log(customer)
});

Or

async function createCustomer() {

  const customer = await chargify.customer.create({
  customer:{
    first_name: "Joe",
    last_name: "Blow",
    email: "[email protected]"
  }
});

console.log(customer)
}

Available resources and methods

  • customer
    • list(queryObject)
    • create(customerObject)
    • update(updateObject)
    • read(customer_id)
    • delete(customer_id)
  • subscription
    • list(queryObject)
    • create(subscriptionObject)
    • update(updateObject)
    • read(id)
    • delete(id)
  • product
    • list(queryObject)
    • create(family_id, productObject)
    • update(updateObject)
    • read(id)
    • archive(id)

About

A simple wrapper around Chargify's API that returns promises.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published