AWS Import/Export
Developer Guide (API Version 2010-06-03)
Print this pageEmail this pageGo to the ForumsView the PDFShare this page on TwitterShare this page on FacebookBookmark this page on DeliciousSubmit this page to RedditSubmit this page to DiggDid this page help you?  Yes  No   Tell us about it...

Creating an Amazon S3 Export Job Using the REST API

If your application requires programmatic access to AWS Import/Export and the AWS SDK does not meet your requirements you can program directly using the REST API.

To create a job using the API

  1. Use a text editor to create a manifest file.

    Following is an example manifest file.

    manifestVersion:2.0
    accessKeyId:AKIAIOSFODNN7EXAMPLE
    deviceId:HD001
    fileSystem:NTFS
    logBucket:mybucket
    operations:
      - exportBucket:mybucket
    returnAddress:
        name:Your Name
        company:Your Company
        street1:Your Street
        street2:Optional 2nd Line for Street
        city:Your City
        stateOrProvince:Your State
        postalCode:Your Postal/Zip Code
        phoneNumber:Your Phone Number
        country:Your Country

    For more information, see Manifest File Options.

  2. URL encode the manifest file.

  3. Sign request.

    For more information, go to Making HTTP Requests in the AWS Import/Export API Reference.

  4. Send a CreateJob request.

    Following is a sample create job request. The request includes the URL encoded manifest file in the body of the request as the Manifest option value. The request also shows the other required string parameters.

    POST / HTTP/1.1
    content-type:application/x-www-form-urlencoded;charset=utf-8
    host: https://importexport.amazonaws.com
    content-length:760
    
    Action=CreateJob&Manifest=manifestVersion%3A2.0%0AaccessKeyId%AKIAIOSFODNN7EXAMPLE%0AdeviceId%3AHD001%0AfileSystem%3ANTFS%0AlogBucket%3Amybucket%0Aoperations%3A%0A%20%20-%20exportBucket%3Amybucket%0AreturnAddress%3A%0A%20%20%20%20name%3AYour%20Name%0A%20%20%20%20company%3AYour%20Company%0A%20%20%20%20street1%3AYour%20Street%0A%20%20%20%20street2%3AOptional%202nd%20Line%20for%20Street%0A%20%20%20%20city%3AYour%20City%0A%20%20%20%20stateOrProvince%3AYour%20State%0A%20%20%20%20postalCode%3AYour%20Postal%2FZip%20Code%0A%20%20%20%20phoneNumber%3AYour%20Phone%20Number%0A%20%20%20%20country%3AYour%20CountryJobType=Export&AWSAccessKeyId=AKIAIOSFODNN7EXAMPLE​SignatureVersion=2&SignatureMethod=HmacSHA256&Version=2010-06-01&Signature=%2FVfkltRBOoSUi1sWxRzN8rw%3D

    AWS Import/Export returns a job ID, the contents of your signature file, and the address to ship your storage device to.

  5. Save the signature value in a file named SIGNATURE in the root directory of your storage device.

  6. Save the JobId value so that you can use it in other requests regarding this job, and the AwsShippingAddress value so you know where to ship your device.

For more information about creating a job using the REST API, go to CreateJob in the AWS Import/Export API Reference. You can validate the manifest and parameter values without creating a job by setting the ValidateOnly parameter to true.