R/error.R

Defines functions notionapi_error

# Error helpers --------------------------------------------------

#' Create standardised notionapi errors
#'
#' @noRd
#' @keywords internal
notionapi_error <- function(
  message,
  class = NULL,
  call = caller_env(),
  .envir = caller_env(),
  ...
) {
  cli::cli_abort(
    message,
    call = call,
    class = c(class, "notionapi_error"),
    .envir = .envir
  )
}

Try the notionapi package in your browser

Any scripts or data that you put into this service are public.

notionapi documentation built on April 13, 2026, 9:07 a.m.