UNPKG

@dima_aryze/reforge

Version:

TypeScript/JavaScript SDK for Reforge - Cross-chain token operations

59 lines 1.5 kB
"use strict"; /** * Main Reforge HTTP client implementation */ Object.defineProperty(exports, "__esModule", { value: true }); exports.ReforgeClient = void 0; const base_1 = require("./base"); /** * Reforge-specific HTTP client with convenient HTTP method wrappers */ class ReforgeClient extends base_1.BaseHttpClient { constructor(options) { super(options); } /** * Make GET request */ async get(path, params, options) { return this.makeRequest('GET', path, params, options); } /** * Make POST request */ async post(path, data, options) { return this.makeRequest('POST', path, data, options); } /** * Make PUT request */ async put(path, data, options) { return this.makeRequest('PUT', path, data, options); } /** * Make PATCH request */ async patch(path, data, options) { return this.makeRequest('PATCH', path, data, options); } /** * Make DELETE request */ async delete(path, options) { return this.makeRequest('DELETE', path, undefined, options); } /** * Get health status of the API */ async health() { return this.get('/health', undefined, { skipAuth: true }); } /** * Get API version information */ async version() { return this.get('/version', undefined, { skipAuth: true }); } } exports.ReforgeClient = ReforgeClient; //# sourceMappingURL=reforge-client.js.map