This package was created by Naflouille Creations.
*Documentation will be available on SesAPI shortly.
To install this package, you first need to have NodeJS and NPM installed. Then you can install the package.
npm install sesame-api
To use the Sesame API, you must first define sesame in your NodeJS script
const sesame = require("sesame-api");
Once this is done, you can use the API functions to search the Sesame database.
const sesame = require("sesame-api");
let data = sesame.search.SearchInDatabase("Rithy", "users");
console.log(data);
The data
variable normally contains :
[
{
name: 'Rithy',
description: 'A guy.',
links: [...],
about: {
isStaff: false,
isModder: false,
isUCP: false,
isContrib: false,
isSesame: true
},
sesameID: 'usr-RTY-bDEO1zR7Gx',
templateImage: 'https://github.com/rithyn/rithy-archive/blob/main/pictures/ucp/rithy.png?raw=true'
}
]
The search function is normally sesame.search.SearchInDatabase(KEYWORDS, TYPE);
TYPE
can be "users"
, "ships"
, "mods"
, "codes"
and "communities"
.
KEYWORDS
is your keyword.