{"id":14066568,"url":"https://github.com/datopian/giftlessclient","last_synced_at":"2025-07-21T13:33:38.731Z","repository":{"id":54881063,"uuid":"317231923","full_name":"datopian/giftlessclient","owner":"datopian","description":"A Git LFS client library implemented in R","archived":false,"fork":false,"pushed_at":"2021-01-22T14:35:13.000Z","size":27,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":11,"default_branch":"main","last_synced_at":"2025-07-02T11:13:24.565Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/datopian.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":"2020-11-30T13:26:40.000Z","updated_at":"2023-03-27T17:28:32.000Z","dependencies_parsed_at":"2022-08-14T05:31:23.395Z","dependency_job_id":null,"html_url":"https://github.com/datopian/giftlessclient","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/datopian/giftlessclient","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datopian%2Fgiftlessclient","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datopian%2Fgiftlessclient/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datopian%2Fgiftlessclient/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datopian%2Fgiftlessclient/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/datopian","download_url":"https://codeload.github.com/datopian/giftlessclient/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datopian%2Fgiftlessclient/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266312030,"owners_count":23909744,"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-07-21T11:47:31.412Z","response_time":64,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"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":[],"created_at":"2024-08-13T07:05:09.991Z","updated_at":"2025-07-21T13:33:38.692Z","avatar_url":"https://github.com/datopian.png","language":"R","readme":"\n# giftlessclient\n\n\u003c!-- badges: start --\u003e\n\u003c!-- badges: end --\u003e\n\nA Git LFS client library implemented in R, compatible with the [Giftless Git LFS server](https://github.com/datopian/giftless).\n\n## Installation\n\nYou can install `giftlessclient` from GitHub with:\n\n``` r\ndevtools::install_github(\"datopian/giftlessclient\")\n```\n\n## Example\n\nTo use `giftlessclient` you need to set up your lfs server URL in a environment variable:\n\n``` r\nSys.setenv(\"LFS_SERVER_URL\" = 'https://www.my-lfs-server.com')\n```\n\n\n#### Upload using multipart-basic transfer adapter\n\n```r\nfile_path \u003c- \"~/Documents/large-file.bin\"\nrepository \u003c- \"repository\"\ndataset \u003c- \"large-dataset\"\nauthz_token \u003c- \"eyJ0eXAiOiJK.eyJleHAiOjE2.WOalwa58Wr7_q3zm\"\n\nresp \u003c- lfs_upload(file_path, repository, dataset, authz_token, transfer=c('multipart-basic'))\n```\n\n* `file_path`: a readable, seekable file-like object\n* `repository`, `dataset`: used to generate the prefix for the batch request in form `repository/dataset`\n* `authz_token`: Bearer token required by the server\n\n\nReturns two files attributes: `sha256` of the file and it's `size`\n```\n\u003e resp\n$sha256\n[1] \"06c2e256b425f0222db6f14386aa827135043a0645f98e734d3c5cb2999e883f\"\n\n$size\n[1] \"51\"\n\n\u003e\n```\n\n\n#### Upload using basic transfer adapter\n\n```r\nfile_path \u003c- \"~/Documents/my-small-csv.csv\"\nrepository \u003c- \"repository\"\ndataset \u003c- \"small-dataset\"\nauthz_token \u003c- \"eyJ0eXAiOiJK.eyJleHAiOjE2.WOalwa58Wr7_q3zm\"\n\nlfs_upload(file_path, repository, dataset, authz_token, transfer=c('basic'))\n\n```\n\nThe `transfers` parameter is optional, and represents a list of supported transfer adapters by priority to negotiate with the server; Typically, there is no reason to provide this parameter.\n\n\n#### Sending a batch request to the server\n\nSend a [batch request](https://github.com/git-lfs/git-lfs/blob/master/docs/api/batch.md) to the LFS server:\n\n```r\nlfs_prefix \u003c- 'organization/giftlessclient'\nobjects \u003c- list(list(oid = '1231231', size = 12313))\nauthz_token \u003c- \"eyJ0eXAiOiJK.eyJleHAiOjE2.WOalwa58Wr7_q3zm\"\n\nbatch(lfs_prefix, objects, authz_token, transfer = c('multipart-basic'))\n\n```\n\n* `lfs_prefix`: add to LFS server url e.g. if `lfs_prefix \u003c- \"abc\"` and client was created with server url of `https://www.my-lfs-server.com` then batch request is made by POST to `https://www.my-lfs-server.com/abc/objects/batch`\n* `objects`: a list of objects to upload. \n  * `oid`: String OID (`sha256`) of the LFS object.\n  * `size`: Byte size of the LFS object. Must be at least zero.\n\n\n## License\n\ngiftlessclient is free software distributed under the terms of the MIT license. See [LICENSE](LICENSE.md) for details.\n\ngiftlessclient is (c) 2020 Datopian / Viderum Inc.\n","funding_links":[],"categories":["R"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatopian%2Fgiftlessclient","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdatopian%2Fgiftlessclient","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatopian%2Fgiftlessclient/lists"}