Prva stranica 
Natrag 
Naprijed 
Novosti 
 Kopiraj URL stranice 
 
Natisni stranNatisni stran  
e-računi upute za uporabu  >  Internetske usluge i in...  >  API Reference  >  TABooking API

TABooking API

API for retrieving, creating, updating and listing of reservations/bookings.

TABookingGetGet reservation by number.
TABookingCreateCreate a new reservation.
TABookingUpdateUpdate an existing reservation.
TABookingDeleteDelete a desired reservation.
TABookingListGet a list of reservations for the specified criteria.

TABookingGet

Get a travel agency reservation/booking by document number or by a combination the document number and date.

Parameters

numberDocument number. Can use sequential document number (example: 2), or formated number (example: 2016-00001)
dateDocument date

Example request and response

POST /WebServicesHR/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream

<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="ivan" md5pass="8b29582ce0a1c85dc0c574d218acb900" token="649026C063054A139549200F3C9D01C6" />
<method name="TABookingGet">
       <parameter name="number" value="2016-00001" />
       <parameter name="date" type="Date" value="2016-12-15" />
</method>
</request>

Response
HTTP/1.1 200 OK
Server: e-racuni.com web server
Date: Tue, 1 March 2010 11:00:05 GMT
Content-Type: text/xml
Content-Length: 328

<?xml version="1.0" encoding="utf-8"?>
<response status="ok">
       <TABooking>
               <accommodationDescription>Hotel Arena</accommodationDescription>
               <bookingPayerCity>Zagreb</bookingPayerCity>
               <bookingPayerCountry>HR</bookingPayerCountry>
               <bookingPayerName>Ivan Novak</bookingPayerName>
               <bookingPayerPostalCode>10000</bookingPayerPostalCode>
               <bookingPayerStreet>Ilica 9</bookingPayerStreet>
               <bookingPayerPassportNumber>123456789</bookingPayerPassportNumber>
               <bookingPayerTaxNumber>87311810356</bookingPayerTaxNumber>
               <businessYear>2016</businessYear>
               <cancellationRiskEnsurance>true</cancellationRiskEnsurance>
               <cancellationRiskEnsuranceAmount>250.000</cancellationRiskEnsuranceAmount>
               <commissionAbsoluteAmount>0.00</commissionAbsoluteAmount>
               <commissionAmount>0.00</commissionAmount>
               <commissionPercent>0.000</commissionPercent>
               <costPosition>100</costPosition>
               <dateFrom>2016-12-18</dateFrom>
               <dateTo>2017-01-03</dateTo>
               <dateOfIssue>2016-12-15</dateOfIssue>
               <destinationDescription>Dubrovnik</destinationDescription>
               <documentDate>2016-12-15</documentDate>
               <firstService>DINNER</firstService>
               <lastService>BREAKFAST</lastService>
               <number>2016-00001</number>
               <numberOfDays>16</numberOfDays>
               <organizer>OrganizerNameString</organizer>
               <salesService>Prodajna služba</salesService>
               <services>2xALL</services>
               <status>Confirm</status>
               <subscriber>Naručitelj</subscriber>
               <totalCurrency>HRK</totalCurrency>
               <Services>
                       <Service>
                               <amount>200.00</amount>
                               <baseForCommission>false</baseForCommission>
                               <dateFrom>2017-01-01</dateFrom>
                               <dateTo>2017-01-05</dateTo>
                               <description>PPO</description>
                               <numberOfDays>16</numberOfDays>
                               <numberOfPerson>1</numberOfPerson>
                               <position>1</position>
                               <quantity>1</quantity>
                               <totalAmount>200.00</totalAmount>
                               <vatPercentage>25</vatPercentage>
                               <vatTransactionType>26</vatTransactionType>
                       </Service>
                       <Service>
                               <amount>2.00</amount>
                               <baseForCommission>false</baseForCommission>
                               <dateFrom>2017-01-01</dateFrom>
                               <dateTo>2017-01-05</dateTo>
                               <description>Boravišna pristojba</description>
                               <numberOfDays>16</numberOfDays>
                               <numberOfPerson>1</numberOfPerson>
                               <position>2</position>
                               <quantity>1</quantity>
                               <totalAmount>2.00</totalAmount>
                               <vatPercentage>0</vatPercentage>
                               <vatTransactionType>10</vatTransactionType>
                       </Service>
               </Services>
               <Participants>
                       <Participant>
                               <dateOfBirth>1981-10-08</dateOfBirth>
                               <position>1</position>
                               <surnameAndName>Zrinski Nikola</surnameAndName>
                       </Participant>
               </Participants>
       </TABooking>
