TMW Web-API Schnittstelle

Version: 2.5.3

Server: SQL01.TMW.AC.AT\TMW

Rätsel-Rallye Funktionen


Allgemein
Headers Values
Authorization Basic
Content-Type application/json

Language
Property Type Description
Language_ID Int Primary-Key of Language
LanguageName String Name of Language
CultureCode String culture_Code of Language
Language - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all posible languages GET --- --- --- List[Language] https://webapi.tmw.at/language
Get a languages by it's primary key GET id Int Primary-Key of Language Language https://webapi.tmw.at/language?id=1

Floor
Property Type Description
Floor_ID Int Primary-key of Floor
FloorName String Name of Floor
Floor - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all floors in the museum GET --- --- --- List[Floor] https://webapi.tmw.at/floor
Get a floor by it's primary key GET id Int Primary-Key of Floor Floor https://webapi.tmw.at/floor?id=4
Get the map of a floor by it's primary key GET id Int Primary-Key of Floor Content-Type: image/jpeg https://webapi.tmw.at/floor-map?id=4

GridSquare
Property Type Description
GridSquare_ID Int Primary-Key of Gridsquare
GridSquareName String Name of Gridsquare
Floor_ID Int (NULL) Primary-Key of Floor
Map_Top Int (NULL) Top position (Pixel) of the Gridsquare in the Floor-Map
Map_Left Int (NULL) Left position (Pixel) of the Gridsquare in the Floor-Map
Map_Right Int (NULL) Right position (Pixel) of the Gridsquare in the Floor-Map
Map_Bottom Int (NULL) Bottom position (Pixel) of the Gridsquare in the Floor-Map
GridSquare - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all gridsquares in the museum GET --- --- --- List[GridSquare] https://webapi.tmw.at/grid-square
Get a gridsquare by it's primary key GET id Int Primary-Key of Gridsquare GridSquare https://webapi.tmw.at/grid-square?id=4786
Get a list of all gridsquares on a predefined floor in the museum GET floor_id Int Primary-Key of Floor GridSquare https://webapi.tmw.at/grid-square?floor_id=4

MediaCategory
Property Type Description
MediaCategory_ID Int Primary-Key of MediaCategory
MediaCategoryName String Name of MediaCategory
MediaCategory - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all media categories GET --- --- --- List[MediaCategory] https://webapi.tmw.at/media-storage/media-category
Get a media category by it's primary key GET id Int Primary-Key of MediaCategory MediaCategory https://webapi.tmw.at/media-storage/media-category?id=9

FileType
Property Type Description
FileType_ID Int Primary-Key of FileType
FileTypeName String Name of FileType
FileExtension String Possible extensions of FileType
DefaultExtension String Default extension of FileType
IsImageFileType Boolean Flag for Image
IsAudioFileType Boolean Flag for Audio
IsVideoFileType Boolean Flag for Video
FileType - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all file types GET --- --- --- List[FileType] https://webapi.tmw.at/media-storage/file-type
Get a file types by it's primary key GET id Int Primary-Key of FileType FileType https://webapi.tmw.at/media-storage/file-type?id=14

MediaStorage
Property Type Description
MediaStorage_ID Int Primary Key
Title String Title of the stored file
Remarks String Remarks regarding to the stored file and about the storing process.
MediaCategory_ID Int (NULL) Foreign-Key of the MediaCategory
FileType_ID Int Foreign-Key of the FileType
Checksum String Checksum generated from the stored file with MD5 Hash-Algorithm
MediaStorage - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a media storage dataset by it's primary key GET id Int Primary-Key of MediaStorage MediaStorage https://webapi.tmw.at/media-storage?id=386873
Get the original media storage file by it's primary key GET id Int Primary-Key of MediaStorage Content-Type: application/octet-stream https://webapi.tmw.at/media-storage/file?id=386873
Get the thumbnail picture of the media storage dataset by it's primary key. (only available for file types with falg "IsImageFileType") GET id Int Primary-Key of MediaStorage Content-Type: image/jpeg https://webapi.tmw.at/media-storage/thumbnail?id=386873
Get a version of the image suitable in size for displaying on the web. (only available for file types with falg "IsImageFileType") GET id Int Primary-Key of MediaStorage Content-Type: image/jpeg https://webapi.tmw.at/media-storage?id=386873&version_id=13
version_id Int Primary-Key of Picture-Version
Upload a file into the media storage POST title String Title of the File MediaStorage (NULL) https://webapi.tmw.at/media-storage/upload?title=UploadFile&file_type_id=5&media_type_id=1&media_category_id=4&remarks=Upload Test
file_type_id Int Primary-Key of FileType
media_type_id Int Primary-Key of MediaType
media_category_id Int Primary-Key of MediaCategory
remarks String Remarks regarding the file
Attache the file to the request as a stream

