@peable.to/sdk 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/dist/cjs/browser/mount.js +308 -0
  2. package/dist/cjs/browser/payerClient.js +135 -0
  3. package/dist/cjs/checkout.js +17 -0
  4. package/dist/cjs/core/client.js +77 -0
  5. package/dist/cjs/core/config.js +38 -0
  6. package/dist/cjs/core/errors.js +112 -0
  7. package/dist/cjs/core/serviceToken.js +81 -0
  8. package/dist/cjs/index.js +41 -0
  9. package/dist/cjs/resources/checkoutSessions.js +26 -0
  10. package/dist/cjs/resources/paymentIntents.js +30 -0
  11. package/dist/cjs/resources/paymentLinks.js +23 -0
  12. package/dist/cjs/resources/webhooks.js +65 -0
  13. package/dist/esm/browser/mount.js +298 -0
  14. package/dist/esm/browser/payerClient.js +132 -0
  15. package/dist/esm/checkout.js +12 -0
  16. package/dist/esm/core/client.js +74 -0
  17. package/dist/esm/core/config.js +34 -0
  18. package/dist/esm/core/errors.js +102 -0
  19. package/dist/esm/core/serviceToken.js +78 -0
  20. package/dist/esm/index.js +28 -0
  21. package/dist/esm/resources/checkoutSessions.js +21 -0
  22. package/dist/esm/resources/paymentIntents.js +26 -0
  23. package/dist/esm/resources/paymentLinks.js +19 -0
  24. package/dist/esm/resources/webhooks.js +61 -0
  25. package/dist/types/browser/mount.d.ts +80 -0
  26. package/dist/types/browser/payerClient.d.ts +23 -0
  27. package/dist/types/checkout.d.ts +2 -0
  28. package/dist/types/core/client.d.ts +17 -0
  29. package/dist/types/core/config.d.ts +30 -0
  30. package/dist/types/core/errors.d.ts +54 -0
  31. package/dist/types/core/serviceToken.d.ts +11 -0
  32. package/dist/types/index.d.ts +22 -0
  33. package/dist/types/resources/checkoutSessions.d.ts +15 -0
  34. package/dist/types/resources/paymentIntents.d.ts +29 -0
  35. package/dist/types/resources/paymentLinks.d.ts +29 -0
  36. package/dist/types/resources/webhooks.d.ts +18 -0
  37. package/package.json +83 -0
package/package.json ADDED
@@ -0,0 +1,83 @@
1
+ {
2
+ "name": "@peable.to/sdk",
3
+ "version": "0.1.1",
4
+ "description": "Peable SDK — a Stripe-ergonomics TypeScript client over the Peable Gateway REST + realtime contract. Server entry (`@peable.to/sdk`) mints Oxy service tokens from an ApplicationCredential and exposes paymentIntents/paymentLinks/checkout.sessions/webhooks; browser entry (`@peable.to/sdk/checkout`) is the anonymous payer-side client core.",
5
+ "main": "dist/cjs/index.js",
6
+ "module": "dist/esm/index.js",
7
+ "types": "dist/types/index.d.ts",
8
+ "source": "src/index.ts",
9
+ "sideEffects": false,
10
+ "publishConfig": {
11
+ "access": "public"
12
+ },
13
+ "exports": {
14
+ ".": {
15
+ "react-native": "./dist/esm/index.js",
16
+ "import": {
17
+ "types": "./dist/types/index.d.ts",
18
+ "default": "./dist/esm/index.js"
19
+ },
20
+ "require": {
21
+ "types": "./dist/types/index.d.ts",
22
+ "default": "./dist/cjs/index.js"
23
+ },
24
+ "default": "./dist/esm/index.js"
25
+ },
26
+ "./checkout": {
27
+ "react-native": "./dist/esm/checkout.js",
28
+ "import": {
29
+ "types": "./dist/types/checkout.d.ts",
30
+ "default": "./dist/esm/checkout.js"
31
+ },
32
+ "require": {
33
+ "types": "./dist/types/checkout.d.ts",
34
+ "default": "./dist/cjs/checkout.js"
35
+ },
36
+ "default": "./dist/esm/checkout.js"
37
+ },
38
+ "./package.json": "./package.json"
39
+ },
40
+ "files": [
41
+ "dist"
42
+ ],
43
+ "keywords": [
44
+ "peable",
45
+ "oxy",
46
+ "payments",
47
+ "sdk",
48
+ "faircoin"
49
+ ],
50
+ "repository": {
51
+ "type": "git",
52
+ "url": "https://github.com/OxyHQ/Peable.git",
53
+ "directory": "packages/sdk"
54
+ },
55
+ "author": "Peable",
56
+ "license": "MIT",
57
+ "homepage": "https://peable.to",
58
+ "engines": {
59
+ "node": ">=18.0.0"
60
+ },
61
+ "scripts": {
62
+ "build": "bun run build:cjs && bun run build:esm && bun run build:types",
63
+ "build:cjs": "tsc -p tsconfig.cjs.json",
64
+ "build:esm": "tsc -p tsconfig.esm.json && node scripts/fix-esm-imports.mjs",
65
+ "build:types": "tsc -p tsconfig.types.json",
66
+ "clean": "rm -rf dist",
67
+ "dev": "tsc --watch",
68
+ "lint": "tsc --noEmit",
69
+ "typecheck": "tsc --noEmit",
70
+ "test": "bun test",
71
+ "prepublishOnly": "bun run clean && bun run build"
72
+ },
73
+ "dependencies": {
74
+ "@peable.to/shared-types": "workspace:^",
75
+ "qrcode-generator": "^2.0.4",
76
+ "socket.io-client": "^4.8.3"
77
+ },
78
+ "devDependencies": {
79
+ "typescript": "~5.9.2",
80
+ "@types/node": "^20.0.0",
81
+ "@types/bun": "latest"
82
+ }
83
+ }