Request

POST /file/
Content-Type: multipart/form-data; boundary=BoUnDaRyStRiNg
--BoUnDaRyStRiNg
Content-Disposition: form-data; name="uploaded_file"; filename="test file.txt"
Content-Type: text/plain
Test file A
--BoUnDaRyStRiNg--

Response

201 Created
Content-Type: application/json
Location: /file/5231cbe24ab63c53dc90049d/
{
    "size": 11, 
    "stream_link": "/file/test-company/5231cbe24ab63c53dc90049d/s/", 
    "name": "test file.txt", 
    "created_at": "2013-09-12T14:12:48.684324+00:00", 
    "modified_at": "2013-09-12T14:12:50.404520+00:00", 
    "sha1_checksum": "4070d5187d243e397f1d1d9d7ee3801318784a47", 
    "download_link": "/file/test-company/5231cbe24ab63c53dc90049d/d/", 
    "ttl": null, 
    "resource_uri": "/api/v1/file/5231cbe24ab63c53dc90049d/", 
    "id": "5231cbe24ab63c53dc90049d", 
    "issuer": "/api/v1/user/5231cbd64ab63c53dc900474/"
}

Request

POST /file/
Content-Type: multipart/form-data; boundary=BoUnDaRyStRiNg
--BoUnDaRyStRiNg
Content-Disposition: form-data; name="uploaded_file"; filename="test file.txt"
Content-Type: text/plain
Test file B
--BoUnDaRyStRiNg--

Response

201 Created
Content-Type: application/xml; charset=utf-8
Location: /file/5231cbe34ab63c53dc90049e/
<object>
  <stream_link>/file/test-company/5231cbe34ab63c53dc90049e/s/</stream_link>
  <name>test file.txt</name>
  <issuer>/api/v1/user/5231cbd64ab63c53dc900474/</issuer>
  <created_at>2013-09-12T14:12:50.523943+00:00</created_at>
  <download_link>/file/test-company/5231cbe34ab63c53dc90049e/d/</download_link>
  <modified_at>2013-09-12T14:12:51.052011+00:00</modified_at>
  <sha1_checksum>590d401712a70f6965e86ca84f0ba207c5c0108c</sha1_checksum>
  <ttl type="null"/>
  <size type="integer">11</size>
  <id>5231cbe34ab63c53dc90049e</id>
  <resource_uri>/api/v1/file/5231cbe34ab63c53dc90049e/</resource_uri>
</object>

Request

POST /file/
Content-Type: multipart/form-data; boundary=BoUnDaRyStRiNg
--BoUnDaRyStRiNg
Content-Disposition: form-data; name="uploaded_file"; filename="test file.txt"
Content-Type: text/plain
Test file C
--BoUnDaRyStRiNg--

Response

201 Created
Content-Type: text/yaml; charset=utf-8
Location: /file/5231cbe34ab63c53dc90049f/
{created_at: '2013-09-12T14:12:51.080940+00:00', download_link: !!python/unicode '/file/test-company/5231cbe34ab63c53dc90049f/d/',
id: !!python/unicode '5231cbe34ab63c53dc90049f', issuer: !!python/unicode '/api/v1/user/5231cbd64ab63c53dc900474/',
modified_at: '2013-09-12T14:12:51.651986+00:00', name: !!python/unicode 'test file.txt',
resource_uri: !!python/unicode '/api/v1/file/5231cbe34ab63c53dc90049f/', sha1_checksum: !!python/unicode 'd1202ef5d0202ea3befe24796e8e080700b3bb97',
size: 11, stream_link: !!python/unicode '/file/test-company/5231cbe34ab63c53dc90049f/s/',
ttl: null}