Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: API is not a constructor #6

Open
rainb3rry opened this issue Mar 28, 2024 · 0 comments
Open

TypeError: API is not a constructor #6

rainb3rry opened this issue Mar 28, 2024 · 0 comments

Comments

@rainb3rry
Copy link

Receiving this error

const bypass = new API();
               ^

TypeError: API is not a constructor

on this setup,

const API = require("./Puppeteer-Bypass/built/API");
const bypass = new API();

(
    async () => {
        const result = await bypass.request("https://accounts.shopify.com", { method: "GET"
           
        });

        console.log(result);
    }
)();

tried also with const API = require("./Puppeteer-Bypass/built/API").default;
and

export class API {
,
export default class API {

on API.d.ts file..

any solutions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant