{"id":17933164,"url":"https://github.com/thisliu/easy-waimai","last_synced_at":"2026-07-03T19:33:23.817Z","repository":{"id":113143197,"uuid":"437789708","full_name":"thisliu/easy-waimai","owner":"thisliu","description":"外卖平台 SDK","archived":false,"fork":false,"pushed_at":"2021-12-15T16:06:21.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-09T00:34:22.993Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thisliu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2021-12-13T08:18:26.000Z","updated_at":"2021-12-15T16:06:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"1fdaa703-b7d5-4f26-9462-0223c1974d31","html_url":"https://github.com/thisliu/easy-waimai","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thisliu%2Feasy-waimai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thisliu%2Feasy-waimai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thisliu%2Feasy-waimai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thisliu%2Feasy-waimai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thisliu","download_url":"https://codeload.github.com/thisliu/easy-waimai/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246989753,"owners_count":20865331,"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","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":[],"created_at":"2024-10-28T21:37:54.927Z","updated_at":"2025-10-29T14:04:50.354Z","avatar_url":"https://github.com/thisliu.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e finecho/waimai \u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e 外卖平台 SDK\u003c/p\u003e\n\n\n## 安装\n\n```shell\n$ composer require finecho/waimai -vvv\n```\n\n## 介绍\n\n现阶段将会支持两家外卖平台\n\n* [饿了吗](https://open.shop.ele.me/openapi/documents/workflow)\n* [美团](https://developer.waimai.meituan.com/home/guide/6)\n\n## 配置\n```php\n$config = [\n    'default_platform' =\u003e 'meituan',\n    'platforms' =\u003e [\n        'meituan' =\u003e [\n            'app_id' =\u003e 10020201024, \n            'secret_id' =\u003e 'AKIDsiQzQla780mQxLLU2GJCxxxxxxxxxxx', \n        ],\n        'eleme' =\u003e [\n            'app_id' =\u003e 20020201024, \n            'secret_id' =\u003e 'CKIDsiQzQla780mQxLLU2GJCxxxxxxxxxxx', \n        ],\n    ],\n];\n```\n\n## 使用\n\n您可以使用两种调用方式：原始方式调用 和 链式调用，请根据你的喜好自行选择使用方式，效果一致。\n\n### 方式一 - 原始方式调用\n```php\nuse EasyWaimai\\Application;\n\n$app = new Application($config);\n\n$api = $app-\u003egetClient();\n\n$response = $api-\u003epost(\n    '/poi/save',\n    [\n        'name'    =\u003e 'finecho 的快餐店',\n        'address' =\u003e '深圳市南山区',\n    ]\n);\n```\n\n### 方式二 - 链式调用\n```php\nuse EasyWaimai\\Application;\n\n$app = new Application($config);\n\n$api = $app-\u003egetClient();\n\n$response = $api-\u003epoi-\u003esave-\u003epost(\n    [\n        'name'    =\u003e 'finecho 的快餐店',\n        'address' =\u003e '深圳市南山区',\n    ]\n);\n```\n\n当一个项目中同时使用到了多个平台，可以使用 `setPlatform` 进行灵活切换\n```php\n...\n$app-\u003esetPlatform(\\EasyMeiTuan\\Platforms\\Eleme::PLATFORM_NAME);\n....\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthisliu%2Feasy-waimai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthisliu%2Feasy-waimai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthisliu%2Feasy-waimai/lists"}