Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

184
Visualizações
Browser requests to the token endpoint must use Proof Key for Code Exchange

I am getting the error "Browser requests to the token endpoint must use Proof Key for Code Exchange" when trying to post the following request from my code. But the same is working from the postman. Am I missing anything here?

  const urlEncodeData = qs.stringify({
            grant_type: "client_credentials",
            client_id: "xxxxxxxxxxxx",
            client_secret: "xxxxxxxxxxxxx",
            scope: Scope,
        });
        const headers: any = {
            "Content-Type": "application/x-www-form-urlencoded",
          
        };

        const tokenData = await axios.post(
            `${issuer}/v1/token`,
            urlEncodeData,
            headers
        );

I tried using qs and urlsearchparams and nothing worked.

about 4 years ago · Juan Pablo Isaza
2 Respostas
Responde à pergunta

0

I believe the problem is that client_credentials flow assumes that you will be initiating a call to /token endpoint from a back-end server and not from your browser. So it might be an additional security check on Okta side, to discourage the use of inappropriate mechanisms/solutions

about 4 years ago · Juan Pablo Isaza Relatório

0

For client side application you are using and you should use PKCE Flow. Postman works because you are testing implicit flow, not the PKCE flow.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda