@postman/postman-plugin 0.5.0 → 0.6.0-rc.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.
- package/README.md +2 -2
- package/dist/hosts/factory.js +29 -3
- package/hooks/session-start-context.md +1 -1
- package/mcp.pi.json +2 -2
- package/package.json +1 -1
- package/skills/api-discovery/SKILL.md +7 -2
- package/skills/api-documentation/SKILL.md +2 -3
- package/skills/api-engineer/SKILL.md +13 -15
- package/skills/api-mocking/SKILL.md +4 -2
- package/skills/api-monitoring/SKILL.md +35 -25
- package/skills/api-simulation/SKILL.md +109 -74
- package/skills/api-simulation/reference/context_file.md +183 -149
- package/skills/api-simulation/reference/sim_yaml_schema.md +1 -1
- package/skills/api-testing/SKILL.md +3 -3
- package/skills/application-testing/SKILL.md +2 -2
- package/skills/ci-integration/SKILL.md +7 -5
- package/skills/cli-install/SKILL.md +29 -0
- package/skills/collection-schema-v3/SKILL.md +21 -11
- package/skills/collection-schema-v3/reference/environment.md +2 -0
- package/skills/collection-schema-v3/reference/globals.md +40 -0
- package/skills/collection-schema-v3/reference/http.md +149 -11
- package/skills/collection-schema-v3/reference/other_protocols.md +232 -86
- package/skills/datasets/SKILL.md +6 -5
- package/skills/datasets/reference/schema.md +51 -0
- package/skills/flows/SKILL.md +0 -1
- package/skills/performance-testing/SKILL.md +14 -1
- package/skills/performance-testing/references/gatling-import/README.md +141 -0
- package/skills/performance-testing/references/gatling-import/feeders.md +31 -0
- package/skills/performance-testing/references/gatling-import/injection.md +88 -0
- package/skills/performance-testing/references/gatling-import/mapping.md +91 -0
- package/skills/performance-testing/references/gatling-import/unsupported.md +31 -0
- package/skills/postman-mcp-server/SKILL.md +1 -1
- package/skills/variables/SKILL.md +2 -2
- package/skills/webhook-testing/SKILL.md +1 -1
- package/skills/workspaces/SKILL.md +53 -0
- package/skills/bootstrap/SKILL.md +0 -140
- package/skills/bootstrap/reference/cli_installation.md +0 -59
|
@@ -1,159 +1,193 @@
|
|
|
1
|
-
# `<name>.context.
|
|
1
|
+
# `<name>.context.yaml`
|
|
2
2
|
|
|
3
|
-
The handoff
|
|
4
|
-
gets `checkout.context.
|
|
5
|
-
`simulation create` and the Postman app write it from
|
|
3
|
+
The handoff record beside a simulation: `postman/simulations/checkout.sim.yaml`
|
|
4
|
+
gets `checkout.context.yaml`, and a foldered simulation keeps both in its folder.
|
|
5
|
+
`simulation create` and the Postman app write it from a fixed template,
|
|
6
6
|
`simulation update` renames it with the simulation, and `simulation delete`
|
|
7
|
-
removes it.
|
|
8
|
-
sessions learned.
|
|
7
|
+
removes it.
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
expect to find, so keep them.
|
|
9
|
+
**Update the existing record without discarding prior claims or evidence.**
|
|
10
|
+
Replacing it with a fresh template loses findings and unresolved assumptions
|
|
11
|
+
while looking complete.
|
|
14
12
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
It carries what is believed about the services this simulation stands in for,
|
|
14
|
+
and what each belief rests on. **api-simulation** is how a simulation is run,
|
|
15
|
+
read and judged — its commands running clean is not yet the work being done.
|
|
18
16
|
|
|
19
|
-
##
|
|
17
|
+
## Its shape
|
|
20
18
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
comment, so a half-filled file reads as half-filled instead of as fact.
|
|
19
|
+
The whole file is YAML under a fixed key schema. The key names and the `status`
|
|
20
|
+
vocabulary are fixed; the template carries each key's field schema in the
|
|
21
|
+
comments above it. A `null` is something nobody has established yet.
|
|
25
22
|
|
|
26
|
-
|
|
|
23
|
+
| Key | Holds |
|
|
27
24
|
| --- | --- |
|
|
28
|
-
|
|
|
29
|
-
|
|
|
30
|
-
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
## How a line carries its evidence
|
|
78
|
-
|
|
79
|
-
The log a claim came from isn't committed, so the line is all the next session
|
|
80
|
-
gets. Date every claim in `## Assumptions` and `## What didn't work`, and say
|
|
81
|
-
where it came from when a run didn't show it: `(observed 2026-10-22)` for what
|
|
82
|
-
a run established, `(reasoned 2026-10-22, src/payments/client.ts)` for what was
|
|
83
|
-
read rather than run.
|
|
84
|
-
|
|
85
|
-
A failure also carries the signature the next session will recognize it by —
|
|
86
|
-
the error text, the status, the member that sent it — since that is what
|
|
87
|
-
someone matches a new failure against. Quote the error itself, never a
|
|
88
|
-
response body. For the rest, name the committed file that holds it: the
|
|
89
|
-
handler that threw, the mock example captured from the real service, the test
|
|
90
|
-
that reproduces it. Not the run's log, which is wherever that run redirected
|
|
91
|
-
output and which the next run overwrites.
|
|
92
|
-
|
|
93
|
-
A good `## Assumptions` is a claim, its consequence and its date; a good
|
|
94
|
-
`## Observations` is a few lines; a good `## What didn't work` is one line per
|
|
95
|
-
failure:
|
|
96
|
-
|
|
97
|
-
```markdown
|
|
98
|
-
## Assumptions
|
|
99
|
-
|
|
100
|
-
- **`payments` treats a retried charge as idempotent on `Idempotency-Key`.**
|
|
101
|
-
If it doesn't, the retry path charges twice. Nobody has settled it and the
|
|
102
|
-
mock answers as though it does. (reasoned 2026-10-22, the mock's handler)
|
|
103
|
-
- **Redis holds no `EVENT_BATCH` key when a run starts.** A leftover one
|
|
104
|
-
crashes the aggregation flush before any request is sent. (observed
|
|
105
|
-
2026-10-22)
|
|
106
|
-
|
|
107
|
-
<!-- begin:observations -->
|
|
108
|
-
2026-10-22: every member served except `workspace`, which the service never
|
|
109
|
-
calls in development, and `god`, which models no endpoints.
|
|
110
|
-
2026-10-18: same, and `payments` served only `POST /charges`.
|
|
111
|
-
<!-- end:observations -->
|
|
112
|
-
|
|
113
|
-
## What didn't work
|
|
114
|
-
|
|
115
|
-
- 2026-10-22: the aggregation flush crashed on start —
|
|
116
|
-
`TypeError: batch.map is not a function` in `src/events/flush.ts`, from a
|
|
117
|
-
stale Redis `EVENT_BATCH` key an earlier run left behind. Not a simulation
|
|
118
|
-
error, so the log shows nothing.
|
|
119
|
-
- 2026-09-30: `payments` answered `501` for `POST /refunds` — the mock models
|
|
120
|
-
no refund path, so a run that reaches it proves nothing about refunds.
|
|
25
|
+
| `purpose` | `stands_in_for` and `unblocks` — what the simulation stands in for and what work it unblocks. Record the intended purpose when known and refine it as you learn, distinguishing intended outcomes from demonstrated results. The members it serves, their route keys and the hosts they answer for are in the `.sim.yaml` beside it. |
|
|
26
|
+
| `assumptions` | What the code relies on about a dependency's behaviour. One claim per entry: `id`, `status`, `claim`, `reason`, `verification`, `source`, `updated_at`. |
|
|
27
|
+
| `fingerprints` | What the claims were written against — `id`, `date`, `commit`, `cli`. |
|
|
28
|
+
|
|
29
|
+
Everything else about this simulation lives where it already is: the members and
|
|
30
|
+
their origins in the `.sim.yaml`, the handlers in `postman/mocks/`, and how to
|
|
31
|
+
run any of it in **api-simulation**. Use this record to connect those details
|
|
32
|
+
to the assumptions and findings a later session needs.
|
|
33
|
+
|
|
34
|
+
Keep an entry when it helps a later session make a decision without repeating
|
|
35
|
+
the investigation, even if supporting details already exist in the repo.
|
|
36
|
+
For routes, request shapes, auth or config, link the file that holds them and
|
|
37
|
+
record the conclusion, evidence and uncertainty relevant to the caller.
|
|
38
|
+
Avoid copying details that can drift, and keep credentials out of this
|
|
39
|
+
committed record.
|
|
40
|
+
|
|
41
|
+
## What an assumption is
|
|
42
|
+
|
|
43
|
+
A claim about how a dependency behaves, which the code under test relies on:
|
|
44
|
+
what the caller is taken to be, which plan or permission is assumed, the order
|
|
45
|
+
calls go in, what gets retried, the shape of the data. A mock answers these
|
|
46
|
+
whether or not anyone checked, so its answer is a belief your code now carries.
|
|
47
|
+
|
|
48
|
+
For example, checkout may retry a payment after a timeout without knowing
|
|
49
|
+
whether the first attempt charged the customer. This illustrative entry
|
|
50
|
+
records the provider assumption that makes that retry safe; the paths and
|
|
51
|
+
run reference are examples, not evidence from this repository.
|
|
52
|
+
|
|
53
|
+
```yaml
|
|
54
|
+
- id: payment-retry-does-not-double-charge
|
|
55
|
+
status: unknown
|
|
56
|
+
claim: Retrying a payment for the same unchanged cart with identical payment
|
|
57
|
+
details and the same idempotency key within 24 hours creates at most one
|
|
58
|
+
charge at the payment provider, even if the first response times out.
|
|
59
|
+
reason: Checkout relies on this guarantee to retry without double-charging
|
|
60
|
+
the customer. The stand-in deduplicates payments by key, but that behavior
|
|
61
|
+
was configured by us; a passing simulation does not establish the
|
|
62
|
+
provider's retention window or handling of a retry after a timeout.
|
|
63
|
+
verification: On 2026-10-28, ran the checkout timeout test. The stand-in
|
|
64
|
+
recorded a successful charge, then delayed its response past the caller's
|
|
65
|
+
timeout. Checkout retried with the same payment details and key, and the
|
|
66
|
+
stand-in returned the original payment ID with one charge in its state.
|
|
67
|
+
This demonstrates caller key reuse in this scenario. The provider's
|
|
68
|
+
idempotency contract has not been checked; confirm its scope and retention
|
|
69
|
+
window, including retries after an ambiguous outcome, before relying on
|
|
70
|
+
this assumption for real payments.
|
|
71
|
+
source: src/checkout/submit-payment.ts; postman/mocks/payments/handler.js;
|
|
72
|
+
tests/checkout/payment-timeout.test.ts; runs/cart-payment-timeout-001
|
|
73
|
+
updated_at: "2026-10-28"
|
|
121
74
|
```
|
|
122
75
|
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
76
|
+
One claim per entry. A sentence holding two claims is two entries, because
|
|
77
|
+
evidence can settle one and leave the other standing.
|
|
78
|
+
|
|
79
|
+
### `status`
|
|
80
|
+
|
|
81
|
+
| Value | Means | For example |
|
|
82
|
+
| --- | --- | --- |
|
|
83
|
+
| `supported` | Evidence supports the claim, within a stated scope. | The provider guarantees idempotency for 24 hours. |
|
|
84
|
+
| `contradicted` | Evidence provides a counterexample. | A timed-out request did create an order. |
|
|
85
|
+
| `unknown` | Available evidence cannot establish or reject it. | Key scope across token refresh is unspecified. |
|
|
86
|
+
| `conflicting` | Applicable sources disagree. | Documentation promises immediate revocation; a real probe observes continued access. |
|
|
87
|
+
|
|
88
|
+
`supported` is the one to be careful with: support comes with a scope, so the
|
|
89
|
+
claim says what that scope is. Name the operation, relevant conditions and
|
|
90
|
+
window the evidence covers. Narrow an overbroad claim before marking it
|
|
91
|
+
`supported`; a check at one point in a window does not establish behavior
|
|
92
|
+
throughout it.
|
|
93
|
+
|
|
94
|
+
`contradicted` and `conflicting` are findings to report, not states to route
|
|
95
|
+
around. A contradiction says the code relies on something untrue; a conflict
|
|
96
|
+
says two sources disagree and nobody has settled which governs — often a
|
|
97
|
+
contract promising one thing while the running service does another.
|
|
98
|
+
|
|
99
|
+
### `reason`, `verification` and `source`
|
|
100
|
+
|
|
101
|
+
Three different jobs, and keeping them apart is what makes a claim checkable.
|
|
102
|
+
|
|
103
|
+
`reason` is the judgment: why the evidence adds up to this status. It is the
|
|
104
|
+
field that earns its place on a `conflicting` or `unknown` claim, where the
|
|
105
|
+
status alone does not say what is unresolved.
|
|
106
|
+
|
|
107
|
+
`verification` is what was actually done and what it showed — a contract read,
|
|
108
|
+
a request made and its response, a handler inspected. Include when the
|
|
109
|
+
verification occurred and the revision or environment it covered, using a
|
|
110
|
+
fingerprint entry where applicable. Name what is still
|
|
111
|
+
planned or blocked and what would settle it, and say when a piece of evidence
|
|
112
|
+
has gone stale and why, since stale evidence stays as history but cannot
|
|
113
|
+
establish a current status.
|
|
114
|
+
|
|
115
|
+
Match the claim to the kind of evidence. A mock handler shows what the
|
|
116
|
+
stand-in models; a simulated run shows how the caller behaved under that
|
|
117
|
+
model. Neither independently establishes the real dependency's behavior.
|
|
118
|
+
Use provider evidence for that: distinguish a published contract's promise
|
|
119
|
+
from behavior observed against the real service, and retain the conditions
|
|
120
|
+
and scope of each. If only the mock supports a provider assumption, that
|
|
121
|
+
assumption remains `unknown` even when the caller test passes.
|
|
122
|
+
|
|
123
|
+
`source` is where to go and re-check it, so the next session can audit the
|
|
124
|
+
claim rather than take it on trust. Any of:
|
|
125
|
+
|
|
126
|
+
- a file and line range in this repo, where the code shows what it relies on;
|
|
127
|
+
- a request that was actually made and what came back — the target environment
|
|
128
|
+
(stand-in or real service), sequence and status codes, with a retrievable
|
|
129
|
+
test or run reference where available;
|
|
130
|
+
- the dependency's own code, or its published contract, read for the endpoint
|
|
131
|
+
in question.
|
|
132
|
+
|
|
133
|
+
A claim is only as good as what it points at, so `source` carries the specific
|
|
134
|
+
thing, not its category: `api/policies/hasAccess.js:12-115` rather than "read
|
|
135
|
+
the code". A claim with nothing to point at is `unknown`.
|
|
136
|
+
|
|
137
|
+
Where two sources disagree, `verification` says what each one showed and
|
|
138
|
+
`status` is `conflicting` — that is the state a contract promising one thing
|
|
139
|
+
while the running service does another belongs in.
|
|
140
|
+
|
|
141
|
+
### `updated_at`
|
|
142
|
+
|
|
143
|
+
The day the entry was last written, `YYYY-MM-DD`. Set it when you add a claim,
|
|
144
|
+
and set it again whenever you change one — a new status, a fresh piece of
|
|
145
|
+
verification, a reworded claim.
|
|
146
|
+
|
|
147
|
+
This date tracks record maintenance. Rewording a claim does not refresh its
|
|
148
|
+
evidence: judge that from the date, revision and environment in `verification`
|
|
149
|
+
and its referenced fingerprint. Re-check when relevant behavior or conditions
|
|
150
|
+
have changed, or when the evidence's applicability is unclear.
|
|
151
|
+
|
|
152
|
+
Nothing enforces this. `simulation create` writes an empty list and no command
|
|
153
|
+
edits entries, so the field is only as true as the session that last wrote it.
|
|
154
|
+
|
|
155
|
+
## Where claims come from
|
|
156
|
+
|
|
157
|
+
Evidence first, claim second. Make the run or read the code, then write down
|
|
158
|
+
what it establishes — including the parts nobody had written down before, which
|
|
159
|
+
are the valuable half: a call order you did not expect, a dependency answering
|
|
160
|
+
something the code does not handle, a member never called at all.
|
|
161
|
+
|
|
162
|
+
Going the other way — writing the claim and then looking for something to back
|
|
163
|
+
it — is how a guess ends up marked `supported`. A claim written ahead of any
|
|
164
|
+
evidence is fine; it is `unknown` until something points at it.
|
|
165
|
+
|
|
166
|
+
## Fingerprints
|
|
167
|
+
|
|
168
|
+
What the claims were written against: `git rev-parse HEAD` and
|
|
169
|
+
`postman --version`. Append an entry when either differs, and say so when the
|
|
170
|
+
tree is dirty — a sha alone reads as a clean checkout.
|
|
171
|
+
|
|
172
|
+
Tie each verification to the fingerprint it used. Appending a new fingerprint
|
|
173
|
+
does not revalidate older claims. A changed commit or CLI is a reason to
|
|
174
|
+
assess whether relevant behavior changed; it does not by itself invalidate
|
|
175
|
+
all prior evidence.
|
|
176
|
+
|
|
177
|
+
## Reading it before you start
|
|
178
|
+
|
|
179
|
+
Read the claims relevant to the task before repeating dependency research.
|
|
180
|
+
Compare their scope and evidence with the code, configuration and provider
|
|
181
|
+
conditions your work depends on. Reuse findings that still apply, and inspect
|
|
182
|
+
the code you are changing to identify assumptions the change may affect.
|
|
183
|
+
|
|
184
|
+
Treat `supported` as conditional on that applicability, not as a permanent
|
|
185
|
+
guarantee. Revisit affected claims when relevant conditions change or their
|
|
186
|
+
evidence no longer establishes the current behavior. If current support is
|
|
187
|
+
unresolved, mark the claim `unknown` and preserve the prior evidence with the
|
|
188
|
+
reason it no longer settles the question. An `unknown` or `conflicting` claim
|
|
189
|
+
is worth investigating when the task depends on it; record what would settle
|
|
190
|
+
it if verification remains blocked.
|
|
191
|
+
|
|
192
|
+
Preserve unrelated claims and their history. A claim not exercised in this
|
|
193
|
+
session is not thereby contradicted or stale.
|
|
@@ -26,7 +26,7 @@ since the file is what declares the hostnames.
|
|
|
26
26
|
`simulation create` writes each `path:` relative to the repository root, the
|
|
27
27
|
directory holding `postman/`, and puts the simulation in a folder of its own
|
|
28
28
|
(`postman/simulations/checkout-dev/checkout-dev.sim.yaml`) so its
|
|
29
|
-
`<name>.context.
|
|
29
|
+
`<name>.context.yaml` sits beside it; the app records that document in a
|
|
30
30
|
`context:` ref. Reading is broader than writing — a path relative to
|
|
31
31
|
`postman/simulations/`, to the file, absolute or `~/`, naming the folder or
|
|
32
32
|
the manifest inside it, all resolve — and an unresolvable one names every
|
|
@@ -45,9 +45,9 @@ guarantee; a successful HTTP exchange alone does not establish correctness.
|
|
|
45
45
|
without validating it. Results are recorded in the connected workspace by
|
|
46
46
|
default; `--report-events=false` keeps the run local when required.
|
|
47
47
|
|
|
48
|
-
Use command-specific `-h` for supported options
|
|
49
|
-
CLI
|
|
50
|
-
|
|
48
|
+
Use command-specific `-h` for supported options. Workspace resources need a
|
|
49
|
+
signed-in CLI; a bare URL or local collection does not require a workspace
|
|
50
|
+
binding.
|
|
51
51
|
|
|
52
52
|
## Verification
|
|
53
53
|
|
|
@@ -44,7 +44,7 @@ If this run does not need to publish results (local debugging, dry run), authent
|
|
|
44
44
|
|
|
45
45
|
Publishing to Application Inventory requires a workspace binding. Check `.postman/resources.yaml` for a `workspace.id`. Reason about whether publishing is actually needed for this task before treating a missing workspace as a blocker:
|
|
46
46
|
|
|
47
|
-
- If publishing is needed and the workspace is missing, load the `
|
|
47
|
+
- If publishing is needed and the workspace is missing, load the `workspaces` skill to set it up. In a non-interactive context this must be done locally first, then `.postman/resources.yaml` committed.
|
|
48
48
|
- If publishing is not needed, pass `--report-events false` and proceed.
|
|
49
49
|
|
|
50
50
|
### Capture plugin
|
|
@@ -106,7 +106,7 @@ A **target** is a named set of collections + optional environment. The `default`
|
|
|
106
106
|
```bash
|
|
107
107
|
postman --version
|
|
108
108
|
```
|
|
109
|
-
This skill targets the latest CLI release. If the version is outdated,
|
|
109
|
+
This skill targets the latest CLI release. If the version is outdated, update the CLI, then re-run. The `--help` output for each command shows the flags actually available in the installed version.
|
|
110
110
|
|
|
111
111
|
Read the CLI error output first — it names the specific failure and what to fix.
|
|
112
112
|
|
|
@@ -38,10 +38,12 @@ the author's own passing tests do not establish cross-service compatibility.
|
|
|
38
38
|
not make the command read-only.
|
|
39
39
|
4. Authenticate only jobs that need workspace resources. Use the CI secret
|
|
40
40
|
store to supply `POSTMAN_API_KEY`, then
|
|
41
|
-
`postman login --with-api-key "$POSTMAN_API_KEY"`. A local-only gate
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
41
|
+
`postman login --with-api-key "$POSTMAN_API_KEY"`. A local-only gate can
|
|
42
|
+
run without it, but its run results are then lost: they stay in that job's
|
|
43
|
+
log instead of reaching the workspace, where teammates and later agent
|
|
44
|
+
sessions read them as evidence. Command-specific API-key flags are not a general replacement
|
|
45
|
+
for login across lint and push operations. Use **workspaces** for
|
|
46
|
+
unresolved bindings, and **variables** for request credentials.
|
|
45
47
|
5. Publish only the reviewed branch after its merge checks pass.
|
|
46
48
|
`postman workspace push -y` changes shared context; a PR-triggered push
|
|
47
49
|
would publish an unmerged contract. The normal prepare phase assigns IDs
|
|
@@ -51,7 +53,7 @@ the author's own passing tests do not establish cross-service compatibility.
|
|
|
51
53
|
6. Use the default create/update strategy unless exact mirroring is the
|
|
52
54
|
explicit requirement. `--push-strategy force-sync` can delete workspace
|
|
53
55
|
entities absent from the checkout, including resources managed elsewhere.
|
|
54
|
-
|
|
56
|
+
Preview that push's diff and get its deletions approved before enabling it.
|
|
55
57
|
|
|
56
58
|
## Verification
|
|
57
59
|
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: cli-install
|
|
3
|
+
description: Use when the Postman CLI is missing or can't be installed, or when `postman` is "command not found". Installs the CLI globally so `postman` is on `PATH`, with a fallback to the hosted MCP server when installing is blocked. Use for requests such as "install the Postman CLI".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Install the Postman CLI
|
|
7
|
+
|
|
8
|
+
Install it globally so `postman` is on `PATH`. If installing is blocked, use
|
|
9
|
+
**postman-mcp-server** for hosted operations.
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
# npm, any platform with Node
|
|
13
|
+
npm install -g postman-cli
|
|
14
|
+
|
|
15
|
+
# macOS, Linux, and WSL
|
|
16
|
+
curl -o- "https://dl-cli.pstmn.io/install/unix.sh" | sh
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
```powershell
|
|
20
|
+
# Windows
|
|
21
|
+
powershell.exe -NoProfile -InputFormat None -ExecutionPolicy AllSigned -Command "[System.Net.ServicePointManager]::SecurityProtocol = 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://dl-cli.pstmn.io/install/win64.ps1'))"
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## Verification
|
|
25
|
+
|
|
26
|
+
Report the installed version and the route it came from, and confirm `postman`
|
|
27
|
+
on `PATH` resolves to that copy.
|
|
28
|
+
|
|
29
|
+
Source: https://learning.postman.com/docs/postman-cli/postman-cli-installation/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: collection-schema-v3
|
|
3
|
-
description: Use when writing or debugging local Postman v3 collection
|
|
3
|
+
description: Use when writing or debugging local Postman v3 collection, environment or globals files, including collection lint failures. Preserves the per-entity files, inherited context, and schema shapes that make API changes reusable and reviewable in Git. Use for requests such as "fix this request YAML".
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Collection Schema (v3, Git-Native)
|
|
@@ -19,12 +19,14 @@ checks, without regenerating a single large collection export.
|
|
|
19
19
|
Collection/folder definitions supply shared context; copying every inherited
|
|
20
20
|
field into each request creates competing values and noisy future edits.
|
|
21
21
|
See **variables** when deciding the scope of a value or secret reference.
|
|
22
|
-
3.
|
|
23
|
-
|
|
24
|
-
[
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
22
|
+
3. Consult the reference section for the entity being changed:
|
|
23
|
+
[HTTP requests, examples, and definitions](reference/http.md),
|
|
24
|
+
[environment files](reference/environment.md), or
|
|
25
|
+
[other protocols](reference/other_protocols.md).
|
|
26
|
+
Protocols have different URL, body, script, and settings shapes; an HTTP
|
|
27
|
+
field is not necessarily valid on another request kind.
|
|
28
|
+
For globals files, use the [globals reference](reference/globals.md).
|
|
29
|
+
Dataset YAML belongs to **datasets**; mocks belong to **api-mocking**.
|
|
28
30
|
4. Preserve types at the YAML boundary. Quote `{{variables}}` and strings that
|
|
29
31
|
resemble booleans or numbers; JSON bodies are string content, best expressed
|
|
30
32
|
with block scalars. A syntactically valid YAML object can still be the wrong
|
|
@@ -43,7 +45,15 @@ checks, without regenerating a single large collection export.
|
|
|
43
45
|
## Verification
|
|
44
46
|
|
|
45
47
|
Run `postman collection lint <collection-path>` for collection changes and
|
|
46
|
-
`postman environment lint <path>` for environment changes.
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
`postman environment lint <path>` for environment changes. Review warnings as
|
|
49
|
+
well as errors: an ignored field can change behavior even when parsing succeeds.
|
|
50
|
+
Use `postman workspace lint` when checking relationships across entities or
|
|
51
|
+
workspace manifest mappings.
|
|
52
|
+
|
|
53
|
+
Inspect the diff for unintended scope changes. When execution is appropriate,
|
|
54
|
+
run the changed request through its collection to check inherited context.
|
|
55
|
+
For script changes, check that the changed script executed and produced its
|
|
56
|
+
intended effect; compare assertion counts with the assertions expected for that
|
|
57
|
+
run. A setup script may intentionally have none, and unrelated passing assertions
|
|
58
|
+
do not prove the changed script worked. Report structural validation separately
|
|
59
|
+
from behavior verified against a target.
|
|
@@ -36,6 +36,8 @@ An environment is one YAML file named `<name>.environment.yaml` under
|
|
|
36
36
|
- `enabled` — boolean. The CLI writes `true` for a newly set variable.
|
|
37
37
|
- `type` — optional string. Use `default` for ordinary values and `secret`
|
|
38
38
|
for sensitive values.
|
|
39
|
+
- `secret` — optional boolean; `secret: true` alongside `type: default` is
|
|
40
|
+
also a recognised way to mark a secret.
|
|
39
41
|
- `description` — optional string.
|
|
40
42
|
|
|
41
43
|
Do not add collection-only fields such as `$kind`, `scripts`, `auth`, or
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Globals
|
|
2
|
+
|
|
3
|
+
A globals file is named `<name>.globals.yaml` under `postman/globals/`.
|
|
4
|
+
It has no `$kind` discriminator.
|
|
5
|
+
|
|
6
|
+
## Fields
|
|
7
|
+
|
|
8
|
+
- `name` — required string, conventionally `Globals`.
|
|
9
|
+
- `values` — required array; `values: []` represents no globals.
|
|
10
|
+
- Each value has:
|
|
11
|
+
- `key` — required variable name.
|
|
12
|
+
- `value` — required string. Quote numeric- or boolean-looking strings
|
|
13
|
+
and `{{variables}}` so YAML preserves their type.
|
|
14
|
+
- `enabled` — boolean.
|
|
15
|
+
- `type` — optional string: `default` or `secret`.
|
|
16
|
+
- `secret` — optional boolean; `secret: true` alongside `type: default`
|
|
17
|
+
also marks a secret.
|
|
18
|
+
- `description` — optional string.
|
|
19
|
+
|
|
20
|
+
## Example
|
|
21
|
+
|
|
22
|
+
```yaml
|
|
23
|
+
name: Globals
|
|
24
|
+
values:
|
|
25
|
+
- key: base_url
|
|
26
|
+
value: 'https://api.example.com'
|
|
27
|
+
enabled: true
|
|
28
|
+
type: default
|
|
29
|
+
- key: api_token
|
|
30
|
+
value: ''
|
|
31
|
+
enabled: false
|
|
32
|
+
type: secret
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Marking a value as secret does not make a literal credential safe to commit.
|
|
36
|
+
Keep reusable examples free of credentials; see **variables** for secret sources.
|
|
37
|
+
|
|
38
|
+
Validate with `postman globals lint <file>`. This checks structure, not whether
|
|
39
|
+
requests resolve the intended values; check scope and overrides when diagnosing
|
|
40
|
+
unexpected runtime values.
|