
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
@aller/labrador-utils
Advanced tools
yarn add @aller/labrador-utils
or
npm install @aller/labrador-utils
const { api } = require('labrador-utils')
const labApi = api({ base: 'http://api.secret.labrador.api.lol', site_id: 1 })
labApi.getArticleById({ id: 9999999, args... }) // {Article}
labApi.getArticlesByTags({ tags:['test', 'bil'], args... }) // [{Article}...]
labApi.getArticlesByTag({ tag: 'test', args... }) // [{Article}...]
labApi.getArticlesBySection({ section: 'mat', args... }) // [{Article}...]
labApi.getFrontPageById({ id: 9999999, args... }) // { FrontPage }
labApi.getFragment({ id: 9999999, args... }, ?clean) // Returns HTML string. If clean is provided, the resulting HTML is parsed throuhg parse5 to ensure valid markup.
Article-based high level methods also have query-specific options e.g:
labApi.getArticleById({
isFeatured: true,
visibility_status: 'P'
})
labApi.getQuery('/front', { query: 'id:999999', args... }).get() // { result: [{ FrontPage }...] }
labApi.getFrontPage({ query: 'id:9999999', args... }).getResult() // [{ FrontPage }...]
labApi.getArticles({ query: 'tag:test', args... }).getFrist() // { Article }
All base methods have 3 request methods
get() -> { result: [ { ENTITY }...] }
getResult() -> [ {ENTITY }... ]
getFirst() -> { ENTITY }
The base methods use the queryBuilder for parsing of the query-parameter. The queryBuilder takes nested JS objects/arrays as input and generates a query string as output.
labApi.getArticles({
query: [{ tag: ['nyheter', 'bil'] }, { 'review_score': '*' }],
}).getResult()
// query: (tag:(nyheter AND bil) AND review_score:*)
// The underlying queryBuilder method can also be directly accessed:
labApi.queryBuilder([{ tags: ['hello', { wat: ['test1', ['hello', 'hello2'], 'OR'] }] }])
// returns the string: '(tags:(hello AND wat:(test1 OR (hello AND hello2))))'
Concepts:
['nyheter', 'bil'] // -> (nyheter AND bil)
['nyheter', 'bil', 'OR'] // -> (nyheter OR bil), the 'OR' keyword needs to be the last el. of the array.
{ tag: ['nyheter', 'bil', 'OR']} // -> (tag:(nyheter OR bil))
// And any nested combination of these three concepts
All additional args. on all methods, are sent as query params, e.g:
labApi.getArticlesByTags({
tags: ['test', 'bil'],
limit: 5,
start: 5,
order: 'desc',
orderBy: 'published'
})
Defaults are found here
FAQs
Labrador utils
The npm package @aller/labrador-utils receives a total of 0 weekly downloads. As such, @aller/labrador-utils popularity was classified as not popular.
We found that @aller/labrador-utils demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 10 open source maintainers 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.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.