BerriAI/litellm · error · OCIError

Missing required parameters: oci_user, oci_fingerprint…

Error message

Missing required parameters: oci_user, oci_fingerprint, oci_tenancy, oci_compartment_id and at least one of oci_key or oci_key_file. These can be supplied via optional_params or via OCI_USER, OCI_FINGERPRINT, OCI_TENANCY, OCI_COMPARTMENT_ID, OCI_KEY_FILE environment variables. Alternatively, provide an oci_signer object from the OCI SDK.

What it means

Error "Missing required parameters: oci_user, oci_fingerprint, oci_tenancy, oci_compartment_id and at least one of oci_key or oci_key_file. These can be supplied via optional_params or via OCI_USER, OCI_FINGERPRINT, OCI_TENANCY, OCI_COMPARTMENT_ID, OCI_KEY_FILE environment variables. Alternatively, provide an oci_signer object from the OCI SDK." thrown in BerriAI/litellm.

Solutions

  1. Supply oci_user, oci_fingerprint, oci_tenancy, oci_compartment_id and oci_key or oci_key_file via optional_params or the OCI_USER/OCI_FINGERPRINT/OCI_TENANCY/OCI_COMPARTMENT_ID/OCI_KEY_FILE env vars.
  2. Alternatively pass an oci_signer object from the OCI SDK.

When it happens

Trigger: Thrown at litellm/llms/oci/chat/transformation.py:424 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of BerriAI/litellm@77b7c6c40c (2026-08-18). Data as JSON: /api/errors/7705fd99fe1a140d. Report an issue: GitHub.

Appendix: source

Thrown at litellm/llms/oci/chat/transformation.py:424

        if not messages:
            raise OCIError(
                status_code=400,
                message="kwarg `messages` must be an array of messages that follow the openai chat standard",
            )
        if optional_params.get("oci_signer") is None:
            creds: Final = resolve_oci_credentials(optional_params)
            missing: Final = [
                k
                for k in (
                    "oci_user",
                    "oci_fingerprint",
                    "oci_tenancy",
                    "oci_compartment_id",
                )
                if not creds.get(k)
            ]
            if missing or not (creds.get("oci_key") or creds.get("oci_key_file")):
                raise OCIError(
                    status_code=401,
                    message=(
                        "Missing required parameters: oci_user, oci_fingerprint, oci_tenancy, "
                        "oci_compartment_id and at least one of oci_key or oci_key_file. "
                        "These can be supplied via optional_params or via OCI_USER, OCI_FINGERPRINT, "
                        "OCI_TENANCY, OCI_COMPARTMENT_ID, OCI_KEY_FILE environment variables. "
                        "Alternatively, provide an oci_signer object from the OCI SDK."
                    ),
                )
        return validate_oci_environment(headers, optional_params, api_key)

    def get_complete_url(
        self,
        api_base: str | None,
        api_key: str | None,
        model: str,
        optional_params: dict,
        litellm_params: dict,

View on GitHub (pinned to 77b7c6c40c)