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 4003050
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T08:06:19+00:00 2026-05-20T08:06:19+00:00

there been quite good thread on rest urls in SO. Is this a bad

  • 0

there been quite good thread on rest urls in SO.

Is this a bad REST URL?
Understanding REST: Verbs, error codes, and authentication

I see a good resource here as well.

The question is how to represent the create and edit forms urls. The So links doesn’t clearly say that, but the microformats links suggest

GET /people/new  

return a form for creating a new record

GET /people/1/edit

return a form to edit the first record

Not being too religious about using verbs in url, wonder whether there a better option to represent the same.

  • 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-05-20T08:06:19+00:00Added an answer on May 20, 2026 at 8:06 am

    The reason that you will find no consensus on the structure of the URL is because when developers start to understand REST they learn that the structure is irrelevant to the client and is simply a function of aesthetics and server framework implementations.

    However, there is a standardized approach to achieving the goals you are trying to achieve.

    GET /people/1
    Content-Type: application/vnd.hal+xml
    =>
    <resource rel="self" href="/people/1">
      <link rel="edit" href="/people/1/editform"/>
      <link rel="urn://vnd.acme.rels/create" href="/people/createform"/>
      <name>Joe Foo</name>
    </resource>
    

    By embedding links into the response the client can discover the URI needed to perform the desired action. However, to discover the URI, the client needs to have prior knowledge of the link relations (“rel”) that are being used. In this case we used “edit” as that has a well defined behaviour described in the IANA Link Registry. The other link for accessing a create form, as far as I know, does not have a standard name, so I took the liberty of creating a uniquely named link relation.

    As a side note, I happened to use the media type application/hal+xml because it is a flexible hypermedia format but is simple enough to understand without reading too much documentation.

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

Sidebar

Related Questions

Recently there has been quite some hype around all the different mocking frameworks in
Having been a PHP developer on LAMP servers for quite a while, is there
I've been getting these messages in apache error.log for quite a while: [client 217.197.152.228]
I've been reading through quite a few articles on the 'this' keyword when using
There's been quite some hype around the new Reactive Framework in .NET 4.0. While
There has been quite a few image-to-isolated-storage questions here, but I couldn't find a
Its been quite sometime, I've been evaluating ExtJs Grid. So far so good and
If I use the url tag with double quotes: @{/public/images/blue.png} I get this error:
I have been using IDEs like NetBeans for quite sometime. NetBeans has a good
I have to compute at libraries quite often these days, and have been having

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.