import { type ExistingManifestContextOptions } from "./existing-manifest-context.mjs"; import type { ManifestComponentDeletion, ManifestScope } from "./manifest-builder.mjs"; /** * Initialization properties for {@link Category}. */ export interface CategoryProps { /** * Unique identifier for this category (e.g. `'gym__c'`). Must end with `__c`. * * Required. */ apiName: string; /** * Display name shown in the Rippling UI (e.g. `'Gym'`). * * Required. */ name: string; /** * Human-readable description of what this category groups. * * Required. The backend (`CustomCategoryConfig.description: str`) requires the * key to be present and rejects `null`. Pass an empty string only if you truly * have no meaningful copy. */ description: string; } /** * Defines a category and registers it with the manifest. * * A category is the navigation grouping that organizes related custom objects * in the Rippling sidebar. You would normally define one category per domain, * then pass it (or its api_name string) to each {@link CustomObject} in that domain. * * @example * ```ts * const manifest = new ManifestBuilder({ * key: 'gym_membership_management', * name: 'Gym Membership Management', * }); * * const gymCategory = new Category(manifest, { * apiName: 'gym__c', * name: 'Gym', * description: 'Memberships, staff, schedules, and attendance', * }); * * // Pass the instance to any CustomObject in this domain: * const memberObj = new CustomObject(manifest, { * apiName: 'gym_member__c', * name: 'Member', * category: gymCategory, * }); * ``` * * @see {@link CustomObject} — references this category via instance. */ export declare class Category { static readonly componentType: "CUSTOM_CATEGORY"; static toDeletionIdentifier(apiName: string): ManifestComponentDeletion; private readonly _apiName; private readonly _name; private readonly _description; /** * @param scope - The manifest to register this category with. * @param props - Initialization properties. */ constructor(scope: ManifestScope, props: CategoryProps); /** * Loads this category from the active existing-manifest JSON context. */ static loadFromExisting(apiName: string, options?: ExistingManifestContextOptions): Category; /** @internal Hydrates a category from existing manifest wire JSON. */ static _fromExistingComponent(scope: ManifestScope, component: Record): Category; /** * Returns the api_name of this category (e.g. `'gym__c'`). */ getApiName(): string; /** * Returns the display name of this category (e.g. `'Gym'`). */ getName(): string; /** * Serializes this category to the wire format consumed by the manifest install endpoint. * * @returns A plain object with `type: 'CUSTOM_CATEGORY'` and all configured fields. */ toDict(): Record; } //# sourceMappingURL=category.d.mts.map