API says "title must not be blank" even when title is set.
Hi Folks -
I'm POSTing to the API and getting a 422 that reports the title field must not be blank, and yet, the title field is not blank. Here's what I'm sending:
<?xml version="1.0"?>
<ticket><title>as</title><body>
*User's Email: [email blocked]
*User's Username: Chris Vander Mey
*User's Authentication Type (1,2,3)=(fb,goog,evernote): 1
*Device Type: iPhone Simulator
*Device OS Version: 6.1
*App Version: 0.0.25
*Build Number: 0.0.25</body><tag>userbug</tag><assigned-user-id type="integer">211192</assigned-user-id></ticket>
The Response Body:
<?xml version="1.0" encoding="UTF-8"?>
<errors>
<error>Title can't be blank</error>
</errors>
Any suggestions?
Discussions are closed to public comments.
If you need help with Lighthouse please
start a new discussion.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by chris (at scale... on 15 Mar, 2013 06:54 PM
Hm, the markup ate my XML. Trying again...
2 Posted by Julien on 15 Mar, 2013 07:13 PM
Hi Chris,
You're missing the 'Content-Type: application/xml' header in your call.
Let me know how that goes.
3 Posted by chris (at scale... on 15 Mar, 2013 09:07 PM
That did it! Thanks. You might want to edit the page that references the 422 and consider adding the Content-Type header to the error message. I know it's in your docs somewhere, but it might save you an email or two...
Thanks!
Julien closed this discussion on 15 Mar, 2013 09:31 PM.