Return a list of all short links.
Method: GET
URL: https://<domain>/links
Headers: X-Access-Token: <token supplied at login>
Body: Not required.
Expected response: Json string, e.g.
{ "status": 200, "data": [{ "name": "Link 1", "description": "First link", "source": "slink", "target": "www.example.com/some-page", "secure": true, "permanent": false, "active": true, "expire": "2018-12-31T23:58:00.000Z", "updated": "2018-08-01T15:00:00.000Z" }, { "name": "Link 2", "description": "Second link", "source": "slink2", "target": "www.example.com/some-other-page", "secure": true, "permanent": false, "active": true, "expire": "2018-12-31T23:58:00.000Z", "updated": "2018-08-01T15:00:00.000Z" }], "message": "2 links found." }
Return specified short url link.
Method: GET
URL: https://<domain>/links/<link name>
Headers: X-Access-Token: <token supplied at login>
Body: Not required.
Expected response: Json string, e.g.
{ "status": 200, "data": [{ "name": "Short Link", "description": "A short link", "source": "slink", "target": "wwww.example.com/some-page", "secure": true, "permanent": false, "active": true, "expire": "2018-12-31T23:58:00.000Z", "updated": "2018-08-01T15:00:00.000Z" }], "message": "1 link found." }
Create a new short url link.
Method: POST
URL: https://<domain>/links
Headers: Content-Type: application/json
X-Access-Token: <token supplied at login>
Body: Json string containing at least source and target. Any omitted will be defaulted to the values specified in the configuration, e.g.
{ "name": "A new short link", "description": "This is a new short link", "source": "slink", "target": "www.example.com/some-page", "secure": true, "permanent": false, "active": true, "expire": "2018-12-31T23:58:00.000Z" }
Expected response: Json string, e.g.
{ "status": 201, "data": [{ "source": "slink" }], "message": "Link confirmed." }
Update a short url link.
Method: PUT
URL: https://<domain>/links/<link name>
Headers: Content-Type: application/json
X-Access-Token: <token supplied at login>
Body: Json string containing one or more of the fields shown, e.g.
{ "name": "A short link", "description": "This is a short link", "target": "www.example.com/some-other-page", "secure": true, "permanent": false, "active": true, "expire": "2018-12-31T23:58:00.000Z" }
Expected response: Json string, e.g.
{ "status": 200, "data": [{ "source": "slink" }], "message": "Link updated." }
Delete a short url link.
Method: DELETE
URL: https://<domain>/links/<link name>
Headers: X-Access-Token: <token supplied at login>
Body: Not required.
Expected response: Json string, e.g.
{ "status": 200, "data": [{ "source": "slink" }], "message": "Link deleted." }