Skip to content

GetParametersByPath

Source: src/AWS/SSM/GetParametersByPath.ts

Runtime binding for ssm:GetParametersByPath.

Bind this operation to a Parameter with a hierarchical name (e.g. /my-app/config) to get a callable that reads every parameter stored under that name — the bound parameter acts as the subtree root. The binding grants ssm:GetParametersByPath on the parameter’s ARN and its /* subtree wildcard, plus kms:Decrypt on the bound parameter’s encryption key so WithDecryption: true works for SecureString children encrypted with the same key.

const root = yield* SSM.Parameter("ConfigRoot", {
name: "/my-app/config",
value: "v1",
});
const getByPath = yield* SSM.GetParametersByPath(root);
// returns /my-app/config/db-url, /my-app/config/flags/beta, …
const result = yield* getByPath({ Recursive: true });