1.1.1 • Published 2 years ago

@zalter/http2-client-node v1.1.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

@zalter/http2-client-node

An internal package

Usage

import { Client } from '@zalter/http2-client-node';

const client = new Client();
const response = await client.request('https://domain.example', {
  headers: {
    ':method': 'GET',
    'content-type': 'application/json'
  },
  body: JSON.stringify({ name: 'John' })
});

const data = response.body; // Buffer
console.log(`Received response status: ${response.headers[':status']}`);