Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

kitsu

Latest version: v13.0.4

Overview

Last scanned
23 Nov 2026
Published
23 Nov 2026
npm package Publisher: wopian
295 Stars
47 Forks
7 Versions
23.6K Downloads
TypeScript Repo language

Scan summary

kitsu was last scanned on 23 Nov 2026 at version 13.0.4. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 7 versions; the latest was published on 23 Nov 2026.
  • Findings: No rules fired in version 13.0.4.
  • Downloads: 23,605 downloads.

Versions

7 versions published
Versions and the rules that fired in each
VersionPublishedStatus
13.0.4 LATEST 23 Nov 2026 No rules fired
13.0.3 19 Oct 2026 No rules fired
13.0.2 16 Oct 2026 No rules fired
13.0.1 16 Oct 2026 Not shown
13.0.0 16 Oct 2026 Not shown

No rules fired in 13.0.4

Findings

Findings for v13.0.4. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 13.0.4; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

JSON:API 1.1

Relationships are direct resources, arrays, or null. Resource metadata lives under $; document metadata stays at document level. See migration guidance and compliance boundaries.

Features

  • JSON:API 1.1 client document support
  • Automatically links relationships to data
  • Works in Node & browsers
  • Uses the [Promise] API

Response Comparison

{
  data: {
    id: '1'
    type: 'articles'
    attributes: {
      title: 'JSON API paints my bikeshed'
    }
    relationships: {
      author: {
        data: {
          id: '42'
          type: 'people'
        }
      }
    }
  }
  included: [
    {
      id: '42'
      type: 'people'
      attributes: {
        name: 'John'
      }
    }
  ]
}
const result = {
  data: {
    id: '1',
    type: 'articles',
    title: 'JSON API paints my bikeshed',
    author: { id: '42', type: 'people', name: 'John' }
  },
  included: [{ id: '42', type: 'people', name: 'John' }]
}
// data.author and included[0] reference the same object.

Install

Bun / npm / Yarn
bun add kitsu
npm install kitsu
yarn add kitsu
import Kitsu from "kitsu";

Quick Start

import Kitsu from 'kitsu'

// kitsu.app's API
const defaultApi = new Kitsu()

// Other JSON:API servers
const api = new Kitsu({
  baseURL: 'https://api.example/2'
})

// Using with async/await
interface Anime {
  id: string
  type: 'anime'
  canonicalTitle: string
}
const result = await api.get<Anime[]>('anime')
console.log(result.data?.[0]?.canonicalTitle)

// Using with Promises
api.get('anime')
  .then(result => console.log(result.data))
  .catch((error: unknown) => console.error(error))

// Fetching resources (get/fetch)
api.fetch('anime')
api.fetch('anime', { params: { filter: { id: 1 } } })
api.fetch('anime/1/episodes')
api.fetch('anime/1/relationships/episodes')

// Creating resources (post/create)
api.create('post', {
  content: 'some content'
})

// Updating resources (patch/update)
api.update('post', {
  id: '1',
  content: 'new content'
})

// Deleting resources (delete/remove)
api.remove('post', 1)

// JSON:API parameters
api.get('users', {
  params: {
    include: 'followers,waifu.character',
    fields: {
      users: 'slug,followers,waifu'
    },
    filter: {
      slug: 'wopian'
    },
    sort: '-id',
    page: {
      limit: 5,
      offset: 0
    }
  }
})

[More Examples]

If you're working with [kitsu.app]'s API, their [API docs][kitsu.app api docs] lists all available resources with their attributes & relationships

Contributing

See [CONTRIBUTING]

Releases

See [CHANGELOG]

License

All code released under [MIT]

API

Table of Contents
  • Kitsu
    • Parameters
    • Examples
    • get
      • Parameters
      • Examples
    • patch
      • Parameters
      • Examples
    • post
      • Parameters
      • Examples
    • delete
      • Parameters
      • Examples
    • self
      • Parameters
      • Examples
    • request
      • Parameters
      • Examples
    • plural
      • Examples
    • headers
      • Examples
    • interceptors
      • Examples
  • RequestConfig
    • Properties
    • Examples
  • KitsuOptions
    • Properties
    • Examples
  • ArbitraryRequest
    • Properties
    • Examples
  • KitsuResponse
    • Properties
    • Examples
Kitsu

JSON:API client using Axios, including adapters and interceptors.

Constructor options configure defaults. Pass params and document per request; constructor params and document are accepted by the type but ignored.

