Interface description
Ticket generator
All of the following attributes are mandatory. Exceptions are marked "optional".
Attribute | Example / Format | Explanation |
semester | 23S / 23W | Semester Summer semester 23S or winter semester 23W |
matriculationNumber | 123456 | matriculation number |
salutation | m / f | Salutation m=male, f=female "Divers" is not possible in OTS. You must select m or f. |
title | Dr. | Title (optional) |
firstName | Max Moritz | firstName(s) |
lastName | Sample man | LastName(s) |
birthdate | 1990-09-07 | date of birth |
company | e.g. student secretariat | Company, can be identical for all (optional) |
street | castle square | street |
streetNumber | 2 | house number |
postalCode | 12345 | postal code |
city | Sample city | city |
country | DE | country |
phone | 0123456789 | Phone (optional) |
max.mustermann@meine-uni.de | e-mail address | |
payment | free | Payment method (according to www.ots-nrw.de step 3) |
elv | true | Direct debit accepted? |
privacyHs | true | Data exchange with university accepted? |
general terms and conditions | true | AGB accepted? |
privacy | true | Privacy policy accepted? |
Further explanations
To order the tickets, you must agree to / acknowledge the direct debit, GTC and privacy policy. The order can only be executed if all 4 attributes contain the value "true".
Our recommendation:
Have users agree to the following conditions and information in the application. In the OTS, the following texts are displayed in order step 5 and are each provided with a checkbox.
elv: I hereby confirm that the total amount is to be debited from my account / credit card. Semesterticket NRW will not be charged.
privacyHs: Yes, the specified university may inform DB Vertrieb GmbH whether or not I am enrolled for the semester in question using the information provided here.
agb + privacy: I accept the general terms and conditions and take note of the data protection information .
Note
Brain Appeal cannot provide a legal assessment of whether these checkboxes must be included in your application. If in doubt, please seek legal advice.
Example request with curl
All information is transferred to the ticket generator via this call. In this example, the data transfer takes place via the command line with cURL (information on cURL with UbuntuLinux, cURL with Windows 10). Other forms are also possible and may depend on the system used.
Readable variant:
| curl
| --header "Accept: application/json"
| --header "Content-Type: application/json"
| --request POST
| --data '{
| "semester": "20212",
| xml-ph-0032@deepl."123456",
| "salutation": "m",
| "title":"",
| "firstName":"Max Moritz",
| "lastName": "Mustermann",
| "birthdate": "1990-09-07",
| "company":"",
| "street": "Schlossplatz",
| "streetNumber": "2",
| "postalCode":"12345",
| "city": "Musterstadt",
| "country": "DE",
| "phone": "0123456789",
| "email":"max.mustermann@meine-uni.de",
| "payment": "free",
| "elv": "true",
| "agb":"true",
| "privacy": "true",
| "privacyHs": "true"
| }'
| www.semestertickets.com
Compact variant:
| curl --header "Accept: application/json" --header "Content-Type: application/json" --request POST --data '{"semester": "20212", "matriculationNumber": "123456", "salutation": "f", "title":"", "firstName": "Max Moritz", "lastName": "Mustermann", "birthdate":"1990-09-07","company":"","street":"Schlossplatz","streetNumber":"2","postalCode":"12345","city":"Musterstadt","country":"DE","phone":"0123456789","email":"max.mustermann@meine-uni.de","payment":"free","elv":"true","agb":"true","privacy":"true","privacyHs":"true"}' https://www.semestertickets.com
Return value:
If the ticket generation is successful, the interface returns a URL via which the ticket can be downloaded as a PDF.
The validity of the link to the ticket PDF is determined by the OTS. Recommendation: For performance reasons, store the ticket in the local cache .
Alternative:
After the ticket has been generated, the ticket can be sent to the e-mail address of the customer.