Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7976531
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T08:55:58+00:00 2026-06-04T08:55:58+00:00

Lets say I have resource representing images PUT /images/[id] with path -> going to

  • 0

Lets say I have resource representing images

PUT /images/[id] with path -> going to create me a new image resource if already present updates my resource

POST /images/[id] -> to change or update a resource Ex., image name

DELETE /images/[id] -> this will delete my resource

GET /images/[id] -> gets me the image details

Now the actual question. what if I need to add additional actions to the images ?. Lets say the image resource will respond to a red eye reduction action or any other like crop, resize

So how these action are considered and how this should be called in restful interface ?

/images/[id]/remove_redeye

/images/[id]/crop

/images/[id]/resize

Is the above calls valid in restful interface ? I am confused about what should these action should be considered(PUT POST)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T08:56:00+00:00Added an answer on June 4, 2026 at 8:56 am

    “Remove redeye”, “crop”, and “resize” all sound like actions which “change or update a resource.” They would belong in a PUT action. (I think you mixed up PUT and POST in your question, refer to the verbs listed at w3c.)

    How you convey the nature of the action depends on what’s being POSTed. For example, if we were talking about a form sitting on top of a database record, the POST would simply be the data for that record. It wouldn’t be necessary to specify which fields are being changed because the whole object is being POSTed in its new state.

    Is the whole object being POSTed in its new state in this case? Or does the object live only server-side and the interface is just sending a request for some kind of action? It sounds like the latter to me, based on the information provided.

    In that case you can include in the POST some more information about the action. Keep in mind that a POST can contain key/value pairs in its data and/or a larger and more complex POST body. This body can contain XML, for example, specifying a lot more information for the server to use in processing the request. Maybe something like this:

    <image id="123">
        <resize>
            <width>200</width>
            <height>200</height>
        </resize>
    </image>
    

    This could even allow multiple actions within the same request, allowing the user to try various things client-side before committing them all in a single unit of work server-side. How you’d process that or if it’s even applicable in this case is up to you, of course.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Lets say I have the following DataMapper resources: class Post include DataMapper::Resource has n,
Consider that I have 1 resource and 2 urls (let's say new one and
Lets say I have a message resource. Somewhere in the html I have: <%=
I have folder inside reource folder lets say resource->folder A->61.png so how to access
How can I model roles views restfully? Lets say I have a resource that
Lets say we have two Threads A, B and one Mutex (Shared resource) M.
In my iPhone project I want to add a new resource folder. Lets say
i have a table of resources (lets say cars) which i want to claim
Lets say have this immutable record type: public class Record { public Record(int x,
Lets say I have this code: <?php class hello { var $greeting = hello;

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.