Work.upload.commit

From SafeCreativeWiki

Jump to: navigation, search

Ends an upload-by-chunk process. You must send the SHA-1 hash of the uploaded file to checksum the upload.

This component must be called on an upload API server returned by work.upload.lookup.

This components returns an uploadticket to be used on other components like work.register.

Contents

Info

  • Component name: work.upload.commit
  • Signature: Requires signature using the authkey's private key
  • Timestamp: Requires ztime parameter
  • Authorization level: ADD
  • API trust level: Standard
  • API server: Upload server returned by work.upload.lookup

Parameters

  • authkey*: Authorization key of the work owner
  • ztime*: Z-Timestamp
  • uploadid*: Upload ID obtained from work.upload.lookup
  • length*: Uploaded file size
  • checksum*: Uploaded file SHA-1 hash

* Required parameter

Returns

  • workuploadcommit
    • uploadticket: Upload ticket

Example

REQUEST:

https://upload01.safecreative.org/v2/
?component=work.upload.commit
&authkey=1i5g2aaf2bz09lyo867cuimqg
&checksum=9f9e051a32f6a773335a0cc1d4cf94d17b49faa6
&length=14
&uploadid=3c33a96c-7743-43d0-9614-db70fa46d3ad
&ztime=1271749837035
&signature=f53cf9e21778719e599f6ad39bd85924ecb0bc23

RESPONSE:

<?xml version="1.0" encoding="UTF-8"?>
<workuploadcommit>
  <uploadticket>HvWIbGj7anAW8Nm6LoroakJAPHUjtW_CcZMI8QUOQ1jV2lkRW-jU27ukjPxRvTKk2bL0rOuFow2yiJtmLSvK_9iXZzC_c1CkcJYOSb0Kq8XOzk_CovkO4cfzzNa9NouQVeYoyO6UAXod9xI05wGlboss2jDrN974Z5qgSIjVTLtxDg1mdUFevdbdJXoJr_8T6NJEk3ZnlBXxgq3eEz7NvjvDKp_TDBWuj0UaUOJe_PtcMO0sHrZ5GIfM0yTPHSNE</uploadticket>
</workuploadcommit>
Personal tools
Safe Stamper API