PictureVersion
Property Type Description
PictureVersion_ID Int Primary-Key
PictureVersionName String Title of Picture-Version
Width Int Maximum width of the picture
Height Int (NULL) Maximum height of the picture
Quality Int Quality of the rendered picture in percent.
PictureVersion - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of picture versions GET --- --- --- List[PictureVersion] https://webapi.tmw.at/media-storage/picture-version
Get a picture versions by it's primary key GET id int Primary-Key of Picture-Version PictureVersion (NULL) https://webapi.tmw.at/media-storage/picture-version?id=13
Zone
Property Type Description
Zone_ID Int Primary-Key
ZoneTitle String Title of Zone
ZoneDescription String Description of Zone
MediaStorage_ID Int (NULL) Primary-Key of MediaStorage (main picture of the zone)
MediaSubTitle String Caption of the zone's main picture
Gridsquare_ID Int Primary-Key of Gridsquare
GridsquareOffsetX Int (NULL) Horizontal offset for the flag on the map
GridsquareOffsetY Int (NULL) Vertical offset for the flag on the map
Duration Int (NULL) Duration in minutes to reach the zone
SorktKey Int (NULL) Sortorder within a puzzle-hunt
Zone - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of zones in the defined language GET language_id Int Primary-Key of Language List[Zone] https://webapi.tmw.at/puzzle-hunt/zone?language_id=1
Get a zones by it's primary key GET zone_id Int Primary-Key of Zone Zone https://webapi.tmw.at/puzzle-hunt/zone?zone_id=15
Get all zones of a puzzle hunt GET puzzle_hunt_id Int Primary-Key of PuzzleHunt List[Zone] https://webapi.tmw.at/puzzle-hunt/zone?puzzle_hunt_id=4433
Difficulty
Property Type Description
Difficulty_ID Int Primary-Key of Difficulty
DifficultyTitle String Title of Difficulty
InternalKey String Internal-Key of Difficulty
Language_ID Int Primary-Key of Language
Difficulty - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all available difficulty levels GET --- --- --- List[Difficulty] https://webapi.tmw.at/puzzle-hunt/difficulty?language_id=1
Get a difficulty level by it's primary key GET id Int Primary-Key of Difficulty Difficulty https://webapi.tmw.at/puzzle-hunt/difficulty?language_id=1&difficulty_id=2

Station
Property Type Description
Station_ID Int Primary-Key of Station
StationTitle String Title of Station
Zone_ID Int Primary-Key of Zone
Difficulty_ID Int Primary-Key of Difficulty
StationDescription String Text, that describes the station
DidYouKnowThat String Did you konw that, ...
Gridsquare_ID Int Primary-Key of Gridsquare
GridsquareOffsetX Int (NULL) Horizontal offset for the flag on the map
GridsquareOffsetY Int (NULL) Vertical offset for the flag on the map
Duration Int (NULL) Duration in minutes to solve all questions related with this station.
MediaStorage_ID Int (NULL) Primary-Key of MediaStorage (main pictrue of this station)
MediaSubTitle String Caption of the picture
InternalKey String Internal key related to import files
Questions List[Question] All questions from TMW related to this station
SortKey Int (NULL) Sortorder of the Station in a PuzzleHunt
Station - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all stations of a zone with a predefined difficulty GET zone_id Int Primary-Key of Zone List[Station] https://webapi.tmw.at/puzzle-hunt/station?zone_id=15&difficulty_id=2
difficulty_id Int Primary-Key of Difficulty
Get a station by it's primary key with a predefined difficulty GET station_id Int Primary-Key of Station Station https://webapi.tmw.at/puzzle-hunt/station?station_id=587&difficulty_id=2
difficulty_id Int Primary-Key of Difficulty
Get a specific number of random stations with a predefined zone and difficulty GET zone_id Int Primary-Key of Zone List[Station] https://webapi.tmw.at/puzzle-hunt/station?zone_id=15&difficulty_id=2&count=3
difficulty_id Int Primary-Key of Difficulty
count Int Number of Stations to get

