{"id":22108936,"url":"https://github.com/itxq/api-doc-php","last_synced_at":"2025-09-01T03:34:09.699Z","repository":{"id":56994609,"uuid":"136263136","full_name":"itxq/api-doc-php","owner":"itxq","description":"根据接口注释自动生成接口文档","archived":false,"fork":false,"pushed_at":"2018-07-12T07:38:39.000Z","size":163,"stargazers_count":15,"open_issues_count":0,"forks_count":8,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-25T08:51:41.952Z","etag":null,"topics":["api","doc","php"],"latest_commit_sha":null,"homepage":"https://www.xqitw.cn","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/itxq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-06-06T02:53:46.000Z","updated_at":"2024-05-16T17:21:08.000Z","dependencies_parsed_at":"2022-08-21T13:50:38.231Z","dependency_job_id":null,"html_url":"https://github.com/itxq/api-doc-php","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/itxq/api-doc-php","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itxq%2Fapi-doc-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itxq%2Fapi-doc-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itxq%2Fapi-doc-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itxq%2Fapi-doc-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/itxq","download_url":"https://codeload.github.com/itxq/api-doc-php/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/itxq%2Fapi-doc-php/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273069704,"owners_count":25040103,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-01T02:00:09.058Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","doc","php"],"created_at":"2024-12-01T09:27:16.338Z","updated_at":"2025-09-01T03:34:09.670Z","avatar_url":"https://github.com/itxq.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Api-Doc-PHP\n\n### 主要功能：\n\n+ 根据接口注释自动生成接口文档\n\n### 演示地址\n\n[【Gitee Pages:】http://itxq.gitee.io/api-doc-php](http://itxq.gitee.io/api-doc-php)\n\n### 开源地址：\n\n[【GigHub:】https://github.com/itxq/api-doc-php](https://github.com/itxq/api-doc-php)\n\n[【码云:】https://gitee.com/itxq/api-doc-php](https://github.com/itxq/api-doc-php)\n    \n### 扩展安装：\n\n+ 方法一：composer命令 `composer require itxq/api-doc-php`\n\n+ 方法二：直接下载压缩包，然后进入项目中执行 composer命令 `composer update` 来生成自动加载文件\n\n### 引用扩展：\n\n+ 当你的项目不支持composer自动加载时，可以使用以下方式来引用该扩展包\n\n```\n// 引入扩展（具体路径请根据你的目录结构自行修改）\nrequire_once __DIR__ . '/vendor/autoload.php';\n```\n\n### 使用扩展：\n\n```\n// 引入扩展（具体路径请根据你的目录结构自行修改）\nrequire_once __DIR__ . '/../vendor/autoload.php';\n// 加载测试API类1\nrequire_once __DIR__ . '/Api.php';\n// 加载测试API类2\nrequire_once __DIR__ . '/Api2.php'; \n$config = [\n    'class'         =\u003e ['Api', 'Api2'], // 要生成文档的类\n    'filter_method' =\u003e ['__construct'], // 要过滤的方法名称\n];\n$api = new \\itxq\\apidoc\\BootstrapApiDoc($config);\n$doc = $api-\u003egetHtml();\nexit($doc);\n```\n### 具体效果可运行test目录下的`index.php`查看","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitxq%2Fapi-doc-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fitxq%2Fapi-doc-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fitxq%2Fapi-doc-php/lists"}