sparta_worlds 0.6.0

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 (93) hide show
  1. package/LICENSE.txt +15 -0
  2. package/bin/worlds.js +53 -0
  3. package/dist/cli/argv.js +27 -0
  4. package/dist/cli/claims.js +250 -0
  5. package/dist/cli/commands.js +67 -0
  6. package/dist/cli/contract.js +142 -0
  7. package/dist/cli/demo.js +114 -0
  8. package/dist/cli/doctor.js +299 -0
  9. package/dist/cli/expect.js +197 -0
  10. package/dist/cli/home.js +18 -0
  11. package/dist/cli/import.js +530 -0
  12. package/dist/cli/index.js +1014 -0
  13. package/dist/cli/init.js +725 -0
  14. package/dist/cli/judge-command.js +184 -0
  15. package/dist/cli/judge.js +1495 -0
  16. package/dist/cli/load.js +8 -0
  17. package/dist/cli/packs.js +82 -0
  18. package/dist/cli/passk.js +1256 -0
  19. package/dist/cli/policy-starters.js +83 -0
  20. package/dist/cli/preload.js +45 -0
  21. package/dist/cli/report.js +579 -0
  22. package/dist/cli/rubric.js +727 -0
  23. package/dist/cli/run.js +266 -0
  24. package/dist/cli/scoreboard.js +432 -0
  25. package/dist/cli/selftest.js +157 -0
  26. package/dist/cli/stdio.js +25 -0
  27. package/dist/cli/tasks.js +1246 -0
  28. package/dist/cli/try.js +156 -0
  29. package/dist/cli/version.js +17 -0
  30. package/package.json +38 -0
  31. package/packs/cancellations.yaml +201 -0
  32. package/packs/credits.yaml +274 -0
  33. package/packs/invoices.yaml +206 -0
  34. package/packs/plan-changes.yaml +170 -0
  35. package/packs/refunds.yaml +437 -0
  36. package/preload/node-hooks.mjs +28 -0
  37. package/preload/node.mjs +19 -0
  38. package/preload/python/sitecustomize.py +88 -0
  39. package/preload/wrap.mjs +81 -0
  40. package/rubrics/acme-prod-library.json +1427 -0
  41. package/rubrics/acme-prod-shift.json +499 -0
  42. package/server/dist/admin/auth.js +145 -0
  43. package/server/dist/admin/routes.js +469 -0
  44. package/server/dist/admin/schemas.js +243 -0
  45. package/server/dist/app.js +112 -0
  46. package/server/dist/core/canonical.js +22 -0
  47. package/server/dist/core/db.js +294 -0
  48. package/server/dist/core/errors.js +136 -0
  49. package/server/dist/core/manager.js +337 -0
  50. package/server/dist/core/money.js +43 -0
  51. package/server/dist/core/nondeterministic.js +39 -0
  52. package/server/dist/core/paths.js +33 -0
  53. package/server/dist/core/prng.js +19 -0
  54. package/server/dist/core/protocol.js +1 -0
  55. package/server/dist/core/publicUrl.js +49 -0
  56. package/server/dist/core/seed.js +286 -0
  57. package/server/dist/core/seedExport.js +169 -0
  58. package/server/dist/core/seedLoader.js +156 -0
  59. package/server/dist/core/time.js +45 -0
  60. package/server/dist/core/world.js +361 -0
  61. package/server/dist/index.js +17 -0
  62. package/server/dist/main.js +42 -0
  63. package/server/dist/scenario/engine.js +172 -0
  64. package/server/dist/scenario/library.js +49 -0
  65. package/server/dist/twin/build.js +372 -0
  66. package/server/dist/twin/pagination.js +32 -0
  67. package/server/dist/twin/params.js +118 -0
  68. package/server/dist/twin/resources/charges.js +24 -0
  69. package/server/dist/twin/resources/customers.js +151 -0
  70. package/server/dist/twin/resources/events.js +26 -0
  71. package/server/dist/twin/resources/invoices.js +217 -0
  72. package/server/dist/twin/resources/payment_intents.js +146 -0
  73. package/server/dist/twin/resources/products.js +92 -0
  74. package/server/dist/twin/resources/refunds.js +103 -0
  75. package/server/dist/twin/resources/shared.js +113 -0
  76. package/server/dist/twin/resources/subscriptions.js +325 -0
  77. package/server/dist/twin/resources/tickets.js +128 -0
  78. package/server/dist/twin/router.js +279 -0
  79. package/server/dist/twin/unsupported.js +212 -0
  80. package/server/dist/webhooks/dispatcher.js +148 -0
  81. package/server/scenarios/auth-expiry.yaml +7 -0
  82. package/server/scenarios/intermittent-500s.yaml +9 -0
  83. package/server/scenarios/lock-timeouts.yaml +12 -0
  84. package/server/scenarios/rate-limit-storm.yaml +10 -0
  85. package/server/scenarios/slow-stripe.yaml +9 -0
  86. package/server/scenarios/stripe-storm-shift.yaml +15 -0
  87. package/server/scenarios/tickets-storm.yaml +10 -0
  88. package/server/scenarios/webhook-chaos.yaml +7 -0
  89. package/server/seeds/acme-prod-library.json +40470 -0
  90. package/server/seeds/acme-prod-shift.json +36544 -0
  91. package/server/seeds/acme-prod.json +35412 -0
  92. package/server/seeds/saas-billing-small.json +4792 -0
  93. package/server/seeds/saas-billing-smoke.json +160 -0
