Skip to content
Greg Malcolm edited this page Jun 23, 2016 · 2 revisions

Details on each world being prospected

http://api.edmaterializer.com/api/v4/worlds/

With filtering:

http://api.edmaterializer.com/api/v4/worlds?system=achenar

Currently worlds are imported from the "Monster" Distant Worlds spreadsheet World page.

Only one record is kept per world, the record is shared by commanders. The last commander to update is the "updater" field. If it's imported from the monster spread sheet it'll be "DW Spreadsheet"

The world's id is used as a foreign key (world_id) for Basecamps, Surveys and World Surveys

Delete requests will only be honoured when received from the original creator and only if there are no dependent surveys, world surveys or basecamps linked.

Filters

Add filters on the GET "index" round as querystring params in the url:

(eg http://example.com/things/?filter1=a&filter2=b)

  • page
  • system
  • world
  • updater
  • creator
  • updated_before
  • updated_after

Sorting

Use sort (column name) and direction (asc or desc). Eg:

?sort=created_at&direction=desc

Notes / Updates

  • Added image_url for attaching images from external sites like imgur
  • Now includes child tables in the json when listed as a GET #show route
  • Application users (EDDiscovery) must submit a "user" root level param so we can discern if the request is legal for updates or deletes.
  • System name changes (other than case changes) are not supported. To change a system name apply the change to the the new parent system resource.
  • Using JSON API schema now (http://jsonapi.org/)