npm install @iqrf/iqrf-repository-client
Client is a wrapper around API methods of IQRF Repository providing shared configuration for Axios instance.
import { Client } from '@iqrf/iqrf-repository-client';
const client = new Client();
import { Client } from '@iqrf/iqrf-repository-client';
const config: AxiosRequestConfig = {
baseURL: 'https://devrepo.iqrfalliance.org/api/',
};
const client = new Client({ config });
import axios, { type AxiosRequestConfig } from 'axios';
import { Client } from '@iqrf/iqrf-repository-client';
const config: AxiosRequestConfig = {
baseURL: 'https://repository.iqrfalliance.org/api/',
};
const axiosInstance = axios.create(config);
const client = new Client({ axiosInstance });