Import

A GET request will list the index.

Example request

$ curl -i http://skylar.livingfire.de/api/import

Response fields

Path Type Description

_links

Object

Links to other resources

Relation Description

self

Canonical link for this resource

importOruxmaps

See Oruxmaps

importLibra

See Libra

importMicrolife

See Microlife

importGarmin

See Garmin

Oruxmaps

A POST request will import a Oruxmaps KML file.

Example request
$ curl -i --form file=@oruxmaps.kml http://skylar.livingfire.de/api/import/oruxmaps
Example response
HTTP/1.1 201 OK
Content-Type: application/json;charset=UTF-8

{
  "status" : 201,
  "code" : "009004",
  "userMessage" : "upload oruxmaps successful: oruxmaps.kml",
  "developerMessage" : "upload oruxmaps successful",
  "moreInfoURL" : "https://github.com/phoen1x/skylar-the-scholar/blob/master/book_en.pdf"
}

Libra

A POST request will import a Libra CSV file.

Example request
$ echo '#Version:5
#Units:kg

#date;weight;weight trend;body fat;body fat trend;comment
2017-04-01 00:00:00;75.1;75.1;;;' \
    > libra.csv

$ curl -i --form file=@libra.csv http://skylar.livingfire.de/api/import/libra
Example response
HTTP/1.1 201 OK
Content-Type: application/json;charset=UTF-8

{
  "status" : 201,
  "code" : "009007",
  "userMessage" : "libra import successful: libra.csv",
  "developerMessage" : "libra import successful",
  "moreInfoURL" : "https://github.com/phoen1x/skylar-the-scholar/blob/master/book_en.pdf"
}

Microlife

A POST request will import a Microlife CSV file.

Example request
$ echo 'Name : Skylar
ID : skylar
Geschlecht : Weiblich
Geburtsdatum : 1. April 2010
Datum,Zeit,Systole,Diastole,Puls,Arrhythmie,MAM
"01.04.17","21:37","120","80","70","",""' \
    > microlife.csv

$ curl -i --form file=@microlife.csv http://skylar.livingfire.de/api/import/microlife
Example response
HTTP/1.1 201 OK
Content-Type: application/json;charset=UTF-8

{
  "status" : 201,
  "code" : "009009",
  "userMessage" : "microlife import successful: microlife.csv",
  "developerMessage" : "microlife import successful",
  "moreInfoURL" : "https://github.com/phoen1x/skylar-the-scholar/blob/master/book_en.pdf"
}

Garmin

A GET request will list the index.

Example request
$ curl -i http://skylar.livingfire.de/api/import/garmin
Response fields
Path Type Description

_links

Object

Links to other resources

Relation Description

self

Canonical link for this resource

importGarminActivity

See Garmin Activity

Activity

A POST request will import a Training Center XML (TCX) file.

Example request
$ # download sample https://developer.garmin.com/garmin-connect-api/sample-data/
$ curl https://developer.garmin.com/downloads/connect-api/sample_file.tcx > activity.tcx
$ curl -i --form file=@activity.tcx http://skylar.livingfire.de/api/import/garmin/activity
Example response
HTTP/1.1 201 OK
Content-Type: application/json;charset=UTF-8

{
  "status" : 201,
  "code" : "009005",
  "userMessage" : "garmin activity import successful: activity.tcx",
  "developerMessage" : "garmin activity import successful",
  "moreInfoURL" : "https://github.com/phoen1x/skylar-the-scholar/blob/master/book_en.pdf"
}