GET /contests/previous_week

GET /contests/previous_week

Get previous week contests

Responses

  • 200

    successful operation

    Hide response attribute Show response attribute object
    • data object
      Hide data attributes Show data attributes object
      • id integer
      • started_at string(DateTime)
      • ended_at string(DateTime)
      • week_number integer
      • winning_tickets array[integer]
      • prizes array[string]
  • 400

    Bad Request

  • 401

    Authorization information is missing or invalid.

  • 404

    Contest Not Found

  • 500

    Server Error

GET /contests/previous_week
curl \
 -X GET https://api.cosmily.com/api/v1/contests/previous_week \
 -H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": {
    "id": 42,
    "started_at": "string",
    "ended_at": "string",
    "week_number": 42,
    "winning_tickets": [
      42
    ],
    "prizes": [
      "string"
    ]
  }
}
Response examples (200)
{
  "data": {
    "id": 42,
    "started_at": "string",
    "ended_at": "string",
    "week_number": 42,
    "winning_tickets": [
      42
    ],
    "prizes": [
      "string"
    ]
  }
}