This package provides a standardized layer for accessing SimilarWeb services along with data types.
Install the service in your own project
npm install @torch-ai/similar-web
At the top of your application, or in an imported configuration file:
// Import the service definition and environment constants
import Service, { IServiceOptions } from "@torch-ai/similar-web";
// Create an instance of the service
const onInvalidCredentials = jest.fn(() => {});
const options: IServiceOptions = {
apiKey: process.env.API_KEY,
onInvalidCredentials: onInvalidCredentials,
};
export default new Service(options);
import service from "./similar-web";
try {
const capabilities = await service.utilities.capabilities();
} catch (error) {}
There is a limitation of 10 API request per second per SimilarWeb account; if 2 API keys belong to the same account, this limitation applies to both keys.
This package is provided through an MIT license. Usage of this package is freely available without restriction.
SimilarWeb itself has its own requirements. Please contact them for your account and terms.
Refer to the official documentation on Postman.
Clone the package from the repository.
npm install
A local file .env
file will need to be created with credentials for the api:
API_KEY=****
You may run tests in a continuous watch mode:
npm run-script test:watch
Open an issue requesting a version to publish.