All Projects â†’ xcarpentier â†’ React Native Stripe Api

xcarpentier / React Native Stripe Api

Licence: mit
🤑 A small React Native library for Stripe Rest API

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to React Native Stripe Api

Product-Site-101
Simple product site - demo for a talk
Stars: ✭ 33 (-82.63%)
Mutual labels:  stripe-api
Docker2saas
An open source tool that lets you create a SaaS website from docker images in 10 minutes.
Stars: ✭ 498 (+162.11%)
Mutual labels:  stripe-api
Stripe Kit
Stars: ✭ 50 (-73.68%)
Mutual labels:  stripe-api
procesa-pagos-con-laravel
Código fuente resultado del curso "Procesa pagos con Laravel y las mejores plataformas de pagos"
Stars: ✭ 38 (-80%)
Mutual labels:  stripe-api
Stripe Connect Rocketrides
Sample on-demand platform built on Stripe: Connect onboarding for pilots, iOS app for passengers to request rides.
Stars: ✭ 426 (+124.21%)
Mutual labels:  stripe-api
Pinax Stripe
a payments Django app for Stripe
Stars: ✭ 650 (+242.11%)
Mutual labels:  stripe-api
MERN-Ecommerce
An E-commerce app built using MERN stack. It has 4 social login options and implements email verification as well. Stripe and Paypal payment gateways are implemented.
Stars: ✭ 50 (-73.68%)
Mutual labels:  stripe-api
Stripe
💰 Stripe API
Stars: ✭ 150 (-21.05%)
Mutual labels:  stripe-api
Vue Stripe Elements
A Vue 2 component collection for StripeElements
Stars: ✭ 498 (+162.11%)
Mutual labels:  stripe-api
Stripy
Micro wrapper for Stripe's REST API.
Stars: ✭ 49 (-74.21%)
Mutual labels:  stripe-api
stripe-scala
Scala library for the Stripe API
Stars: ✭ 33 (-82.63%)
Mutual labels:  stripe-api
Stripe Webhook Monitor
Stripe Webhook Monitor provides a real-time feed and graph of Stripe events received via webhooks. 📈✨
Stars: ✭ 356 (+87.37%)
Mutual labels:  stripe-api
Stripe Rs
Moved to https://github.com/wyyerd/stripe-rs.
Stars: ✭ 16 (-91.58%)
Mutual labels:  stripe-api
stripe-course
Stripe Payments In Practice - Build your own online ecommerce store and subscription membership website
Stars: ✭ 31 (-83.68%)
Mutual labels:  stripe-api
Stripe Elixir
Stripe API client for Elixir
Stars: ✭ 66 (-65.26%)
Mutual labels:  stripe-api
nuxt-stripejs
💳 NuxtJS module for Stripe.js which loads only when required and w/ retry mechanism
Stars: ✭ 17 (-91.05%)
Mutual labels:  stripe-api
Stripity stripe
An Elixir Library for Stripe
Stars: ✭ 597 (+214.21%)
Mutual labels:  stripe-api
Stripe
Stripe library for Vapor
Stars: ✭ 151 (-20.53%)
Mutual labels:  stripe-api
Terraform Provider Stripe
A Terraform Provider for Stripe
Stars: ✭ 143 (-24.74%)
Mutual labels:  stripe-api
Stripe Demo Connect Roastery Saas Platform
Roastery demo SaaS platform using Stripe Connect
Stars: ✭ 33 (-82.63%)
Mutual labels:  stripe-api

react-native-stripe-api (only to create token)

NPM version Downloads Circle CI reactnative.gallery

Little Stripe library for React-Native.

Installation

$ npm i react-native-stripe-api --save

or

$ yarn add react-native-stripe-api

Roadmap

  • include a payment form component
  • include react-native-awesome-card-io
  • a new server project to keep secret

Setup

Security issue (fixed since 0.1.0)

https://github.com/xcarpentier/react-native-stripe-api/issues/8

Stripe API

This lib need a Stripe API Key

import Stripe from 'react-native-stripe-api';

const apiKey = '<your Stripe API Key>';
const client = new Stripe(apiKey);

// Create a Stripe token with new card infos
const token = await client.createToken({
       number: '4242424242424242' ,
       exp_month: '09', 
       exp_year: '18', 
       cvc: '111',
       address_zip: '12345'
    });

// Create a new customer and link your new card
// const customer = await client.createCustomer(token.id, '[email protected]', '<Your user ID>', 'John', 'Doe');

// Create charge, 1 USD
// const charge = await client.createCharge(1 * 100, customer.id, 'Payment example','USD');

Functions

Name Return Type Arguments Description
createToken Promise
  • cardNumber: string
  • expMonth: string
  • expYear: string
  • cvc: string
Create a new token (equivalent of a new card)
createCustomer Promise
  • token: string
  • email: string
Create a new customer and add card (or token)
getCustomer Promise customerId: string Retrieve customer by its id
createCharge Promise
  • amount: number
  • customer: string
  • description: string
  • currency: string = 'eur'
Create a new charge
refundCharge Promise chargeId: string Refund a previous charge
addCardToCustomer Promise
  • token: string
  • customerId: string
    Add a new card to a customer
    destroyCardOfCustomer Promise
    • cardId: string
    • customerId: string
    Delete a card from a customer
    createSubscription Promise
    • customerId: string
    • plan: string
    Subscribes a customer to a subscription plan
    retrieveSubscription Promise
    • subscriptionId: string
    Retrieve the data of a subscription

    Contribution

    Questions

    Feel free to contact me or create an issue

    made with ♥

    Hire an expert!

    Looking for a ReactNative freelance expert with more than 12 years experience? Contact me from my website!

    Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].