Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

flatmarket

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

flatmarket

A free, open source e-commerce platform for static websites.

  • 2.1.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

flatmarket

Build Status codecov.io

Flatmarket is a free, open source e-commerce platform for static websites. It is reliable, secure, and inexpensive to operate.

The platform uses Stripe for payment processing and is built on the latest web technologies like hapi, React, and Webpack.

At its core is a batteries-included CLI to help you get started quickly. Modules are also packaged individually so you can customize your rig.

How it works

The Flatmarket architecture consists of a static website paired with a proxy server for sending payments to Stripe. The browser and server share a public schema (represented by a JSON document) to prevent charge tampering. The store operator can manage inventory and store configuration by updating the schema document.

Architecture

Architecture Diagram

  1. The web browser loads the single-page app from the static file server (e.g. AWS S3).
  2. The user submits their credit card information with Stripe Checkout and the web browser obtains a new Stripe token.
  3. The web browser sends the token and product ID the Flatmarket server.
  4. The Flatmarket server pulls the product information from flatmarket.json hosted on the static file server.
  5. The Flatmarket server sends the charge to Stripe.

Live Demo

Take a minute to go try the live demo.

Design goals

  • It should cost next-to-nothing to operate.
  • It should should be reliable and scalable. This is achieved by offloading expensive and complicated operations to third-party services.
  • It should be secure.
  • It should be easy to customize, update, and deploy.

Features

Use cases

Flatmarket isn't appropriate for every e-commerce project, but it is uniquely suited for the following situations:

  • high traffic but low sales volume.
  • high touch, where every transaction requires human involvement.
  • sale of digital goods, made-to-order goods, or donations (where stock keeping is not required).
  • any situation where low cost is a priority.

Installation

$ npm install flatmarket

Quick Start

1.

Deploy a Flatmarket server to your Heroku account.

2.

Create a schema document at ./src/flatmarket.json

{
  "info": {
    "name": "Your Store"
  },
  "products": {
    "sku_001": {
      "amount": 1000
    }
  },
  "server": {
    "host": "your-flatmarket-server.herokuapp.com"
  },
  "stripe": {
    "publishableKey": "your_publishable_key"
  }
}

3.

Build the Flatmarket website and deploy to your favorite static web host.

$ flatmarket ./src/flatmarket.json

4.

Read the API reference and customization guide to learn more.

Platform

Themes

Reference

See REFERENCE.

Customization

See CUSTOMIZATION.

Contributing

See CONTRIBUTING.

License

See LICENSE.

FAQs

Package last updated on 01 Feb 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc