# Super newbie here, how to post xml REST data?

**URL:** <https://www.ruby-forum.com/t/super-newbie-here-how-to-post-xml-rest-data/186292>\
**Category:** Rails\
**Created:** [April 3, 2010, 10:19pm UTC](https://www.ruby-forum.com/t/super-newbie-here-how-to-post-xml-rest-data/186292 "2010-04-03T22:19:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![dan](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/eada6e/32.png) [@dan](https://www.ruby-forum.com/u/dan)\
**Post date:** [April 3, 2010, 10:19pm UTC](https://www.ruby-forum.com/t/super-newbie-here-how-to-post-xml-rest-data/186292/1 "2010-04-03T22:19:21Z")

</div>

I have created the simplest rails app using the apple tutorial:  
[http://developer.apple.com/tools/developonrailsleopard.html](http://developer.apple.com/tools/developonrailsleopard.html).

Ok actually I only got halfway through because I really only wanted to  
try out the basic REST services. Long story short I setup a couple  
tables and now I’m trying to use POST to create a table entry with an  
xml doc. Is that possible with the basic 2 minute setup?

Whenever I curl this: curl --data-urlencode  
“AlvinBirthday10000”  
[http://localhost:3000/events.xml](http://localhost:3000/events.xml)

I get a message that it created a record, and it did, it’s just blank  
entries though.

Any ideas on how to do this?

---

<div class="post-metadata">

**Author:** ![dan](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/eada6e/32.png) [@dan](https://www.ruby-forum.com/u/dan)\
**Post date:** [April 4, 2010, 9:56am UTC](https://www.ruby-forum.com/t/super-newbie-here-how-to-post-xml-rest-data/186292/2 "2010-04-04T09:56:28Z")

</div>

On 3 April 2010 12:59, dan [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> [http://localhost:3000/events.xml](http://localhost:3000/events.xml)
> 
> I get a message that it created a record, and it did, it’s just blank  
> entries though.

If you cannot see the problem by code inspection and looking in the  
log you could use ruby-debug or other debugging technique to break  
into your app in create see what data you have. See the rails guide  
on debugging if you don’t know how to do this.

Colin
