adobe / da-admin

Apache License 2.0
0 stars 4 forks source link

Create Version should return location and users #45

Open bosschaert opened 3 months ago

bosschaert commented 3 months ago

Expected Behaviour

The Create Version API should return the URL of the version created in the Location header.

It should also return the associated user(s) with the version in the metadata.

auniverseaway commented 3 months ago

FWIW, I don't think this should be stored in the header. I think this should be in the body. It's pretty un-conventional to get information client-side from a header object.

{
  "url": "https://...",
  "users": [{"email": "anonymous"}],
  "label": "My new version",
}

My expectation would be that the format matches what the list API gives.

auniverseaway commented 3 months ago

I also noticed that we are not sending the fully qualified domain... this means the client has to do more work:

Screenshot 2024-05-20 at 2 52 14 PM

URL is not actually a URL in the above screenshot. I would follow Helix conventions in that we always try to provide fully qualified URLs.