Skip to content
This repository was archived by the owner on Dec 31, 2025. It is now read-only.
This repository was archived by the owner on Dec 31, 2025. It is now read-only.

Can't run any passthrough calls with Vessel #315

@Samanimkr

Description

@Samanimkr

So I've been trying to use this integrations library to get a simple google calendar passthrough call working but keep running into an auth problem.

Code:

const vessel = require("@vesselapi/integrations");

const main = async () => {
  const auth = vessel.auth.oauth2(vessel.googleCalendar.auth);
  
  const response = await vessel.googleCalendar.client.passthrough(auth, {
    method: "GET",
    url: "/calendar/v3/calendars/primary/events",
  });

  console.log("response: ", response);
};

main();

Error:

const fetchRawResponse = async (auth2, args) => await auth2.retry(async () => {
                                                                ^
TypeError: auth2.retry is not a function
    at fetchRawResponse (.../node_modules/@vesselapi/integrations/dist/index.js:251:65)
    at Object.makeValidatedRequest [as passthrough] (.../node_modules/@vesselapi/integrations/dist/index.js:279:30)
    at main (.../vessel.js:13:55)
    at Object.<anonymous> (.../vessel.js:29:1)
    at Module._compile (node:internal/modules/cjs/loader:1233:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1287:10)
    at Module.load (node:internal/modules/cjs/loader:1091:32)
    at Module._load (node:internal/modules/cjs/loader:938:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:83:12)
    at node:internal/main/run_main_module:23:47

Node.js v20.5.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions