Skip to content

Latest commit

 

History

History
161 lines (144 loc) · 3.14 KB

File metadata and controls

161 lines (144 loc) · 3.14 KB

Get Person Information by Card Number

GET /cards/{card_number}

Description

Get person information by NCU card number. Read the NCU card number by devices with NFC.

Required Scope

  • user.info.basic.read

Request

Query Parameters

Name Required Description
id yes the last 4 digits of your id card number (身分證字號) for security purpose

Headers

Name Required Description
Authorization yes Your OAuth token in the form of Bearer XXX

Example

GET /cards/F06D4935?id=1234
GET /cards/F06D2549?id=6789

Response

Formats

  • json

Structure

There are two types of response. You can verify the type by type attribute

  • Student

    Field Name Type Value Description
    id String identity
    name String person name
    type String person type, this must be STUDENT here
    unit String student unit
    group String student group
    number String student number ( deprecated )
  • Faculty

    Field Name Type Value Description
    id String identity
    name String person name
    type String person type, this must be FACULTY here
    unit String faculty unit
    title String faculty title
    number String faculty number ( deprecated )

Example

{
    "id": "101502549",
    "name" : "john",
    "type" : "STUDENT",
    "unit" : "computer science",
    "group" : "none",
    "number" : "101502549",
}
{
    "id": "F123456",
    "name" : "jack",
    "type" : "FACULTY",
    "unit" : "computer center",
    "title" : "software developer",
    "number" : "F123456",
}