2.0.0 • Published 8 months ago
@requestkit/node v2.0.0
Nodejs client for RequestKit
Installation
npm install @requestkit/nodeUsage
import { RequestKit } from "@requestkit/node";
const requestKit = new RequestKit({ apiKey: "your-api-key" });
const requests = await requestKit.getRequests();
console.log(requests);API
getRequests
const requests = await requestKit.getRequests();createRequest
const request = await requestKit.createRequest({
title: "My Request",
description: "This is a test request",
});upvoteRequest
const request = await requestKit.upvoteRequest(requestId);removeUpvoteFromRequest
const request = await requestKit.removeUpvoteFromRequest(requestId);getRequest
const request = await requestKit.getRequest(requestId);