Image Attachment in python SDK

Hi all,
I have the below document which got synced from couchbase lite (iOS).
{ "Date": "00170925591601", "ID": "tmp652844", "InvoiceNumber": "tmp652844", "Supplier": "Temp", "_attachments": { "ImageAttachment": { "content_type": "image/jpeg", "digest": "sha1-8uKi9mywFwvoP8qNrTGEMWemgKU=", "length": 1898952, "revpos": 2, "stub": true } }, "channels": [ "payment" ], "type": "invoice" }

How do I get the attachment from the document? I need to render the image attachment in the HTML. I believe the above attachment data is only meta data.
It would be of great help if someone can help me with this.


You can use the GET /{db}/{doc}/{attachment} endpoint on Sync Gateway to render the image in an <img />.
I read python SDK in the title of the question. Are you referring to the Python SDK for Couchbase Server or an HTTP client for the Sync Gateway REST API ?