Giter Club home page Giter Club logo

fscheckoutsheet's Introduction

FSCheckoutSheet

A WKWebView wrapper that handles interaction w/ a FastSpring checkout form. FastSpring is an online store provider, useful for selling digital products. For example Mac applications outside of Apple's Mac App Store.

This package is only dealing with the actual FastSpring checkout process, it doesn't provide any In-App store parts. To see it in a live app, download Shrugs.app.

Inspired by Make Money Outside the Mac App Store. This code doesn't require a "classic" FastSpring store, but uses the regular one. It uses the Store Builder Library to configure the checkout, and scans the result for licenses after a successful checkout.

Usage

The package provides a single NSViewController used for checkout: FastSpringCheckoutVC.

let vc = FastSpringCheckoutVC()
vc.checkoutProduct("soy-for-community-slacks",
                   in: "zeezide.onfastspring.com") {
    licenseKeys in

    for licenseKey in licenseKeys {
        print("User",   licenseKey.name,
              "bought", licenseKey.sku,
              "code:",  licenseKey.code)
    }
}

self.presentAsSheet(vc)

Note: Currently this is only reporting CocoaFob licenses.

Don't forget to enable client network connections if your hosting app is sandboxed! Otherwise you'll just see the spinner or a white background.

Import Package

The Package URL is: https://github.com/ZeeZide/FSCheckoutSheet.git, can be added to your Xcode project.

Demo Application

The Demo folder contains a demo application for the sheet. Configure your store (e.g. a test store) in the Configuration.swift file, to play with the panel. By default it is configured to access the live Shrugs.app store, so careful, what you buy is what you buy :-)

Looks like this:

Who

FSCheckoutSheet is brought to you by ZeeZide. We like feedback, GitHub stars, cool contract work, presumably any form of praise you can think of.

fscheckoutsheet's People

Contributors

helje5 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.