@ibm-cloud/cloudant - v0.12.5
    Preparing search index...

    Class Attachment

    Schema for an attachment.

    Index

    Constructors

    Properties

    contentType?: string

    Attachment MIME type.

    data?: Buffer

    Base64-encoded content. Available if attachment content is requested by using the query parameters attachments=true or atts_since. Note that when used with a view or changes feed include_docs must also be true.

    digest?: string

    Content hash digest. It starts with prefix which announce hash type (e.g. md5-) and continues with Base64-encoded hash digest.

    encodedLength?: number

    Compressed attachment size in bytes. Available if content_type was in list of compressible types when the attachment was added and the query parameter att_encoding_info is true. Note that when used with a view or changes feed include_docs must also be true.

    encoding?: string

    Compression codec. Available if content_type was in list of compressible types when the attachment was added and the and the query parameter att_encoding_info is true. Note that when used with a view or changes feed include_docs must also be true.

    follows?: boolean

    True if the attachment follows in a multipart request or response.

    length?: number

    Real attachment size in bytes. Not available if inline attachment content requested.

    revpos?: number

    Revision number when attachment was added.

    stub?: boolean

    Has true value if object contains stub info and no content. Otherwise omitted in response.

    Methods