POST api/courses

Insert a new Course.

Request Information

URI Parameters

None.

Body Parameters

CourseDto
NameDescriptionTypeAdditional information
Id

The primary key of the record in the Hobsons database.

integer

None.

Name

string

Required

String length: inclusive between 0 and 200

Code

The client system code for the given record. Ignored for PUT requests sent to the API.

string

Required

String length: inclusive between 0 and 100

Description

Ignored for PUT requests sent to the API.

string

String length: inclusive between 0 and 4000

Position

Can be used for ordering a collection of records if configured. Ignored for PUT requests sent to the API.

integer

Range: inclusive between 1 and 99999999

QualificationId

A reference to the primary key of the Qualification record that is associated with this record. Ignored for PUT requests sent to the API.

integer

Range: inclusive between 1 and 99999999

QualificationName

The name of the Qualification record that is associated with this record. Ignored for PUT and POST requests sent to the API.

string

None.

StudyLevelId

A reference to the primary key of the StudyLevel record that is associated with this record. Ignored for PUT requests sent to the API.

integer

Required

Range: inclusive between 1 and 99999999

StudyLevelName

The name of the StudyLevel record that is associated with this record. Ignored for PUT and POST requests sent to the API.

string

None.

FacultyId

A reference to the primary key of the Faculty record that is associated with this record. Ignored for PUT requests sent to the API.

integer

Range: inclusive between 1 and 99999999

FacultyName

The name of the Faculty record that is associated with this record. Ignored for PUT and POST requests sent to the API.

string

None.

DepartmentId

A reference to the primary key of the Department record that is associated with this record. Ignored for PUT requests sent to the API.

integer

Range: inclusive between 1 and 99999999

DepartmentName

The name of the Department record that is associated with this record. Ignored for PUT and POST requests sent to the API.

string

None.

StudyAreas

During PUT and POST requests sent to the API, only the StudyAreaDto.Id field is used. During PUT requests sent to the API the system replaces all existing associations with the list provided.

Collection of StudyAreaDto

None.

Inactive

boolean

Required

Request Formats

application/json, text/json

Sample:
{
  "Id": 1,
  "Name": "sample string 2",
  "Code": "sample string 3",
  "Description": "sample string 4",
  "Position": 1,
  "QualificationId": 1,
  "QualificationName": "sample string 5",
  "StudyLevelId": 6,
  "StudyLevelName": "sample string 7",
  "FacultyId": 1,
  "FacultyName": "sample string 8",
  "DepartmentId": 1,
  "DepartmentName": "sample string 9",
  "StudyAreas": [
    {
      "Id": 1,
      "Name": "sample string 2",
      "Position": 1,
      "Inactive": true
    },
    {
      "Id": 1,
      "Name": "sample string 2",
      "Position": 1,
      "Inactive": true
    }
  ],
  "Inactive": true
}

Response Information

Resource Description

The primary key (id) of the Course record inserted in the Hobsons database.

integer

Response Formats

application/json, text/json

Sample:
1