Update from Croquet to Multisynq
TL;DR To switch your application from Croquet to Multisynq, you need to:
- Update the Croquet library to the latest version (≥ 2.0.0), and
- Replace your Croquet API key with a Multisynq API key from multisynq.io/coder, and
- That's it. There's no step 3, it should just work.
Step 1: Update Croquet to version 2
If you use a bundler to build your app, install the latest version in your project:
npm i --save @croquet/croquet@latest
Otherwise, if the library is included directly via CDN, use the latest version in your script tag, e.g.
<script src="https://cdn.jsdelivr.net/npm/@croquet/croquet@2.0.4/pub/croquet.min.js">
</script>
Croquet 2 is designed to be a drop-in replacement for Croquet 1. There are some additions to the library, but they all should be backwards compatible.
Step 2: Switch to a Multisynq API Key
Go to multisynq.io/coder and click on "Get API key". Create an account, then create the API key and add the domain of your deployment to it.
Note: Unlike Croquet keys, Multisynq keys are always restricted, you need to add a domain!
Notice that a Multisynq key starts with "2..." whereas Croquet keys started with "1..." This way you can easily tell them apart.
Find the place in your code or configuration with the old API key, and paste in the new.
Step 3: Test Your App
Everything should work as before. If you encounter difficulties, contact us via Discord or email us at support@multisynq.io.