Access Keys:
Skip to content (Access Key - 0)

MIT Subject Management API

Please note that this page and related pages are being developed as part of the CIM Courses Project and are subject to change.

This page is intended to specify the needs and validations of the mit-subjects API. This API is the single gateway to create and edit MIT subjects and was developed as part of the CIM Courses Project.

# Data Element Grouping Required Validation Notes    
  Subject Code Subject Yes Must be a valid value in STVSUBJ -    
  Subject Number Subject Yes Must be in regular expression format:
[A-Z0-9][A-Z0-9][A-Z0-9][A-Z0-9]
[A-Z0-9][A-Z0-9][A-Z0-9][A-Z0-9]
Must be alphanumeric, 1 to 3 or 4 characters.  3 if subj_code is 3 characters otherwise 4.
Expects uppercase values and numbers    
  Subject Key
(Subject Code + Number)
Subject N/A -Must be no more than 6 characters
-Checks if identical Subject Key exists in table 
SUBJ_TMPL_REG_INSTANCE
Listed as separate data element for validation purposes only
#work - impacted by (de/re)activation?
   
  Subject Type Subject Yes Must be in approved list of values List of values listed in Business Rules KB article    
  Effective From Term Subject Yes -Must be a valid term in SGBGP_TERM
-Must be less than or equal to the Effective Thru Term
-Must not overlap with other records in SUBJECT_TEMPLATE
-    
  Effective Thru Term Subject Yes -Must be a valid term in SGBGP_TERM
-Must be greater than or equal to Effective From Term
-Must not overlap with other records in SUBJECT_TEMPLATE
-    
  Subject Title Subject Yes Cannot be longer than 255 characters #work - special character handling?    
  Transcript Title Subject Yes -Cannot be longer than 30 characters
-Must be equal or shorter than Subject Title
-    
  Department Code Subject Yes* -Must be a valid value in STVDEPT
-Must match mapping in STVSUBJ 

*If Subject Type is "Cross Registration", Department must be empty
-    
  Department Description Subject Yes Expects the Description associated with the Department Code -    
  School Code Subject Yes Expects the School Code associated with the Department Code -    
  School Description Subject Yes Expects the Description associated with the School Code -    
  Status Subject     #work - revisit after (re/de)activation use cases    
  Unit Type Units Yes Database field is variable_units - must be "Y" or "N" -    
  Fixed Units - Lecture Units Yes* -Must be not be greater than zero if variable_units = "Y"
-Must be in range [hd:0-9] if variable_units = "N"
*Required if variable_units = "N"
-    
  Fixed Units - Laboratory Units Yes* -Must be not be greater than zero if variable_units = "Y"
-Must be in range [hd:0-9] if variable_units = "N"
*Required if variable_units = "N"
-    
  Fixed Units - Preparation Units Yes* -Must be not be greater than zero if variable_units = "Y"
-Must be in range [hd:0-9] if variable_units = "N"
*Required if variable_units = "N"
-    
  Credit Limit Units Yes* -Must be not be greater than zero if variable_units = "Y" 
-Must be in range [hd:0-9] if variable_units = "N"
*Required if variable_units = "N"
-    
  Total Units Units Yes*   -Must be not be greater than zero if variable_units = "Y" 
-Must be in range [hd:0-9] if variable_units = "N"
*Required if variable_units = "N"

- - -    
  Subject Level Level Yes -Must be "U" or "G" "U" and "G" are hardcoded, not validating against a table    
  Attribute Code Attributes No Attribute Code must match a value in STVATTR Old attributes can be saved - STVATTR has no field to flag a field as old or out of use    
  Attribute Description Attributes No Expects the Description associated with the Attribute Code in STVATTR -    
  Enrollment Limitation Enrollment Limitations No -#work - max chars? #work - special character check?    
  Grading Scheme Grading Yes Must be an entry where Grading Type = "D" -    
  Grading Mode Grading Yes Must match a valid value in STVGMODE -    
  Grading Type Grading Yes -Must match a valid value in STVGM_TYP
-If FSEM attribute is present, must be a valid type for the Grading Mode - GMOD_TYPE_FRESHMAN_IND
-Certain Grading Types can only appear once in the Grading Scheme
-    
  Grading Description Grading Yes Expects the Grading Description associated with the Grading Mode -    
  Cross-listed Subject Code Cross-listed No Must be a valid value in STVSUBJ -    
  Cross-listed Subject Number Cross-listed No Must be in regular expression format [hd:A-Z0-9][hd:A-Z0-9][hd:A-Z0-9][hd:A-Z0-9] -    
  Cross-listed
Subject Key
Cross-listed No Subject Key must not already existing in      
               
               
               
               
               
               
               
               
               
               

Other API Error Handling

-If the API gets a THES attribute without a SUPR attribute, the API will throw an error
-If the API gets a UROP attribute without a SUPR attribute, the API will throw an error
-If the API gets an SWE attribute on a subject that has no child cross-listed subject numbers, the API will throw an error
-If the API gets a subject with a "URN" subject number and a UROP attribute but no "URN" attribute, the API will throw an error

Subject Management Documentation Index

The Subject Management Documentation Index is the central listing for documentation pertaining to Subject Management.

IS&T Contributions

Documentation and information provided by IS&T staff members


Last Modified:

May 19, 2017

Get Help

Request help
from the Help Desk
Report a security incident
to the Security Team
Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
Feedback
This product/service is:
Easy to use
Average
Difficult to use

This article is:
Helpful
Inaccurate
Obsolete
Adaptavist Theme Builder (4.2.3) Powered by Atlassian Confluence 3.5.13, the Enterprise Wiki