{"id":17922724,"url":"https://github.com/overtrue/flysystem-cos","last_synced_at":"2025-04-06T05:16:41.046Z","repository":{"id":33287724,"uuid":"157651976","full_name":"overtrue/flysystem-cos","owner":"overtrue","description":":floppy_disk: Flysystem adapter for the Qcloud COS storage.","archived":false,"fork":false,"pushed_at":"2024-04-30T07:26:08.000Z","size":75,"stargazers_count":72,"open_issues_count":4,"forks_count":10,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-05-17T05:43:48.289Z","etag":null,"topics":["flysystem","flysystem-adapter","qcloud","qcloud-cos"],"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/overtrue.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":["overtrue"]}},"created_at":"2018-11-15T04:27:13.000Z","updated_at":"2024-06-18T12:39:02.140Z","dependencies_parsed_at":"2024-02-01T16:31:13.849Z","dependency_job_id":"4a5e8afc-aae9-40c9-80a6-cbcba9db5f80","html_url":"https://github.com/overtrue/flysystem-cos","commit_stats":{"total_commits":65,"total_committers":11,"mean_commits":5.909090909090909,"dds":"0.23076923076923073","last_synced_commit":"9a8f2eba21d7c869b7f53798a5329f55e0a7e42f"},"previous_names":[],"tags_count":25,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overtrue%2Fflysystem-cos","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overtrue%2Fflysystem-cos/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overtrue%2Fflysystem-cos/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/overtrue%2Fflysystem-cos/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/overtrue","download_url":"https://codeload.github.com/overtrue/flysystem-cos/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247436286,"owners_count":20938533,"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":["flysystem","flysystem-adapter","qcloud","qcloud-cos"],"created_at":"2024-10-28T20:40:36.453Z","updated_at":"2025-04-06T05:16:40.906Z","avatar_url":"https://github.com/overtrue.png","language":"PHP","funding_links":["https://github.com/sponsors/overtrue"],"categories":[],"sub_categories":[],"readme":"# Flysystem QCloud COS\n\n---\n\n:floppy_disk: Flysystem adapter for the Qcloud COS storage.\n\n[![Test](https://github.com/overtrue/flysystem-cos/actions/workflows/test.yml/badge.svg)](https://github.com/overtrue/flysystem-cos/actions/workflows/test.yml) [![Latest Stable Version](https://poser.pugx.org/overtrue/flysystem-cos/v/stable.svg)](https://packagist.org/packages/overtrue/flysystem-cos) [![Latest Unstable Version](https://poser.pugx.org/overtrue/flysystem-cos/v/unstable.svg)](https://packagist.org/packages/overtrue/flysystem-cos) [![Total Downloads](https://poser.pugx.org/overtrue/flysystem-cos/downloads)](https://packagist.org/packages/overtrue/flysystem-cos) [![License](https://poser.pugx.org/overtrue/flysystem-cos/license)](https://packagist.org/packages/overtrue/flysystem-cos)\n\n[![Sponsor me](https://github.com/overtrue/overtrue/blob/master/sponsor-me-button-s.svg?raw=true)](https://github.com/sponsors/overtrue)\n\n## Requirement\n\n* PHP \u003e= 8.0.2\n\n## Installation\n\n```shell\ncomposer require overtrue/flysystem-cos -vvv\n```\n\n## Usage\n\n```php\nuse League\\Flysystem\\Filesystem;\nuse Overtrue\\Flysystem\\Cos\\CosAdapter;\n\n$config = [\n    // 必填，app_id、secret_id、secret_key \n    // 可在个人秘钥管理页查看：https://console.cloud.tencent.com/capi\n    'app_id' =\u003e 10020201024, \n    'secret_id' =\u003e 'AKIDsiQzQla780mQxLLU2GJCxxxxxxxxxxx', \n    'secret_key' =\u003e 'b0GMH2c2NXWKxPhy77xhHgwxxxxxxxxxxx',\n\n    'region' =\u003e 'ap-guangzhou', \n    'bucket' =\u003e 'example',\n    \n    // 可选，如果 bucket 为私有访问请打开此项\n    'signed_url' =\u003e false,\n    \n    // 可选，是否使用 https，默认 false\n    'use_https' =\u003e true, \n    \n    // 可选，自定义域名\n    'domain' =\u003e 'emample-12340000.cos.test.com', \n    \n    // 可选，使用 CDN 域名时指定生成的 URL host\n    'cdn' =\u003e 'https://youcdn.domain.com/',\n];\n\n$adapter = new CosAdapter($config);\n\n$flysystem = new League\\Flysystem\\Filesystem($adapter);\n\n```\n## API\n\n```php\n\nbool $flysystem-\u003ewrite('file.md', 'contents');\n\nbool $flysystem-\u003ewrite('file.md', 'http://httpbin.org/robots.txt', ['mime' =\u003e 'application/redirect302']);\n\nbool $flysystem-\u003ewriteStream('file.md', fopen('path/to/your/local/file.jpg', 'r'));\n\nbool $flysystem-\u003emove('foo.md', 'bar.md');\n\nbool $flysystem-\u003ecopy('foo.md', 'foo2.md');\n\nbool $flysystem-\u003edelete('file.md');\n\nbool $flysystem-\u003efileExists('file.md');\n\nstring|mixed|false $flysystem-\u003eread('file.md');\n\narray $flysystem-\u003elistContents();\n\nint $flysystem-\u003efileSize('file.md');\n\nstring $flysystem-\u003emimeType('file.md');\n\nint $flysystem-\u003elastModified('file.md');\n\n```\n\n## :heart: Sponsor me \n\n[![Sponsor me](https://github.com/overtrue/overtrue/blob/master/sponsor-me.svg?raw=true)](https://github.com/sponsors/overtrue)\n\n如果你喜欢我的项目并想支持它，[点击这里 :heart:](https://github.com/sponsors/overtrue)\n\n## Project supported by JetBrains\n\nMany thanks to Jetbrains for kindly providing a license for me to work on this and other open-source projects.\n\n[![](https://resources.jetbrains.com/storage/products/company/brand/logos/jb_beam.svg)](https://www.jetbrains.com/?from=https://github.com/overtrue)\n\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fovertrue%2Fflysystem-cos","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fovertrue%2Fflysystem-cos","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fovertrue%2Fflysystem-cos/lists"}