restful architecture - How to build a REST API without resource? -


I want to build a lightweight web service, customers should use this function to do a different job. I have read a lot about the concept of REST and now I have a problem identifying a resource.

So far, I have found some examples that are easy to understand and "product", "book is such a clear resource" or something like that. In my case, I do not want to acquire, create or delete anything from a database. I just want to do one thing.

Example: A client should send AOI access token (instead of user name and password) and url. If the token is valid then the server (API) starts a download and uploads it to a cloud service. How should I do this with the REST API? All sources show that actions should not be used in the URI, generally I would use a method named "uploadMediaContentToCloud" or something like that. There is no representation of the media content in my database. Action is neither a fetch nor a creation, so I definitely do not have to use GET or Post or ....

For any advice or article, I must read. I am grateful.

Edit: I just want to make sure that upload is just one example. The server should work (download some, upload some, run a script etc.) and my question is that if I should not use the verb in the URI, then I want to design / design the URI.

You are fine with any language to handle, you can upload the file to the web service You can find discussions about applying. There is a real script to implement the upload function.

Edit:

When you can not serve as a resource, provide resources of the restore API) For example Etc. With services such as Twitter API and Echine APIs can be found. Yuri is a best practice blog for design.


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -