> ## Documentation Index
> Fetch the complete documentation index at: https://docs.galileo.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# exceptions

## Module

Galileo SDK exceptions.

## GalileoLoggerException

Exception raised by GalileoLogger.

## GalileoAPIError

Base class for Galileo API HTTP errors with actionable messages.

## BadRequestError

HTTP 400 - The request was malformed or invalid.

## AuthenticationError

HTTP 401 - Authentication failed.

## ForbiddenError

HTTP 403 - Insufficient permissions.

## NotFoundError

HTTP 404 - Resource not found.

**Arguments**

* `status_code_or_message` (`int | str`): Either an HTTP status code (`int`, paired with `content`) or a
  full message string (`str`, used on its own).

* `content` (`bytes`): Raw response body. Only valid alongside an `int` status code; on the
  message path it must be omitted.

**Examples**

```python theme={null}
NotFoundError(404, b"{\\"detail\\": ...}")  # HTTP response path
NotFoundError("Project \\"foo\\" not found.")  # SDK lookup path
```

**Notes**

Two construction paths are supported, exposed via `@overload` so type
checkers see the right shape per call site:

* `NotFoundError(status_code, content)` — built from an HTTP 404 response
  by the generated client. Uses the standard "Resource not found…" message.
* `NotFoundError(message)` — built from an SDK-level lookup that has no
  HTTP response (e.g. resolving a project from env vars). The string is the
  full message; no `content` argument is accepted.

The runtime constructor also enforces the contract. The following all raise
`TypeError` instead of producing nonsensical state:

* Mixing shapes: `NotFoundError("msg", b"")` / `NotFoundError("msg", b"body")`
* Passing `None`: `NotFoundError(None)`
* Passing `bool`: `NotFoundError(True, b"x")` (`bool` is technically an
  `int` subclass but is rejected explicitly to avoid silent acceptance)

## ConflictError

HTTP 409 - Resource conflict.

## RateLimitError

HTTP 429 - Rate limit exceeded.

## ServerError

HTTP 5xx - Server-side error.
