Why doesn't the token work?

Why doesn't the token work?

sinevik
Visitor
2 0 0

I created the remix app and dev store according to the documentation.

 

I save the accesToken that I get when installing the application

 

 

export const loader = async ({ request }) => {
  const { admin, session } = await authenticate.admin(request);
  await saveAuth({
    shop: session.shop,
    accessToken: session.accessToken
  })

  return null;
};

Now I want to use this token to get store products. According to the documentation, I make a request:

 

 

sinevik_0-1732970850712.png

I add the token according to the documentation

 

sinevik_1-1732970975914.png

Can you please tell me why I'm getting an error? 

 

401 Unauthorized

""errors": "[API] Invalid API key or access token (unrecognized login or wrong password)"

Reply 1 (1)

sinevik
Visitor
2 0 0

Created a new dev store and installed there. The problem disappeared. For some reason, when you uninstall the app and dev store and then install it again, the token is not updated via remix. It's a terrible bug