import { Ref, ComputedRef } from 'vue'; import { GraphQLClient, SparePartsMachine } from '@propeller-commerce/propeller-sdk-v2'; /** * Build ONE aliased query resolving every installation in a single request: * `machine_0: machine(source: $source, sourceId: $sourceId_0, language: $language) { … }` * per id. One shared `$source`/`$language`/`$imageVariantFilters`, one * `$sourceId_N` per id. `imageVariants(input:)` is NON_NULL — the same * `TransformationsInput!` the SDK `machine`/`category` queries require. */ export declare function buildRootMachinesQuery(count: number): string; export interface UseMachinesOptions { /** SDK client. Without it the composable stays idle. */ graphqlClient?: GraphQLClient; /** External system the machine ids belong to (pairs with each id). */ source?: Ref; /** Installation ids (from the `MY_INSTALLATIONS` company track attribute). */ sourceIds?: Ref; /** Language the machine TREE is authored in (usually EN). */ language?: Ref; /** * Image transformation for the card thumbnail — the `TransformationsInput!` * the schema requires on `imageVariants(input:)`. Without it the query fails * validation. Pass `config.imageVariantFiltersMedium` (same value the node * query uses). */ imageVariantFilters?: unknown; } export interface UseMachinesReturn { /** Resolved installations, in `sourceIds` order, nulls dropped. */ machines: ComputedRef; /** `true` while the concat request is in flight. */ isLoading: Ref; /** Re-run the fetch. */ fetchMachines: () => Promise; } /** * useMachines — resolve a company's installations in one concatenated request. */ export declare function useMachines(options: UseMachinesOptions): UseMachinesReturn;