import { APIResource } from "../core/resource.mjs"; import * as BusinessPartnersAPI from "./business-partners.mjs"; import * as WorkersAPI from "./workers.mjs"; import { APIPromise } from "../core/api-promise.mjs"; import { PageCursorURL, PagePromise } from "../core/pagination.mjs"; import { RequestOptions } from "../internal/request-options.mjs"; /** * Mappings between Rippling workers and their user accounts in third-party apps */ export declare class AppUsers extends APIResource { /** * A list of app users. * * - Requires: `API Tier 1` * - Filterable fields: `worker_id`, `spoke_user_identifier`, `app_handle`, * `created_at`, `updated_at` * - Expandable fields: `worker` * - Sortable fields: `id`, `created_at`, `updated_at` * * @example HTTP * Representative request and response shapes. * ``` * GET /app-users/?filter=filter&expand=expand&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", * "worker_id": "string", * "worker": { * "id": "string", * "created_at": "string", * "updated_at": "string", * "user_id": "string", * "user": {}, * "is_manager": "string", * "manager_id": "string", * "manager": {}, * "legal_entity_id": "string", * "legal_entity": {}, * "country": "AF", * "start_date": "string", * "end_date": "string", * "number": "string", * "work_email": "string", * "personal_email": "string", * "status": "INIT", * "location": {}, * "employment_type_id": "string", * "employment_type": {}, * "gender": "MALE", * "date_of_birth": "string", * "race": "BLACK", * "ethnicity": "HISPANIC_OR_LATINO", * "citizenship": "AF", * "compensation_id": "string", * "compensation": {}, * "overtime_exemption": "EXEMPT", * "department_id": "string", * "department": {}, * "teams_id": [], * "teams": [], * "title": "string", * "title_effective_date": "string", * "level_id": "string", * "level": {}, * "job_function_id": "string", * "job_function": {}, * "termination_details": {}, * "pay_schedule_id": "string", * "work_schedule": {}, * "compensation_grade": {}, * "original_start_date": "string", * "custom_fields": [], * "country_fields": {}, * "business_partners_id": [], * "business_partners": [] * }, * "app_handle": "string", * "app_display_name": "string", * "spoke_user_identifier": "string", * "external_username": "string", * "external_email": "string", * "push_state": "INIT", * "match_state": "MATCHED" * } * ], * "next_link": "string" * } * ``` */ list(query?: AppUserListParams | null | undefined, options?: RequestOptions): PagePromise; /** * Retrieve a specific app user * * @example HTTP * Representative request and response shapes. * ``` * GET /app-users/{id}/?expand=expand 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, query?: AppUserRetrieveParams | null | undefined, options?: RequestOptions): APIPromise; } export type AppUserListResponsesPageCursorURL = PageCursorURL; /** * Maps a Rippling worker (if any) to their user account in a third-party * app (e.g. Slack, Jira, GitHub). Sourced from SpokeUser records. * * Includes orphan accounts — third-party app accounts with no matching * Rippling worker (`worker_id=None`, `match_state=NOT_MATCHED`). These are * the primary signal for IT-admin triage. Uses `BaseResourceDTO` rather * than `BaseEmployeeResourceDTO` so the platform's role-based auto-filter * does not silently drop orphans for non-admin tokens. Company scoping is * enforced explicitly in `AppUsersAPIViewSet.get_queryset`; the `app-users.read` * scope is the access gate. * * Resource name aligns with how the product surfaces these in the UI * ("Slack account", "GitHub account") and matches the equivalent concept * in Okta's IAM API (AppUser). * * Designed for point lookups: list endpoint requires at least one filter * on `worker_id` or `spoke_user_identifier` to prevent bulk enumeration of the * org's identity graph across connected apps. * * `spoke_user_identifier` reads `SpokeUser.spokeId` — the user identifier * stored for the third-party account. Depending on the integration, this may * be an email, username, account handle, or app-specific user id. */ export interface AppUserListResponse { /** * Identifier field */ id: string; /** * Record creation date */ created_at: string; /** * Record update date */ updated_at: string; /** * Human-readable display name for the third-party app (e.g. 'Slack', 'GitHub'). * Sourced from the customer-configured SpokeOwner.app_display_name; falls back to * a title-cased app handle when the customer hasn't set one. */ app_display_name?: string; /** * Machine-readable identifier for the third-party app (e.g. 'slack', 'jira', * 'asana'). Stable across the App Shop catalog. */ app_handle?: string; /** * The user's email address in the third-party app, if known. Null when the app * does not expose an email or Rippling did not capture one. */ external_email?: string; /** * The user's display name in the third-party app, if known. Null when the app does * not surface a separate username. */ external_username?: string; /** * Whether this third-party account has been matched to a Rippling worker. */ match_state?: 'MATCHED' | 'NOT_MATCHED' | 'IGNORED'; /** * Provisioning lifecycle state of this account in the third-party app. */ push_state?: 'INIT' | 'EMPLOYEE_CONFIRMATION_PENDING' | 'EMPLOYEE_CONFIRMATION_ACCEPTED' | 'EMPLOYEE_CONFIRMATION_REJECTED' | 'INVITE_PENDING' | 'INVITE_CONFIRMED' | 'INVITE_FAILED' | 'CREATE_PENDING' | 'CREATE_CONFIRMED' | 'CREATE_FAILED' | 'DELETE_PENDING' | 'DELETE_CONFIRMED' | 'DELETE_FAILED' | 'SUSPEND_PENDING' | 'SUSPEND_CONFIRMED' | 'SUSPEND_FAILED'; /** * Identifier for the user's account in the third-party app workspace. Depending on * the integration, this may be an email, username, account handle, or app-specific * user id. */ spoke_user_identifier?: string; /** * The Rippling worker associated with this external app account. Expanding this * field requires both `app-users.read` and `workers.read` scopes. * * Expandable field */ worker?: WorkersAPI.Worker; /** * ID of the Rippling worker associated with this external app account. */ worker_id?: string; } /** * Meta information for the response. */ export interface AppUserRetrieveResponse extends BusinessPartnersAPI.Meta { /** * Identifier field */ id: string; /** * Record creation date */ created_at: string; /** * Record update date */ updated_at: string; /** * Human-readable display name for the third-party app (e.g. 'Slack', 'GitHub'). * Sourced from the customer-configured SpokeOwner.app_display_name; falls back to * a title-cased app handle when the customer hasn't set one. */ app_display_name?: string; /** * Machine-readable identifier for the third-party app (e.g. 'slack', 'jira', * 'asana'). Stable across the App Shop catalog. */ app_handle?: string; /** * The user's email address in the third-party app, if known. Null when the app * does not expose an email or Rippling did not capture one. */ external_email?: string; /** * The user's display name in the third-party app, if known. Null when the app does * not surface a separate username. */ external_username?: string; /** * Whether this third-party account has been matched to a Rippling worker. */ match_state?: 'MATCHED' | 'NOT_MATCHED' | 'IGNORED'; /** * Provisioning lifecycle state of this account in the third-party app. */ push_state?: 'INIT' | 'EMPLOYEE_CONFIRMATION_PENDING' | 'EMPLOYEE_CONFIRMATION_ACCEPTED' | 'EMPLOYEE_CONFIRMATION_REJECTED' | 'INVITE_PENDING' | 'INVITE_CONFIRMED' | 'INVITE_FAILED' | 'CREATE_PENDING' | 'CREATE_CONFIRMED' | 'CREATE_FAILED' | 'DELETE_PENDING' | 'DELETE_CONFIRMED' | 'DELETE_FAILED' | 'SUSPEND_PENDING' | 'SUSPEND_CONFIRMED' | 'SUSPEND_FAILED'; /** * Identifier for the user's account in the third-party app workspace. Depending on * the integration, this may be an email, username, account handle, or app-specific * user id. */ spoke_user_identifier?: string; /** * The Rippling worker associated with this external app account. Expanding this * field requires both `app-users.read` and `workers.read` scopes. * * Expandable field */ worker?: WorkersAPI.Worker; /** * ID of the Rippling worker associated with this external app account. */ worker_id?: string; } export interface AppUserListParams { cursor?: string; expand?: string; filter?: string; /** * The maximum number of results to return. Defaults to 50. Maximum is 100. */ limit?: number; order_by?: string; } export interface AppUserRetrieveParams { expand?: string; } export declare namespace AppUsers { export { type AppUserListResponse as AppUserListResponse, type AppUserRetrieveResponse as AppUserRetrieveResponse, type AppUserListResponsesPageCursorURL as AppUserListResponsesPageCursorURL, type AppUserListParams as AppUserListParams, type AppUserRetrieveParams as AppUserRetrieveParams, }; } //# sourceMappingURL=app-users.d.mts.map