Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Реализовать GET /api/stupid_achievments #178

Closed
qelphybox opened this issue Jan 4, 2021 · 2 comments
Closed

Реализовать GET /api/stupid_achievments #178

qelphybox opened this issue Jan 4, 2021 · 2 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@qelphybox
Copy link
Owner

GET /api/stupid_achievments - отдает все поддерживаемые глупые ачивки.

  1. Валидируем данные сессии (https://core.telegram.org/widgets/login#checking-authorization)
  2. Если валидно отдаем:
    200 OK
    {   
      "status": "ok",
      "stupid_achievments": [
        { "title": "Количество сообщений", "name": "messages_count" },
        { "title": "Безработный", "name": "workless_user" },
        { "title": "Поставщик контента", "name": "content_supplier" },
        { "title": "Худший юзер чата", "name": "worst_chat_user" },
        { "title": "Стикерпакер", "name": "stickerpacker" },
        { "title": "Пропавший без вести", "name": "maybe_died" },
        { "title": "Дудь", "name": "dud" },
        { "title": "Философ", "name": "philosopher" }
      ] 
    }
  3. Если невалидно, отдаем
    403 Forbidden
    {
      "status": "forbidden"
    }
@qelphybox qelphybox added the good first issue Good for newcomers label Jan 4, 2021
@smthingwicked
Copy link
Contributor

беру

@qelphybox
Copy link
Owner Author

@smthingwicked Спасибо! Ждём пулреквеста

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants