# @maxqwars/xconnect

> XConnect is an open library for working with AniLibria REST API's. Using a modern API based on promises.

Latest version **4.0.0** (published 2021-10-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install @maxqwars/xconnect
pnpm add @maxqwars/xconnect
yarn add @maxqwars/xconnect
bun add @maxqwars/xconnect
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 4.0.0 |
| Published | 2021-10-18 |
| First published | 2021-10-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 42.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Maxim "maxqwars" Maximenko |
| Maintainers | maxqwars |
| Keywords | rest-api, typescript-library, anilibria-api |

## Links

- npm: https://www.npmjs.com/package/@maxqwars/xconnect
- Repository: https://github.com/maxqwars/xconnect
- Homepage: https://github.com/maxqwars/xconnect#readme
- Issues: https://github.com/maxqwars/xconnect/issues
- npm.io page: https://npm.io/package/@maxqwars/xconnect

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 4.0.0 (latest) — 2021-10-18

## README

![Xconnect logo](/rep/rep-cover.png)

# XConnect

XConnect is an open library for working with AniLibria REST API. Using a modern API based on promises.

[Live demo](https://codesandbox.io/embed/xconnect-random-release-otyzs?fontsize=14&hidenavigation=1&theme=dark) -
[Online docs](https://maxqwars.github.io/xconnect/)

## Installation

```
npm i @maxqwars/xconnect
```

## Example of working with XConnect

Getting information about a random release using XConnect components

#### Using the XConnect module (recommended)

```
import { Database } from '@maxqwars/xconnect'

const XDatabase = new Database('api.service.com/v2/')

XDatabase.getRandomTitle({ /* query params */ })
  .then(title => console.log(title))
  .catch(e => onErrorCallback())

```

#### Using core classes (if target platform not support fetch, async/await, Promises)

```
import { URLBuilder, TitleQueryBuilder, API_ENDPOINTS_ENUM } from '@maxqwars/xconnect'

const U_BUILDER = new URLBuilder('api.service.com/v2/', true)
const QUERY_BUILDER = new TitleQueryBuilder()

const requestUrl = U_BUILDER()
  .useEndpoint(API_ENDPOINTS_ENUM.GET_TITLE)
  .useQuery(QUERY_BUILDER.code('release-code').build())
  .build()

```

## Current API support status

- [x] getTitle
- [ ] getTitles
- [x] getUpdates
- [ ] getChanges
- [ ] getSchedule
- [x] getRandomTitle
- [ ] getYouTube
- [ ] getFeed
- [x] getYears
- [x] getGenres
- [ ] getCachingNodes
- [ ] getTeam
- [ ] getSeedStats
- [ ] getRSS
- [x] searchTitles
- [ ] advancedSearch
- [ ] getFavorites
- [ ] addFavorite
- [ ] delFavorite

---
_Source: https://npm.io/package/@maxqwars/xconnect · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
