
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.
@izhank216/content-types-fetch-pull
Advanced tools
import { fetchPull, encode, decode } from '@izhank216/content-types-fetch-pull';
async function main() {
// GET request
const todo = await fetchPull('https://jsonplaceholder.typicode.com/todos/1');
console.log(todo);
// POST request with JSON
const newTodo = await fetchPull('https://jsonplaceholder.typicode.com/todos', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ title: 'Test', completed: false }),
});
console.log(newTodo);
// Encode/decode
const encoded = encode('Hello World');
const decoded = decode(encoded);
console.log(decoded);
}
main();
const { fetchPull, encode, decode } = require('@izhank216/content-types-fetch-pull');
(async () => {
// GET request
const todo = await fetchPull('https://jsonplaceholder.typicode.com/todos/1');
console.log(todo);
// POST request with JSON
const newTodo = await fetchPull('https://jsonplaceholder.typicode.com/todos', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ title: 'Test', completed: false }),
});
console.log(newTodo);
// Encode/decode
const encoded = encode('Hello World');
const decoded = decode(encoded);
console.log(decoded);
})();
Include the library from jsDelivr:
<script src="https://cdn.jsdelivr.net/npm/@izhank216/content-types-fetch-pull@1.0.9/dist/content-types-fetch-pull.browser.js"></script>
<script>
// Access via the UMD global object
const { fetchPull, encode, decode } = ContentTypesFetchPull;
async function main() {
// GET request
const todo = await fetchPull('https://jsonplaceholder.typicode.com/todos/1');
console.log(todo);
// POST request with JSON
const newTodo = await fetchPull('https://jsonplaceholder.typicode.com/todos', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ title: 'Test', completed: false }),
});
console.log(newTodo);
// Encode/decode
const encoded = encode('Hello World');
const decoded = decode(encoded);
console.log(decoded);
}
main();
</script>
FAQs
A faster, clean fetch library
We found that @izhank216/content-types-fetch-pull demonstrated a healthy version release cadence and project activity because the last version was released less than 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.