Class: Attachment

Attachment

new Attachment()

Attachment

Properties:
Name Type Description
connector IConnector

the jira connector instance

Source:

Methods

deleteById(options, callbackopt) → {Promise.<any>}

Remove an attachment from an issue.

Parameters:
Name Type Attributes Description
options Object

An object containing options to pass to the Jira API.

Properties
Name Type Description
id string

id

token string

token The token to use for authentication. This token is supplied on a sucessful login. If not supplied, the default token (if set) is used

callback <optional>

if supplied, called with result of api call

Source:
Returns:

result of api call

Type
Promise.<any>

expandForHumans(options, callbackopt) → {Promise.<any>}

Tries to expand an attachment. Output is human-readable and subject to change.

Parameters:
Name Type Attributes Description
options Object

An object containing options to pass to the Jira API.

Properties
Name Type Description
id string

id

token string

token The token to use for authentication. This token is supplied on a sucessful login. If not supplied, the default token (if set) is used

callback <optional>

if supplied, called with result of api call

Source:
Returns:

result of api call

Type
Promise.<any>

expandForMachines(options, callbackopt) → {Promise.<any>}

Tries to expand an attachment. Output is raw and should be backwards-compatible through the course of time.

Parameters:
Name Type Attributes Description
options Object

An object containing options to pass to the Jira API.

Properties
Name Type Description
id string

id

token string

token The token to use for authentication. This token is supplied on a sucessful login. If not supplied, the default token (if set) is used

callback <optional>

if supplied, called with result of api call

Source:
Returns:

result of api call

Type
Promise.<any>

findById(options, callbackopt) → {Promise.<any>}

Returns the meta-data for an attachment, including the URI of the actual attached file.

Parameters:
Name Type Attributes Description
options Object

An object containing options to pass to the Jira API.

Properties
Name Type Description
id string

id

token string

token The token to use for authentication. This token is supplied on a sucessful login. If not supplied, the default token (if set) is used

callback <optional>

if supplied, called with result of api call

Source:
Returns:

result of api call

Type
Promise.<any>

getAttachmentMeta(options, callbackopt) → {Promise.<any>}

Returns the meta information for an attachments, specifically if they are enabled and the maximum upload size allowed.

Parameters:
Name Type Attributes Description
options Object

An object containing options to pass to the Jira API.

Properties
Name Type Description
token string

token The token to use for authentication. This token is supplied on a sucessful login. If not supplied, the default token (if set) is used

callback <optional>

if supplied, called with result of api call

Source:
Returns:

result of api call

Type
Promise.<any>