chargily

1.0.1 • Public • Published

Chargily Node.js SDK

Chargily Node.js SDK is a library for interacting with the Chargily API.

Documentation

visit Chargily API Documentation for more information.

Installation

npm install chargily
# or
yarn add chargily

Usage

The package needs to be configured with your account's API key which is available in your Chargily Dashboard.

const Chargily = require("chargily");

const chargily = new Chargily("test_sk_..."); // your secret key

chargily.customers
  .create({
    email: "customer@example.com",
  })
  .then((customer) => console.log(customer.id))
  .catch((error) => console.error(error));

or with ES6 import

import Chargily from "chargily";
const chargily = new Chargily("test_sk_..."); // your secret key

const customer = await chargily.customers.create({
  email: "customer@example.com",
});

console.log(customer.id);

Readme

Keywords

none

Package Sidebar

Install

npm i chargily

Weekly Downloads

3

Version

1.0.1

License

GPL

Unpacked Size

1.35 kB

Total Files

2

Last publish

Collaborators

  • theoriginalayaka