{"_id":"564b79c31ed5c823003eb647","user":"546d17e2eb9cfd1400dd4529","version":{"_id":"55773a5ba042551900b002ce","project":"55773a5ba042551900b002cb","__v":17,"createdAt":"2015-06-09T19:11:23.764Z","releaseDate":"2015-06-09T19:11:23.764Z","categories":["55773a5ca042551900b002cf","55773a6ce6063e0d00481380","55773ab007e7110d001043ec","55773abaa042551900b002d5","55773ac207e7110d001043ed","55773acb07e7110d001043ee","55773ad3a042551900b002d6","55773adce6063e0d00481383","55773ae4a042551900b002d7","55773af307e7110d001043ef","55773af907e7110d001043f0","55773b0407e7110d001043f1","563a4f7ad25e8919005f3f39","563a4fcaa19edf0d00972321","564a70dc4cd0521700523edf","564b797bcc472d0d00da9435","564b855b766d4923004e1fd1"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"Motherboard","version_clean":"1.0.0","version":"1"},"__v":6,"project":"55773a5ba042551900b002cb","category":{"_id":"55773abaa042551900b002d5","version":"55773a5ba042551900b002ce","__v":18,"pages":["55776c06a042551900b0034f","564a6fdf4cd0521700523edc","564b6753cc472d0d00da940e","564b78801ed5c823003eb640","564b788fcc472d0d00da942e","564b7898dda79a19000f2641","564b78bfdda79a19000f2643","564b78cd1ed5c823003eb643","564b78ebdda79a19000f2646","564b791d766d4923004e1fb3","564b7929e323d01700a5132f","564b7935766d4923004e1fb5","564b793fe323d01700a51331","564b7957cc472d0d00da9431","564b7962dda79a19000f2648","564b79b31ed5c823003eb645","564b79c31ed5c823003eb647","564b79fee323d01700a51336"],"project":"55773a5ba042551900b002cb","sync":{"url":"","isSync":false},"reference":true,"createdAt":"2015-06-09T19:12:58.040Z","from_sync":false,"order":2,"slug":"athletes-api","title":"Athletes API"},"editedParams":true,"editedParams2":true,"parentDoc":null,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-11-17T19:02:27.759Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"method":"put","results":{"codes":[{"language":"json","status":200,"name":"","code":"{\n   \"code\":200,\n   \"status\":\"success\",\n   \"data\":{\n      \"athlete_id\":103070,\n      \"athlete_title\":\"Fabian Velazquez Rangel\",\n      \"athlete_slug\":\"fabian_velazquez_rangel\",\n      \"athlete_edit_date\":\"2016-01-06T19:09:08+00:00\",\n      \"athlete_first\":\"Fabian\",\n      \"athlete_last\":\"Velazquez Rangel\",\n      \"athlete_country_id\":219,\n      \"athlete_gender\":\"male\",\n      \"athlete_yob\":\"1996\",\n      \"validated\":false,\n      \"athlete_profile_image\":null,\n      \"athlete_noc\":\"MEX\",\n      \"athlete_country_name\":\"Mexico\",\n      \"athlete_country_isoa2\":\"MX\",\n      \"athlete_listing\":\"http:\\/\\/www.triathlon.org\\/athletes\\/profile\\/103070\\/fabian_velazquez_rangel\",\n      \"athlete_flag\":\"https:\\/\\/f9ca11ef49c28681fc01-0acbf57e00c47a50e70a1acb89e86c89.ssl.cf1.rackcdn.com\\/images\\/icons\\/mx.png\",\n      \"athlete_api_listing\":\"https:\\/\\/api.triathlon.org\\/v1\\/v1\\/athletes\\/103070\",\n      \"athlete_categories\":[\n         42\n      ]\n   }\n}"}]},"settings":"","examples":{"codes":[]},"auth":"required","params":[{"_id":"5657630c5656350d001d84bf","ref":"","in":"path","required":true,"desc":"The athlete_id of the athlete to be edited","default":"","type":"int","name":"athlete_id"},{"_id":"5702a43ab3cd0e20009ba328","ref":"","in":"body","required":true,"desc":"A json encoded object of key=>vaue pairs for updating","default":"","type":"object","name":"body"}],"url":"/athletes/{athlete_id}"},"isReference":true,"order":4,"body":"[block:callout]\n{\n  \"type\": \"danger\",\n  \"title\": \"Method checks the authenticated user is authorized to edit the resource\",\n  \"body\": \"Unauthorized users will be returned a 401 unauthorized response when attempting to update athletes they do not have ownership of.\"\n}\n[/block]\nThe **Edit Athlete** method allows editing of an athlete profile and returns a basic athlete object of the edited athlete.","excerpt":"","slug":"edit-an-athlete","type":"endpoint","title":"Edit Athlete"}

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Path Params

athlete_id:
required
integer
The athlete_id of the athlete to be edited

Body Params

body:
required
object
A json encoded object of key=>vaue pairs for updating

Result Format


Documentation

[block:callout] { "type": "danger", "title": "Method checks the authenticated user is authorized to edit the resource", "body": "Unauthorized users will be returned a 401 unauthorized response when attempting to update athletes they do not have ownership of." } [/block] The **Edit Athlete** method allows editing of an athlete profile and returns a basic athlete object of the edited athlete.

User Information

Try It Out

put
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}