Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

/social/share/add/binary/{title}/{description} (POST)

Saves a binary file to the share library.  Typical uses for binary files include widget thumbnail images, widget swf files, and hadoop map reduce jars.

A simple web-based utility is available  for performing many share management activities.

Authentication

Not required (this call gives auth)

Arguments

title (required)
 a title of the binary file you are adding

description (required)
the description of the binary file you are adding

binary (required)
byte steam you want to save

Example

See this example in Java for how to share a file. Note: The java example sets the content-type before sending the object to the API.  The api will store whatever content type it gets sent and use that to return the object when you get it at a later time.  If no content type is set the API cannot determine what the stream of bytes means and will return it with a general content type later.  This may cause issues if you are trying to download the files from the API at a later date if the content type is not set.  A good list of content/media types can be found here: http://en.wikipedia.org/wiki/Internet_media_type

Example Response
{
    response: {
        action: "Share"
        success: true
        message: "New binary share added successfully. ID in data field"
        time: 10
    }
}

 

 

  • No labels