Create new User activity from JSON

POST /endpoint/v1/user_activities

Create new User activity from JSON

Request Form

Response Example

{
  "errors": [
    {
      "activity": {
        "user_id": 2,
        "account_id": 1,
        "time_spent": 99.05
      },
      "message": [
        "Time spent invalid"
      ]
    }
  ]
}

Request Schema

  • additionalProperties: false
  • activities
    • Required: yes
    • Type: array
    • Items
      • Required: no
      • additionalProperties: false
      • user_id
        User id
        • Required: yes
        • Type: integer
        • Example: 3
      • account_id
        Account id
        • Required: yes
        • Type: integer
        • Example: 2
      • time_spent
        Time that user spent in ms, must be grater than 100
        • Required: yes
        • Type: number
        • Example: 101.05
      • course_id
        Course id
        • Required: no
        • Type: integer
        • Example: 3
      • course_session_id
        Course Session id
        • Required: no
        • Type: integer
        • Example: 3
      • material_id
        Material id
        • Required: no
        • Type: integer
        • Example: 3
      • quiz_id
        Quiz id
        • Required: no
        • Type: integer
        • Example: 3
      • question_id
        Question id
        • Required: no
        • Type: integer
        • Example: 3
      • document_id
        Document id
        • Required: no
        • Type: integer
        • Example: 3
      • meeting_id
        Meeting id
        • Required: no
        • Type: integer
        • Example: 3
      • timestamp
        Activity timestamp
        • Required: no
        • Type: string
        • Example: "2017-02-06T13:33:44.990+03:00"
  • access_token
    • Required: yes
    • Type: string
    • Example: "c2fe24abe5237808725fa7b41dcad7d2a6ea7f71e0ef613f7a49116e2868d12f"

Response Schema

  • additionalProperties: false
  • errors
    • Required: no
    • Type: array
    • Items
      • Required: no
      • additionalProperties: false
      • activity
        Activity from request
        • Required: no
        • additionalProperties: false
        • user_id
          User id
          • Required: no
          • Type: integer
          • Example: 2
        • account_id
          Account id
          • Required: no
          • Type: integer
          • Example: 1
        • time_spent
          Time that user spent in ms
          • Required: no
          • Type: number
          • Example: 99.05
      • message
        • Required: no
        • Type: array
        • Items
          Array of error messages
          • Required: no
          • Type: string
          • Example: "Time spent invalid"