@mymoid/api

MYMOID JavaScript API SDK

NPM Version npm bundle size

Welcome to the MYMOID JavaScript API SDK! 🎉 This library provides an easy-to-use interface for interacting with the MYMOID REST API using JavaScript or TypeScript.

Documentation

Getting Started

Installation

To install the SDK in your project, run the following npm command:

npm install @mymoid/api

SDK Basic Setup

Create a MymoidApi instance before initializing your application. You should only have one instance of the client.

[!IMPORTANT] Ensure that you have an API Key and an Organization ID, as these are required for setup. If you don't have them yet, please refer to our initial setup.

Using Environment Variables (Recommended)

Set the following environment variables in your project:

MYMOID_BASE_URL=https://apis.san.mymoid.com
MYMOID_API_KEY=*********************
MYMOID_ORGANIZATION_ID=******************

Passing Options to MymoidApi

Alternatively, you can pass options directly to MymoidApi instance:

import { MymoidApi } from '@mymoid/api'

const api = await MymoidApi({
baseUrl: '{MYMOID_BASE_URL}',
apiKey: '{MYMOID_API_KEY}',
organizationId: '{MYMOID_ORGANIZATION_ID}'
})

API Reference

Explore the available API methods in the @mymoid/api.

Feedback

Contributing

We appreciate feedback and contributions to this repository! Before you start, please review:

Raise an issue

To provide feedback or report a bug, please raise an issue on our issue tracker. We value your input!