Security News
Combatting Alert Fatigue by Prioritizing Malicious Intent
In 2023, data breaches surged 78% from zero-day and supply chain attacks, but developers are still buried under alerts that are unable to prevent these threats.
A simple little wrapper for Company X's APIs.
You can request things like:
yarn add rt-sdk
in the root of your project. (This will add rt-sdk
to your package.json
)// Import the rt-sdk
const rt = require('rt-sdk');
rt-sdk
methods return a Promise()options
object isn't required... its.. optional.The options
object is a way of customizing your request to the rt-sdk
. It isn't required, but setting options
can be pretty helpful if you want to organize the results before the Promise resolves. You can use it to set maximum page item limits, organize items by oldest to newest, request a specific page of the results, etc. (If you aren't using any options, don't bother passing it to the method.)
const options = {
order: 'desc',
per_page: '10',
page: 1
}
rt.seasons() takes a series slug (and options
).
rt.seasons('rt-podcast', options)
.then(seasons => {
for (let season of seasons) {
console.log(season.attributes.title);
}
});
rt.season() takes a season slug (and options
).
rt.season('always-open-2018', options)
.then(episodes => {
for (let episode of episodes) {
console.log(episode.attributes.title);
console.log(episode.attributes.description);
console.log(episode.attributes.number);
}
});
rt.episode() takes an episode slug (and options
).
rt.episode('lets-play-2012-16', options)
.then(episode => {
console.log(episode.attributes.show_title);
console.log(episode.attributes.title);
console.log(episode.attributes.description);
console.log(episode.included.images);
});
rt.products() takes a series slug (and options
). If there isn't a specific product collection associated with the series it will return generic products.
rt.products('cow-chop-gaming', options)
.then(products => {
for (let product of products) {
console.log(product.title);
console.log(JSON.stringify(product.body_html));
console.log(product.image.src);
console.log(product.url);
}
});
rt.livestream() only takes the optional options
obj.
rt.livestreams(options)
.then(episodes => {
for (let episode of episodes) {
console.log(episode.attributes.title);
console.log(episode.type);
console.log(episode.attributes.description);
console.log(episode.included.images);
}
});
rt.series() only takes the optional options
obj.
rt.series(options)
.then(series => {
for (let serie of series) {
console.log(serie.attributes.title);
console.log(serie.type);
console.log(serie.attributes.slug);
console.log(serie.attributes.summary);
}
});
rt.queryByEpisode() takes an episode query string (and options
).
rt.queryByEpisode('Mark Nutt', options)
.then(episodes => {
for (let episode of episodes) {
console.log(episode.attributes.title);
console.log(episode.type);
console.log(episode.attributes.slug);
}
});
FAQs
A simple little wrapper for Company X's APIs.
The npm package rt-sdk receives a total of 1 weekly downloads. As such, rt-sdk popularity was classified as not popular.
We found that rt-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.
Security News
In 2023, data breaches surged 78% from zero-day and supply chain attacks, but developers are still buried under alerts that are unable to prevent these threats.
Security News
Solo open source maintainers face burnout and security challenges, with 60% unpaid and 60% considering quitting.
Security News
License exceptions modify the terms of open source licenses, impacting how software can be used, modified, and distributed. Developers should be aware of the legal implications of these exceptions.