Skip to content

Commit

Permalink
Merge pull request #162 from holidayextras/ci-branch
Browse files Browse the repository at this point in the history
run on pr
  • Loading branch information
hx-markterry authored Jan 19, 2024
2 parents 7860815 + 276db44 commit fe40a26
Show file tree
Hide file tree
Showing 11 changed files with 160 additions and 158 deletions.
23 changes: 11 additions & 12 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,6 @@ on:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
workflow_call:
secrets:
GH_TOKEN:
description: 'A github oauth token used for deployment'
required: true

jobs:
test_and_deploy:
Expand All @@ -34,10 +29,14 @@ jobs:
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: bundle exec rake
- uses: actions4git/setup-git@v1
- name: Run deploy
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
# only deploy on master pushes
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
run: bundle exec rake deploy
- name: Setup Git
uses: actions4git/setup-git@v1
- name: Commit generated pages
# only update docs on non master
if: ${{ github.ref != 'refs/heads/master' }}
run: |
bundle exec rake dist
cd docs
git status
git commit -am "Update dist"
git push origin HEAD:${{ github.head_ref }} --force
12 changes: 4 additions & 8 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,8 @@ task :html_proofer do
HTMLProofer.check_directory("./_site", options).run
end

desc "Deploy site to production"
task :deploy do
sh "rm -rf docs"
sh "cp -a _site docs"
Dir.chdir('docs')
sh "git status"
sh "git commit -am 'Deploy'"
sh "git push"
desc "Update production site content"
task :dist do
sh "rm -rf docs/*"
sh "cp -a _site/* docs/"
end
2 changes: 1 addition & 1 deletion docs/feed.xml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.9.2">Jekyll</generator><link href="/feed.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2022-09-30T11:58:00+00:00</updated><id>/feed.xml</id><title type="html">Holiday Extras API</title><subtitle>Documentation to give to partners who would like to integrate with our API.
<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.9.3">Jekyll</generator><link href="/feed.xml" rel="self" type="application/atom+xml" /><link href="/" rel="alternate" type="text/html" /><updated>2024-01-19T22:06:18+00:00</updated><id>/feed.xml</id><title type="html">Holiday Extras API</title><subtitle>Documentation to give to partners who would like to integrate with our API.
</subtitle></feed>
4 changes: 2 additions & 2 deletions docs/hxapi/carhire/availability/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@ <h2 id="request">Request</h2>
</code></pre></div></div>

<p>Example request:</p>
<ul class="uk-tab" data-uk-switcher="{connect:'#f95ef8f7-3dee-4b37-bd60-5c588943b189'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#ce895ad0-90a5-4149-a6f9-022b3da70bbe'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="f95ef8f7-3dee-4b37-bd60-5c588943b189" class="uk-switcher uk-margin">
<ul id="ce895ad0-90a5-4149-a6f9-022b3da70bbe" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/v1/sandbox/carHire/products?key=1&amp;From=06NOV16&amp;ArrivalTime=1200&amp;To=13NOV&amp;DepartTime=1600&amp;PickupLocation=FL965&amp;DropoffLocation=FL965&amp;DateOfBirth=1990-10-13
Expand Down
9 changes: 8 additions & 1 deletion docs/hxapi/errors/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@
<div class="panel-body">
<h1 id="errors">Errors</h1>

<p>List of errors that can be returned from the API. Your application can handle the error by code.</p>
<p>List of errors that can be returned from the API.</p>

<p>Please ensure that your application can handle the errors by inspecting the error code only, do not use the error message as this is for debugging purposes only.</p>

<table>
<thead>
Expand Down Expand Up @@ -121,6 +123,11 @@ <h1 id="errors">Errors</h1>
<td>Sorry, we have no availability for the dates and times selected.</td>
<td>Availability lookup does not find availability for dates and times provided in the request.</td>
</tr>
<tr>
<td>0037</td>
<td>Sorry, the availability timeout has been reached. Please try again.</td>
<td>Availability lookup does not find availability due to end supplier latency.</td>
</tr>
<tr>
<td>0051</td>
<td>Invalid Booking Number</td>
Expand Down
20 changes: 10 additions & 10 deletions docs/hxapi/parking/av/airport/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,15 +57,15 @@ <h3 id="endpoint">Endpoint</h3>

<p>For example, for London Gatwick the endpoint is:</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#543f3e36-9873-4795-ae36-8dd634b7d00f'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#15df075e-9beb-4245-be20-edd4cd371be1'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="543f3e36-9873-4795-ae36-8dd634b7d00f" class="uk-switcher uk-margin">
<ul id="15df075e-9beb-4245-be20-edd4cd371be1" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/v1/carpark/LGW
Expand Down Expand Up @@ -450,15 +450,15 @@ <h2 id="worked-examples">Worked Examples</h2>

