Person.GetPicture

Summary

Returns the image data for the person with the given slug.

Signatures

Web Service Method Signature
Stream GetPicture(string apiKey, string site, string slug, int size)
REST Signature
/rest/person/{slug}/Picture?apiKey={apiKey}&site={site}&size={size}

Return Value

The image for the person. When requested via the REST API the image data is returned in the HTTP response stream as a JPEG encoded image. When requested via the web services, a stream is returned from which the image data can be read.

Arguments

apiKey

Your API key. For more information see here.

site

The site the API should be executed against, e.g. www.ditto.net.

slug

The slug of the user to get the image for.

size (Optional)

The size of the image in pixels to return. This is both the height and width, as user images are always stored as in a square format.

If this value is omitted or set to 0, it defaults to 80.

The minimum allowed value is 10 and the maximum is 300.

REST Example

http://api.ditto.net/rest/person/Mike/Picture?apiKey=xxxx&site=www.ditto.net&size=100