Coder Social home page Coder Social logo

cheatsnake / emojihub Goto Github PK

View Code? Open in Web Editor NEW
117.0 2.0 15.0 195 KB

๐Ÿ˜บ A simple & free HTTP API with emojis for your cool apps

Home Page: https://emojihub.yurace.pro/api/random

License: MIT License

Dockerfile 1.53% Go 98.47%
emoji api free typescripts nestjs random emoji-unicode emoji-list public-api

emojihub's Introduction

EmojiHub GitHub repo size GitHub repo size GitHub repo size

EmojiHub provides an opportunity to get random emojis from already sorted categories and groups. You can also get a whole list of emojis by a certain category, group, or get the entire emoji database consisting of 1791 objects.

All emoji data is stored in a simple JSON object from which you can get html codes to insert into your web applications.

๐Ÿ“„ API documentation

  • Get random emoji
GET https://emojihub.yurace.pro/api/random
{
    "name": "hugging face",
    "category": "smileys and people",
    "group": "face positive",
    "htmlCode": ["🤗"],
    "unicode": ["U+1F917"]
}
  • Get an array of all emojis
GET https://emojihub.yurace.pro/api/all

Each endpoint can be supplemented by a path to a specific category or group:

/category/{category-name}
/group/{group-name}

๐Ÿ“š Table with all available emoji categories and groups:

Category Groups
smileys-and-people body, cat-face, clothing, creature-face, emotion, face-negative, face-neutral, face-positive, face-positive, face-role, face-sick, family, monkey-face, person, person-activity, person-gesture, person-role, skin-tone
animals-and-nature animal-amphibian, animal-bird, animal-bug, animal-mammal, animal-marine, animal-reptile, plant-flower, plant-other
food-and-drink dishware, drink, food-asian, food-fruit, food-prepared, food-sweet, food-vegetable
travel-and-places travel-and-places
activities activities
objects objects
symbols symbols
flags flags

๐ŸŽฏ Examples

https://emojihub.yurace.pro/api/random/group/face-positive
https://emojihub.yurace.pro/api/random/category/food-and-drink
https://emojihub.yurace.pro/api/all/category/travel-and-places
https://emojihub.yurace.pro/api/all/group/animal-bird

๐Ÿš€ Server startup

  1. Clone this repository:
git clone https://github.com/cheatsnake/emojihub.git
cd ./emojihub
  1. Inside the project, run this command to install the necessary packages:
go mod download

Make sure you have already installed Go on your computer.

  1. Start the server by running the last command:
go run cmd/main.go

The server will start at the address: http://localhost:4000

๐Ÿณ Docker container startup

Run the following commands to create an image and start the container:

docker build -t emojihub . --target production
docker run -p 4000:4000 --name emojihub-server emojihub

emojihub's People

Contributors

ccmtaylor avatar cheatsnake avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

emojihub's Issues

Using emojihub in a student project

Hi @cheatsnake - one of our teachers at scrimba.com wants to use your api in a project she is building for students. For public api's I prefer that we host our own version for students it since it is not uncommon for public api's to change domains, path structure to change in versions, they go down etc. which creates issues for our recorded material. This also reduces the traffic from your heroku instance.

Happy to put in canonical url tags,etc. to give you any seo,etc. Feel free to reach out on frode at scrimba to discuss as well.

Heroku application error

I want to access the emoji data but am unable to - when I copy paste the given urls like https://emojihub.herokuapp.com/api/random/group_face_positive into my browser and search I get the following message: "An error occurred in the application and your page could not be served. If you are the application owner, check your logs for details. You can do this from the Heroku CLI with the command
heroku logs --tail"

Migrated from Heroku

Migrated from Heroku

Hello, Developers! Due to the closure of free hosting service Heroku, I decided to move all my public APIs projects on my own server.

Because of this, the EmojiHub has undergone some changes:

  1. The new permanent domain name - emojihub.yurace.pro.
  2. Complete rewrite of the code in Go language (now everything is fast, lightweight and easy to clone). You can still find the old version in the special branch.
  3. Updated API endpoints (following to best practices).

Hopefully in the future there will be no such incompatible changes and now we will be completely focused only on adding new functionality.

Thank you for continuing to use the EmojiHub API!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.