# Leslin/thinkphp5-restfulapi

restful-api风格接口 APP接口 APP接口权限  oauth2.0 接口版本管理 接口鉴权

Repository: https://github.com/Leslin/thinkphp5-restfulapi
Canonical: https://ross.abutalabs.com/products/thinkphp5-restfulapi
Language: PHP
License: NOASSERTION
License Family: other
Topics: thinkphp5, restful-api, tp5, api-server, restful, thinkphp5-restfulapi
Last push: 2023-03-29T08:51:33+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 3276, "days_push": 1253, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1014, forks 349 (observed 2026-08-28T04:03:13.912393+00:00)

## What it is
A lightweight RESTful API starter built on ThinkPHP 5.1, providing token-based authentication (OAuth2-style access/refresh tokens), API versioning, and permission checks in under 200 lines of code. It is aimed at PHP developers building mobile-app or web API backends on the ThinkPHP framework.

## Use cases
- build a restful api backend with thinkphp5
- add oauth2 access token authentication to php api
- version my api endpoints v1 v2
- secure app interfaces with token-based auth
- refresh token flow for mobile app api
- whitelist routes that skip authentication

## When to choose
- you are already using ThinkPHP 5.x and need a quick API skeleton with auth
- you want a minimal, readable codebase to customize for app backends

## When to avoid
- you use a modern PHP framework like Laravel or Symfony
- you need a non-RESTful or microservice architecture
- your project requires a permissive license (it uses the 996-prohibited NPL license)
- you need long-term support - the project is based on an aging framework

## Facets
- artifact type: framework
- maturity: maintenance
- function: api-framework, auth, routing, middleware, http-server
- domain: web-development, backend, apis
- platform: php, self-hosted
- tags: thinkphp5, restful-api, oauth2, access-token, api-versioning, app-backend, web-server

## Member repositories
- Leslin/thinkphp5-restfulapi (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:13.912393+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:11:30.974662+00:00, confidence not recorded.
  - readme: https://github.com/Leslin/thinkphp5-restfulapi (fetched 2026-08-28T04:03:13.912393+00:00, sha cc32b28924ea)
- Data as of 2026-08-30T08:39:29.467469+00:00.
