@blinkhost/cli 2.2.0 → 2.3.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 CHANGED
@@ -7,7 +7,7 @@ The BlinkHost CLI brings project setup, local development, source control, previ
7
7
  Node.js 22.12 or newer is required.
8
8
 
9
9
  ```bash
10
- npm install --global @blinkhost/cli@2.2.0
10
+ npm install --global @blinkhost/cli@2.3.0
11
11
  blinkhost --version
12
12
  ```
13
13
 
@@ -107,6 +107,7 @@ Connected repository, release, approval, agency handoff, enterprise policy, and
107
107
  Manage beta event, schedule, and background triggers without using raw API routes:
108
108
 
109
109
  ```bash
110
+ blinkhost functions status [PROJECT_ID]
110
111
  blinkhost functions triggers list MODULE_ID
111
112
  blinkhost functions triggers create MODULE_ID --data @trigger.json
112
113
  blinkhost functions invoke run MODULE_ID TRIGGER_ID --data @payload.json --idempotency-key order-1042
@@ -117,7 +118,7 @@ blinkhost functions invocations cancel MODULE_ID INVOCATION_ID
117
118
  blinkhost functions invocations retry MODULE_ID INVOCATION_ID --idempotency-key retry-order-1042
118
119
  ```
119
120
 
120
- Payloads must be JSON objects no larger than 256 KiB. Use a stable idempotency key when repeating the same logical request. Runs remain subject to workspace roles, rollout availability, verified artifacts, runtime policy, and plan limits.
121
+ `functions status` reports the effective language and trigger capabilities for a project; omit the project ID inside a linked directory. Payloads must be JSON objects no larger than 256 KiB. Use a stable idempotency key when repeating the same logical request. Runs remain subject to workspace roles, rollout availability, verified artifacts, runtime policy, and plan limits.
121
122
 
122
123
  ## Secrets and resources
123
124
 
@@ -177,7 +178,7 @@ Pin or roll back explicitly with `npm install --global @blinkhost/cli@VERSION`.
177
178
  ```bash
178
179
  cosign verify-blob \
179
180
  --bundle SHA256SUMS.sigstore.json \
180
- --certificate-identity "https://github.com/blinkhost-ltd/blinkhost-cli/.github/workflows/release.yml@refs/tags/v2.2.0" \
181
+ --certificate-identity "https://github.com/blinkhost-ltd/blinkhost-cli/.github/workflows/release.yml@refs/tags/v2.3.0" \
181
182
  --certificate-oidc-issuer https://token.actions.githubusercontent.com \
182
183
  SHA256SUMS
183
184
  ```