MeetingPoint
Property Type Description
MeetingPoint_ID Int Primary-Key of MeetingPoint
MeetingPointName String Name of MeetingPoint
Gridsquare_ID Int Primary-Key of Gridsquare
GridsquareOffsetX Int (NULL) Horizontal offset for the flag on the map
GridsquareOffsetY Int (NULL) Vertical offset for the flag on the map
MeetingPoint - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all posible meeting points in the museum GET --- --- --- List[MeetingPoint] https://webapi.tmw.at/puzzle-hunt/meeting-point

QuestionType
Property Type Description
QuestionType_ID Int Primary-Key of QuestionType
QuestionTypeName String Name of QuestionType
InternalKey String Internal reference for import/export
MediaStorage_ID Int (NULL) Primary-Key of Mediastorage (Icon of Questiontype)
QuestionType - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all question types GET --- --- --- List[QuestionType] https://webapi.tmw.at/puzzle-hunt/question-type
Get a question type by it's primary key GET id Int Primary-Key of QuestionType QuestionType https://webapi.tmw.at/puzzle-hunt/question-type?id=12
Get the icon of a question type by it's primary key GET id Int Primary-Key of QuestionType Content-Type: image/jpeg https://webapi.tmw.at/puzzle-hunt/question-type-icon?id=12

AnswerBoxSize
Property Type Description
AnswerBoxSize_ID Int Primary-Key of AnswerBoxSize
AnswerBoxSizeName String Name of AnswerBoxSize
Width Int Width of answer box in pixel
Height Int Height of answer box in pixel
AnswerBoxSize - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all answer box types GET --- --- --- List[AnswerBoxSize] https://webapi.tmw.at/puzzle-hunt/answer-box-size
Get a answer box type by it's primary key GET id Int Primary-Key of AnswerBoxSize AnswerBoxSize https://webapi.tmw.at/puzzle-hunt/answer-box-size?id=4

PictureBoxSize
Property Type Description
PictureBoxSize_ID Int Primary-Key of PictureBoxSize
PictureBoxSizeName String Name of PictureBoxSize
InternalKey String Internal reference for import/export
Width Int Width of picture box in pixel
Height Int Height of picture box in pixel
PictureBoxSize - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all picture box types GET --- --- --- List[PictureBoxSize] https://webapi.tmw.at/puzzle-hunt/picture-box-size
Get a picture box type by it's primary key GET id Int Primary-Key of PictureBoxSize PictureBoxSize https://webapi.tmw.at/puzzle-hunt/picture-box-size?id=5

