Open-Source Headless CMS API
Important: This API is currently under development for the next major Directus version. It is not ready to be used on production yet.
- HTTP/Web Server
- MySQL 5.2+
- PHP 5.6+
- PDO+MySql extension
- cUrl extension
- GD extension
- FileInfo extension
- Multibyte String extension
The root directory for public access should be /path/to/directus/public
.
Read how to configure Directus on different HTTP Servers here.
Install MySQL 5.2 or newer
Install PHP 5.6 or newer and all the required dependencies
Download the latest release or clone this repository.
You need to install composer if you are going to install from source.
$ git clone https://github.com/directus/api.git
$ cd api
$ composer install
After composer install all the dependencies, you need to create a config file and a database.
Create a config file by copying config/api_sample.php
to config/api.php
change the database
configuration and everything should stay the same to work with default configuration.
Create the directus system tables and data by importing src/schema.sql
to the database you just created and configured in your config file.
Create the config file:
$ bin/directus install:config -n <database-name> -u <mysql-user> -p <mysql-password>
Create the directus system tables and data
$ bin/directus install:database
Create the directus default settings and user
$ bin/directus install:install -e <admin-email> -p <admin-password> -t <project-title>
The default access_token
is admin_token
.
Make you first request to see all the users:
GET /_/users?access_token=admin_token
- Directus Core codebase released under the GPLv3 license.
- Example Code, Design Previews, Demonstration Apps, Custom Extensions, Custom interfaces, and Documentation copyright 2017 RANGER Studio LLC.
- RANGER Studio owns all Directus trademarks, service marks, and graphic logos on behalf of our project's community. The names of all Directus projects are trademarks of RANGER Studio LLC.