euforic / banking.js

The Missing API for Banks - Get all of your transactions and balances using node

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Discover Card

OverFlow636 opened this issue · comments

Discover made some changes on their ofx server and now im no longer able to access it. Anyone have any good ways to debug?

all i get from the server is

<HTML><HEAD>
<TITLE>Access Denied</TITLE>
</HEAD><BODY>
<H1>Access Denied</H1>

You don't have permission to access "http&#58;&#47;&#47;ofx&#46;discovercard&#46;com&#47;" on this server.<P>
Reference&#32;&#35;18&#46;f6a83d42&#46;148987705&#46;100e5d5d
</BODY>
</HTML>

heres the connection info http://www.ofxhome.com/index.php/institution/view/444

I'm seeing these symptoms too. Some research turned up March 5 ofxforum discussion:

The server is very finicky about the order of the HTTP headers -- this sequence works for me:

POST / HTTP/1.1
Content-Type: application/x-ofx
Host: ofx.discovercard.com
Content-Length: [the length of the request]
Connection: Keep-Alive

What was the fix for this? It's still not working, for me.

Sorry closed on accident, but the fix will require you to replace the superagent api call with a custom http request so you can set all the headers yourself.
see https://github.com/euforic/banking.js/blob/master/lib/banking.js#L98-L104

Ooh... nice, @OverFlow636! I wish I'd seen that fix a couple days ago when I grabbed Discover stuff. I could have verified the fix. Here's hoping for time to do so soon...

@dckc np, ive been doing ofx and discover for a couple years now so i had an easy test case!

these settings should allow you to connect https://github.com/euforic/banking.js/blob/master/test/parsing.js#L41

Darn; I'm getting the same symptoms.

Now I see:

They changed the account # format: Discovr##X##X####X####
-- Overflow636 May 7

Ohai. You again :)

Thanks @OverFlow636 for your fix! I used Money Dance to get the new account format, and your changes restored my account access.

Quick request. Could these latest changes be published to npm? For now, I just ended up including this from GitHub, but it would be great if I could pull it in from npm.

https://www.npmjs.com/package/banking

Thank you again!

@joelika just published v1.1.0 to npm