diegosouzapw/OmniRoute · error · Error

Bearer token is required

Error message

Bearer token is required

What it means

Error "Bearer token is required" thrown in diegosouzapw/OmniRoute.

Source

Thrown at src/lib/oauth/services/raycast.ts:31

} from "@omniroute/open-sse/services/raycast.ts";

export class RaycastService {
  validateCredentials(input: {
    accessToken: string;
    deviceId: string;
    aid?: string;
    signatureJwt?: string;
    sigSecret?: string;
  }): { aid: string } {
    const accessToken = input.accessToken.trim();
    const deviceId = input.deviceId.trim();
    let aid = (input.aid || "").trim();

    if (!aid && input.signatureJwt?.trim()) {
      aid = decodeAidFromRaycastJwt(input.signatureJwt.trim()) || "";
    }

    if (!accessToken) throw new Error("Bearer token is required");
    if (!deviceId) throw new Error("Device ID is required");

    // AID is optional for current Raycast API — fall back to deviceId when not captured manually.
    if (!aid) aid = deviceId;

    return { aid };
  }

  async probeModels(credentials: {
    accessToken: string;
    deviceId: string;
    aid: string;
    sigSecret?: string;
  }): Promise<RaycastModelEntry[]> {
    return fetchRaycastModels({
      accessToken: credentials.accessToken,
      providerSpecificData: {
        deviceId: credentials.deviceId,

View on GitHub (pinned to a179ffed5b)

When it happens

Trigger: Thrown at src/lib/oauth/services/raycast.ts:31 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of diegosouzapw/OmniRoute@a179ffed5b (2026-08-25). Data as JSON: /api/errors/b3708b5ac311bd3c. Report an issue: GitHub.