Skip to main content Link Search Menu Expand Document (external link)

PopulationClient overview

PingOne Populations HTTP Client

Provides functions for managing PingOne populations via the PingOne Management API. Includes operations for creating, reading, updating, and deleting user populations.

Added in v0.0.1


Table of contents


API Client

createPopulation

Creates a new population in PingOne

Signature

export declare const createPopulation: <S extends Schema.Schema.Type<typeof CreatePopulationRequestSchema>>({
  envId,
  token,
  populationData
}: {
  envId: string
  token: string
  populationData: S
}) => Effect.Effect<
  {
    readonly name: string
    readonly id: string
    readonly environment?: { readonly id: string }
    readonly createdAt?: string
    readonly updatedAt?: string
    readonly _links?: { readonly [x: string]: unknown }
    readonly description?: string
    readonly preferredLanguage?: string
    readonly passwordPolicy?: { readonly id: string }
    readonly default: boolean
    readonly userCount?: number
    readonly theme?: { readonly id: string }
  },
  PingOneApiError | HttpClientError | ParseError | HttpBodyError,
  HttpClient | CredentialService
>

Added in v0.0.1

deletePopulation

Deletes a population

Signature

export declare const deletePopulation: ({
  envId,
  token,
  populationId
}: {
  envId: string
  token: string
  populationId: string
}) => Effect.Effect<any, PingOneApiError | HttpClientError, HttpClient | CredentialService>

Added in v0.0.1

listPopulations

Lists populations in an environment

Signature

export declare const listPopulations: ({
  envId,
  token,
  limit,
  filter
}: {
  envId: string
  token: string
  limit?: number
  filter?: string
}) => Effect.Effect<
  {
    readonly _embedded: {
      readonly populations: readonly {
        readonly name: string
        readonly id: string
        readonly environment?: { readonly id: string }
        readonly createdAt?: string
        readonly updatedAt?: string
        readonly _links?: { readonly [x: string]: unknown }
        readonly description?: string
        readonly preferredLanguage?: string
        readonly passwordPolicy?: { readonly id: string }
        readonly default: boolean
        readonly userCount?: number
        readonly theme?: { readonly id: string }
      }[]
    }
    readonly count?: number
    readonly size?: number
  },
  PingOneApiError | HttpClientError | ParseError,
  HttpClient | CredentialService | CacheService
>

Added in v0.0.1

readPopulation

Reads a population by ID

Signature

export declare const readPopulation: ({
  envId,
  token,
  populationId
}: {
  envId: string
  token: string
  populationId: string
}) => Effect.Effect<
  {
    readonly name: string
    readonly id: string
    readonly environment?: { readonly id: string }
    readonly createdAt?: string
    readonly updatedAt?: string
    readonly _links?: { readonly [x: string]: unknown }
    readonly description?: string
    readonly preferredLanguage?: string
    readonly passwordPolicy?: { readonly id: string }
    readonly default: boolean
    readonly userCount?: number
    readonly theme?: { readonly id: string }
  },
  PingOneApiError | HttpClientError | ParseError,
  HttpClient | CredentialService | CacheService
>

Added in v0.0.1

updatePopulation

Updates a population

Signature

export declare const updatePopulation: <S extends Schema.Schema.Type<typeof UpdatePopulationRequestSchema>>({
  envId,
  token,
  populationId,
  populationData
}: {
  envId: string
  token: string
  populationId: string
  populationData: S
}) => Effect.Effect<
  {
    readonly name: string
    readonly id: string
    readonly environment?: { readonly id: string }
    readonly createdAt?: string
    readonly updatedAt?: string
    readonly _links?: { readonly [x: string]: unknown }
    readonly description?: string
    readonly preferredLanguage?: string
    readonly passwordPolicy?: { readonly id: string }
    readonly default: boolean
    readonly userCount?: number
    readonly theme?: { readonly id: string }
  },
  PingOneApiError | HttpClientError | ParseError | HttpBodyError,
  HttpClient | CredentialService
>

Added in v0.0.1