2.0.5 • Published 2 years ago

yiff_api v2.0.5

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

Hi! and welcome to a SUPER yiff bookstore !! with various functions and etc! OwO

import:

var yiff = require("yiff_api");
//or
inport yiff from "yiff_api"

how to use?:

var yiff = require("yiff_api");
var y = new yiff.<event>([opitions])

y.<subEvent>

<...> = required

[...] = optional

event = event to get "yiffs"

opitions = options depending on the EVENT

subEvent = sub event


existing events:

e621 = search on e621

e926 = search on e926

yiff = random yiff

autoPost = pick up posts from time to time (beta)

existing options:

blacklist = tag list you don't want (works only on EVENT e621 and e926)


sub events:

e621

FunctionDescription
getposts(tags, limit, page)get e621 publications
randompost(tags)randomize a post
getpostsbyID(id)get a post from the id
getpostByMD5(md5)get a post from the MD5
setBlacklist(tags)set the blacklist
----------------

examples:

var yiff = require("yiff_api")
var y = new yiff.e621({blacklist:["oral_vore"]})//blacklist


//getposts
y.getposts("toriel").then(console.log)
y.getposts("toriel",2).then(console.log)
y.getposts("toriel",2,9).then(console.log)
//array
y.getposts(["toriel"]).then(console.log)
y.getposts(["toriel"],1).then(console.log)
y.getposts(["toriel"],2,10).then(console.log)
//more tags
y.getposts(["toriel","animal_bikini"]).then(console.log)
y.getposts(["toriel","animal_bikini"],1).then(console.log)
y.getposts(["toriel","animal_bikini"],2,8).then(console.log)


//randompost
y.randompost("toriel").then(console.log)
//more tags
y.randompost(["toriel","-human"]).then(console.log)

//getpostsbyID
y.getpostsbyID(847294).then(console.log)

//getpostByMD5
y.getpostByMD5("6fd0b0f2237543bfeee5ca9318a97b46").then(console.log)

//setBlacklist
y.setBlacklist("vore")
y.setBlacklist(["vore"])
y.setBlacklist(["vore", "gore" /*as many tags as you want :3*/])

e926

FunctionDescription
getposts(tags, limit, page)get e926 publications
randompost(tags)randomize a post
getpostsbyID(id)get a post from the id
getpostByMD5(md5)get a post from the MD5
setBlacklist(tags)set the blacklist
----------------

examples:

var yiff = require("yiff_api")
var y = new yiff.e926({blacklist:["oral_vore"]})//blacklist


//getposts
y.getposts("toriel").then(console.log)
y.getposts("toriel",2).then(console.log)
y.getposts("toriel",2,9).then(console.log)
//array
y.getposts(["toriel"]).then(console.log)
y.getposts(["toriel"],1).then(console.log)
y.getposts(["toriel"],2,10).then(console.log)
//more tags
y.getposts(["toriel","animal_bikini"]).then(console.log)
y.getposts(["toriel","animal_bikini"],1).then(console.log)
y.getposts(["toriel","animal_bikini"],2,8).then(console.log)


//randompost
y.randompost("toriel").then(console.log)
//more tags
y.randompost(["toriel","-human"]).then(console.log)

//getpostsbyID
y.getpostsbyID(40242).then(console.log)

//getpostByMD5
y.getpostByMD5("6fd0b0f2237543bfeee5ca9318a97b46").then(console.log)

//setBlacklist
y.setBlacklist("vore")
y.setBlacklist(["vore"])
y.setBlacklist(["vore", "gore" /*as many tags as you want :3*/])

yiff

FunctionDescription
gay()gay yiffs
straight()straight yiffs
lesbian()lesbian yiffs
gynomorph()synormorph yiffs
bulge()bulge yiffs
andromorph()andromorph yiffs
butts()butts fursuits
-------------------

examples:

var yiff = require("yiff_api")
var y = new yiff.yiff()

y.gay().then(console.log)

y.straight().then(console.log)

y.lesbian().then(console.log)

y.gynomorph().then(console.log)

y.bulge().then(console.log)

y.andromorph().then(console.log)

y.butts().then(console.log)

examples:

var yiff = require("yiff_api")
var y = new yiff.yiff()
let y_1 = new yiff.e621()

y_1.getposts('toriel').then(x => {
	var { posts } = x;
	if (!posts) {
		console.log('no post :(');
	} else {
		console.log(posts);
	}
});

y.gay().then(console.log)

async / await:

var yiff = require("yiff_api")
let y = new yiff.e621()

async function main() {
	let x = await y.getposts('toriel');

	var { posts } = x;
	if (!posts) {
		console.log('no post :(');
	} else {
		console.log(posts);
	}
}
main()

suport on "INSURES" for git