instagram-graph-api
Version:
A library to help perform requests to the Instagram Graph API.
30 lines (29 loc) • 826 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.AbstractMediaCommentsRequest = void 0;
const AbstractRequest_1 = require("../../AbstractRequest");
/**
* Abstract class to represent requests related to a media's comments.
*
* @author Tiago Grosso <tiagogrosso99@gmail.com>
* @since 0.5.0
*/
class AbstractMediaCommentsRequest extends AbstractRequest_1.AbstractRequest {
/**
* The constructor.
*
* @param accessToken The access token.
* @param mediaId the id of the media object.
*/
constructor(accessToken, mediaId) {
super(accessToken);
this.mediaId = mediaId;
}
/**
* @inheritdoc
*/
url() {
return `/${this.mediaId}/comments`;
}
}
exports.AbstractMediaCommentsRequest = AbstractMediaCommentsRequest;