HortusFox

HortusFox documentation


Project maintained by hortusfox Hosted on GitHub Pages — Theme by mattgraham

Custom Sharing Backend

This document describes the requirements to implement your own photo sharing backend. Implementing your own photo sharing backend is only required if you want to provide your own web service for letting your users share workspace photos instead of the official hortusfox.com backend.

Your backend needs to provide two API routes. After you have successfully set up your own backend, you can then set the URL of your backend via the admin dashboard.

Share photo

This endpoint is used to share a photo.

POST /api/photo/share

Arguments:

Successful response:

{
    "code": 200,
    "data": {
        "ident": "Item identifier",
        "url": "URL to photo (prettified)",
        "asset": "Full URL to image asset",
        "public": "Flag to indicate if public or private"
    }
}

Error response:

{
    "code": 500,
    "msg": "String with further information"
}

Remove photo

This endpoint is used to remove a photo upon request

ANY /api/photo/remove

Arguments:

Successful response:

{
    "code": 200
}

Error response:

{
    "code": 500,
    "msg": "String with further information"
}


Go back