Skip to content

Still missing CORS header #289

Description

@dwicao

Hi! I've used PokeAPI in my React.js pure client-side app [repo],
any API calls fail because it still missing CORS header,
although I've been set a user agent header { 'User-Agent': 'cheese' },
any workarounds?

SOLVED: cloudflare messes up the request.

  1. Try add a slash to the end of the request - http://pokeapi.co/api/v2/

  2. Try change API endpoints from http://pokeapi.co/api/v2 to http://pokeapi.salestock.net/api/v2
    It works! 🎉 🎉 🎉

  3. Or as a temporary remedy, you can try cors.now.sh
    https://cors.now.sh/https://pokeapi.co/api/v2/

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    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