معرفی شرکت ها


django-simple-api-0.2.2


Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر

توضیحات

A non-intrusive component that can help you quickly create APIs.
ویژگی مقدار
سیستم عامل -
نام فایل django-simple-api-0.2.2
نام django-simple-api
نسخه کتابخانه 0.2.2
نگهدارنده ['waitan2018']
ایمیل نگهدارنده []
نویسنده abersheeran
ایمیل نویسنده me@abersheeran.com
آدرس صفحه اصلی https://github.com/Django-Simple-API/django-simple-api
آدرس اینترنتی https://pypi.org/project/django-simple-api/
مجوز -
**Language: English | [Chinese](README.zh-CN.md)** # Django Simple API A non-intrusive component that can help you quickly create APIs. ## Quick Start ### Install Download and install from github: ``` pip install django-simple-api ``` ### Configure Add django-simple-api to your `INSTALLED_APPS` in settings: ```python INSTALLED_APPS = [ ..., "django_simple_api", ] ``` Register the middleware to your `MIDDLEWARE` in settings: ```python MIDDLEWARE = [ ..., "django_simple_api.middleware.SimpleApiMiddleware", ] ``` Add the url of ***django-simple-api*** to your urls.py: ```python # urls.py from django.urls import include, path from django.conf import settings # Your urls urlpatterns = [ ... ] # Simple API urls, should only run in a test environment. if settings.DEBUG: urlpatterns += [ # generate documentation path("docs/", include("django_simple_api.urls")) ] ``` ### Complete the first example Define your url: ```python # your urls.py from django.urls import path from yourviews import JustTest urlpatterns = [ ..., path("/path/<int:id>/", JustTest.as_view()), ] ``` Define your view: ```python # your views.py from django.views import View from django.http.response import HttpResponse from django_simple_api import Query class JustTest(View): def get(self, request, id: int = Query()): return HttpResponse(id) ``` > ⚠️ To generate the document, you must declare the parameters according to the rules of ***Simple API*** (like the example above). > > Click [Declare parameters](https://django-simple-api.aber.sh/declare-parameters/) to see how to declare parameters. ### Access interface document After the above configuration, you can start your server and access the interface documentation now. If your service is running locally, you can visit [http://127.0.0.1:8000/docs/](http://127.0.0.1:8000/docs/) to view your documentation. ## More For more tutorials, see [Django Simple API](https://django-simple-api.aber.sh/).


نیازمندی

مقدار نام
<9.0.0,>=8.2.0 Pillow
- django
<2.0.0,>=1.8.1 pydantic


زبان مورد نیاز

مقدار نام
>=3.7,<4.0 Python


نحوه نصب


نصب پکیج whl django-simple-api-0.2.2:

    pip install django-simple-api-0.2.2.whl


نصب پکیج tar.gz django-simple-api-0.2.2:

    pip install django-simple-api-0.2.2.tar.gz