Skip to main content

Update the 'Batch Course Update (PUT /course/v1/courses/batch)' API call to include Additional Fields

  • September 13, 2023
  • 6 replies
  • 202 views

Forum|alt.badge.img

The Batch Course Update API call only includes the bare minimum of options for LMS admins:

 

{
  "items": [
    {
      "id": 0,
      "code": "string",
      "title": "string",
      "description": "string",
      "language": "string",
      "course_status": "published",
      "category_id": 0,
      "category_code": 0,
      "thumbnail_id": 0,
      "batch_item_id": "string"
    }
  ]
}

 

This should be updated to include Additional Fields so that this is not a manual process when updating courses.

6 replies

Ian
Guide I
  • Guide I
  • September 21, 2023

I think you may want to share this as an idea.

But just in case it helps, I wanted to mention a potential workaround as well. That’d be to – instead of a batch update via the Courses service – cycle through your courses via the Learn service instead. You could do this either with a script or, if you have Docebo Connect, a recipe.

  1. You can get all courses via GET /learn/v1/courses, and then
  2. Update them one at a time via PUT /learn/v1/courses/{id}

There are many other fields that you can update this way besides the additional fields.


Forum|alt.badge.img
  • Author
  • Novice II
  • September 21, 2023

Thanks, Ian. Good point, I‘ve now shared it as an idea, here

Thanks for the potential workarounds - I will give those a try! 😃


Forum|alt.badge.img
  • Author
  • Novice II
  • September 29, 2023

Thanks to Ian’s suggestion, I have now been able to use Docebo Connect as a workaround.

This was achieved by uploading the data into a Lookup Table in Docebo Connect, then by using a repeat function to cycle through each record using the Update Course API call (/learn/v1/courses/{id}).

The only caveat is that Lookup Tables are limited to 10 columns, so if you have more than 9 fields to update (1 field is needed for the course id), then you need to use multiple tables.

 


  • Novice III
  • January 29, 2024

Hello @Ian & @trouk,

Thank you for sharing your experience. We are also looking for a workaround to update an additionnal fieldd with Batch course update and I came across your post but we do not have Docebo Connect and I’m wondering if this can do in Postman? Thanks


Ian
Guide I
  • Guide I
  • January 29, 2024

I’m fairly sure you can use Postman to do this, @RokiaB, but I’m not a Postman expert and so I don’t feel particularly comfortable trying to advise you on how to use scripting there. I think I know who to call, however.

*hums the theme tune to Ghostbusters*

@Bfarkas!


  • Novice III
  • January 29, 2024

Great! yes you’re right i didn’t do the link but yes probabely @Bfarkas can help me? Mainly to automate the PUT call or using a repeat function like mentioned above.. Thank you