public-transport / hafas-client

JavaScript client for HAFAS public transport APIs.
ISC License
278 stars 54 forks source link

add Arriva UK endpoint #236

Closed derhuerst closed 1 year ago

derhuerst commented 3 years ago
{
    // https://gist.github.com/PDesire/3dab828612a20e80d539af2b5387b9cc#arriva-uk
    auth: {type: 'AID', aid: 'a4r2b3i8x2n9f6l0'},
    client: {type: 'AND', id: 'ARRIVA', name: 'ARRIVA'},
    endpoint: 'http://arriva-uk.hafas.de/bin/mgate.exe',
    defaultLanguage: 'en',

    locale: 'de-DE',
    timezone: 'Europe/London',
    ver: '1.18',
}

With the config above, the endpoint returns a PARSE error.

./tools/debug-cli/cli.js arriva-uk locations 'london'
# {"lang":"en","svcReqL":[{"cfg":{"polyEnc":"GPA"},"meth":"LocMatch","req":{"input":{"loc":{"type":"ALL","name":"london?"},"maxLoc":5,"field":"S"}}}],"client":{"type":"AND","id":"ARRIVA","name":"ARRIVA"},"ver":"1.18","auth":{"type":"AID","aid":"a4r2b3i8x2n9f6l0"}}
# {"ver":"","lang":"eng","err":"PARSE","svcResL":[]}
derhuerst commented 1 year ago

I think this endpoint has been shut off.