Need help with captain-fact-api?
Click the β€œchat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

141 Stars 24 Forks GNU Affero General Public License v3.0 940 Commits 18 Opened issues


πŸ”Ž CaptainFact - API. The one that serves and process all the data for

Services available


Need anything else?

Contributors list

Discord AGPL3 Coverage Status

Install & Run


You need to install Elixir. We recommand using asdf-vm. Check their documentation on how to install it, then run

asdf install
from root

Start DB

Create / launch a PostgreSQL instance on your local machine. If you have Docker installed, you can use the pre-Seed PostgreSQL Docker image:

docker run -d --name cf_dev_db -p 5432:5432 captainfact/dev-db:latest

Start API

  • mix deps.get
    --> Get dependencies
  • mix ecto.migrate
    --> Migrate DB
  • iex -S mix
    --> Start project

Following services will be started:

You can also see all e-mail sent, by going to http://localhost:4000/_dev/mail

Other useful commands

  • mix test
    --> Run tests
  • mix
    --> Run test watcher
  • mix format
    --> Format code
  • mix ecto.gen.migration [migration_name]
    --> Generate migration

Project architecture

This application is organized as an umbrella project which allows us to divide CaptainFact API into small apps.

β”œβ”€β”€ apps
β”‚   β”œβ”€β”€ cf => Core functions as a library. **Not deployed**
β”‚   β”œβ”€β”€ cf_atom_feed => Atom feed.
β”‚   β”œβ”€β”€ cf_graphql => GraphQL API (public).
β”‚   β”œβ”€β”€ cf_jobs => Jobs.
β”‚   β”œβ”€β”€ cf_rest_api => REST/WS API (private).
β”‚   └── db => DB repository and schemas **Not deployed**
β”‚       β”œβ”€β”€ lib
β”‚       β”‚   β”œβ”€β”€ db
β”‚       β”‚   β”œβ”€β”€ db_schema => Contains all the schemas (Video, Speaker, Comment…etc)
β”‚       β”‚   β”œβ”€β”€ db_type => Special types (SpeakerPicture…etc.)
β”‚       β”‚   └── db_utils => Some utility functions
β”‚       └── priv
β”‚           └── repo/migrations => All DB migrations files
β”œβ”€β”€ => You're reading it right now. Are you?
β”œβ”€β”€ rel => Release configs & tools
β”‚   β”œβ”€β”€ commands => Commands that will be available to run on the release (seed DB…etc.)
β”‚   β”œβ”€β”€ hooks => Some hooks for automatically run commands when release run.
β”‚   β”œβ”€β”€ runtime_config => Runtime configurations for all apps.
β”‚   └── config.exs => Release configuration.

Linked projects

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.