A public JSON API for Wordle with vue.js frontend

Related tags

Web Game wordle-API
Overview

Wordle API

A public JSON API for Wordle. This repo also includes a frontend made with Vue.js.

See it in action here.

Why?

The original Wordle game only allows you to play 1 game per day. It is also extremely easy to cheat as the answer to the puzzle is sent to the client before it has been solved.

This version solves these issues.

Architecture

What's notable about this rendition of Wordle is that all of the guessing happens through a server-side JSON api.

This means that it is impossible to cheat, the answer is never stored in the browser before the puzzle has been finished.

Even looking at the backend source code will not reveal the answer, as the wordlist is shuffled before it is inserted into the database.

Public API

You can use the public API to make your own Wordle game! Also feel free to copy the backend code and self-host it.

API Documentation

If you need any help with using this API, please open an issue!

POST /api/v1/start_game/

Request body (optional)

{
  "wordID": int
}

If you don't include wordID, a random word is chosen.

Response body

{
  "id": int,
  "key": string,
  "wordID": int
}

id is a unique ID for this game.

key is a random string used to validate future actions for this game.

wordID is a unique ID identifying this word. You can use this ID to play the same game again, without leaking the answer.

POST /api/v1/guess/

Request body

{
  "id": int,
  "key": string,
  "guess": string
}

Response body

[
  {
    "letter": char,
    "status": int
  },
  ...
]

status is an int of value 0, 1, or 2. 0 means the letter is not present in the word. 1 means the letter is present in the word. 2 means the letter is present in the word and is in the correct position.

For example: โฌ› ๐ŸŸจ ๐ŸŸจ ๐ŸŸฉ โฌ› is represented as 0 1 1 2 0

Errors

  • 400 Bad Request if the word is the wrong length, contains non-letters, or is not in the dictionary
  • 403 Forbidden if the game has been finished, or already has 6 guesses

POST /api/v1/finish_game

Request body

{
  "id": int,
  "key": string
}

Response body

{
   "answer": string
}

After calling this, you will be unable to make more guesses as the answer has been revealed.

Dev environment quick start

python3 -m venv .venv

. .venv/bin/activate

python3 -m pip install --upgrade wheel pip

python3 -m pip install -r requirements.txt -r requirements-dev.txt

pre-commit install

python3 init.py

FLASK_DEBUG=1 flask run --cert=adhoc --host=0.0.0.0

The dev server is accessible on https://localhost:5000.

https is necessary for the async clipboard API to work on IOS. You may have to click through a warning about an invalid certificate.

You might also like...

The extension to help you when you badly don't want to mess up your wordle streak

Your last resort in woordle to maintain your woordle win streak

Feb 3, 2022

๐ŸŸฉ in case you want to cheat on your wordle games

Wordle Solver How to use Enter each right guess in the first grid Enter all letters that you know aren't in a certain position in the second grid For

Feb 7, 2022

Wordle but it's on your Terminal!

Wordinal Wordle but it's on your Terminal! What's Wordle? ๐Ÿค” Wordle is a classic word guessing game developed by Josh Wardle. Players have six attempt

Apr 12, 2022

I found 'WORDLE' game is hackable . we get solution on localStorage. I just prevented this.

WordleGame() Demo: https://shobdokhela.vercel.app Go play the real Wordle here Read the story behind it here Main Author Hannah Park Inspiration: I fo

Mar 6, 2022

๐Ÿ“Ÿ Chrome extension to solve Wordle puzzles.

๐Ÿ“Ÿ Chrome extension to solve Wordle puzzles.

๐Ÿ“Ÿ Chrome extension to solve Wordle puzzles. Learn to build Node.js CLI apps. wordle-solved ๐Ÿ“ฆ Chrome extension that solves Wordle puzzles for you ๐Ÿคฏ

Feb 8, 2022

Italian version of Wordle

Par ๐Ÿ‡ฎ๐Ÿ‡น le https://pietroppeter.github.io/wordle-it/ Una versione italiana (non ufficiale) di WORDLE. Se l'autore di Wordle non approva, lo tiro giรน:

Dec 18, 2022

A Wordle trainer, for the lols.

This is a Next.js project bootstrapped with create-next-app. Getting Started First, run the development server: npm run dev # or yarn dev Open http://

Mar 10, 2022

Chrome extension for the game called Wordle

Chrome extension for the game called Wordle

Chrome extension for the game called Wordle. No need to get stuck again while you have this at your side. Climb up that leader board!

Sep 17, 2022

JavaScript library guessing game, a Wordle clone

Jazle JavaScript library guessing game, a Wordle clone. A fork of cwackerfuss/react-wordle. See the list of accepted libraries: wordlist.ts Build and

May 26, 2022
How to build a multiplayer Wordle clone with Liveblocks, Vue, and Vite

Wordle Wars This repo shows how to build a multiplayer Wordle clone with Liveblocks, Vue, and Vite. Try it out It's forked from VVowrdle created by Ev

Chris 71 Dec 8, 2022
A clone of the popular Wordle game.

Wordle Clone How to play locally: yarn install

null 2 Jan 9, 2022
A clone of the popular game Wordle made using React, Typescript, and Tailwind

Wordle Clone Go play the real Wordle here Read the story behind it here Try a demo of this clone project here Inspiration: This game is an open source

Hannah Park 2.4k Jan 8, 2023
Wordle2Townscaper is meant to convert Wordle tweets into Townscaper houses using yellow and green building blocks.

Wordle2Townscaper Wordle2Townscaper is meant to convert Wordle tweets into Townscaper houses using yellow and green building blocks. You can download

Tarmo 66 Nov 2, 2022
Provides 5 keywords with which to narrow down your wordle game. I ruin nice things.

Widdle?? I hate fun so I wrote a script that ruins Wordle. This script can be used to find a Widdle, a set of five words that cover nearly all letters

Tess Myers 3 Mar 12, 2022
A simple wordle solver for Node.js

This is just a weekend project, so take it easy :-) simple-worlde-solver Wordle solver for Node.js. I am aware of other efforts that use greedy algori

Alessandro Toppi 3 Feb 20, 2022
WORDLEBOARD prototype: Show your Wordle game on a Vestaboard as you play.

WORDLEBOARD prototype Show your Wordle game on a Vestaboard as you play. Copyright (c) 2022, Scott Schiller. MIT license. Made with love and fun in mi

Scott Schiller 7 Dec 20, 2022
CLI to to solve your Wordle puzzle daily

?? CLI to to solve your Wordle puzzle daily. Learn to build Node.js CLI apps. wordle-solved-cli ?? CLI that solves Wordle puzzles for you ?? Automatic

Ahmad Awais โšก๏ธ 8 Feb 2, 2022
A Wordle-like game where you have to guess the unsigned 8-bit binary number

Bytle A Wordle-like game where you have to guess the unsigned 8-bit binary number! Game coded in 2h 14m 50.570s, but it's not like I'm counting how lo

James Livesey 16 Jun 30, 2022
Latin Wordle is a free and open-source project that aims to provide a fun and interactive way to learn Latin.

Latin Wordle Live Game Here Inspiration Latin Wordle is a free and open-source project that aims to provide a fun and interactive way to learn Latin.

null 15 Dec 16, 2022