Skip to content

igormatos/api.swift

Repository files navigation

Build Status

Connect to your API

pod 'Launchpad'
import Launchpad

Read and Write Data

Launchpad
	.url("http://liferay.io/<YOUR-APP>/<YOUR-SERVICE>/items")
	.post([
		"title": "Star Wars IV",
		"year": 1977
	])
	.then { response in
		print("Data saved")
	}
.done()
Launchpad
	.url("http://liferay.io/<YOUR-APP>/<YOUR-SERVICE>/items")
	.get()
	.then { response in
		let movies = response.body as? [String: AnyObject]
		print(movies)
	}
.done()
Launchpad
	.url("http://liferay.io/app/service/movies")
	.filter("year", ">", 2000)
	.sort("rating")
	.limit(2)
	.offset(1)
	.get()
	.then { response in
		let movies = response.body as? [String: AnyObject]
		print(movies)
	}
.done()

About

Swift API Client for Launchpad Project

Resources

License

Stars

Watchers

Forks

Packages

No packages published