A-short-name / Public-Transportation-Manager

Web Applications II project
0 stars 0 forks source link

GET /tickets #12

Closed MattiaRiola closed 2 years ago

MattiaRiola commented 2 years ago

GET /tickets → returns a JSON representation of all available tickets. Those tickets are represented as a JSON object consisting of price, ticketId, type ( ordinal or type of pass). A ticketAcquired is represented as a JSON object consisting of the fields “sub” (the unique ticketID), “iat” (issuedAt, a timestamp), “validfrom” (useful for subscriptions), “exp” (expiry timestamp), “zid” (zoneID, the set of transport zones it gives access to), type (ordinal, weekend pass, etc), “jws” (the encoding of the previous information as a signed JWT) [Note that this JWT will be used for providing physical access to the train area and will be signed by a key that has nothing to do with the key used by the LoginService]