<h3 id="uk-products-availability-request">UK Products Availability Request</h3>

<ul class="uk-tab" data-uk-switcher="{connect:'#a458ea14-9435-42b9-8d48-72751d78f106'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#1fdd2ef8-2026-4cd6-ad7e-c01073ca6a0b'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="a458ea14-9435-42b9-8d48-72751d78f106" class="uk-switcher uk-margin">
<ul id="1fdd2ef8-2026-4cd6-ad7e-c01073ca6a0b" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/carpark/LGW?ABTANumber=YourABTANumber&amp;Password=YourPassword&amp;Initials=YourInitials&amp;key=YourKey&amp;token=YourToken&amp;ArrivalDate=2020-01-07&amp;ArrivalTime=1200&amp;DepartDate=2020-01-08&amp;DepartTime=1200&amp;NumberOfPax=1
Expand All @@ -477,15 +477,15 @@ <h3 id="uk-products-availability-response">UK Products Availability Response</h3

<p>NB: This is a shortened example compiled from a full availability response.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#477c889a-bcf2-479f-8b8b-8d4b1229a023'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#430b6d88-3fd4-4b3a-af0d-414e373c2772'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="477c889a-bcf2-479f-8b8b-8d4b1229a023" class="uk-switcher uk-margin">
<ul id="430b6d88-3fd4-4b3a-af0d-414e373c2772" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="cp">&lt;?xml version="1.0"?&gt;</span>
Expand Down Expand Up @@ -713,15 +713,15 @@ <h3 id="uk-products-availability-response">UK Products Availability Response</h3

<h3 id="european-products-availability-request">European Products Availability Request</h3>

<ul class="uk-tab" data-uk-switcher="{connect:'#714a56b5-e951-475d-bed0-c2345796b44e'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#0af0e09a-8eb5-4ab2-95c9-c9e13672a51b'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="714a56b5-e951-475d-bed0-c2345796b44e" class="uk-switcher uk-margin">
<ul id="0af0e09a-8eb5-4ab2-95c9-c9e13672a51b" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/carpark/MUC?ABTANumber=YourABTANumber&amp;Password=YourPassword&amp;Initials=YourInitials&amp;key=YourKey&amp;token=YourToken&amp;ArrivalDate=2017-12-01&amp;ArrivalTime=1200&amp;DepartDate=2017-12-08&amp;DepartTime=1200&amp;NumberOfPax=1&amp;System=ABG&amp;lang=en
Expand All @@ -740,15 +740,15 @@ <h3 id="european-products-availability-response">European Products Availability

<p>NB: This is a shortened example compiled from a full availability response.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#e529811b-68e2-46da-a97c-9f2ad6167f37'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#a9ba7d38-a621-4e12-925c-ae916b360a09'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="e529811b-68e2-46da-a97c-9f2ad6167f37" class="uk-switcher uk-margin">
<ul id="a9ba7d38-a621-4e12-925c-ae916b360a09" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="cp">&lt;?xml version="1.0"?&gt;</span>
Expand Down
28 changes: 14 additions & 14 deletions docs/hxapi/productlibrary/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ <h2 id="available-fields">Available Fields</h2>

<p>The available fields vary by product type. For each product type there is a recommended list of fields which should be requested to get the information required to effectively sell the product.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#5c43a2e1-3cf0-4b1e-be7b-df8a29612592'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#37fd8c1c-3d41-4c4d-9175-219d67db9689'}">

<li class="uk-active"><a href="#">Parking</a></li>

Expand All @@ -105,7 +105,7 @@ <h2 id="available-fields">Available Fields</h2>

</ul>

<ul id="5c43a2e1-3cf0-4b1e-be7b-df8a29612592" class="uk-switcher uk-margin">
<ul id="37fd8c1c-3d41-4c4d-9175-219d67db9689" class="uk-switcher uk-margin">

<li>
<h4 id="recommended">Recommended</h4>
Expand Down Expand Up @@ -976,7 +976,7 @@ <h3 id="example-1---default-response">Example 1 - Default Response</h3>

<h4 id="request">Request</h4>

<ul class="uk-tab" data-uk-switcher="{connect:'#126aad18-8704-474f-aec9-68443729d4b5'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#86ff1dd5-9ec3-4d0c-bdc8-74d993419ba0'}">

<li class="uk-active"><a href="#">Live (XML)</a></li>

