npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@iniciador/iniciador-sdk

v0.0.1

Published

SDK to streamline payment initiation integrations with Node.js.

Downloads

4

Readme

Iniciador Node SDK

Welcome to the Iniciador Node SDK! This tool is made for Node developers who want to easily integrate with our API.

If you have no idea what Iniciador is, check out our website

1. Description

The Iniciador SDK is a Node.js library that provides a convenient way to interact with the Iniciador API.

2. Installation

To install the Iniciador SDK, run the following command:

npm install iniciador-sdk

3. Usage

To use the Iniciador SDK, import the necessary modules and create an instance of the Iniciador class:

const { Iniciador } = require('iniciador-sdk')

const iniciador = new Iniciador({
  clientId: 'your-client-id',
  clientSecret: 'your-client-secret',
  environment: 'dev', // or 'sandbox' or 'staging'
})

3.1 Whitelabel

3.1.1 Authentication

To authenticate with the Iniciador Whitelabel, use the authInterface method:

const { accessToken, interfaceURL, paymentId } = await iniciador.authInterface()
  • Use interfaceURL to complete the payment flow
  • Use the accessToken and paymentId to verify the payment data

3.1.2 Payments

To use payments services with the Iniciador Whitelabel, use the payments method:

3.1.2.1 get

to get the payment details use get method

const payment = await iniciador.payment({ accessToken }).get()
3.1.2.2 status

to get the payment status details use status method

const paymentStatus = await iniciador.payment({ accessToken }).status()

3.2 API Only

3.2.1 Authentication

To authenticate with the Iniciador API, use the auth method:

const { accessToken } = await iniciador.auth()

3.2.2 Participants

To get participants with the Iniciador API, use the participants method:

const participants = await iniciador.participants({ accessToken })

3.2.3 Payments

To use payments services with the Iniciador API, use the payments method:

3.2.3.1 save

to save the payment with the specified details use save method

const savePayment = iniciador.save({
  externalId: 'externalId',
  participantId: 'c8f0bf49-4744-4933-8960-7add6e590841',
  redirectURL: 'https://app.sandbox.inic.dev/pag-receipt',
  user: {
    name: 'John Doe',
    taxId: 'taxId',
  },
  amount: 133300,
  method: 'PIX_MANU_AUTO',
})
3.2.3.2 send

to send the payment use send method

const paymentInitiation = await iniciador.payment({ accessToken }).send()
3.2.3.3 get

to get the payment details use get method

const payment = await iniciador.payment({ accessToken }).get()
3.2.3.4 status

to get the payment status details use status method

const paymentStatus = await iniciador.payment({ accessToken }).status()

Help and Feedback

If you have any questions or need assistance regarding our SDK, please don't hesitate to reach out to us. Our dedicated support team is here to help you integrate with us as quickly as possible. We strive to provide prompt responses and excellent support.

We also highly appreciate any feedback you may have. Your thoughts and suggestions are valuable to us as we continuously improve our SDK and services. We welcome your input and encourage you to share your thoughts with us.

Feel free to contact us by sending an email to [email protected]. We look forward to hearing from you and assisting you with your integration.