{"openapi":"3.1.0","info":{"title":"runfarwhere","version":"0.1.0"},"paths":{"/api/races":{"get":{"tags":["races"],"summary":"List Races","operationId":"list_races_api_races_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/races/qualify":{"get":{"tags":["races"],"summary":"Qualify For","description":"Every race whose entry standards a runner's time meets. Premium, as the\nstandards are; it names the races and the standard met, never the rest.","operationId":"qualify_for_api_races_qualify_get","parameters":[{"name":"gender","in":"query","required":true,"schema":{"enum":["men","women","nonbinary"],"type":"string","title":"Gender"}},{"name":"age","in":"query","required":true,"schema":{"type":"integer","maximum":110,"minimum":10,"title":"Age"}},{"name":"distance","in":"query","required":false,"schema":{"enum":["5k","10k","15k","10mi","half","marathon"],"type":"string","default":"marathon","title":"Distance"}},{"name":"time","in":"query","required":true,"schema":{"type":"string","maxLength":10,"title":"Time"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}":{"get":{"tags":["races"],"summary":"Get Race","description":"A race's page: its free part, for anyone, signed in or not. (The HTML\na crawler reads is built from `page` directly.)","operationId":"get_race_api_races__race_id__get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/course":{"get":{"tags":["races"],"summary":"Get Course","operationId":"get_course_api_races__race_id__course_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/find":{"get":{"tags":["races"],"summary":"Latest Finds","description":"The latest Find of each kind for the race, in one round trip.","operationId":"latest_finds_api_races__race_id__find_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/find/{kind}":{"get":{"tags":["races"],"summary":"Latest Find","description":"The latest Find of this kind for the race, or null. Once one has\nsaved what it found, the cached copy is dropped so the page reads it.","operationId":"latest_find_api_races__race_id__find__kind__get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}},{"name":"kind","in":"path","required":true,"schema":{"enum":["course","results","course_history","scout"],"type":"string","title":"Kind"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["races"],"summary":"Find","operationId":"find_api_races__race_id__find__kind__post","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}},{"name":"kind","in":"path","required":true,"schema":{"enum":["course","results","course_history","scout"],"type":"string","title":"Kind"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/course.gpx":{"get":{"tags":["races"],"summary":"Get Gpx","operationId":"get_gpx_api_races__race_id__course_gpx_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/weather":{"get":{"tags":["races"],"summary":"Get Weather","operationId":"get_weather_api_races__race_id__weather_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/results":{"get":{"tags":["races"],"summary":"Get Results","operationId":"get_results_api_races__race_id__results_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/terrain":{"get":{"tags":["races"],"summary":"Get Terrain","operationId":"get_terrain_api_races__race_id__terrain_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/course-history":{"get":{"tags":["races"],"summary":"Get Course History","operationId":"get_course_history_api_races__race_id__course_history_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/elite-entry":{"get":{"tags":["races"],"summary":"Get Elite Entry","description":"The times that get a runner into the race: every tier, distance,\ngender and age group it publishes.","operationId":"get_elite_entry_api_races__race_id__elite_entry_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/races/{race_id}/entrants":{"get":{"tags":["races"],"summary":"Get Entrants","description":"Competitor Scout: everyone on the race's entrants list on UltraSignup,\neach with their predicted finish once the race has been scouted. Asking\nmay have rundb read UltraSignup, so it takes an account, and counts.","operationId":"get_entrants_api_races__race_id__entrants_get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/collections":{"get":{"tags":["races"],"summary":"List Collections","operationId":"list_collections_api_collections_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/collections/{path}":{"get":{"tags":["races"],"summary":"Get Collection","description":"A list's page: \"100-mile-races\", \"in/colorado\", or \"all\" for /races.","operationId":"get_collection_api_collections__path__get","parameters":[{"name":"path","in":"path","required":true,"schema":{"type":"string","title":"Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/describe":{"post":{"tags":["races"],"summary":"Describe Race","description":"The five races nearest a description, each with a line on why. It\ncalls the model, so it takes an account, free.","operationId":"describe_race_api_describe_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DescribeIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/me":{"get":{"tags":["account"],"summary":"Read Me","operationId":"read_me_api_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/plans":{"get":{"tags":["account"],"summary":"Plans","operationId":"plans_api_plans_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/auth/link":{"post":{"tags":["account"],"summary":"Send Link","description":"Email a link that signs in once. The account is made when it's used.","operationId":"send_link_api_auth_link_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/verify":{"post":{"tags":["account"],"summary":"Verify","description":"The link's page posts here, rather than the link itself signing in: a\nmail scanner that opens every link would otherwise use it up.","operationId":"verify_api_auth_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/methods":{"get":{"tags":["account"],"summary":"Methods","description":"The ways to sign in besides email, for the sign-in forms.","operationId":"methods_api_auth_methods_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/auth/google":{"get":{"tags":["account"],"summary":"Google Start","operationId":"google_start_api_auth_google_get","parameters":[{"name":"next","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/google/callback":{"get":{"tags":["account"],"summary":"Google Back","description":"Back from Google: signed in and on to where they were, or back to the\nsign-in page saying what went wrong.","operationId":"google_back_api_auth_google_callback_get","parameters":[{"name":"code","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"}},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/signout":{"post":{"tags":["account"],"summary":"Sign Out","operationId":"sign_out_api_auth_signout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/auth/signout-everywhere":{"post":{"tags":["account"],"summary":"Sign Out Everywhere","description":"End every session the account has — on other devices, and any cookie\nthat's got out — not just this one.","operationId":"sign_out_everywhere_api_auth_signout_everywhere_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/billing/checkout":{"post":{"tags":["account"],"summary":"Checkout","operationId":"checkout_api_billing_checkout_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckoutIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/billing/sync":{"post":{"tags":["account"],"summary":"Sync","description":"Back from Checkout: ask Stripe how it went, without waiting on the webhook.","operationId":"sync_api_billing_sync_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/billing/portal":{"post":{"tags":["account"],"summary":"Portal","operationId":"portal_api_billing_portal_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/contact/token":{"get":{"summary":"Form Token","description":"A fresh form's token and the puzzle its browser solves before sending.","operationId":"form_token_api_contact_token_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenOut"}}}}}}},"/api/contact":{"post":{"summary":"Send","description":"Take a message from the contact form. Answers the same whether or not\nit was judged spam; only a bad address and the rate limit are errors.","operationId":"send_api_contact_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageIn"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/pace/{race_id}":{"get":{"tags":["pace"],"summary":"Read","operationId":"read_api_pace__race_id__get","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["pace"],"summary":"Save","operationId":"save_api_pace__race_id__put","parameters":[{"name":"race_id","in":"path","required":true,"schema":{"type":"integer","title":"Race Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlanIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CheckoutIn":{"properties":{"plan":{"type":"string","title":"Plan"}},"type":"object","required":["plan"],"title":"CheckoutIn"},"DescribeIn":{"properties":{"text":{"type":"string","maxLength":200,"minLength":2,"title":"Text"}},"type":"object","required":["text"],"title":"DescribeIn"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"LinkIn":{"properties":{"email":{"type":"string","maxLength":254,"title":"Email"},"next":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Next"}},"type":"object","required":["email"],"title":"LinkIn"},"MessageIn":{"properties":{"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name"},"email":{"type":"string","maxLength":254,"title":"Email"},"message":{"type":"string","maxLength":5000,"minLength":1,"title":"Message"},"token":{"type":"string","maxLength":300,"title":"Token","default":""},"number":{"anyOf":[{"type":"integer","maximum":100000000.0,"minimum":0.0},{"type":"null"}],"title":"Number"},"website":{"type":"string","maxLength":500,"title":"Website","default":""}},"type":"object","required":["name","email","message"],"title":"MessageIn"},"PlanIn":{"properties":{"goal":{"type":"string","maxLength":20,"title":"Goal"},"start":{"type":"string","maxLength":10,"title":"Start"},"stop":{"type":"integer","maximum":86400.0,"minimum":0.0,"title":"Stop"},"stops":{"additionalProperties":{"type":"integer"},"type":"object","maxProperties":200,"title":"Stops"},"drift":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Drift"},"altitude":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Altitude"}},"type":"object","required":["goal","start","stop","drift","altitude"],"title":"PlanIn"},"SyncIn":{"properties":{"session_id":{"type":"string","maxLength":200,"title":"Session Id"}},"type":"object","required":["session_id"],"title":"SyncIn"},"TokenOut":{"properties":{"token":{"type":"string","title":"Token"},"salt":{"type":"string","title":"Salt"},"challenge":{"type":"string","title":"Challenge"},"max_number":{"type":"integer","title":"Max Number"}},"type":"object","required":["token","salt","challenge","max_number"],"title":"TokenOut"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VerifyIn":{"properties":{"email":{"type":"string","maxLength":254,"title":"Email"},"token":{"type":"string","maxLength":120,"title":"Token"}},"type":"object","required":["email","token"],"title":"VerifyIn"}}}}