lmmfranco / nintendo-switch-eshop

Crawler for Nintendo Switch eShop
Apache License 2.0
517 stars 82 forks source link

Fetching of Games failed #261

Closed croccio closed 3 years ago

croccio commented 3 years ago

Hi i get always this error: Fetching of EU Games failed Fetching of US Games failed Fetching of JP Games failed

from these requests: getGamesEurope() getGamesAmerica() getGamesJapan()

favna commented 3 years ago

My best guess is that it is somehow related to your network, I just tried it out myself and it still works just fine.

For example, make sure that you are not blocking Nintendo's servers because you have a modded Switch and don't want it to go online (a common practice in the Nintendo Switch hacking scene).

Closing this because it's not related to the library.

Sample I tried:

const { getGamesAmerica } = require('nintendo-switch-eshop');

(async () => {
    try {
        const games = await getGamesAmerica();

        console.log(games[0]);
    } catch (error) {
        console.error(error)
    }
})();

games[0] is:

{
  type: 'game',
  locale: 'en_US',
  url: '/games/detail/super-kirby-clash-switch',
  title: 'Super Kirby Clash™',
  description: 'To defeat bosses this wicked, it’ll take a whole team of Kirbys! In this free-to-start multiplayer* action game, you can choose from four unique Roles and join up to three other players to take down tough bosses. Puff up your power by crafting weapons and spending materials at the shop to receive even MORE weapons, not to mention armor and items. Pass a Joy-Con™ controller to a friend to play locally, and if you have a Nintendo Switch Online membership, you can even play online**!\n' +
    'Are you a Sword Hero? Hammer Lord? Beam Mage? Or Doctor Healmore?! No matter what, each mighty role offers up a unique way to play. Story Quest lets players team-up locally* by sharing Joy-Con controllers, while Party Quest enables users to play together on one system, via local wireless, or online**. Plus, tapping compatible amiibo™ figures/accessories *** will earn you extra fragments to help craft new gear! Are you ready? For Kirby, the answer is always fight and flight.',
  lastModified: 1596520928388,
  nsuid: '70010000022951',
  slug: 'super-kirby-clash-switch',
  boxArt: '/content/dam/noa/en_US/games/switch/s/super-kirby-clash-switch/Switch_SuperKirbyClash_box_eShop.png',
  gallery: 'U2bzJpaTE6f4bVXYJo5z5bVZQ81s30vW',
  platform: 'Nintendo Switch',
  releaseDateMask: '2019-09-04T00:00:00.000-07:00',
  characters: [ 'Kirby' ],
  categories: [ 'Action' ],
  msrp: 0,
  esrb: 'Everyone',
  esrbDescriptors: [ 'Mild Fantasy Violence', 'Users Interact', 'In-Game Purchases' ],
  virtualConsole: 'na',
  generalFilters: [ 'Online Play via Nintendo Switch Online' ],
  filterShops: [],
  filterPlayers: [ '3+', '2+', '1+' ],
  publishers: [ 'Nintendo' ],
  players: 'up to 4 players',
  featured: true,
  freeToStart: true,
  priceRange: 'Free to start',
  salePrice: null,
  availability: [ 'Available now' ],
  objectID: '73d8d1f8-526d-31a6-a566-c9e8eea97a85',
  _distinctSeqID: 0,
  _highlightResult: {
    title: {
      value: 'Super Kirby Clash™',
      matchLevel: 'none',
      matchedWords: []
    },
    nsuid: { value: '70010000022951', matchLevel: 'none', matchedWords: [] },
    publishers: [ [Object] ]
  }
}