</response>

Response (on error)
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
       <error description="document could not be found"><error/>
</response>


TABookingCreate

Create a new travel agency reservation/booking.

Supported values for vatTransactionType are:

0 - Taxable transactions of goods and services in Croatia,
7 - Transactions exempt from VAT - not for VAT records,
3 - Transactions excluded from VAT - Other,
10 - Transitory item - tourist residence tax,
11 - Transitory item - tourist travel insurance,
12 - Transitory item - other,
26 - Special VAT margin calculation for travel agencies,
27 - Special VAT margin calculation for travel agencies - Excluded from vat,

Possible status values: Option, Request, Confirm, Personally, Cancelled, Ready, Coupon, Finished
Possible transportation values: OwnTransport, Bus, Plane, Ship

Parameters

TABookingTravel agencies reservation/booking data in xml substructure.

Example request and response

POST /WebServicesHR/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream

<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="ivan" md5pass="8b29582ce0a1c85dc0c574d218acb900" token="649026C063054A139549200F3C9D01C6" />
<method name="TABookingCreate">
       <parameter name="TABooking">
               <accommodationDescription>Hotel Arena</accommodationDescription>
               <bookingPayerCity>Zagreb</bookingPayerCity>
               <bookingPayerCountry>HR</bookingPayerCountry>
               <bookingPayerName>Ivan Novak</bookingPayerName>
               <bookingPayerPostalCode>10000</bookingPayerPostalCode>
               <bookingPayerStreet>Ilica 9</bookingPayerStreet>
               <bookingPayerPassportNumber>123456789</bookingPayerPassportNumber>
               <bookingPayerTaxNumber>87311810356</bookingPayerTaxNumber>
               <businessYear>2016</businessYear>
               <cancellationRiskEnsurance>true</cancellationRiskEnsurance>
               <cancellationRiskEnsuranceAmount>250.000</cancellationRiskEnsuranceAmount>
               <commissionAbsoluteAmount>0.00</commissionAbsoluteAmount>
               <commissionAmount>0.00</commissionAmount>
               <commissionPercent>0.000</commissionPercent>
               <costPosition>100</costPosition>
               <dateFrom>2016-12-18</dateFrom>
               <dateTo>2017-01-03</dateTo>
               <dateOfIssue>2016-12-15</dateOfIssue>
               <destinationDescription>Dubrovnik</destinationDescription>
               <documentDate>2016-12-15</documentDate>
               <firstService>DINNER</firstService>
               <lastService>BREAKFAST</lastService>
               <number>2016-00001</number>
               <numberOfDays>16</numberOfDays>
               <organizer>OrganizerNameString</organizer>
               <salesService>Prodajna služba</salesService>
               <services>2xALL</services>
               <status>Confirm</status>
               <subscriber>Naručitelj</subscriber>
               <totalCurrency>HRK</totalCurrency>
               <Services>
                       <Service>
                               <amount>200.00</amount>
                               <baseForCommission>false</baseForCommission>
                               <dateFrom>2017-01-01</dateFrom>
                               <dateTo>2017-01-05</dateTo>
                               <description>PPO</description>
                               <numberOfDays>16</numberOfDays>
                               <numberOfPerson>1</numberOfPerson>
                               <position>1</position>
                               <quantity>1</quantity>
                               <totalAmount>200.00</totalAmount>
                               <vatPercentage>25</vatPercentage>
                               <vatTransactionType>26</vatTransactionType>
                       </Service>
                       <Service>
                               <amount>2.00</amount>
                               <baseForCommission>false</baseForCommission>
                               <dateFrom>2017-01-01</dateFrom>
                               <dateTo>2017-01-05</dateTo>
                               <description>Boravišna pristojba</description>
                               <numberOfDays>16</numberOfDays>
                               <numberOfPerson>1</numberOfPerson>
                               <position>2</position>
                               <quantity>1</quantity>
                               <totalAmount>2.00</totalAmount>
                               <vatPercentage>0</vatPercentage>
                               <vatTransactionType>10</vatTransactionType>
                       </Service>
               </Services>
               <Participants>
                       <Participant>
                               <dateOfBirth>1981-10-08</dateOfBirth>
                               <position>1</position>
                               <surnameAndName>Zrinski Nikola</surnameAndName>
                       </Participant>
               </Participants>
       </parameter>
