0

XML formatting error for Roster Change Put

Ok, after a lot of work, I've finally got almost everything working. However, at this point, when I attempt to send XML for a roster change via PUT, I get this error: Invalid XML PUT. Error at line 2 of input XML. \n <detail/>\n \n

My XML is as follows: " \n date 2012-11-29 304.p.3173 PF 304.p.4612 PG "

I'm sending to this URL: http://fantasysports.yahooapis.com/fantasy/v2/team/304.l.41835.t.12/roster/

I've pulled the XML and the URL from what the library I'm using reports, so I'm pretty sure that those are exactly what are being sent. I'd appreciate any help. Thanks, Matt

by
4 Replies
  • Arghhh... Now I need to figure out how to copy and paste my XML into these forums without it getting edited. The above post is not a correct representation at all.

    0
  • Ok, after a lot of work, I've finally got almost everything working. However, at this point, when I attempt to send XML for a roster change via PUT, I get this error:

    <description>Invalid XML PUT. Error at line 2 of input XML.</description>\n <detail/>\n</error>\n

    My XML is as follows:

    <?xml version='1.0' encoding='UTF-8'?>\n<fantasy_content><roster><coverage_type>date</coverage_type><date>2012-11-29</date><players><player><playerkey>304.p.3173</playerkey><position>PF</position></player><player><playerkey>304.p.4612</playerkey><position>PG</position></player></players></roster></fantasy_content>

    I'm sending to this URL: http://fantasysports.yahooapis.com/fantasy/v2/team/304.l.41835.t.12/roster/

    I've pulled the XML and the URL from what the library I'm using reports, so I'm pretty sure that those are exactly what are being sent. I'd appreciate any help.

    Thanks,

    Matt

    0
  • Ok, my first post to this forum, and I'm an idiot. The problem was simply that I put 'playerkey' instead of 'player_key'

    0
  • Well at least you figured it out!

    0

Recent Posts

in Fantasy Sports API