As @systemseven said what you are looking for is called query params, you can send limit amount of data in you requests, mostly GET calls and access those fields in via params.
Example:
# Let's say we are inside books controller
# GET books?name="alchemist"&author="paulo coelho"
def index
# you can access those other extra fields via params
book_name = params[:name]
book_auhtor = params[:author]
end
Note that the size of data you can send via query params is limited. In the case of a POST call and when sending sensitive information you would want to use headers. You can also access them in the same fashion. After having the value do whatever you want to do.
Tip: add details to the question so that more people can respond and get benefit.
define "robust", do you mean a REST API? a full featured API?
Question is unclear.
Justin
Laravel, Vue.js, CSS, SASS and more...
@t0nylombardi Okay, if that's what you want to do its not do bad. basically you're talking about doing "filters" which in the REST world is typically accomplished via a query string.
let's look at an example, say you have a books api
So you can have a request like /api/v1/books/q?sort=DESC
In your controller for the show method you would need to build a dynamic query. I'm not super familar with rails, but this is the pseduo code
def show start grabbing Books. if there's a url.sort, then do a orderby(title,url.sort) if there's a url.year, then do a where('published_year',url.year) output the results to json endDoes this help at all?