Activity Comments
Comments on an activity can be viewed by any user. However, only internal applications are allowed to create or delete them.
Summary and detailed representation attributes
id: | integer |
resource_state: |
integer indicates level of detail. Possible value: 2 -> ‘summary’ |
activity_id: |
integer parent activity id |
text: | string |
athlete: |
object summary representation of the commenting athlete |
created_at: | time string |
Example comment
[
{
"id": 26,
"activity_id": 123,
"resource_state": 2,
"text": "Nice ride!!!",
"athlete": {
"id": 227615,
"resource_state": 2,
"firstname": "John",
"lastname": "Applestrava",
"profile_medium": "http://pics.com/227615/medium.jpg",
"profile": "http://pics.com/227615//large.jpg",
"city": "San Francisco",
"state": "California",
"country": "United States",
"sex": "M",
"friend": "accepted",
"follower": "accepted",
"premium": true,
"created_at": "2009-08-26T13:42:05Z",
"updated_at": "2013-01-11T18:51:00Z"
},
"created_at": "2013-09-06T21:07:22Z"
}
]
The number of comments is included in the activity summary and detail responses. Use this endpoint to retrieve a list of comments left on a given activity. Pagination is supported.
Parameters
id: | integer required |
page: |
integer optional |
per_page: |
integer optional |
Returns an array of comment summary objects, oldest first.
Definition
GET https://www.strava.com/api/v3/activities/:id/comments
Example request
$ curl -G https://www.strava.com/api/v3/activities/123/comments \
-H "Authorization: Bearer 83ebeabdec09f6670863766f792ead24d61fe3f9"
Example response
[
{
"id": 26,
"activity_id": 123,
"resource_state": 2,
"text": "Nice ride!!!",
"athlete": {
"id": 227615,
"resource_state": 2,
"firstname": "John",
"lastname": "Applestrava",
"profile_medium": "http://pics.com/227615/medium.jpg",
"profile": "http://pics.com/227615//large.jpg",
"city": "San Francisco",
"state": "California",
"country": "United States",
"sex": "M",
"friend": "accepted",
"follower": "accepted",
"premium": true,
"created_at": "2009-08-26T13:42:05Z",
"updated_at": "2013-01-11T18:51:00Z"
},
"created_at": "2013-09-06T21:07:22Z"
}
]
Parameters
id: |
integer required ID of the activity to comment on |
text: |
string required |
Definition
POST https://www.strava.com/api/v3/activities/:id/comments
Only the owner of the activity, or the creator of the comment, can perform this delete action.
Parameters
id: |
integer required ID of the comment |
activity_id: |
integer required ID of the activity the comment is on |
Definition
DELETE https://www.strava.com/api/v3/activities/:activity_id/comments/:id