Skip to content

Commit

Permalink
Merge pull request #13 from byu-oit/patch-api-type
Browse files Browse the repository at this point in the history
Patch api type
  • Loading branch information
stuft2 authored Aug 23, 2021
2 parents 135e0e9 + 56cede6 commit 1b07735
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 28 deletions.
4 changes: 2 additions & 2 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ export namespace UAPI {

export type PropertyDictionary = Record<string, Property<any> | ComplexProperty<any>>

export type ApiType = 'readonly' | 'modifiable' | 'system' | 'derived' | 'unauthorized' | 'related'
export type ApiType = 'read-only' | 'modifiable' | 'system' | 'derived' | 'unauthorized' | 'related'

export type ObjectApiType = 'readonly' | 'related'
export type ObjectApiType = 'read-only' | 'related'

export type Value<T extends Scalar.Type> = {
value: T | null
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@byu-oit/uapi-ts",
"version": "2.3.2",
"version": "2.3.3",
"description": "TypeScript definitions of UAPI elements",
"main": "index.d.ts",
"files": [
Expand Down
50 changes: 25 additions & 25 deletions test/students-v3-api.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,59 +91,59 @@ export namespace StudentsV3API {
},
byu_id: {
value: '123456789',
api_type: 'readonly',
api_type: 'read-only',
key: true,
description: 'LastName, FirstName'
},
year_term: {
value: '20185',
api_type: 'readonly',
api_type: 'read-only',
key: true,
description: 'Fall 2018',
long_description: 'Fall Semester 2018'
},
curriculum_id: {
value: '10314',
api_type: 'readonly',
api_type: 'read-only',
key: true
},
title_code: {
value: '000',
api_type: 'readonly',
api_type: 'read-only',
key: true
},
teaching_area: {
value: 'C S',
api_type: 'readonly',
api_type: 'read-only',
description: 'Computer Science'
},
course_number: {
value: '301R',
api_type: 'readonly'
api_type: 'read-only'
},
section_number: {
value: '003',
api_type: 'readonly',
api_type: 'read-only',
key: true
},
term_code: {
value: 'S',
api_type: 'readonly',
api_type: 'read-only',
description: 'Semester Long'
},
class_provider: {
value: 'DAY',
domain: 'https://api.byu.edu/byuapi/meta/registration/class_providers',
api_type: 'readonly'
api_type: 'read-only'
},
instruction_mode: {
value: null,
api_type: 'readonly',
api_type: 'read-only',
description: null
},
percent_classroom_time: {
value: null,
api_type: 'readonly'
api_type: 'read-only'
},
course_title: {
value: 'Topics in Computer Science',
Expand All @@ -152,11 +152,11 @@ export namespace StudentsV3API {
},
credit_hours: {
value: '3.0',
api_type: 'readonly'
api_type: 'read-only'
},
end_date: {
value: '2018-12-13',
api_type: 'readonly'
api_type: 'read-only'
},
final_exam_schedule: {
object: {
Expand Down Expand Up @@ -200,15 +200,15 @@ export namespace StudentsV3API {
related_resource: 'https://api.byu.edu/byuapi/classes/v2/Fall2018,C%20S,301R,003/assigned_schedules/FINAL%20EXAM,1'
}
},
api_type: 'readonly'
api_type: 'read-only'
},
help_section: {
value: false,
api_type: 'readonly'
api_type: 'read-only'
},
honors_section: {
value: false,
api_type: 'readonly'
api_type: 'read-only'
},
instructors: {
object_array: [
Expand All @@ -221,7 +221,7 @@ export namespace StudentsV3API {
},
instructor_type: {
value: 'PRIMARY',
api_type: 'readonly',
api_type: 'read-only',
description: 'Primary Instructor'
}
},
Expand All @@ -234,33 +234,33 @@ export namespace StudentsV3API {
},
instructor_type: {
value: 'TEACHING ASSISTANT',
api_type: 'readonly',
api_type: 'read-only',
description: 'Teaching Assistant'
}
}
],
api_type: 'readonly'
api_type: 'read-only'
},
lab_section: {
value: false,
api_type: 'readonly'
api_type: 'read-only'
},
lms_name: {
value: 'Learning Suite',
domain: 'https://api.byu.edu/byuapi/meta/registration/lms_names',
api_type: 'readonly'
api_type: 'read-only'
},
online_section: {
value: false,
api_type: 'readonly'
api_type: 'read-only'
},
position_in_queue: {
value: 1,
api_type: 'system'
},
quiz_section: {
value: false,
api_type: 'readonly'
api_type: 'read-only'
},
reason_skipped: {
value: 'Adding ACC 402 will exceed the maximum of 18.0 credit hours allowed for this semester',
Expand All @@ -277,7 +277,7 @@ export namespace StudentsV3API {
},
start_date: {
value: '2018-09-04',
api_type: 'readonly'
api_type: 'read-only'
},
when_taught: {
object_array: [
Expand Down Expand Up @@ -364,7 +364,7 @@ export namespace StudentsV3API {
}
}
],
api_type: 'readonly'
api_type: 'read-only'
}
}
]
Expand Down

0 comments on commit 1b07735

Please sign in to comment.