open-index/open-npm huggingface dataset:
npm package: @moar-market/sdk
Description: Moar Market SDK
Author: Moar Market
Latest version: 0.3.1

# @moar-market/sdk

The main SDK for interacting with Moar Market on the Aptos blockchain.
Provides configuration management, logging, and type-safe interfaces
for blockchain operations.

## 📦 Installation
```bash
pnpm add @moar-market/sdk
```

## 🔧 Configuration
```typescript
import { setAptosApiKey, setPanoraApiKey } from '@moar-market/sdk'

// set these config once in the beginning of the script
// setAptosApiKey(process.env.APTOS_API_KEY || '') // set aptos api key
// setPanoraApiKey(process.env.PANORA_API_KEY || '') // set panora api key

console.log('SDK initialized:')
```

## 📝 Examples

See [examples](./../../examples/src/user-actions.ts) for more detailed examples.
npm package: @moar-market/utils
Description: Moar Market Utils
Author: Moar Market
Latest version: 0.0.3

# @moar-market/utils

A collection of utility functions and helpers for the Moar Market SDK.
This package provides common functionality that's shared across SDK packages and
not recommended for external integration as it's meant to be used internally & does
not provide any promises of stability.

## 📦 Installation

```bash
# Install via pnpm (recommended)
pnpm add @moar-market/utils

```
npm package: @moataz84/link-crawler
Description: Crawl links or generate sitemaps for a URL.
Author: Moataz Ghazy
Latest version: 1.1.0

# link-crawler

A simple Node.js package that crawls internal links of a website and generates a sitemap.

## Installation

```sh
npm install @moataz84/link-crawler
```

## Usage

### Importing the Module

```js
const { validateURLInput, crawlURL, generateSitemap } = require("link-crawler")
```

### Functions

#### `validateURLInput(usrInput): async`
Asynchronous function that validates user input to determine if it's a valid URL. Returns the full URL with appropriate protocol (HTTP/HTTPS).

```js
validateURLInput("example.com").then(resp => {
  console.log(resp)
})
/*
{
  valid: true,
  URL: "https://example.com",
  usrInput: "example.com"
}
*/
```

#### `crawlURL(URL): async`
Asynchronous function that crawls a URL and returns a list of internal links. Recommended to be used in combination with `validateURLInput(URL)`.

```js
validateURLInput("example.com").then(async resp => {
  const links = await crawlURL(resp.URL)
  console.log(links)
})
/*
{
  links: ["https://example.com/page1", "https://example.com/page2"],
  time: "00:00:00.515"
}
*/
```

#### `generateSitemap(URL): async`
Asynchronous function that generates a sitemap file for the given URL, saves it in the local directory, and returns the file name. Recommended to be used in combination with `validateURLInput(URL)`.

```js
validateURLInput("example.com").then(async resp => {
  const sitemap = await generateSitemap(resp.URL)
  console.log(sitemap)
})
/*
{
  file: "sitemap-7d0d59b4-3aa2-4712-876e-a721cc73f99b.xml",
  time: "00:00:00.515"
}
*/
```

## License

MIT