Expand All @@ -988,7 +988,7 @@ <h4 id="request">Request</h4>

</ul>

<ul id="126aad18-8704-474f-aec9-68443729d4b5" class="uk-switcher uk-margin">
<ul id="86ff1dd5-9ec3-4d0c-bdc8-74d993419ba0" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/v1/product/LGW4/lite?token=000015778&amp;key=mytestkey
Expand Down Expand Up @@ -1016,15 +1016,15 @@ <h4 id="request">Request</h4>

<h4 id="response">Response</h4>

<ul class="uk-tab" data-uk-switcher="{connect:'#a9ff23a5-e41d-4a34-8ce5-5ecbd0db326b'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#8041c502-f59e-410e-bbcc-b46237bdb419'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="a9ff23a5-e41d-4a34-8ce5-5ecbd0db326b" class="uk-switcher uk-margin">
<ul id="8041c502-f59e-410e-bbcc-b46237bdb419" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="cp">&lt;?xml version="1.0"?&gt;</span>
Expand Down Expand Up @@ -1411,7 +1411,7 @@ <h3 id="example-2---restricted-field-list">Example 2 - Restricted field list</h3

<h4 id="request-1">Request</h4>

<ul class="uk-tab" data-uk-switcher="{connect:'#ee07f229-cbe9-41e2-94c9-0712a82fabe3'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#039907cd-15f5-4cc0-823f-f0107a2467c1'}">

<li class="uk-active"><a href="#">Live (XML)</a></li>

Expand All @@ -1423,7 +1423,7 @@ <h4 id="request-1">Request</h4>

</ul>

<ul id="ee07f229-cbe9-41e2-94c9-0712a82fabe3" class="uk-switcher uk-margin">
<ul id="039907cd-15f5-4cc0-823f-f0107a2467c1" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/v1/product/LGW4/lite?token=000015778&amp;key=mytestkey&amp;fields=name,longitude,latitude
Expand Down Expand Up @@ -1451,15 +1451,15 @@ <h4 id="request-1">Request</h4>

<h4 id="response-1">Response</h4>

<ul class="uk-tab" data-uk-switcher="{connect:'#7bfce292-115b-43c9-8348-75573103fb6b'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#dbbf5ca0-6d1c-483b-9fe2-fb61fbd1dc0d'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="7bfce292-115b-43c9-8348-75573103fb6b" class="uk-switcher uk-margin">
<ul id="dbbf5ca0-6d1c-483b-9fe2-fb61fbd1dc0d" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="cp">&lt;?xml version="1.0"?&gt;</span>
Expand Down Expand Up @@ -1520,7 +1520,7 @@ <h4 id="request-2">Request</h4>

<p>Requests for German products return a different set of fields. Explanation of fields not currently available.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#6c29dc6e-f26d-4620-9062-374b9790da53'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#1d34804b-9186-4b3d-a6a9-b7fdbfc3f64b'}">

<li class="uk-active"><a href="#">Live (XML)</a></li>

Expand All @@ -1532,7 +1532,7 @@ <h4 id="request-2">Request</h4>

</ul>

<ul id="6c29dc6e-f26d-4620-9062-374b9790da53" class="uk-switcher uk-margin">
<ul id="1d34804b-9186-4b3d-a6a9-b7fdbfc3f64b" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https://api.holidayextras.co.uk/v1/product/FRA0?key=mytestkey
Expand Down Expand Up @@ -1560,15 +1560,15 @@ <h4 id="request-2">Request</h4>

<h4 id="response-2">Response</h4>

<ul class="uk-tab" data-uk-switcher="{connect:'#adb2c5e6-c403-40fd-9d32-a1d675604c02'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#e1d78a78-68cf-4b83-9cc5-7edd090b2b51'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="adb2c5e6-c403-40fd-9d32-a1d675604c02" class="uk-switcher uk-margin">
<ul id="e1d78a78-68cf-4b83-9cc5-7edd090b2b51" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="cp">&lt;?xml version="1.0"?&gt;</span>
Expand Down
16 changes: 8 additions & 8 deletions docs/hxapi/transfers/av/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -847,15 +847,15 @@ <h3 id="worked-examples">Worked Examples</h3>
<h4 id="airport-to-tti">Airport to TTI</h4>
<h5 id="request">Request</h5>

