@ogment-ai/cli 0.9.0 → 0.9.1-next.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
@@ -1,6 +1,6 @@
1
1
  # Ogment CLI
2
2
 
3
- Agent-first CLI for discovering and invoking Ogment-backed tools.
3
+ Agent-first CLI for discovering servers and running Codemode `search`/`execute` flows against Ogment-backed tools.
4
4
 
5
5
  - Package: `@ogment-ai/cli`
6
6
  - Binary: `ogment`
@@ -21,14 +21,11 @@ ogment auth login
21
21
  # 2) Discover servers
22
22
  ogment catalog
23
23
 
24
- # 3) Discover tools on one server
25
- ogment catalog <server-id>
24
+ # 3) Inspect tool definitions on one server
25
+ ogment search <server-id> --code 'return input'
26
26
 
27
- # 4) Inspect one tool schema
28
- ogment catalog <server-id> <tool-name> --example
29
-
30
- # 5) Invoke
31
- ogment invoke <server-id> <tool-name> --input '{}'
27
+ # 4) Execute Codemode JavaScript
28
+ ogment execute <server-id> --code 'return input' --input '{}'
32
29
  ```
33
30
 
34
31
  ## Common Commands
@@ -38,9 +35,10 @@ ogment auth login
38
35
  ogment auth status
39
36
  ogment auth logout
40
37
 
41
- ogment catalog [server-id] [tool-name]
38
+ ogment catalog
42
39
 
43
- ogment invoke <server-id> <tool-name> --input '{}'
40
+ ogment search <server-id> --code 'return input'
41
+ ogment execute <server-id> --code 'return input' --input '{}'
44
42
  ogment status
45
43
  ```
46
44
 
package/dist/cli.js CHANGED
@@ -8798,9 +8798,9 @@ const DEFAULT_OGMENT_BASE_URL = "https://dashboard.ogment.ai";
8798
8798
  * These are injected by Rolldown `transform.define` during release builds.
8799
8799
  * Runtime env vars (`OGMENT_CLI_SENTRY_*`) can still override them.
8800
8800
  */
8801
- const SENTRY_DSN_BUILD = "https://4219ab98670b61086758b4d0e31ae318@o4507724844957696.ingest.us.sentry.io/4510992932405248";
8802
- const SENTRY_ENVIRONMENT_BUILD = "production";
8803
- const SENTRY_RELEASE_BUILD = "cli-v0.9.0+git:f88c23e58";
8801
+ const SENTRY_DSN_BUILD = void 0;
8802
+ const SENTRY_ENVIRONMENT_BUILD = void 0;
8803
+ const SENTRY_RELEASE_BUILD = void 0;
8804
8804
  const packageJsonSchema = object({ version: string().min(1) });
8805
8805
  const hasCode = (value, code) => {
8806
8806
  if (typeof value !== "object" || value === null) return false;
@@ -13737,6 +13737,10 @@ const cacheSchema = object({
13737
13737
  lastCheckedAtMs: number$1().int().nonnegative(),
13738
13738
  latestVersion: string().optional()
13739
13739
  });
13740
+ const isPrereleaseVersion = (version) => {
13741
+ const parsed = import_semver.default.parse(version);
13742
+ return parsed?.prerelease.length !== void 0 && parsed.prerelease.length > 0;
13743
+ };
13740
13744
  const isTruthyEnvValue = (value) => {
13741
13745
  if (value === void 0) return false;
13742
13746
  const normalized = value.trim().toLowerCase();
@@ -13797,6 +13801,7 @@ const cachePathFromConfigDir = (configDir) => {
13797
13801
  const maybeGetAvailableCliUpdate = async (options, deps = {}) => {
13798
13802
  try {
13799
13803
  if (shouldSkipUpdateCheck(options.env ?? process.env)) return null;
13804
+ if (isPrereleaseVersion(options.currentVersion)) return null;
13800
13805
  const now = deps.now ?? (() => /* @__PURE__ */ new Date());
13801
13806
  const fetchLatestVersion = deps.fetchLatestVersion ?? defaultFetchLatestVersion;
13802
13807
  const cachePath = cachePathFromConfigDir(options.configDir ?? defaultConfigDir());
@@ -14112,6 +14117,7 @@ var OutputManager = class {
14112
14117
  //#endregion
14113
14118
  //#region ../../packages/shared/src/cli/common.ts
14114
14119
  const jsonObjectSchema = record(string(), unknown());
14120
+ const isoTimestampSchema = datetime({ offset: true });
14115
14121
  const cliErrorSchema = object({
14116
14122
  code: string().min(1),
14117
14123
  message: string().min(1)
@@ -14162,7 +14168,7 @@ const deviceCodeStartDataSchema = object({
14162
14168
  const deviceCodeStartSchema = cliSuccessEnvelopeSchema(deviceCodeStartDataSchema);
14163
14169
  const authStartDataSchema = object({
14164
14170
  authRequestId: string().min(1),
14165
- expiresAt: string().datetime(),
14171
+ expiresAt: isoTimestampSchema,
14166
14172
  userCode: string().min(1),
14167
14173
  verificationUrl: string().url()
14168
14174
  }).strict();
@@ -14244,7 +14250,7 @@ const cliCommandCompletedEventSchema = object({
14244
14250
  inputMode: cliInputModeSchema.nullable(),
14245
14251
  installationId: uuid(),
14246
14252
  success: boolean(),
14247
- timestamp: datetime({ offset: true })
14253
+ timestamp: isoTimestampSchema
14248
14254
  }).strict();
14249
14255
  const cliTelemetryAcceptedDataSchema = object({ accepted: literal(true) }).strict();
14250
14256
  const cliTelemetryAcceptedSchema = cliSuccessEnvelopeSchema(cliTelemetryAcceptedDataSchema);
@@ -72550,4 +72556,4 @@ if (shouldExecuteCli(import.meta.url, process.argv[1])) await executeCli();
72550
72556
 
72551
72557
  //#endregion
72552
72558
  export { executeCli, runCli, shouldExecuteCli };
72553
- //# debugId=856f5502-c592-445c-b0d7-d8c7048e63ba
72559
+ //# debugId=444cb93e-b899-4c52-9527-64988c3dbf06