Question
Property Type Description
Question_ID Int Primary-Key of Question
CustomerAccount_ID Int Primary-Key of CustomerAccount
QuestionType_ID Int Primary-Key of QuestionType
InternalKey String Internal reference for import/export
Station_ID Int Primary-Key of Station
Difficulty_ID Int Primary-Key of Difficulty
QuestionText String The question
QuestionMediaStorage_ID Int (NULL) Main picture of the question
QuestionPictureBoxSize_ID Int (NULL) Size of the main picture
AnswerText String Answer, that is showed at answer book
AnswerMediaStorage_ID Int (NULL) Picture belonging to the answer, that is showed at answer book
AnswerBoxSize_ID Int (NULL) Size of the answer box
Duration Int (NULL) Duration to answer the question
ChoiceList List[Choice] (NULL) Choice list for some kinds of questions
Question - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get all questions for a station with a predefined difficulty
Questions defined by a customer account are excluded.
GET station_id Int Primary-Key of Station List[Question] https://webapi.tmw.at/puzzle-hunt/question?station_id=587&difficulty_id=2
difficulty_id Int Primary-Key of Difficulty
Get all questions for a station with a predefined difficulty
Questions defined by a customer account are included.
GET station_id Int Primary-Key of Station List[Question] https://webapi.tmw.at/puzzle-hunt/question?customer_account_id=182708&station_id=587&difficulty_id=2
difficulty_id Int Primary-Key of Difficulty
customer_account_id Int Primary-Key of Customer Account
Get a single questions by it's primary key GET id Int Primary-Key of Question Question https://webapi.tmw.at/puzzle-hunt/question?id=4533
Add a customized Single- or Multiple-Choice-Question to the puzzle hunt. POST puzzle_hunt_id Int Primary-Key of PuzzleHunt Question https://webapi.tmw.at/puzzle-hunt/question/add?puzzle_hunt_id=4433&question_type_id=4&station_id=636&question=Was galubst du?&customer_account_id=182708
customer_account_id Int Primary-Key of Customer Account
station_id Int Primary-Key of Station
question_type_id Int Primary-Key of QuestionType
only Multiple Choice Text (id: 4) and
Single Choice Text (id: 5) allowed
question String The question
Delete customer account defined question. POST question_id Int Primary-Key of Question HttpResponseMessage https://webapi.tmw.at/puzzle-hunt/question/remove?&question_id=4679
Update customer account defined question. POST question_id Int Primary-Key of Question Question https://webapi.tmw.at/puzzle-hunt/question/update?question_id=4679&question=Kann man 159 durch 3 teilen?
question String The question

Choice
Property Type Description
Choice_ID Int Primary-Key of Choice
Question_ID Int Primary-Key of Question
ChoiceText String Choice as Text
ChoiceMediaStorage_ID Int (NULL) Choice as Picture (Primary_key of MediaStorage)
ResponseText String Counterpart as Text
ResponseBoolean Boolean (NULL) Counterpart as Boolean
ResponseMediaStorage_ID Int (NULL) Counterpart as Picture
ResponseSort Int (NULL) Counterpart as Number
Choice
Purpose Method Parameter Return-Value Example
Name Type Description
Get the choices for a question GET question_id Int Primary-Key of Question List[Choice] https://webapi.tmw.at/puzzle-hunt/question/choice?question_id=4679
Get a single choice by it's primary key GET id Int Primary-Key of Choice Choice https://webapi.tmw.at/puzzle-hunt/question/choice?id=1520
Add a choice to a customized question POST question_id Int Primary-Key of Question Choice https://webapi.tmw.at/puzzle-hunt/question/add-choice?question_id=4031&choice_text=Auswahl Nr. 159&response=false
choice_text String Choice-Text to display
response Boolean Choice ist true or false
Remove a single choice by it's primary key POST id Int Primary-Key of Choice Question https://webapi.tmw.at/puzzle-hunt/question/remove-choice?id=1520
Update a choice to a customized question POST choice_id Int Primary-Key of Choice Choice https://webapi.tmw.at/puzzle-hunt/question/update-choice?choice_id=1520&choice_text=Ja&response=false
choice_text String Choice-Text to display
response Boolean Choice ist true or false

Status
Property Type Description
Status_ID Int Primary-key of Status
StatusName String Name of Status
Status - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of all status GET --- --- --- List[Status] https://webapi.tmw.at/status
Get a status by it's primary key GET id Int Primary-Key of Status Status https://webapi.tmw.at/status?id=2

