Problems Creating A Course With API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Post URL: /api/v1/accounts/1/courses
I am trying to create a new course using the API and every time is creates a course with none of my values filled in and gives it a name of 'Unnamed Course' I have tried stripping the payload down so i am basically only posting the name but still no luck.
Here are the two payloads I have tried:
#1. "{\"account_id\":1,\"course\":{\"id\":0,\"name\":\"AD Name\"}}"
#2. "{\"id\":0,\"name\":\"AD Name\"}"
I am not sure what i am doing wrong. Any help would be great.
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What programming language are you using? Can you post your entire code?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for your reply,
I got it to work. It turns out i was missing ContentType = "application/json" in my request.
Thanks for your help