Parameters
  • options KitsuOptions Client defaults; see typed properties and individual examples in KitsuOptions (optional, default {})

    • options.baseURL string API base URL for relative resource paths (optional, default 'https://kitsu.app/api/edge')
    • options.headers JsonObject? Default headers. Accept and Content-Type initially use application/vnd.api+json. Media parameters and Accept alternatives are preserved.
    • options.query ("traditional" | "modern" | function (JsonObject?): string) Traditional mode repeats array keys. Modern mode uses key[]. A callback returns an encoded query string without ?. (optional, default 'traditional')
    • options.camelCaseTypes boolean Convert inferred outgoing types to camelCase; decoded types stay unchanged (optional, default true)
    • options.resourceCase ("kebab" | "snake" | "none") Generated URL case: library-entries, library_entries, or libraryEntries (optional, default 'kebab')
    • options.attributeCase ("kebab" | "snake" | "none") Keep attribute names by default. kebab and snake encode that case and decode camelCase. Nested JSON, relationships, metadata, extension attributes and queries stay unchanged. (optional, default 'none')
    • options.pluralize boolean Pluralize generated resource URLs and inferred outgoing types (optional, default true)
    • options.timeout number Timeout in milliseconds. Top-level 0 also selects 30000; use axiosOptions.timeout: 0 to disable. (optional, default 30000)
    • options.hoistData boolean Unwrap a single-resource document containing only data. Document metadata and included keep the wrapper; HTTP arrays and null stay under data. Resource metadata stays under $. (optional, default false)
    • options.axiosOptions AxiosRequestConfig? Axios defaults, overriding generated baseURL, timeout and paramsSerializer when supplied.
    • options.params JsonObject? Ignored at construction; pass config.params to a method
    • options.document JsonApiDocument? Ignored at construction; pass config.document on writes
Examples

Configure every constructor option

import Kitsu, { type KitsuOptions } from 'kitsu'
const options: KitsuOptions = {
  baseURL: 'https://bakery.example/api',
  headers: { Authorization: 'Bearer bakery-demo-token' },
  query: 'modern',
  camelCaseTypes: false,
  resourceCase: 'snake',
  attributeCase: 'kebab',
  pluralize: false,
  timeout: 10000,
  hoistData: false,
  axiosOptions: { withCredentials: true }
}
const api = new Kitsu(options)
await api.get('article', { params: { include: 'author' } })

Attribute casing enabled and disabled

const unchanged = new Kitsu({ attributeCase: 'none' })
const converted = new Kitsu({ attributeCase: 'kebab' })
await unchanged.post('people', { firstName: 'Mina' }) // attributes: { firstName: 'Mina' }
await converted.post('people', { firstName: 'Mina' }) // attributes: { 'first-name': 'Mina' }
// For a response with attributes: { 'first-name': 'Mina' }:
// unchanged.get('people/9') keeps data['first-name']; converted.get('people/9') gives data.firstName.

Document metadata, resource metadata, and hoisting

const wrapped = new Kitsu({ hoistData: false })
const hoisted = new Kitsu({ hoistData: true })
// Server body: { data: { type: 'people', id: '9', meta: { editable: true } } }
const first = await wrapped.get('people/9')
console.log(first.data.$.meta.editable) // true
const second = await hoisted.get('people/9')
console.log(second.$.meta.editable) // true; status and headers remain available
// If that body also contains meta: { total: 1 }, both clients retain data:
// result.meta.total describes the document; result.data.$.meta.editable describes the person.

Custom query serializer

const custom = new Kitsu({
  query: (params) => new URLSearchParams({ title: String(params?.title ?? '') }).toString()
})
await custom.get('articles', { params: { title: 'Moonlight Bread' } })
// URL ends with ?title=Moonlight+Bread
get

Fetch a resource, collection, related resources, or relationship linkage. Alias: fetch.

Parameters
  • model string Resource path: articles, articles/42, articles/42/author, or articles/42/relationships/author

  • config RequestConfig Per-request options (optional, default {})

    • config.headers JsonObject? Override default headers without changing client defaults
    • config.params JsonObject? Encoded query parameters: include, fields, sort, page, filter and extension families.
    • config.document JsonApiDocument? Ignored by this read method; use document on writes.
    • config.axiosOptions AxiosRequestConfig? Axios overrides, applied after generated headers and params. request() also permits method, url and data overrides. Use signal for cancellation.
Examples
await api.get('articles', {
  headers: { 'Accept-Language': 'en' },
  params: { include: 'author', fields: { articles: 'title,author' }, sort: '-createdAt', page: { number: 2, size: 10 }, filter: { title: 'Bread' } },
  axiosOptions: { timeout: 10000, signal: new AbortController().signal }
})

Returns Promise\ Decoded document with HTTP details

patch

Update a resource or replace relationship linkage. Alias: update.

