% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/audit.R
\name{audit}
\alias{audit}
\alias{audit.ArmadilloCredentials}
\alias{audit.character}
\alias{audit.cr8tor}
\alias{audit.list}
\alias{audit.opal}
\alias{audit.rocrate}
\title{Create an audit RO-Crate}
\usage{
audit(x, ...)

\method{audit}{ArmadilloCredentials}(x, ..., intent = NULL)

\method{audit}{character}(x, ..., intent = NULL)

\method{audit}{cr8tor}(x, ..., intent = NULL)

\method{audit}{list}(x, ..., intent = NULL)

\method{audit}{opal}(
  x,
  ...,
  intent = NULL,
  project = NULL,
  user = NULL,
  logs_from = -Inf,
  logs_to = Inf,
  path = NULL
)

\method{audit}{rocrate}(x, ..., intent = NULL)
}
\arguments{
\item{x}{Object to be audited. This can be
\itemize{
\item a \emph{connection} to a DataSHIELD server (e.g., OBiBa's Opal).
\item a \emph{path} pointing to an RO-Crate OR a \code{cr8tor} archive /
.        governance bundle.
\item an \emph{RO-Crate} object.
}
Alternatively, a list of any of the above.}

\item{...}{Additional arguments.}

\item{intent}{Additional object with governance bundle/specification of the
intent of a project. It takes the same types as \code{x}.}

\item{project}{String with project name(s) from which to extra Safe Project
details.}

\item{user}{String with the user name for which to extract Safe People
details.}

\item{logs_from}{Lower limit timestamp to filter out the outputs generated
(default: \code{-Inf}, everything up to \code{logs_to})}

\item{logs_to}{Upper limit timestamp to filter out the outputs generated
(default: \code{Inf}, everything from \code{logs_from} onwards).}

\item{path}{String with path pointing to the root of the RO-Crate. This will
be used to store log files. If not provided, logs will be stored within
the RO-Crate returned by this function.}
}
\value{
RO-Crate with audit details.
}
\description{
Create an audit RO-Crate following the 5 Safes Principles.
}
\details{
This function handles various audit types, which will be dispatched based on
the input object. If the input object is

\itemize{
\item a \emph{connection} to a DataSHIELD server (e.g., OBiBa's Opal):
.    generates an RO-Crate object with deployment details, including outputs.
\item a \emph{path} pointing to
\itemize{
\item \strong{a \code{cr8tor} archive / governance bundle}: generates an
RO-Crate object with pre-deployment governance details.
\item \strong{an RO-Crate object}: generates an RO-Crate object with
clearly defined 5 Safes elements.
}
\item an \emph{RO-Crate} object: generates an RO-Crate object with clearly
defined 5 Safes elements.
}
}
