Skip to content

A very simple pastebin npm package to interact with the pastebin api!

License

Notifications You must be signed in to change notification settings

casperiv0/pastebin-api

Folders and files

NameName
Last commit message
Last commit date
Mar 3, 2024
Jun 12, 2022
Aug 6, 2022
Jun 12, 2022
Jun 12, 2022
Mar 9, 2022
Aug 15, 2023
Feb 25, 2021
Oct 1, 2023
Aug 17, 2023
Aug 17, 2023
Jan 2, 2024
May 2, 2024
Jun 6, 2021
Jun 1, 2022

Repository files navigation

pastebin-api

License Downloads

A very simple npm package to interact with the pastebin api.

Features

  • Create pastes with all the available API data
  • Fetch the raw contents of a paste
  • Fetch pastes from the authenticated user via a user login
  • Delete pastes from the authenticated user via a user login

Installation

# npm
npm install pastebin-api

# Yarn
yarn add pastebin-api

# pnpm
pnpm add pastebin-api

Note > pastebin-api requires node.js version 14 or higher.

Usage

// src/main.js
import { PasteClient, Publicity, ExpireDate } from "pastebin-api";
// const { PasteClient, Publicity, ExpireDate } = require("pastebin-api"); // using CommonJS

// Tip: load dev key from a `.env` file
const client = new PasteClient("DEV_KEY_HERE");

/* ... */

Documentation

You can checkout the documentation here

Support

All stars/forks are appreciated! ⚡

Feel free to open a pull request with a new feature.

Made with ❤️ and TypeScript!

License

MIT © Casper Iversen