---
title: "Publish Race"
method: POST
path: "/races/{race_id}/publish"
---

# Publish Race

`POST /races/{race_id}/publish`

## Request

- Base URL: `https://safefamilyapp.com` (the document declares no server; this is the origin it was published from)
- URL: `https://safefamilyapp.com/races/{race_id}/publish`
- Auth: HTTP bearer

Make the race's results, course and measurement public. Owner or admin; needs scored results,
a confirmed email address, and the organizer's word that the race is theirs to publish.

Nobody approves a race. What happens instead: the race is screened (api/screening.py). A clean
race is public at once and is marked verified on its own after `AUTO_VERIFY_HOURS` unless an
admin objects first; a race with a strong sign of being invented or copied is held, not public,
with the reasons in the answer, and an admin decides. The admins hear about every publish.

## Path parameters

- `race_id` string, required

## Request body

- PublishRequest: What the organizer confirms when they press Publish: that they organize the race and have the right to publish these results. Recorded with the race.
  - `attest` boolean

## Response `200`

Successful Response

- RaceSummary
  - `race_id` string, required
  - `event_id` string, required
  - `event_name` string, required
  - `event_date` string, date, required
  - `course_name` string, required
  - `distance_km` number, required
  - `elevation_gain_m` number, required
  - `has_gpx` boolean
  - `scoring_version` string, required
  - `measurement_version` string, nullable
  - `measurement_status` string, nullable
  - `published_at` string, date-time, nullable
  - `is_published` boolean
  - `is_demo` boolean
  - `finisher_count` integer, nullable
  - `event_location` string, nullable
  - `event_country` string, nullable
  - `organizer_display` string, nullable
  - `organizer_website` string, nullable
  - `elevation_loss_m` number, nullable
  - `is_vertical` boolean
  - `listing_status` string
  - `is_listed` boolean
  - `calculator_only` boolean
  - `source_url` string, nullable
  - `edition_year` integer, nullable
  - `review_status` string
  - `review_flags` object[], nullable
  - `auto_verify_at` string, date-time, nullable
  - `reviewed_at` string, date-time, nullable
  - `reviewed_by` string, nullable
  - `review_note` string, nullable
  - `publish_attested_at` string, date-time, nullable

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/safefamilyapp/apis/otri-api.md) · [All operations](https://skmtc.dev/safefamilyapp/apis/otri-api/llms.txt) · [OpenAPI document](https://skmtc.dev/safefamilyapp/apis/otri-api/revisions/d07bb03cb836?raw)
