It is possible but the way is a bit different from you suggested.
Firstly to answer your questions: When you include that "data fetcher" script from site A on site B, it will be executed on Site B. It will try to perform ajax call to site A and will fail because of same-origin policy.
The way to accomplish this is via JSONP.
You need to first create a php page, which produces some json data and calls a predefined javascript function like:
fetcher.php:
<?php
$data = fetchCustomerBookings($_GET['customerid']);
echo "renderBookings(".json_encode($data).")";
?>
Then you can include this script on Site B with an ordinary script tag like:
<script type="text/javascript" src="http://site-a.com/fetcher.php?customerid=XXX"></script>
There you need to have defined renderBookings javascript function already.