Open source API for the awesome Elden Ring game :)

Overview

Elden Ring API

eldenring-opensource-logo

Description

This repository holds the code for Elden Ring API. This consists of a RESTful API and GraphQL API of our beloved FromSoft game.

Get started at: https://eldenring.fanapis.com

Tech Stack

Deployment: Vercel

Engine: NextJS Docs: Docusaurus v2 Media Hosting: GitHub

Building

In order to build this project just clone this repository and install the dependencies:

user@admin:~$ git clone https://github.com/deliton/eldenring-api.git && cd eldenring-api
user@admin:~/fanapis-template$ yarn && yarn dev

Deploy

You can also quickly deploy a version of this repository using Vercel. Just create an account there, import this repository and that's it, it's done. In order to properly use this API it is necessary to define some ENVIRONMENT VARIABLES:

API_URL= URL TO THE DOMAIN OF YOUR API

Tech Description

This template uses NextJS API routes to deliver data, and to achieve that we use static JSON files with a simple JSON driver to filter and join between different files.

Comments
  • FIX: Allow lookup of _scaling_ values in GQL

    FIX: Allow lookup of _scaling_ values in GQL

    A typo in a GQL field leads to an attempted lookup of a nonexistent JSON key. Update the schema and corresponding documentation.

    Loving the API! I noticed scaling tiers were returning null from the GQL endpoint- looks like a little typo:

    Request

    # extra L in `scalling`, as defined in GQL schema
    curl 'https://eldenring.fanapis.com/api/graphql' -H 'Content-Type: application/json' --data-binary '{"query":"{getWeapon(id:\"17f69d12746l0i1ojbzxzgz6gfjsi\"){name scalesWith{name scalling}}}"}'
    

    Response

    {"data":{"getWeapon":{"name":"Longbow","scalesWith":[{"name":"Str","scalling":null},{"name":"Dex","scalling":null}]}}}
    
    opened by julesferreira 4
  • Eccentric's Manchettes description is incorrect

    Eccentric's Manchettes description is incorrect

    Should be:

    The knight Jerren's manchettes.

    Jerren preferred a nomadic existence, but after spending time as a guest of the Carian royals, he became the guest commander for General Radahn. And for the first time, the restless tumbleweed would be bound by honorable oath.

    Currently is:

    Gauntlets of the Cleanrot Knights, celebrated for their undefeated campaign in the Shattering. The Cleanrot Knights vowed to fight alongside Malenia, despite the inevitable, if gradual, putrefaction of their flesh. Their acceptance of their fate made these battles fiercest of all.

    opened by kartikdc 3
  • Inconsistency with Weapon Category

    Inconsistency with Weapon Category

    There are plural and non plural versions of categories, ie: Greatsword and Greatswords , Dagger and Daggers. This makes using the category argument tricky due to having to handle both category arguments for one category type.

    opened by RyanGreenburg 2
  • data.requires[{ inconsistent array}]

    data.requires[{ inconsistent array}]

    This is just looking at the "sorceries" request, but I wouldnt be shocked if it went further. So when looking at the array of "requires" it is too inconsistent to use as a source of sorting the overall fetch. we see that there are some which contain "intelligence" "faith" and "arcane" (ideal) while others will be missing some of the attributes or will have abbreviated the name (check out "Carian Slicer" requires [{"name": "Int", "amount": 14]) this is making it impossible to cater a list based on these nested arrays. Is there anyway to fix this across all fields (including weapons, incantations, ect?)

    Thanks so much!

    opened by TheRayCannon 2
  • Issue querying stats on Class

    Issue querying stats on Class

    Getting this error: Expected Iterable, but did not find one for field \"Class.stats\"." The query thinks stats should return an array of ClassStats where the JSON is not set up as an array.

    opened by RyanGreenburg 2
  • Epic/version 0.1.1 release

    Epic/version 0.1.1 release

    • Max limit increased to 100
    • Added "Search" to all GraphQL objects
    • added "total" in REST responses. This corresponds to the max amount of objects for that model
    • Lots of improvements in data quality for "Armors" objects.
    • Fix ashes of war REST route
    opened by deliton 2
  • Making an iOS app

    Making an iOS app

    Hello,

    Thanks for this great API! I’ve sent you messages over Reddit but I have no ideas if you read those, so I’m making an issue here :) I’m making an iOS app using your GQL API, you can see it here: https://github.com/Dimillian/The-Roundtable Do you plan to add a search API? Would be wonderful. If you’re not planing to do it I can look into it. Also some kind of filter / sort would be great. For example being able to request weapons by scaling rank or armor by weight.

    Thanks for this great API!

    Here is some screens: Screenshot 2022-03-21 at 19 20 47 Screenshot 2022-03-21 at 21 34 25 Screenshot 2022-03-21 at 21 34 31

    opened by Dimillian 2
  • return total amount

    return total amount

    Hey, super cool API! I just started playing around with it a bit and noticed that the API doesn't return the total amount of possible data, which makes pagination a bit tricky. Could you add a field like total next to count, so people don't have to "brute force" check if there is more data available than initially requested?

    opened by jon4hz 2
  • Rounded Values + nulls where 0s should be

    Rounded Values + nulls where 0s should be

    Looking at some values from armor pieces, I could see all(?) values have been rounded down. E.g.: Black Dumpling Your values = dmgNegation: 2 3 2 2 3 3 3 3; resistance: 24 15 null 20 null Actual values = dmgNegation: 2.8, 3.1, 2.8, 2.8, 3.1, 3.4, 3.6, 3.1; resistance: 24 15 0 20 0

    It would be awesome, if you could get more accurate numbers and maybe even replace the nulls with 0s.

    opened by ItamiKyojin 1
  • Feature/04 13 2021 release

    Feature/04 13 2021 release

    • improved data quality
    • added descriptions to all armors
    • fixed class stats issue
    • removed parenthesis from names (REST couldn't search)
    • Fixed weight typo
    opened by deliton 1
  • GraphQL CORS

    GraphQL CORS

    Hi there. Great API and thanks for all the work putting this together!

    I am trying to hit this API from the browser and getting a CORS pre-flight issue. Specifically:

    405 Method Not Allowed

    Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://eldenring.fanapis.com/api/graphql. (Reason: CORS preflight response did not succeed). Status code: 405.
    

    I do see in the Response Headers that you have access-control-allow-origin: * (which is correct if you intend to allow browsers to hit the API). But I also see there is an Allow header which is restricted to GET, POST. I believe this might be the problem.

    Since you are using Next.js, I think we can just follow the example here to fix this.

    I am happy to make a PR with these changes if you agree with the root cause and the suggestion solution. Please let me know. Thank you.

    opened by willsoto 1
  • fixed Phy20, Phy40, Phy100 values

    fixed Phy20, Phy40, Phy100 values

    To improve data consistency, changed Phy20 to ("physical", 20), Phy40 to ("physical", 40) and Phy100 to ("physical", 100)

    opened by rmirabelli 2
  • Api returning null on some values with graphql

    Api returning null on some values with graphql

    I was trying to obtain the levels assigned to the classes, but there is a misspelling on the words "inteligence" and "strenght" using graphql. image

    opened by Richard-The-Wise 0
  • Upgraded weapon stats

    Upgraded weapon stats

    Noticed that all weapon stats appear to be pre-upgrade. It would be useful to see at least max upgrade stats so that weapons can be compared at that point.

    Thanks.

    opened by MrManlyPrincess 0
Owner
Deliton Junior
Passionate developer, tech enthusiast and learning a bit of everything.
Deliton Junior
Hemsida för personer i Sverige som kan och vill erbjuda boende till människor på flykt

Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

null 4 May 3, 2022
Kurs-repo för kursen Webbserver och Databaser

Webbserver och databaser This repository is meant for CME students to access exercises and codealongs that happen throughout the course. I hope you wi

null 14 Jan 3, 2023
This project is an Awesome Books web page where users can add or remove books from the site. It also displays a list of the books added to the collection. This Awesome books webpage was created using ES6.

Awesome books App using Module Awesome books App using Module This book list was built using modules and other ES6 syntax. It allows users to add/remo

Esther Udondian 6 Jul 25, 2022
An Awesome Toggle Menu created with HTML,CSS,JQuery,font-awesome and line by line comment.

Demo : https://blackx-732.github.io/AwesomeMenu/ Under open source license No ©copyright issues Anyone can be modify this code as well Specifically we

BlackX-Lolipop 2 Feb 9, 2021
Reference for How to Write an Open Source JavaScript Library - https://egghead.io/series/how-to-write-an-open-source-javascript-library

Reference for How to Write an Open Source JavaScript Library The purpose of this document is to serve as a reference for: How to Write an Open Source

Sarbbottam Bandyopadhyay 175 Dec 24, 2022
An Open-Source Platform to certify open-source projects.

OC-Frontend This includes the frontend for Open-Certs. ?? After seeing so many open-source projects being monetized ?? without giving any recognition

Open Certs 15 Oct 23, 2022
Shikhar 4 Oct 9, 2022
This is a project for open source enthusiast who want to contribute to open source in this hacktoberfest 2022. 💻 🎯🚀

HACKTOBERFEST-2022-GDSC-IET-LUCKNOW Beginner-Hacktoberfest Need Your first pr for hacktoberfest 2k22 ? come on in About Participate in Hacktoberfest b

null 8 Oct 29, 2022
Free, open source game engine online

microStudio is a free, open source game engine online. It is also a platform to learn and practise programming. microStudio can be used for free at ht

Gilles 719 Dec 30, 2022
An open-source server software for a certain anime game.

Open-Shen An open-source server software for a certain anime gaem. Based off the leaked Pancake and closed-source Bridge servers. You can find the Ope

Magix 68 Dec 10, 2022
Free open-source game cheat for Tanki Online.

shizoval Free open-source game cheat for Tanki Online. snusoedik#4769 Features AirBreak - air walk Clicker - auto use FAK/supplies/mines FPS Up - remo

null 16 Dec 24, 2022
FCIV.NET is a open source strategy game loosely based on Freeciv

FCIV.NET FCIV.NET is an open-source turn-based strategy game. It can be played in any HTML5 capable web-browser and features in-depth game-play and a

FCIV.NET 13 Nov 22, 2022
🏃‍♂️Open source, puzzle based adventure game in your browser

??‍♂️ Rungeon Rungeon is an open source, puzzle based adventure game. ?? About Rungeon features a series of puzzles in the form of stages, in which th

null 16 Aug 25, 2022
Futuristic tank game. Pure JavaScript with ThreeJS. Open Source

Retro-futuristic tank game. Pure JavaScript with ThreeJS. Open Source SYNTHBLAST.COM Gameplay shoot tanks Run over all yellow pads to advance a level

Brian Risk 107 Dec 11, 2022
This is the open source version of the fan-made game Plants vs Zombies Travel.

Plants vs Zombies Travel — A Fan-Made PvZ Game! What's PvZ Travel? Plants vs Zombies Travel ("《植物大战僵尸:旅行》" in Chinese) is a fan-made PvZ Game, written

JiangNanGame 12 Dec 3, 2022
Clinton Mbonu 20 Jun 30, 2022
An open source API wrapper for TechHost API.

TechHost API Wrapper An open source API wrapper for TechHost API. Badges Installation Install techhost-api-wrapper with npm. npm install techhost-api-

Eight∞ 4 Jun 23, 2022
A recreation of a startpage posted on Reddit without the source, so I rewrote it in Next.js + Tailwind for the open source community.

Startpage "Figma Balls" Rewrite Why Did I Make This I saw a startpage posted on the subreddit r/startpages that I thought looked nice, but when I look

Thomas Leon Highbaugh 5 Mar 29, 2022