{"id":22835266,"url":"https://github.com/gueff/mymvc_module_openapi","last_synced_at":"2026-04-24T16:39:26.612Z","repository":{"id":160319398,"uuid":"554845059","full_name":"gueff/myMVC_module_OpenApi","owner":"gueff","description":"OpenAPI module for myMVC","archived":false,"fork":false,"pushed_at":"2024-01-15T15:18:06.000Z","size":64,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"1.x","last_synced_at":"2025-03-31T02:44:09.303Z","etag":null,"topics":["mymvc","mymvc-module","openapi","php","php-framework"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gueff.png","metadata":{"files":{"readme":"README.md","changelog":"Changelog.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-20T13:50:22.000Z","updated_at":"2023-11-17T11:20:08.000Z","dependencies_parsed_at":null,"dependency_job_id":"f0f3c5da-0f7c-49db-8a44-a3503297e766","html_url":"https://github.com/gueff/myMVC_module_OpenApi","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/gueff/myMVC_module_OpenApi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gueff%2FmyMVC_module_OpenApi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gueff%2FmyMVC_module_OpenApi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gueff%2FmyMVC_module_OpenApi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gueff%2FmyMVC_module_OpenApi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gueff","download_url":"https://codeload.github.com/gueff/myMVC_module_OpenApi/tar.gz/refs/heads/1.x","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gueff%2FmyMVC_module_OpenApi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32231481,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-24T13:21:15.438Z","status":"ssl_error","status_checked_at":"2026-04-24T13:21:15.005Z","response_time":64,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["mymvc","mymvc-module","openapi","php","php-framework"],"created_at":"2024-12-12T22:08:51.429Z","updated_at":"2026-04-24T16:39:26.579Z","avatar_url":"https://github.com/gueff.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# myMVC_module_OpenApi\n\n## Requirements\n\n- Linux\n- php \u003e= 8\n  - `pdo` extension\n- myMVC 3.x\n  - `git clone --branch 3.x https://github.com/gueff/myMVC.git myMVC_3.x`\n  - Docs: \u003chttps://mymvc.ueffing.net/\u003e\n  - github: \u003chttps://github.com/gueff/myMVC/tree/3.x\u003e\n\n---\n\n## Installation\n\n_git clone_\n~~~bash\ncd /modules/;\n\ngit clone --branch 1.x \\\nhttps://github.com/gueff/myMVC_module_OpenApi.git \\\nOpenApi;\n~~~\n\n---\n\n## Usage\n\n_validate against openapi **file**_\n~~~php\nuse OpenApi\\Model\\Validate;\n\n$oDTValidateRequestResponse = Validate::request(\n    $oDTRequestCurrent,\n    Config::get_MVC_PUBLIC_PATH() . '/openapi/api.yaml'\n);\n\nheader('Content-Type: application/json');\necho json_encode(Convert::objectToArray($oDTValidateRequestResponse));\n~~~\n\n_validate against openapi **URL**_\n~~~php\nuse OpenApi\\Model\\Validate;\n\n// validate against openapi URL\n$oDTValidateRequestResponse = Validate::request(\n    $oDTRequestCurrent,\n    'https://example.com/api/openapi.yaml'\n);\n\nheader('Content-Type: application/json');\necho json_encode(Convert::objectToArray($oDTValidateRequestResponse));\n~~~\n\n**auto-creating myMVC Routes from openapi file**\n\n_All Routes lead to their given `operationId`, set in openapi_    \n~~~php\n\\OpenApi\\Model\\Route::autoCreateFromOpenApiFile(\n    Config::get_MVC_PUBLIC_PATH() . '/openapi/api.yaml',\n    '\\Foo\\Controller\\Api'\n);\n~~~\n\n_All Routes lead explicitely to `Api::delegate()`_      \n~~~php\n\\OpenApi\\Model\\Route::autoCreateFromOpenApiFile(\n    Config::get_MVC_PUBLIC_PATH() . '/openapi/api.yaml',\n    '\\Foo\\Controller\\Api',\n    'delegate'\n);\n~~~\n\n---\n\n## Get Logs\n\nLogs are fired to Events.\n\nAvailable events are:\n\n- `myMVC_module_OpenApi::sYamlSource`\n\n_listen to event and write its content to a logfile_    \n~~~php\n\\MVC\\Event::bind('myMVC_module_OpenApi::sYamlSource', function($sContent){\n    \\MVC\\Log::write($sContent, 'openapi.log');\n});\n~~~","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgueff%2Fmymvc_module_openapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgueff%2Fmymvc_module_openapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgueff%2Fmymvc_module_openapi/lists"}