Latest 1.2.0
License MIT
Platforms ios 8.0
Dependencies CodyFire, RxSwift, RxCocoa



via CocoaPods

pod 'RxCodyFire'

How to use

Please see API declaration examples in the original CodyFire repo

Let’s imagine that you have ToDos app. Our goal is to get a list of ToDos.

Ok, let’s declare a ToDo model in Models/ToDoModel.swift

struct ToDoModel: Codable {
    let id: UUID
    let text: String
    let createdAt: Date

Then declare your API class in /API/API.swift file

class API {
    typealias todo = ToDoController

Then declare your empty ToDo controller in API/Controllers/ToDoController.swift file

class ToDoController {}

And in a separated decorator API/Controllers/ToDo+Search.swift file declare a search endpoint

import RxCodyFire

extension ToDoController {
    struct Query: Codable {
        let text: String
    static func search(_ text: String) -> APIRequest<[ToDo]> {
        return APIRequest("todo").query(Query(text: text))

When everything is ready you’re able to easily use it in your reactive code!
Please don’t forget to import RxCodyFire

  .map { ($0 ?? "").lowercased() }
  .flatMap {$0).observable }
  .bind(to: tableView.rx.items(cellIdentifier: cellIdentifier)) { index, model, cell in
    cell.textLabel?.text =
  .disposed(by: disposeBag)

Nice, right?

TIP: There is no need to also import CodyFire cause it's already imported by RxCodyFire


Mihael Isaev, [email protected]


RxCodyFire is available under the MIT license. See the LICENSE file for more info.

Latest podspec

    "name": "RxCodyFire",
    "version": "1.2.0",
    "summary": "CodyFire wrapper for RxSwift ud83dudd25",
    "description": "Install this pod to use CodyFire with RxSwift ud83dudd25",
    "homepage": "",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    "authors": {
        "MihaelIsaev": "[email protected]"
    "source": {
        "git": "",
        "tag": "1.2.0"
    "platforms": {
        "ios": "8.0"
    "source_files": "RxCodyFire/Classes/**/*",
    "dependencies": {
        "CodyFire": [],
        "RxSwift": [],
        "RxCocoa": []
    "swift_version": "4.2"

Pin It on Pinterest

Share This