Constructor
new Attachment(client, response)
Instantiate an attachment object.
Parameters:
Name | Type | Description |
---|---|---|
client |
Client | The client that is instantiating the object. |
response |
object | The data for the object. |
- Source:
Members
(private) _client :Client
The client that instantiated this object.
Type:
- Client
- Source:
content_type :String
The type of attachment file content.
Type:
- String
- Source:
created_at :Number
The timestamp of when the attachment was created.
Type:
- Number
- Source:
file_size :Number
The file size of the attachment in bytes.
Type:
- Number
- Source:
file_url :String
The URL of the attachment file.
Type:
- String
- Source:
filename :String
The filename of the attachment file.
Type:
- String
- Source:
for_logged_in_only :Boolean
Whether or not the attachment is for logged in users only.
Type:
- Boolean
- Source:
id :Number
The ID of the attachment.
Type:
- Number
- Source:
is_previewable :Boolean
Whether or not the attachment is previewable.
Type:
- Boolean
- Source:
preview_url :String
The preview URL of the attachment.
Type:
- String
- Source:
third_party_provider :String
The provider of the file if it is hosted on a third party.
Type:
- String
- Source:
third_party_shared_link :String
Type:
- String
- Source:
updated_at :Number
The timestamp of when the attachment was last updated.
Type:
- Number
- Source:
user_id :Number
The ID of the user who created the attachment.
Type:
- Number
- Source:
Methods
getUser() → {Promise.<User>}
Get the user who created the attachment.
- Source:
Returns:
- Type
- Promise.<User>