@nullplatform/mcp 0.1.6 → 0.1.8

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 (47) hide show
  1. package/dist/i18n.js +599 -24
  2. package/dist/np/client.js +3 -0
  3. package/dist/np/journey.js +236 -24
  4. package/dist/tool-names.js +7 -0
  5. package/dist/tools/action-flow.js +94 -0
  6. package/dist/tools/approvals.js +2 -2
  7. package/dist/tools/builds.js +23 -6
  8. package/dist/tools/create-app.js +37 -9
  9. package/dist/tools/create-link.js +163 -0
  10. package/dist/tools/create-service.js +149 -0
  11. package/dist/tools/delete-flow.js +30 -0
  12. package/dist/tools/delete-link.js +95 -0
  13. package/dist/tools/delete-param.js +76 -0
  14. package/dist/tools/delete-service.js +108 -0
  15. package/dist/tools/deployments.js +2 -2
  16. package/dist/tools/index.js +14 -0
  17. package/dist/tools/logs.js +2 -2
  18. package/dist/tools/metrics.js +4 -1
  19. package/dist/tools/overview.js +2 -2
  20. package/dist/tools/params.js +78 -17
  21. package/dist/tools/playbook.js +2 -1
  22. package/dist/tools/releases.js +2 -2
  23. package/dist/tools/services.js +2 -2
  24. package/dist/tools/set-params.js +61 -11
  25. package/dist/tools/shared.js +4 -0
  26. package/dist/tools/update-link.js +87 -0
  27. package/dist/tools/update-service.js +92 -0
  28. package/dist/ui.js +4 -1
  29. package/package.json +3 -1
  30. package/skills/starting-a-new-app/SKILL.md +84 -0
  31. package/widgets-dist/approvals.html +261 -57
  32. package/widgets-dist/builds.html +261 -57
  33. package/widgets-dist/create-app.html +257 -53
  34. package/widgets-dist/deployments.html +251 -47
  35. package/widgets-dist/find-apps.html +257 -53
  36. package/widgets-dist/logs.html +256 -52
  37. package/widgets-dist/manifest.json +16 -13
  38. package/widgets-dist/metrics.html +261 -57
  39. package/widgets-dist/np-panel.html +257 -53
  40. package/widgets-dist/overview.html +257 -53
  41. package/widgets-dist/params.html +261 -57
  42. package/widgets-dist/releases.html +257 -53
  43. package/widgets-dist/service-action.html +1118 -0
  44. package/widgets-dist/service-create.html +1117 -0
  45. package/widgets-dist/{playbook.html → service-delete.html} +258 -58
  46. package/widgets-dist/service-link.html +1117 -0
  47. package/widgets-dist/services.html +256 -52
