1.3.5 • Published 1 year ago
notrix v1.3.5
Notrix JavaScript SDK
Install
npm install notrix
Examples
Create Checkout Session
import Client from "notrix";
let client = new Client("SECRET_API_KEY", "PROJECT_ID");
let checkoutSession = await client.createCheckoutSession(
[
{
name: "Bike",
description: "green",
price: 32.56, // USD
quantity: 1,
imageURL: "https://example.com/bike.png" // make sure the image is available from the notrix.io domain
}
],
"https://example.com/success",
"https://example.com/cancel",
);
console.log(checkoutSession.url); // redirect the user here to pay
Check Payment Status
import Client from "notrix";
let client = new Client("SECRET_API_KEY", "PROJECT_ID");
let paymentConfirmed = await client.isPaid(checkoutSession.paymentRequestToken); // true / false
1.3.5
1 year ago
1.3.4
1 year ago
1.3.3
1 year ago
1.3.2
1 year ago
1.3.1
1 year ago
1.3.0
1 year ago
1.2.1
1 year ago
1.2.0
1 year ago
1.0.2
2 years ago
1.1.0
2 years ago
1.0.16
2 years ago
1.0.9
2 years ago
1.0.8
2 years ago
1.0.7
2 years ago
1.0.6
2 years ago
1.0.5
2 years ago
1.0.4
2 years ago
1.0.3
2 years ago
1.0.11
2 years ago
1.0.10
2 years ago
1.0.15
2 years ago
1.0.14
2 years ago
1.0.13
2 years ago
1.0.12
2 years ago
1.0.1
2 years ago
1.0.0
2 years ago