POST Train/SeatMap

Request Information

URI Parameters

None.

Body Parameters

TrainSeatMapRequest
NameDescriptionTypeAdditional information
origin

string

None.

destination

string

None.

paxAdult

integer

None.

paxChild

integer

None.

paxInfant

integer

None.

departDate

date

None.

trainNumber

string

None.

trainID

string

None.

subClass

string

None.

bookingCode

string

None.

bookingDate

date

None.

userID

user API

string

None.

accessToken

access code getting from login

string

None.

Request Formats

application/json, text/json

Sample:
{
  "origin": "sample string 1",
  "destination": "sample string 2",
  "paxAdult": 3,
  "paxChild": 4,
  "paxInfant": 5,
  "departDate": "2021-11-27T11:53:27.771382+07:00",
  "trainNumber": "sample string 7",
  "trainID": "sample string 8",
  "subClass": "sample string 9",
  "bookingCode": "sample string 10",
  "bookingDate": "2021-11-27T11:53:27.771382+07:00",
  "userID": "sample string 11",
  "accessToken": "sample string 12"
}

application/xml, text/xml

Sample:
<TrainSeatMapRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Cebes.DI.H2H.Api.Models">
  <accessToken>sample string 12</accessToken>
  <userID>sample string 11</userID>
  <bookingCode>sample string 10</bookingCode>
  <bookingDate>2021-11-27T11:53:27.771382+07:00</bookingDate>
  <departDate>2021-11-27T11:53:27.771382+07:00</departDate>
  <destination>sample string 2</destination>
  <origin>sample string 1</origin>
  <paxAdult>3</paxAdult>
  <paxChild>4</paxChild>
  <paxInfant>5</paxInfant>
  <subClass>sample string 9</subClass>
  <trainID>sample string 8</trainID>
  <trainNumber>sample string 7</trainNumber>
</TrainSeatMapRequest>

Response Information

Resource Description

TrainSeatMapResponse
NameDescriptionTypeAdditional information
origin

string

None.

destination

string

None.

paxAdult

integer

None.

paxChild

integer

None.

paxInfant

integer

None.

departDate

date

None.

trainNumber

string

None.

trainID

string

None.

subClass

string

None.

seats

Collection of TrainSeatModel

None.

respTime

describe time in sending response

date

None.

userID

user ID to access API

string

None.

accessToken

access token that needed to access API

string

None.

status

SUCCESS or FAILED

string

None.

respMessage

detail message of response status

string

None.

Response Formats

application/json, text/json

Sample:
{
  "origin": "sample string 1",
  "destination": "sample string 2",
  "paxAdult": 3,
  "paxChild": 4,
  "paxInfant": 5,
  "departDate": "2021-11-27T11:53:27.7869824+07:00",
  "trainNumber": "sample string 7",
  "trainID": "sample string 8",
  "subClass": "sample string 9",
  "seats": [
    {
      "wagonCode": "sample string 1",
      "wagonNumber": "sample string 2",
      "detail": [
        {
          "row": 1,
          "column": 2,
          "seatRow": "sample string 3",
          "seatColumn": "sample string 4",
          "seatNumber": "sample string 5",
          "subClass": "sample string 6",
          "isAvailable": true
        },
        {
          "row": 1,
          "column": 2,
          "seatRow": "sample string 3",
          "seatColumn": "sample string 4",
          "seatNumber": "sample string 5",
          "subClass": "sample string 6",
          "isAvailable": true
        }
      ],
      "totalRow": 3.1,
      "totalColumn": 4.1
    },
    {
      "wagonCode": "sample string 1",
      "wagonNumber": "sample string 2",
      "detail": [
        {
          "row": 1,
          "column": 2,
          "seatRow": "sample string 3",
          "seatColumn": "sample string 4",
          "seatNumber": "sample string 5",
          "subClass": "sample string 6",
          "isAvailable": true
        },
        {
          "row": 1,
          "column": 2,
          "seatRow": "sample string 3",
          "seatColumn": "sample string 4",
          "seatNumber": "sample string 5",
          "subClass": "sample string 6",
          "isAvailable": true
        }
      ],
      "totalRow": 3.1,
      "totalColumn": 4.1
    }
  ],
  "respTime": "2021-11-27T11:53:27.7869824+07:00",
  "userID": "sample string 11",
  "accessToken": "sample string 12",
  "status": "sample string 13",
  "respMessage": "sample string 14"
}

application/xml, text/xml

Sample:
<TrainSeatMapResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Cebes.DI.H2H.Api.Models">
  <accessToken>sample string 12</accessToken>
  <respMessage>sample string 14</respMessage>
  <respTime>2021-11-27T11:53:27.7869824+07:00</respTime>
  <status>sample string 13</status>
  <userID>sample string 11</userID>
  <departDate>2021-11-27T11:53:27.7869824+07:00</departDate>
  <destination>sample string 2</destination>
  <origin>sample string 1</origin>
  <paxAdult>3</paxAdult>
  <paxChild>4</paxChild>
  <paxInfant>5</paxInfant>
  <seats>
    <TrainSeatModel>
      <detail>
        <TrainSeatDetailModel>
          <column>2</column>
          <isAvailable>true</isAvailable>
          <row>1</row>
          <seatColumn>sample string 4</seatColumn>
          <seatNumber>sample string 5</seatNumber>
          <seatRow>sample string 3</seatRow>
          <subClass>sample string 6</subClass>
        </TrainSeatDetailModel>
        <TrainSeatDetailModel>
          <column>2</column>
          <isAvailable>true</isAvailable>
          <row>1</row>
          <seatColumn>sample string 4</seatColumn>
          <seatNumber>sample string 5</seatNumber>
          <seatRow>sample string 3</seatRow>
          <subClass>sample string 6</subClass>
        </TrainSeatDetailModel>
      </detail>
      <totalColumn>4.1</totalColumn>
      <totalRow>3.1</totalRow>
      <wagonCode>sample string 1</wagonCode>
      <wagonNumber>sample string 2</wagonNumber>
    </TrainSeatModel>
    <TrainSeatModel>
      <detail>
        <TrainSeatDetailModel>
          <column>2</column>
          <isAvailable>true</isAvailable>
          <row>1</row>
          <seatColumn>sample string 4</seatColumn>
          <seatNumber>sample string 5</seatNumber>
          <seatRow>sample string 3</seatRow>
          <subClass>sample string 6</subClass>
        </TrainSeatDetailModel>
        <TrainSeatDetailModel>
          <column>2</column>
          <isAvailable>true</isAvailable>
          <row>1</row>
          <seatColumn>sample string 4</seatColumn>
          <seatNumber>sample string 5</seatNumber>
          <seatRow>sample string 3</seatRow>
          <subClass>sample string 6</subClass>
        </TrainSeatDetailModel>
      </detail>
      <totalColumn>4.1</totalColumn>
      <totalRow>3.1</totalRow>
      <wagonCode>sample string 1</wagonCode>
      <wagonNumber>sample string 2</wagonNumber>
    </TrainSeatModel>
  </seats>
  <subClass>sample string 9</subClass>
  <trainID>sample string 8</trainID>
  <trainNumber>sample string 7</trainNumber>
</TrainSeatMapResponse>