Also known as
  • Add other possible names for this topic
Raw upload service, mainly for XHR based requests or requests from non-browser clients.
The following rules apply regarding the arguments:
  1. If the document argument is not provided a new one is created
  2. If content-type argument is not provided, the service looks for the HTTP Content-Type header to get the information
  3. If the content-type argument and the HTTP Content-Type header are both provided the form argument takes precedence
  4. If media-type is not provided and either the content-type form argument or the HTTP Content-Type header is provided, the first part is used for media-type information
  5. If media-type form argument is provided it overrides every other source for the information.
  6. If text-encoding is not provided and either the content-type form argument or the HTTP Content-Type header is provided with the charset, that value is used for text-encoding.
  7. If text-encoding form argument is provided it overrides every other source for the information.

The service also creates and executes a MQL query to register the content object in the graph and associate it with an existing document or newly created document as the case may be.

Sample response:

 {
   "status": "200 OK", 
   "result": {
     "length": $length$, 
     "blob_id": "d3e382ebdc06c41ab93b0d25adf132ff787f2cb511e792ed3d9807d44c56a680", 
     "language": "/lang/en", 
     "media_type": "text/plain", 
     "text_encoding": "utf-8", 
     "type": "/type/content", 
     "id": "#4401a8c040004da3800000000002b1a7"
   }
 }
Contents:
With the exception of Wikipedia summaries and some images the content on this page is typically distributed under the Creative Commons Attribution license or Public Domain.

Topic History

Created by skud Dec 17, 2007
Last edited by skud Apr 24, 2008
Gallery add an image edit gallery
There are no images for this topic yet.

Recent Discussions about upload

no recent discussions