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

@bennyapi/react-native-sdk

v1.2.2

Published

Benny API's React Native SDK

Downloads

17

Readme

Benny React Native SDK

The Benny React Native SDK allows your app to use Benny client libraries.

Note See our complete documentation at docs.bennyapi.com.

Installation

Install the SDK using your preferred package manager.

yarn install @bennyapi/react-native-sdk

EBT Balance Link Flow

The Ebt Balance Link Flow allows users to link their EBT account, verify the account, and returning a tokenized representation of the credentials for fetching balance and transaction information.

Required IDs

You'll need an organizationId, the ID representing your organization, along with a temporarylink that is generated serverside via a call to the Benny API.

Note Reach out to [email protected] to set up your organization.

Integration

The Ebt Balance Link Flow is contained in a simple fullscreen component, EbtBalanceLinkFlow, that is initialized with your organization ID and the single-use temporary link.

Callbacks (i.e., onExit and onLinkResult) are responsible for communicating to your app when the user wants to exit the flow and when a link result is obtained.

<EbtBalanceLinkFlow
  organizationId="org_wup29bz683g8habsxvazvyz1"
  temporaryLink="temp_clr0vujq9000108l66odc7fxv"
  onExit={() => {
    /** Your on exit logic. */
  }}
  onLinkResult={
    /** Your on link result logic. */
  }
  environment={EbtBalanceLinkFlowEnvironment.Sandbox}
/>

Environments

Set the environment to EbtBalanceLinkFlowEnvironment.Sandbox to integrate with the Benny sandbox environment, or omit to default to the production environment.

Handling Browser Navigation

The flow will go back on Android's hardware back press or gesture if there are previous screens.

EBT Transfer

The EBT Transfer product consists of EbtTransferLinkCardFlow, EbtTransferBalanceFlow, and the EbtTransferFlow. Once a user successfully links their EBT card through the EbtTransferLinkCardFlow, a transfer token is created. The transfer token allows for EBT balance checks through the EbtTransferBalanceFlow and EBT cash transfers through the EbtTransferBalanceFlow.

Link Card Flow

The EbtTransferLinkCardFlow is initialized with an organization ID and a single-use temporary link generated serverside via a call to Benny's API.

Callbacks (i.e., onExit and onLinkResult) are responsible for communicating to your app when the user wants to exit the flow and when a link result is obtained. A successful link result returns a transfer token along with its expiration date. A failed link result returns an error message.

<EbtTransferLinkCardFlow
  organizationId="org_wup29bz683g8habsxvazvyz1"
  temporaryLink="temp_clr0vujq9000108l66odc7fxv"
  onExit={() => {
    /** Your on exit logic. */
  }}
  onLinkResult={
    (transferToken?: string, expiration?: string, error?: string) {/** Your on link result logic. */}
  }
  environment={EbtTransferEnvironment.Sandbox}
/>

Balance Flow

The EbtTransferBalanceFlow is initialized with an organization ID and the transfer token obtained earlier.

Callbacks (i.e., onExit and onResult) are responsible for communicating to your app when the user wants to exit the flow and when a result is obtained. A successful result returns the customer's cents-denominated EBT cash balance, while a failed link result returns an error message.

<EbtTransferBalanceFlow
  organizationId="org_wup29bz683g8habsxvazvyz1"
  transferToken="transfer_sf3k3absxvazvjsd3lks"
  onExit={() => {
    /** Your on exit logic. */
  }}
  onResult={
   (balance?: string, error?: string) => {/** Your logic here. */}
  }
  environment={EbtTransferEnvironment.Sandbox}
/>

Transfer Flow

The EbtTransferFlow is initialized with an organization ID, the transfer token obtained earlier, a cents-denominated amount that the customer wishes to transfer, and an idempotency key.

Callbacks (i.e., onExit and onResult) are responsible for communicating to your app when the user wants to exit the flow and when a transfer result is obtained. A successful result invokes the onResult callback with no value, while a failed result returns an error message.

<EbtTransferFlow
  organizationId="org_wup29bz683g8habsxvazvyz1"
  transferToken="transfer_sf3k3absxvazvjsd3lks"
  amount={100}
  idempotencyKey="idempotency"
  onExit={() => {
    /** Your on exit logic. */
  }}
  onResult={
      (error?: string) => {/** Your result logic. */}
  }
  environment={EbtTransferEnvironment.Sandbox}
/>

Environments

Set the environment to EbtTransferEnvironment.Sandbox to integrate with the Benny sandbox environment, or omit to default to the production environment.

Example App

The Expo example app can be run with:

yarn example android

or

yarn example ios

Author

Benny API Inc.

License

The Benny SDK is available under the MIT license.