{"id":19925282,"url":"https://github.com/tomatoes-app/tomatoes-swift-sdk","last_synced_at":"2026-05-20T05:07:24.432Z","repository":{"id":136978095,"uuid":"80292303","full_name":"tomatoes-app/tomatoes-swift-sdk","owner":"tomatoes-app","description":"Swift SDK of Tomatoes - Pomodoro Technique® online time tracker","archived":false,"fork":false,"pushed_at":"2017-02-05T20:54:41.000Z","size":742,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-12T20:04:52.364Z","etag":null,"topics":["ios","iphone","macos","pomodoro","sdk","swift"],"latest_commit_sha":null,"homepage":"http://www.tomato.es","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tomatoes-app.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-01-28T15:34:53.000Z","updated_at":"2024-05-03T04:39:00.000Z","dependencies_parsed_at":"2023-03-22T12:16:58.040Z","dependency_job_id":null,"html_url":"https://github.com/tomatoes-app/tomatoes-swift-sdk","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/tomatoes-app/tomatoes-swift-sdk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomatoes-app%2Ftomatoes-swift-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomatoes-app%2Ftomatoes-swift-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomatoes-app%2Ftomatoes-swift-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomatoes-app%2Ftomatoes-swift-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tomatoes-app","download_url":"https://codeload.github.com/tomatoes-app/tomatoes-swift-sdk/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tomatoes-app%2Ftomatoes-swift-sdk/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266255243,"owners_count":23900097,"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":["ios","iphone","macos","pomodoro","sdk","swift"],"created_at":"2024-11-12T22:21:38.342Z","updated_at":"2026-05-20T05:07:24.401Z","avatar_url":"https://github.com/tomatoes-app.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Tomatoes Swift SDK\n[![Build Status](https://travis-ci.org/tomatoes-app/tomatoes-swift-sdk.svg?branch=master)](https://travis-ci.org/tomatoes-app/tomatoes-swift-sdk)\n\nThe Tomatoes Swift SDK allows developers to quickly integrate Tomatoes services into their Swift applications. \nSee [API reference](http://www.tomato.es/pages/api_reference) for more details.\n\n## Requirements\n\n- iOS 9.0+ / macOS 10.11+\n- Xcode 8.1+\n- Swift 3.0+\n\n## Installation\n### Carthage\n\nYou can install [Carthage](https://github.com/Carthage/Carthage) with [Homebrew](http://brew.sh/) using the following command:\n\n```bash\n$ brew update\n$ brew install carthage\n```\n\nTo integrate Tomatoes Swift SDK into your Xcode project using Carthage, specify it in your `Cartfile`:\n\n```ogdl\ngithub \"tomatoes-app/tomatoes-swift-sdk\" ~\u003e 0.2.1\n```\n\nRun `carthage update` to build the framework and drag the built `Tomatoes.framework` into your Xcode project.\n\n### Swift Package Manager\n\nAdd the following code to your `Package.swift` file and run `swift build`.\n\n```Swift\nimport PackageDescription\n\nlet package = Package(\n    name: \"tomatoes-swift-sdk\",\n    dependencies: [\n        .Package(url: \"https://github.com/tomatoes-app/tomatoes-swift-sdk.git\", Version(0,2,1))\n    ])\n```\n### App Transport Security\n\nApp Transport Security was introduced with iOS 9 to enforce secure Internet connections, but Tomatoes doesn't support HTTPS yet. Allow insecure connections to Tomatoes by adding the following exception to your application's `Info.plist` file.\n\n```xml\n\u003ckey\u003eNSAppTransportSecurity\u003c/key\u003e\n\t\u003cdict\u003e\n\t\t\u003ckey\u003eNSExceptionDomains\u003c/key\u003e\n\t\t\u003cdict\u003e\n\t\t\t\u003ckey\u003ewww.tomato.es\u003c/key\u003e\n\t\t\t\u003cdict\u003e\n\t\t\t\t\u003ckey\u003eNSExceptionAllowsInsecureHTTPLoads\u003c/key\u003e\n\t\t\t\t\u003ctrue/\u003e\n\t\t\t\t\u003ckey\u003eNSIncludesSubdomains\u003c/key\u003e\n\t\t\t\t\u003ctrue/\u003e\n\t\t\t\t\u003ckey\u003eNSTemporaryExceptionMinimumTLSVersion\u003c/key\u003e\n\t\t\t\t\u003cstring\u003eTLSv1.1\u003c/string\u003e\n\t\t\t\u003c/dict\u003e\n\t\t\u003c/dict\u003e\n\t\u003c/dict\u003e\n```\n\n## Usage\nReview the iOS [sample application](https://github.com/tomatoes-app/tomatoes-ios)\n\n### Create a Tomatoes session\n\nTo establish a new Tomatoes session you'll need to implement GitHub auth and retrieve a GitHub user access token, see [GitHub doc](https://developer.github.com/v3/oauth_authorizations/). Leave the default scope.\n\nThen you can use the GitHub access token to create a new Tomatoes session as follow:\n\n```Swift\n let session = Session(provider: .github, accessToken: \u003cgithub-access-token\u003e)\n session.create { (result) in\n    switch result {\n    case .success: print(\"You are authenticated\")\n    case .failure(let error): print(error?.localizedDescription ?? \"no error description\")\n   }\n }\n```\n__Note: Tomatoes new session requests will return an access token that the SDK will store in the keychain. The SDK will try to apply the token stored in the keychain to send requests to Tomatoes that need authentication.__\n\n### Request user info\n\n```Swift\nUser.read { (result) in\n    switch result {\n    case .success(let user): print(user.name)\n    case .failure(let error): print(error?.localizedDescription)\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomatoes-app%2Ftomatoes-swift-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftomatoes-app%2Ftomatoes-swift-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomatoes-app%2Ftomatoes-swift-sdk/lists"}