</method>
</request>

Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
       <number>PG2521U</number>
       <date>2016-05-23<<date>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
       <error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named <TABooking> must be specified., missing mandatory attributes, invalid values, no privileges, Error creating TABooking   -->
</response>



TABookingUpdate

Update an existing travel agency reservation/booking. Data must contain the reservation/booking number to be able to identify the document which is to be updated.

Parameters

numberMandatory data. The number of the reservation/booking which is going to be updated.

Example request and response

POST /WebServicesHR/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream

<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="ivan" md5pass="8b29582ce0a1c85dc0c574d218acb900" token="649026C063054A139549200F3C9D01C6" />
<method name="TABookingUpdate">
       <parameter name="TABooking">
               <number>2016-000010</number>                                <!-- (Mandatory and Unique)
               <!--  Parameters are identical to the parameters in TABookingCreate api                               
       </parameter>
</method>
</request>

Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
       <number>2016-000010</number>
</response>

Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
       <error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "TABooking" needed, TABooking's property <number> is required, Can not find TABooking for number: 2016-000010, missing mandatory attributes, invalid values, no privileges,   -->
</response>



TABookingDelete

Delete a desired travel agency reservation/booking.

Parameters

numberMandatory data. The number of the reservation/booking which is going to be updated.

Example request and response

POST /WebServicesHR/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream

<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="ivan" md5pass="8b29582ce0a1c85dc0c574d218acb900" token="649026C063054A139549200F3C9D01C6" />
<method name="TABookingDelete">
       <parameter name="number" value="2016-000011" />
</method>
</request>

Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
</response>

Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
       <error description=""><error/>   <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named <TABooking> is required, Can not find TABooking for number: 2016-000004, Can not delete. Found 3 TABookings with number: 2016-000003 -->
</response>


TABookingList

Get a list of travel agency reservations/bookings for specified criteria.

Parameters

numberDocument number.
statusStatus (Option, Request, Confirm, Personally, Cancelled, Ready, Coupon, Finished)
dateFrom Date from.
dateTo Date to.
documentDateFromDocument date from.
documentDateToDocument date to.
organizerSearch by organizer.
subagentSearch by subagent.
salesServiceSearch by sales service.
bookingPayerSearch by booking payer.
participantsSearch by participients.
addressSearch by booking payer address.
subscriberSearch by subscriber.

Example request and response

POST /WebServicesHR/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream

<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="ivan" md5pass="8b29582ce0a1c85dc0c574d218acb900" token="649026C063054A139549200F3C9D01C6" />
<method name="TABookingList">
       <parameter name="number" value="2016-0001*" />
       <parameter name="costPosition" value="0001" />
       <parameter name="status" value="Request"/>
</method>
</request>


Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
       <TABooking>
                <!-- structure of TABooking data is the same as in TABookingGet
       </TABooking>
       <TABooking>
                <!-- structure of TABooking data is the same as in TABookingGet
       </TABooking>
       ...
</response>

Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
       <error description=""><error/>  <!-- Access denied. User account does not have sufficient privileges for the given request, Invalid search keys, invalid values, no privileges,   -->
</response>

Reference na stran

---
Zadnja sprememba 05.08.2020 8:52:13
© E-RAČUNI d.o.o. 2003-2024