
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
api-doc-js-sdk
Advanced tools
Official repository of the SDK used in the "Api Doc" project, this SDK consists of an abstraction of the Api-Doc rules, it contains Knex as a base, and has migration encapsulated within itself, with that, the user will be free to be an independent project from Expressjs, which is the base where the official Api Rest was built

$ npm install api-doc-js-sdk
or
$ yarn add install api-doc-js-sdk
The "Api Doc - SDK" uses the knex as a base, so the whole mechanism behind it is based on knex, including its settings format.
import ApiDoc from "api-doc-js-doc";
const config = {
dev: {
client: "pg",
connection: {
port: process.env.PORTDB,
host: process.env.HOSTDB,
user: process.env.POSTGRES_USER,
password: process.env.POSTGRES_PASSWORD,
database: process.env.POSTGRES_DB,
},
pool: { min: 0, max: 10, idleTimeoutMillis: 500 },
},
};
export default new ApiDoc(config.dev, "TheApiSecretKey");
import apiDoc from "../config/api";
const name = "name";
const email = "email@teste.com";
const password = "passwordTest";
// Async Await / Try Catch
async function newUserAsyncAwait() {
try {
const user = await apiDoc.userRegister(name, email, password);
console.log(user); // return new user
} catch (error) {
console.log(error.message); // return an eventual error
}
}
// Then Catch
apiDoc
.userRegister(name, email, password)
.then((newUser) => {
console.log(newUser); // return new user
})
.catch((err) => {
console.log(err); // return an eventual error
});
All other examples can be seen in the Api Doc, there the SDK is 100% used.
FAQs
SDK for Api Doc development
The npm package api-doc-js-sdk receives a total of 1 weekly downloads. As such, api-doc-js-sdk popularity was classified as not popular.
We found that api-doc-js-sdk demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.