Create checkin

POST /1/checkins

Create checkin

multipart/form-data

Body

  • text string

    Summary of the activity.

  • extension string

    The extension of the image jpg or png.

  • imageData string(binary)

    The data of the image.

  • goalIds string Required
  • challengeIds array[string]
  • metaData array[object]
    Hide metaData attributes Show metaData attributes object
    • id string Required
    • name string
    • type string Required
    • value integer Required
    • priority integer Required

Responses

  • 200 application/json

    The created checkin.

    Hide response attribute Show response attribute object
    • checkin object
      Hide checkin attributes Show checkin attributes object
      • id string Required
      • user object Required
        Hide user attributes Show user attributes object
        • id string Required
        • nickname string Required
        • fullName string
        • email string Required
        • language string Required
        • startDate string Required
        • imageUrl string
        • waitingListValue number Required
        • notificationsEnabled boolean Required
        • notifyDaysBefore array[integer] Required
        • private boolean Required
        • yourFriendship object
          Hide yourFriendship attributes Show yourFriendship attributes object
          • id string Required
          • status string Required
          • date string Required
          • muted boolean
        • theirFriendship object
          Hide theirFriendship attributes Show theirFriendship attributes object
          • id string Required
          • status string Required
          • date string Required
          • muted boolean
      • text string
      • imageUrl string
      • date string Required
      • metaData array[object]
        Hide metaData attributes Show metaData attributes object
        • id string Required
        • name string
        • type string Required
        • value integer Required
        • priority integer Required
      • goalIds array[string]
      • challengeIds array[string]
POST /1/checkins
curl \
 --request POST 'https://api.localsporthero.com/1/checkins' \
 --header "Content-Type: multipart/form-data" \
 --form "text=string" \
 --form "extension=string" \
 --form "imageData=@file" \
 --form "goalIds=E37BE212-BC06-4A75-AE21-9D16F56AA686,E37BE212-BC06-4A75-AE21-9D16F56AA686" \
 --form "challengeIds[]=E37BE212-BC06-4A75-AE21-9D16F56AA686" \
 --form "metaData[]={"id"=>"85362399-38e1-4255-87a0-f3f984ed16d9", "name"=>"Push-ups", "type"=>"seconds, meters, number or exercise", "value"=>1000, "priority"=>1}"
Response examples (200)
{
  "checkin": {
    "id": "85362399-38e1-4255-87a0-f3f984ed16d9",
    "user": {
      "id": "1ab474d5-e1fa-4340-ba6a-5642e720ea6a",
      "nickname": "Stevertje",
      "fullName": "Stefan de Jong",
      "email": "stefandejong@gmail.com",
      "language": "nl",
      "startDate": "2022-05-02T11:00:00.000Z",
      "imageUrl": "https://example.org/image.jpg",
      "waitingListValue": 0,
      "notificationsEnabled": true,
      "notifyDaysBefore": [
        -1,
        1
      ],
      "private": false,
      "yourFriendship": {
        "id": "85362399-38e1-4255-87a0-f3f984ed16d9",
        "status": "requested, accepted or blocked",
        "date": "2022-05-02T11:00:00.000Z",
        "muted": false
      },
      "theirFriendship": {
        "id": "85362399-38e1-4255-87a0-f3f984ed16d9",
        "status": "requested, accepted or blocked",
        "date": "2022-05-02T11:00:00.000Z",
        "muted": false
      }
    },
    "text": "Het ging echt mega lekker...",
    "imageUrl": "https://example.org/image.jpg",
    "date": "2022-05-02T11:00:00.000Z",
    "metaData": [
      {
        "id": "85362399-38e1-4255-87a0-f3f984ed16d9",
        "name": "Push-ups",
        "type": "seconds, meters, number or exercise",
        "value": 1000,
        "priority": 1
      }
    ],
    "goalIds": [
      "85362399-38e1-4255-87a0-f3f984ed16d9"
    ],
    "challengeIds": [
      "85362399-38e1-4255-87a0-f3f984ed16d9"
    ]
  }
}