package/dist/guidance.js CHANGED
@@ -82,9 +82,9 @@ const TOPICS = {
82
82
  modules: resource('modules', 'Manage Rust, Go, Python, JavaScript and TypeScript Functions.'),
83
83
  functions: {
84
84
  name: 'functions', title: 'Function triggers and runs', summary: 'Manage beta event, schedule and background triggers with explicit retry and idempotency controls.',
85
- usage: ['blinkhost functions triggers list MODULE_ID', 'blinkhost functions triggers create MODULE_ID --data @trigger.json', 'blinkhost functions triggers update MODULE_ID TRIGGER_ID --data @trigger.json', 'blinkhost functions triggers delete MODULE_ID TRIGGER_ID --confirm TRIGGER_ID', 'blinkhost functions invoke run MODULE_ID TRIGGER_ID --data @payload.json [--idempotency-key KEY]', 'blinkhost functions invocations list MODULE_ID', 'blinkhost functions invocations get|result|cancel MODULE_ID INVOCATION_ID', 'blinkhost functions invocations retry MODULE_ID INVOCATION_ID [--idempotency-key KEY]'],
85
+ usage: ['blinkhost functions status [PROJECT_ID]', 'blinkhost functions triggers list MODULE_ID', 'blinkhost functions triggers create MODULE_ID --data @trigger.json', 'blinkhost functions triggers update MODULE_ID TRIGGER_ID --data @trigger.json', 'blinkhost functions triggers delete MODULE_ID TRIGGER_ID --confirm TRIGGER_ID', 'blinkhost functions invoke run MODULE_ID TRIGGER_ID --data @payload.json [--idempotency-key KEY]', 'blinkhost functions invocations list MODULE_ID', 'blinkhost functions invocations get|result|cancel MODULE_ID INVOCATION_ID', 'blinkhost functions invocations retry MODULE_ID INVOCATION_ID [--idempotency-key KEY]'],
86
86
  details: ['Event, schedule and background triggers are beta capabilities and may be enabled progressively by workspace. Workspace roles, runtime policy, verified artifacts, plan limits and the service rollout gate remain authoritative.', 'Payloads must be JSON objects no larger than 256 KiB. Results are bounded by the service. Use a stable idempotency key when repeating the same logical request; otherwise the CLI generates one for each submission.', 'Delivery is at least once. Handlers that can create duplicate writes, messages or charges must be idempotent. Cancellation cannot undo application work that has already completed.'],
87
- examples: ['blinkhost functions triggers list MODULE_ID --json', 'blinkhost functions invoke run MODULE_ID TRIGGER_ID --data @payload.json --idempotency-key order-1042 --json'], related: ['modules', 'automation', 'limits', 'troubleshooting'], url: DOCUMENTATION_URL,
87
+ examples: ['blinkhost functions status PROJECT_ID --json', 'blinkhost functions triggers list MODULE_ID --json', 'blinkhost functions invoke run MODULE_ID TRIGGER_ID --data @payload.json --idempotency-key order-1042 --json'], related: ['modules', 'automation', 'limits', 'troubleshooting'], url: DOCUMENTATION_URL,
88
88
  },
89
89
  databases: resource('databases', 'Manage database resources.', ['Database list, get, create, update, delete and supported server actions are remote and may require plan capacity or protected-environment approval.', 'The CLI does not invent local backup, restore, credential-rotation or migration semantics. Use only actions returned by the active workspace API and consult the detailed database guide before production data changes. Deletion retains exact-ID confirmation and server authorization.']),
90
90
  bindings: resource('bindings', 'Manage explicit application-to-resource bindings.'),
package/dist/remote.js CHANGED
@@ -150,6 +150,19 @@ export async function runRemote(group, input, profile) {
150
150
  export async function runFunctions(input, profile) {
151
151
  const args = [...input];
152
152
  const resource = args.shift();
153
+ if (resource === 'status') {
154
+ let project = args.shift();
155
+ let selectedProfile = profile;
156
+ if (!project) {
157
+ const link = await readProjectLink();
158
+ project = link.project_id;
159
+ selectedProfile ||= link.profile;
160
+ }
161
+ const projectId = safeIdentifier(project, 'Project ID');
162
+ noExtra(args);
163
+ const client = await ApiClient.create(selectedProfile);
164
+ return client.request(`/api/backend-modules/rollout-status/?site_id=${projectId}`);
165
+ }
153
166
  const action = args.shift() || 'list';
154
167
  const moduleId = safeIdentifier(args.shift(), 'Module ID');
155
168
  const client = await ApiClient.create(profile);
@@ -217,7 +230,7 @@ export async function runFunctions(input, profile) {
217
230
  }
218
231
  throw new CliError(`Unknown invocation action: ${action}.`, EXIT.usage, 'unknown_action');
219
232
  }
220
- throw new CliError('Use `functions triggers`, `functions invoke`, or `functions invocations`.', EXIT.usage, 'invalid_function_command');
233
+ throw new CliError('Use `functions status`, `functions triggers`, `functions invoke`, or `functions invocations`.', EXIT.usage, 'invalid_function_command');
221
234
  }
222
235
  export async function writeProjectLink(projectId, profile, root) {
223
236
  safeIdentifier(projectId, 'Project ID');
package/dist/version.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export declare const VERSION = "2.2.0";
1
+ export declare const VERSION = "2.3.0";
2
2
  export declare const DOCUMENTATION_URL = "https://app.blinkhost.me/docs/source-control/cli";
3
3
  export declare const RELEASES_URL = "https://github.com/blinkhost-ltd/blinkhost-cli/releases";
4
4
  export declare function supportedNodeVersion(version?: string): boolean;
package/dist/version.js CHANGED
@@ -1,4 +1,4 @@
1
- export const VERSION = '2.2.0';
1
+ export const VERSION = '2.3.0';
2
2
  export const DOCUMENTATION_URL = 'https://app.blinkhost.me/docs/source-control/cli';
3
3
  export const RELEASES_URL = 'https://github.com/blinkhost-ltd/blinkhost-cli/releases';
4
4
  export function supportedNodeVersion(version = process.versions.node) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blinkhost/cli",
3
- "version": "2.2.0",
3
+ "version": "2.3.0",
4
4
  "description": "Secure local and remote developer workflows for BlinkHost",
5
5
  "keywords": ["blinkhost", "deployment", "hosting", "cloud", "cli", "developer-tools"],
6
6
  "homepage": "https://app.blinkhost.me/docs/source-control/cli",