Once you've implemented your custom question type and its components, you can publish it to make it available for use in assessments. This involves packaging your question type and making it accessible within the Examplary platform.
Acquire an API key
To publish your question type, you need an API key. You'll find it on the settings page of your Examplary account — it's created automatically the first time you view it, so there's nothing to set up. There's one key per workspace: resetting it invalidates the previous one immediately, so update it everywhere you use it (e.g. CI secrets) if you do.
Note that API keys are scoped against your workspace, so any question types you publish will be available to all users in your workspace.
Setting public
Choose whether you want your question type to only be available to your workspace or to all Examplary users.
If you set public to true, your question type will be listed in the public question type library, making it available to all users. If it's not set, or set to false, it will only be available within your workspace.
{
"public": true
}Public question types go through a short review before they're visible outside your own workspace: your upload is usable in your own workspace right away, but a new or changed public question type only appears in the public question type library and becomes usable by other orgs once it's been approved. You'll get an email when it enters review, and another once it's approved or rejected.
If you're updating a question type that's already public, other orgs keep using your last-approved version while the update is in review — it isn't pulled from the library in the meantime.
Publishing your question type
Make sure you have a recent version of Node and NPM installed, then run the following command in your question type folder:
npx @examplary/cli upload --key YOUR_API_KEYYour question type will be uploaded to the Examplary platform, and if successful, it will immediately be available for use in assessments.
You can also provide the API key via environment variable (useful in CI): set EXAMPLARY_API_KEY and run npx @examplary/cli upload without the --key flag.
Once a question type has ever been used in a test, it cannot be deleted. This is to ensure that assessments remain consistent and that we don't break any existing tests.
Don't set public back to false to retire it — that also stops other orgs from resolving the definition of questions they already have, so those questions stop rendering. Upload a new version with deprecated set to true instead: existing questions keep rendering, grading and regenerating everywhere, but no new questions of that type can be created, and orgs that haven't already enabled it can no longer discover or enable it.
{
"deprecated": true
}