0.0.3 • Published 6 years ago

chargify-promise v0.0.3

Weekly downloads
3
License
MIT
Repository
github
Last release
6 years ago

#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: "joe@test.com"
}
}).then((customer)=>{
  console.log(customer)
});

Or

async function createCustomer() {

  const customer = await chargify.customer.create({
  customer:{
    first_name: "Joe",
    last_name: "Blow",
    email: "joe@test.com"
  }
});

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)
0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago