Skip to content

Quick start


pip install fastapi_amis_admin

Simple example

  1. Create the file
from fastapi_amis_admin.admin.settings import Settings
from import AdminSite
from fastapi_amis_admin.admin import admin
from fastapi_amis_admin.amis.components import PageSchema

# Create AdminSite instance
site = AdminSite(settings=Settings(database_url_async='sqlite+aiosqlite:///amisadmin.db'))

# Registration management class
class GitHubIframeAdmin(admin.IframeAdmin):
    # Set page menu information
    page_schema = PageSchema(label='AmisIframeAdmin', icon='fa fa-github')
    # Set the jump link
    src = ''
  1. Create the file
from fastapi import FastAPI
from adminsite import site

app = FastAPI()

# Mount the background management system

if __name__ == '__main__':
    import uvicorn

Run the program

uvicorn main:app

Interface preview

  • Open a browser to access:

Smple program

  • FastAPI-User-Auth: A simple and powerful FastAPI user RBAC authentication and authorization library.
  • FastAPI-Scheduler: A simple scheduled task management project based on FastAPI+APScheduler.

More features