<ul class="uk-tab" data-uk-switcher="{connect:'#9ae5ba92-8d7c-4471-8f4b-70049ac2a121'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#e3e399d1-81e7-4dcd-8ac2-b97b14540b93'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="9ae5ba92-8d7c-4471-8f4b-70049ac2a121" class="uk-switcher uk-margin">
<ul id="e3e399d1-81e7-4dcd-8ac2-b97b14540b93" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https:///api.holidayextras.co.uk/v1/transfers/search?ABTANumber=YourABTANumber&amp;Password=YourABTANumber&amp;Initials=YourInitials&amp;key=YourKey&amp;token=YourToken&amp;PickUp=ALC&amp;PickUpType=IATA&amp;DropOffType=TTI&amp;DropOff=10147575&amp;FromDate=2022-03-16&amp;FromTime=1115&amp;ReturnDate=2022-03-23&amp;ReturnTime=1115&amp;Adults=2&amp;OutFlight=U28605&amp;ReturnFlight=U28602
Expand All @@ -874,15 +874,15 @@ <h5 id="response">Response</h5>

<p>NB: This is a shortened example compiled from a full availability response.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#908b1274-7d82-46c9-88a1-f8dd88fac318'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#4cd0c768-8e56-454b-9b91-4f447a107ab7'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="908b1274-7d82-46c9-88a1-f8dd88fac318" class="uk-switcher uk-margin">
<ul id="4cd0c768-8e56-454b-9b91-4f447a107ab7" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">&lt;API_Reply</span> <span class="na">Product=</span><span class="s">"Transfers"</span> <span class="na">RequestCode=</span><span class="s">"1"</span> <span class="na">Result=</span><span class="s">"OK"</span> <span class="na">cached=</span><span class="s">"1"</span> <span class="na">expires=</span><span class="s">"2021-12-07 13:06:41"</span><span class="nt">&gt;</span>
Expand Down Expand Up @@ -1117,15 +1117,15 @@ <h5 id="response">Response</h5>

<h4 id="airport-to-postal-address">Airport to Postal Address</h4>
<h5 id="request-1">Request</h5>
<ul class="uk-tab" data-uk-switcher="{connect:'#a8ada725-a887-4ce2-9bca-2dd31f2e6d53'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#0ee83a66-59c5-43a2-8f90-914fdc20ad9a'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="a8ada725-a887-4ce2-9bca-2dd31f2e6d53" class="uk-switcher uk-margin">
<ul id="0ee83a66-59c5-43a2-8f90-914fdc20ad9a" class="uk-switcher uk-margin">

<li>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>https:///api.holidayextras.co.uk/v1/transfers/search?ABTANumber=YourABTANumber&amp;Password=YourABTANumber&amp;Initials=YourInitials&amp;key=YourKey&amp;token=YourToken&amp;PickUp=ALC&amp;PickUpType=IATA&amp;DropOffType=postal-address&amp;DropOffName=Hotel%20Rural%20Castillo%20De%20Biar&amp;DropOffAddress[0]=Carretera%20de%20Banyeres&amp;DropOffAddress[1]=s/n&amp;DropOffTown=%20Biar&amp;DropOffCounty=Alicante&amp;DropOffPostcode=03410&amp;DropOffCountryCode=ES&amp;DropOffLongitude=-0.76832006&amp;DropOffLatitude=38.63852215&amp;Adults=2&amp;FromDate=2022-03-16&amp;FromTime=1115&amp;ReturnDate=2022-03-23&amp;ReturnTime=1115&amp;OutFlight=U28605&amp;ReturnFlight=U28602
Expand All @@ -1144,15 +1144,15 @@ <h5 id="response-1">Response</h5>

<p>NB: This is a shortened example compiled from a full availability response.</p>

<ul class="uk-tab" data-uk-switcher="{connect:'#38757cef-77cb-4a01-9bb8-25191be729fc'}">
<ul class="uk-tab" data-uk-switcher="{connect:'#9b3afe44-1112-48b6-81fc-7bc965dc46cb'}">

<li class="uk-active"><a href="#">XML</a></li>

<li><a href="#">JSON</a></li>

</ul>

<ul id="38757cef-77cb-4a01-9bb8-25191be729fc" class="uk-switcher uk-margin">
<ul id="9b3afe44-1112-48b6-81fc-7bc965dc46cb" class="uk-switcher uk-margin">

<li>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">&lt;API_Reply</span> <span class="na">Product=</span><span class="s">"Transfers"</span> <span class="na">RequestCode=</span><span class="s">"1"</span> <span class="na">Result=</span><span class="s">"OK"</span> <span class="na">cached=</span><span class="s">"1"</span> <span class="na">expires=</span><span class="s">"2021-12-07 16:31:35"</span><span class="nt">&gt;</span>
Expand Down
Loading

0 comments on commit fe40a26

Please sign in to comment.