instructure / canvas-lms

The open LMS by Instructure, Inc.
https://github.com/instructure/canvas-lms/wiki
GNU Affero General Public License v3.0
5.46k stars 2.44k forks source link

api /api/v1 returned json contains values without string quotes #2072

Open 2jt opened 2 years ago

2jt commented 2 years ago

Hi. On a self-hosted canvas instance api endpoints (for example /api/v1/courses/some-course-id/assignments) return json containing attributes like (url, html_url) with their values not being strings (meaning, not being wrapped in " "). Obviously trying to parse json containing these values breaks. On any other canvas instance I've tried (all of them deployed on dlg.instructure), a GET request using browser returns a valid json from that same endpoint (url, html_url values are wrapped with string quotes).

What could be that causes canvas to return this kind of json?

Ardena commented 1 year ago

I've never seen Canvas do anything like that. I have heard of browsers or other http services causing issues like that. What are you using to request the API data?