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

Getting 403 forbidden error after login using ic identity #154

Open
aliscie opened this issue Jan 3, 2023 · 0 comments
Open

Getting 403 forbidden error after login using ic identity #154

aliscie opened this issue Jan 3, 2023 · 0 comments

Comments

@aliscie
Copy link
Owner

aliscie commented Jan 3, 2023

I am creating an actor like this in js

const authClient = await AuthClient.create();

const identity = await authClient.getIdentity();

export const get_actor = async () => {
    const idenitit = await clinet.
    const host = "http://localhost:5173/";
    const options = {agentOptions: {host}}
    const agent = new HttpAgent({identity, host});
     return await Actor.createActor(idlFactory, {
        agent,
        canisterId: process.env.BACKEND_CANISTER_ID,
    });
}

NFTActor = await get_actor();
let new_nft = awiat NFTActor.mint();
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