Add API call to download one file
@varmar05 已经在做这个了。
开始于 2026年8月10日。
评估
这个 Issue 还没有评估数据。
描述
Currently, there's no simple way to fetch just one file from a project. There is download_file() API call, but it needs the project to be already downloaded (it is useful just to get older versions of a file).
One could either query MM server API directly, e.g.:
https://app.merginmaps.com/v1/project/raw/<workspace>/<project>?file=myfile.gpkg
(with appropriate auth token)
Alternatively, using python with a workaround like this (handles auth stuff):
from mergin import MerginClient
from mergin.utils import save_to_file
mergin_client = MerginClient(...)
res = mergin_client.get('/v1/project/raw/<workspace>/<project>', data={'file': 'myfile.gpkg'})
save_to_file(res, 'myfile.gpkg')
If we add support for this, maybe we could just update the existing download_file() implementation so that it will accept as the first argument either <workspace>/<project> or it would accept an existing the local directory with a project downloaded already.
No project checkout, download raw file
- 主要语言
- Python
- 星标
- 23
- 派生
- 12
- 平均合并
- 2 天 13 小时
- 30 天内合并 PR
- 7
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
MerginMaps/python-api-client 的其他 Issue
-
Vacuuming 未关闭
难度 2/5 1-3 小时 新手友好度 68/100
MerginMaps/python-api-client#320 ·
-
难度 5/5 一周以上 新手友好度 30/100
MerginMaps/python-api-client#270 ·
-
enhancement
难度 5/5 一周以上 新手友好度 25/100
MerginMaps/python-api-client#257 · 3 条评论 ·
-
enhancement
难度 4/5 3-5 天 新手友好度 25/100
MerginMaps/python-api-client#254 · 1 条评论 ·
-
enhancement
难度 5/5 一周以上 新手友好度 25/100
MerginMaps/python-api-client#245 ·
查看 MerginMaps/python-api-client 的全部 Issue
相似的 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 90/100
learningequality/ricecooker#747 ·
-
难度 2/5 1-3 小时 新手友好度 68/100
BSData/horus-heresy-3rd-edition#3171 ·
-
enhancement
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 2/5 1-3 小时 新手友好度 76/100
run-llama/llama_index#23199 ·
-
难度 2/5 1-3 小时 新手友好度 84/100
KhronosGroup/glTF-Blender-IO#2769 ·