@@ -0,0 +1,160 @@
1
+ {
2
+ "name": "saas-billing-smoke",
3
+ "version": 1,
4
+ "epoch": 1767225600,
5
+ "clock_mode": "manual",
6
+ "data": {
7
+ "customers": [
8
+ {
9
+ "id": "cus_smoke_ada",
10
+ "name": "Ada Lovelace",
11
+ "email": "ada@example.com",
12
+ "created_offset": 7776000
13
+ },
14
+ {
15
+ "id": "cus_smoke_bob",
16
+ "name": "Bob Bobberson",
17
+ "email": "bob@example.com",
18
+ "created_offset": 6912000
19
+ },
20
+ {
21
+ "id": "cus_smoke_cat",
22
+ "name": "Cat Catterly",
23
+ "email": "cat@example.com",
24
+ "created_offset": 6048000
25
+ },
26
+ {
27
+ "id": "cus_smoke_dan",
28
+ "name": "Dan Danvers",
29
+ "email": "dan@example.com",
30
+ "created_offset": 5184000
31
+ },
32
+ {
33
+ "id": "cus_smoke_eve",
34
+ "name": "Eve Everly",
35
+ "email": "eve@example.com",
36
+ "created_offset": 4320000
37
+ }
38
+ ],
39
+ "products": [
40
+ {
41
+ "id": "prod_seed_starter",
42
+ "name": "Starter Plan",
43
+ "description": "For small teams getting going."
44
+ },
45
+ {
46
+ "id": "prod_seed_pro",
47
+ "name": "Pro Plan",
48
+ "description": "For teams that ship."
49
+ },
50
+ {
51
+ "id": "prod_seed_ent",
52
+ "name": "Enterprise Plan",
53
+ "description": "For the big fish."
54
+ },
55
+ {
56
+ "id": "prod_seed_onboarding",
57
+ "name": "Onboarding Package",
58
+ "description": "One-time white-glove setup."
59
+ }
60
+ ],
61
+ "prices": [
62
+ {
63
+ "id": "price_seed_starter_m",
64
+ "product": "prod_seed_starter",
65
+ "unit_amount": 999,
66
+ "currency": "usd",
67
+ "nickname": "Starter monthly",
68
+ "recurring": {
69
+ "interval": "month",
70
+ "interval_count": 1
71
+ }
72
+ },
73
+ {
74
+ "id": "price_seed_pro_m",
75
+ "product": "prod_seed_pro",
76
+ "unit_amount": 4000,
77
+ "currency": "usd",
78
+ "nickname": "Pro monthly",
79
+ "recurring": {
80
+ "interval": "month",
81
+ "interval_count": 1
82
+ }
83
+ },
84
+ {
85
+ "id": "price_seed_ent_m",
86
+ "product": "prod_seed_ent",
87
+ "unit_amount": 19900,
88
+ "currency": "usd",
89
+ "nickname": "Enterprise monthly",
90
+ "recurring": {
91
+ "interval": "month",
92
+ "interval_count": 1
93
+ }
94
+ },
95
+ {
96
+ "id": "price_seed_onboarding",
97
+ "product": "prod_seed_onboarding",
98
+ "unit_amount": 15000,
99
+ "currency": "usd",
100
+ "nickname": "Onboarding one-time",
101
+ "recurring": null
102
+ }
103
+ ],
104
+ "invoices": [
105
+ {
106
+ "id": "in_smoke_draft",
107
+ "customer": "cus_smoke_ada",
108
+ "status": "draft",
109
+ "created_offset": 172800,
110
+ "lines": [
111
+ {
112
+ "description": "Pro Plan (monthly)",
113
+ "amount": 4000,
114
+ "price": "price_seed_pro_m"
115
+ }
116
+ ]
117
+ },
118
+ {
119
+ "id": "in_smoke_open",
120
+ "customer": "cus_smoke_bob",
121
+ "status": "open",
122
+ "created_offset": 432000,
123
+ "lines": [
124
+ {
125
+ "description": "Starter monthly",
126
+ "amount": 999,
127
+ "price": "price_seed_starter_m"
128
+ }
129
+ ]
130
+ },
131
+ {
132
+ "id": "in_smoke_paid",
133
+ "customer": "cus_smoke_cat",
134
+ "status": "paid",
135
+ "created_offset": 864000,
136
+ "lines": [
137
+ {
138
+ "description": "Pro Plan (monthly)",
139
+ "amount": 4000,
140
+ "price": "price_seed_pro_m"
141
+ }
142
+ ],
143
+ "charges": [
144
+ {
145
+ "id": "ch_smoke_paid"
146
+ }
147
+ ]
148
+ }
149
+ ],
150
+ "subscriptions": [
151
+ {
152
+ "id": "sub_smoke_eve",
153
+ "customer": "cus_smoke_eve",
154
+ "price": "price_seed_pro_m",
155
+ "created_offset": 3888000,
156
+ "current_period_start": 1766361600
157
+ }
158
+ ]
159
+ }
160
+ }