/** * Copyright (c) 2026, Salesforce, Inc., * All rights reserved. * For full license text, see the LICENSE.txt file */ import type { OrgAuth } from "./auth.js"; export interface PicklistValue { value: string | null; label: string | null; } export interface PicklistFieldInfo { apiName: string; label: string; required: boolean; values: PicklistValue[]; } export interface FieldMetadata { apiName: string; label: string | null; dataType: string | null; required: boolean; createable: boolean; updateable: boolean; calculated: boolean; custom: boolean; filterable: boolean; sortable: boolean; nameField: boolean; reference: boolean; relationshipName: string | null; compound: boolean; compoundFieldName: string | null; defaultedOnCreate: boolean; extraTypeInfo: string | null; inlineHelpText: string | null; precision: number; scale: number; referenceToInfos: { apiName: string; nameFields: string[]; }[]; controllerName: string | null; controllingFields: string[]; } export interface ObjectInfoResult { apiName: string; label: string | null; labelPlural: string | null; createable: boolean; deletable: boolean; updateable: boolean; queryable: boolean; searchable: boolean; custom: boolean; keyPrefix: string | null; nameFields: string[]; defaultRecordTypeId: string | null; fields: FieldMetadata[]; childRelationships: { childObjectApiName: string; fieldName: string | null; relationshipName: string | null; }[]; recordTypeInfos: { recordTypeId: string; name: string | null; available: boolean; master: boolean; defaultRecordTypeMapping: boolean; }[]; picklists: PicklistFieldInfo[]; fetchedAt: string; } export declare function getObjectInfo(auth: OrgAuth, orgAlias: string, sObjectName: string, refresh?: boolean): Promise; export declare function getCachedObjectInfo(orgAlias: string, sObjectName: string): ObjectInfoResult | null; export declare function setCachedObjectInfo(orgAlias: string, sObjectName: string, info: ObjectInfoResult): void; export declare function getRequiredCreateFields(info: ObjectInfoResult): FieldMetadata[]; export declare function getPicklistValues(info: ObjectInfoResult, fieldName: string): PicklistValue[] | null; export declare function clearObjectInfoCache(orgAlias?: string): void;