import type { AxiosInstance } from 'axios'; import { Schema } from '../schema/Schema.js'; import type { AdapterT } from './Adapter.js'; import * as Location from './Location.js'; export declare type Agent = AxiosInstance; export declare type ResourcePathStep = Location.Step; export declare type ResourcePath = Location.Location; export declare type URI = string; export declare type StorePath = Location.Location; export declare type Options = { agent: Agent; adapter: AdapterT; }; export declare type Context = { options: Options; path: ResourcePath; uri: URI; store: StorePath; agent: Agent; }; export declare type ResourceDefinition = Context & { schema: S; methods: any; adapter: AdapterT; }; export declare const resourceDef: unique symbol; export declare type Resource = { [resourceDef]: ResourceDefinition; }; export declare type ResourceCreator = { (context: Context): Resource; schema: S; }; export declare type ResourceSpec = { path: ResourcePath; uri: URI; store: StorePath; methods: { [method: string]: (...args: never[]) => unknown; }; resources: { [resource: string]: ResourceCreator; }; }; export declare const intantiateSpec: , SpecT extends ResourceSpec, Spec extends Partial>(context: Context, specPartial: Spec, defaults: ResourceSpec) => SpecT & { resources: { [x: string]: Resource>; }; }; //# sourceMappingURL=Resource.d.ts.map