@sockethub/server 5.0.0-alpha.10

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 (46) hide show
  1. package/LICENSE +165 -0
  2. package/README.md +130 -0
  3. package/bin/sockethub +4 -0
  4. package/dist/defaults.json +36 -0
  5. package/dist/index.js +166465 -0
  6. package/dist/index.js.map +1877 -0
  7. package/dist/platform.js +103625 -0
  8. package/dist/platform.js.map +1435 -0
  9. package/package.json +100 -0
  10. package/res/socket.io.js +4908 -0
  11. package/res/sockethub-client.js +631 -0
  12. package/res/sockethub-client.min.js +19 -0
  13. package/src/bootstrap/init.d.ts +21 -0
  14. package/src/bootstrap/init.test.ts +211 -0
  15. package/src/bootstrap/init.ts +160 -0
  16. package/src/bootstrap/load-platforms.ts +151 -0
  17. package/src/config.test.ts +33 -0
  18. package/src/config.ts +98 -0
  19. package/src/defaults.json +36 -0
  20. package/src/index.ts +68 -0
  21. package/src/janitor.test.ts +211 -0
  22. package/src/janitor.ts +157 -0
  23. package/src/listener.ts +173 -0
  24. package/src/middleware/create-activity-object.test.ts +30 -0
  25. package/src/middleware/create-activity-object.ts +22 -0
  26. package/src/middleware/expand-activity-stream.test.data.ts +351 -0
  27. package/src/middleware/expand-activity-stream.test.ts +77 -0
  28. package/src/middleware/expand-activity-stream.ts +37 -0
  29. package/src/middleware/store-credentials.test.ts +85 -0
  30. package/src/middleware/store-credentials.ts +16 -0
  31. package/src/middleware/validate.test.data.ts +259 -0
  32. package/src/middleware/validate.test.ts +44 -0
  33. package/src/middleware/validate.ts +73 -0
  34. package/src/middleware.test.ts +184 -0
  35. package/src/middleware.ts +71 -0
  36. package/src/platform-instance.test.ts +531 -0
  37. package/src/platform-instance.ts +360 -0
  38. package/src/platform.test.ts +375 -0
  39. package/src/platform.ts +358 -0
  40. package/src/process-manager.ts +88 -0
  41. package/src/routes.test.ts +54 -0
  42. package/src/routes.ts +61 -0
  43. package/src/sentry.test.ts +106 -0
  44. package/src/sentry.ts +19 -0
  45. package/src/sockethub.ts +198 -0
  46. package/src/util.ts +5 -0
package/package.json ADDED
@@ -0,0 +1,100 @@
1
+ {
2
+ "name": "@sockethub/server",
3
+ "description": "A polyglot messaging service, server libraries",
4
+ "version": "5.0.0-alpha.10",
5
+ "type": "module",
6
+ "private": false,
7
+ "author": "Nick Jennings <nick@silverbucket.net>",
8
+ "license": "LGPL-3.0+",
9
+ "publishConfig": {
10
+ "access": "public"
11
+ },
12
+ "main": "dist/index.js",
13
+ "exports": {
14
+ ".": {
15
+ "bun": "./src/index.ts",
16
+ "import": "./dist/index.js",
17
+ "default": "./dist/index.js"
18
+ }
19
+ },
20
+ "files": [
21
+ "src/",
22
+ "dist/",
23
+ "bin/",
24
+ "res/"
25
+ ],
26
+ "bin": "bin/sockethub",
27
+ "preferGlobal": true,
28
+ "engines": {
29
+ "bun": ">=1.2.4"
30
+ },
31
+ "keywords": [
32
+ "sockethub",
33
+ "messaging",
34
+ "polyglot",
35
+ "unhosted",
36
+ "apis",
37
+ "api",
38
+ "protocols",
39
+ "protocol",
40
+ "irc",
41
+ "xmpp",
42
+ "facebook",
43
+ "rss",
44
+ "atom",
45
+ "twitter",
46
+ "smtp",
47
+ "imap",
48
+ "email"
49
+ ],
50
+ "repository": {
51
+ "type": "git",
52
+ "url": "git+https://github.com/sockethub/sockethub.git",
53
+ "directory": "packages/server"
54
+ },
55
+ "homepage": "https://sockethub.org",
56
+ "dependencies": {
57
+ "@sentry/bun": "^10.36.0",
58
+ "@sockethub/activity-streams": "^4.4.0-alpha.10",
59
+ "@sockethub/client": "^5.0.0-alpha.10",
60
+ "@sockethub/crypto": "^1.0.0-alpha.10",
61
+ "@sockethub/data-layer": "^1.0.0-alpha.10",
62
+ "@sockethub/schemas": "^3.0.0-alpha.10",
63
+ "body-parser": "^1.20.4",
64
+ "chalk": "^5.6.2",
65
+ "debug": "^4.4.3",
66
+ "ejs": "^3.1.10",
67
+ "express": "^4.22.1",
68
+ "express-rate-limit": "^8.2.1",
69
+ "jquery": "^3.7.1",
70
+ "nconf": "^0.12.1",
71
+ "socket.io": "^4.7.5"
72
+ },
73
+ "scripts": {
74
+ "build": "bun build src/index.ts --outdir dist --target node --format esm --sourcemap=external && bun build src/platform.ts --outdir dist --target node --format esm --sourcemap=external && cp src/defaults.json dist/defaults.json",
75
+ "clean": "rm -rf dist",
76
+ "dev": "DEBUG=sockethub* bun run --hot ./bin/sockethub --examples",
77
+ "start": "DEBUG=sockethub* bun run ./bin/sockethub"
78
+ },
79
+ "devDependencies": {
80
+ "@types/body-parser": "^1.19.6",
81
+ "@types/bun": "latest",
82
+ "@types/debug": "^4.1.12",
83
+ "@types/express": "^4.17.25",
84
+ "@types/jquery": "^3.5.33",
85
+ "@types/nconf": "^0.10.7",
86
+ "@types/sinon": "^17.0.4",
87
+ "jaribu": "^2.2.3",
88
+ "sinon": "^17.0.2",
89
+ "web-streams-polyfill": "^3.3.3"
90
+ },
91
+ "optionalDependencies": {
92
+ "@sockethub/examples": "^1.0.0-alpha.10",
93
+ "@sockethub/platform-dummy": "^3.0.0-alpha.10",
94
+ "@sockethub/platform-feeds": "^4.0.0-alpha.10",
95
+ "@sockethub/platform-irc": "^4.0.0-alpha.10",
96
+ "@sockethub/platform-metadata": "^1.0.1-alpha.5",
97
+ "@sockethub/platform-xmpp": "^5.0.0-alpha.10"
98
+ },
99
+ "gitHead": "8e1abf116b2a6b57d33c6e1a4af9143870517bae"
100
+ }