{"id":21901219,"url":"https://github.com/moltin/moltin-micro-checkout","last_synced_at":"2025-04-15T20:11:07.139Z","repository":{"id":69257463,"uuid":"126095391","full_name":"moltin/moltin-micro-checkout","owner":"moltin","description":"💳 One-click moltin purchase with Stripe","archived":false,"fork":false,"pushed_at":"2018-10-12T12:28:54.000Z","size":66,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-29T00:41:21.185Z","etag":null,"topics":["commerce","javascript","micro","moltin","stripe"],"latest_commit_sha":null,"homepage":"https://moltin-next-checkout.now.sh","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/moltin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2018-03-20T23:23:23.000Z","updated_at":"2019-05-28T13:08:16.000Z","dependencies_parsed_at":"2023-02-28T01:01:05.241Z","dependency_job_id":null,"html_url":"https://github.com/moltin/moltin-micro-checkout","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moltin%2Fmoltin-micro-checkout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moltin%2Fmoltin-micro-checkout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moltin%2Fmoltin-micro-checkout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moltin%2Fmoltin-micro-checkout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/moltin","download_url":"https://codeload.github.com/moltin/moltin-micro-checkout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249145303,"owners_count":21219966,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["commerce","javascript","micro","moltin","stripe"],"created_at":"2024-11-28T15:12:45.233Z","updated_at":"2025-04-15T20:11:07.120Z","avatar_url":"https://github.com/moltin.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# moltin-micro-checkout\n\n\u003e ⚡️ One-click moltin purchasing with Stripe\n\n[![Deploy to now](https://deploy.now.sh/static/button.svg)](https://deploy.now.sh/?repo=https://github.com/ynnoj/moltin-micro-checkout\u0026env=MOLTIN_CLIENT_ID)\n\nAsynchronous microservice that enables one-click purchasing with [moltin](https://moltin.com) and [Stripe](https://stripe.com). Built with [Micro](https://github.com/zeit/micro) 🤩\n\n- Add the product to a cart\n- Checkout the cart (create an order)\n- Pay for the order (using the Stripe token)\n\nTry out the [demo app](https://moltin-next-checkout.now.sh) using this service [here](https://moltin-next-checkout.now.sh).\n\n## 🛠 Setup\n\n`npm install`\n\n`npm run dev`\n\nCreate a `.env` at the project root with your moltin `client_id`.\n\n```dosini\nMOLTIN_CLIENT_ID=\n```\n\nBoth a moltin _and_ Stripe account are needed for this to function. Be sure that your [Stripe keys](https://stripe.com/docs/dashboard#api-keys) are attached to your moltin store. Learn more about that [here](https://docs.moltin.com/?bash#configuring-stripe).\n\n## ⛽️ Usage\n\nThis service exposes a single `POST` endpoint which expects the following payload 👇\n\n```json\n{\n  \"token\": \"tok_visa\",\n  \"product\": \"648a0eb5-329b-4475-bd8e-5eed12d27b2c\",\n  \"customer\": \"ec1332a3-7579-4129-90b1-4f0d2c4e38b5\",\n  \"billing_address\": {\n    \"first_name\": \"Jonathan\",\n    \"last_name\": \"Steele\",\n    \"line_1\": \"2nd Floor British India House\",\n    \"line_2\": \"15 Carliol Square\",\n    \"city\": \"Newcastle Upon Tyne\",\n    \"postcode\": \"NE1 6UF\",\n    \"county\": \"Tyne \u0026 Wear\",\n    \"country\": \"United Kingdom\"\n  }\n}\n```\n\nYou can also pass an optional `shipping_address` object. If this omitted then `billing_address` value will be passed to the API.\n\n```json\n\"shipping_address\": {\n  \"first_name\": \"Jonathan\",\n  \"last_name\": \"Steele\",\n  \"line_1\": \"2nd Floor British India House\",\n  \"line_2\": \"15 Carliol Square\",\n  \"city\": \"Newcastle Upon Tyne\",\n  \"postcode\": \"NE1 6UF\",\n  \"county\": \"Tyne \u0026 Wear\",\n  \"country\": \"United Kingdom\"\n}\n```\n\nIf a customer record does not exist, you can instead pass a customer object.\n\n```json\n\"customer\": {\n  \"name\": \"Jonathan Steele\",\n  \"email\": \"jonathan@moltin.com\"\n}\n```\n\nIf a product record does not exist, you can instead pass a product object.\n\n```json\n\"product\": {\n  \"name\": \"MULTI-VIBE 2\",\n  \"sku\": \"MULTI-VIBE-MK2\",\n  \"description\": \"Abstract, sculptural, refined and edgy with a modern twist.\",\n  \"quantity\": 1,\n  \"price\": {\n    \"amount\": 50000\n  }\n}\n```\n\nLearn more at the moltin [API reference](https://docs.moltin.com).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoltin%2Fmoltin-micro-checkout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmoltin%2Fmoltin-micro-checkout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoltin%2Fmoltin-micro-checkout/lists"}