mirror of
https://github.com/alexmickelson/canvasManagement.git
synced 2026-03-25 23:28:33 -06:00
model refactorings
This commit is contained in:
@@ -1,46 +0,0 @@
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Accounts;
|
||||
public class AccountModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("uuid")]
|
||||
public string Uuid { get; set; }
|
||||
|
||||
[JsonPropertyName("parent_account_id")]
|
||||
public ulong? ParentAccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("root_account_id")]
|
||||
public ulong? RootAccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("default_user_storage_quota_mb")]
|
||||
public ulong? DefaultUserStorageQuotaMb { get; set; }
|
||||
|
||||
[JsonPropertyName("default_group_storage_quota_mb")]
|
||||
public ulong? DefaultGroupStorageQuotaMb { get; set; }
|
||||
|
||||
[JsonPropertyName("default_time_zone")]
|
||||
public string DefaultTimeZone { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_account_id")]
|
||||
public string? SisAccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("integrationI-d")]
|
||||
public string? IntegrationId { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public string? SisImportId { get; set; }
|
||||
|
||||
[JsonPropertyName("lti_guid")]
|
||||
public string LtiGuid { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Accounts;
|
||||
public class HelpLinkModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("subtext")]
|
||||
public string Subtext { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("available_to")]
|
||||
public IEnumerable<string> AvailableTo { get; set; }
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Accounts;
|
||||
public class HelpLinksModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("help_link_name")]
|
||||
public string HelpLinkName { get; set; }
|
||||
|
||||
[JsonPropertyName("help_link_icon")]
|
||||
public string HelpLinkIcon { get; set; }
|
||||
|
||||
[JsonPropertyName("custom_help_links")]
|
||||
public IEnumerable<HelpLinkModel> CustomHelpLinks { get; set; }
|
||||
|
||||
[JsonPropertyName("default_help_links")]
|
||||
public IEnumerable<HelpLinkModel> DefaultHelpLinks { get; set; }
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Accounts;
|
||||
public class TermsOfServiceModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("terms_type")]
|
||||
public string TermsType { get; set; }
|
||||
|
||||
[JsonPropertyName("passive")]
|
||||
public bool Passive { get; set; }
|
||||
|
||||
[JsonPropertyName("account_id")]
|
||||
public ulong AccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("content")]
|
||||
public string Content { get; set; }
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public class CourseAssignmentSummaryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("assignment_id")]
|
||||
public ulong AssignmentId { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime DueAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("muted")]
|
||||
public bool Muted { get; set; }
|
||||
|
||||
[JsonPropertyName("points_possible")]
|
||||
public decimal PointsPossible { get; set; }
|
||||
|
||||
[JsonPropertyName("non_digital_submission")]
|
||||
public bool? NonDigitalSubmission { get; set; }
|
||||
|
||||
[JsonPropertyName("max_score")]
|
||||
public decimal? MaxScore { get; set; }
|
||||
|
||||
[JsonPropertyName("min_score")]
|
||||
public decimal? MinScore { get; set; }
|
||||
|
||||
[JsonPropertyName("first_quartile")]
|
||||
public decimal? FirstQuartile { get; set; }
|
||||
|
||||
[JsonPropertyName("median")]
|
||||
public decimal? Median { get; set; }
|
||||
|
||||
[JsonPropertyName("third_quartile")]
|
||||
public decimal? ThirdQuartile { get; set; }
|
||||
|
||||
[JsonPropertyName("tardiness_breakdown")]
|
||||
public TardinessModel TardinessBreakdown { get; set; }
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public class CourseStudentSummaryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("page_views")]
|
||||
public uint PageViews { get; set; }
|
||||
|
||||
[JsonPropertyName("max_page_views")]
|
||||
public uint? MaxPageViews { get; set; }
|
||||
|
||||
[JsonPropertyName("page_views_level")]
|
||||
public uint? PageViewsLevel { get; set; }
|
||||
|
||||
[JsonPropertyName("participations")]
|
||||
public uint Participations { get; set; }
|
||||
|
||||
[JsonPropertyName("max_participations")]
|
||||
public uint? MaxParticipations { get; set; }
|
||||
|
||||
[JsonPropertyName("participations_level")]
|
||||
public uint? ParticipationsLevel { get; set; }
|
||||
|
||||
[JsonPropertyName("tardiness_breakdown")]
|
||||
public TardinessModel TardinessBreakdown { get; set; }
|
||||
}
|
||||
@@ -1,41 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
// The format of this model in the documentation is COMPLETELY WRONG. Each property is an array of objects, not an object,
|
||||
// and each of those objects have some extra fields: {id, date, views, participations} in by_date and
|
||||
// {id, category, views} in by_category. In both cases, id seems to be null 100% of the time, so I am omitting that one.
|
||||
// The primary keys (date and category) are thankfully discrete, so we can trivially build the dictionary ourselves.
|
||||
public class DepartmentParticipationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("by_date")]
|
||||
public IEnumerable<DepartmentParticipationDateEntryModel> ByDate { get; set; }
|
||||
|
||||
[JsonPropertyName("by_category")]
|
||||
public IEnumerable<DepartmentParticipationCategoryEntryModel> ByCategory { get; set; }
|
||||
}
|
||||
|
||||
public class DepartmentParticipationDateEntryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("date")]
|
||||
public DateTime Date { get; set; }
|
||||
|
||||
[JsonPropertyName("views")]
|
||||
public ulong Views { get; set; }
|
||||
|
||||
[JsonPropertyName("participations")]
|
||||
public ulong Participations { get; set; }
|
||||
}
|
||||
|
||||
public class DepartmentParticipationCategoryEntryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("category")]
|
||||
public string Category { get; set; }
|
||||
|
||||
[JsonPropertyName("views")]
|
||||
public ulong Views { get; set; }
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public class DepartmentStatisticsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("courses")]
|
||||
public ulong Courses { get; set; }
|
||||
|
||||
[JsonPropertyName("subaccounts")]
|
||||
public ulong Subaccounts { get; set; }
|
||||
|
||||
[JsonPropertyName("teacher")]
|
||||
public ulong Teachers { get; set; }
|
||||
|
||||
[JsonPropertyName("students")]
|
||||
public ulong Students { get; set; }
|
||||
|
||||
[JsonPropertyName("discussion_topics")]
|
||||
public ulong DiscussionTopics { get; set; }
|
||||
|
||||
[JsonPropertyName("media_objects")]
|
||||
public ulong MediaObjects { get; set; }
|
||||
|
||||
[JsonPropertyName("attachments")]
|
||||
public ulong Attachments { get; set; }
|
||||
|
||||
[JsonPropertyName("assignments")]
|
||||
public ulong Assignments { get; set; }
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public class TardinessModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("missing")]
|
||||
public decimal Missing { get; set; }
|
||||
|
||||
[JsonPropertyName("late")]
|
||||
public decimal Late { get; set; }
|
||||
|
||||
[JsonPropertyName("on_time")]
|
||||
public decimal OnTime { get; set; }
|
||||
|
||||
[JsonPropertyName("floating")]
|
||||
public decimal Floating { get; set; }
|
||||
|
||||
[JsonPropertyName("total")]
|
||||
public decimal Total { get; set; }
|
||||
}
|
||||
@@ -1,57 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public struct UserAssignmentSubmissionDataModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("submitted_at")]
|
||||
public DateTime? SubmittedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("score")]
|
||||
public double? Score { get; set; }
|
||||
}
|
||||
|
||||
public class UserAssignmentDataModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("assignment_id")]
|
||||
public ulong AssignmentId { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("points_possible")]
|
||||
public double? PointsPossible { get; set; }
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("muted")]
|
||||
public bool? Muted { get; set; }
|
||||
|
||||
[JsonPropertyName("min_score")]
|
||||
public double? MinScore { get; set; }
|
||||
|
||||
[JsonPropertyName("max_score")]
|
||||
public double? MaxScore { get; set; }
|
||||
|
||||
[JsonPropertyName("median")]
|
||||
public double? Median { get; set; }
|
||||
|
||||
[JsonPropertyName("first_quartile")]
|
||||
public double? FirstQuartile { get; set; }
|
||||
|
||||
[JsonPropertyName("third_quartile")]
|
||||
public double? ThirdQuartile { get; set; }
|
||||
|
||||
[JsonPropertyName("module_ids")]
|
||||
public IEnumerable<ulong> ModuleIds { get; set; }
|
||||
|
||||
[JsonPropertyName("submission")]
|
||||
public UserAssignmentSubmissionDataModel? Submission { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Analytics;
|
||||
public struct UserParticipationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("page_views")]
|
||||
public Dictionary<DateTime, ulong> PageViews { get; set; }
|
||||
|
||||
[JsonPropertyName("participations")]
|
||||
public IEnumerable<UserParticipationEventModel> Participations { get; set; }
|
||||
}
|
||||
|
||||
public struct UserParticipationEventModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
}
|
||||
@@ -1,87 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Calendar;
|
||||
|
||||
namespace CanvasModel.Appointments;
|
||||
|
||||
public class AppointmentGroupModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime StartAt { get; set; }
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime EndAt { get; set; }
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("location_name")]
|
||||
public string LocationName { get; set; }
|
||||
|
||||
[JsonPropertyName("location_address")]
|
||||
public string LocationAddress { get; set; }
|
||||
|
||||
[JsonPropertyName("participant_count")]
|
||||
public uint? ParticipantCount { get; set; }
|
||||
|
||||
[JsonPropertyName("reserved_times")]
|
||||
public IEnumerable<AppointmentModel> ReservedTimes { get; set; }
|
||||
|
||||
[JsonPropertyName("context_codes")]
|
||||
public IEnumerable<string> ContextCodes { get; set; }
|
||||
|
||||
[JsonPropertyName("sub_context_codes")]
|
||||
public IEnumerable<string> SubContextCodes { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("requiring_action")]
|
||||
public bool? RequiringAction { get; set; }
|
||||
|
||||
[JsonPropertyName("appointments_count")]
|
||||
public uint AppointmentsCount { get; set; }
|
||||
|
||||
[JsonPropertyName("appointments")]
|
||||
public IEnumerable<CalendarEventModel> Appointments { get; set; }
|
||||
|
||||
[JsonPropertyName("new_appointments")]
|
||||
public IEnumerable<CalendarEventModel>? NewAppointments { get; set; }
|
||||
|
||||
[JsonPropertyName("max_appointments_per_participant")]
|
||||
public uint? MaxAppointmentsPerParticipant { get; set; }
|
||||
|
||||
[JsonPropertyName("min_appointments_per_participant")]
|
||||
public uint? MinAppointmentsPerParticipant { get; set; }
|
||||
|
||||
[JsonPropertyName("participants_per_appointment")]
|
||||
public uint? ParticipantsPerAppointment { get; set; }
|
||||
|
||||
[JsonPropertyName("participant_visibility")]
|
||||
public string ParticipantVisibility { get; set; }
|
||||
|
||||
[JsonPropertyName("participant_type")]
|
||||
public string ParticipantType { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("html")]
|
||||
public string HtmlUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
}
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Appointments;
|
||||
|
||||
public class AppointmentModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime StartAt { get; set; }
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime EndAt { get; set; }
|
||||
}
|
||||
|
||||
@@ -1,26 +1,22 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
|
||||
public class AssignmentDateModel
|
||||
{
|
||||
public record AssignmentDateModel
|
||||
(
|
||||
[property: JsonPropertyName("title")]
|
||||
string Title,
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong? Id { get; set; }
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong? Id = null,
|
||||
|
||||
[JsonPropertyName("base")]
|
||||
public bool? Base { get; set; }
|
||||
[property: JsonPropertyName("base")]
|
||||
bool? Base = null,
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
[property: JsonPropertyName("due_at")]
|
||||
DateTime? DueAt = null,
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
[property: JsonPropertyName("unlock_at")]
|
||||
DateTime? UnlockAt = null,
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("lock_at")]
|
||||
DateTime? LockAt = null
|
||||
);
|
||||
@@ -1,212 +1,209 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Discussions;
|
||||
using CanvasModel.Submissions;
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class AssignmentModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
public record AssignmentModel
|
||||
(
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
[property: JsonPropertyName("name")]
|
||||
string Name,
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
[property: JsonPropertyName("description")]
|
||||
string Description,
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
[property: JsonPropertyName("created_at")]
|
||||
DateTime CreatedAt,
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
[property: JsonPropertyName("has_overrides")]
|
||||
bool HasOverrides,
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
[property: JsonPropertyName("course_id")]
|
||||
ulong CourseId,
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
[property: JsonPropertyName("html_url")]
|
||||
string HtmlUrl,
|
||||
|
||||
[JsonPropertyName("has_overrides")]
|
||||
public bool HasOverrides { get; set; }
|
||||
[property: JsonPropertyName("submissions_download_url")]
|
||||
string SubmissionsDownloadUrl,
|
||||
|
||||
[JsonPropertyName("all_dates")]
|
||||
public IEnumerable<AssignmentDateModel>? AllDates { get; set; }
|
||||
[property: JsonPropertyName("assignment_group_id")]
|
||||
ulong AssignmentGroupId,
|
||||
|
||||
[JsonPropertyName("course_id")]
|
||||
public ulong CourseId { get; set; }
|
||||
[property: JsonPropertyName("due_date_required")]
|
||||
bool DueDateRequired,
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
[property: JsonPropertyName("max_name_length")]
|
||||
uint MaxNameLength,
|
||||
|
||||
[JsonPropertyName("submissions_download_url")]
|
||||
public string SubmissionsDownloadUrl { get; set; }
|
||||
[property: JsonPropertyName("peer_reviews")]
|
||||
bool PeerReviews,
|
||||
|
||||
[JsonPropertyName("assignment_group_id")]
|
||||
public ulong AssignmentGroupId { get; set; }
|
||||
[property: JsonPropertyName("automatic_peer_reviews")]
|
||||
bool AutomaticPeerReviews,
|
||||
|
||||
[JsonPropertyName("due_date_required")]
|
||||
public bool DueDateRequired { get; set; }
|
||||
[property: JsonPropertyName("position")]
|
||||
ulong Position,
|
||||
|
||||
[JsonPropertyName("allowed_extensions")]
|
||||
public IEnumerable<string>? AllowedExtensions { get; set; }
|
||||
[property: JsonPropertyName("grading_type")]
|
||||
string GradingType,
|
||||
|
||||
[JsonPropertyName("max_name_length")]
|
||||
public uint MaxNameLength { get; set; }
|
||||
[property: JsonPropertyName("published")]
|
||||
bool Published,
|
||||
|
||||
[JsonPropertyName("turnitin_enabled")]
|
||||
public bool? TurnitinEnabled { get; set; }
|
||||
[property: JsonPropertyName("unpublishable")]
|
||||
bool Unpublishable,
|
||||
|
||||
[JsonPropertyName("vericite_enabled")]
|
||||
public bool? VeriCiteEnabled { get; set; }
|
||||
[property: JsonPropertyName("only_visible_to_overrides")]
|
||||
bool OnlyVisibleToOverrides,
|
||||
|
||||
[JsonPropertyName("turnitin_settings")]
|
||||
public TurnitinSettingsModel? TurnitinSettings { get; set; }
|
||||
[property: JsonPropertyName("locked_for_user")]
|
||||
bool LockedForUser,
|
||||
|
||||
[JsonPropertyName("grade_group_students_individually")]
|
||||
public bool? GradeGroupStudentsIndividually { get; set; }
|
||||
[property: JsonPropertyName("moderated_grading")]
|
||||
bool ModeratedGrading,
|
||||
|
||||
[JsonPropertyName("external_tool_tag_attributes")]
|
||||
public ExternalToolTagAttributesModel? ExternalToolTagAttributes { get; set; }
|
||||
[property: JsonPropertyName("grader_count")]
|
||||
uint GraderCount,
|
||||
|
||||
[JsonPropertyName("peer_reviews")]
|
||||
public bool PeerReviews { get; set; }
|
||||
[property: JsonPropertyName("allowed_attempts")]
|
||||
int AllowedAttempts,
|
||||
|
||||
[JsonPropertyName("automatic_peer_reviews")]
|
||||
public bool AutomaticPeerReviews { get; set; }
|
||||
[property: JsonPropertyName("submission_types")]
|
||||
IEnumerable<string> SubmissionTypes,
|
||||
|
||||
[JsonPropertyName("peer_review_count")]
|
||||
public uint? PeerReviewCount { get; set; }
|
||||
[property: JsonPropertyName("updated_at")]
|
||||
DateTime? UpdatedAt = null,
|
||||
|
||||
[JsonPropertyName("peer_reviews_assign_at")]
|
||||
public DateTime? PeerReviewsAssignAt { get; set; }
|
||||
[property: JsonPropertyName("due_at")]
|
||||
DateTime? DueAt = null,
|
||||
|
||||
[JsonPropertyName("intra_group_peer_reviews")]
|
||||
public bool? IntraGroupPeerReviews { get; set; }
|
||||
[property: JsonPropertyName("lock_at")]
|
||||
DateTime? LockAt = null,
|
||||
|
||||
[JsonPropertyName("group_category_id")]
|
||||
public ulong? GroupCategoryId { get; set; }
|
||||
[property: JsonPropertyName("unlock_at")]
|
||||
DateTime? UnlockAt = null,
|
||||
|
||||
[JsonPropertyName("needs_grading_count")]
|
||||
public uint? NeedsGradingCount { get; set; }
|
||||
[property: JsonPropertyName("all_dates")]
|
||||
IEnumerable<AssignmentDateModel>? AllDates = null,
|
||||
|
||||
[JsonPropertyName("needs_grading_count_be_section")]
|
||||
public IEnumerable<NeedsGradingCountModel>? NeedsGradingCountBySection { get; set; }
|
||||
[property: JsonPropertyName("allowed_extensions")]
|
||||
IEnumerable<string>? AllowedExtensions = null,
|
||||
|
||||
[JsonPropertyName("position")]
|
||||
public ulong Position { get; set; }
|
||||
[property: JsonPropertyName("turnitin_enabled")]
|
||||
bool? TurnitinEnabled = null,
|
||||
|
||||
[JsonPropertyName("post_to_sis")]
|
||||
public bool? PostToSis { get; set; }
|
||||
[property: JsonPropertyName("vericite_enabled")]
|
||||
bool? VeriCiteEnabled = null,
|
||||
|
||||
[JsonPropertyName("integration_id")]
|
||||
public string? IntegrationId { get; set; }
|
||||
[property: JsonPropertyName("turnitin_settings")]
|
||||
TurnitinSettingsModel? TurnitinSettings = null,
|
||||
|
||||
[JsonPropertyName("integration_data")]
|
||||
public object? IntegrationData { get; set; }
|
||||
[property: JsonPropertyName("grade_group_students_individually")]
|
||||
bool? GradeGroupStudentsIndividually = null,
|
||||
|
||||
[JsonPropertyName("muted")]
|
||||
public bool? Muted { get; set; }
|
||||
[property: JsonPropertyName("external_tool_tag_attributes")]
|
||||
ExternalToolTagAttributesModel? ExternalToolTagAttributes = null,
|
||||
|
||||
[JsonPropertyName("points_possible")]
|
||||
public double? PointsPossible { get; set; }
|
||||
[property: JsonPropertyName("peer_review_count")]
|
||||
uint? PeerReviewCount = null,
|
||||
|
||||
[JsonPropertyName("submission_types")]
|
||||
public IEnumerable<string> SubmissionTypes { get; set; }
|
||||
[property: JsonPropertyName("peer_reviews_assign_at")]
|
||||
DateTime? PeerReviewsAssignAt = null,
|
||||
|
||||
[JsonPropertyName("has_submitted_submissions")]
|
||||
public bool? HasSubmittedSubmissions { get; set; }
|
||||
[property: JsonPropertyName("intra_group_peer_reviews")]
|
||||
bool? IntraGroupPeerReviews = null,
|
||||
|
||||
[JsonPropertyName("grading_type")]
|
||||
public string GradingType { get; set; }
|
||||
[property: JsonPropertyName("group_category_id")]
|
||||
ulong? GroupCategoryId = null,
|
||||
|
||||
[JsonPropertyName("grading_standard_id")]
|
||||
public ulong? GradingStandardId { get; set; }
|
||||
[property: JsonPropertyName("needs_grading_count")]
|
||||
uint? NeedsGradingCount = null,
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool Published { get; set; }
|
||||
[property: JsonPropertyName("needs_grading_count_be_section")]
|
||||
IEnumerable<NeedsGradingCountModel>? NeedsGradingCountBySection = null,
|
||||
|
||||
[JsonPropertyName("unpublishable")]
|
||||
public bool Unpublishable { get; set; }
|
||||
[property: JsonPropertyName("post_to_sis")]
|
||||
bool? PostToSis = null,
|
||||
|
||||
[JsonPropertyName("only_visible_to_overrides")]
|
||||
public bool OnlyVisibleToOverrides { get; set; }
|
||||
[property: JsonPropertyName("integration_id")]
|
||||
string? IntegrationId = null,
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool LockedForUser { get; set; }
|
||||
[property: JsonPropertyName("integration_data")]
|
||||
object? IntegrationData = null,
|
||||
|
||||
[JsonPropertyName("lock_info")]
|
||||
public LockInfoModel? LockInfo { get; set; }
|
||||
[property: JsonPropertyName("muted")]
|
||||
bool? Muted = null,
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string? LockExplanation { get; set; }
|
||||
[property: JsonPropertyName("points_possible")]
|
||||
double? PointsPossible = null,
|
||||
|
||||
[JsonPropertyName("quiz_id")]
|
||||
public ulong? QuizId { get; set; }
|
||||
[property: JsonPropertyName("has_submitted_submissions")]
|
||||
bool? HasSubmittedSubmissions = null,
|
||||
|
||||
[JsonPropertyName("anonymous_submissions")]
|
||||
public bool? AnonymousSubmissions { get; set; }
|
||||
[property: JsonPropertyName("grading_standard_id")]
|
||||
ulong? GradingStandardId = null,
|
||||
|
||||
[JsonPropertyName("discussion_topic")]
|
||||
public DiscussionTopicModel? DiscussionTopic { get; set; }
|
||||
[property: JsonPropertyName("lock_info")]
|
||||
LockInfoModel? LockInfo = null,
|
||||
|
||||
[JsonPropertyName("freeze_on_copy")]
|
||||
public bool? FreezeOnCopy { get; set; }
|
||||
[property: JsonPropertyName("lock_explanation")]
|
||||
string? LockExplanation = null,
|
||||
|
||||
[JsonPropertyName("frozen")]
|
||||
public bool? Frozen { get; set; }
|
||||
[property: JsonPropertyName("quiz_id")]
|
||||
ulong? QuizId = null,
|
||||
|
||||
[JsonPropertyName("frozen_attributes")]
|
||||
public IEnumerable<string>? FrozenAttributes { get; set; }
|
||||
[property: JsonPropertyName("anonymous_submissions")]
|
||||
bool? AnonymousSubmissions = null,
|
||||
|
||||
[JsonPropertyName("submission")]
|
||||
public SubmissionModel? Submission { get; set; }
|
||||
[property: JsonPropertyName("discussion_topic")]
|
||||
DiscussionTopicModel? DiscussionTopic = null,
|
||||
|
||||
[JsonPropertyName("use_rubric_for_grading")]
|
||||
public bool? UseRubricForGrading { get; set; }
|
||||
[property: JsonPropertyName("freeze_on_copy")]
|
||||
bool? FreezeOnCopy = null,
|
||||
|
||||
[JsonPropertyName("rubric_settings")]
|
||||
public object? RubricSettings { get; set; } // again, docs give no concrete type.
|
||||
[property: JsonPropertyName("frozen")]
|
||||
bool? Frozen = null,
|
||||
|
||||
[JsonPropertyName("rubric")]
|
||||
public IEnumerable<RubricCriteriaModel>? Rubric { get; set; }
|
||||
[property: JsonPropertyName("frozen_attributes")]
|
||||
IEnumerable<string>? FrozenAttributes = null,
|
||||
|
||||
[JsonPropertyName("assignment_visibility")]
|
||||
public IEnumerable<ulong>? AssignmentVisibility { get; set; }
|
||||
[property: JsonPropertyName("submission")]
|
||||
SubmissionModel? Submission = null,
|
||||
|
||||
[JsonPropertyName("overrides")]
|
||||
public IEnumerable<AssignmentOverrideModel>? Overrides { get; set; }
|
||||
[property: JsonPropertyName("use_rubric_for_grading")]
|
||||
bool? UseRubricForGrading = null,
|
||||
|
||||
[JsonPropertyName("omit_from_final_grade")]
|
||||
public bool? OmitFromFinalGrade { get; set; }
|
||||
[property: JsonPropertyName("rubric_settings")]
|
||||
object? RubricSettings = null,
|
||||
|
||||
[JsonPropertyName("moderated_grading")]
|
||||
public bool ModeratedGrading { get; set; }
|
||||
[property: JsonPropertyName("rubric")]
|
||||
IEnumerable<RubricCriteriaModel>? Rubric = null,
|
||||
|
||||
[JsonPropertyName("grader_count")]
|
||||
public uint GraderCount { get; set; }
|
||||
[property: JsonPropertyName("assignment_visibility")]
|
||||
IEnumerable<ulong>? AssignmentVisibility = null,
|
||||
|
||||
[JsonPropertyName("final_grader_id")]
|
||||
public ulong? FinalGraderId { get; set; }
|
||||
[property: JsonPropertyName("overrides")]
|
||||
IEnumerable<AssignmentOverrideModel>? Overrides = null,
|
||||
|
||||
[JsonPropertyName("grader_comments_visible_to_graders")]
|
||||
public bool? GraderCommentsVisibleToGraders { get; set; }
|
||||
[property: JsonPropertyName("omit_from_final_grade")]
|
||||
bool? OmitFromFinalGrade = null,
|
||||
|
||||
[JsonPropertyName("graders_anonymous_to_graders")]
|
||||
public bool? GradersAnonymousToGraders { get; set; }
|
||||
[property: JsonPropertyName("final_grader_id")]
|
||||
ulong? FinalGraderId = null,
|
||||
|
||||
[JsonPropertyName("grader_names_anonymous_to_final_grader")]
|
||||
public bool? GraderNamesVisibleToFinalGrader { get; set; }
|
||||
[property: JsonPropertyName("grader_comments_visible_to_graders")]
|
||||
bool? GraderCommentsVisibleToGraders = null,
|
||||
|
||||
[JsonPropertyName("anonymous_grading")]
|
||||
public bool? AnonymousGrading { get; set; }
|
||||
[property: JsonPropertyName("graders_anonymous_to_graders")]
|
||||
bool? GradersAnonymousToGraders = null,
|
||||
|
||||
[JsonPropertyName("allowed_attempts")]
|
||||
public int AllowedAttempts { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("grader_names_anonymous_to_final_grader")]
|
||||
bool? GraderNamesVisibleToFinalGrader = null,
|
||||
|
||||
[property: JsonPropertyName("anonymous_grading")]
|
||||
bool? AnonymousGrading = null
|
||||
);
|
||||
@@ -1,42 +1,38 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class AssignmentOverrideModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
public record AssignmentOverrideModel
|
||||
(
|
||||
|
||||
[JsonPropertyName("assignment_id")]
|
||||
public ulong AssignmentId { get; set; }
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("student_ids")]
|
||||
public IEnumerable<ulong>? StudentIds { get; set; }
|
||||
[property: JsonPropertyName("assignment_id")]
|
||||
ulong AssignmentId,
|
||||
|
||||
[JsonPropertyName("group_id")]
|
||||
public ulong? GroupId { get; set; }
|
||||
[property: JsonPropertyName("course_section_ids")]
|
||||
ulong CourseSectionId,
|
||||
|
||||
[JsonPropertyName("course_section_ids")]
|
||||
public ulong CourseSectionId { get; set; }
|
||||
[property: JsonPropertyName("title")]
|
||||
string Title,
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
[property: JsonPropertyName("student_ids")]
|
||||
IEnumerable<ulong>? StudentIds = null,
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
[property: JsonPropertyName("group_id")]
|
||||
ulong? GroupId = null,
|
||||
|
||||
[JsonPropertyName("all_day")]
|
||||
public bool? AllDay { get; set; }
|
||||
[property: JsonPropertyName("due_at")]
|
||||
DateTime? DueAt = null,
|
||||
|
||||
[JsonPropertyName("all_day_date")]
|
||||
public DateTime? AllDayDate { get; set; }
|
||||
[property: JsonPropertyName("all_day")]
|
||||
bool? AllDay = null,
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
[property: JsonPropertyName("all_day_date")]
|
||||
DateTime? AllDayDate = null,
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("unlock_at")]
|
||||
DateTime? UnlockAt = null,
|
||||
|
||||
[property: JsonPropertyName("lock_at")]
|
||||
DateTime? LockAt = null
|
||||
);
|
||||
@@ -1,15 +1,13 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class ExternalToolTagAttributesModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
public record ExternalToolTagAttributesModel
|
||||
(
|
||||
[property: JsonPropertyName("url")]
|
||||
string Url,
|
||||
|
||||
[JsonPropertyName("new_tab")]
|
||||
public bool? NewTab { get; set; }
|
||||
[property: JsonPropertyName("resource_link_id")]
|
||||
string ResourceLinkId,
|
||||
|
||||
[JsonPropertyName("resource_link_id")]
|
||||
public string ResourceLinkId { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("new_tab")]
|
||||
bool? NewTab = null
|
||||
);
|
||||
@@ -1,23 +1,19 @@
|
||||
using System;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class LockInfoModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("asset_string")]
|
||||
public string AssetString { get; set; }
|
||||
public record LockInfoModel
|
||||
(
|
||||
[property: JsonPropertyName("asset_string")]
|
||||
string AssetString,
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
[property: JsonPropertyName("unlock_at")]
|
||||
DateTime? UnlockAt = null,
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
[property: JsonPropertyName("lock_at")]
|
||||
DateTime? LockAt = null,
|
||||
|
||||
[JsonPropertyName("context_module")]
|
||||
public object? ContextModule { get; set; }
|
||||
[property: JsonPropertyName("context_module")]
|
||||
object? ContextModule = null,
|
||||
|
||||
[JsonPropertyName("manually_locked")]
|
||||
public bool? ManuallyLocked { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("manually_locked")]
|
||||
bool? ManuallyLocked = null
|
||||
);
|
||||
@@ -1,12 +1,10 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class NeedsGradingCountModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("section_id")]
|
||||
public string SectionId { get; set; }
|
||||
public record NeedsGradingCountModel
|
||||
(
|
||||
[property: JsonPropertyName("section_id")]
|
||||
string SectionId,
|
||||
|
||||
[JsonPropertyName("needs_grading_count")]
|
||||
public uint NeedsGradingCount { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("needs_grading_count")]
|
||||
uint NeedsGradingCount
|
||||
);
|
||||
@@ -1,36 +1,30 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
|
||||
public class RubricCriteriaModel
|
||||
{
|
||||
public record RubricCriteriaModel
|
||||
(
|
||||
[property: JsonPropertyName("id")]
|
||||
string Id,
|
||||
|
||||
[JsonPropertyName("points")]
|
||||
public double? Points { get; set; }
|
||||
[property: JsonPropertyName("description")]
|
||||
string Description,
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
[property: JsonPropertyName("long_description")]
|
||||
string LongDescription,
|
||||
|
||||
[JsonPropertyName("learning_outcome_id")]
|
||||
public string? LearningOutcomeId { get; set; }
|
||||
[property: JsonPropertyName("points")]
|
||||
double? Points,
|
||||
[property: JsonPropertyName("learning_outcome_id")]
|
||||
string? LearningOutcomeId,
|
||||
|
||||
[JsonPropertyName("vendor_guid")]
|
||||
public string? VendorGuid { get; set; }
|
||||
[property: JsonPropertyName("vendor_guid")]
|
||||
string? VendorGuid,
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
[property: JsonPropertyName("criterion_use_range")]
|
||||
bool? CriterionUseRange = null,
|
||||
|
||||
[JsonPropertyName("long_description")]
|
||||
public string LongDescription { get; set; }
|
||||
[property: JsonPropertyName("ratings")]
|
||||
IEnumerable<RubricRatingModel>? Ratings = null,
|
||||
|
||||
[JsonPropertyName("criterion_use_range")]
|
||||
public bool? CriterionUseRange { get; set; }
|
||||
|
||||
[JsonPropertyName("ratings")]
|
||||
public IEnumerable<RubricRatingModel>? Ratings { get; set; }
|
||||
|
||||
[JsonPropertyName("ignore_for_scoring")]
|
||||
public bool? IgnoreForScoring { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("ignore_for_scoring")]
|
||||
bool? IgnoreForScoring = null
|
||||
);
|
||||
@@ -1,18 +1,16 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class RubricRatingModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("points")]
|
||||
public double Points { get; set; }
|
||||
public record RubricRatingModel
|
||||
(
|
||||
[property: JsonPropertyName("points")]
|
||||
double Points,
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
[property: JsonPropertyName("id")]
|
||||
string Id,
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
[property: JsonPropertyName("description")]
|
||||
string Description,
|
||||
|
||||
[JsonPropertyName("long_description")]
|
||||
public string LongDescription { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("long_description")]
|
||||
string LongDescription
|
||||
);
|
||||
@@ -1,30 +1,28 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Assignments;
|
||||
public class TurnitinSettingsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("originality_report_visibility")]
|
||||
public string OriginalityReportVisibility { get; set; }
|
||||
public record TurnitinSettingsModel
|
||||
(
|
||||
[property: JsonPropertyName("originality_report_visibility")]
|
||||
string OriginalityReportVisibility,
|
||||
|
||||
[JsonPropertyName("s_paper_check")]
|
||||
public bool SPaperCheck { get; set; }
|
||||
[property: JsonPropertyName("s_paper_check")]
|
||||
bool SPaperCheck,
|
||||
|
||||
[JsonPropertyName("internet_check")]
|
||||
public bool InternetCheck { get; set; }
|
||||
[property: JsonPropertyName("internet_check")]
|
||||
bool InternetCheck,
|
||||
|
||||
[JsonPropertyName("journal_check")]
|
||||
public bool JournalCheck { get; set; }
|
||||
[property: JsonPropertyName("journal_check")]
|
||||
bool JournalCheck,
|
||||
|
||||
[JsonPropertyName("exclude_biblio")]
|
||||
public bool ExcludeBiblio { get; set; }
|
||||
[property: JsonPropertyName("exclude_biblio")]
|
||||
bool ExcludeBiblio,
|
||||
|
||||
[JsonPropertyName("exclude_quoted")]
|
||||
public bool ExcludeQuoted { get; set; }
|
||||
[property: JsonPropertyName("exclude_quoted")]
|
||||
bool ExcludeQuoted,
|
||||
|
||||
[JsonPropertyName("exclude_small_matches_type")]
|
||||
public bool? ExcludeSmallMatchesType { get; set; }
|
||||
[property: JsonPropertyName("exclude_small_matches_type")]
|
||||
bool? ExcludeSmallMatchesType = null,
|
||||
|
||||
[JsonPropertyName("exclude_small_matches_value")]
|
||||
public uint? ExcludeSmallMatchesValue { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("exclude_small_matches_value")]
|
||||
uint? ExcludeSmallMatchesValue = null
|
||||
);
|
||||
@@ -1,36 +0,0 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Authentications;
|
||||
// NOTE: the api documentation for this model is incorrect
|
||||
public class AuthenticationEventModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("event_type")]
|
||||
public string EventType { get; set; }
|
||||
|
||||
[JsonPropertyName("links")]
|
||||
public AuthenticationEventLinksModel Links { get; set; }
|
||||
}
|
||||
|
||||
public struct AuthenticationEventLinksModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("login")]
|
||||
public ulong Login { get; set; }
|
||||
|
||||
[JsonPropertyName("account")]
|
||||
public ulong Account { get; set; }
|
||||
|
||||
[JsonPropertyName("user")]
|
||||
public ulong User { get; set; }
|
||||
|
||||
[JsonPropertyName("page_view")]
|
||||
public ulong? PageView { get; set; }
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Authentications;
|
||||
public struct AuthenticationEventsResponseModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("events")]
|
||||
public IEnumerable<AuthenticationEventModel> Events { get; set; }
|
||||
|
||||
}
|
||||
@@ -1,53 +0,0 @@
|
||||
namespace CanvasModel.Calendar;
|
||||
|
||||
public record AssignmentEventModel
|
||||
{
|
||||
|
||||
// // A synthetic ID for the assignment
|
||||
// "id": "assignment_987",
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
// // The title of the assignment
|
||||
// "title": "Essay",
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
// // The due_at timestamp of the assignment
|
||||
// "start_at": "2012-07-19T23:59:00-06:00",
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime StartAt { get; set; }
|
||||
// // The due_at timestamp of the assignment
|
||||
// "end_at": "2012-07-19T23:59:00-06:00",
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime EndAt { get; set; }
|
||||
// // The HTML description of the assignment
|
||||
// "description": "<b>Write an essay. Whatever you want.</b>",
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
// // the context code of the (course) calendar this assignment belongs to
|
||||
// "context_code": "course_123",
|
||||
// // Current state of the assignment ('published' or 'deleted')
|
||||
// "workflow_state": "published",
|
||||
// // URL for this assignment (note that updating/deleting should be done via the
|
||||
// // Assignments API)
|
||||
// "url": "https://example.com/api/v1/calendar_events/assignment_987",
|
||||
// // URL for a user to view this assignment
|
||||
// "html_url": "http://example.com/courses/123/assignments/987",
|
||||
// // The due date of this assignment
|
||||
// "all_day_date": "2012-07-19",
|
||||
// // Boolean indicating whether this is an all-day event (e.g. assignment due at
|
||||
// // midnight)
|
||||
// "all_day": true,
|
||||
// // When the assignment was created
|
||||
// "created_at": "2012-07-12T10:55:20-06:00",
|
||||
// // When the assignment was last updated
|
||||
// "updated_at": "2012-07-12T10:55:20-06:00",
|
||||
// // The full assignment JSON data (See the Assignments API)
|
||||
// "assignment": null,
|
||||
// // The list of AssignmentOverrides that apply to this event (See the Assignments
|
||||
// // API). This information is useful for determining which students or sections
|
||||
// // this assignment-due event applies to.
|
||||
// "assignment_overrides": null,
|
||||
// // Boolean indicating whether this has important dates.
|
||||
// "important_dates": true
|
||||
|
||||
}
|
||||
@@ -1,126 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Assignments;
|
||||
using CanvasModel.Groups;
|
||||
using CanvasModel.Users;
|
||||
|
||||
namespace CanvasModel.Calendar;
|
||||
|
||||
/*
|
||||
* This class combines the fields of normal, reservation, time-slot, and assignment calendar events.
|
||||
* Concrete structure classes will specialize to these types and inherit from a common base.
|
||||
*/
|
||||
|
||||
public record CalendarEventModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime StartAt { get; set; }
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime EndAt { get; set; }
|
||||
|
||||
[JsonPropertyName("type")]
|
||||
public string Type { get; set; }
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("location_name")]
|
||||
public string LocationName { get; set; }
|
||||
|
||||
[JsonPropertyName("location_address")]
|
||||
public string LocationAddress { get; set; }
|
||||
|
||||
[JsonPropertyName("context_code")]
|
||||
public string ContextCode { get; set; }
|
||||
|
||||
[JsonPropertyName("effective_context_code")]
|
||||
public string? EffectiveContextCode { get; set; }
|
||||
|
||||
[JsonPropertyName("all_context_codes")]
|
||||
public string AllContextCodes { get; set; } // comma separated
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden")]
|
||||
public bool Hidden { get; set; }
|
||||
|
||||
[JsonPropertyName("parent_event_id")]
|
||||
public string? ParentEventId { get; set; }
|
||||
|
||||
[JsonPropertyName("child_events_count")]
|
||||
public uint? ChildEventsCount { get; set; }
|
||||
|
||||
[JsonPropertyName("child_events")]
|
||||
public IEnumerable<CalendarEventModel>? ChildEvents { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("all_day_date")]
|
||||
public DateTime? AllDayDate { get; set; }
|
||||
|
||||
[JsonPropertyName("all_day")]
|
||||
public bool AllDay { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("appointment_group_id")]
|
||||
public ulong AppointmentGroupId { get; set; }
|
||||
|
||||
[JsonPropertyName("appointment_group_url")]
|
||||
public string AppointmentGroupUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("own_reservation")]
|
||||
public bool? OwnReservation { get; set; }
|
||||
|
||||
[JsonPropertyName("reserve_url")]
|
||||
public string? ReserveUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("reserved")]
|
||||
public bool? Reserved { get; set; }
|
||||
|
||||
[JsonPropertyName("participant_type")]
|
||||
public string ParticipantType { get; set; } // User|Group
|
||||
|
||||
[JsonPropertyName("participant_limit")]
|
||||
public uint? ParticipantLimit { get; set; }
|
||||
|
||||
[JsonPropertyName("available_slots")]
|
||||
public uint? AvailableSlots { get; set; }
|
||||
|
||||
[JsonPropertyName("user")]
|
||||
public UserModel? User { get; set; }
|
||||
|
||||
[JsonPropertyName("group")]
|
||||
public GroupModel? Group { get; set; }
|
||||
|
||||
[JsonPropertyName("assignment")]
|
||||
public AssignmentModel? Assignment { get; set; }
|
||||
|
||||
[JsonPropertyName("assignment_overrides")]
|
||||
public IEnumerable<AssignmentOverrideModel>? AssignmentOverrides { get; set; }
|
||||
|
||||
[JsonPropertyName("can_manage_appointment_group")]
|
||||
public bool? CanManageAppointmentGroup { get; set; } // undocumented
|
||||
|
||||
[JsonPropertyName("participants_per_appointment")]
|
||||
public uint? ParticipantsPerAppointment { get; set; }
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ContentShares;
|
||||
public struct ContentExportIdModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Courses;
|
||||
using CanvasModel.Users;
|
||||
|
||||
namespace CanvasModel.ContentShares;
|
||||
public class ContentShareModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("content_type")]
|
||||
public string ContentType { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong? UserId { get; set; }
|
||||
|
||||
[JsonPropertyName("sender")]
|
||||
public ShortUserModel? Sender { get; set; }
|
||||
|
||||
[JsonPropertyName("receivers")]
|
||||
public IEnumerable<ShortUserModel>? Receivers { get; set; }
|
||||
|
||||
[JsonPropertyName("source_course")]
|
||||
public ShortCourseModel? SourceCourse { get; set; }
|
||||
|
||||
[JsonPropertyName("read_state")]
|
||||
public string ReadState { get; set; }
|
||||
|
||||
[JsonPropertyName("content_export")]
|
||||
public ContentExportIdModel? ContentExport { get; set; }
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Discussions;
|
||||
using CanvasModel.Submissions;
|
||||
|
||||
namespace CanvasModel.Conversations;
|
||||
public class ConversationMessageModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("body")]
|
||||
public string Body { get; set; }
|
||||
|
||||
[JsonPropertyName("author_id")]
|
||||
public ulong AuthorId { get; set; }
|
||||
|
||||
[JsonPropertyName("generated")]
|
||||
public bool Generated { get; set; }
|
||||
|
||||
[JsonPropertyName("media_comment")]
|
||||
public MediaCommentModel? MediaComment { get; set; }
|
||||
|
||||
[JsonPropertyName("forwarded_messages")]
|
||||
public IEnumerable<ConversationMessageModel> ForwardedMessages { get; set; }
|
||||
|
||||
[JsonPropertyName("attachments")]
|
||||
public IEnumerable<FileAttachmentModel> Attachments { get; set; }
|
||||
}
|
||||
@@ -1,57 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Conversations;
|
||||
public class ConversationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("subject")]
|
||||
public string Subject { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("last_message")]
|
||||
public string LastMessage { get; set; }
|
||||
|
||||
[JsonPropertyName("last_message_at")]
|
||||
public DateTime? LastMessageAt { get; set; }
|
||||
|
||||
[JsonPropertyName("message_count")]
|
||||
public uint MessageCount { get; set; }
|
||||
|
||||
[JsonPropertyName("subscribed")]
|
||||
public bool? Subscribed { get; set; }
|
||||
|
||||
[JsonPropertyName("private")]
|
||||
public bool? Private { get; set; }
|
||||
|
||||
[JsonPropertyName("starred")]
|
||||
public bool? Starred { get; set; }
|
||||
|
||||
[JsonPropertyName("properties")]
|
||||
public IEnumerable<string>? Properties { get; set; }
|
||||
|
||||
[JsonPropertyName("audience")]
|
||||
public IEnumerable<ulong>? Audience { get; set; }
|
||||
|
||||
[JsonPropertyName("audience_contexts")]
|
||||
public Dictionary<string, Dictionary<string, IEnumerable<string>>>? AudienceContexts { get; set; }
|
||||
|
||||
[JsonPropertyName("avatar_url")]
|
||||
public string AvatarUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("participants")]
|
||||
public IEnumerable<ConversationParticipantModel>? Participants { get; set; }
|
||||
|
||||
[JsonPropertyName("visible")]
|
||||
public bool? Visible { get; set; }
|
||||
|
||||
[JsonPropertyName("context_name")]
|
||||
public string ContextName { get; set; }
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Conversations;
|
||||
public class ConversationParticipantModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("full_name")]
|
||||
public string FullName { get; set; }
|
||||
|
||||
[JsonPropertyName("avatar_url")]
|
||||
public string? AvatarUrl { get; set; }
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Conversations;
|
||||
public class DetailedConversationModel : ConversationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("messages")]
|
||||
public IEnumerable<ConversationMessageModel> Messages { get; set; }
|
||||
|
||||
}
|
||||
@@ -1,151 +1,53 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
using CanvasModel.Enrollments;
|
||||
|
||||
namespace CanvasModel.Courses;
|
||||
public class CourseModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_course_id")]
|
||||
public string SisCourseId { get; set; }
|
||||
|
||||
[JsonPropertyName("uuid")]
|
||||
public string Uuid { get; set; }
|
||||
|
||||
[JsonPropertyName("integration_id")]
|
||||
public string IntegrationId { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public ulong? SisImportId { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("course_code")]
|
||||
public string CourseCode { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("account_id")]
|
||||
public ulong AccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("root_account_id")]
|
||||
public ulong RootAccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("enrollment_term_id")]
|
||||
public ulong EnrollmentTermId { get; set; }
|
||||
|
||||
[JsonPropertyName("grading_standard_id")]
|
||||
public ulong? GradingStandardId { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime? StartAt { get; set; }
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime? EndAt { get; set; }
|
||||
|
||||
[JsonPropertyName("locale")]
|
||||
public string Locale { get; set; }
|
||||
|
||||
[JsonPropertyName("enrollments")]
|
||||
public IEnumerable<EnrollmentModel>? Enrollments { get; set; }
|
||||
|
||||
[JsonPropertyName("total_students")]
|
||||
public ulong? TotalStudents { get; set; }
|
||||
|
||||
[JsonPropertyName("calendar")]
|
||||
public CalendarLinkModel Calendar { get; set; }
|
||||
|
||||
[JsonPropertyName("default_view")]
|
||||
public string DefaultView { get; set; }
|
||||
|
||||
[JsonPropertyName("syllabus_body")]
|
||||
public string SyllabusBody { get; set; }
|
||||
|
||||
[JsonPropertyName("needs_grading_count")]
|
||||
public uint? NeedsGradingCount { get; set; }
|
||||
|
||||
[JsonPropertyName("term")]
|
||||
public TermModel? Term { get; set; }
|
||||
|
||||
[JsonPropertyName("course_progress")]
|
||||
public CourseProgressModel? CourseProgress { get; set; }
|
||||
|
||||
[JsonPropertyName("apply_assignment_group_weights")]
|
||||
public bool? ApplyAssignmentGroupWeights { get; set; }
|
||||
|
||||
[JsonPropertyName("permissions")]
|
||||
public Dictionary<string, bool> Permissions { get; set; }
|
||||
|
||||
[JsonPropertyName("is_public")]
|
||||
public bool? IsPublic { get; set; }
|
||||
|
||||
[JsonPropertyName("is_public_to_auth_users")]
|
||||
public bool? IsPublicToAuthUsers { get; set; }
|
||||
|
||||
[JsonPropertyName("public_syllabus")]
|
||||
public bool? PublicSyllabus { get; set; }
|
||||
|
||||
[JsonPropertyName("public_syllabus_to_auth")]
|
||||
public bool? PublicSyllabusToAuth { get; set; }
|
||||
|
||||
[JsonPropertyName("public_description")]
|
||||
public string? PublicDescription { get; set; }
|
||||
|
||||
[JsonPropertyName("storage_quota_mb")]
|
||||
public ulong StorageQuotaMb { get; set; }
|
||||
|
||||
[JsonPropertyName("storage_quota_used_mb")]
|
||||
public ulong StorageQuotaUsedMb { get; set; }
|
||||
|
||||
[JsonPropertyName("hide_final_grades")]
|
||||
public bool? HideFinalGrades { get; set; }
|
||||
|
||||
[JsonPropertyName("license")]
|
||||
public string License { get; set; }
|
||||
|
||||
[JsonPropertyName("allow_student_assignment_edits")]
|
||||
public bool? AllowStudentAssignmentEdits { get; set; }
|
||||
|
||||
[JsonPropertyName("allow_wiki_comments")]
|
||||
public bool? AllowWikiComments { get; set; }
|
||||
|
||||
[JsonPropertyName("allow_student_forum_attachments")]
|
||||
public bool? AllowStudentForumAttachments { get; set; }
|
||||
|
||||
[JsonPropertyName("open_enrollment")]
|
||||
public bool? OpenEnrollment { get; set; }
|
||||
|
||||
[JsonPropertyName("self_enrollment")]
|
||||
public bool? SelfEnrollment { get; set; }
|
||||
|
||||
[JsonPropertyName("restrict_enrollments_to_courses")]
|
||||
public bool? RestrictEnrollmentsToCourseDates { get; set; }
|
||||
|
||||
[JsonPropertyName("course_format")]
|
||||
public string CourseFormat { get; set; }
|
||||
|
||||
[JsonPropertyName("access_restricted_by_date")]
|
||||
public bool? AccessRestrictedByDate { get; set; }
|
||||
|
||||
[JsonPropertyName("time_zone")]
|
||||
public string TimeZone { get; set; }
|
||||
|
||||
[JsonPropertyName("blueprint")]
|
||||
public bool? Blueprint { get; set; }
|
||||
|
||||
[JsonPropertyName("blueprint_restrictions")]
|
||||
public Dictionary<string, bool>? BlueprintRestrictions { get; set; }
|
||||
|
||||
[JsonPropertyName("blueprint_restrictions_by_object_type")]
|
||||
public Dictionary<string, Dictionary<string, bool>>? BlueprintRestrictionsByObjectType { get; set; }
|
||||
}
|
||||
public record CourseModel
|
||||
(
|
||||
[property: JsonPropertyName("id")] ulong Id,
|
||||
[property: JsonPropertyName("sis_course_id")] string SisCourseId,
|
||||
[property: JsonPropertyName("uuid")] string Uuid,
|
||||
[property: JsonPropertyName("integration_id")] string IntegrationId,
|
||||
[property: JsonPropertyName("name")] string Name,
|
||||
[property: JsonPropertyName("course_code")] string CourseCode,
|
||||
[property: JsonPropertyName("workflow_state")] string WorkflowState,
|
||||
[property: JsonPropertyName("account_id")] ulong AccountId,
|
||||
[property: JsonPropertyName("root_account_id")] ulong RootAccountId,
|
||||
[property: JsonPropertyName("enrollment_term_id")] ulong EnrollmentTermId,
|
||||
[property: JsonPropertyName("created_at")] DateTime CreatedAt,
|
||||
[property: JsonPropertyName("locale")] string Locale,
|
||||
[property: JsonPropertyName("calendar")] CalendarLinkModel Calendar,
|
||||
[property: JsonPropertyName("default_view")] string DefaultView,
|
||||
[property: JsonPropertyName("syllabus_body")] string SyllabusBody,
|
||||
[property: JsonPropertyName("permissions")] Dictionary<string, bool> Permissions,
|
||||
[property: JsonPropertyName("storage_quota_mb")] ulong StorageQuotaMb,
|
||||
[property: JsonPropertyName("storage_quota_used_mb")] ulong StorageQuotaUsedMb,
|
||||
[property: JsonPropertyName("license")] string License,
|
||||
[property: JsonPropertyName("course_format")] string CourseFormat,
|
||||
[property: JsonPropertyName("time_zone")] string TimeZone,
|
||||
[property: JsonPropertyName("sis_import_id")] ulong? SisImportId = null,
|
||||
[property: JsonPropertyName("grading_standard_id")] ulong? GradingStandardId = null,
|
||||
[property: JsonPropertyName("start_at")] DateTime? StartAt = null,
|
||||
[property: JsonPropertyName("end_at")] DateTime? EndAt = null,
|
||||
[property: JsonPropertyName("enrollments")] IEnumerable<EnrollmentModel>? Enrollments = null,
|
||||
[property: JsonPropertyName("total_students")] ulong? TotalStudents = null,
|
||||
[property: JsonPropertyName("needs_grading_count")] uint? NeedsGradingCount = null,
|
||||
[property: JsonPropertyName("term")] TermModel? Term = null,
|
||||
[property: JsonPropertyName("course_progress")] CourseProgressModel? CourseProgress = null,
|
||||
[property: JsonPropertyName("apply_assignment_group_weights")] bool? ApplyAssignmentGroupWeights = null,
|
||||
[property: JsonPropertyName("is_public")] bool? Is= null,
|
||||
[property: JsonPropertyName("is_public_to_auth_users")] bool? IsPublicToAuthUsers = null,
|
||||
[property: JsonPropertyName("public_syllabus")] bool? PublicSyllabus = null,
|
||||
[property: JsonPropertyName("public_syllabus_to_auth")] bool? PublicSyllabusToAuth = null,
|
||||
[property: JsonPropertyName("public_description")] string? PublicDescription = null,
|
||||
[property: JsonPropertyName("hide_final_grades")] bool? HideFinalGrades = null,
|
||||
[property: JsonPropertyName("allow_student_assignment_edits")] bool? AllowStudentAssignmentEdits = null,
|
||||
[property: JsonPropertyName("allow_wiki_comments")] bool? AllowWikiComments = null,
|
||||
[property: JsonPropertyName("allow_student_forum_attachments")] bool? AllowStudentForumAttachments = null,
|
||||
[property: JsonPropertyName("open_enrollment")] bool? OpenEnrollment = null,
|
||||
[property: JsonPropertyName("self_enrollment")] bool? SelfEnrollment = null,
|
||||
[property: JsonPropertyName("restrict_enrollments_to_courses")] bool? RestrictEnrollmentsToCourseDates = null,
|
||||
[property: JsonPropertyName("access_restricted_by_date")] bool? AccessRestrictedByDate = null,
|
||||
[property: JsonPropertyName("blueprint")] bool? Blueprint = null,
|
||||
[property: JsonPropertyName("blueprint_restrictions")] Dictionary<string, bool>? BlueprintRestrictions = null,
|
||||
[property: JsonPropertyName("blueprint_restrictions_by_object_type")] Dictionary<string, Dictionary<string, bool>>? BlueprintRestrictionsByObjectType = null
|
||||
);
|
||||
@@ -1,20 +1,16 @@
|
||||
using System;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Courses;
|
||||
public class CourseProgressModel
|
||||
{
|
||||
public record CourseProgressModel
|
||||
(
|
||||
[property: JsonPropertyName("requirement_count")]
|
||||
uint? RequirementCount = null,
|
||||
|
||||
[property: JsonPropertyName("requirement_completed_count")]
|
||||
uint? RequirementCompletedCount = null,
|
||||
|
||||
[JsonPropertyName("requirement_count")]
|
||||
public uint? RequirementCount { get; set; }
|
||||
[property: JsonPropertyName("next_requirement_url")]
|
||||
string? NextRequirementUrl = null,
|
||||
|
||||
[JsonPropertyName("requirement_completed_count")]
|
||||
public uint? RequirementCompletedCount { get; set; }
|
||||
|
||||
[JsonPropertyName("next_requirement_url")]
|
||||
public string? NextRequirementUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("completed_at")]
|
||||
public DateTime? CompletedAt { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("completed_at")]
|
||||
DateTime? CompletedAt = null
|
||||
);
|
||||
@@ -1,48 +1,46 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Courses;
|
||||
public class CourseSettingsModel
|
||||
{
|
||||
public record CourseSettingsModel
|
||||
(
|
||||
|
||||
[JsonPropertyName("allow_final_grade_override")]
|
||||
public bool AllowFinalGradeOverride { get; set; }
|
||||
[property: JsonPropertyName("allow_final_grade_override")]
|
||||
bool AllowFinalGradeOverride,
|
||||
|
||||
[JsonPropertyName("allow_student_discussion_topics")]
|
||||
public bool AllowStudentDiscussionTopics { get; set; }
|
||||
[property: JsonPropertyName("allow_student_discussion_topics")]
|
||||
bool AllowStudentDiscussionTopics,
|
||||
|
||||
[JsonPropertyName("allow_student_forum_attachments")]
|
||||
public bool AllowStudentForumAttachments { get; set; }
|
||||
[property: JsonPropertyName("allow_student_forum_attachments")]
|
||||
bool AllowStudentForumAttachments,
|
||||
|
||||
[JsonPropertyName("allow_student_discussion_editing")]
|
||||
public bool AllowStudentDiscussionEditing { get; set; }
|
||||
[property: JsonPropertyName("allow_student_discussion_editing")]
|
||||
bool AllowStudentDiscussionEditing,
|
||||
|
||||
[JsonPropertyName("grading_standard_enabled")]
|
||||
public bool GradingStandardEnabled { get; set; }
|
||||
[property: JsonPropertyName("grading_standard_enabled")]
|
||||
bool GradingStandardEnabled,
|
||||
|
||||
[JsonPropertyName("grading_standard_id")]
|
||||
public ulong? GradingStandardId { get; set; }
|
||||
[property: JsonPropertyName("allow_student_organized_groups")]
|
||||
bool AllowStudentOrganizedGroups,
|
||||
|
||||
[JsonPropertyName("allow_student_organized_groups")]
|
||||
public bool AllowStudentOrganizedGroups { get; set; }
|
||||
[property: JsonPropertyName("hide_final_groups")]
|
||||
bool HideFinalGrades,
|
||||
|
||||
[JsonPropertyName("hide_final_groups")]
|
||||
public bool HideFinalGrades { get; set; }
|
||||
[property: JsonPropertyName("hide_distributor_graphs")]
|
||||
bool HideDistributionGraphs,
|
||||
|
||||
[JsonPropertyName("hide_distributor_graphs")]
|
||||
public bool HideDistributionGraphs { get; set; }
|
||||
[property: JsonPropertyName("lock_all_announcements")]
|
||||
bool LockAllAnnouncements,
|
||||
|
||||
[JsonPropertyName("lock_all_announcements")]
|
||||
public bool LockAllAnnouncements { get; set; }
|
||||
[property: JsonPropertyName("restrict_student_past_view")]
|
||||
bool RestrictStudentPastView,
|
||||
|
||||
[JsonPropertyName("restrict_student_past_view")]
|
||||
public bool RestrictStudentPastView { get; set; }
|
||||
[property: JsonPropertyName("restrict_student_future_view")]
|
||||
bool RestrictStudentFutureView,
|
||||
|
||||
[JsonPropertyName("restrict_student_future_view")]
|
||||
public bool RestrictStudentFutureView { get; set; }
|
||||
[property: JsonPropertyName("show_announcements_on_home_page")]
|
||||
bool ShowAnnouncementsOnHomePage,
|
||||
|
||||
[JsonPropertyName("show_announcements_on_home_page")]
|
||||
public bool ShowAnnouncementsOnHomePage { get; set; }
|
||||
[property: JsonPropertyName("home_page_announcements_limit")]
|
||||
long HomePageAnnouncementLimit,
|
||||
|
||||
[JsonPropertyName("home_page_announcements_limit")]
|
||||
public long HomePageAnnouncementLimit { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("grading_standard_id")]
|
||||
ulong? GradingStandardId = null
|
||||
);
|
||||
|
||||
@@ -1,12 +1,6 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Courses;
|
||||
public class ShortCourseModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
}
|
||||
public record ShortCourseModel
|
||||
(
|
||||
[property: JsonPropertyName("id")] ulong Id,
|
||||
[property: JsonPropertyName("name")] string Name
|
||||
);
|
||||
|
||||
@@ -3,6 +3,6 @@ public record TermModel
|
||||
(
|
||||
[property: JsonPropertyName("id")] ulong Id,
|
||||
[property: JsonPropertyName("name")] string Name,
|
||||
[property: JsonPropertyName("start_at")] DateTime? StartAt,
|
||||
[property: JsonPropertyName("end_at")] DateTime? EndAt
|
||||
[property: JsonPropertyName("start_at")] DateTime? StartAt = null,
|
||||
[property: JsonPropertyName("end_at")] DateTime? EndAt = null
|
||||
);
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.CustomGradebookColumns;
|
||||
public struct ColumnDatumModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("content")]
|
||||
public string Content { get; set; }
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong UserId { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.CustomGradebookColumns;
|
||||
public class CustomColumnModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("teacher_notes")]
|
||||
public bool? TeacherNotes { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("position")]
|
||||
public int? Position { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden")]
|
||||
public bool? Hidden { get; set; }
|
||||
|
||||
[JsonPropertyName("read_only")]
|
||||
public bool? ReadOnly { get; set; }
|
||||
}
|
||||
@@ -1,115 +1,111 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using CanvasModel.Users;
|
||||
|
||||
|
||||
namespace CanvasModel.Discussions;
|
||||
public class DiscussionTopicModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
public record DiscussionTopicModel
|
||||
(
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
[property: JsonPropertyName("title")]
|
||||
string Title,
|
||||
|
||||
[JsonPropertyName("message")]
|
||||
public string Message { get; set; }
|
||||
[property: JsonPropertyName("message")]
|
||||
string Message,
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
[property: JsonPropertyName("html_url")]
|
||||
string HtmlUrl,
|
||||
|
||||
[JsonPropertyName("posted_at")]
|
||||
public DateTime? PostedAt { get; set; }
|
||||
[property: JsonPropertyName("read_state")]
|
||||
string ReadState,
|
||||
|
||||
[JsonPropertyName("last_reply_at")]
|
||||
public DateTime? LastReplyAt { get; set; }
|
||||
[property: JsonPropertyName("subscription_hold")]
|
||||
string SubscriptionHold,
|
||||
|
||||
[JsonPropertyName("require_initial_post")]
|
||||
public bool? RequireInitialPost { get; set; }
|
||||
[property: JsonPropertyName("assignment_id")]
|
||||
int AssignmentId,
|
||||
|
||||
[JsonPropertyName("user_can_see_posts")]
|
||||
public bool? UserCanSeePosts { get; set; }
|
||||
[property: JsonPropertyName("lock_explanation")]
|
||||
string LockExplanation,
|
||||
|
||||
[JsonPropertyName("discussion_subentry_count")]
|
||||
public uint? DiscussionSubentryCount { get; set; }
|
||||
[property: JsonPropertyName("user_name")]
|
||||
string UserName,
|
||||
|
||||
[JsonPropertyName("read_state")]
|
||||
public string ReadState { get; set; }
|
||||
[property: JsonPropertyName("topic_children")]
|
||||
IEnumerable<uint> TopicChildren,
|
||||
|
||||
[JsonPropertyName("unread_count")]
|
||||
public uint? UnreadCount { get; set; }
|
||||
[property: JsonPropertyName("podcast_url")]
|
||||
string PodcastUrl,
|
||||
|
||||
[JsonPropertyName("subscribed")]
|
||||
public bool? Subscribed { get; set; }
|
||||
[property: JsonPropertyName("discussion_type")]
|
||||
string DiscussionType,
|
||||
|
||||
[JsonPropertyName("subscription_hold")]
|
||||
public string SubscriptionHold { get; set; }
|
||||
[property: JsonPropertyName("attachments")]
|
||||
IEnumerable<FileAttachmentModel> Attachments,
|
||||
|
||||
[JsonPropertyName("assignment_id")]
|
||||
public int AssignmentId { get; set; }
|
||||
[property: JsonPropertyName("permissions")]
|
||||
Dictionary<string, bool> Permissions,
|
||||
|
||||
[JsonPropertyName("delayed_post_at")]
|
||||
public DateTime? DelayedPostAt { get; set; }
|
||||
[property: JsonPropertyName("author")]
|
||||
UserDisplayModel Author,
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool? Published { get; set; }
|
||||
[property: JsonPropertyName("unread_count")]
|
||||
uint? UnreadCount = null,
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
[property: JsonPropertyName("subscribed")]
|
||||
bool? Subscribed = null,
|
||||
|
||||
[JsonPropertyName("locked")]
|
||||
public bool? Locked { get; set; }
|
||||
[property: JsonPropertyName("posted_at")]
|
||||
DateTime? PostedAt = null,
|
||||
|
||||
[JsonPropertyName("pinned")]
|
||||
public bool? Pinned { get; set; }
|
||||
[property: JsonPropertyName("last_reply_at")]
|
||||
DateTime? LastReplyAt = null,
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool? LockedForUser { get; set; }
|
||||
[property: JsonPropertyName("require_initial_post")]
|
||||
bool? RequireInitialPost = null,
|
||||
|
||||
[JsonPropertyName("lock_info")]
|
||||
public object LockInfo { get; set; }
|
||||
[property: JsonPropertyName("user_can_see_posts")]
|
||||
bool? UserCanSeePosts = null,
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string LockExplanation { get; set; }
|
||||
[property: JsonPropertyName("discussion_subentry_count")]
|
||||
uint? DiscussionSubentryCount = null,
|
||||
|
||||
[JsonPropertyName("user_name")]
|
||||
public string UserName { get; set; }
|
||||
[property: JsonPropertyName("delayed_post_at")]
|
||||
DateTime? DelayedPostAt = null,
|
||||
|
||||
[JsonPropertyName("topic_children")]
|
||||
public IEnumerable<uint> TopicChildren { get; set; }
|
||||
[property: JsonPropertyName("published")]
|
||||
bool? Published = null,
|
||||
|
||||
[JsonPropertyName("group_topic_children")]
|
||||
public object GroupTopicChildren { get; set; }
|
||||
[property: JsonPropertyName("lock_at")]
|
||||
DateTime? LockAt = null,
|
||||
|
||||
[JsonPropertyName("root_topic_id")]
|
||||
public ulong? RootTopicId { get; set; }
|
||||
[property: JsonPropertyName("locked")]
|
||||
bool? Locked = null,
|
||||
|
||||
[JsonPropertyName("podcast_url")]
|
||||
public string PodcastUrl { get; set; }
|
||||
[property: JsonPropertyName("pinned")]
|
||||
bool? Pinned = null,
|
||||
|
||||
[JsonPropertyName("discussion_type")]
|
||||
public string DiscussionType { get; set; }
|
||||
[property: JsonPropertyName("locked_for_user")]
|
||||
bool? LockedForUser = null,
|
||||
|
||||
[JsonPropertyName("group_category_id")]
|
||||
public ulong? GroupCategoryId { get; set; }
|
||||
[property: JsonPropertyName("lock_info")]
|
||||
object? LockInfo = null,
|
||||
|
||||
[JsonPropertyName("attachments")]
|
||||
public IEnumerable<FileAttachmentModel> Attachments { get; set; }
|
||||
[property: JsonPropertyName("group_topic_children")]
|
||||
object? GroupTopicChildren = null,
|
||||
|
||||
[JsonPropertyName("permissions")]
|
||||
public Dictionary<string, bool> Permissions { get; set; }
|
||||
[property: JsonPropertyName("root_topic_id")]
|
||||
ulong? RootTopicId = null,
|
||||
|
||||
[JsonPropertyName("allow_rating")]
|
||||
public bool? AllowRating { get; set; }
|
||||
[property: JsonPropertyName("group_category_id")]
|
||||
ulong? GroupCategoryId = null,
|
||||
|
||||
[JsonPropertyName("only_graders_can_rate")]
|
||||
public bool? OnlyGradersCanRate { get; set; }
|
||||
[property: JsonPropertyName("allow_rating")]
|
||||
bool? AllowRating = null,
|
||||
|
||||
[JsonPropertyName("sort_by_rating")]
|
||||
public bool? SortByRating { get; set; }
|
||||
[property: JsonPropertyName("only_graders_can_rate")]
|
||||
bool? OnlyGradersCanRate = null,
|
||||
|
||||
[JsonPropertyName("author")]
|
||||
public UserDisplayModel Author { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("sort_by_rating")]
|
||||
bool? SortByRating = null
|
||||
);
|
||||
@@ -1,21 +1,16 @@
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Discussions;
|
||||
public class FileAttachmentModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("content_type")]
|
||||
public string ContentType { get; set; }
|
||||
public record FileAttachmentModel
|
||||
(
|
||||
[property: JsonPropertyName("content_type")]
|
||||
string ContentType,
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
[property: JsonPropertyName("url")]
|
||||
string Url,
|
||||
|
||||
[JsonPropertyName("filename")]
|
||||
public string Filename { get; set; }
|
||||
[property: JsonPropertyName("filename")]
|
||||
string Filename,
|
||||
|
||||
[JsonPropertyName("display_name")]
|
||||
public string DisplayName { get; set; }
|
||||
|
||||
|
||||
}
|
||||
[property: JsonPropertyName("display_name")]
|
||||
string DisplayName
|
||||
);
|
||||
@@ -1,48 +1,40 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Discussions;
|
||||
public class TopicEntryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
public record TopicEntryModel
|
||||
(
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong UserId { get; set; }
|
||||
[property: JsonPropertyName("user_id")]
|
||||
ulong UserId,
|
||||
|
||||
[JsonPropertyName("editor_id")]
|
||||
public ulong? EditorId { get; set; }
|
||||
[property: JsonPropertyName("user_name")]
|
||||
string UserName,
|
||||
|
||||
[JsonPropertyName("user_name")]
|
||||
public string UserName { get; set; }
|
||||
[property: JsonPropertyName("message")]
|
||||
string Message,
|
||||
|
||||
[JsonPropertyName("message")]
|
||||
public string Message { get; set; }
|
||||
[property: JsonPropertyName("read_state")]
|
||||
string ReadState,
|
||||
|
||||
[JsonPropertyName("read_state")]
|
||||
public string ReadState { get; set; }
|
||||
[property: JsonPropertyName("forced_read_state")]
|
||||
bool ForcedReadState,
|
||||
|
||||
[JsonPropertyName("forced_read_state")]
|
||||
public bool ForcedReadState { get; set; }
|
||||
[property: JsonPropertyName("created_at")]
|
||||
DateTime CreatedAt,
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
[property: JsonPropertyName("editor_id")]
|
||||
ulong? EditorId = null,
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
[property: JsonPropertyName("updated_at")]
|
||||
DateTime? UpdatedAt = null,
|
||||
|
||||
[JsonPropertyName("attachment")]
|
||||
public FileAttachmentModel? Attachment { get; set; }
|
||||
[property: JsonPropertyName("attachment")]
|
||||
FileAttachmentModel? Attachment = null,
|
||||
|
||||
[JsonPropertyName("recent_replies")]
|
||||
public IEnumerable<TopicReplyModel>? RecentReplies { get; set; }
|
||||
[property: JsonPropertyName("recent_replies")]
|
||||
IEnumerable<TopicReplyModel>? RecentReplies = null,
|
||||
|
||||
[JsonPropertyName("has_more_replies")]
|
||||
public bool? HasMoreReplies { get; set; }
|
||||
|
||||
|
||||
}
|
||||
[property: JsonPropertyName("has_more_replies")]
|
||||
bool? HasMoreReplies = null
|
||||
);
|
||||
@@ -1,34 +1,28 @@
|
||||
using System;
|
||||
|
||||
|
||||
|
||||
namespace CanvasModel.Discussions;
|
||||
public class TopicReplyModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
public record TopicReplyModel
|
||||
(
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong UserId { get; set; }
|
||||
[property: JsonPropertyName("user_id")]
|
||||
ulong UserId,
|
||||
|
||||
[JsonPropertyName("editor_id")]
|
||||
public ulong? EditorId { get; set; }
|
||||
[property: JsonPropertyName("user_name")]
|
||||
string UserName,
|
||||
|
||||
[JsonPropertyName("user_name")]
|
||||
public string UserName { get; set; }
|
||||
[property: JsonPropertyName("message")]
|
||||
string Message,
|
||||
|
||||
[JsonPropertyName("message")]
|
||||
public string Message { get; set; }
|
||||
[property: JsonPropertyName("read_state")]
|
||||
string ReadState,
|
||||
|
||||
[JsonPropertyName("read_state")]
|
||||
public string ReadState { get; set; }
|
||||
[property: JsonPropertyName("created_at")]
|
||||
DateTime CreatedAt,
|
||||
|
||||
[JsonPropertyName("forced_read_state")]
|
||||
public bool? ForcedReadState { get; set; }
|
||||
[property: JsonPropertyName("editor_id")]
|
||||
ulong? EditorId = null,
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
|
||||
}
|
||||
[property: JsonPropertyName("forced_read_state")]
|
||||
bool? ForcedReadState = null
|
||||
);
|
||||
@@ -1,6 +1,6 @@
|
||||
namespace CanvasModel.EnrollmentTerms;
|
||||
|
||||
public record EnrollmentTermModel
|
||||
record EnrollmentTermModel
|
||||
(
|
||||
[property: JsonPropertyName("id")] ulong Id,
|
||||
[property: JsonPropertyName("name")] string Name,
|
||||
@@ -14,7 +14,7 @@ public record EnrollmentTermModel
|
||||
Dictionary<string, EnrollmentTermDateOverrideModel>? Overrides = null
|
||||
);
|
||||
|
||||
public record EnrollmentTermDateOverrideModel
|
||||
record EnrollmentTermDateOverrideModel
|
||||
(
|
||||
[property: JsonPropertyName("start_at")] DateTime? StartAt = null,
|
||||
[property: JsonPropertyName("end_at")] DateTime? EndAt = null
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
|
||||
namespace CanvasModel.EnrollmentTerms;
|
||||
public record RedundantEnrollmentTermsResponse
|
||||
record RedundantEnrollmentTermsResponse
|
||||
(
|
||||
[property: JsonPropertyName("enrollment_terms")]
|
||||
IEnumerable<EnrollmentTermModel> EnrollmentTerms
|
||||
|
||||
@@ -1,135 +1,135 @@
|
||||
using CanvasModel.Users;
|
||||
|
||||
namespace CanvasModel.Enrollments;
|
||||
public class EnrollmentModel
|
||||
{
|
||||
public record EnrollmentModel
|
||||
(
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
[property: JsonPropertyName("id")]
|
||||
ulong Id,
|
||||
|
||||
[JsonPropertyName("course_id")]
|
||||
public ulong CourseId { get; set; }
|
||||
[property: JsonPropertyName("course_id")]
|
||||
ulong CourseId,
|
||||
|
||||
[JsonPropertyName("sis_course_id")]
|
||||
public string? SisCourseId { get; set; }
|
||||
[property: JsonPropertyName("enrollment_state")]
|
||||
string EnrollmentState,
|
||||
|
||||
[JsonPropertyName("course_integration_id")]
|
||||
public string? CourseIntegrationId { get; set; }
|
||||
[property: JsonPropertyName("type")]
|
||||
string Type,
|
||||
|
||||
[JsonPropertyName("course_section_id")]
|
||||
public ulong? CourseSectionId { get; set; }
|
||||
[property: JsonPropertyName("user_id")]
|
||||
ulong UserId,
|
||||
|
||||
[JsonPropertyName("section_integration_id")]
|
||||
public string? SectionIntegrationId { get; set; }
|
||||
[property: JsonPropertyName("role")]
|
||||
string Role,
|
||||
|
||||
[JsonPropertyName("sis_account_id")]
|
||||
public string? SisAccountId { get; set; }
|
||||
[property: JsonPropertyName("role_id")]
|
||||
ulong RoleId,
|
||||
|
||||
[JsonPropertyName("sis_section_id")]
|
||||
public string? SisSectionId { get; set; }
|
||||
[property: JsonPropertyName("html_url")]
|
||||
string HtmlUrl,
|
||||
|
||||
[JsonPropertyName("sis_user_id")]
|
||||
public string? SisUserId { get; set; }
|
||||
[property: JsonPropertyName("grades")]
|
||||
GradeModel Grades,
|
||||
|
||||
[JsonPropertyName("enrollment_state")]
|
||||
public string EnrollmentState { get; set; }
|
||||
[property: JsonPropertyName("user")]
|
||||
UserDisplayModel User,
|
||||
|
||||
[JsonPropertyName("limit_privileges_to_course_section")]
|
||||
public bool? LimitPrivilegesToCourseSection { get; set; }
|
||||
[property: JsonPropertyName("override_grade")]
|
||||
string OverrideGrade,
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public ulong? SisImportId { get; set; }
|
||||
[property: JsonPropertyName("sis_course_id")]
|
||||
string? SisCourseId = null,
|
||||
|
||||
[JsonPropertyName("root_account_id")]
|
||||
public ulong? RootAccountId { get; set; }
|
||||
[property: JsonPropertyName("course_integration_id")]
|
||||
string? CourseIntegrationId = null,
|
||||
|
||||
[JsonPropertyName("type")]
|
||||
public string Type { get; set; }
|
||||
[property: JsonPropertyName("course_section_id")]
|
||||
ulong? CourseSectionId = null,
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong UserId { get; set; }
|
||||
[property: JsonPropertyName("section_integration_id")]
|
||||
string? SectionIntegrationId = null,
|
||||
|
||||
[JsonPropertyName("associated_user_id")]
|
||||
public ulong? AssociatedUserId { get; set; }
|
||||
[property: JsonPropertyName("sis_account_id")]
|
||||
string? SisAccountId = null,
|
||||
|
||||
[JsonPropertyName("role")]
|
||||
public string Role { get; set; }
|
||||
[property: JsonPropertyName("sis_section_id")]
|
||||
string? SisSectionId = null,
|
||||
|
||||
[JsonPropertyName("role_id")]
|
||||
public ulong RoleId { get; set; }
|
||||
[property: JsonPropertyName("sis_user_id")]
|
||||
string? SisUserId = null,
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime? CreatedAt { get; set; }
|
||||
[property: JsonPropertyName("limit_privileges_to_course_section")]
|
||||
bool? LimitPrivilegesToCourseSection = null,
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
[property: JsonPropertyName("sis_import_id")]
|
||||
ulong? SisImportId = null,
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime? StartAt { get; set; }
|
||||
[property: JsonPropertyName("root_account_id")]
|
||||
ulong? RootAccountId = null,
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime? EndAt { get; set; }
|
||||
[property: JsonPropertyName("associated_user_id")]
|
||||
ulong? AssociatedUserId = null,
|
||||
|
||||
[JsonPropertyName("last_activity_at")]
|
||||
public DateTime? LastActivityAt { get; set; }
|
||||
[property: JsonPropertyName("created_at")]
|
||||
DateTime? CreatedAt = null,
|
||||
|
||||
[JsonPropertyName("last_attended_at")]
|
||||
public DateTime? LastAttendedAt { get; set; }
|
||||
[property: JsonPropertyName("updated_at")]
|
||||
DateTime? UpdatedAt = null,
|
||||
|
||||
[JsonPropertyName("total_activity_time")]
|
||||
public ulong? TotalActivityTime { get; set; }
|
||||
[property: JsonPropertyName("start_at")]
|
||||
DateTime? StartAt = null,
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
[property: JsonPropertyName("end_at")]
|
||||
DateTime? EndAt = null,
|
||||
|
||||
[JsonPropertyName("grades")]
|
||||
public GradeModel Grades { get; set; }
|
||||
[property: JsonPropertyName("last_activity_at")]
|
||||
DateTime? LastActivityAt = null,
|
||||
|
||||
[JsonPropertyName("user")]
|
||||
public UserDisplayModel User { get; set; }
|
||||
[property: JsonPropertyName("last_attended_at")]
|
||||
DateTime? LastAttendedAt = null,
|
||||
|
||||
[JsonPropertyName("override_grade")]
|
||||
public string OverrideGrade { get; set; }
|
||||
[property: JsonPropertyName("total_activity_time")]
|
||||
ulong? TotalActivityTime = null,
|
||||
|
||||
[JsonPropertyName("override_score")]
|
||||
public decimal? OverrideScore { get; set; }
|
||||
[property: JsonPropertyName("override_score")]
|
||||
decimal? OverrideScore = null,
|
||||
|
||||
[JsonPropertyName("unposted_current_grade")]
|
||||
public string? UnpostedCurrentGrade { get; set; }
|
||||
[property: JsonPropertyName("unposted_current_grade")]
|
||||
string? UnpostedCurrentGrade = null,
|
||||
|
||||
[JsonPropertyName("unposted_final_grade")]
|
||||
public string? UnpostedFinalGrade { get; set; }
|
||||
[property: JsonPropertyName("unposted_final_grade")]
|
||||
string? UnpostedFinalGrade = null,
|
||||
|
||||
[JsonPropertyName("unposted_current_score")]
|
||||
public string? UnpostedCurrentScore { get; set; }
|
||||
[property: JsonPropertyName("unposted_current_score")]
|
||||
string? UnpostedCurrentScore = null,
|
||||
|
||||
[JsonPropertyName("unposted_final_score")]
|
||||
public string? UnpostedFinalScore { get; set; }
|
||||
[property: JsonPropertyName("unposted_final_score")]
|
||||
string? UnpostedFinalScore = null,
|
||||
|
||||
[JsonPropertyName("has_grading_periods")]
|
||||
public bool? HasGradingPeriods { get; set; }
|
||||
[property: JsonPropertyName("has_grading_periods")]
|
||||
bool? HasGradingPeriods = null,
|
||||
|
||||
[JsonPropertyName("totals_for_all_grading_periods_option")]
|
||||
public bool? TotalsForAllGradingPeriodsOption { get; set; }
|
||||
[property: JsonPropertyName("totals_for_all_grading_periods_option")]
|
||||
bool? TotalsForAllGradingPeriodsOption = null,
|
||||
|
||||
[JsonPropertyName("current_grading_period_title")]
|
||||
public string? CurrentGradingPeriodTitle { get; set; }
|
||||
[property: JsonPropertyName("current_grading_period_title")]
|
||||
string? CurrentGradingPeriodTitle = null,
|
||||
|
||||
[JsonPropertyName("current_grading_period_id")]
|
||||
public ulong? CurrentGradingPeriodId { get; set; }
|
||||
[property: JsonPropertyName("current_grading_period_id")]
|
||||
ulong? CurrentGradingPeriodId = null,
|
||||
|
||||
[JsonPropertyName("current_period_override_grade")]
|
||||
public string? CurrentPeriodOverrideGrade { get; set; }
|
||||
[property: JsonPropertyName("current_period_override_grade")]
|
||||
string? CurrentPeriodOverrideGrade = null,
|
||||
|
||||
[JsonPropertyName("current_period_override_score")]
|
||||
public decimal? CurrentPeriodOverrideScore { get; set; }
|
||||
[property: JsonPropertyName("current_period_override_score")]
|
||||
decimal? CurrentPeriodOverrideScore = null,
|
||||
|
||||
[JsonPropertyName("current_period_unposted_final_score")]
|
||||
public decimal? CurrentPeriodUnpostedFinalScore { get; set; }
|
||||
[property: JsonPropertyName("current_period_unposted_final_score")]
|
||||
decimal? CurrentPeriodUnpostedFinalScore = null,
|
||||
|
||||
[JsonPropertyName("current_period_unposted_current_grade")]
|
||||
public string? CurrentPeriodUnpostedCurrentGrade { get; set; }
|
||||
[property: JsonPropertyName("current_period_unposted_current_grade")]
|
||||
string? CurrentPeriodUnpostedCurrentGrade = null,
|
||||
|
||||
[JsonPropertyName("current_period_unposted_final_grade")]
|
||||
public string? CurrentPeriodUnpostedFinalGrade { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("current_period_unposted_final_grade")]
|
||||
string? CurrentPeriodUnpostedFinalGrade = null
|
||||
);
|
||||
@@ -2,33 +2,32 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Enrollments;
|
||||
public class GradeModel
|
||||
{
|
||||
public record GradeModel
|
||||
(
|
||||
[property: JsonPropertyName("html_url")]
|
||||
string? HtmlUrl = null,
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string? HtmlUrl { get; set; }
|
||||
[property: JsonPropertyName("current_grade")]
|
||||
string? CurrentGrade = null,
|
||||
|
||||
[JsonPropertyName("current_grade")]
|
||||
public string? CurrentGrade { get; set; }
|
||||
[property: JsonPropertyName("final_grade")]
|
||||
string? FinalGrade = null,
|
||||
|
||||
[JsonPropertyName("final_grade")]
|
||||
public string? FinalGrade { get; set; }
|
||||
[property: JsonPropertyName("current_score")]
|
||||
string? CurrentScore = null,
|
||||
|
||||
[JsonPropertyName("current_score")]
|
||||
public string? CurrentScore { get; set; }
|
||||
[property: JsonPropertyName("final_score")]
|
||||
string? FinalScore = null,
|
||||
|
||||
[JsonPropertyName("final_score")]
|
||||
public string? FinalScore { get; set; }
|
||||
[property: JsonPropertyName("unposted_current_grade")]
|
||||
string? UnpostedCurrentGrade = null,
|
||||
|
||||
[JsonPropertyName("unposted_current_grade")]
|
||||
public string? UnpostedCurrentGrade { get; set; }
|
||||
[property: JsonPropertyName("unposted_final_grade")]
|
||||
string? UnpostedFinalGrade = null,
|
||||
|
||||
[JsonPropertyName("unposted_final_grade")]
|
||||
public string? UnpostedFinalGrade { get; set; }
|
||||
[property: JsonPropertyName("unposted_current_score")]
|
||||
string? UnpostedCurrentScore = null,
|
||||
|
||||
[JsonPropertyName("unposted_current_score")]
|
||||
public string? UnpostedCurrentScore { get; set; }
|
||||
|
||||
[JsonPropertyName("unposted_final_score")]
|
||||
public string? UnpostedFinalScore { get; set; }
|
||||
}
|
||||
[property: JsonPropertyName("unposted_final_score")]
|
||||
string? UnpostedFinalScore = null
|
||||
);
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class AccountNavigationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_width")]
|
||||
public uint? SelectionWidth { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_height")]
|
||||
public uint? SelectionHeight { get; set; }
|
||||
|
||||
[JsonPropertyName("display_type")]
|
||||
public string DisplayType { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class CourseHomeSubNavigationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("icon_url")]
|
||||
public string IconUrl { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class CourseNavigationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("visible")]
|
||||
public string Visibility { get; set; }
|
||||
|
||||
[JsonPropertyName("window_target")]
|
||||
public string WindowTarget { get; set; }
|
||||
|
||||
[JsonPropertyName("default")]
|
||||
public bool? Default { get; set; }
|
||||
|
||||
[JsonPropertyName("display_type")]
|
||||
public string DisplayType { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class EditorButtonModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("icon_url")]
|
||||
public string IconUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_width")]
|
||||
public uint? SelectionWidth { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_height")]
|
||||
public uint? SelectionHeight { get; set; }
|
||||
|
||||
[JsonPropertyName("message_type")]
|
||||
public string MessageType { get; set; }
|
||||
}
|
||||
@@ -1,74 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class ExternalToolModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("domain")]
|
||||
public string Domain { get; set; }
|
||||
|
||||
[JsonPropertyName("consumer_key")]
|
||||
public string ConsumerKey { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime? CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("privacy_level")]
|
||||
public string PrivacyLevel { get; set; }
|
||||
|
||||
[JsonPropertyName("custom_fields")]
|
||||
public Dictionary<string, string> CustomFields { get; set; }
|
||||
|
||||
[JsonPropertyName("account_navigation")]
|
||||
public AccountNavigationModel AccountNavigation { get; set; }
|
||||
|
||||
[JsonPropertyName("course_home_sub_navigation")]
|
||||
public CourseHomeSubNavigationModel CourseHomeSubNavigation { get; set; }
|
||||
|
||||
[JsonPropertyName("course_navigation")]
|
||||
public CourseNavigationModel CourseNavigation { get; set; }
|
||||
|
||||
[JsonPropertyName("editor_button")]
|
||||
public EditorButtonModel EditorButton { get; set; }
|
||||
|
||||
[JsonPropertyName("homework_submission")]
|
||||
public HomeworkSubmissionModel HomeworkSubmission { get; set; }
|
||||
|
||||
[JsonPropertyName("migration_selection")]
|
||||
public MigrationSelectionModel MigrationSelection { get; set; }
|
||||
|
||||
[JsonPropertyName("resource_selection")]
|
||||
public ResourceSelectionModel ResourceSelection { get; set; }
|
||||
|
||||
[JsonPropertyName("tool_configuration")]
|
||||
public ToolConfigurationModel ToolConfiguration { get; set; }
|
||||
|
||||
[JsonPropertyName("user_navigation")]
|
||||
public UserNavigationModel UserNavigation { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_width")]
|
||||
public uint? SelectionWidth { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_height")]
|
||||
public uint? SelectionHeight { get; set; }
|
||||
|
||||
[JsonPropertyName("icon_url")]
|
||||
public string IconUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("not_selectable")]
|
||||
public bool? NotSelectable { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class HomeworkSubmissionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("message_type")]
|
||||
public string MessageType { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class LinkSelectionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("message_type")]
|
||||
public string MessageType { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class MigrationSelectionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("message_type")]
|
||||
public string MessageType { get; set; }
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class ResourceSelectionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("icon_url")]
|
||||
public string IconUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_width")]
|
||||
public uint? SelectionWidth { get; set; }
|
||||
|
||||
[JsonPropertyName("selection_height")]
|
||||
public uint? SelectionHeight { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class ToolConfigurationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("message_type")]
|
||||
public string MessageType { get; set; }
|
||||
|
||||
[JsonPropertyName("prefer_sis_email")]
|
||||
public bool? PreferSisEmail { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ExternalTools;
|
||||
public class UserNavigationModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool? Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("text")]
|
||||
public string Text { get; set; }
|
||||
|
||||
[JsonPropertyName("visibility")]
|
||||
public string Visibility { get; set; }
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Files;
|
||||
public class CanvasFileModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("uuid")]
|
||||
public string Uuid { get; set; }
|
||||
|
||||
[JsonPropertyName("folder_id")]
|
||||
public ulong FolderId { get; set; }
|
||||
|
||||
[JsonPropertyName("display_name")]
|
||||
public string DisplayName { get; set; }
|
||||
|
||||
[JsonPropertyName("filename")]
|
||||
public string Filename { get; set; }
|
||||
|
||||
[JsonPropertyName("content_type")]
|
||||
public string ContentType { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("size")]
|
||||
public ulong Size { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime? CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime? UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("locked")]
|
||||
public bool Locked { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden")]
|
||||
public bool Hidden { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden_for_user")]
|
||||
public bool HiddenForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("thumbnail_url")]
|
||||
public string ThumbnailUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("modified_at")]
|
||||
public DateTime? ModifiedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("mime_class")]
|
||||
public string MimeClass { get; set; }
|
||||
|
||||
[JsonPropertyName("media_entry_id")]
|
||||
public string MediaEntryId { get; set; }
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool LockedForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_info")]
|
||||
// public LockInfo? LockInfo { get; set; }
|
||||
public object? LockInfo { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string LockExplanation { get; set; }
|
||||
|
||||
[JsonPropertyName("preview_url")]
|
||||
public string PreviewUrl { get; set; }
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
using System;
|
||||
|
||||
|
||||
namespace CanvasModel.Files;
|
||||
public class FolderModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("context_type")]
|
||||
public string ContextType { get; set; }
|
||||
|
||||
[JsonPropertyName("context_id")]
|
||||
public ulong ContextId { get; set; }
|
||||
|
||||
[JsonPropertyName("files_count")]
|
||||
public uint FilesCount { get; set; }
|
||||
|
||||
[JsonPropertyName("position")]
|
||||
public int? Position { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("folders_url")]
|
||||
public string FoldersUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("files_url")]
|
||||
public string FilesUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("full_name")]
|
||||
public string FullName { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("folders_count")]
|
||||
public uint FoldersCount { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("parents_folder_id")]
|
||||
public ulong? ParentFolderId { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden")]
|
||||
public bool? Hidden { get; set; }
|
||||
|
||||
[JsonPropertyName("hidden_for_user")]
|
||||
public bool? HiddenForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("locker")]
|
||||
public bool? Locked { get; set; }
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool? LockedForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("for_submissions")]
|
||||
public bool? ForSubmissions { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Files;
|
||||
public class LicenseModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
||||
namespace CanvasModel.Files;
|
||||
public class UsageRightsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("legal_copyright")]
|
||||
public string LegalCopyright { get; set; }
|
||||
|
||||
[JsonPropertyName("use_justification")]
|
||||
public string UsageJustification { get; set; }
|
||||
|
||||
[JsonPropertyName("license")]
|
||||
public string License { get; set; }
|
||||
|
||||
[JsonPropertyName("license_name")]
|
||||
public string LicenseName { get; set; }
|
||||
|
||||
[JsonPropertyName("message")]
|
||||
public string Message { get; set; }
|
||||
|
||||
[JsonPropertyName("file_ids")]
|
||||
public IEnumerable<ulong> FileIds { get; set; }
|
||||
}
|
||||
@@ -1,20 +0,0 @@
|
||||
|
||||
namespace CanvasModel.GradeChangelog;
|
||||
public class GradeChangeEventLinksModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("assignment")]
|
||||
public ulong Assignment { get; set; }
|
||||
|
||||
[JsonPropertyName("course")]
|
||||
public ulong Course { get; set; }
|
||||
|
||||
[JsonPropertyName("student")]
|
||||
public ulong Student { get; set; }
|
||||
|
||||
[JsonPropertyName("grader")]
|
||||
public ulong Grader { get; set; }
|
||||
|
||||
[JsonPropertyName("page_view")]
|
||||
public string? PageView { get; set; }
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
|
||||
namespace CanvasModel.GradeChangelog;
|
||||
public class GradeChangeEventModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("event_type")]
|
||||
public string EventType { get; set; }
|
||||
|
||||
[JsonPropertyName("excused_after")]
|
||||
public bool ExcusedAfter { get; set; }
|
||||
|
||||
[JsonPropertyName("excused_before")]
|
||||
public bool ExcusedBefore { get; set; }
|
||||
|
||||
[JsonPropertyName("grade_after")]
|
||||
public string GradeAfter { get; set; }
|
||||
|
||||
[JsonPropertyName("grade_before")]
|
||||
public string GradeBefore { get; set; }
|
||||
|
||||
[JsonPropertyName("graded_anonymously")]
|
||||
public bool? GradedAnonymously { get; set; }
|
||||
|
||||
[JsonPropertyName("version_number")]
|
||||
public string VersionNumber { get; set; }
|
||||
|
||||
[JsonPropertyName("request_id")]
|
||||
public string RequestId { get; set; }
|
||||
|
||||
[JsonPropertyName("links")]
|
||||
public GradeChangeEventLinksModel? Links { get; set; }
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
|
||||
namespace CanvasModel.GradeChangelog;
|
||||
public class RedundantGradeChangeEventResponse
|
||||
{
|
||||
|
||||
[JsonPropertyName("events")]
|
||||
public IEnumerable<GradeChangeEventModel> Events { get; set; }
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Gradebook;
|
||||
public class DayModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("date")]
|
||||
public DateTime Date { get; set; }
|
||||
|
||||
[JsonPropertyName("graders")]
|
||||
public IEnumerable<GraderModel> Graders { get; set; }
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
|
||||
using CanvasModel.Assignments;
|
||||
|
||||
namespace CanvasModel.Gradebook;
|
||||
public class GraderModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
// the docs say this is a list of integers, but it isn't.
|
||||
[JsonPropertyName("assignments")]
|
||||
public IEnumerable<AssignmentModel> Assignments { get; set; }
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Gradebook;
|
||||
public class SubmissionHistoryModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("submission_id")]
|
||||
public ulong SubmissionId { get; set; }
|
||||
|
||||
[JsonPropertyName("versions")]
|
||||
public IEnumerable<SubmissionVersionModel>? Versions { get; set; }
|
||||
}
|
||||
@@ -1,36 +0,0 @@
|
||||
using CanvasModel.Submissions;
|
||||
|
||||
namespace CanvasModel.Gradebook;
|
||||
public class SubmissionVersionModel : SubmissionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("assignment_name")]
|
||||
public string AssignmentName { get; set; }
|
||||
|
||||
[JsonPropertyName("current_grade")]
|
||||
public string CurrentGrade { get; set; }
|
||||
|
||||
[JsonPropertyName("current_graded_at")]
|
||||
public DateTime? CurrentGradedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("current_grader")]
|
||||
public string CurrentGrader { get; set; }
|
||||
|
||||
[JsonPropertyName("new_grade")]
|
||||
public string NewGrade { get; set; }
|
||||
|
||||
[JsonPropertyName("new_graded_at")]
|
||||
public DateTime? NewGradedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("new_grader")]
|
||||
public string NewGrader { get; set; }
|
||||
|
||||
[JsonPropertyName("previous_grade")]
|
||||
public string PreviousGrade { get; set; }
|
||||
|
||||
[JsonPropertyName("previous_graded_at")]
|
||||
public DateTime? PreviousGradedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("previous_grader")]
|
||||
public string PreviousGrader { get; set; }
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
|
||||
namespace CanvasModel.GradingPeriods;
|
||||
public class GradingPeriodModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("start_date")]
|
||||
public DateTime? StartDate { get; set; }
|
||||
|
||||
[JsonPropertyName("end_date")]
|
||||
public DateTime? EndDate { get; set; }
|
||||
|
||||
[JsonPropertyName("close_date")]
|
||||
public DateTime? CloseDate { get; set; }
|
||||
|
||||
[JsonPropertyName("weight")]
|
||||
public double? Weight { get; set; }
|
||||
|
||||
[JsonPropertyName("is_closed")]
|
||||
public bool? IsClosed { get; set; }
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.GradingPeriods;
|
||||
public class RedundantGradingPeriodResponse
|
||||
{
|
||||
[JsonPropertyName("grading_periods")]
|
||||
public IEnumerable<GradingPeriodModel> GradingPeriods { get; set; }
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Groups;
|
||||
public class GroupMembershipModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("group_id")]
|
||||
public ulong GroupId { get; set; }
|
||||
|
||||
[JsonPropertyName("user_id")]
|
||||
public ulong UserId { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("moderator")]
|
||||
public bool Moderator { get; set; }
|
||||
|
||||
[JsonPropertyName("just_created")]
|
||||
public bool? JustCreated { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public ulong? SisImportId { get; set; }
|
||||
}
|
||||
@@ -1,56 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Groups;
|
||||
public class GroupModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string? Description { get; set; }
|
||||
|
||||
[JsonPropertyName("is_public")]
|
||||
public bool? IsPublic { get; set; }
|
||||
|
||||
[JsonPropertyName("followed_by_user")]
|
||||
public bool FollowedByUser { get; set; }
|
||||
|
||||
[JsonPropertyName("join_level")]
|
||||
public string JoinLevel { get; set; }
|
||||
|
||||
[JsonPropertyName("members_count")]
|
||||
public uint MembersCount { get; set; }
|
||||
|
||||
[JsonPropertyName("avatar_url")]
|
||||
public string AvatarUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("context_type")]
|
||||
public string ContextType { get; set; }
|
||||
|
||||
[JsonPropertyName("course_id")]
|
||||
public ulong? CourseId { get; set; }
|
||||
|
||||
[JsonPropertyName("account_id")]
|
||||
public ulong? AccountId { get; set; }
|
||||
|
||||
[JsonPropertyName("role")]
|
||||
public string Role { get; set; }
|
||||
|
||||
[JsonPropertyName("group_category_id")]
|
||||
public ulong GroupCategoryId { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_group_id")]
|
||||
public string? SisGroupId { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public ulong? SisImportId { get; set; }
|
||||
|
||||
[JsonPropertyName("storage_quota_mb")]
|
||||
public uint StorageQuoteMb { get; set; }
|
||||
|
||||
[JsonPropertyName("permissions")]
|
||||
public Dictionary<string, bool> Permissions { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class CompletionRequirementModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("type")]
|
||||
public string Type { get; set; }
|
||||
|
||||
[JsonPropertyName("min_score")]
|
||||
public double? MinScore { get; set; }
|
||||
|
||||
[JsonPropertyName("completed")]
|
||||
public bool? Completed { get; set; }
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class ContentDetailsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("points_possible")]
|
||||
public uint? PointsPossible { get; set; }
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool? LockedForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string? LockExplanation { get; set; }
|
||||
}
|
||||
@@ -1,48 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class ModuleItemModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("module_id")]
|
||||
public ulong ModuleId { get; set; }
|
||||
|
||||
[JsonPropertyName("position")]
|
||||
public uint Position { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("indent")]
|
||||
public uint? Indent { get; set; }
|
||||
|
||||
[JsonPropertyName("type")]
|
||||
public string Type { get; set; }
|
||||
|
||||
[JsonPropertyName("content_id")]
|
||||
public ulong? ContentId { get; set; }
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string? Url { get; set; }
|
||||
|
||||
[JsonPropertyName("page_url")]
|
||||
public string? PageUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("external_url")]
|
||||
public string? ExternalUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("new_tab")]
|
||||
public bool NewTab { get; set; }
|
||||
|
||||
// [OptIn]
|
||||
[JsonPropertyName("completion_requirement")]
|
||||
public CompletionRequirementModel? CompletionRequirement { get; set; }
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool? Published { get; set; }
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class ModuleItemSequenceModel
|
||||
{
|
||||
[JsonPropertyName("items")]
|
||||
public IEnumerable<ModuleItemSequenceNodeModel> Items { get; set; }
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class ModuleItemSequenceNodeModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("prev")]
|
||||
public ModuleItemModel? Prev { get; set; }
|
||||
|
||||
[JsonPropertyName("current")]
|
||||
public ModuleItemModel Current { get; set; }
|
||||
|
||||
[JsonPropertyName("next")]
|
||||
public ModuleItemModel? Next { get; set; }
|
||||
|
||||
[JsonPropertyName("mastery_path")]
|
||||
public object? MasteryPath { get; set; } // todo concrete type?
|
||||
}
|
||||
@@ -1,50 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Modules;
|
||||
public class ModuleModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("position")]
|
||||
public uint Position { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("require_sequential_progress")]
|
||||
public bool? RequireSequentialProgress { get; set; }
|
||||
|
||||
[JsonPropertyName("prerequisite_module_ids")]
|
||||
public IEnumerable<ulong>? PrerequisiteModuleIds { get; set; }
|
||||
|
||||
[JsonPropertyName("items_count")]
|
||||
public uint ItemsCount { get; set; }
|
||||
|
||||
[JsonPropertyName("items_url")]
|
||||
public string ItemsUrl { get; set; }
|
||||
|
||||
// [OptIn]
|
||||
// [Enigmatic] // can be null if "the module is deemed too large", even if opted-in
|
||||
[JsonPropertyName("items")]
|
||||
public IEnumerable<ModuleItemModel>? Items { get; set; }
|
||||
|
||||
[JsonPropertyName("state")]
|
||||
public string? State { get; set; } // todo make sure this is an enum in Structure class
|
||||
|
||||
// [OptIn]
|
||||
[JsonPropertyName("completed_at")]
|
||||
public DateTime? CompletedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("publish_final_grade")]
|
||||
public bool? PublishFinalGrade { get; set; }
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool? Published { get; set; }
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeAlignmentModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string? HtmlUrl { get; set; }
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public struct OutcomePathModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("parts")]
|
||||
public IEnumerable<OutcomePathPartModel>? Parts { get; set; }
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public struct OutcomePathPartModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeResultModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("score")]
|
||||
public double Score { get; set; }
|
||||
|
||||
[JsonPropertyName("submitted_or_assessed_at")]
|
||||
public DateTime SubmittedOrAssessedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("links")]
|
||||
public Dictionary<string, object> Links { get; set; } // todo
|
||||
|
||||
[JsonPropertyName("percent")]
|
||||
public decimal Percent { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeRollupLinksModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("course")]
|
||||
public ulong? Course { get; set; }
|
||||
|
||||
[JsonPropertyName("user")]
|
||||
public ulong? User { get; set; }
|
||||
|
||||
[JsonPropertyName("section")]
|
||||
public ulong? Section { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeRollupModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("scores")]
|
||||
public IEnumerable<OutcomeRollupScoreModel>? Scores { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("links")]
|
||||
public OutcomeRollupLinksModel Links { get; set; }
|
||||
}
|
||||
@@ -1,9 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeRollupScoreLinksModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("outcome")]
|
||||
public ulong Outcome { get; set; }
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.OutcomeResults;
|
||||
public class OutcomeRollupScoreModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("score")]
|
||||
public double? Score { get; set; }
|
||||
|
||||
[JsonPropertyName("count")]
|
||||
public uint? Count { get; set; }
|
||||
|
||||
[JsonPropertyName("links")]
|
||||
public OutcomeRollupScoreLinksModel Links { get; set; }
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
using CanvasModel.Assignments;
|
||||
using CanvasModel.Users;
|
||||
|
||||
namespace CanvasModel.Pages;
|
||||
public class PageModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string Url { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("editing_roles")]
|
||||
public string EditingRoles { get; set; }
|
||||
|
||||
[JsonPropertyName("last_edited_by")]
|
||||
public UserDisplayModel LastEditedBy { get; set; }
|
||||
|
||||
[JsonPropertyName("body")]
|
||||
public string? Body { get; set; }
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool Published { get; set; }
|
||||
|
||||
[JsonPropertyName("front_page")]
|
||||
public bool FrontPage { get; set; }
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool LockedForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_info")]
|
||||
public LockInfoModel? LockInfo { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string? LockExplanation { get; set; }
|
||||
|
||||
[JsonPropertyName("page_id")]
|
||||
public string PageId { get; set; }
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
using CanvasModel.Users;
|
||||
|
||||
namespace CanvasModel.Pages;
|
||||
public class PageRevisionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("revision_id")]
|
||||
public ulong RevisionId { get; set; }
|
||||
|
||||
[JsonPropertyName("updated_at")]
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("latest")]
|
||||
public bool Latest { get; set; }
|
||||
|
||||
[JsonPropertyName("edited_by")]
|
||||
public UserDisplayModel? EditedBy { get; set; }
|
||||
|
||||
[JsonPropertyName("url")]
|
||||
public string? Url { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string? Title { get; set; }
|
||||
|
||||
[JsonPropertyName("body")]
|
||||
public string? Body { get; set; }
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
|
||||
namespace CanvasModel.ProficiencyRatings;
|
||||
public struct ProficiencyModel
|
||||
{
|
||||
[JsonPropertyName("ratings")]
|
||||
public IEnumerable<ProficiencyRatingModel> Ratings { get; set; }
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.ProficiencyRatings;
|
||||
public class ProficiencyRatingModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("points")]
|
||||
public double Points { get; set; }
|
||||
|
||||
[JsonPropertyName("mastery")]
|
||||
public bool Mastery { get; set; }
|
||||
|
||||
[JsonPropertyName("color")]
|
||||
public string Color { get; set; }
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
|
||||
using CanvasModel.Assignments;
|
||||
|
||||
namespace CanvasModel.Quizzes;
|
||||
public class QuizModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("html_url")]
|
||||
public string HtmlUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("mobile_url")]
|
||||
public string MobileUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("preview_url")]
|
||||
public string PreviewUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("quiz_type")]
|
||||
public string QuizType { get; set; }
|
||||
|
||||
[JsonPropertyName("assignment_group_id")]
|
||||
public ulong AssignmentGroupId { get; set; }
|
||||
|
||||
[JsonPropertyName("time_limit")]
|
||||
public decimal? TimeLimit { get; set; }
|
||||
|
||||
[JsonPropertyName("shuffle_answers")]
|
||||
public bool? ShuffleAnswers { get; set; }
|
||||
|
||||
[JsonPropertyName("hide_results")]
|
||||
public string? HideResults { get; set; }
|
||||
|
||||
[JsonPropertyName("show_correct_answers")]
|
||||
public bool? ShowCorrectAnswers { get; set; }
|
||||
|
||||
[JsonPropertyName("show_correct_answers_last_attempt")]
|
||||
public bool? ShowCorrectAnswersLastAttempt { get; set; }
|
||||
|
||||
[JsonPropertyName("show_correct_answers_at")]
|
||||
public DateTime? ShowCorrectAnswersAt { get; set; }
|
||||
|
||||
[JsonPropertyName("hide_correct_answers_at")]
|
||||
public DateTime? HideCorrectAnswersAt { get; set; }
|
||||
|
||||
[JsonPropertyName("one_time_results")]
|
||||
public bool? OneTimeResults { get; set; }
|
||||
|
||||
[JsonPropertyName("scoring_policy")]
|
||||
public string? ScoringPolicy { get; set; }
|
||||
|
||||
[JsonPropertyName("allowed_attempts")]
|
||||
public int AllowedAttempts { get; set; }
|
||||
|
||||
[JsonPropertyName("one_question_at_a_time")]
|
||||
public bool? OneQuestionAtATime { get; set; }
|
||||
|
||||
[JsonPropertyName("question_count")]
|
||||
public uint? QuestionCount { get; set; }
|
||||
|
||||
[JsonPropertyName("points_possible")]
|
||||
public decimal? PointsPossible { get; set; }
|
||||
|
||||
[JsonPropertyName("cant_go_back")]
|
||||
public bool? CantGoBack { get; set; }
|
||||
|
||||
[JsonPropertyName("access_code")]
|
||||
public string? AccessCode { get; set; }
|
||||
|
||||
[JsonPropertyName("ip_filter")]
|
||||
public string? IpFilter { get; set; }
|
||||
|
||||
[JsonPropertyName("due_at")]
|
||||
public DateTime? DueAt { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_at")]
|
||||
public DateTime? LockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("unlock_at")]
|
||||
public DateTime? UnlockAt { get; set; }
|
||||
|
||||
[JsonPropertyName("published")]
|
||||
public bool? Published { get; set; }
|
||||
|
||||
[JsonPropertyName("unpublishable")]
|
||||
public bool? Unpublishable { get; set; }
|
||||
|
||||
[JsonPropertyName("locked_for_user")]
|
||||
public bool? LockedForUser { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_info")]
|
||||
public LockInfoModel? LockInfo { get; set; }
|
||||
|
||||
[JsonPropertyName("lock_explanation")]
|
||||
public string? LockExplanation { get; set; }
|
||||
|
||||
[JsonPropertyName("speedgrader_url")]
|
||||
public string? SpeedGraderUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("quiz_extensions_url")]
|
||||
public string QuizExtensionsUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("permissions")]
|
||||
public QuizPermissionsModel Permissions { get; set; }
|
||||
|
||||
[JsonPropertyName("all_dates")]
|
||||
public object AllDates { get; set; } // exact type unspecified by canvas & no example value given
|
||||
|
||||
[JsonPropertyName("version_number")]
|
||||
public uint? VersionNumber { get; set; }
|
||||
|
||||
[JsonPropertyName("question_types")]
|
||||
public IEnumerable<string> QuestionTypes { get; set; }
|
||||
|
||||
[JsonPropertyName("anonymous_submissions")]
|
||||
public bool? AnonymousSubmissions { get; set; }
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Quizzes;
|
||||
public class QuizPermissionsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("read")]
|
||||
public bool Read { get; set; }
|
||||
|
||||
[JsonPropertyName("submit")]
|
||||
public bool Submit { get; set; }
|
||||
|
||||
[JsonPropertyName("create")]
|
||||
public bool Create { get; set; }
|
||||
|
||||
[JsonPropertyName("manage")]
|
||||
public bool Manage { get; set; }
|
||||
|
||||
[JsonPropertyName("read_statistics")]
|
||||
public bool ReadStatistics { get; set; }
|
||||
|
||||
[JsonPropertyName("review_grades")]
|
||||
public bool ReviewGrades { get; set; }
|
||||
|
||||
[JsonPropertyName("update")]
|
||||
public bool Update { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Reports;
|
||||
public class ReportDescriptionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("report")]
|
||||
public string Report { get; set; }
|
||||
|
||||
[JsonPropertyName("title")]
|
||||
public string Title { get; set; }
|
||||
|
||||
[JsonPropertyName("parameters")]
|
||||
public Dictionary<string, ReportParameterDescriptionModel>? Parameters { get; set; }
|
||||
}
|
||||
|
||||
public class ReportParameterDescriptionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("description")]
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonPropertyName("required")]
|
||||
public bool Required { get; set; }
|
||||
}
|
||||
@@ -1,42 +0,0 @@
|
||||
|
||||
using CanvasModel.Discussions;
|
||||
|
||||
namespace CanvasModel.Reports;
|
||||
public class ReportModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("report")]
|
||||
public string Report { get; set; }
|
||||
|
||||
[JsonPropertyName("file_url")]
|
||||
public string? FileUrl { get; set; }
|
||||
|
||||
[JsonPropertyName("attachment")]
|
||||
public FileAttachmentModel? Attachment { get; set; }
|
||||
|
||||
[JsonPropertyName("status")]
|
||||
public string Status { get; set; }
|
||||
|
||||
[JsonPropertyName("created_at")]
|
||||
public DateTime? CreatedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("started_at")]
|
||||
public DateTime? StartedAt { get; set; }
|
||||
|
||||
[JsonPropertyName("ended_at")]
|
||||
public DateTime? EndedAt { get; set; }
|
||||
|
||||
// the fields in this object can vary wildly depending on the report type, so for now we will loosely type it
|
||||
// like this
|
||||
[JsonPropertyName("parameters")]
|
||||
public Dictionary<string, object> Parameters { get; set; }
|
||||
|
||||
[JsonPropertyName("progress")]
|
||||
public double? Progress { get; set; }
|
||||
|
||||
[JsonPropertyName("current_line")]
|
||||
public ulong? CurrentLine { get; set; }
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Results;
|
||||
public class ResultModel
|
||||
{
|
||||
// yes indeed the docs say this model specifically uses camelCase properties
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonPropertyName("userId")]
|
||||
public string UserId { get; set; }
|
||||
|
||||
[JsonPropertyName("resultScore")]
|
||||
public string ResultScore { get; set; }
|
||||
|
||||
[JsonPropertyName("resultMaximum")]
|
||||
public string ResultMaximum { get; set; }
|
||||
|
||||
[JsonPropertyName("comment")]
|
||||
public string Comment { get; set; }
|
||||
|
||||
[JsonPropertyName("scoreOf")]
|
||||
public string ScoreOf { get; set; }
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
|
||||
using CanvasModel.Accounts;
|
||||
|
||||
namespace CanvasModel.Roles;
|
||||
public class RoleModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("label")]
|
||||
public string Label { get; set; }
|
||||
|
||||
[JsonPropertyName("base_role_type")]
|
||||
public string BaseRoleType { get; set; }
|
||||
|
||||
[JsonPropertyName("account")]
|
||||
public AccountModel Account { get; set; }
|
||||
|
||||
[JsonPropertyName("workflow_state")]
|
||||
public string WorkflowState { get; set; }
|
||||
|
||||
[JsonPropertyName("permissions")]
|
||||
public Dictionary<string, RolePermissionsModel> Permissions { get; set; }
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
|
||||
|
||||
namespace CanvasModel.Roles;
|
||||
public class RolePermissionsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("enabled")]
|
||||
public bool Enabled { get; set; }
|
||||
|
||||
[JsonPropertyName("locked")]
|
||||
public bool Locked { get; set; }
|
||||
|
||||
[JsonPropertyName("applies_to_self")]
|
||||
public bool AppliesToSelf { get; set; }
|
||||
|
||||
[JsonPropertyName("applies_to_descendants")]
|
||||
public bool AppliesToDescendants { get; set; }
|
||||
|
||||
[JsonPropertyName("readonly")]
|
||||
public bool Readonly { get; set; }
|
||||
|
||||
[JsonPropertyName("explicit")]
|
||||
public bool Explicit { get; set; }
|
||||
|
||||
[JsonPropertyName("prior_default")]
|
||||
public bool PriorDefault { get; set; }
|
||||
}
|
||||
@@ -1,36 +0,0 @@
|
||||
|
||||
namespace CanvasModel.Sections;
|
||||
public class SectionModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("id")]
|
||||
public ulong Id { get; set; }
|
||||
|
||||
[JsonPropertyName("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_section_id")]
|
||||
public string? SisSectionId { get; set; }
|
||||
|
||||
[JsonPropertyName("integration_id")]
|
||||
public string? IntegrationId { get; set; }
|
||||
|
||||
[JsonPropertyName("sis_import_id")]
|
||||
public ulong? SisImportId { get; set; }
|
||||
|
||||
[JsonPropertyName("start_at")]
|
||||
public DateTime? StartAt { get; set; }
|
||||
|
||||
[JsonPropertyName("end_at")]
|
||||
public DateTime? EndAt { get; set; }
|
||||
|
||||
[JsonPropertyName("restrict_enrollments_to_section_dates")]
|
||||
public bool? RestrictEnrollmentsToSectionDates { get; set; }
|
||||
|
||||
[JsonPropertyName("nonxlist_course_id")]
|
||||
public ulong? NonCrossListedCourseId { get; set; }
|
||||
|
||||
[JsonPropertyName("total_students")]
|
||||
// [OptIn]
|
||||
public uint? TotalStudents { get; set; }
|
||||
}
|
||||
@@ -1,55 +0,0 @@
|
||||
|
||||
namespace CanvasModel.SisImports;
|
||||
public class SisImportCountsModel
|
||||
{
|
||||
|
||||
[JsonPropertyName("accounts")]
|
||||
public ulong Accounts { get; set; }
|
||||
|
||||
[JsonPropertyName("terms")]
|
||||
public ulong Terms { get; set; }
|
||||
|
||||
[JsonPropertyName("abstract_courses")]
|
||||
public ulong AbstractCourses { get; set; }
|
||||
|
||||
[JsonPropertyName("courses")]
|
||||
public ulong Courses { get; set; }
|
||||
|
||||
[JsonPropertyName("sections")]
|
||||
public ulong Sections { get; set; }
|
||||
|
||||
[JsonPropertyName("xlists")]
|
||||
public ulong CrossLists { get; set; }
|
||||
|
||||
[JsonPropertyName("users")]
|
||||
public ulong Users { get; set; }
|
||||
|
||||
[JsonPropertyName("enrollments")]
|
||||
public ulong Enrollments { get; set; }
|
||||
|
||||
[JsonPropertyName("groups")]
|
||||
public ulong Groups { get; set; }
|
||||
|
||||
[JsonPropertyName("group_memberships")]
|
||||
public ulong GroupMemberships { get; set; }
|
||||
|
||||
[JsonPropertyName("grade_publishing_results")]
|
||||
public ulong GradePublishingResults { get; set; }
|
||||
|
||||
// the following three specific fields are null when 0, unlike the other ones which are 0 when 0
|
||||
|
||||
[JsonPropertyName("batch_courses_deleted")]
|
||||
public ulong? BatchCoursesDeleted { get; set; }
|
||||
|
||||
[JsonPropertyName("batch_sections_deleted")]
|
||||
public ulong? BatchSectionsDeleted { get; set; }
|
||||
|
||||
[JsonPropertyName("batch_enrollments_deleted")]
|
||||
public ulong? BatchEnrollmentsDeleted { get; set; }
|
||||
|
||||
[JsonPropertyName("error_count")]
|
||||
public ulong Errors { get; set; }
|
||||
|
||||
[JsonPropertyName("warning_count")]
|
||||
public ulong Warnings { get; set; }
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user