@@ -0,0 +1,84 @@
1
+ ---
2
+ name: starting-a-new-app
3
+ description: Use when standing up something NEW on nullplatform — a new application (or a small set, e.g. a frontend and its API), choosing where it lives, wiring its data dependencies, and getting it to a first running deploy before any features are built. The greenfield counterpart to working-from-a-ticket.
4
+ ---
5
+
6
+ # Starting a new app on nullplatform
7
+
8
+ nullplatform owns the *platform* half — where the app lives, how it ships, what it depends on.
9
+ The code is your own craft. This playbook carries a new thing from a request to its first running
10
+ deploy with its dependencies wired, then hands the feature-building back to you. Do it in order:
11
+ each step de-risks the next. Standing up the skeleton and *then* coding beats coding against a
12
+ platform you haven't proven yet.
13
+
14
+ ## 1. Place it before you create it
15
+
16
+ An app lives in an **account + namespace** pair — `application_create` opens a pre-filled form, but
17
+ *where* it goes is a real decision, not a default. Read the request for the home it implies (a demo
18
+ for a banking client in Argentina is not the same namespace as a throwaway) and pick the best-fitting
19
+ pair from that context rather than the first on the list; pass `account` to disambiguate when a
20
+ namespace name repeats across accounts, and `namespace`/`namespace_id` for the namespace. Confirm the
21
+ choice for anything that isn't obviously disposable, and never drop it in the default namespace
22
+ without checking it fits. New repo vs. importing an existing one is the other fork the form covers;
23
+ it derives the repo URL for new ones.
24
+
25
+ For a **new** repo the form also offers scaffolding **templates** — read them and pick the best fit
26
+ for the stack (a React/SPA template for a UI, a Node/Express template for an API). If none fits
27
+ cleanly, say so and offer the closest, or fall back to importing an existing repo — don't force a
28
+ mismatched template. (Importing skips the template entirely: you bring a repo you already have.)
29
+
30
+ A request often implies **more than one app** (a frontend *and* its API). Create them one at a time
31
+ in the same namespace, named so the pair reads as a set — there is no batch-create, and that's fine:
32
+ two focused creates are clearer than one opaque one.
33
+
34
+ ## 2. Get it running before you build on it
35
+
36
+ Deploy the boilerplate to a real scope *first*, so the next step is "add features to a running app,"
37
+ not "debug the platform and my code at once." Create the target environment with
38
+ `managing-environments`, then ship the skeleton with `deploying-safely` (first-ever-deploy semantics
39
+ live there). Real environments are usually **policy-gated** — a production scope or deploy may land
40
+ in `creating_approval`; that's normal, surface it and don't fight it, keep moving on what isn't gated.
41
+
42
+ ## 3. Wire the data it needs
43
+
44
+ A new product usually needs a dependency — a SQL database, a queue, a cache. `application_service_list`
45
+ shows what's already attached and the catalog available; `application_service_create` provisions one
46
+ and autolinks it. Provisioning creates **real cloud resources (cost-bearing)** and runs
47
+ asynchronously, so it is **form-first**: call it to open the form, let the user fill the parameters
48
+ and submit (the submit is the cost confirmation) — never pass `provision:true` unprompted. Target the
49
+ link at the scope that needs the data. Don't call it "ready" until the service is active and linked.
50
+
51
+ Once a service is linked, its connection details arrive **automatically as read-only parameters**
52
+ (`DATABASE_URL`, host, credentials — secrets masked). Your code reads those env vars; you never
53
+ hard-code them or re-create them by hand. New parameters only reach a running scope on the **next
54
+ deploy**.
55
+
56
+ ## 4. Pull the repo, then build
57
+
58
+ A new-from-template app is a fresh **remote** repo you've never cloned — so the move is forward, not
59
+ backwards: **clone it into a folder and continue the work there**, rather than writing code first and
60
+ retrofitting it onto the platform. (An imported app is already local; nothing to clone.) The create
61
+ reply carries the repo URL; clone it, and if the request implied a pair (a frontend *and* its API),
62
+ clone each into its own folder.
63
+
64
+ Then the code is your own craft — writing the REST API, the UI, the schema or its codegen is not this
65
+ playbook's job (same boundary as `working-from-a-ticket`). Build against the injected env vars, keep
66
+ the work on a branch with the issue key (`tracing-a-change`), push so CI produces a build, and ship
67
+ it with `deploying-safely`.
68
+
69
+ ## 5. Configure and redeploy
70
+
71
+ App-level config the code expects — a page-size cap, feature flags — is a parameter, not a code
72
+ constant: set it with `application_parameter_create` (`configuring-safely` for targeting at app vs.
73
+ scope vs. dimension). Remember values apply on the **next** deploy, so redeploy to pick them up.
74
+
75
+ ## Don'ts
76
+
77
+ - Don't drop a new app in the default namespace without checking it fits the request.
78
+ - Don't write feature code before the boilerplate has a running deploy — prove the platform first.
79
+ - Don't re-create or hard-code connection details a service link already injects — read them as
80
+ parameters (they're `read_only`).
81
+ - Don't treat provisioning as instant — it's async and costs money; confirm before, and don't mark
82
+ data "ready" until the service is active, linked, and a redeploy has surfaced its params.
83
+ - Don't block the whole product on one approval — production gates are routine; surface them and
84
+ keep moving on everything that isn't gated.