logologo
Get Started
Guide
Development
Plugins
API
Home
English
简体中文
日本語
한국어
Español
Português
Deutsch
Français
Русский
Italiano
Türkçe
Українська
Tiếng Việt
Bahasa Indonesia
ไทย
Polski
Nederlands
Čeština
العربية
עברית
हिन्दी
Svenska
Get Started
Guide
Development
Plugins
API
Home
logologo
Overview

API

API Keys
API Documentation
Usage Scenarios
SSO

Workflow

Webhook
HTTP Request
External Data Sources

Foreign Data Tables (FDW)

Overview
Enable MySQL Federated

Embedded Content

Iframe Block
Embed
Previous PageAPI Keys
Next PageUsage Scenarios

#API Documentation

This feature is provided by the plugin «API documentation»

#Introduction

The plugin generates NocoBase HTTP API documentation based on Swagger.

#Installation

This is a built-in plugin, no installation required. Activate to use.

#Usage Instructions

#Accessing the API Documentation Page

http://localhost:13000/admin/settings/api-doc/documentation

#Documentation Overview

  • Total API Documentation: /api/swagger:get
  • Core API Documentation: /api/swagger:get?ns=core
  • All Plugins API Documentation: /api/swagger:get?ns=plugins
  • Each Plugin's Documentation: /api/swagger:get?ns=plugins/{name}
  • API documentation for custom collections: /api/swagger:get?ns=collections
  • Specified ${collection} and related ${collection}.${association} resources: /api/swagger:get?ns=collections/{name}

#Developer Guide

#How to Write Swagger Documentation for Plugins

Add a swagger/index.ts file in the plugin's src folder with the following content:

export default {
  info: {
    title: 'NocoBase API - Auth plugin',
  },
  tags: [],
  paths: {},
  components: {
    schemas: {},
  },
};

For detailed writing rules, please refer to the Swagger Official Documentation.