[Opensim-dev] Asset Server Rest Interface
Stefan Andersson
stefan at tribalmedia.se
Mon Nov 5 09:11:39 UTC 2007
Uh, not entirely sure how to read the current state of the draft, but just wanted to make sure that
POST /assets/new should returd assetid in response, as we can't rely on everybody 'playing nice'.
The Draft should also define the response on all commands; I'd suggest we use an xml posted object response; something like
GET:
The binary asset,
Content-type: xxx
DELETE:
<DeleteResponse>
<Result success="true">Ok</Result>
</DeleteResponse>
Content-type: application/xml
POST:
<CreateResponse>
<Result success="true">Ok</Result>
<AssetId>xxx</AssetId>
</CreateResponse>
Content-type: application/xml
(I'm not entirely sure about the syntax, writing this off the top of my head, but should be something that can be easily deserialized into a c# class)
/Stefan
Date: Mon, 5 Nov 2007 07:49:55 +0100From: tleiades at gmail.comTo: opensim-dev at lists.berlios.deSubject: Re: [Opensim-dev] Asset Server Rest Interface
I'd really like to get this back into the URL itself like it waspreviously. Typically params are not used in REST interfaces, with PATHINFO being the prefered mechanism.
<question>I thought that REST used a mixture of paths and parameters, based on "what makes sense in the current scenario", how ever you define this. </question>
Based on input from this thread I would suggest this interfaceGET /assets/assetid/<value>DELETE /assets/assetid/<value>POST /assets/new - asset server creates new asset - grabs asset it from the serialized asset in the request body.Changes from my first proposal:PUT/UPDATE has been removedThe path now begins with the plural 'asset s'.assetid is a "sub-folder" under "assets", used to retrieve individual assets by assetid./tleiades
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://opensimulator.org/pipermail/opensim-dev/attachments/20071105/0c59c570/attachment-0001.html>
More information about the Opensim-dev
mailing list