mattsalt / national-rail-darwin

JS module abstracting national rail's SOAP API
https://www.npmjs.com/package/national-rail-darwin
MIT License
35 stars 19 forks source link

Darwin API still supported? #8

Closed jackdewhurst closed 6 years ago

jackdewhurst commented 6 years ago

Hi,

I've registered with the Darwin LDBWS service and received my token but all calls through national-rail-darwin fail with the following error:

<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><soap:Code><soap:Value>soap:Receiver</soap:Value></soap:Code><soap:Reason><soap:Text xml:lang="en">Unexpected server error</soap:Text></soap:Reason><soap:Detail /></soap:Fault></soap:Body></soap:Envelope>'

The key part being Unexpected server error.

I'm using the CMD tool with the following command darwin db LGX -t {Darwin Token Here}.

Any ideas? Thanks!

mattsalt commented 6 years ago

Hi Jack, thanks for using this tool. Is LGX a valid National Rail CRS code? Can you try with WAT for London Waterloo.

Cheers!

jackdewhurst commented 6 years ago

Hi Matt, thanks for making it. Was not looking forward to interacting with the SOAP API myself!

You're right WAT works, LGX must not be a valid code, I should have tried another.

LGX is currently included in your Readme getDepartureBoard example. Might be worth changing it to WAT or similar?

Cheers

mattsalt commented 6 years ago

Apologies for the late reply, I was on holiday. That's a really good point. I shall update the readme! Thanks for highlighting this.