{"_id":"564b79b31ed5c823003eb645","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,"user":"546d17e2eb9cfd1400dd4529","editedParams2":true,"parentDoc":null,"__v":5,"project":"55773a5ba042551900b002cb","version":{"_id":"55773a5ba042551900b002ce","project":"55773a5ba042551900b002cb","__v":18,"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","59cd4b81935249001c77c48e"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"Motherboard","version_clean":"1.0.0","version":"1"},"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-11-17T19:02:11.888Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[]},"method":"post","results":{"codes":[{"name":"","code":"{\n   \"code\":201,\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}","language":"json","status":201}]},"settings":"","auth":"required","params":[{"_id":"56575f20a795770d00a2af81","ref":"","in":"body","required":true,"desc":"The first name of the athlete","default":"","type":"string","name":"first_name"},{"_id":"56575f20a795770d00a2af80","ref":"","in":"body","required":true,"desc":"The family name of the athlete","default":"","type":"string","name":"family_name"},{"_id":"56575fa54d1c720d001f5214","ref":"","in":"body","required":true,"desc":"The date of birth of the athlete","default":"","type":"yyyy-mm-dd","name":"dob"},{"_id":"56575fa54d1c720d001f5213","ref":"","in":"body","required":true,"desc":"The gender of the athlete (male or female)","default":"","type":"string","name":"gender"},{"_id":"56575fa54d1c720d001f5212","ref":"","in":"body","required":true,"desc":"The country_id of the athlete","default":"","type":"int","name":"country_id"},{"_id":"56575fa54d1c720d001f5211","ref":"","in":"body","required":false,"desc":"The email address of the athlete","default":"","type":"string","name":"email"},{"_id":"56575fff96d7ff0d009fc536","ref":"","in":"body","required":true,"desc":"A pipe delimited list of athlete category ids","default":"","type":"string","name":"category_id"}],"url":"/athletes"},"isReference":true,"order":3,"body":"The **Create Athlete** method creates a new athlete and returns a basic athlete object. You may add additional profile information via the [Edit Athlete](https://developers.triathlon.org/docs/edit-an-athlete) method once you have a valid athlete_id.\n\nThis method validates that a duplicate user is not being created and returns a 400 error code if this validation fails i.e. a duplicate user exists in the system.","excerpt":"","slug":"create-an-athlete","type":"endpoint","title":"Create Athlete"}

postCreate Athlete


Definition

{{ api_url }}{{ page_api_url }}

Parameters

Body Params

first_name:
required
string
The first name of the athlete
family_name:
required
string
The family name of the athlete
dob:
required
yyyy-mm-dd
The date of birth of the athlete
gender:
required
string
The gender of the athlete (male or female)
country_id:
required
integer
The country_id of the athlete
email:
string
The email address of the athlete
category_id:
required
string
A pipe delimited list of athlete category ids

Result Format


Documentation

The **Create Athlete** method creates a new athlete and returns a basic athlete object. You may add additional profile information via the [Edit Athlete](https://developers.triathlon.org/docs/edit-an-athlete) method once you have a valid athlete_id. This method validates that a duplicate user is not being created and returns a 400 error code if this validation fails i.e. a duplicate user exists in the system.

User Information

Try It Out

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