{"id":15029544,"url":"https://github.com/dduan/just","last_synced_at":"2025-12-11T23:01:39.023Z","repository":{"id":30757367,"uuid":"34313971","full_name":"dduan/Just","owner":"dduan","description":"Swift HTTP for Humans","archived":false,"fork":false,"pushed_at":"2024-03-26T16:03:27.000Z","size":2513,"stargazers_count":1404,"open_issues_count":30,"forks_count":134,"subscribers_count":38,"default_branch":"master","last_synced_at":"2024-10-29T17:55:00.485Z","etag":null,"topics":["http","requests","swift"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dduan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":"Supporting Files/Info-Tests.plist","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-04-21T08:21:10.000Z","updated_at":"2024-10-25T16:14:45.000Z","dependencies_parsed_at":"2024-05-05T02:36:39.084Z","dependency_job_id":"8c8d1053-b025-4400-827e-fae010f3c2c0","html_url":"https://github.com/dduan/Just","commit_stats":{"total_commits":314,"total_committers":21,"mean_commits":"14.952380952380953","dds":"0.23248407643312097","last_synced_commit":"be341d3df1102954339ce04b7f99f6a952535b9f"},"previous_names":["justhttp/just"],"tags_count":32,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dduan%2FJust","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dduan%2FJust/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dduan%2FJust/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dduan%2FJust/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dduan","download_url":"https://codeload.github.com/dduan/Just/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247721898,"owners_count":20985084,"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":["http","requests","swift"],"created_at":"2024-09-24T20:10:58.208Z","updated_at":"2025-12-11T23:01:38.592Z","avatar_url":"https://github.com/dduan.png","language":"Swift","readme":"![Supported Flatform](https://img.shields.io/cocoapods/p/Just.svg)\n[![CocoaPods](https://img.shields.io/cocoapods/v/Just.svg)](https://cocoapods.org/pods/Just)\n[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)\n[![Build Status](https://travis-ci.org/dduan/Just.svg?branch=master)](https://travis-ci.org/dduan/Just)\n\n\u003cimg src=\"https://raw.githubusercontent.com/dduan/Just/master/Docs/IconMasked.png\" width=\"280\" height=\"280\"\u003e\n\nJust is a client-side HTTP library inspired by [python-requests][] - HTTP for Humans.\n\n[python-requests]: http://python-requests.org \"python-requests\"\n\n# Features\n\nJust lets you to the following effortlessly:\n\n- URL queries\n- custom headers\n- form (`x-www-form-encoded`) / JSON HTTP body\n- redirect control\n- multipart file upload along with form values.\n- basic/digest authentication\n- cookies\n- timeouts\n- synchronous / asynchronous requests\n- upload / download progress tracking for asynchronous requests\n- link headers\n- friendly accessible results\n\n# Use\n\nThe simplest request with Just looks like this:\n\n```swift\n//  A simple get request\nJust.get(\"http://httpbin.org/get\")\n```\n\nThe next example shows how to upload a file along with some data:\n\n```swift\n//  talk to registration end point\nlet r = Just.post(\n    \"http://justiceleauge.org/member/register\",\n    data: [\"username\": \"barryallen\", \"password\":\"ReverseF1ashSucks\"],\n    files: [\"profile_photo\": .url(fileURLWithPath:\"flash.jpeg\", nil)]\n)\n\nif r.ok { /* success! */ }\n```\n\nHere's the same example done asynchronously:\n\n```swift\n//  talk to registration end point\nJust.post(\n    \"http://justiceleauge.org/member/register\",\n    data: [\"username\": \"barryallen\", \"password\":\"ReverseF1ashSucks\"],\n    files: [\"profile_photo\": .url(fileURLWithPath:\"flash.jpeg\", nil)]\n) { r in\n    if r.ok { /* success! */ }\n}\n\n```\n\nRead *Getting Started* [on the web][starting link] or\n[in this playground][starting playground] to learn more!\n\n[starting playground]: https://github.com/dduan/Just/blob/master/Docs/QuickStart.zip?raw=true\n[starting link]: https://JustHTTP.github.io\n\n#  Install\n\nHere are some ways to leverage Just.\n\n## Xcode\n\nAdd `https://github.com/dduan/Just.git` the usual way.\n\n## Swift Package Manager\n\nAdd the following to your `dependencies`:\n\n```swift\n.package(url: \"https://github.com/dduan/Just.git\",  from: \"0.8.0\")\n```\n\n… and `\"Just\"` to your target dependencies.\n\n## Carthage\n\nInclude the following in your Cartfile:\n\n    github \"dduan/Just\"\n\nJust includes dynamic framework targets for both iOS and OS X.\n\n## CocoaPods\n\nThe usual way:\n\n    platform :ios, '8.0'\n    use_frameworks!\n\n    target 'MyApp' do\n      pod 'Just'\n    end\n\n## Manual\n\nDrop `Just.xcodeproj` into your project navigator. Under the *General* tab of\nyour project settings, use the plus sign to add `Just.framework` to\n*Linked Framework and Libraries*. Make sure to include the correct version\nfor your target's platform.\n\nIt's also common to add Just as a git submodule to your projects repository:\n\n    cd path/to/your/project\n    git submodule add https://github.com/dduan/Just.git\n\n\n## Source File\n\nPut `Just.swift` directly into your project. Alternately, put it in the\n*Sources* folder of a playground. (The latter makes a fun way to explore the\nweb.)\n\n\n[Carthage]: https://github.com/Carthage/Carthage \"Carthage\"\n\n\n# Contribute\n\nPull requests are welcome. Here are some tips for code contributors:\n\nWork in `Just.xcworkspace`.\n\nThe tests for link headers relies on Github APIs, which has a low per-hour\nlimit. To overcome this, you can edit the Xcode build schemes and add\n[environment variables][XcodeEnvVar]  `GITHUB_TOKEN`. Learn more about\npersonal tokens [here][GithubToken].\n\nFor Xcode rebels, checkout `Makefile`.\n\nHTML documentation pages are generated by literate programmin tool [docco][]\n\n[docco]: http://jashkenas.github.io/docco/ \"docco\"\n[GithubToken]: https://developer.github.com/v3/#increasing-the-unauthenticated-rate-limit-for-oauth-applications \n[XcodeEnvVar]: http://nshipster.com/launch-arguments-and-environment-variables/\n\n# License\n\nMIT, see [LICENSE.md](https://github.com/dduan/Just/blob/master/LICENSE.md).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdduan%2Fjust","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdduan%2Fjust","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdduan%2Fjust/lists"}