Skip to content

REST API

Peter Stanko edited this page Nov 9, 2016 · 2 revisions

REST API

Basics

  • Versioned
  • Prefix: /api/v1.0/

Entities

Users

Method Endpoint Descriptions
GET /users/ Get all users
GET /users/{id or email} Get detail about the user
POST /users/ Create user
PUT /users/ Update user
DELETE /users/{id or name} Delete user

Users

Method Endpoint Descriptions
GET /heroes/ Get all heroes
GET /heroes/{id or name} Get detail about the hero
GET /heroes/{id or name}/roles Get user roles
POST /heroes/ Create hero
PUT /heroes/ Update hero
DELETE /heroes/{id or name} Delete hero

Troops

Method Endpoint Descriptions
GET /troops/ Get all troops
GET /troops/{id or name} Get detail about the troop
GET /troops/{id or name}/heroes Get heroes in troop
POST /troops/ Create troop
PUT /troops/ Update troop
DELETE /troops/{id or name} Delete troop

Roles

Method Endpoint Descriptions
GET /roles/ Get all roles
GET /roles/{id or name} Get detail about the role
GET /roles/{id or name}/heroes Get heroes that are associated to role
POST /roles/ Create role
PUT /roles/ Update role
DELETE /roles/{id or name} Delete role

Clone this wiki locally