// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from '../core/resource'; import * as BusinessPartnersAPI from './business-partners'; import { APIPromise } from '../core/api-promise'; import { PageCursorURL, PagePromise } from '../core/pagination'; import { RequestOptions } from '../internal/request-options'; import { path } from '../internal/utils/path'; /** * Organizational classifications used to categorize hiring needs based on business urgency and strategic importance */ export class HeadcountPriorities extends APIResource { /** * A list of headcount priorities. * * - Requires: `API Tier 1` * - Sortable fields: `id`, `created_at`, `updated_at` * * @example HTTP * Representative request and response shapes. * ``` * GET /headcount-priorities/?order_by=order_by&limit=50&cursor=cursor HTTP/1.1 * Host: rest.ripplingapis.com * Accept: application/json * Rippling-Api-Version: 2024-08-01 * * HTTP/1.1 200 OK * Content-Type: application/json * * { * "__meta": { * "redacted_fields": [ * { * "name": "date_of_birth", * "reason": "Insufficient entitlements" * } * ] * }, * "results": [ * { * "id": "string", * "created_at": "string", * "updated_at": "string", * "name": "string" * } * ], * "next_link": "string" * } * ``` */ list( query: HeadcountPriorityListParams | null | undefined = {}, options?: RequestOptions, ): PagePromise { return this._client.getAPIList('/headcount-priorities/', PageCursorURL, { query, ...options, }); } /** * Retrieve a specific headcount priority * * @example HTTP * Representative request and response shapes. * ``` * GET /headcount-priorities/{id}/ HTTP/1.1 * Host: rest.ripplingapis.com * Accept: application/json * Rippling-Api-Version: 2024-08-01 * * HTTP/1.1 200 OK * Content-Type: application/json * * { * "__meta": { * "redacted_fields": [ * {} * ] * } * } * ``` */ retrieve(id: string, options?: RequestOptions): APIPromise { return this._client.get(path`/headcount-priorities/${id}/`, options); } } export type HeadcountPriorityListResponsesPageCursorURL = PageCursorURL; export interface HeadcountPriorityListResponse { /** * Identifier field */ id: string; /** * Record creation date */ created_at: string; /** * Record update date */ updated_at: string; /** * Display name of the headcount priority */ name?: string; } /** * Meta information for the response. */ export interface HeadcountPriorityRetrieveResponse extends BusinessPartnersAPI.Meta { /** * Identifier field */ id: string; /** * Record creation date */ created_at: string; /** * Record update date */ updated_at: string; /** * Display name of the headcount priority */ name?: string; } export interface HeadcountPriorityListParams { cursor?: string; /** * The maximum number of results to return. Defaults to 50. Maximum is 100. */ limit?: number; order_by?: string; } export declare namespace HeadcountPriorities { export { type HeadcountPriorityListResponse as HeadcountPriorityListResponse, type HeadcountPriorityRetrieveResponse as HeadcountPriorityRetrieveResponse, type HeadcountPriorityListResponsesPageCursorURL as HeadcountPriorityListResponsesPageCursorURL, type HeadcountPriorityListParams as HeadcountPriorityListParams, }; }