Where is the custom column data history API?

maguire
Community Champion

The current gradebook history API only gives access to the history of changes to the grades for assignments. There does not appear to be an API to access the custom column data. Such an API should be quite straight forward as the underlying database table is very simple - as can be seen from the first few entries below:

canvas=# select * from custom_gradebook_column_data; 
 select * from custom_gradebook_column_data;
id | content | user_id | custom_gradebook_column_id
----+----------------------------------------------------------------------------------------------------------------+---------+----------------------------
1 | ⚠⚠Gerald Q. Maguire Jr. | 12 | 5
2 | ⚠⚠DA224X | 12 | 1
3 | yes_to_diva | 12 | 10
4 | A short working title | 12 | 3
5 | The project concerns finding Schrodinger's cat. | 12 | 4
6 | company = ABBBBA, country_code = AQ | 12 | 8
7 | Ann TheBigBoss <ann@abbba.com> | 12 | 9
8 | 2019-06-01 | 12 | 2
...
canvas=# \d custom_gradebook_column_data

Table "public.custom_gradebook_column_data" Column | Type | Modifiers
----------------------------+------------------------+---------------------------------------------------------------------------
id | bigint | not null default nextval('custom_gradebook_column_data_id_seq'::regclass)
content | character varying(255) | not null
user_id | bigint | not null
custom_gradebook_column_id | bigint | not null

The basic API could give a feed similar to 

GET /api/v1/courses/:course_id/gradebook_history/feed

for example, it could be:

GET /api/v1/courses/:course_id/custom_column_data/feed

This would filter the data by course_id (thus only giving custom columns that exist in the specified course) and then allow filtering on user_id (which when unspecified would give all entries). [Ascending as an optional boolean is potentially useful, as one might want the changes in reverse temporal order, i.e., the most recent changes first.]

However, looking at this data also points up a deficiency - there is no timestamp recorded in the database for these changes!  To me, this is a major deficiency, as it means that one cannot tell when the change was made - which seems to fly in the face of auditability. A timestamp might be another field, such as:  updated_at     | timestamp without time zone .

It would seem that the alternative is to use no submission assignments to be able to record information while having the history functionality.

0 Likes