import { Command } from '@oclif/core'; import { OAuthCommand } from './oauth-command.js'; import type { ResolvedB2CConfig } from '../config/index.js'; import { type OdsClient } from '../clients/ods.js'; /** * Base command for ODS (On-Demand Sandbox) operations. * Use this for commands that interact with the Developer Sandbox API * (sandbox creation, deletion, start/stop, realm info, etc.) * * Environment variables: * - SFCC_SANDBOX_API_HOST: ODS API hostname * - Plus all from OAuthCommand (SFCC_CLIENT_ID, SFCC_CLIENT_SECRET) * * Provides: * - Host configuration flag with env var support * - Typed ODS API client via `this.odsClient` * * @example * export default class MySandboxCommand extends OdsCommand { * async run(): Promise { * const { data } = await this.odsClient.GET('/me', {}); * console.log('User:', data?.data?.user?.name); * } * } */ export declare abstract class OdsCommand extends OAuthCommand { protected getDefaultClientId(): string; static baseFlags: { 'sandbox-api-host': import("@oclif/core/interfaces").OptionFlag; 'client-id': import("@oclif/core/interfaces").OptionFlag; 'client-secret': import("@oclif/core/interfaces").OptionFlag; 'auth-scope': import("@oclif/core/interfaces").OptionFlag; 'short-code': import("@oclif/core/interfaces").OptionFlag; 'tenant-id': import("@oclif/core/interfaces").OptionFlag; 'auth-methods': import("@oclif/core/interfaces").OptionFlag; 'user-auth': import("@oclif/core/interfaces").BooleanFlag; 'account-manager-host': import("@oclif/core/interfaces").OptionFlag; 'jwt-cert': import("@oclif/core/interfaces").OptionFlag; 'jwt-key': import("@oclif/core/interfaces").OptionFlag; 'jwt-passphrase': import("@oclif/core/interfaces").OptionFlag; 'log-level': import("@oclif/core/interfaces").OptionFlag<"trace" | "debug" | "info" | "warn" | "error" | "silent" | undefined, import("@oclif/core/interfaces").CustomOptions>; debug: import("@oclif/core/interfaces").BooleanFlag; json: import("@oclif/core/interfaces").BooleanFlag; jsonl: import("@oclif/core/interfaces").BooleanFlag; lang: import("@oclif/core/interfaces").OptionFlag; config: import("@oclif/core/interfaces").OptionFlag; instance: import("@oclif/core/interfaces").OptionFlag; 'project-directory': import("@oclif/core/interfaces").OptionFlag; 'extra-query': import("@oclif/core/interfaces").OptionFlag; 'extra-body': import("@oclif/core/interfaces").OptionFlag; 'extra-headers': import("@oclif/core/interfaces").OptionFlag; }; protected loadConfiguration(): Promise; private _odsClient?; /** * Gets the ODS API client for this command. * * The client is lazily created using the configured host and OAuth credentials. * It provides typed methods for all ODS API operations. * * @example * // Get user info * const { data } = await this.odsClient.GET('/me', {}); * * // List sandboxes * const { data } = await this.odsClient.GET('/sandboxes', {}); * * // Create a sandbox operation * const { data } = await this.odsClient.POST('/sandboxes/{sandboxId}/operations', { * params: { path: { sandboxId: 'uuid' } }, * body: { operation: 'start' } * }); */ protected get odsClient(): OdsClient; /** * Gets the configured ODS API host. */ protected get odsHost(): string; /** * Resolves a sandbox identifier to a UUID. * * Supports both UUID format and friendly format (realm-instance, e.g., "abcd-123" or "abcd_123"). * If given a UUID, returns it directly. If given a friendly format, queries the API to find * the matching sandbox and logs the resolution. * * @param identifier - Sandbox identifier (UUID or friendly format) * @returns The sandbox UUID * @throws Error if the sandbox cannot be found (friendly ID not resolved) * * @example * ```typescript * // In a command's run() method: * const sandboxId = await this.resolveSandboxId(this.args.sandboxId); * ``` */ protected resolveSandboxId(identifier: string): Promise; }