POST /routines/:id/favorite

POST /routines/{id}/favorite

Creates a favorite routine for current user.

Path parameters

  • id integer(int64) Required

    ID of the resource to fetch

Responses

POST /routines/{id}/favorite
curl \
 -X POST https://api.cosmily.com/api/v1/routines/{id}/favorite \
 -H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": {
    "id": 1,
    "user_id": 1,
    "routine_type": "AM",
    "routine_step_ids": [
      1,
      2
    ],
    "routine_step_order": [
      1,
      2
    ],
    "title": "Daily Routine",
    "status": "published",
    "created_at": "2021-10-04T13:24:22.000Z",
    "updated_at": "2021-11-13T20:23:18.000Z"
  }
}