npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@newgameplusinc/organization-sdk

v1.0.0

Published

Official JavaScript/TypeScript SDK for the Odyssey Organization Service.

Readme

Odyssey Organization SDK

Official JavaScript/TypeScript SDK for the Odyssey Organization Service.

This SDK provides a typed, consistent, and runtime-safe interface to interact with the Odyssey Organization REST API, including organizations, organization users, spaces, rooms, invites, and related resources.


Requirements

  • Node.js 18+
  • Valid API key for the Odyssey Organization Service

Installation

npm install @newgameplusinc/organization-sdk

Initialization

import { OdysseyOrgSDK } from "@newgameplusinc/organization-sdk";

const sdk = new OdysseyOrgSDK({
  apiKey: "YOUR_API_KEY",
});

The API key is sent as a Bearer token in the Authorization header.


Usage

Organizations

Create an organization:

await sdk.organizations.create({
  name: "Acme Inc",
});

Update an organization:

await sdk.organizations.update("org_id", {
  name: "New Organization Name",
});

Get organization by ID:

const org = await sdk.organizations.getOrgById("org_id");

Get organizations of current user:

const orgs = await sdk.organizations.getUserOrgs();

Delete organization:

await sdk.organizations.deleteOrg("org_id");

Organization Users

Update organization user:

await sdk.organizations.updateOrgUser("org_user_id", {
  roleId: "admin",
});

Get organization user:

const users = await sdk.organizations.getOrgUser("org_id");

Delete organization user:

await sdk.organizations.deleteOrgUser("org_user_id");

Organization Invitations

Create org user invitation:

await sdk.organizationInvite.create({
  orgId: "org_id",
  email: "[email protected]",
  roleId: "member",
});

Accept invitation:

await sdk.organizationInvite.accept("invite_id");

Reject invitation:

await sdk.organizationInvite.reject("invite_id");

Spaces

Create space:

await sdk.space.create({
  orgId: "org_id",
  name: "Design Space",
  spaceTemplateId: "template_id",
  unrealProject: {
    unrealProjectId: "project_id",
    unrealProjectVersionId: "version_id",
  },
});

Update space:

await sdk.space.update("space_id", {
  name: "Updated Space Name",
});

Get spaces by organization:

const spaces = await sdk.space.getSpaceByOrg("org_id");

Get spaces by project:

const spaces = await sdk.space.getSpaceByProject("project_id");

Delete space:

await sdk.space.delete("space_id");

Space Users

Get space users:

const users = await sdk.space.getSpaceUser("space_id");

Update space user:

await sdk.space.updateSpaceUser("space_user_id", {
  roleId: "viewer",
});

Delete space user:

await sdk.space.deleteSpaceUser("space_user_id");

Space Settings

Update space settings:

await sdk.space.updateSetting("space_id", {
  isPublic: true,
  enableSharding: true,
});

Space Invitations

Create space invite:

await sdk.spaceInvite.create({
  spaceId: "space_id",
  email: "[email protected]",
  roleId: "viewer",
});

Accept space invite:

await sdk.spaceInvite.accept("invite_id");

Reject space invite:

await sdk.spaceInvite.reject("invite_id");

Error Handling

All errors are normalized and thrown as ApiError.

import { ApiError } from "@odyssey/organization-sdk";

try {
  await sdk.organizations.update("org_id", { name: "" });
} catch (err) {
  if (err instanceof ApiError) {
    console.error(err.status);
    console.error(err.message);
    console.error(err.code);
    console.error(err.details);
  }
}

All network, validation, and authorization errors follow the same error format.


Design Notes

  • Thin wrapper over the REST API
  • Prisma models define response types
  • Validation schemas define input types
  • Runtime argument checks for JavaScript users
  • Full type safety for TypeScript users

Build

npm run build

License

MIT