Authenticated Endpoints

Hayden McAfee edited this page May 14, 2017 · 2 revisions

There are other API endpoints that Purdue.io exposes that require authentication. These APIs are typically used for operations that require a Purdue Career Account (adding/dropping CRNs, fetching user schedule, etc). Due to the nature of these APIs, be aware that they are largely untested and that the Purdue.io team and contributors are not responsible for any consequences of their use.

How to authenticate

Authenticated endpoints require a valid Purdue Career Account to use. In order to provide credentials when using these APIs, simply add a Basic Authorization header. For example:

Authorization: Basic cHVyZHVlcGV0ZTpib2lsZXJtYWtlcjE=

Where cHVyZHVlcGV0ZTpib2lsZXJtYWtlcjE= is a base64 encoded username/password pair in the form of username:password, in this case purduepete:boilermaker1.

Security considerations

Always use https when using authenticated endpoints, as to avoid transmitting credentials in plaintext across the network.

Purdue.io does not store the credentials you send for authenticated endpoints - the credentials are only used to authenticate to MyPurdue via https. The Purdue.io team and contributors are not responsible for any consequences of making use of authenticated endpoints.

/Student

GET /Student/Crn/{termCode}/{crn}

This endpoint is used to retrieve up-to-date information on a particular CRN (usually used to get the latest seat count or waitlist).

termCode is the MyPurdue code for the term of the CRN you are querying for. E.g. 201710 for Fall 2016.

crn is the CRN number.

Example: GET /Student/Crn/201710/10055

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.