Skip to content

file

POST
/trail/{id}/file

Uploads or removes photos, uploads GPS data file for a trail.

Authorizations

Parameters

Path Parameters

id
required
string

Trail Id

Example
4yql7587j64qdo5

Request Body

object
photos

List of image files to add. Allowed file types: PNG, JPG, WEBP, SVG

string format: binary
[
""
]
photos-

List of file names to delete.

Array<string>
gpx

File containing GPS track data. Allowed file types: GPX, JSON, FIT, KML

string format: binary
<= 1 characters
file:///Users/christianbeutel/Downloads/2021-10-24_536064034_Essen-Mitte.nach.Bochum-Hauptbahnhof.gpx

Responses

200

object
author
required
string
category
required
string
collectionId
required
string
collectionName
required
string
created
required
string
date
required
string
description
required
string
difficulty
required
string
distance
required
number
duration
required
number
elevation_gain
required
number
elevation_loss
required
number
gpx
required
string
id
required
string
lat
required
number
location
required
string
lon
required
number
name
required
string
photos
required
Array<string>
public
required
boolean
summit_logs
required
Array<string>
thumbnail
required
integer
updated
required
string
waypoints
required
Array<string>
Examples

Success

{
"author": "3mugf953w4a9fg5",
"category": "7sqwezntokmbvdr",
"collectionId": "e864strfxo14pm4",
"collectionName": "trails",
"created": "2025-01-03 11:42:07.848Z",
"date": "2025-01-03 07:14:55.803Z",
"description": "At dolor deleniti architecto nulla nemo in perspiciatis. Iste iusto ex quidem sed modi. Ipsam unde doloribus aut. Molestias ducimus molestias soluta.",
"difficulty": "easy",
"distance": 71499916.19683264,
"duration": 87771408.86514412,
"elevation_gain": 67291819.86293587,
"elevation_loss": 76718134.08675973,
"gpx": "4_champex_to_le_chable_h8sE0CwAes.gpx",
"id": "hfdmpa1n1ulyr64",
"lat": 85.23610854378416,
"location": "ex laborum",
"lon": -48.60959423486602,
"name": "inventore est laboriosam",
"photos": [
"23xxesym0e9w18z2904frnpgy7_0h84aa22yv.jpg",
"23xxesym0e9w18z2904frnpgy7_7JhLWsRrsm.jpg"
],
"public": true,
"summit_logs": [
"3pagejfjt1cz4vr"
],
"thumbnail": 0,
"updated": "2025-01-03 12:08:43.037Z",
"waypoints": []
}

400

object
message
required
string
detail
required
Array<object>
object
code
string
minimum
integer
type
string
inclusive
boolean
exact
boolean
message
string
path
Array<string>
Examples

Exception

{
"message": "invalid_params",
"detail": [
{
"code": "too_small",
"minimum": 15,
"type": "string",
"inclusive": true,
"exact": true,
"message": "String must contain exactly 15 character(s)",
"path": [
"id"
]
}
]
}

404

object
message
required
string
detail
required
object
code
required
integer
message
required
string
data
required
object
Examples

Exception

{
"message": "The requested resource wasn't found.",
"detail": {
"code": 404,
"message": "The requested resource wasn't found.",
"data": {}
}
}