PuzzleHunt
Property Type Description
PuzzleHunt_ID Int Primary-Key of Puzzle-Hunt
PuzzleHuntTitle String Title of the Puzzle-Hunt
Difficulty_ID Int Primary-Key of Difficulty
Language_ID Int Primary-Key of Language
Status_ID Int Primary-Key of Status
CustomerAccount_ID Int (NULL) Primary-Key of Customer-Account
MeetingPointStart_ID Int (NULL) Primary-Key of Meetingpoint for start location
MeetingPointStart MeetingPoint (NULL) Meetingpoint for start location
MeetingPointEnd_ID Int (NULL) Primary-Key of Meetingpoint for end location
MeetingPointEnd MeetingPoint (NULL) Meetingpoint for end location
Stations List[Station] All Stations linked to the Puzzle-Hunt
Zones List[Zone] All Zones linked to the Puzzle-Hunt
Duration Int Duration in minutes of the Puzzle-Hunt
PuzzleHunt - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a puzzle hunt by it's primary key GET id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt?id=4433
Create a new puzzle hunt with a predefined number of stations, in a predefined zone with a predefined difficulty. The start and end meeting points are optional. POST zone_id Int Primary-Key of Zone PuzzleHunt https://webapi.tmw.at/puzzle-hunt/create?zone_id=15&difficulty_id=2&title=Neue Rätselrallye&meeting_point_start_id=1&meeting_point_end_id=3&station_count=2&customer_account_id=182708
difficulty_id Int Primary-Key of Difficulty
title String Title of the Puzzle-Hunt
meeting_point_start_id Int (NULL) Primary-Key of Meetingpoint for start location
meeting_point_end_id Int (NULL) Primary-Key of Meetingpoint for end location
station_count Int Number of stations to be created
status_id Int Primary-Key of Status (Default-Value [online] = 1)
customer_acccount_id Int (NULL) Primary-Key of Customer-Account
Update a puzzle hunt (only title, status and the meeting poinst can be changed) POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/update?id=4433&title=Rätselrallye Nr. 4433&status_id=2&meeting_point_start_id=1&meeting_point_end_id=3
title String The title of PuzzleHunt
status_id Int (NULL) If omitted the status keeps the same value
meeting_point_start_id Int (NULL) The title of PuzzleHunt
meeting_point_end_id Int (NULL) The title of PuzzleHunt
Add a station to the puzzle hunt POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/add-station?id=4433&station_id=587
station_id Int Primary-Key of Station
Remove a station from the puzzle hunt POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/remove-station?id=4433&station_id=636
station_id Int Primary-Key of Station
Remove all station of a defined zone from the puzzle hunt POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/remove-zone?id=4433&zone_id=21
zone_id Int Primary-Key of Zone
Move a station one place up in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-up-station?id=4433&station_id=639
station_id Int Primary-Key of Station
Move a station one place down in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-down-station?id=4433&station_id=639
station_id Int Primary-Key of Station
Move a station to a specific position in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-to-position-station?id=4433&station_id=639&position=1
station_id Int Primary-Key of Station
position Int Move to position
Move a zone one place up in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-up-zone?id=4433&zone_id=21
zone_id Int Primary-Key of Zone
Move a zone one place down in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-down-zone?id=4433&zone_id=21
zone_id Int Primary-Key of Zone
Move a zone to a specific position in sort order POST id Int Primary-Key of Puzzle-Hunt PuzzleHunt https://webapi.tmw.at/puzzle-hunt/move-to-position-zone?id=4433&zone_id=21&position=1
zone_id Int Primary-Key of Zone
position Int Move to position
Copy an existing puzzle hunt POST id Int Primary-Key of Puzzle-Hunt (source) PuzzleHunt https://webapi.tmw.at/puzzle-hunt/copy?id=4433&customer_account_id=182708
customer_account_id Int (NULL) Primary-Key of Customer Account (target)

PuzzleHuntShortSummary
Property Type Description
PuzzleHunt_ID Int Primary-Key of Puzzle-Hunt
PuzzleHuntTitle String Title of the Puzzle-Hunt
Difficulty_ID Int Primary-Key of Difficulty
Language_ID Int Primary-Key of Language
Status_ID Int Primary-Key of Status
CustomerAccount_ID Int (NULL) Primary-Key of Customer-Account
Duration Int Duration in minutes of the Puzzle-Hunt
PuzzleHuntShortSummary - Functions
Purpose Method Parameter Return-Value Example
Name Type Description
Get a list of puzzle hunt short summary by searching title, difficulty, language and status GET title String Search string with wildcard % allowed List[PuzzleHuntShortSummary] https://webapi.tmw.at/puzzle-hunt/search?title=*rallye*&difficulty_id=2&language_id=1
difficulty_id Int (NULL) Primary-Key of Difficulty
language_id Int (NULL) Primary-Key of Language
status_id Int (NULL) Primary-Key of Status (Default-Value [online] = 1)
Get a list of puzzle hunt short summary by customer account GET customer_account_id Int Primary-Key of Customer Account List[PuzzleHuntShortSummary] https://webapi.tmw.at/puzzle-hunt?customer_account_id=182708