Badgeyay: REST API Enhancement

Created on 7 Jan 2018  Β·  18Comments  Β·  Source: fossasia/badgeyay

I'm submitting a ...

  • [ ] bug report
  • [x] feature request

Expected behavior:
This is the structure for our backend which I had thought of to make the code more maintainable. The following directory tree shows where each part of the logic is located.

β”œβ”€β”€ api                         #
β”‚   β”œβ”€β”€ generate                #
β”‚   β”‚   β”œβ”€β”€ main.py             #
β”‚   β”‚   β”œβ”€β”€ endpoints           #  API namespaces and REST methods
β”‚   β”‚   β”œβ”€β”€ parsers.py          #  Argument parsers
β”‚   β”‚   β”œβ”€β”€serializers.py       #  Output serializers
|   |   β”œβ”€β”€other files           #
β”‚   └── restplus.py             #  API bootstrap file
β”œβ”€β”€ app.py                      #  Application bootstrap file
β”œβ”€β”€ database                    #
β”‚   └── models.py               #  Definition of SQLAlchemy models
β”œβ”€β”€ tests                       #  Tests for testing of API
β”œβ”€β”€ db.sqlite                   #
└── settings.py                 #  Global app settings

Your views please
Cc: @harshit98 @ParthS007 @mariobehling @djmgit @abishekvashok

Enhancement Parent issue

Most helpful comment

Hey, can I help as well?

All 18 comments

Looks good to me @vaibhavsingh97 πŸ‘ , Looking forward to working on this

Solving this issue also solves #437

@vaibhavsingh97 Please create a checklist after tree structure so that others can contribute to it also πŸ‘

Looks good to me @vaibhavsingh97. Can we have sub issues once someone like
@mariobehling or @djmgit review?

Yes I suppose. There are many things to be finalized as of now.
It will be broken down into multiple issues to ensure parallel development

Okay, great @vaibhavsingh97. Looks good to me! Can you share, how this issue can be divided into sub-tasks?

@harshit98 So I and @ParthS007 will collaborate to make the develop the basic structure of API (Swagger UI will automatically added in this process which also solves this https://github.com/fossasia/badgeyay/pull/460).

After that to make the generated file persistent we will save in the database, authenticatoin will be added, make badges distinguishable by providing hashes and delete badges after 10 days or so after authentication and authentication tokens with hashes in the db. I will create one parent issue after solving this issue and link these with sub issues and can be claimable by anyone.

Okay. Please go ahead @vaibhavsingh97.

I would love to help as well @ParthS007 & @vaibhavsingh97

I would also love to help as well @vaibhavsingh97 @ParthS007 @gabru-md

Hey, can I help as well?

Sure @abishekvashok you can also help : )

Maybe lets have this as a parent issues and achieve this step by step. Adding parent issue label.

Thanks @abishekvashok Let me send PR by EOD. Sorry for being late

@vaibhavsingh97 @abishekvashok what's the problem with bootstrap model, why do we need to shift to swagger UI ?

Sorry, I mistook this with Semantic UI (was reading about it the other day). So we are adding Swagger UI for documentation purpose of API (similar to open-event-server https://open-event-api.herokuapp.com/ ) ? @vaibhavsingh97 @abishekvashok.

Yea

We are following this in #627 . Hence this can be closed :+1:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

niccokunzmann picture niccokunzmann  Β·  6Comments

niccokunzmann picture niccokunzmann  Β·  5Comments

vaibhavsingh97 picture vaibhavsingh97  Β·  8Comments

vaibhavsingh97 picture vaibhavsingh97  Β·  6Comments

nanspro picture nanspro  Β·  5Comments