{"id":19778908,"url":"https://github.com/dialogflow/api-ai-cocoa-swift","last_synced_at":"2025-04-30T21:31:23.613Z","repository":{"id":56900513,"uuid":"46132972","full_name":"dialogflow/api-ai-cocoa-swift","owner":"dialogflow","description":"Cocoa Swift library","archived":false,"fork":false,"pushed_at":"2019-02-25T18:26:20.000Z","size":99,"stargazers_count":28,"open_issues_count":8,"forks_count":8,"subscribers_count":12,"default_branch":"master","last_synced_at":"2024-03-17T15:54:45.485Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/dialogflow.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":"2015-11-13T16:19:20.000Z","updated_at":"2022-08-27T13:21:43.000Z","dependencies_parsed_at":"2022-08-20T18:20:36.703Z","dependency_job_id":null,"html_url":"https://github.com/dialogflow/api-ai-cocoa-swift","commit_stats":null,"previous_names":["api-ai/api-ai-cocoa-swift"],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dialogflow%2Fapi-ai-cocoa-swift","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dialogflow%2Fapi-ai-cocoa-swift/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dialogflow%2Fapi-ai-cocoa-swift/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dialogflow%2Fapi-ai-cocoa-swift/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dialogflow","download_url":"https://codeload.github.com/dialogflow/api-ai-cocoa-swift/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224224820,"owners_count":17276428,"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":[],"created_at":"2024-11-12T05:32:37.622Z","updated_at":"2024-11-12T05:32:53.457Z","avatar_url":"https://github.com/dialogflow.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DEPRECATED Cocoa SDK for api.ai\n\n## This library is deprecated. Please use [API.AI's Apple Client library](https://github.com/api-ai/apiai-apple-client)\n\n[![Build Status](https://travis-ci.org/api-ai/api-ai-ios-sdk.svg?branch=master)](https://travis-ci.org/api-ai/api-ai-cocoa-swift)\n[![Version](https://img.shields.io/cocoapods/v/AI.svg?style=flat)](http://cocoapods.org/pods/AI)\n[![License](https://img.shields.io/cocoapods/l/AI.svg?style=flat)](http://cocoapods.org/pods/AI)\n[![Platform](https://img.shields.io/cocoapods/p/AI.svg?style=flat)](http://cocoapods.org/pods/AI)\n[![Carthage Compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)\n\n* [Overview](#overview)\n* [Prerequisites](#prerequisites)\n* [Running the Demo app](#runningthedemoapp)\n* [Integrating api.ai into your Cocoa app](#integratingintoyourapp)\n\n---------------\n\n## \u003ca name=\"overview\"\u003e\u003c/a\u003eOverview\nThe API.AI iOS SDK makes it easy to integrate natural language processing API on Apple devices. API.AI allows using voice commands and integration with dialog scenarios defined for a particular agent in API.AI.\n\n## \u003ca name=\"prerequisites\"\u003e\u003c/a\u003ePrerequsites\n* Create an [API.AI account](http://api.ai)\n* Install [CocoaPods](#cocoapods) or [Carthage](#carthage)\n\n\n## \u003ca name=\"runningthedemoapp\"\u003e\u003c/a\u003eRunning the Demo app (CocoaPods supports only)\n* Run ```pod update``` in the AIDemo project folder.\n* Open **AIDemo.xworkspace** in Xcode.\n* In **AppDelegate** insert API key.\n  ```\n  AI.configure(\"YOUR_CLIENT_ACCESS_TOKEN\")\n  ```\n\n  Note: an agent in **api.ai** should exist. Keys could be obtained on the agent's settings page.\n\n* Define sample intents in the agent.\n* Run the app in Xcode.\n  Inputs are possible with text and voice (experimental).\n\n\n## \u003ca name=\"integratingintoyourapp\"\u003e\u003c/a\u003eIntegrating into your app\n\n### CocoaPods\n\n[CocoaPods](http://cocoapods.org) is a dependency manager for Swift and Objective-C Cocoa projects. Installing:\n\n```bash\n$ [sudo] gem install cocoapods\n```\n\nList \"AI\" in a text file named `Podfile` in your Xcode project directory:\n\n```ruby\nsource 'https://github.com/CocoaPods/Specs.git'\nplatform :ios, '10.0'\nuse_frameworks!\n\ntarget '\u003cYour Target Name\u003e' do\n    pod 'AI', '~\u003e 0.7'\nend\n```\n\nNow you can install the dependencies in your project:\n\n```bash\n$ pod install\n```\n\n### Carthage\n\n[Carthage](https://github.com/Carthage/Carthage) is intended to be the simplest way to add frameworks to your Cocoa application.\n\nYou can use [Homebrew](http://brew.sh) and install the `carthage` tool on your system simply by running `brew update` and `brew install carthage`.\n\nCreate a `Cartfile` with following text:\n```\ngithub \"api-ai/AI\"\n```\n\nRun `carthage update`.\nDrag the built `AI.framework` into your Xcode project.\n\n### Init the SDK.\n\nIn the ```AppDelegate.swift```, add AI import:\n```Swift\nimport AI\n```\n\nIn the AppDelegate.swift, add\n\n```Swift\n// Define API.AI configuration here.\nAI.configure(\"YOUR_CLIENT_ACCESS_TOKEN\")\n```\n\n### Perform request.\n\n```Swift\n...\n// Request using text (assumes that speech recognition / ASR\n// is done using a third-party library, e.g. AT\u0026T)\nAI.sharedService.TextRequest(\"Hello\").success { (response) -\u003e Void in\n    // Handle success ...\n}.failure { (error) -\u003e Void in\n    // Handle error ...\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdialogflow%2Fapi-ai-cocoa-swift","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdialogflow%2Fapi-ai-cocoa-swift","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdialogflow%2Fapi-ai-cocoa-swift/lists"}