Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Restful API On Grape

2,080 views

Published on

a topic I shared in Xi'an OpenParty 2013/07/27

Published in: Technology
  • Be the first to comment

Restful API On Grape

  1. 1. Copyright 2010, Intridea Inc. All Rights Reserved. RESTful API On Grape andy@intridea.com 2013/07/27 @XianOpenParty
  2. 2. Copyright 2010, Intridea Inc. All Rights Reserved. Introduction 王要弟 == Andy Wang WangYaodi.com Senior Ruby/Rails Enginner @intridea Weibo/Twitter/Github/RubyChina: @yorzi
  3. 3. Copyright 2010, Intridea Inc. All Rights Reserved. What’s Grape?
  4. 4. Copyright 2010, Intridea Inc. All Rights Reserved. Generalized Rapid APIs Erector https://github.com/intridea/grape/blob/master/README.md
  5. 5. Copyright 2010, Intridea Inc. All Rights Reserved. “An opinionated micro-framework for creating RESTful APIs in Ruby”
  6. 6. Copyright 2010, Intridea Inc. All Rights Reserved. REpresentational State Transfer http://www.ruanyifeng.com/blog/2011/09/restful.html
  7. 7. Copyright 2010, Intridea Inc. All Rights Reserved. Grape APIs are Rack applications
  8. 8. Copyright 2010, Intridea Inc. All Rights Reserved. http://guides.rubyonrails.org/rails_on_rack.html
  9. 9. Copyright 2010, Intridea Inc. All Rights Reserved. Basic API
  10. 10. Copyright 2010, Intridea Inc. All Rights Reserved.
  11. 11. Copyright 2010, Intridea Inc. All Rights Reserved. Add Prefix
  12. 12. Copyright 2010, Intridea Inc. All Rights Reserved. Add Namespace
  13. 13. Copyright 2010, Intridea Inc. All Rights Reserved. Add Version
  14. 14. Copyright 2010, Intridea Inc. All Rights Reserved. Authentication
  15. 15. Copyright 2010, Intridea Inc. All Rights Reserved. Use Helpers
  16. 16. Copyright 2010, Intridea Inc. All Rights Reserved. Raise Error
  17. 17. Copyright 2010, Intridea Inc. All Rights Reserved. Exception Handling
  18. 18. Copyright 2010, Intridea Inc. All Rights Reserved. JSONP & CORS
  19. 19. Copyright 2010, Intridea Inc. All Rights Reserved. Rabl Template
  20. 20. Copyright 2010, Intridea Inc. All Rights Reserved. Cookies
  21. 21. Copyright 2010, Intridea Inc. All Rights Reserved. Redirecting
  22. 22. Copyright 2010, Intridea Inc. All Rights Reserved. Logging
  23. 23. Copyright 2010, Intridea Inc. All Rights Reserved. https://github.com/intridea/grape/blob/master/README.md More Features
  24. 24. Copyright 2010, Intridea Inc. All Rights Reserved. Run Rack App
  25. 25. Copyright 2010, Intridea Inc. All Rights Reserved. Work with Rails
  26. 26. Copyright 2010, Intridea Inc. All Rights Reserved. Resources https://github.com/intridea/grape/wiki
  27. 27. Copyright 2010, Intridea Inc. All Rights Reserved. Question?
  28. 28. Copyright 2010, Intridea Inc. All Rights Reserved. Thank You!

×