Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

4 Commits

Repository files navigation

SUMMARY


It is a REST API about the characters of OPM (One Punch Man). It includes some features such as:

  • Character skills
  • Nicknames
  • Age and special ability
  • Physical attributes (Height & weight)
  • Human & monster classification
  • Weapons and ranking system

All routes

  • GET /api/generateCode
  • POST /api/generateToken
  • GET /api/actor/:name
  • PATCH /api/actor/updateAge
  • GET /api/actors/occupation/:occupation
  • GET /api/actors/heroes/byClass/:letter
  • GET /api/actors/height?gte=:min&lte=:max
  • GET /api/actors/weight?gte=:min&lte=:max
  • PATCH /api/actor/addAbilities
  • DELETE /api/actor/removeAbilities
  • PATCH /api/actor/updateWeight
  • PATCH /api/actor/updateHeight
  • GET /api/actors/race/:race
  • PATCH /api/actor/addWeapons
  • GET /api/actors/age?gte=:min&lte=:max
  • GET /api/actors/sameAbilities
  • DELETE /api/actor/:name
  • POST /api/actor/new

Build your own with Surreal Cloud

Below are the standard environment variables:

DB_USER=your_usernameDB_PASS=your_password
URL_INSTANCE=wss://your.provided.link.surreal.cloudDB_NM=your_namespaceDB_NAME=your_db_nameDB_TABLE=your_table_name
URL_INSTANCE_TEST=http://127.0.0.1:8000/rpcSALT=your.secret.tokenFROM_EMAIL=you@gmail.comAPP_GMAIL_PASSWORD=yourgmailpassword

Data

After creating an instance in Surreal Cloud, you can copy and paste this data.


Run Tests

First, you need to install SurrealDB on your device. Then, you can copy and paste the command below to initialize SurrealDB:

surreal start --user root --pass root --bind 0.0.0.0:8000 rocksdb:/your/path/my-local-db/

Now, you can run the tests properly:

npm run test

Important

Comming soon, the user will add new attributes in a specific record.

About

REST API includes a rate limiting from scratch using One Punch Man characters data.

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Used by

Contributors

Languages