Humaans.PerformanceReviews (Humaans v0.6.0)

Copy Markdown View Source

This module provides functions for listing and retrieving performance review resources in the Humaans API. Performance reviews are read-only via the API.

Summary

Functions

Lists all performance_reviews.

Retrieves a specific performance_review by ID.

Types

list_response()

@type list_response() ::
  {:ok,
   [
     %Humaans.Resources.PerformanceReview{
       company_id: term(),
       created_at: term(),
       id: term(),
       performance_instance_id: term(),
       person_id: term(),
       status: term(),
       updated_at: term()
     }
   ]}
  | {:error, Humaans.Error.t()}

response()

@type response() ::
  {:ok,
   %Humaans.Resources.PerformanceReview{
     company_id: term(),
     created_at: term(),
     id: term(),
     performance_instance_id: term(),
     person_id: term(),
     status: term(),
     updated_at: term()
   }}
  | {:error, Humaans.Error.t()}

Functions

list(client, params \\ %{})

@spec list(client :: map(), params :: map() | keyword() | [{String.t(), term()}]) ::
  {:ok, [Humaans.Resources.PerformanceReview.t()]} | {:error, Humaans.Error.t()}

Lists all performance_reviews.

Returns a list of performance_reviews matching the optional filter params.

Parameters

  • client - Client created with Humaans.new/1
  • params - Optional map of filter parameters (default: %{})

Examples

client = Humaans.new(access_token: "your_access_token")
{:ok, performance_reviews} = Humaans.PerformanceReviews.list(client)
{:ok, performance_reviews} = Humaans.PerformanceReviews.list(client, %{})

retrieve(client, id)

@spec retrieve(client :: map(), id :: String.t()) ::
  {:ok, Humaans.Resources.PerformanceReview.t()} | {:error, Humaans.Error.t()}

Retrieves a specific performance_review by ID.

Parameters

  • client - Client created with Humaans.new/1
  • id - String ID of the performance_review to retrieve

Examples

client = Humaans.new(access_token: "your_access_token")
{:ok, performance_review} = Humaans.PerformanceReviews.retrieve(client, "performance_review_id")