-
-
Notifications
You must be signed in to change notification settings - Fork 128
CSteamSharedFile
A class which represents a shared file on Steam, including artwork, screenshots, and guides. This class cannot be
instantiated directly; it must be received from a call to
getSteamSharedFile
.
The shared file's unique ID.
A value from the ESharedFileType enum.
You can compare values like this:
const SteamCommunity = require('steamcommunity');
let sharedFile = getSomeSharedFileSomehow();
if (sharedFile.type == SteamCommunity.ESharedFileType.Screenshot) {
console.log('This file is a screenshot');
}
The ID of the Steam app to which this shared file belongs.
A SteamID
object representing the account that owns this shared file.
A string containing a human-readable representation of the size of the file, if applicable.
A Date
object representing the date and time when this file was posted.
A string containing a human-readable representation of the resolution of the file, if applicable.
A count of how many unique people have viewed this file.
A count of how many people have favorited this file.
A count of how many people have voted this file up.
A count of how many people have rated this file, if the file is a guide.
A bool indicating whether the logged-in account has upvoted this file.
A bool indicating whether the logged-in account has downvoted this file.
-
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Adds this shared file to your favorites.
You can also call this directly on a SteamCommunity
instance, like so:
community.favoriteSharedFile(sharedFileId, fileAppId, callback);
-
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Removes this shared file from your favorites.
You can also call this directly on a SteamCommunity
instance, like so:
community.unfavoriteSharedFile(sharedFileId, fileAppId, callback);
-
message
- The message you want to post as a comment -
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Posts a comment on this shared file.
You can also call this directly on a SteamCommunity
instance, like so:
community.postSharedFileComment(sharedFileOwnerSteamId, sharedFileId, message, callback);
-
cid
- The ID of the comment you want to delete -
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Deletes a comment on this shared file, provided you have privilege to do so.
You can also call this directly on a SteamCommunity
instance, like so:
community.deleteSharedFileComment(sharedFileOwnerSteamId, sharedFileId, cid, callback);
-
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Subscribes to this shared file's comment section.
You can also call this directly on a SteamCommunity
instance, like so:
community.subscribeSharedFileComments(sharedFileOwnerSteamId, sharedFileId, callback);
-
callback
- Optional. Called when the request completes.-
err
- AnError
object on failure, ornull
on success
-
Unsubscribes from this shared file's comment section.
You can also call this directly on a SteamCommunity
instance, like so:
community.unsubscribeSharedFileComments(sharedFileOwnerSteamId, sharedFileId, callback);