Hi everyone, new bubbler here and i’m stuck; I’m putting together a plugin and am having trouble with an authentication call. Here are the instructions from the site who’s API i’m using.
- Prompt for the customer’s username and password - you might want to do this similarly to how we do it on the login page.
- Programmatically call the login API at: https://api.myfantasyleague.com/2019/login?USERNAME=testuser&PASSWORD=testing&XML=1, passing in a valid username and password. You must use HTTPS for this request to avoid exposing the user’s credentials.
- If valid information is passed into the login program, the response will include a <status cookie_name =" cookie_value "…>.
- If invalid information is passed into the login program, it will respond with an <error… status message.
- The above cookie name/value pair should be passed back in as via a standard HTTP header cookie in the format: "Cookie: MFL_USER_ID= cookie_value " in all subsequent calls to the API.
- Note that the cookie value is a Base64 string. That means it may contain the special symbols ‘+’, ‘/’ and/or ‘=’. Depending on your environment, you may need to explicitly URL-escape these symbols before passing them back to us (e.g. converting ‘=’ to ‘%3D’).
When i pass this all outside bubble i can see the user cookie in the source, but when i do it in bubble i don’t see the cookie (even in the “raw data”)
Here’s how i have it set up (i took out my actual user name & pw):
and the “raw data” (after I initialize call with my username/pw)
and here’s what i see when i do it outside bubble (what i want to see IN bubble)
<?xml version="1.0" encoding="utf-8"?> < status MFL_USER_ID=“bRZi3M2bvrD1jwQ=”>OK|
any ideas?
Andy