Parameters
  • model string Resource or relationship path. With a bare resource name, body.id is appended to the URL.

  • body (JsonObject | Array\ | null) Flat resources or relationship identifiers. Use null to clear to-one linkage at a relationship endpoint.

  • config RequestConfig Per-request options (optional, default {})

    • config.headers JsonObject? Override default headers without changing client defaults
    • config.params JsonObject? Encoded query parameters: include, fields, sort, page, filter and extension families.
    • config.document JsonApiDocument? Extra write document members: meta, links, jsonapi, included and extensions. No data or errors. Ignored by bodyless resource DELETE.
    • config.axiosOptions AxiosRequestConfig? Axios overrides, applied after generated headers and params. request() also permits method, url and data overrides. Use signal for cancellation.
Examples

Resource and document metadata

await api.patch('articles', {
  id: '42', title: 'Moonlight Bread', $: { meta: { editable: true } }
}, { document: { meta: { requestId: 'demo-42' } } })

Clear relationships

await api.patch('articles/42/relationships/author', null)
await api.patch('articles/42/relationships/tags', [])

Returns Promise\ Decoded response with HTTP details

post

Create resources or add relationship linkage. Alias: create. Resource arrays require server support; no Atomic Operations processing.

Parameters
  • model string Resource or relationship path

  • body (JsonObject | Array\ | null) Flat resources or relationship identifiers; full related resources generate included

  • config RequestConfig Per-request options (optional, default {})

    • config.headers JsonObject? Override default headers without changing client defaults
    • config.params JsonObject? Encoded query parameters: include, fields, sort, page, filter and extension families.
    • config.document JsonApiDocument? Extra write document members: meta, links, jsonapi, included and extensions. No data or errors. Ignored by bodyless resource DELETE.
    • config.axiosOptions AxiosRequestConfig? Axios overrides, applied after generated headers and params. request() also permits method, url and data overrides. Use signal for cancellation.
Examples
await api.post('articles', { title: 'Moonlight Bread', author: { type: 'people', id: '9' } }, {
  document: { meta: { requestId: 'demo-42' } }
})
await api.post('articles/42/relationships/tags', [{ type: 'tags', id: '3' }])

Returns Promise\ Decoded response with HTTP details

delete

Delete a resource or remove relationship identifiers. Alias: remove. Resource DELETE sends no body. Relationship DELETE sends identifiers without appending their IDs to the URL. Legacy bulk resource DELETE requires server support.

Parameters
  • model string Resource name or relationship path. For a resource, pass its ID separately.

  • id (string | number | Array\<(string | number)>) Resource ID, including 0, or IDs for relationship/bulk deletion

  • config RequestConfig Per-request options (optional, default {})

    • config.headers JsonObject? Override default headers without changing client defaults
    • config.params JsonObject? Encoded query parameters: include, fields, sort, page, filter and extension families.
    • config.document JsonApiDocument? Extra write document members: meta, links, jsonapi, included and extensions. No data or errors. Ignored by bodyless resource DELETE.
    • config.axiosOptions AxiosRequestConfig? Axios overrides, applied after generated headers and params. request() also permits method, url and data overrides. Use signal for cancellation.
Examples
await api.delete('articles', '42') // DELETE /articles/42; no body
await api.delete('articles/42/relationships/tags', ['3'], { document: { meta: { requestId: 'demo-42' } } })
// DELETE /articles/42/relationships/tags; body: { data: [{ type: 'tags', id: '3' }] }

Returns Promise\ Decoded response; empty responses retain HTTP details

self

Fetch the first authenticated user. Server must support filter[self]=true; supplied filter is replaced.

Parameters
  • config RequestConfig Per-request options (optional, default {})

    • config.headers JsonObject? Override default headers without changing client defaults
    • config.params JsonObject? Encoded query parameters: include, fields, sort, page, filter and extension families. self() replaces filter with { self: true }.
    • config.document JsonApiDocument? Ignored by this read method; use document on writes.
    • config.axiosOptions AxiosRequestConfig? Legacy self() forwards this object as outer get configuration. Use get() for transport overrides.
Examples
const result = await api.self({ headers: { Authorization: 'Bearer bakery-demo-token' }, params: { fields: { users: 'name' } } })
console.log(result.data?.name)

Returns Promise\ First user under data, plus response headers. Legacy self() omits status and other document members.

request

Send an arbitrary JSON:API request without generated URL casing or pluralization.

Parameters

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • npm kitsu

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Copy of Template Design OX Blog (1)
Research

Thousands Of GitHub Accounts Hijacked With wfx-loot CI Secret Stealing Malware Via GitHub Actions & npm

Cry2Wolf: How to Tell a Real Bug from a Nothingburger
AI & VibeSec

Cry2Wolf: Not Every Branded Bug Deserves a Fire Drill

Microsoft's Official agent framework Hijacked
AI & VibeSec

BREAKING: Hijacked Releases of Microsoft’s Official agent-framework Steals Azure and CI Credentials

Frame 2085668439 (1)
Group 1261154229